diff options
Diffstat (limited to 'docs/superpowers/specs')
| -rw-r--r-- | docs/superpowers/specs/2026-10-05-brainstorming-rebuild-design.md | 165 | ||||
| -rw-r--r-- | docs/superpowers/specs/2026-10-06-antigravity-marketplace-design.md | 181 |
2 files changed, 346 insertions, 0 deletions
diff --git a/docs/superpowers/specs/2026-10-05-brainstorming-rebuild-design.md b/docs/superpowers/specs/2026-10-05-brainstorming-rebuild-design.md new file mode 100644 index 0000000..527a298 --- /dev/null +++ b/docs/superpowers/specs/2026-10-05-brainstorming-rebuild-design.md @@ -0,0 +1,165 @@ +# Brainstorming rebuild: intent + +## Why this exists + +Coding agents are very good at building. They build what they believe the +human wants, and they rarely ask enough or look around enough before they +start. The brainstorming skill exists to close that gap: draw the human's +real intent out of them, including the parts they haven't worked out yet, +before anything gets built. + +The original superpowers prompt did this well in about forty words: "I've +got an idea in my head. I'd like you to ask me lots of questions about it. +As you think you understand what I really want, describe it to me in +chunks of about 200-300 words. Once we're dialed in, write out an informal +spec." The current skill has grown to about 2,600 words, almost all of it +about routing (spike / bounded / architectural), approval gates, and the +spec-to-plan handoff. Intent got squeezed into one paragraph whose default +move is "ask one focused question about purpose", which doesn't work on +people. + +This is a rewrite from scratch, not an edit. + +## Goals + +- The agent understands the *why* behind anything non-trivial, because an + agent that knows the why makes the hundred unstated decisions well. +- The human ends up thinking through what they actually want. Good + questions help them flesh out an idea they haven't finished forming. +- Works for any domain: software, a talk, a renovation, a small business. +- Ends with a document a talented builder in that domain could plan from + without going back to the human. + +## How a session should feel + +**Start with a private check.** The agent asks itself: what do I actually +know about what they want, and why? If the answer is "nearly everything" +("make the icon cornflower blue"), it confirms and moves on. If anything +non-trivial is missing, it starts asking. + +**Ask, one question at a time.** Plain language by default, pitched just a +little above the human's level. Questions should help the human think, not +quiz them. + +- Get them describing first. Open questions beat menus because menus + garden-path people toward the agent's assumptions. +- Offer a menu only when they're struggling. +- If they say "just guess" or "what do you think", always propose. +- Ground questions in real moments ("walk me through the last time...") + and concrete tradeoffs ("if it could only do one of these well..."). +- Ask about prior art and current state: what exists elsewhere, what + exists now. +- Ask which parts of the *how* they want to decide, and which they'd + rather hand to the builder. + +The ground to cover, loosely in order: what kind of thing this is, what +makes it special, goals, non-goals, anti-goals, the details they care +about, and what they want to delegate. These are territory, not a script. +The agent never reads them out as literal questions. + +**Offer recon.** Once there's some grounding, the agent offers to go look: +the codebase or project, the human's own files and data, or the web. The +human decides whether it goes. + +**Show, don't tell, once things get concrete.** Use the visual companion +for diagrams, mockups, and throwaway prototypes where seeing beats reading. + +**Spike to feel things out.** Agentic development is waterfall, but very, +very fast. A quick throwaway build is often the cheapest way to find out +what the human wants or whether something works, and the agent should +offer one when it would help. When the human just wants to spike, the +agent gets out of the way. Spikes have no tests or minimal ones, aren't +bulletproof, and don't go through the full plan, implementation, and +review process. What a spike teaches feeds back into the conversation. + +**Think wide internally.** Before proposing anything, the agent generates +several ideas and discards the weak ones. It shows the human the comparison +only when that helps them decide. + +**Play it back.** Once the agent thinks it understands, it describes its +understanding in chunks of roughly 200-300 words and adjusts after each. + +## What it produces + +A plain written document covering: + +- intent and the why +- goals, non-goals, anti-goals +- constraints +- the parts of the how the human cares about, as they decided them +- what's explicitly left to the builder + +**Done test:** before the human reviews it, a fresh subagent playing a +talented builder in the domain reads the document and lists what it would +still need to ask. Those questions go back to the human. The document is +done when the builder has nothing important left to ask. + +**Sizing the work.** Once intent is clear, the agent sorts the work into +one of three sizes, says which out loud, and lets the human override: + +- **A quick, clear task.** Intent was clear from the start. Confirm and do it. +- **A small change.** The full description lives in chat. No document file. +- **A project with a written design.** The full description is the + document above, followed by a full plan (for software, the writing-plans + skill). + +This is where the old spike / bounded / architectural choice lives now: +after intent, not before it, with plain names. + +**Approval.** Whatever the size, the human approves the full description +before anything gets built: in chat for a small change, by reading the +document for a project. + +**Opting out.** Early in the session, the agent mentions once that if the +human doesn't want to go through this process, they can just say so. + +## Non-goals + +- Designing architecture the human didn't ask to decide. The doc records + the how the human cares about; the rest belongs to the builder. +- Being software-specific. +- Ceremony for trivial requests. + +## Anti-goals + +- Interrogation: a checklist of questions read at the human. +- Garden-pathing: steering the human into the agent's preferred idea with + leading menus. +- "What are you actually trying to do?" style questions that ask the human + to do the agent's thinking. +- Small asks inflating into multi-phase projects. +- Building before the human agrees with the playback. + +## Decisions + +- The skill keeps the name `brainstorming`. Other skills and the README + point at it. +- The visual companion and its server scripts stay as they are. +- `spec-document-reviewer-prompt.md` is replaced by the builder-check prompt. +- The agent screens the builder check's questions before bringing them to + the human: it answers what it can from context and drops questions about + delegated details. Without a subagent tool, it runs the check itself. +- A short hard gate stays: nothing gets built until the human approves the + full description. One exception: a spike the human said yes to. It stays + labeled throwaway. Keeping what it produced is a new request and goes + through the gate. +- The builder check runs only on the written document. Small changes stay + in chat. +- The trigger description keeps the strong "use before any creative work" + wording. The opening check keeps trivial asks cheap. +- The todo-list example from the old skill goes. The evals that encode the + old routing (`brainstorming-todo-purpose-discovery`, + `brainstorming-todo-shared-intent`) get rewritten to match. +- Software projects keep `docs/superpowers/specs/YYYY-MM-DD-<topic>-design.md` + as the default location for the document. + +## Left to the builder + +- Section structure and wording of the skill. +- Exact prompts for the builder check. +- Where non-software documents get saved, absent a human preference. + +## Will be tuned after first use + +Jesse expects to tune the skill after real sessions. Ship something small +and sharp rather than complete. diff --git a/docs/superpowers/specs/2026-10-06-antigravity-marketplace-design.md b/docs/superpowers/specs/2026-10-06-antigravity-marketplace-design.md new file mode 100644 index 0000000..aab6ad2 --- /dev/null +++ b/docs/superpowers/specs/2026-10-06-antigravity-marketplace-design.md @@ -0,0 +1,181 @@ +# Antigravity Marketplace plugin + +## Goal + +List Superpowers in the Google Antigravity plugin Marketplace, as part of a +partnership with Google. That requires a native Antigravity plugin manifest with +the Marketplace presentation fields, a logo, and a session bootstrap that works +on the native plugin path. + +Source: "Antigravity Plugin Marketplace Publishing Guide" (PDF from Google), plus +probes against `agy` 1.3.1 recorded below. + +## Current state (agy 1.3.1) + +- `agy plugin install https://github.com/obra/superpowers` succeeds, but only + through agy's Gemini-extension fallback: `agy plugin list` reports + `"source": "gemini-cli"`. The bootstrap rides `GEMINI.md`'s `@` lines, which + the model treats as hints and follows with `view_file`. The acceptance test + passes on this path. +- agy copies our Claude-format `hooks/hooks.json` to the install root as + `hooks.json` and fails to parse it on every session: + `invalid hook "hooks": command hook must specify 'command'`. +- `agy plugin validate .` on the repo fails: `missing plugin.json`. + +## Probe findings (agy 1.3.1) + +Each probe installed a throwaway plugin, ran `agy -p`, and uninstalled it. + +1. agy's hook events are `PreToolUse`, `PostToolUse`, `PreInvocation`, + `PostInvocation`, and `Stop`. There is no `SessionStart`. agy's embedded docs + use named top-level hooks (`{"<name>": {"PreToolUse": [...]}}`), which differs + from the PDF's `{"hooks": {...}}` example. +2. `rules/AGENTS.md` in a plugin loads as an always-on rule on every session. +3. In a rule, an `@` path relative to the rule file is rewritten to an absolute + install path (`@../skills/x/SKILL.md` becomes + `@/Users/<u>/.gemini/config/plugins/<plugin>/skills/x/SKILL.md`). Its content + is not inlined. `${PLUGIN_ROOT}` is not substituted in rules. A path that does + not resolve relative to the rule file is left as written. +4. With `.antigravity-plugin/plugin.json` present, agy installs the plugin as + `"source": "antigravity"`, finds all 15 skills, and skips hooks (no root + `hooks.json`), so the parse warning goes away. +5. A staged copy of the repo with the native manifest and a one-line + `rules/AGENTS.md` (`@../skills/using-superpowers/SKILL.md`) passed the + acceptance test: the model read `using-superpowers`, then + `antigravity-tools.md`, then `brainstorming`, and replied + "Using superpowers:brainstorming…" with a clarifying question. No code. +6. The repo-root `AGENTS.md` (contributor guidelines) is copied into the install + but is not loaded as a rule. Only `rules/AGENTS.md` is. + +## Design + +### 1. Native manifest: `.antigravity-plugin/plugin.json` + +The guide allows the manifest at `.antigravity-plugin/plugin.json`, which +matches our other harness dotdirs. Fields: + +| Field | Value | +|---|---| +| `name` | `superpowers` | +| `displayName` | `Superpowers` | +| `version` | current release version, maintained by `.version-bump.json` | +| `description` | `Make your coding agent a better engineer` (Jesse's copy; shorter than the guide's recommended 120–160, at most 160) | +| `logo` | `assets/antigravity-logo.png` | +| `suggestedPrompts` | `I've got an idea for something I'd like to build`, `Let's figure out why this broke` (Jesse's copy) | +| `category` | `Developer Tools` | +| `keywords` | lowercase, matching `.claude-plugin/plugin.json` keywords | +| `author` | `{ "name": "Jesse Vincent", "email": "jesse@fsck.com" }`, matching `.claude-plugin/plugin.json` | +| `homepage`, `repository` | `https://github.com/obra/superpowers` | +| `license` | `MIT` | + +No `skills` or `mcpServers` fields: the defaults (`skills/`, no MCP config) are +what we want, and probe 4 confirmed default discovery finds all skills. + + +### 2. Bootstrap: skill discovery, no extra files + +agy lists each installed skill's description, and `using-superpowers`' +"Use when starting any conversation" gets the model to load it. The plugin +ships no `rules/` and no `hooks.json`. + +This replaced a first design, a one-line `rules/AGENTS.md` pointer, after the +final review found that Cursor also loads any `rules/*.md` a plugin ships from +the same repo root. Alternatives probed on agy 1.3.1 and rejected: + +- A `PreInvocation` hook. It runs before every model call and `hooks.json` + must sit at the plugin root. An `ephemeralMessage` is dropped on the next + call; a `userMessage` persists, and gating it on `invocationNum == 0` and + `initialNumSteps == 1` injects exactly once per conversation, but agy still + starts the hook process on every call. +- No manifest field relocates `hooks.json` or `rules/`. + +Verified with no bootstrap file, 12/12 runs: "Let's make a react todo list" +(3) and "add a settings page" (3) load brainstorming before any code; "this +test is failing, can you fix it?" (3) loads systematic-debugging before any +edit; a react-todo second turn after an unrelated first turn (3) loads +brainstorming. Model: Gemini 3.8 Flash. The risk is that triggering depends on +the model honoring a skill description; the once-per-conversation hook is the +fallback if it slips. + +### 3. Logo: `assets/antigravity-logo.png` + +512×512 PNG, transparent background. A white rounded square (inset 31px, +corner radius 100) holds the `assets/superpowers-small.svg` mark in `#1a1a1a`, +scaled to about 70% of the square's width and centered. No border; on a light +theme it reads as a bare mark on white, which is acceptable. + +`scripts/render-antigravity-logo.sh` composes the SVG from +`superpowers-small.svg` and rasterizes it with `rsvg-convert`. It is the only way +the PNG gets regenerated; it has help text and fails clearly when +`rsvg-convert` is missing. + +### 4. Version bumps + +Add `{ "path": ".antigravity-plugin/plugin.json", "field": "version" }` to +`.version-bump.json`. + +### 5. Codex sync + +Add `/.antigravity-plugin/` and `/assets/antigravity-logo.png` to +`EXCLUDES` in `scripts/sync-to-codex-plugin.sh`, and cover them in +`tests/codex-plugin-sync/test-sync-to-codex-plugin.sh`. + +### 6. README + +The Antigravity install command stays +`agy plugin install https://github.com/obra/superpowers`. The prose changes from +"runs the plugin's session-start hook" to describing skill discovery. Add the +Marketplace route once it exists; until then, no claim about it. + +### 7. Tests: `tests/antigravity/` + +- `test-plugin-manifest.sh` (CI-safe, mirrors `tests/kimi/test-plugin-manifest.sh`): + - manifest parses; `name` matches the kebab-case pattern and equals + `superpowers`; + - every Marketplace-required field is present and non-empty: `name`, + `description`, `displayName`, `logo`, `suggestedPrompts` (1–3 non-empty + strings), `version`, `author`; + - `description` is at most 160 characters; + - `version` equals `.claude-plugin/plugin.json`'s version; + - `logo` file exists, is a PNG, and is square and at least 128×128; + - `.version-bump.json` lists the manifest; + - `using-superpowers`' description still says "Use when starting any + conversation", which the bootstrap relies on; + - no root `plugin.json`, `hooks.json`, or `rules/` exists. +- When `agy` is on `PATH`, also run `agy plugin validate` on the repo and + require `[ok]` with skills processed. +- Update the header comment of `test-antigravity-tools.sh`, which still says agy + runs the SessionStart hook. + +Live acceptance (not in CI): install the branch's tree into agy, run +"Let's make a react todo list" at least three times in clean workspaces, and +require that brainstorming triggers before any code each time. Uninstall +afterward. + +### 8. Porting guide: separate commit + +`docs/porting-to-a-new-harness.md` describes `.antigravity-plugin/install.sh` +and a generated `ANTIGRAVITY.md` that do not exist. Fix it in its own commit: + +- Routing table row: Antigravity uses the surfaced skill index. +- The "no `Skill` tool" section: replace the `contextFileName` advice for + Antigravity with the skill-index bootstrap, and record the hook and rule + findings (no session-start event, `PreInvocation` per call, no + `${PLUGIN_ROOT}` in hooks, shared plugin roots leak `rules/` into Cursor). +- The distribution table: Antigravity installs from a git URL (`agy plugin + install <url>`) and lists in its Marketplace. +- The installer-stripping section: drop the `install.sh` / `ANTIGRAVITY.md` + example. +- The harness index table has no Antigravity row; add one (manifest, + bootstrap, tool mapping, tests, install). + +## Out of scope + +- Marketplace submission mechanics. The guide does not describe how to submit; + that goes through Jesse's Google contact. +- Antigravity 2.0 and the IDE. Not installed here, so not verified. The README + makes no claims about them. +- Open PR #2350, which copies `using-superpowers` into a generated rule. Jesse + decides how to respond after this lands; I draft the reply. +- `.hermes-plugin/` and `.muse-plugin/` are missing from the Codex sync + excludes. Unrelated; noted for a separate fix. |
