From eee4e98ab552287d0aa8cf029012ecc6cf88e581 Mon Sep 17 00:00:00 2001 From: skobeltsyn Date: Mon, 15 Jun 2026 10:10:25 +0300 Subject: [PATCH] docs(caching): provider count seven -> eight + guard it in DocsConsistencyTest caching.md still said `ModelProvider.entries` has "seven values" / "seven first-party values" (lines 39, 109) after Gemini made it eight. It slipped both gates: the 0.8.0 truth-surface sweeps grepped "seven provider" (not "seven values"), and DocsConsistencyTest's provider-count check only guarded providers.md / model-and-tools.md / SECURITY.md. - caching.md: seven -> **eight** (both spots) + note that Gemini is its own wire shape (engine-side caching, no cache_control). - DocsConsistencyTest: add docs/caching.md to the `provider count words` claims, so the count is now guarded and can't silently drift again. DocsConsistencyTest green. Co-Authored-By: Claude Opus 4.8 (1M context) --- docs/caching.md | 4 ++-- src/test/kotlin/agents_engine/core/DocsConsistencyTest.kt | 1 + 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/docs/caching.md b/docs/caching.md index 637fa9d..7cb317b 100644 --- a/docs/caching.md +++ b/docs/caching.md @@ -36,7 +36,7 @@ val agent = agent("ResearchBot") { | **DeepSeek** | Automatic disk-based caching | Inherits the OpenAI-compatible request shape; no extra wiring needed. Cached-input tokens surface on `TokenUsage`. | | **Ollama** | Engine-level KV-cache reuse (no wire-level control) | Hints degrade to no-op. Prefix stability (see below) is what makes the engine cache hit. | -The four rows above are the four **wire shapes**; `ModelProvider.entries` has seven values — Kimi, OpenRouter, and Perplexity extend the OpenAI adapter and inherit its row (automatic prefix caching where the upstream supports it). Fourth-party deployments that ride on top of one of these wire shapes are documented under [Under evaluation](#under-evaluation) below. +The four rows above are the four **wire shapes**; `ModelProvider.entries` has **eight** values — Kimi, OpenRouter, and Perplexity extend the OpenAI adapter and inherit its row (automatic prefix caching where the upstream supports it), and Gemini is its own wire shape (its prompt caching is not wired in this table — engine-side, no `cache_control`). Fourth-party deployments that ride on top of one of these wire shapes are documented under [Under evaluation](#under-evaluation) below. ### `CacheHint` model @@ -106,7 +106,7 @@ These are the silent killers — `System.currentTimeMillis()` interpolated into ### Under evaluation -These backends are **not** first-party `ModelProvider` adapters (`ModelProvider.entries` has seven first-party values; these are not among them). Consumers who point the OpenAI adapter at one of these endpoints (via `openAiBaseUrl`) get OpenAI-compatible behavior, but the caching characteristics differ: +These backends are **not** first-party `ModelProvider` adapters (`ModelProvider.entries` has eight first-party values; these are not among them). Consumers who point the OpenAI adapter at one of these endpoints (via `openAiBaseUrl`) get OpenAI-compatible behavior, but the caching characteristics differ: | Backend | Wire-shape compatibility | Caching note | |---|---|---| diff --git a/src/test/kotlin/agents_engine/core/DocsConsistencyTest.kt b/src/test/kotlin/agents_engine/core/DocsConsistencyTest.kt index 953d194..299c87e 100644 --- a/src/test/kotlin/agents_engine/core/DocsConsistencyTest.kt +++ b/src/test/kotlin/agents_engine/core/DocsConsistencyTest.kt @@ -39,6 +39,7 @@ class DocsConsistencyTest { val word = countWords[ModelProvider.entries.size] val claims = listOf( "docs/providers.md" to "`ModelProvider.entries` has **$word** values", + "docs/caching.md" to "`ModelProvider.entries` has **$word** values", "docs/model-and-tools.md" to "$word providers ship today", "docs/model-and-tools.md" to "All $word providers share the `ModelClient` interface", "SECURITY.md" to "$word first-party providers",