docs(llms): add AI/ML API provider configuration example - #7322
docs(llms): add AI/ML API provider configuration example#7322hugoaimlapi wants to merge 5 commits into
Conversation
AI/ML API (aimlapi.com) is OpenAI-compatible and already supported by LiteLLM as the 'aiml' custom_llm_provider (litellm/llms/aiml/), which this project uses for any provider outside SUPPORTED_NATIVE_PROVIDERS - no code change needed, just documenting the existing path.
LLM(...) passes any unrecognized kwarg straight through to litellm.completion() via additional_params, so extra_headers works today with zero code change - verified by reading BaseLLM's model_validator (base_llm.py:286). Opt-in only: only users who copy this exact snippet send it.
|
Hi! I'm Hugo from aimlapi.com — an AI aggregator that gives access to 1000+ models in one API, trusted by 400k+ users. We'd love to be available as a verified provider option inside CrewAI docs — so we went ahead and opened the PR. If you have any questions - happy to answer. My contacts: hugo@aimlapi.com (email / Slack), Telegram: @hug0the |
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Team Run ID: 📒 Files selected for processing (4)
Included review availability: Your plan provides up to 10 included reviews per hour; 9 remain after this review. 📝 WalkthroughWalkthroughThe LLM provider guides for English, Arabic, Korean, and Brazilian Portuguese now include AI/ML API configuration. Each guide documents ChangesAI/ML API provider documentation
Merge Risk: ⚪ Minimal · up to This adds AI/ML API setup examples to four localized LLM guides. It does not alter runtime behavior or dependencies, and no merge-blocking risk remains. 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment Warning |
Related issue
Fixes #7321
Summary
AI/ML API (aimlapi.com) already works with CrewAI: LiteLLM ships it as the
aimlprovider, and CrewAI sends any provider outsideSUPPORTED_NATIVE_PROVIDERSto LiteLLM. It is just not documented, so users have to guess theaiml/prefix and theAIML_API_KEYvariable.This PR adds an "AI/ML API" accordion to the LLM provider examples in
docs/edge/en/concepts/llms.mdx, right after Nebius AI Studio, in the same shape as the other LiteLLM-backed providers:AIML_API_KEYenv varLLM(...)example withmodel="aiml/openai/gpt-5-5"uv add 'crewai[litellm]'noteThe same block is added to the
ar,koandpt-BRdocs, as AGENTS.md asks.Docs only. No code, no
docs.json, no new dependency, nothing changes for current users.Verification
Manual checks:
aimlis not a native provider, so it goes to LiteLLM. The model string is never rewritten, so LiteLLM getsaiml/openai/gpt-5-5and calls AI/ML API.extra_headersneeds no code: unknownLLM(...)kwargs land inadditional_paramsinBaseLLMand are passed to the completion call..env,from crewai import LLMimport,arfix.Additional context
extra_headers={"X-AIMLAPI-Source": "agent/crewai"}line is optional. It only tags requests for our own analytics and changes no behavior. Happy to drop it.llm-generatedlabel; I cannot add labels here, so could a maintainer add it?