Scheduling
Deferred optional upstream contribution. The standalone AIENOS repository and measurement under #32/#33 come first; this issue is not an initial test dependency. Revisit after the AIENOS result and when preparing the TandemLLM side.
Problem
The Phase 1 shared-prefix comparison needs a genuinely cold control. TandemLLM currently ignores cache_prompt: false, so client intent alone cannot establish that no prefix state was reused.
Upstream: https://github.com/0xBakeer/TandemLLM/issues/98
Inspected upstream baseline: 632c965aebbd7822c61ae0c75da383f419597a32. Reinspect the latest implementation and issue before editing; contribute to the existing work rather than opening a duplicate upstream issue.
Scope
Prepare a bounded upstream contribution for a per-request prefix-cache bypass, subject to upstream agreement on semantics. Keep caching behavior unchanged for omitted/true values. A bypassed request reads its entire prompt and leaves the previously stored reusable state intact. Account for resident, RAM and disk restoration paths; explicitly disable response caching for benchmark requests. Lookup drafting is a separate mechanism and stays disabled in Phase 1.
Acceptance
- Trace request parsing through cache selection, resident-prefix reuse, restoration and accounting; identify every route that could defeat the control.
- Define and document false/true/omitted semantics, including resident state, cache writes and parallel slots.
- Demonstrate false produces
timings.cache_n = 0and full prompt computation, not merely a zeroed counter. - A subsequent ordinary request still finds the previously stored prefix; the bypass does not replace or corrupt it.
- Tests cover cold/warm, resident/restored, parallel-slot isolation, errors and cancellation where applicable.
- Warm/cold outputs are compared on the same token history; retain exact mismatches and numerical diagnostics rather than silently accepting them.
- Include a negative control that deliberately enables reuse and makes the bypass test fail.
- Add documentation and run upstream-required CPU checks; retain explicit NOT_RUN status for Spark checks until executed.
Delivery
Reviewable patch against a pinned upstream commit, reproduction commands, test logs and a benchmark capability declaration. If upstream declines this API, agree an equally observable native-adapter reset/bypass mechanism and record that decision; do not silently substitute restarting a server as an equivalent control. No new cache architecture or backend replacement.