Skip to main content

Agent Wave: orchestrate parallel git worktree workflow for AI agents.

Project description

Agent Wave (agvv)

agvv is a lightweight task orchestrator for coding agents. It gives each task an isolated git worktree, runs the agent in a detached tmux session, and tracks lifecycle state in SQLite.

What It Does

  • Isolates task changes with git worktree (main + per-feature worktrees).
  • Runs agent sessions in background tmux so work continues after terminal disconnect.
  • Persists task state/events in SQLite (pending, running, done, failed, timed_out, cleaned).
  • Provides operational commands: task run/status/retry/cleanup and daemon run.

Requirements

  • Python >=3.10
  • git
  • tmux
  • A coding agent CLI in PATH:
    • codex (default)
    • claude (used when --agent claude or --agent claude_code)
  • uv (recommended for install/run)

Agent provider note:

  • --agent claude and --agent claude_code are equivalent inputs.
  • Both normalize to the internal provider claude_code and invoke the claude CLI binary.

Install

From PyPI:

uv tool install agent-wave
agvv --help

From source:

uv sync --dev
uv run agvv --help

Quick Start

1) Create task.md

Write the detailed coding requirement in Markdown.

2) Create task.json

Minimal valid spec:

{
  "project_name": "demo",
  "feature": "feat_demo",
  "task_doc": "./task.md"
}

task_doc or requirements must be present (at least one).

3) Start a task

For an existing local repository:

agvv task run --spec ./task.json --project-dir /path/to/repo

For a new managed project (under current directory):

agvv task run --spec ./task.json

Use Claude Code instead of Codex:

agvv task run --spec ./task.json --agent claude

--agent claude_code is also valid and behaves the same as --agent claude.

4) Monitor and reconcile state

agvv task status
agvv daemon run --once

Run daemon run --once repeatedly to move states forward (running -> done/timed_out).

5) Retry or cleanup

Retry:

agvv task retry --task-id <task_id>

Force restart an existing tmux session during retry:

agvv task retry --task-id <task_id> --force-restart

Cleanup worktree resources:

agvv task cleanup --task-id <task_id>

Force cleanup even with dirty worktree:

agvv task cleanup --task-id <task_id> --force

task.json Contract (CLI)

Required fields

  • project_name: ^[A-Za-z0-9_-]+$
  • feature: ^[A-Za-z0-9_-]+$, and must not be main or repo.git
  • One of:
    • task_doc (must end with .md)
    • requirements (non-empty string)

Common optional fields

  • repo: optional repository slug/identifier
  • from_branch: base branch for feature worktree (default: main)
  • session: custom tmux session name
  • ticket: optional ticket identifier (for task metadata)
  • constraints: list of extra constraints
  • timeout_minutes: session timeout in minutes (default: 240)
  • agent_extra_args: extra args passed to the agent command

Important runtime behavior

  • task_id is generated at runtime; user-provided task_id is ignored.
  • agent/agent_model in spec are reset by runtime; choose provider via CLI --agent.
  • base_dir in spec is overridden by runtime:
    • no --project-dir: current working directory
    • with --project-dir: parent directory of that project

CLI Summary

agvv task run --spec <path> [--db-path <path>] [--agent <codex|claude|claude_code>] [--agent-non-interactive|--agent-interactive] [--project-dir <path>]
agvv task status [--db-path <path>] [--task-id <id>] [--state <pending|running|done|failed|timed_out|cleaned>]
agvv task retry --task-id <id> [--db-path <path>] [--session <name>] [--force-restart]
agvv task cleanup --task-id <id> [--db-path <path>] [--force]
agvv daemon run [--db-path <path>] [--once] [--interval-seconds <n>] [--max-loops <n>] [--max-workers <n>]

Data and Layout

  • Default DB path: ~/.agvv/tasks.db
  • Override DB path with --db-path or environment variable AGVV_DB_PATH
  • Managed project layout:
<runtime_base>/<project_name>/
  repo.git/      # bare repository
  main/          # main worktree
  <feature>/     # feature worktree for one task

Notes

  • daemon run --once is required to reconcile background task state.
  • task cleanup removes the feature worktree and deletes the feature branch in managed repo.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

agent_wave-0.2.0.tar.gz (80.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

agent_wave-0.2.0-py3-none-any.whl (29.3 kB view details)

Uploaded Python 3

File details

Details for the file agent_wave-0.2.0.tar.gz.

File metadata

  • Download URL: agent_wave-0.2.0.tar.gz
  • Upload date:
  • Size: 80.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for agent_wave-0.2.0.tar.gz
Algorithm Hash digest
SHA256 0761dfebc809e19420d9e63d1bd90128c1a06fa6c574711322e4b922425386fd
MD5 73f9c0e3093e4e487e8fcf08c3527356
BLAKE2b-256 2e3bdcc06c187e510ee7e55552a106da174a075582ee6101e40eccd890fbbbdb

See more details on using hashes here.

Provenance

The following attestation bundles were made for agent_wave-0.2.0.tar.gz:

Publisher: publish.yml on niuyunda/agent-wave

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file agent_wave-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: agent_wave-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 29.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for agent_wave-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 758e4dd5ab37d1f991b50297c4a6ab0d741c395fb2927d46b985bd6c2a89a30f
MD5 f5d2d97ee8a9e61d50adad0dda80fa0e
BLAKE2b-256 7646548d0846b17e14a4fb41c1dfa8b1ed59acd662a94acd49f6bbcfb8787e37

See more details on using hashes here.

Provenance

The following attestation bundles were made for agent_wave-0.2.0-py3-none-any.whl:

Publisher: publish.yml on niuyunda/agent-wave

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page