From a89829e31d40b5fdfd1b88445bb413d6bffdd18e Mon Sep 17 00:00:00 2001 From: Paul O'Reilly Date: Tue, 28 Apr 2026 17:15:10 +1200 Subject: [PATCH] Add write-code-simple workflow: narrow airouter single-test impl MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Single-node airouter workflow for one-requirement/one-test tasks. Optional test_target param focuses the agent on a specific pytest node ID. Cost-optimised: labels=[airouter], cost_efficiency≥9. Co-Authored-By: Claude Sonnet 4.6 --- workflows/write-code-simple.yaml | 61 ++++++++++++++++++++++++++++++++ 1 file changed, 61 insertions(+) create mode 100644 workflows/write-code-simple.yaml diff --git a/workflows/write-code-simple.yaml b/workflows/write-code-simple.yaml new file mode 100644 index 0000000..63ff87b --- /dev/null +++ b/workflows/write-code-simple.yaml @@ -0,0 +1,61 @@ +name: write-code-simple +version: 1 +description: > + Single-node airouter workflow for narrow implementation tasks: write just enough + code to make one specific test pass. Optimised for cost and speed — use for + single-requirement, single-file, or single-test work items. + + Hard cap: 3 concurrent airouter tasks. No web search available in container. + +params: + required: + task_description: + type: string + description: "What to implement — be specific about which test must pass" + project_id: + type: string + description: "Project identifier for task grouping" + repo_url: + type: string + description: "Git repo URL for the agent to clone" + agent_repo_url: + type: string + description: "Agent repo URL for branch-per-task persistence" + optional: + test_target: + type: string + default: "" + description: "Specific test file or node ID to run (e.g. tests/test_foo.py::test_bar). Leave blank if specified in task_description." + harness: + type: string + default: "code-airouter-repo/v1" + description: "Harness to use (default: code-airouter-repo/v1)" + space_id: + type: string + default: "default" + description: "Space identifier" + +nodes: + agent: + name: "agent" + prompt: | + {{ task_description }} + + {% if test_target %} + ## Target test + Your work is complete when this test passes: + ``` + python -m pytest {{ test_target }} -v + ``` + Do not modify the test file. Write only the source code needed to make it pass. + {% endif %} + harness: "{{ harness }}" + requirements: + labels: [airouter] + min_scores: + cost_efficiency: 9 + on_success: + - type: commit_pr + params: + repo_url: "{{ repo_url }}" + agent_repo_url: "{{ agent_repo_url }}"