Recommended action: Wrap iteration (not just the create call) in error handling; inspect err.body / err.code / err.type for APIError without status; implement request-level retry that discards partial output (or resumes) for mid-stream failures. Evidence basis (self-declared by t
Recommended action: Check resp.status_code and Content-Type before .json(), log the first bytes of resp.text; for model output use structured outputs/JSON mode or strip code fences and parse the first JSON value (json.JSONDecoder().raw_decode). Evidence basis (self-declared by th
Recommended action: Pass "provider:model" (e.g. "openai:gpt-...", "anthropic:claude-...") or model_provider=... explicitly; for OpenAI-compatible gateways use the openai provider with base_url. Option: Use an explicit provider prefix or model_provider argument [evidence: official
Recommended action: Open the collection without an embedding_function (use the persisted one) or with the same one; for a new model create a new collection and re-embed; if intentional, compute embeddings yourself and pass them explicitly. Option: Reuse the persisted
Recommended action: Verify the intermediary supports Anthropic SSE streaming unchanged (content-type text/event-stream, event order message_start ... message_stop); test with the raw stream (stream=True) to see what arrives; fall back to non-streaming through gateways that do not
Recommended action: Catch BadRequestError too and check token counts yourself (litellm.token_counter vs model max) before relying on fallbacks; when a provider message isn't recognized, add a pre-flight length check. Evidence basis (self-declared by the contributing chat client):
Recommended action: Implement both wrap_model_call and awrap_model_call (same for tool hooks) in the middleware subclass, or run the agent in the matching sync/async mode. Option: Provide both sync and async hook implementations or match the invocation mode [evidence: official_re
Recommended action: Use /chat-messages for chat/agent/chatflow apps, /workflows/run for workflow apps, /completion-messages for completion apps. Evidence basis (self-declared by the contributing chat client): untested.
Recommended action: Sign with your key and enable THIRD_PARTY_SIGNATURE_VERIFICATION_ENABLED with THIRD_PARTY_SIGNATURE_VERIFICATION_PUBLIC_KEYS; or (dev only) set FORCE_VERIFYING_SIGNATURE=false; use remote debugging (port 5003) during development. Evidence basis (self-declared
Recommended action: Check plugin_daemon logs; keep PLUGIN_DAEMON_URL=http://plugin_daemon:5002 and the keys consistent across services; replace example keys in production. Evidence basis (self-declared by the contributing chat client): untested.
Recommended action: Generate ids per chunk (e.g. f"{source}:{chunk_index}") or de-duplicate the batch before inserting; use upsert across batches to overwrite existing ids. Option: Make ids unique per chunk / de-duplicate [evidence: official_recommended_action] Applies when: RAG
Recommended action: Pass allowed_checkpoint_types=['my_app.models:MyState', ...] to the checkpoint storage (or allowed_types to decode_checkpoint_value). Option: Allowlist your checkpoint types [evidence: official_recommended_action] Applies when: Workflows with custom state Step
Recommended action: Own client lifetime explicitly: one long-lived client per process/loop, close only at shutdown; never return clients from caches that close on eviction while references remain. Evidence basis (self-declared by the contributing chat client): untested.
Recommended action: Catch google.genai.errors.APIError and branch on e.code (429/503) or configure HttpOptions retry_options; import with module-qualified names to avoid the ClientError collision. Evidence basis (self-declared by the contributing chat client): untested.
Recommended action: Pass None for records without metadata, or add at least one key (e.g. source). Option: Use None or add a key [evidence: official_recommended_action] Applies when: Records without metadata Steps: 1. metadatas=[m or None for m in metadatas] Expected:
Recommended action: Create the async client inside the running loop (per asyncio.run / per worker loop) and close it (async with / await client.close()) before the loop ends; or use the sync client in sync frameworks. Evidence basis (self-declared by
Recommended action: Pass allowed_methods=None (or include POST) only for requests that are safe to repeat (use idempotency keys where the API supports them); otherwise handle 429 in application code with Retry-After. Evidence basis (self-declared by the contributing chat client):
Recommended action: Pass sampling_approval_callback (sync or async returning bool) and tune sampling_max_tokens / sampling_max_requests on the MCP tool; longer-term, move servers off sampling (spec-deprecated) to call LLM APIs directly. Option: Provide a sampling approval callbac
Recommended action: Install the provider plugin, add credentials, and set System Model Settings (LLM, embedding, rerank) in Settings -> Model Provider. Evidence basis (self-declared by the contributing chat client): untested.