The python3 -c block imported internal entrypoint code directly and pasted module paths into agent prompts — a security boundary violation. Switch to the thin-client verb (added in agent-runtimes a116aedb). Claude-Session: https://claude.ai/code/session_0124mK2BVfCdkELLXDCr5Zzs
66 lines
2.6 KiB
YAML
66 lines
2.6 KiB
YAML
name: scope-decompose-sonnet
|
|
version: 1
|
|
description: Scope and decompose a spec into tagged tasks using Sonnet planning
|
|
runtime: spec-writing-sonnet-repo
|
|
input:
|
|
state: spec-reviewed-arch
|
|
tags_forbidden: []
|
|
required_artifacts: []
|
|
output:
|
|
state: scoped-tagged
|
|
scope_budget:
|
|
files_modified_max: 10
|
|
lines_diff_max: 500
|
|
wall_clock_seconds_max: 2400
|
|
nodes:
|
|
- id: agent
|
|
kind: agent
|
|
# Decomposition is spec-test-tier work (claude/stage-routing.md): Sonnet,
|
|
# not airouter. 2026-07-04 E2E: Qwen3.6 empty-delivered this stage (task
|
|
# "succeeded" touching only .gitignore, zero work items created) — the
|
|
# template NAME never set the model; the node model: field does.
|
|
template: spec-writing-sonnet-repo
|
|
# cli defaults to "claude" — the anthropic-cloud OAuth composite drives
|
|
# the claude CLI; "cli: agentic" is the OpenAI-compatible runner and
|
|
# fails fast with "OPENAI_BASE_URL required" (E2E 2026-07-04).
|
|
model: sonnet
|
|
runtime_env:
|
|
AGENT_REPO_URL: "git@gitea.oreillyit.nz-ai-enablement:skynet/agent-runtimes-agents.git"
|
|
AGENT_BRANCH: "spec/auto-draft"
|
|
CP_URL: "http://controlplane.agent-runtimes.svc.cluster.local:8100"
|
|
# AR-38: this stage's deliverable is work items POSTed to the CP, not a
|
|
# repo diff — the empty-deliverable audit would fail every success.
|
|
AGENT_EMPTY_DELIVERABLE_CHECK: "false"
|
|
prompt: |
|
|
The agent-runtimes project repo is cloned at /workspace/project.
|
|
Change to that directory before doing any work.
|
|
|
|
Find the spec file in /workspace/project/spec/ (the spec was
|
|
written in an earlier pipeline stage — look for a file whose name matches
|
|
the concept title '${item.title}' as a slug, e.g. spec/<slug>.md).
|
|
Read that spec carefully.
|
|
|
|
Write a decomposition plan to /workspace/.agent-output/decompose.json with
|
|
exactly this structure:
|
|
{
|
|
"project_id": "${item.project_id}",
|
|
"space_id": "${item.space_id}",
|
|
"parent_item_uuid": "${item.uuid}",
|
|
"tasks": [
|
|
{
|
|
"title": "...",
|
|
"description": "...",
|
|
"flow_state": "needs-tests",
|
|
"spec_ids": ["WT-EVAL-1", "..."],
|
|
"test_files": ["tests/triggers/test_schema.py", "..."],
|
|
"tags": ["airouter-eligible"]
|
|
}
|
|
]
|
|
}
|
|
|
|
Include "airouter-eligible" in tags only for single-file, self-contained
|
|
tasks that Qwen3.6 can handle alone. Omit tags for complex multi-file tasks.
|
|
|
|
After writing decompose.json, run this command to create the work items:
|
|
|
|
python3 -m lib.cp_cli planner items decompose ${item.uuid} --file /workspace/.agent-output/decompose.json |