Fixed
- Streaming no longer crashes on chunks with empty
choices(e.g. the usage-only final chunk emitted whenstream_options={"include_usage": True}). Thanks @MrDiggles2! (#27) stream_optionsis no longer sent on non-streaming requests. The inference API rejects it unlessstream=True, soinvoke()on models configured withstream_optionsfailed with a 400 validation error.usage_metadatais still populated from the response. (#29)user_agent_versionnow reports the actual installed package version instead of a hardcoded stale one. (#30)
Changed
- Updated integration tests for the current inference API: replaced retired models with currently served ones; empty prompts are now accepted; raised the o3-mini test token budget. (#28)
Install: pip install langchain-gradient==0.2.1