mirror of
https://github.com/Kaelio/ktx.git
synced 2026-06-10 08:05:14 +02:00
* fix(llm): wire prompt caching through all Anthropic call sites
- page-triage classifier + light-extraction now put the static skill
prompt in `system:` so the per-document caches hit instead of
re-sending boilerplate in the user message every call.
- Description generation builders return `{ system, user }` with
instruction text + word limit moved into the cacheable system.
- Relationship-LLM proposal framing moved to `system:`.
- `KtxMessageBuilder.wrapSimple` skips the history breakpoint for
single-message calls (cache write that could never be reused).
- Gateway backend now sets `anthropic-beta: extended-cache-ttl-2025-04-11`
so 1h TTLs don't silently downgrade to 5m on Gateway routes.
* fix(llm): keep wrapSimple history breakpoint so multi-step agent loops cache
Reverts the wrapSimple `messages.length > 1` guard from the prior commit.
agent-runner uses wrapSimple with a single user message, but generateText
runs a multi-step tool loop inside it — the cache marker on the first user
message is reused by every subsequent step, so it isn't waste.
The release validator (scripts/validate-llm-debug-jsonl.mjs) also requires
a `message-part` marker target in captured debug JSONL.
|
||
|---|---|---|
| .. | ||
| credentials.test.ts | ||
| credentials.ts | ||
| data-dictionary.test.ts | ||
| data-dictionary.ts | ||
| description-generation.test.ts | ||
| description-generation.ts | ||
| embedding-text.test.ts | ||
| embedding-text.ts | ||
| enrichment-state.test.ts | ||
| enrichment-state.ts | ||
| enrichment-summary.test.ts | ||
| enrichment-summary.ts | ||
| enrichment-types.test.ts | ||
| enrichment-types.ts | ||
| index.ts | ||
| local-enrichment-artifacts.test.ts | ||
| local-enrichment-artifacts.ts | ||
| local-enrichment.test.ts | ||
| local-enrichment.ts | ||
| local-scan.test.ts | ||
| local-scan.ts | ||
| local-structural-artifacts.test.ts | ||
| local-structural-artifacts.ts | ||
| orchestrator.test.ts | ||
| orchestrator.ts | ||
| relationship-artifacts.test.ts | ||
| relationship-artifacts.ts | ||
| relationship-benchmark-report.test.ts | ||
| relationship-benchmark-report.ts | ||
| relationship-benchmarks.test.ts | ||
| relationship-benchmarks.ts | ||
| relationship-budget.test.ts | ||
| relationship-budget.ts | ||
| relationship-candidates.test.ts | ||
| relationship-candidates.ts | ||
| relationship-composite-candidates.test.ts | ||
| relationship-composite-candidates.ts | ||
| relationship-diagnostics.test.ts | ||
| relationship-diagnostics.ts | ||
| relationship-discovery.test.ts | ||
| relationship-discovery.ts | ||
| relationship-feedback-calibration.test.ts | ||
| relationship-feedback-calibration.ts | ||
| relationship-feedback-export.test.ts | ||
| relationship-feedback-export.ts | ||
| relationship-formal-metadata.test.ts | ||
| relationship-formal-metadata.ts | ||
| relationship-graph-resolver.test.ts | ||
| relationship-graph-resolver.ts | ||
| relationship-llm-proposal.test.ts | ||
| relationship-llm-proposal.ts | ||
| relationship-locality.test.ts | ||
| relationship-locality.ts | ||
| relationship-name-similarity.test.ts | ||
| relationship-name-similarity.ts | ||
| relationship-profiling.test.ts | ||
| relationship-profiling.ts | ||
| relationship-review-apply.test.ts | ||
| relationship-review-apply.ts | ||
| relationship-review-decisions.test.ts | ||
| relationship-review-decisions.ts | ||
| relationship-scoring.test.ts | ||
| relationship-scoring.ts | ||
| relationship-threshold-advice.test.ts | ||
| relationship-threshold-advice.ts | ||
| relationship-validation.test.ts | ||
| relationship-validation.ts | ||
| sqlite-local-enrichment-state-store.ts | ||
| type-normalization.test.ts | ||
| type-normalization.ts | ||
| types.test.ts | ||
| types.ts | ||