S00-013: Bound runner prompts with explicit required task input reads

Changes: Keep startup instructions and exact context packets inline while listing supplementary task inputs as mandatory project reads. Preserve root containment, missing-artifact guidance and budget failures. Add S21-006 exact UI context regression and cover claim/review budgets for all tasks; leave stdin delivery unchanged.
Validation: make check passed all 68 tests, including delayed UTF-8 stdin/EOF, timeout and terminal-transition checks. All 556 current prompts fit 80000 characters; largest 77693. git diff --check passed. Foundation checks do not establish application readiness.

Task: S00-013
Agent: auto-ci-cd-5f68f03dd33b
Role: ci-cd
Action: claim
Status: review

Task title: Bound oversized S21-006 runner context without truncating requirements
This commit is contained in:
wt committed 2026-10-15 01:40:32 +07:00
1 parent c28412ae8f
commit b1014f36c9
9 files changed
+114 -12

No files matched your search

+13 -3
View File
@@ -121,17 +121,27 @@ The coordinator commits each transition before launching another agent.
'''
paths = ['AGENTS.md', 'README.md', 'master_prompt.md', 'roles/common.md', f'roles/{item["role"]}.md',
'docs/WEB_PROFILE.md', 'docs/ARCHITECTURE.md', 'docs/CONTRACTS.md', 'docs/WORKFLOW.md', 'docs/AUTOMATION.md']
# Only bounded, concrete referenced upstream artifacts, never the entire repository.
# Task-specific inputs are explicit required reads, rather than whole
# documents duplicated beside the exact requirements in the packet.
# Keep startup instructions inline for every fresh session.
required_reads = []
for raw in task['inputs']:
candidate = raw.split(' (')[0]
if candidate not in paths and (self.root / candidate).is_file():
paths.append(candidate)
if not (self.root / candidate).resolve().is_relative_to(self.root):
raise ValueError('Prompt input escapes project root')
if candidate not in paths:
required_reads.append(raw)
row = tracker.state()['tasks'][item['id']]
if row.get('handoff'):
paths.append(row['handoff'])
if item['action'] == 'review' and row.get('evidence'):
paths.append(row['evidence'])
chunks = [assigned]
if required_reads:
chunks.append('\n# Required task input reads (not inlined)\n\n'
'Before implementation or review, read these task inputs from the project. '
'Their contents are not included in this prompt; a missing required artifact is a blocker.\n\n'
+ '\n'.join('- ' + raw for raw in required_reads))
for rel in dict.fromkeys(paths):
path = (self.root / rel).resolve()
if not path.is_relative_to(self.root):