Skip to content

v2.16.0 - Context Window Management for Epic Closure

Choose a tag to compare

@bdouble bdouble released this 24 Jan 22:31
· 106 commits to main since this release

Added

  • Context Budget Allocation for Epic Closure: Explicit token limits (~4500 tokens total) prevent context window overflow when closing large epics
    • Epic description: 200 tokens (first 2 paragraphs)
    • Epic comments: 300 tokens (key decisions only)
    • Per-ticket summaries: 100 tokens each (max 3000 for 30 tickets)
    • Retrofit recommendations: 400 tokens
    • Downstream guidance: 400 tokens
    • CLAUDE.md updates: 200 tokens
  • Late Findings Detection: New tracking system for issues discovered during epic closure
    • Severity classification: CRITICAL (blocks closure), HIGH (requires user decision), MEDIUM/LOW (proceed with documentation)
    • Late Findings table format in epic closure reports
    • Automatic closure blocking for CRITICAL findings (hardcoded secrets, security vulnerabilities, disabled security checks)
  • Report Validation Layer: Validates epic-closure-agent output before posting to Linear
    • Required fields check: Status, Retrofit Analysis, Downstream Guidance, CLAUDE.md Updates
    • Retry-once logic for malformed responses
    • User decision prompt for persistent validation failures

Changed

  • 4-Tier Adaptive Scaling: Replaced single 6-ticket threshold with comprehensive tier system
    • Small (1-6 tickets): Direct context gathering
    • Medium (7-15 tickets): 2-3 parallel batches, standard summarization (100 tokens/ticket)
    • Large (16-30 tickets): 4-6 batches, ultra-condensed summaries (50 tokens/ticket)
    • Very Large (31+ tickets): Phased execution (gather → retrofit → downstream → closure)
  • Truncation Priority Matrix: Added explicit priority order for context overflow handling
  • ticket-context-agent Output Constraints: Enforced token limits for subagent responses

Improved

  • Epic closure now scales to 50+ ticket epics without context overflow
  • Better traceability with Late Findings audit trail
  • More reliable Linear posting with validation layer
  • Consistent patterns with execute-ticket context management

Full Changelog: v2.15.0...v2.16.0