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
2 changes: 1 addition & 1 deletion .cursor-plugin/plugin.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,6 @@
"anti-slop"
],
"license": "MIT",
"version": "4.8.4",
"version": "4.8.9",
"repository": "https://github.com/agent-kit-startup/agent-kit"
}
2 changes: 1 addition & 1 deletion .cursor/agent-kit.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"schemaVersion": 1,
"version": "4.8.4",
"version": "4.8.9",
"protected": [
".cursor/HANDOFF.md",
".cursor/agents/test-suites.md",
Expand Down
2 changes: 1 addition & 1 deletion .cursor/commands/agent-kit-onboard.md
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,6 @@ When complete:
- `Next: /start-project` when the user wants to plan a deliverable.
- `Next: finish setup` when no deliverable should start now.

After essentials are ready, Mission Control is **optional** and **not** an essential readiness check. Consumer L0 installs the `/dashboard` command text but not `dashboard/**`. If the operator wants the panel, point them to an agent-kit checkout that includes `dashboard/start.mjs` (loopback `http://127.0.0.1:3333`). Do not block `/start-project` on Mission Control. Do not ask about skins or external review before essentials (Hard Stop 1).
After essentials are ready, Mission Control is **optional** and **not** an essential readiness check. Consumer L0 installs the `/dashboard` command text but not `dashboard/**`. If the operator wants the panel, `agent-kit dashboard` serves it from the installed CLI (4.8.2 onward); on older pins point them to an agent-kit checkout that includes `dashboard/start.mjs` (loopback `http://127.0.0.1:3333`). Do not block `/start-project` on Mission Control. Do not ask about skins or external review before essentials (Hard Stop 1).

Agent Personas remain available through later personalization or settings. External review is offered only when a plan reaches exhaustion.
1 change: 1 addition & 0 deletions .cursor/commands/backlog-add.md
Original file line number Diff line number Diff line change
Expand Up @@ -120,3 +120,4 @@ Vague-goal clarify and write confirmation **must** use Ask questions per `.curso

- ADR: `.cursor/memory/decisions/2026-07-26_backlog-crud-commands-contract.md`
- Disposition gate for `/start-project`: `.cursor/memory/decisions/2026-07-25_start-project-plan-disposition-gate.md`
- Cursor product-update gaps may route here via `/cursor-update-awareness` (Ask → `/backlog-add`)
64 changes: 64 additions & 0 deletions .cursor/commands/cursor-update-awareness.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
# Command: /cursor-update-awareness

## Goal

Run an **opt-in advisory** check for Cursor product updates (changelog + `docs/cursor-native-audit.md` inventory), then route **confirmed** gaps into the existing conveyor with HITL. Never apply kit/IDE changes. Never auto-create Field Reports or public issues.

**Detection source ADR:** `.cursor/memory/decisions/2026-08-01_cursor-update-detection-source.md` (changelog fetch primary; sessionStart = delivery; readiness = optional storage only).

## When to Use

- After a Cursor IDE upgrade or when `cursorUpdateCheck.enabled` sessionStart nudge mentions gaps
- When reviewing whether Agent Kit should adopt a new Cursor surface (hooks, MCP, skills, commands, SDK)
- Before `/backlog-add` or `/dogfood` for Cursor-integration work

## Hard stops

1. **Check ≠ apply.** CLI and this command only report. No silent rewrite of `.cursor/`, no Marketplace submit, no native-audit version-prose refresh (owned by parked `submit-cursor-marketplace`).
2. **No auto Field Reports** and no auto GitHub issues.
3. **Lane separation:** `/dogfood` stays factory vs consumer aware (ADR `2026-07-31_dogfood-factory-consumer-lanes.md`). Do not write consumer notes into factory `dogfood/` without an explicit operator bridge.
4. **HITL before enqueue.** Confirmed gaps go through Ask → `/backlog-add` or Ask → `/dogfood`, never silent backlog rows.
5. **Never `/git-prod`.**

## Check-only (CLI)

```bash
agent-kit cursor-awareness --check [--json] [--respect-prefs] [--stamp] [--offline]
```

- Fetches `https://cursor.com/changelog` (override via `cursorUpdateCheck.changelogUrl`) unless `--offline`.
- Diffs against `docs/cursor-native-audit.md` (open Action items, refresh staleness) and validates `docs/cursor-3-features.md` presence.
- Prefs in `.cursor/context/config.json` under `cursorUpdateCheck` (`enabled` default `false`, `intervalDays`, `lastSeenCursorVersion`). Distinct from kit `updateCheck`.
- `applyRecommended` and `fieldReportRecommended` are always `false`.

## What to Do

1. **Run the check** (prefer CLI JSON):
```bash
agent-kit cursor-awareness --check --json
```
Fallback: inventory-only `agent-kit cursor-awareness --check --offline --json`.

2. **Summarize gaps** for the operator (id, severity, evidence, suggestedRoute). If status is `current` or `skipped-*`, report and stop.

3. **Confirm routing via Ask questions** (chat numbered-list fallback). One question:

> Cursor awareness found N advisory gap(s). Route confirmed work?

Options (labels exact):
- `Enqueue via /backlog-add`
- `File /dogfood note`
- `Not now`

4. **Handlers:**
- `Enqueue via /backlog-add`: hand off to `/backlog-add` with a goal summarizing the confirmed gaps (Broad Intake + write Ask still apply). Do not activate or run the new plan.
- `File /dogfood note`: hand off to `/dogfood` with a hygiene-stripped topic/summary. Respect factory vs consumer lane.
- `Not now` / skipped: stop. Optionally offer enabling `cursorUpdateCheck.enabled` for future sessionStart nudges (do not mutate config without Ask).

5. **Out of scope:** refreshing Marketplace plugin version prose; kit self-release (`/update` / `updateCheck`); auto-remediation of product code.

## Related

- Kit consumer autoupdate (separate): `/update`, ADR `2026-07-27_consumer-autoupdate-check-opt-in.md`
- Dogfood ingest: `/dogfood`, ADR `2026-07-31_dogfood-ingest-contract.md`
- Triage residuals path: `/plan-review-triage` → Write residuals → `/backlog-add`
2 changes: 1 addition & 1 deletion .cursor/commands/dashboard.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ Start (or reuse) Mission Control for **this Cursor workspace only**, then open t

Local-dev only. Read-only. No HITL gate.

**Terminal counterpart:** `agent-kit dashboard` from the workspace cwd. After a CLI publish that ships Path C, the installed package includes `dashboard/start.mjs`. Fallbacks: env `MISSION_CONTROL_KIT_ROOT` / `AGENT_KIT_HOME`, sibling `../agent-kit`, or `node "$KIT_ROOT/dashboard/start.mjs"` with `MISSION_CONTROL_REPO_ROOT` set to this git root. Until Path C is on npm, do not assume `@dadado/agent-kit-cli@4.8.0` has the panel assets.
**Terminal counterpart:** `agent-kit dashboard` from the workspace cwd. The installed package includes `dashboard/start.mjs` from 4.8.2 onward. Fallbacks: env `MISSION_CONTROL_KIT_ROOT` / `AGENT_KIT_HOME`, sibling `../agent-kit`, or `node "$KIT_ROOT/dashboard/start.mjs"` with `MISSION_CONTROL_REPO_ROOT` set to this git root. On 4.8.0 or an older pin the panel assets are absent.

## When to Use

Expand Down
138 changes: 138 additions & 0 deletions .cursor/commands/dogfood.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,138 @@
# Command: /dogfood

## Goal

File a private dogfood note from the current chat or explicit arguments into the local inbox. Factory (`agent-kit-dev`) writes to `dogfood/`; consumer projects write to `.cursor/dogfood/`. Never syncs upstream; never creates a public issue automatically.

## When to Use

- You hit Agent Kit friction, a bug, or a surprising behavior and want it tracked for internal analysis.
- You want a dated record of a session pattern without turning it into a public issue or PR.
- A memory WRITE is not yet warranted; the note is raw material for later triage.

## Usage

```
/dogfood <topic> [one-line summary]
```

Examples:
- `/dogfood plan-handoff context lost after long run`
- `/dogfood update-refresh personalization dropped`
- `/dogfood stale-pack-id install failed on pack migration`

Without arguments, summarize the current chat turn into the topic and body.

## Hard stops

1. **Detect lane before writing.**
- **Factory lane** — this checkout is the canonical `agent-kit-dev` repository (`origin` remote contains `agent-kit-dev`, or `dogfood/` already exists at repo root). Write to `dogfood/cursor_<topic>_<date>.md` and update `dogfood/README.md` Unprocessed index.
- **Consumer lane** — any other project with an Agent Kit install (`.cursor/agent-kit.json` exists). Write to `.cursor/dogfood/cursor_<topic>_<date>.md` and a local index. Do **not** track the folder in git; it should already be gitignored by the base install.
- **Unknown lane** — stop and ask the operator which lane to use.
2. **Hygiene strip (mandatory).** Remove before writing:
- Consumer workspace names, project names, domain names, or external product names.
- People's names, Slack channels, client IDs, or organization names.
- Chat-transient phrasing ("as I mentioned", "dear user", "conforme falamos").
- Any value that looks like a secret, token, or credential.
3. **Session origin ≠ product use case.** The note describes an Agent Kit system pattern, not a specific consumer's business process. See `2026-07-17_session-origin-not-product-usecase.md`.
4. **No public issue or PR without explicit HITL.** If the operator wants a public issue, use `/dogfood` → local save first, then offer a separate `/contribute` or `gh issue create` step after the hygiene strip is verified.
5. **No Field Report cards.** Routine dogfood filing does not create or update Field Report cadence.

## What to Do

### Step 1: Determine lane

Check in order:
1. `git remote get-url origin` (or `git config remote.origin.url`) contains `agent-kit-dev` → factory lane.
2. A `dogfood/` directory exists at the repo root and contains this README → factory lane.
3. `.cursor/agent-kit.json` exists and the repo is not `agent-kit-dev` → consumer lane.
4. Neither → stop and ask: "This doesn't look like the factory or a migrated consumer. Save to `dogfood/` (factory) or `.cursor/dogfood/` (consumer)?"

### Step 2: Build filename and body

1. Normalize the topic: lowercase, spaces/hyphens/underscores to underscores, strip punctuation and trailing date. Keep it short (≤ 40 chars).
2. Date suffix: `YYYYMMDD` from today (`YYYY_MM_DD` for readability).
3. Filename: `cursor_<topic>_<date>.md`.
4. Body template:
```markdown
# Dogfood: <topic>

- **Date:** <YYYY-MM-DD>
- **Lane:** factory | consumer
- **Source:** chat summary | explicit /dogfood args

## Observation

<hygiene-stripped description of the friction>

## Impact

<how this affects the Agent Kit system or operator experience>

## Triage (initial)

- Fix now / Park / Ignore
- **Tags:** <lowercase comma-separated keywords>
```
5. Run the hygiene strip. If you cannot strip enough context to make it generic, file the note but flag it as `needs-anonymization` in the body and stop before any memory WRITE or public issue.

### Step 3: Write and index

**Factory lane:**
- Write `dogfood/cursor_<topic>_<date>.md`.
- Append the file to the `### Unprocessed Files` section of `dogfood/README.md` with a one-line summary and the capture date.

**Consumer lane:**
- Ensure `.cursor/dogfood/` exists (create if missing).
- Write `.cursor/dogfood/cursor_<topic>_<date>.md`.
- Write or append to `.cursor/dogfood/README.md` with the same Unprocessed/Processed structure as the factory README.
- The folder is local-only; do not `git add` it.

### Step 4: Cross-repo bridge (optional, operator-initiated only)

A consumer project does **not** write directly into the factory repo. If the operator wants a note from `.cursor/dogfood/` to reach the canonical `agent-kit-dev` inbox, the supported path is a manual bridge:

1. **Configure factory root** (optional). In `.cursor/context/config.json` add:
```json
{
"dogfood": {
"factoryRoot": "/absolute/path/to/agent-kit-dev"
}
}
```
The path is advisory only; the command never writes there automatically.
2. **Operator copies the file** with `cp` or the IDE file explorer from `.cursor/dogfood/cursor_<topic>_<date>.md` to `dogfood/cursor_<topic>_<date>.md` in the factory checkout.
3. **Re-apply hygiene** in the factory context before committing. The file must be re-reviewed because the factory README index and triage cycle are separate from the consumer inbox.
4. **No bridge for routine friction.** Most consumer notes should stay in `.cursor/dogfood/` as local project memory. Only copy patterns that are clearly Agent Kit system gaps.

If `dogfood.factoryRoot` is absent, omit the bridge step and file locally. Never invent a factory path or guess from repo history.

### Step 5: Optional public issue (HITL only)

After filing locally, you may offer a public GitHub issue **only if**:
1. The pattern is an upstream Agent Kit gap, not a project-specific workaround.
2. The hygiene strip has already been applied (no consumer identities, no session-origin detail).
3. The operator explicitly agrees via Ask questions with options:
- `Create public issue`
- `Keep local only`

If the operator chooses `Create public issue`:
- Use `gh issue create` against the public `agent-kit-startup/agent-kit` repository.
- Title format: `[Dogfood] <topic>`.
- Body: a concise, anonymized summary plus the local dogfood file path for reference.
- Do **not** paste the full local dogfood file if it contains any non-public detail.
- Never create a Field Report card or cadence warning for this step.

If the operator chooses `Keep local only`, stop. The local file is the record.

### Step 6: Respond

> Dogfood filed: `dogfood/cursor_<topic>_<date>.md` (factory) or `.cursor/dogfood/cursor_<topic>_<date>.md` (consumer). Next: analyze → memory WRITE → triage, or ask for a public issue if the pattern is upstream-relevant.

## Related

- `dogfood/README.md` — factory inbox and ingest ritual
- `.cursor/memory/decisions/2026-07-31_dogfood-factory-consumer-lanes.md` — lane decision
- `.cursor/memory/decisions/2026-07-31_dogfood-ingest-contract.md` — ingest contract
- `.cursor/memory/decisions/2026-07-17_session-origin-not-product-usecase.md` — hygiene
- Cursor product-update gaps may route here via `/cursor-update-awareness` (Ask → `/dogfood`)
2 changes: 1 addition & 1 deletion .cursor/commands/git-staging.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ Follow the **git staging** routine to bring local changes to the pre-production

1. **Read** the "Prompt: git staging" section in `autogit/gitupdate.md` (when it exists).
2. **Staging hygiene (monitors):** if `git status` shows untracked or unrelated dirty `.cursor/memory/plan-monitor-*.md`, **warn** before commit. Stage memory/monitor files **add-by-name only**; never broad `git add` of `.cursor/memory/` WIP into a product commit (ADR `decisions/2026-07-27_plan-monitor-consumer-awareness.md`, external-review staging hygiene).
3. **Lint evidence (required when code/format paths change):** before claiming staging-ready, **run** the repo formatter/linter on touched files and **record the command + result** (pass/fail) in the worker summary or tick notes. Writing `Staging ready: yes` or the contract string alone is **not** evidence. Pure markdown / docs-only with no applicable linter: state `none applicable`. Same gate as `/run-plan` Staging-ready lint gate.
3. **Lint evidence (required when code/format paths change):** before claiming staging-ready, **run** the repo formatter/linter on touched files and **record the command + result** (pass/fail) in the worker summary or tick notes. Writing `Staging ready: yes` or the contract string alone is **not** evidence. Pure markdown / docs-only with no applicable linter: state `none applicable`. Same gate as `/run-plan` Staging-ready lint gate. **Dashboard CSS/HTML only** (`dashboard/dashboard.html` and similar, outside Biome scope): record `Tests: none applicable (dashboard-CSS); covered by plugin-ux-validation` when the UX suite pins the change (ADR `decisions/2026-07-29_dashboard-css-lint-evidence-convention.md`); do not claim Biome covered the HTML.
4. Run in order: validation (not on `main`), CHANGELOG (`[Unreleased]`), checkout staging, pull, working branch, Conventional Commits, push, MR/PR (**always `--base staging` / target `staging`**), merge, cleanup.
5. **Never** commit directly to `main`.
6. On completion: update `.cursor/HANDOFF.md` (phase in staging); memory-loop WRITE if it applies.
Expand Down
6 changes: 5 additions & 1 deletion .cursor/commands/plan-external-review.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,8 @@ If any are missing: stop. Do **not** claim a review ran. Tell the user to run `a
### What "operator-visible" means (smoke notes)

- **Autonomous success:** chat arm **must** use `--force --autonomous --wait-monitor`. The launcher prefers a background/inspectable PTY (no OS Terminal focus by default; `--focus-terminal` / `AGENT_KIT_AUDIT_FOCUS_TERMINAL=1` restores activate), then polls until a **fresh** monitor exists (`mtime >= arm epoch` or content sentinel). Exit `0` = fresh ready; `3` = timeout; `4` = soft-fail while waiting. Spawn-only exit 0 without wait is **not** review done. **Chat continuation:** AwaitShell until `0|3|4`; on `0` run `/plan-review-triage` Ask in the same session. Do **not** stop at Final HANDOFF "after monitor lands" or require typing `done`. ADR: `decisions/2026-07-27_audits-wait-freshness-enforce.md`.
- **Autonomous soft-fail:** missing `claude` → tip + exit `4` when `--wait-monitor` was requested (Field Report owed). Background spawn unavailable → falls back to `--paste-only` UX with an honest "NOT running yet" banner. Soft-fail does **not** invent a monitor or run triage as if review completed.
- **Autonomous soft-fail:** missing `claude` → tip + exit `4` when `--wait-monitor` was requested (Field Report owed). Background spawn unavailable → falls back to `--paste-only` UX with an honest "NOT running yet" banner. A **silent PTY** (spawn succeeded, no scrollback within the progress-gate grace window) is reported as a failed launch: the launcher disposes the session it just spawned, prints the paste fallback, and soft-fails instead of burning the wait budget. A **session-cap refusal** (detached `agent-kit-audit-*` sessions at the cap) never spawns at all. Soft-fail does **not** invent a monitor or run triage as if review completed.
- **Exit 3 is timeout-only:** it means the freshness gate was not satisfied inside the budget, never that the review finished. A monitor that appears later, including one written by a different or later arm, does **not** convert a `3` into success. Leave the target Field Report **owed** and re-arm. ADR: `decisions/2026-07-30_audits-pty-progress-gate-zombie-policy.md`.
- **Paste-only:** clipboard + printed interactive one-liner; review starts only after the operator pastes into their Cursor Terminal. After paste (Claude running), the session still waits for the monitor file then continues into triage Ask when possible.
- **`--dry-run`:** resolves mode/plan and prints `background-cmd` / `paste-cmd` / `focus-terminal` without spawning Claude (useful for smoke).

Expand Down Expand Up @@ -92,6 +93,8 @@ Script behavior (ADR):
- `mode: "autonomous"` (non-headless) → background/inspectable PTY auto-launch; soft-fallback to paste-only
- Missing `mode` key → paste-compatible default (`--print` when no flag; chat should pass `--paste-only` or set autonomous)
- Interactive and headless launches pass Claude CLI `--permission-mode auto`
- Post-spawn progress gate: samples PTY scrollback before the monitor wait; silent PTY → early abort (`AGENT_KIT_AUDIT_PROGRESS_TIMEOUT`, default 60s, `0` disables); channels without a scrollback API stay advisory
- Session pressure: warns at `AGENT_KIT_AUDIT_SESSION_WARN` detached `agent-kit-audit-*` sessions, refuses to spawn at `AGENT_KIT_AUDIT_SESSION_CAP`; reap is opt-in (`--reap-audit-sessions`), detached-only, past `AGENT_KIT_AUDIT_REAP_MIN_AGE`
- `--paste-only` copies the interactive one-liner via `pbcopy` / `xclip` / `xsel` / `clip.exe` when available
- Never `/git-prod`; never broad `git add`
- Does **not** register a Cursor native `stop` hook
Expand Down Expand Up @@ -120,6 +123,7 @@ After a successful autonomous arm in chat, **do not** hand off with "run `/plan-
- ADR: `.cursor/memory/decisions/2026-07-20_optional-claude-code-plan-review.md`
- Audits contract: `.cursor/memory/decisions/2026-07-27_audits-autonomous-plan-review-contract.md`
- Post-spawn watch + continue: `.cursor/memory/decisions/2026-07-27_audits-post-spawn-monitor-watch-continue.md`
- PTY progress gate, session cap, exit 3 honesty: `.cursor/memory/decisions/2026-07-30_audits-pty-progress-gate-zombie-policy.md`
- Related: `.cursor/memory/decisions/2026-07-19_stop-hook-no-hitl-interference.md` (no stop-hook auto agent)
- Prompt: `.cursor/context/templates/plan-external-review-prompt.md`
- Monitor template: `.cursor/context/templates/plan-monitor.md`
Expand Down
Loading