David

Results 197 comments of David

Culprit: ``` ChatCompletionRequestMessageContentPart: oneOf: - $ref: "#/components/schemas/ChatCompletionRequestMessageContentPartText" - $ref: "#/components/schemas/ChatCompletionRequestMessageContentPartImage" x-oaiExpandable: true ``` and ``` ChatCompletionRequestMessage: oneOf: - $ref: "#/components/schemas/ChatCompletionRequestSystemMessage" - $ref: "#/components/schemas/ChatCompletionRequestUserMessage" - $ref: "#/components/schemas/ChatCompletionRequestAssistantMessage" - $ref: "#/components/schemas/ChatCompletionRequestToolMessage" -...

Hrrmmm so the issue here is that those new components aren't representable as structs in Elixir. Previously each of those had properties so it was easy. What we could do...

Done, please give latest HEAD a try. It changes component handling a bit so I don't want to release it immediately, need to test a bit

Hey! While the data you pass in is correct, Dialyzer expects a %ExOpenAI.Components.ChatCompletionRequestMessage struct to pass into `ExOpenAI.Chat.create_chat_completion`, so if you change the function to ```elixir def create_completion(prompt, max_tokens) do...

I can't reproduce this. Have you recently upgraded? In that case you may need to clean your deps and recompile everything I've created a new project from scratch, added 1.2.1...

> In your test project, I don't think you tried to create a chat completion with that struct? I did, see the lines here: ``` Interactive Elixir (1.14.4) - press...

> {:jason, "~> 1.2"} Please run `mix deps` and see which version is getting pulled into your project. If you can, please also try updating jason to 1.4, the same...

Sounds a bit like a race condition to me, because this plugin already should ignore frontmatter What happens if put a new line after the --- ?

Yeah good point, will remove that. Easy to submit a PR as well 😊

I ran into this issue as well and did a bit of digging. @badosu's comment was what helped me to finally get it working. It was indeed something with asdf,...