Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
members = [
"crates/config",
"crates/github",
"crates/gardener",
"crates/store",
"crates/webhook",
"crates/worker",
Expand Down
5 changes: 5 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ flowchart LR
- Routes configured triggers to a familiar by bot username or label.
- Runs `coven-code --headless` with a tokenless session brief.
- Posts Check Run state, direct Cave session links, and draft PRs when the run produces commits.
- Runs the Branch Gardener on configured schedules or `garden` commands to prune dead branches and surface PRless work.

See [Architecture Diagrams](docs/architecture.md), [Design](DESIGN.md), [Hosted OpenCoven](HOSTED.md), [Familiar Contract](FAMILIAR-CONTRACT.md), [Roadmap](ROADMAP.md), and [Hosted vs self-hosted](docs/hosted-vs-self-hosted.md) for the operational plan.

Expand Down Expand Up @@ -107,6 +108,8 @@ Implemented lanes:
| Maintainer command in a comment (`@cody <command>`) | See the command table below |
| PR opened / synchronize / reopened / ready_for_review | Automatic hosted review when the `[review]` policy enables the lane (drafts skipped by default; newer pushes supersede queued reviews of the same PR) |
| Review label applied to a PR | Explicit per-PR review opt-in — works even with the automatic lane off, including drafts |
| Branch Gardener schedule | Enqueues adapter-side branch hygiene for configured installation/repository policies |
| Maintainer `garden` command | Runs Branch Gardener on demand for the current repository |

Planned lanes:

Expand Down Expand Up @@ -137,6 +140,7 @@ comments never re-trigger it.
| `deepen` | Clarification | Re-review with a wider lens (supporting files, tests) |
| `retry` | Re-run the fix lane | Re-run the review |
| `cancel` | Clarification (PR reviews only) | Cancel queued reviews for the PR (in-flight work finishes) |
| `garden` | Run Branch Gardener for the repository | Run Branch Gardener for the repository |
| `remember` / `forget` | Acknowledged; persistence lands with the memory governance contract (#6) | Same |
| `status` | Current task state for this thread | Same |

Expand All @@ -161,6 +165,7 @@ duplicate comments.
| Installation-scoped routing | Implemented | `[[installations]]` policy: per-installation familiar allow-lists, per-repo trigger-lane switches, fail-closed for unlisted installations; absent config keeps open self-hosted routing. |
| Usage metering + tier limits | Implemented | Per-installation `max_concurrent` (enforced at claim) and `max_tasks_per_day` (enforced at intake, recorded `ignored:quota_exceeded`); tenant-scoped `GET /api/github/usage` rollup by installation/repo/familiar with attempt runtime. |
| Reference demo of the operating loop | Implemented | Offline, self-verifying replay of the full loop with a real adapter binary — see [docs/demo.md](docs/demo.md). |
| Branch Gardener | Implemented | Scheduled and `garden` command runs classify branches, dry-run or prune dead/merged refs by policy, open draft PRs for PRless branches, and report through Cave-visible task state/status surfaces. |
| PR lifecycle review trigger | Implemented | Policy-gated auto-review on opened/synchronize/reopened/ready_for_review plus label opt-in; familiar-authored PRs are never auto-reviewed. |
| Push / commit review trigger | Partial | Events parsed and typed with fixtures; execution lane needs headless contract v3. |
| GitHub App installation tokens | Implemented | Mints installation access tokens from the App private key. |
Expand Down
7 changes: 3 additions & 4 deletions ROADMAP.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ Goal: support real hosted installations without losing task state or leaking ten
- Task audit log and terminal states. (terminal states #2; audit controls #12)
- Marker-backed GitHub status comments that are edited in place per task. (#13)
- Maintainer command router for status, stop, retry, explain, and approve. (#13)
- **Branch Gardener** — scheduled branch hygiene skill: classify branches, delete dead ones, open draft PRs for PRless work, report to Cave. See [`docs/branch-gardener.md`](docs/branch-gardener.md). (#14)
- **Branch Gardener** — scheduled branch hygiene skill: classify branches, delete dead ones, open draft PRs for PRless work, report to Cave. See [`docs/branch-gardener.md`](docs/branch-gardener.md). (#14) **Shipped.**

## Milestone 3: GitHub Correctness

Expand Down Expand Up @@ -146,8 +146,7 @@ shipped (see the [backlog DAG](docs/backlog-dag.md) for the full ledger). What
remains is sequenced by the hosted beta gates and go-to-market, not code
dependencies:

1. **#14 Branch Gardener** — the last scheduled-hygiene skill (in progress).
2. **#16 (GTM)** — landing page + beta waitlist (pricing #17 has shipped —
1. **#16 (GTM)** — landing page + beta waitlist (pricing #17 has shipped —
see [docs/pricing.md](docs/pricing.md)).
3. Harden toward the hosted beta gates in [HOSTED.md](HOSTED.md) and stand up
2. Harden toward the hosted beta gates in [HOSTED.md](HOSTED.md) and stand up
the hosted control plane on top of the now-durable, tenant-scoped adapter.
14 changes: 14 additions & 0 deletions config/example.toml
Original file line number Diff line number Diff line change
Expand Up @@ -122,3 +122,17 @@ trigger_labels = ["coven:fix", "coven:review"] # Labels that trigger this famil
# retention_days = 365 # forwarded to the runtime; also expires the adapter's memory audit
# [memory.repos."acme/billing"]
# enabled = true # per-repo opt-in

# ── Branch Gardener (issue #14) ──────────────────────────────────────────────
# Scheduled branch hygiene is off by default. Enable it per repository to scan
# branches, open draft PRs for PRless work, and optionally prune dead/merged refs.
# Scheduled runs require [[installations]] so the worker knows the installation id.
# [gardener]
# enabled = false
# autonomy = "propose" # propose (dry-run deletes) or prune-dead
# schedule = "0 4 * * *" # UTC daily; accepted form: M H * * *
# exclude = ["release/*", "hotfix/*"]
# draft_pr_label = "coven:garden"
# [gardener.repos."your-org/your-repo"]
# enabled = true
# autonomy = "propose"
1 change: 1 addition & 0 deletions crates/config/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,4 @@ license.workspace = true
anyhow.workspace = true
serde.workspace = true
toml.workspace = true
coven-github-gardener = { path = "../gardener" }
Loading
Loading