TIL: Sum Types With `instructor_ex`
The Instructor Elixir library lets you retrieve structured output from LLMs like the OpenAI GPT models. But I found that having it return structs that are sum types is not that straightforward. Simple Instructor responses For this post, let’s looks at survey questions as an example. You can define…