Skip to content

Repair planning responses without fabricated human acknowledgements#564

Merged
wwind123 merged 1 commit into
mainfrom
fix/558-planning-repair-human-requirements
Jul 14, 2026
Merged

Repair planning responses without fabricated human acknowledgements#564
wwind123 merged 1 commit into
mainfrom
fix/558-planning-repair-human-requirements

Conversation

@wwind123

Copy link
Copy Markdown
Owner

Fixes #558\n\n## Summary\n- derive plan-state and plan-revision repair acknowledgements from active signed-requirement/direct-discussion context\n- strip fabricated legacy acknowledgement blocks when no acknowledgement is required\n- forward context for initial plans and revisions\n- add regression coverage for acceptance-criteria prose without signed human requirements\n\n## Tests\n- python3 -m pytest tests/test_repair.py tests/test_orchestrator_issue.py tests/test_agent_loop.py -q\n- python3 -m pytest -q

@wwind123

Copy link
Copy Markdown
Owner Author

Implemented the approved repair changes for #558.

  • Planning repair now treats active signed-requirement and direct-discussion context as authoritative.
  • Fabricated human-requirement markers and sections are removed when no acknowledgement is required.
  • Initial plans and plan revisions receive the active repair context.
  • Added regression coverage for issue acceptance-criteria prose without signed human requirements.

Tests: python3 -m pytest tests/test_repair.py tests/test_orchestrator_issue.py tests/test_agent_loop.py -q (461 passed); python3 -m pytest -q (1539 passed).

-- OpenAI Codex: gpt-5.6-luna

@wwind123

Copy link
Copy Markdown
Owner Author

Review verdict: Approved

Repair prompt now treats the active repair_surfaced_requirement_ids / requires_direct_discussion_ack context as authoritative for plan_state and plan_revision, stripping fabricated HUMAN_REQUIREMENTS_ADDRESSED markers when nothing was surfaced, and orchestrator.py threads the new context through the initial plan_state call (previously only plan_revision had it). Verified the exact issue #558 scenario end-to-end (fabricated ack with a bare 'Requirement N' label and no signed comment) is covered by test_plan_revision_repair_strips_fabricated_ack_without_signed_requirement_context, and genuine-requirement preservation is retained by the existing test_issue_loop_plan_revision_repair_preserves_signed_human_requirements. The new ValueError guard in _build_repair_prompt correctly restricts surfaced_requirement_ids/requires_direct_discussion_ack to coder_followup/plan_state/plan_revision without affecting plan_review or other kinds. GitHub checks are still pending (test in_progress); that's an external wait state, not a code issue.

-- Anthropic Claude: claude-sonnet-5

@wwind123

Copy link
Copy Markdown
Owner Author

Review verdict: Approved

The PR correctly propagates the planning human requirements context to the repair step and updates the repair prompt to strictly prioritize the active context over the malformed response. This resolves the bug where fabricated acknowledgements were preserved during format repair. Regression tests are comprehensive.

-- Google Antigravity: Gemini 3.1 Pro (High)

@wwind123
wwind123 merged commit 4681d8b into main Jul 14, 2026
1 check passed
@wwind123
wwind123 deleted the fix/558-planning-repair-human-requirements branch July 14, 2026 04:55
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.

Repair plan revisions must remove fabricated human-requirements acknowledgements

1 participant