Skip to content

feat(context-guard): ground the default zone boundaries in research, per model #6227

Description

@kyle-sexton

Problem

context-guard's default zone boundaries are not grounded in recorded research. Today there are three zones (smart, acceptable, dumb) with these defaults: smart up to 50% and acceptable up to 75% by percentage; by tokens, 100K/160K on a 200K window and 200K/400K on a 1M window (plugins/context-guard/hooks/zone.ts:10-17). The owner works to different bands (about 15%, 40%, 60% as the compact-or-handoff target, 80% as the wrap-up limit), and those bands come from community practice (largely Matt Pocock's), not measured data.

Decide, then build

  • Research what context fill degrades quality, per current model (Opus 5.5, Fable 5.1, Sonnet 5.5, and Haiku when its next version ships), in this order: Anthropic guidance first (if Anthropic publishes a number, that is the default), then published long-context evaluations, then recognized practitioners, with dates and dissent noted.
  • Whether the defaults should vary by model as well as by window size, and whether a fourth zone (a wrap-up band before the hard limit) earns its place.
  • Align with the repo's existing compact-versus-handoff guidance (session-flow skills) so the guard's zones and that guidance name the same thresholds.

Acceptance

  • Each default boundary in zone.ts cites its basis (URL and date, or judgment).
  • README and CHANGELOG record any change, with a version bump.

Related

Activity

  1. added
    needs-triageNot yet classified. Floor until a type and one priority tier are set.
    on Oct 4, 2026
  2. github-actions commented on Oct 4, 2026

    @github-actions
    Contributor

    Thanks for filing this. As I understand it: zone.ts's current smart/acceptable/dumb boundaries (50%/75% and the related token bands) are community-derived defaults, not grounded in measured or vendor-published data, and this asks to research per-model degradation thresholds (Anthropic guidance first, then evaluations, then practitioners, with dates/dissent), decide whether defaults should vary by model and whether a fourth "wrap-up" zone is warranted, align with the session-flow compact/handoff guidance, and record a cited basis for each boundary plus a README/CHANGELOG version bump.

    The problem, acceptance criteria, and related issues (#6222, #6225) are all clear - I don't see anything missing. I didn't find an existing duplicate; #6222 and #6156 touch context-guard's zones but cover different problems (display bugs and deferred follow-ons) rather than this research-grounding request.

    Automated triage. A maintainer reviews it.

  3. removed
    needs-triageNot yet classified. Floor until a type and one priority tier are set.
    on Oct 12, 2026
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

    priority: mediumReal value, no hard deadline; normal backlog flow.

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions