Skip to content

Brain cadence never beats its own 8 s deadline — every boundary burns a model call and falls back [spec 03-02 §2.3] #273

Description

@wine-fall

What it is

cadenceMode: 'brain' buys a cheap-model judgment on talk-vs-music at each
boundary. It never lands: BrainCadence.nextKind races the task against
DEFAULT_TIMEOUT_MS = 8_000 (src/director/cadence.ts:91), and the task is
slower than that every time — so every boundary in brain mode pays a full model
call, throws its answer away, and returns EveryNCadence's.

Measured this session against the real SDK, the real choose_segment task and
the real prompt, with the deadline lifted so the task could finish:

9265ms  11480ms  10419ms  8339ms  8851ms     (n=5, median 9.3 s, min 8.3 s)

Every sample is over the 8 s deadline. The cost is the SDK's default extended
thinking: a bounded tool-use task spends most of its wall-clock writing
reasoning nothing reads back — the same term that made a music pick take
~100 s before #164's fix, where Task.thinking: 'disabled' cut a pick's
faked-network time from 82 s to 11.6 s.

The failure is silent by construction: the fallback returns a legal answer, so
nothing in the dev log says the judgment was discarded. It costs tokens on
every boundary and delivers the local policy.

Default mode is every_n, so this affects only a listener who chose brain
mode — which is exactly the listener who cannot tell it is not working.

Spec

specs/spec03/03-02-ducking.md §2.3 (the CadencePolicy seam: "one cheap-model
judgment per boundary, hard-falling-back on failure or timeout" — the fallback
is meant to be the exception).

Done when

The cadence task carries thinking: 'disabled' (or the deadline is raised on
evidence), and a re-measurement over n>=5 real boundaries shows the model's own
answer returning inside the deadline at the median — plus a dev-log line that
says when a cadence judgment was discarded, so a silent fallback cannot hide
again.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingengEngineering work: a measured defect or a performance target

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions