diff options
Diffstat (limited to 'Omni/Agent/DESIGN.md')
| -rw-r--r-- | Omni/Agent/DESIGN.md | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/Omni/Agent/DESIGN.md b/Omni/Agent/DESIGN.md index a53c802..f976b03 100644 --- a/Omni/Agent/DESIGN.md +++ b/Omni/Agent/DESIGN.md @@ -77,6 +77,7 @@ The Haskell implementation should replicate the logic of `start-worker.sh` but w - **Two-line Status**: The CLI should maintain two reserved lines at the bottom (or top) of the output for each worker: - **Line 1 (Meta)**: `[Worker: omni-worker-1] Task: t-123 | Files: 3 | Credits: $0.45 | Time: 05:23` - **Line 2 (Activity)**: `[14:05:22] 🤖 Thinking...` (updates in place) + - **Task Details**: When claiming a task, print the full task description/details to the log/console so the user can see what is being worked on without looking it up. - **Completion**: When a task finishes, print a summary line (e.g., `[✓] Task t-123 completed in 12m 30s`) and a hard line break before starting the next loop. - **History**: Previous log lines (tool outputs, thoughts) scroll up above these two status lines. @@ -84,12 +85,15 @@ The Haskell implementation should replicate the logic of `start-worker.sh` but w - Iterate over `.tasks/workers/` or `git worktree list`. - For each worker, extract `.tasks/tasks.jsonl` via `git show`. - Run `Task.import`. +- **Squashing**: If the previous commit on the target branch (live) was a harvest commit, use `git commit --amend` to consolidate updates and reduce commit noise. ### 4.5 Git Robustness (Learnings) +- **Identity**: Configure `git config user.name "Omni Worker"` and `user.email` in the worktree to clearly distinguish worker commits from human commits. - **Force Checkout**: The worker must use `git checkout -f` (or equivalent) when switching to task branches to ensure untracked files (like `.tasks/counters.jsonl`) don't block the switch. - **Base Branch Logic**: - If the task depends on another task that is *not* yet in `live` (e.g., in `Review`), the worker should branch off the dependency's branch (`task/<dep-id>`). - - Otherwise, branch off `live` (via the worker's base branch). + - Otherwise, fetch and branch off `origin/live` directly. Do NOT use the local worker branch (`omni-worker-N`) as the base, as it may contain temporary sync commits that shouldn't be merged. +- **Commit Hygiene**: Bundle the task status update (marking as 'Review') *inside* the feature implementation commit. This keeps the history clean (one commit per feature) and avoids separate "sync" commits for status changes. - **Clean State**: The worker should ensure the workspace is clean (no uncommitted changes) before starting a new loop iteration. - **Rebase Safety**: Always check the exit code of `git rebase`. If it fails (conflicts), abort immediately (`git rebase --abort`) to avoid leaving the repo in a broken interactive rebase state. - **Status Verification**: Verify that task status updates actually succeed. Check `task ready` output against `live` state to prevent "zombie" tasks (completed in live but stuck in local loop) from being re-claimed. |
