From the paper: "A Simple but Effective Approach to Improve Structured Language Model Output for Information Extraction" Li et al. 2024, proposes a way to improve structured output generation by asking one agent to generate output unconstrained, and then using a second agent to extract the output into the structured output format.
https://arxiv.org/pdf/2402.13364
This should be pretty simple to implement using effectful.
From the paper: "A Simple but Effective Approach to Improve Structured Language Model Output for Information Extraction" Li et al. 2024, proposes a way to improve structured output generation by asking one agent to generate output unconstrained, and then using a second agent to extract the output into the structured output format.
https://arxiv.org/pdf/2402.13364
This should be pretty simple to implement using effectful.