Skip to content

feat(agents): per-agent prompt-cache TTL pin, 1h for implement-next - #411

Merged
danielhanold merged 9 commits into
mainfrom
feat/per-agent-prompt-cache-ttl-pin-shipped-1h-for-implement-next
Oct 11, 2026
Merged

danielhanold merged 9 commits into
mainfrom
feat/per-agent-prompt-cache-ttl-pin-shipped-1h-for-implement-next

Conversation

@danielhanold

@danielhanold danielhanold commented Oct 11, 2026 •

Copy link
Copy Markdown
Owner

↩ Change 0546 — Per-agent prompt-cache TTL pin, shipped 1h for implement-next

Adds an optional per-agent cache_ttl pin beside model and effort. The Claude Code wrapper renders it as experimental.cacheTtl, and docket ships 1h for the Claude docket-implement-next agent only, which loses about half its cost to prompt-cache expiry while it waits on builds and suites.

  • Layering: built-in, then global, per field; a repository-layer cache_ttl blocks writes like any agent pin; cache_ttl: auto clears the shipped pin.
  • Cursor, Codex, OpenCode: value dropped from their files with an agent-cache-ttl-dropped install warning (none with shipped defaults).
  • docket diagnostic config shows the TTL; the private-visibility fold now recognises agent pins from the config registry.
  • Docs: docs/install/models-and-effort.md and the agent-layer reference.

Review (docket-review-standard)

# Severity Finding Disposition
1 important private-visibility fold did not treat cache_ttl as an agent pin fixed 2870236
2 minor effective-config listing hid cache_ttl fixed 49c8443
3 minor agent digest counted a TTL non-Claude harnesses never render fixed c19ca26
4 minor stale freeze-point comment in internal/config/defaults.go fixed c19ca26
5 minor dated cost figures in the agent-layer reference fixed c19ca26

…visibility fold

Review finding: isAgentPin hand-listed model/effort/runner, so a
repository-layer agents.<harness>.<agent>.cache_ttl was carried into the
private config instead of being dropped and reported. Derive the agent-pin
leaves from the config registry's agents.* rows instead of a spelling list.
…sting

Review finding: agentLines rendered only model / effort, so the shipped
1h cache TTL on claude implement-next, a global override, and a global
auto that clears it were all invisible in the human effective block.
Append a ttl segment when a pin resolves or a layer declared one, and
name the cache_ttl layer in the bracket when it differs from the model's.
- AgentDigest digests cache_ttl only for harnesses in cacheTTLHarnesses,
  since the digest identifies what was rendered; add a test that a codex
  digest is unchanged by a cache_ttl.
- defaults.go package comment anchors the agent table's parity oracle on
  testdata/repositories/v0.9.13 and its PROVENANCE.md entry.
- agent-layer.md drops the dated per-agent cost table and figures, keeping
  the qualitative reason; regenerate embedded assets and lower the budget
  row to 212/1951.
@danielhanold
danielhanold merged commit 50420ee into main Oct 11, 2026
1 check passed
@danielhanold
danielhanold deleted the feat/per-agent-prompt-cache-ttl-pin-shipped-1h-for-implement-next branch October 11, 2026 14:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant