Milestones and review in the new loop (M2.1, PR C)
CI / checks (push) Skipped
CI / checks (pull_request) Successful in 1m48s
CI / checks (push) Skipped
CI / checks (pull_request) Successful in 1m48s
A work item starts from a fresh workspace: fetch, set aside (never discard) leftover changes, branches and unpushed commits, a clean default branch, and a branch of its own (D3, #62). start_milestone cuts the milestone's branch; finish_milestone commits only the work, pushes and opens a PR that closes the issue, under an intent, adopting an open PR and treating a closed one as the operator's answer (D4). Between runs the loop watches each item's PR: operator comments and inline review notes (#69) reach the item, a merge or close hands back to the driver. A review fix is checked after it's pushed and goes out as a new PR if the PR merged first (D5). At boot an interrupted publish is settled against Gitea (L8). Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01PPQ14L3LikyefCMFBqEbKE
This commit is contained in:
1 parent
f84bb70839
commit
21744efac1
9 files changed
+1004
-10
No files matched your search
@@ -5,11 +5,11 @@ the item then waits on the operator."""
|
||||
from typing import Any
|
||||
|
||||
|
||||
def _tool(name: str, description: str, **params: str) -> dict[str, Any]:
|
||||
def _tool(tool: str, description: str, /, **params: str) -> dict[str, Any]:
|
||||
return {
|
||||
"type": "function",
|
||||
"function": {
|
||||
"name": name,
|
||||
"name": tool,
|
||||
"description": description,
|
||||
"parameters": {
|
||||
"type": "object",
|
||||
@@ -42,7 +42,22 @@ CLOSE_ITEM = _tool(
|
||||
summary="What was done, verified, and left open.",
|
||||
)
|
||||
|
||||
WAITING = frozenset({"restate", "ask_human", "close_item"})
|
||||
START_MILESTONE = _tool(
|
||||
"start_milestone",
|
||||
"Start a milestone before changing code: the harness cuts its branch. "
|
||||
"Never create or switch branches yourself.",
|
||||
name="A short name for the milestone.",
|
||||
)
|
||||
FINISH_MILESTONE = _tool(
|
||||
"finish_milestone",
|
||||
"The milestone's work is done and its tests pass: the harness commits "
|
||||
"the work, pushes it and opens a PR, or, after review comments, pushes "
|
||||
"your fix to the PR. Ends your turn; you continue when the PR is "
|
||||
"reviewed or merged.",
|
||||
summary="What the milestone did and how it was verified, for the PR.",
|
||||
)
|
||||
|
||||
WAITING = frozenset({"restate", "ask_human", "close_item", "finish_milestone"})
|
||||
|
||||
|
||||
def names(tools: list[dict[str, Any]]) -> set[str]:
|
||||
|
||||
Reference in new issue
Block a user