litellm), PraisonAI still detects what each model can do — structured outputs, function calling, prompt caching, and web search — via a conservative built-in heuristic.
You installed PraisonAI without extra dependencies, and structured outputs still work.
Quick Start
1
Install lean (no litellm)
gpt-4o still reports structured-output support without litellm.2
Add litellm for authoritative detection
How It Works
Eachsupports_* helper checks for litellm first, then falls back to the static heuristic only when litellm is absent.
litellm stays authoritative whenever it is installed — even when a helper is missing or raises, the result is False rather than the heuristic, so an unsupported param never reaches a provider request. The static heuristic runs only when litellm is None.
What each model gets on a lean install
These are the exact patterns from the static heuristic — names are lowercased and anyprovider/ prefix is stripped before matching.
¹ Only
*-search-preview variants (e.g. gpt-4o-search-preview) report native web search.
² Claude uses web_fetch instead of native web search, so it is intentionally excluded from the web-search heuristic — this is expected, not a bug.
³ Mistral / Mixtral / Llama / Grok report serial function calling but not parallel — the parallel heuristic is deliberately narrower.
⁴ Function calling is disabled by design for embedding, whisper, tts, and dall-e model names.
The web-search heuristic also matches any model name containing the literal substring
search, plus gemini-2 and grok-3. Anthropic Claude is excluded on purpose.Lean or full install?
Use this to decide whether the lean install is enough or whether you should add
litellm.When to install litellm anyway
Add litellm when a wrong True would break a real request.
- Newly released models with no matching pattern — the heuristic returns
Falseuntil you add litellm. - Non-standard model IDs — custom deployments, self-hosted proxies, or renamed models.
- Production workloads where a wrong
Truewould send an unsupportedresponse_formatorweb_search_optionsparam and fail the call.
The helpers live at
praisonaiagents.llm.model_capabilities, but you never call them directly — the Agent uses them for you. Just install litellm when you need authoritative detection.Best Practices
Install litellm for anything user-facing in production
Install litellm for anything user-facing in production
The static heuristic is conservative, not exhaustive. For production traffic,
pip install litellm so capability detection matches each provider’s live catalogue.Lean installs are ideal for edge, serverless, and air-gapped CI
Lean installs are ideal for edge, serverless, and air-gapped CI
When you target a single provider and want a small footprint, skip
litellm. Structured outputs, function calling, and prompt caching still gate correctly for mainstream models.Unknown models return False — add litellm before shipping a new provider
Unknown models return False — add litellm before shipping a new provider
A novel model with no matching pattern reports
False across the board on a lean install. Install litellm before shipping support for a new provider so its capabilities are detected.Related
Lite Package (BYO-LLM)
A different feature — the
praisonaiagents.lite subpackage with LiteAgent, not the litellm-free capability fallback.Installation Extras
Optional dependency groups for bots, gateway, and storage.
Model Fallback
Fall back across models — also uses capability info.
Model Capabilities
Higher-level model-selection layer, distinct from these
supports_* helpers.
