OpenRouter fix
In a recent release we introduced the ability to change the User-Agent string, as well as setting a default User-Agent for Fantasy.
Well... looks like OpenRouter has specific behavior for the OpenAI Go SDK that otherwise break, so need to keep the original SDK User-Agent for OpenRouter specifically so it works correctly.
We also changed the default User-Agent a bit to better follow the convention:
- Previous:
Charm Fantasy/v1.2.3 - Now:
Charm-Fantasy/v1.2.3 (https://charm.land/fantasy)
Changelog
Fixed
- 96f0454: fix(openai): don't mutate shared languageModelOptions (@meowgorithm)
- 522e026: fix(openai): propagate noDefaultUserAgent to responsesLanguageModel (@meowgorithm)
- e8560e6: fix(openai): use noDefaultUserAgent in all responses API calls (@meowgorithm)
- 2e29858: fix(openrouter): avoid brittle User-Agent assertion (@meowgorithm)
- 7dc3888: fix(openrouter): don't set User-Agent (@meowgorithm)
- a3b8a69: fix(openrouter): preserve anthropic reasoning signature in streaming (@andreynering)
- 152acfe: fix: guard against nil EncryptedContent dereference in reasoning details (@andreynering)
- 50a1116: fix: improve default user-agent string (@andreynering)
Docs
- 182ba5f: docs(openai): correct grammar in comment (@meowgorithm)
Other stuff
- fa02069: v0.12.2 (@andreynering)
Thoughts? Questions? We love hearing from you. Feel free to reach out on X, Discord, Slack, The Fediverse, Bluesky.