Turn the open issue backlog into a proposed two-week sprint plan with estimates, a dependency ordering, and an explicit cut line, written as a document for the team to edit.
/goal SPRINT-PLAN.md contains a proposed 2-week plan — read all open issues labeled `ready`, estimate each as S/M/L based on the code it touches, order them by dependency and value, draw a cut line at a realistic capacity, and list what falls below it with reasons; make no changes to the issues themselves; stop after 6 turns
/loop clean up marketing newsletters in my inbox with the ConnectMyEmail MCP — move read promotional newsletters older than 30 days to Trash, only clearly promotional senders, never receipts, security, or personal mail and never permanently deleting. Stop after 500 messages or when none remain, verify each sender was a bulk list before moving it, and ask before trashing anything you're unsure about.
Triage an Outlook inbox across Focused and Other — labelling new mail and moving only newsletters and spam to Deleted Items, protecting receipts, security, and human messages.
/loop triage my Outlook inbox with the ConnectMyEmail MCP — read each unread message across Focused and Other, label it (newsletter, receipt, security, human, spam), and move only clearly promotional newsletters and spam to Deleted Items, never permanently deleting and never touching receipts, security, or human mail. Stop after 200 messages or when no untriaged unread remain, verify each pass by re-counting untriaged unread, and ask before archiving anything ambiguous.
/loop scan my inbox with the ConnectMyEmail MCP for receipts, invoices, and statements and file each under a 'Receipts' label — read-only on everything else and never deleting anything. Stop after 200 messages or when no unlabeled receipts remain, verify each matched message was labeled, and ask before creating any new label.
/schedule every Friday at 5pm, run an inbox-zero pass on my email with the ConnectMyEmail MCP — archive read newsletters, move spam to Trash, and surface anything that needs a reply, never permanently deleting mail and never touching unread human messages. Stop after 300 messages per run, verify the unread count dropped, and ask before archiving anything ambiguous.
/loop find marketing newsletters I never open in my inbox with the ConnectMyEmail MCP, and for each use the List-Unsubscribe header to unsubscribe — only bulk mailing lists, never transactional, receipt, or security senders. Stop after 50 unsubscribes or when no one-click-unsubscribe candidates remain, verify each unsubscribe returned success and keep a log, and ask before unsubscribing from anything that looks like an account or billing service.
Point an agent at your Gmail inbox to read, label, and file new mail — moving only obvious newsletters and spam to Trash while protecting receipts, security, and human messages.
/loop triage my Gmail inbox with the ConnectMyEmail MCP — read each unread message, label it (newsletter, receipt, security, human, spam), and move only clearly promotional newsletters and spam to Trash, never permanently deleting anything and never touching receipts, security, or human mail. Stop after 200 messages or when no untriaged unread remain, verify each pass by re-counting untriaged unread, and ask before archiving anything ambiguous.
/loop run the repo's static analyzer (semgrep, CodeQL, or whatever is already configured) with the security ruleset; take ONE finding — highest severity first — and fix it minimally, then re-run the analyzer to verify the finding is gone and run the test suite. Never suppress or downgrade a rule to make a finding disappear; anything that needs a design change gets flagged for human review instead. Continue until the analyzer reports zero findings at high severity — stop after 10 turns and propose the fixes as one PR.
Pick the oldest untriaged issue, validate it against the current build, then label it, close if obsolete, or document repro steps—one per turn until the queue empties or 12 iterations pass.
/loop pick the single oldest untriaged issue in the tracker; reproduce or validate it against the current build, then either label it (area, priority, effort), close it with a polite explanation if it is obsolete, or write the missing repro steps. One issue per iteration, never close anything that still reproduces, and propose bulk closes for maintainer review instead of executing them. Continue until the untriaged queue hits zero — stop after 12 turns and report the triaged/closed/escalated counts.
/schedule every Friday at 2pm, draft release notes from the PRs merged since the last draft: group changes into features, fixes, and docs, write one plain-English line per change with the PR link, and save to releases/DRAFT.md. Draft only — a human edits and publishes; never post or send anywhere. Verify every PR link resolves and every merged PR since the last run is covered before saving. Stop after 1 pass per run.
Email is the missing tool in your harness. ConnectMyEmail gives Claude Code and Codex a clean MCP into Gmail, Outlook, iCloud and IMAP — triage, drafts, follow-ups, on a loop.
Query the catalog for unindexed foreign keys, create a migration per missing index, and verify each with a full test run until all FKs are covered or 6 turns complete.
/goal every foreign key in the schema has a covering index — query the catalog (pg_catalog or information_schema) to list FKs with no matching index, add one migration per missing index, and re-run the catalog check until it returns zero rows. After each index, apply the migration on a scratch database and run the full test suite to verify nothing regresses; stop after 6 turns. Only add indexes — never change constraints or table definitions — and propose the final migration set as a PR for review.
/schedule every night at 3am, dump the live database schema (`pg_dump --schema-only`) and diff it against the schema produced by applying all committed migrations to a fresh scratch database. Verify the scratch build reports `migrate status` clean before comparing. Any drift — columns, indexes, or constraints present in prod but missing from migrations, or vice versa — gets an issue filed with the exact diff attached and a proposed corrective migration for human review. Read-only against production; never modify the live schema. Stop after 1 pass per run.
Pull the slowest PostgreSQL statement, optimize its query plan with an index or rewrite, verify the improvement, and repeat until all captured queries run under 100ms or hit eight iterations.
/loop pull the 10 slowest statements from pg_stat_statements, take the single worst one, and EXPLAIN ANALYZE it. Fix only that query this iteration — add the missing index, rewrite the predicate, or batch the N+1 — then re-run EXPLAIN ANALYZE to verify the plan improved and run the test suite to prove behavior is unchanged. Only touch indexes and query shape, never application behavior. Continue until every statement in the captured set runs under its 100ms budget — stop after 8 turns, then propose the accumulated index changes as a single PR for review and report any remaining offenders.
Profile the CI pipeline and cut wall-clock time under a target by improving caching, splitting slow jobs, and removing redundant steps, verifying every run stays green.
/goal the CI pipeline completes in under 10 minutes on a typical PR — analyze the slowest recent runs with `gh run view`, apply one speedup per turn (better dependency caching, job parallelization, removing duplicated steps, trimming artifacts), push to a test branch, and confirm the workflow still passes; stop at the target or after 10 turns
Move the project to the current Node LTS across .nvmrc, CI config, Dockerfiles, and engines, fixing deprecations until everything is green on the new runtime.
/goal the project runs on the current Node LTS — update .nvmrc, the engines field, CI workflow files, and any Dockerfile base images to the LTS version, then run install, build, lint, and the full test suite on it, fixing deprecation warnings and breakages one at a time; stop when all are green or after 15 turns
Drive a suspected memory leak to ground: reproduce growth under a repeated workload, capture heap snapshots, and fix the retention until memory stays flat.
/goal heap usage stays flat (within 5%) across 500 repetitions of the failing workload in the leak-repro script — capture heap snapshots before and after, identify what is being retained and by which reference chain, fix the leak, and re-run the repro to confirm; stop after 10 turns
Rewrite the commit messages on your feature branch to conventional-commit format with meaningful bodies before opening the PR, leaving the code untouched.
/goal every commit on this branch (ahead of main) has a conventional-commit subject under 72 characters and a body explaining why — use interactive rebase to reword only (no code changes, no commits dropped), verify with `git log main..HEAD`, and confirm the diff against the original branch tip is empty; stop after 5 turns
/schedule every Friday at 3pm, verify the README: run each documented setup and usage command in a clean checkout, check that referenced files and scripts exist, and open a PR correcting anything that fails or has drifted, with a note explaining each fix
/schedule every Monday at 8am, run `npm audit`, open a single PR applying only non-breaking fixes with tests passing, and file one issue per remaining high or critical advisory with its CVE link and affected paths
/goal CHANGELOG.md has a complete entry for the next release — read every commit since the last version tag, group changes into Added, Changed, Fixed, and Removed, write user-facing descriptions (not commit messages), link PR numbers, and flag anything that looks like a breaking change; stop after 5 turns
Email is the missing tool in your harness. ConnectMyEmail gives Claude Code and Codex a clean MCP into Gmail, Outlook, iCloud and IMAP — triage, drafts, follow-ups, on a loop.
/goal `gitleaks detect --no-git` reports zero findings — for each finding, tell me whether it looks like a real credential (flag it for rotation and replace it with an env var lookup) or a false positive (add it to the baseline with a comment); never print the secret value itself; stop after 8 turns
/goal every path in openapi.yaml has a contract test asserting its status codes and response schema — add tests for one untested endpoint per turn, run the suite, and fix either the spec or the handler when they disagree (tell me which you chose); stop when all paths are covered or after 15 turns
Iteratively shrink a Docker image under a size target using multi-stage builds, smaller base images, and layer cleanup, verifying the container still boots each turn.
/goal `docker images` shows the app image under 300 MB — apply one slimming change per turn (multi-stage build, slimmer base image, prune build deps, consolidate layers), rebuild, and verify the container starts and passes its healthcheck before the next change; stop at the target or after 8 turns
Shrink the production JavaScript bundle under a hard budget by attacking the largest modules with code-splitting, lighter imports, and dead-weight removal.
/goal the main production bundle is under 250 KB gzipped — run the build with the bundle analyzer, address the single largest contributor each turn (code-split it, replace it with a lighter import, or drop it), and confirm the build and tests stay green; stop at the budget or after 10 turns
Instrument the test suite with query logging, find endpoints issuing N+1 queries, and fix them with eager loading or batching until the hot paths are clean.
/goal no endpoint in the integration test suite issues more than 10 SQL queries per request — enable query logging in the test environment, find the worst N+1 offender, fix it with eager loading or a batched query, verify the count dropped and tests still pass, then move to the next; stop after 12 turns
/goal `npm outdated` lists no minor or patch updates — upgrade exactly one package per turn, run tests, lint, and build after each, commit if green, and pin the previous version with a note in UPGRADE-BLOCKERS.md if it fails; stop after 20 turns
/goal `npx knip` reports no unused files or exports — remove one cluster of dead code at a time, run the full test suite and typecheck after each removal, and revert any deletion that breaks them; stop after 15 turns
/loop 30m find the oldest TODO or FIXME comment in the codebase, and either implement it (with a test) if it takes under 50 changed lines, or open a GitHub issue capturing its context and delete the comment; report which TODO you handled; stop when none remain
/loop 15m for each branch listed in .rebase-train (in order), rebase it onto its updated parent, resolve only trivial conflicts (imports, formatting, lockfiles), run the test suite, and push with `--force-with-lease`; if a conflict touches logic, stop that branch and leave a summary comment on its PR instead