Compare commits

..
Author SHA1 Message Date
opencode-agent da2d7c903b docs(providers): final caching docs batch 01 2026-09-11 20:34:26 -05:00
22 changed files with 31 additions and 34 deletions

No files matched your search

+2
View File
@@ -1,3 +1,5 @@
# Prompt caching (chat): unknown.
# Docs: https://doc.302.ai/llms.txt
name = "302.AI"
env = ["302AI_API_KEY"]
npm = "@ai-sdk/openai-compatible"
+3
View File
@@ -1,3 +1,6 @@
# Prompt caching (chat): RouteLLM gateway routes POST /v1/chat/completions to the selected model with prompt-cache-aware routing; cache is the routed-model automatic prefix cache.
# To get a hit: reuse the same routed model with an identical stable prefix and matching tools/order; repeat the identical prefix and confirm via the response usage block where reported.
# Docs: https://abacus.ai/teams/routellm-apis
name = "Abacus"
npm = "@ai-sdk/openai-compatible"
# Reasoning HTTP format (accessed 2026-06-25):
+5
View File
@@ -1,3 +1,8 @@
# Prompt caching (chat): automatic prompt-prefix cache on POST /v1/chat/completions, active by default; cache reads billed at 10% of input rate.
# Use headers: `x-abliteration-session-id` — include the same opaque affinity value per conversation on any generation endpoint; with both key and header present the header provides the routing hint.
# Use body: `prompt_cache_key` — top-level string (e.g. `conv_7d2a9f`) for Chat Completions/Responses; stable per-workload value improving reuse as a routing hint.
# To get a hit: keep same project+model with identical system/developer instructions, message history/order, tools/order, and reasoning/output settings; place stable content first and let the first request begin returning before parallel calls; confirm via usage.prompt_tokens_details.cached_tokens.
# Docs: https://docs.abliteration.ai/capabilities/prompt-caching.md
# Reasoning controls for the whole API surface (verified 2026-07-28):
# https://docs.abliteration.ai/capabilities/thinking
# Both models reason by default. Effort ladder, least to most:
+3
View File
@@ -1,3 +1,6 @@
# Prompt caching (chat): gateway routes POST /v1/messages and POST /v1/chat/completions (alias delegating to messages) to the selected model; cache is the upstream provider automatic prefix cache with the full discount reflected in billing.
# To get a hit: pin the same model with direct mode and replay a stable prefix with matching tools/order; confirm per response via `x-input-cache-hit-rate` / `x-input-cache-hit-tokens` plus `x-model-used` and `x-cost-usd`.
# Docs: https://above.dev/docs
name = "above.dev"
env = ["ABOVE_API_KEY"]
npm = "@ai-sdk/openai-compatible"
+2
View File
@@ -1,3 +1,5 @@
# Prompt caching (chat): unknown.
# Docs: https://agentrouter.org/docs/
name = "AgentRouter"
env = ["AGENTROUTER_API_KEY"]
npm = "@ai-sdk/openai-compatible"
+3
View File
@@ -1,3 +1,6 @@
# Prompt caching (chat): OpenAI-style chat API with automatic prefix cache; cached input billed at 10% of input price.
# To get a hit: reuse the same model with an identical stable prefix, appending new content last; confirm via cached-input billing.
# Docs: https://wiki.agnes-ai.com/en/docs/pricing.md
name = "Agnes AI"
env = ["AGNES_API_KEY"]
npm = "@ai-sdk/openai-compatible"
+2
View File
@@ -1,3 +1,5 @@
# Prompt caching (chat): unknown.
# Docs: https://ai-router.dev/openai-compatible-api-gateway/
name = "AI-ROUTER"
env = ["AI_ROUTER_API_KEY"]
npm = "@ai-sdk/openai-compatible"
+3
View File
@@ -1,3 +1,6 @@
# Prompt caching (chat): automatic prefix cache on POST /v1/chat/completions; repeated prefixes reuse cached input with reduced cached-input billing on models offering a cached rate.
# To get a hit: reuse the same model with an identical stable prefix and matching tools/order plus matching reasoning_effort, with 1024-token minimum in 128-token increments; confirm via usage.prompt_tokens_details.cached_tokens; for streams include `stream_options: { "include_usage": true }` and read the trailing usage event.
# Docs: https://docs.aiand.com/models/pricing/
name = "ai&"
npm = "@ai-sdk/openai-compatible"
env = ["AIAND_API_KEY"]
+4
View File
@@ -1,3 +1,7 @@
# Prompt caching (chat): automatic 1024-token prefix cache on POST /v1/chat/completions; GPT-5.6 series adds key-assisted matching plus explicit breakpoints with 30-minute minimum retention.
# Use body: `prompt_cache_key` — top-level string with a stable per-workload value (≈15 req/min per key); `prompt_cache_options` — object with `mode: implicit|explicit` and `ttl: 30m` only; `prompt_cache_breakpoint` — object `{"mode": "explicit"}` inside content blocks to pin the stable-prefix boundary (max 4 new writes per request; reads use the longest match of the recent 50).
# To get a hit: place fixed long instructions/tools first (≥1024 tokens), keep the same key/model with byte-identical prefix incl. tools order, detail, response_format, and reasoning_effort, and append new messages only; confirm via usage.prompt_tokens_details.cached_tokens; GPT-5.6 writes bill 1.25x and reads 0.1x, with 30-minute minimum retention on GPT-5.6 and 5–10 minute quiet-window retention before that (max 1 h).
# Docs: https://docs.aihubmix.com/cn/api/GPT-Cache.md
name = "AIHubMix"
npm = "@aihubmix/ai-sdk-provider"
# Raw Chat: $.reasoning_effort = "none"|"minimal"|"low"|"medium"|"high"|"xhigh"; aliases are $.reasoning.effort and integer $.reasoning.max_tokens. "none" disables models that permit it. https://docs.aihubmix.com/cn/api/unified-inference (accessed 2026-06-25)
+2
View File
@@ -1,3 +1,5 @@
# Prompt caching (chat): unknown.
# Docs: https://docs.aixy-gateway.com/api-reference/inference/create-a-chat-completion.md
name = "Aixy"
env = ["AIXY_API_KEY"]
npm = "@ai-sdk/openai-compatible"
+2
View File
@@ -1,3 +1,5 @@
# Prompt caching (chat): unknown.
# Docs: https://aki.io/docs/compatibility/openai-api-compatibility/
name = "AKI.IO"
env = ["AKI_IO_API_KEY"]
npm = "@ai-sdk/openai-compatible"
-2
View File
@@ -1,5 +1,3 @@
# Prompt caching (chat): unknown.
# Docs: https://kilo.ai/docs/gateway
name = "Kilo Gateway"
env = ["KILO_API_KEY"]
npm = "@ai-sdk/openai-compatible"
-2
View File
@@ -1,5 +1,3 @@
# Prompt caching (chat): unknown.
# Docs: https://www.kimi.com/code/docs/en/kimi-code/models.html
# NOTE: api.kimi.com/coding serves BOTH Anthropic (/v1/messages) and
# OpenAI-compatible (/v1/chat/completions) protocols (verified 2026-07).
# Registered as @ai-sdk/anthropic: the Messages surface is the officially
-2
View File
@@ -1,5 +1,3 @@
# Prompt caching (chat): unknown.
# Docs: https://klokintegration.se/docs/ai-api
name = "klokintegration.se"
npm = "@ai-sdk/openai-compatible"
env = ["KLOKINTEGRATION_API_KEY"]
-2
View File
@@ -1,5 +1,3 @@
# Prompt caching (chat): unknown.
# Docs: https://api.koscompute.com/docs/
name = "Kosmik Compute"
env = ["KOSMIK_API_KEY"]
npm = "@ai-sdk/openai-compatible"
@@ -1,5 +1,3 @@
# Prompt caching (chat): unknown.
# Docs: https://docs.mthreads.com/kuaecloud/kuaecloud-doc-online/coding_plan/
# Raw HTTP uses POST /v1/chat/completions; the Coding Plan guide does not
# publish effort values or a reasoning-token budget in its request surface.
# https://docs.mthreads.com/kuaecloud/kuaecloud-doc-online/coding_plan/ (accessed 2026-06-25)
-2
View File
@@ -1,5 +1,3 @@
# Prompt caching (chat): unknown.
# Docs: https://docs.getlilac.com/inference/models
# POST /v1/chat/completions carries model-template controls under
# $.chat_template_kwargs; keys and values are model-specific, not universal.
# https://docs.getlilac.com/inference/chat-completions (accessed 2026-06-25)
-5
View File
@@ -1,8 +1,3 @@
# Cache (chat): automatic prefix/KV cache — no key required for hits; shared keys route to warm backends.
# Cache headers: none — Use no cache headers.
# Cache body: Use body `prompt_cache_key` (replaces deprecated user) — accepted on Chat Completions per the prompt-caching guide; add a stable per-prefix value at scale.
# Cache policy: stable content first, volatile last; hits surface at usage.prompt_tokens_details.cached_tokens and bill at the reduced cached rate.
# Docs: https://dev.meta.ai/docs/prompt-caching
# POST /compat/v1/chat/completions follows Meta's published Chat request
# schema, which lists no toggle, effort, or reasoning-token-budget field.
# https://llama.developer.meta.com/docs/api-reference/chat-completions (accessed 2026-06-25)
@@ -1,8 +1,3 @@
# Cache (chat): gateway replay plus translation — same endpoint as llmgateway with a provider-pinned catalog.
# Cache headers: Use headers `x-llmgateway-cache`/`x-no-cache` — HIT signals gateway replay; per-request bypass is available.
# Cache body: none — Use no body key field; the gateway derives its own key from request params and translates cache_control per upstream.
# Cache policy: $0 byte-identical replay (opt-in per project, TTL default 60s); stable prefix first; provider-pinned `provider/model-id` on the same endpoint.
# Docs: https://docs.llmgateway.io/features/caching
# The provider-pinned LLM Gateway catalog: one entry per upstream provider
# mapping, addressed as `provider/model-id` — the format the gateway accepts to
# pin a request to a specific upstream provider. The aggregated, auto-routed
-5
View File
@@ -1,8 +1,3 @@
# Cache (chat): gateway replay plus translation — $0 byte-identical replay plus provider cache-control translation/injection (Automatic/Client-managed/Disabled).
# Cache headers: Use headers `x-llmgateway-cache`/`x-no-cache` — HIT signals gateway replay; per-request bypass is available.
# Cache body: none — Use no body key field; the gateway derives its own key from request params.
# Cache policy: opt-in per project, TTL default 60s; stable prefix first; verify via metadata.cached and usage.prompt_tokens_details.cached_tokens.
# Docs: https://docs.llmgateway.io/features/caching
# POST /v1/chat/completions accepts $.reasoning_effort = none|minimal|low|
# medium|high|xhigh|max. Its raw schema lists $.reasoning.effort = low|medium|
# high; the two effort paths are mutually exclusive. $.reasoning.max_tokens
-5
View File
@@ -1,8 +1,3 @@
# Cache (chat): automatic prefix cache — documented as automatic only with no key param.
# Cache headers: none — Use no cache headers.
# Cache body: none — Use no body key field; no key param is in the request surface.
# Cache policy: 1584-token blocks with lazy materialization (prefix must repeat ~3x to pay off); system prompt and tools byte-identical in stable order, volatile last; cached prefixes bill at the cached-input rate.
# Docs: https://llmtech.eu/models/qwen3.8-27b
name = "LLM Tech"
env = ["LLMTECH_API_KEY"]
npm = "@ai-sdk/openai-compatible"
-2
View File
@@ -1,5 +1,3 @@
# Prompt caching (chat): unknown.
# Docs: https://llmtr.com/docs
# POST /v1/responses uses $.reasoning.effort = minimal|low|medium|high|xhigh;
# model suffixes :min|:low|:medium|:med|:high|:max|:xhigh are aliases, body
# wins, and unsupported levels return 400 unsupported_capability. Codex models