guidance
guidance copied to clipboard
Support for Anthropic Claude v3+ models
From Claude 3 onwards, all future Anthropic models are only compatible with the new Messages API instead of the legacy Text Completions API.
Changes to the prompt input structure are required. The Messages API is backwards compatible with other Anthropic models so it should not break usage for anyone who is still on Claude 2.1 or lower.
Specifically, this line needs to be fixed: https://github.com/guidance-ai/guidance/blob/main/guidance/models/_anthropic.py#L59
With Claude 3.5 I think this is an important feature to have. OpenAi is finally getting a much needed competitor !
I believe we have this supported with the latest guidance release 🙂.