Documentation IndexFetch the complete documentation index at: /llms.txtUse this file to discover all available pages before exploring further.
Fetch the complete documentation index at: /llms.txt
Use this file to discover all available pages before exploring further.
在 DSPy 中将 AI Sonar 配置为 OpenAI 兼容的语言模型
openai/
/v1
export API_KEY="sk-your-api-key"
import os import dspy lm = dspy.LM( "openai/claude-sonnet-5", api_key=os.environ["API_KEY"], api_base="https://api.aisonar.dev/v1", ) dspy.configure(lm=lm)
qa = dspy.ChainOfThought("question -> answer") response = qa(question="What should I monitor in an LLM gateway?") print(response.answer)
gpt-5.4-mini
claude-sonnet-5
deepseek-v4-flash