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
10 changes: 7 additions & 3 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,13 @@ Each released version is tagged in git (`v0.0.1`, `v0.1.0`, etc.) and includes t

## [Unreleased]

### Removed

- **API mode dropped — Draftwise runs only inside coding agents now.** Every command (`scan`, `explain`, `new`, `tech`, `tasks`, `init`) used to support two execution paths: agent mode (print scanner data + instruction, let the host coding agent do the synthesis) and api mode (call Claude directly via `@anthropic-ai/sdk` and write the spec from the CLI). The api path is gone. `src/ai/provider.js`, `src/ai/providers/claude.js`, and the `@anthropic-ai/sdk` dependency are removed. `init` loses its `--ai-mode`, `--provider`, `--api-key-env`, `--stack`, and `--answers` flags plus the corresponding interactive prompts; `new`/`tech`/`tasks` lose `--force` and (for `new`) `--answers`; `scaffold` is unchanged. `config.yaml` schema simplifies — the `ai:` block (`mode`/`provider`/`api_key_env`/`model`/`max_tokens`) is no longer used; `loadConfig` returns only `projectState`/`stack`/`scanMaxFiles`. Existing configs with an `ai:` block keep working: `loadConfig` prints a one-line notice telling the user the block is safe to delete, then ignores it. The shared overwrite-guard and answers-flag utilities and the `src/ai/prompts/principles.js` + `src/ai/prompts/spec-quality.js` modules are removed — every prompt module now exports just `buildAgentInstruction` (or `AGENT_INSTRUCTION` for `scan`), since the host coding agent is the only consumer. CLAUDE.md and README.md updated end-to-end. — Ankur

### Changed

- **`draftwise skills install` auto-detects which AI harnesses are on the machine instead of installing to all three by default.** Previously the default behavior was to write SKILL.md into every known harness's user-level skill dir (`~/.claude/skills/draftwise/`, `~/.cursor/skills/draftwise/`, `~/.gemini/skills/draftwise/`) regardless of whether the user actually had Claude Code, Cursor, or Gemini CLI installed. Now `detectInstalledProviders` (in `src/utils/skill-providers.js`) checks which of `~/.claude` / `~/.cursor` / `~/.gemini` exist at the chosen scope root and installs only to those. The detected set is logged so the user sees *why* a particular harness was picked. `--provider=all` is the explicit opt-in for the old behavior; `--provider=<name>` still targets one harness regardless of detection. When detection finds nothing the command errors with a hint pointing at both override flags. `skills help` now also prints "Detected harnesses (user scope): …" and the project-scope equivalent so the auto-detect set is visible without having to run install. Why: this is the same behavior impeccable's install uses (via the `vercel-labs/skills` package — auto-detect, with `--all` as the explicit override) and it's friendlier than littering provider dirs with files for harnesses the user doesn't have. CLAUDE.md's "Standalone skill" section and README's slash-command callout updated to match. `skills uninstall` keeps its existing "iterate every known dir and skip ones with nothing to remove" behavior — different goal (clean up stale Draftwise installs whether or not the harness is still on disk), so detection-on-uninstall would miss the cleanup case. — Ankur
- **`draftwise skills install` auto-detects which AI harnesses are on the machine instead of installing to all three by default.** Previously the default behavior was to write SKILL.md into every known harness's user-level skill dir (`~/.claude/skills/draftwise/`, `~/.cursor/skills/draftwise/`, `~/.gemini/skills/draftwise/`) regardless of whether the user actually had Claude Code, Cursor, or Gemini CLI installed. Now `detectInstalledProviders` (in `src/utils/skill-providers.js`) checks which of `~/.claude` / `~/.cursor` / `~/.gemini` exist at the chosen scope root and installs only to those. The detected set is logged so the user sees *why* a particular harness was picked. `--provider=all` is the explicit opt-in for the old behavior; `--provider=<name>` still targets one harness regardless of detection. When detection finds nothing the command errors with a hint pointing at both override flags. `skills help` now also prints "Detected harnesses (user scope): …" and the project-scope equivalent so the auto-detect set is visible without having to run install. Why: auto-detect with `--provider=all` as an explicit override is friendlier than littering provider dirs with files for harnesses the user doesn't have. CLAUDE.md's "Standalone skill" section and README's slash-command callout updated to match. `skills uninstall` keeps its existing "iterate every known dir and skip ones with nothing to remove" behavior — different goal (clean up stale Draftwise installs whether or not the harness is still on disk), so detection-on-uninstall would miss the cleanup case. — Ankur

## [0.2.1] — 2026-04-29 — Ankur

Expand All @@ -26,7 +30,7 @@ After merge, ritual: `git tag -a v0.2.1 -m "v0.2.1"`, `git push origin v0.2.1`,

### Added

- **`draftwise skills <install|uninstall|help>` — standalone slash-command skill across Claude Code, Cursor, and Gemini CLI.** Three subcommands grouped under `skills` (the `git remote <sub>` / `gh pr <sub>` / `impeccable skills <sub>` pattern): `install` writes `plugin/skills/draftwise/` (SKILL.md + per-verb references) into each known harness's user-level skill dir (`~/.claude/skills/draftwise/`, `~/.cursor/skills/draftwise/`, `~/.gemini/skills/draftwise/`); `uninstall` removes them; `help` prints a 3×2 state table (3 harnesses × 2 scopes). `--provider=claude|cursor|gemini|all` narrows; `--scope=user|project` switches between `~` and `<cwd>`; `--force` overwrites on install. Why: (1) Claude Code's marketplace plugin path forces a `<plugin>:<skill>` namespace prefix on every plugin skill regardless of `/plugin install` scope ([anthropics/claude-code#15882](https://github.com/anthropics/claude-code/issues/15882), closed: not planned), so the marketplace install gives users `/draftwise:draftwise <verb>` instead of `/draftwise <verb>` — a standalone SKILL.md written directly into `.claude/skills/` has no plugin manifest and resolves bare. (2) Same SKILL.md works across harnesses with a tiny per-provider frontmatter trim (Claude-only `user-invocable` / `argument-hint` / `allowed-tools` stripped for Cursor + Gemini); body identical. Same model impeccable uses (`npx impeccable skills install` writes to ~11 provider dirs). The marketplace plugin is independent and may coexist; both forms appear side-by-side in Claude Code's slash menu. Conflict detection lists every existing target in one error (no half-installs). Subcommand routing lives in `src/index.js` via a small `SUBCOMMAND_GROUPS` table; provider mapping + frontmatter trim in `src/utils/skill-providers.js`; commands at `src/commands/skills/{install,uninstall,help}.js`. `package.json` `files` ships `plugin/skills/` so the install can resolve its source from the npm install. Tests inject temp `home`, `cwd`, and `sourceDir` to keep the real `~/.claude/` (and equivalents) untouched. Plugin SKILL.md learns `skills` as a verb routing to `reference/skills.md` so the marketplace plugin's chat-driven flow handles `skills install` / `skills uninstall` / `skills help` natively. — Ankur
- **`draftwise skills <install|uninstall|help>` — standalone slash-command skill across Claude Code, Cursor, and Gemini CLI.** Three subcommands grouped under `skills` (the `git remote <sub>` / `gh pr <sub>` pattern): `install` writes `plugin/skills/draftwise/` (SKILL.md + per-verb references) into each known harness's user-level skill dir (`~/.claude/skills/draftwise/`, `~/.cursor/skills/draftwise/`, `~/.gemini/skills/draftwise/`); `uninstall` removes them; `help` prints a 3×2 state table (3 harnesses × 2 scopes). `--provider=claude|cursor|gemini|all` narrows; `--scope=user|project` switches between `~` and `<cwd>`; `--force` overwrites on install. Why: (1) Claude Code's marketplace plugin path forces a `<plugin>:<skill>` namespace prefix on every plugin skill regardless of `/plugin install` scope ([anthropics/claude-code#15882](https://github.com/anthropics/claude-code/issues/15882), closed: not planned), so the marketplace install gives users `/draftwise:draftwise <verb>` instead of `/draftwise <verb>` — a standalone SKILL.md written directly into `.claude/skills/` has no plugin manifest and resolves bare. (2) Same SKILL.md works across harnesses with a tiny per-provider frontmatter trim (Claude-only `user-invocable` / `argument-hint` / `allowed-tools` stripped for Cursor + Gemini); body identical. The marketplace plugin is independent and may coexist; both forms appear side-by-side in Claude Code's slash menu. Conflict detection lists every existing target in one error (no half-installs). Subcommand routing lives in `src/index.js` via a small `SUBCOMMAND_GROUPS` table; provider mapping + frontmatter trim in `src/utils/skill-providers.js`; commands at `src/commands/skills/{install,uninstall,help}.js`. `package.json` `files` ships `plugin/skills/` so the install can resolve its source from the npm install. Tests inject temp `home`, `cwd`, and `sourceDir` to keep the real `~/.claude/` (and equivalents) untouched. Plugin SKILL.md learns `skills` as a verb routing to `reference/skills.md` so the marketplace plugin's chat-driven flow handles `skills install` / `skills uninstall` / `skills help` natively. — Ankur

### Changed

Expand Down Expand Up @@ -62,7 +66,7 @@ The "Mode 1, for real" release. Draftwise now ships a Claude Code plugin so PMs

### Added

- **Claude Code plugin: `/draftwise` slash commands.** New `.claude-plugin/marketplace.json` at repo root declares a single `draftwise` plugin with `source: ./plugin`. Inside `plugin/` lives the install manifest (`.claude-plugin/plugin.json`) plus a single skill `skills/draftwise/SKILL.md` that routes user input to per-verb references at `skills/draftwise/reference/<verb>.md` (one per CLI verb: init, new, scan, explain, tech, tasks, list, show, scaffold). Each reference walks the model through how to drive that verb in chat — collect inputs, shell out to the npm-installed `draftwise` CLI, parse the structured handoff or streamed output, report back. Pattern mirrors impeccable: 1 skill / N commands / shells out to the underlying CLI. Users install via `/plugin marketplace add 4nkur/draftwise` then `/plugin install draftwise` in Claude Code; the npm CLI install (`npm i -g draftwise`) is the prerequisite. Plugin name = skill name = `draftwise` so the slash form is `/draftwise <verb>` (no `<plugin>:<skill>` namespacing in command logs). Plugin is distributed separately from the npm package — `package.json` `files` does not include the plugin directories. SKILL.md includes a "Setup gates" table making the verb-dependency chain explicit (`init` is bootstrap; `tech` requires a product spec; `tasks` requires a tech spec; etc.) and a "Conversation standards" section that pulls in the eight collaboration principles from `src/ai/prompts/principles.js` by reference, so the chat-driven flow matches what the CLI's api-mode synthesis enforces. Per-verb references add pre-flight gate checks (catch missing prerequisites in chat instead of letting the CLI throw), tone-shaping guidance for ambiguous flag questions, idea-concreteness check for `new` (one-word ideas get one elaboration ask before invoking), and review nudges for `tech` / `tasks`. README's Quick Start gains a 3-line install snippet for the plugin path. Closes #42. — Ankur
- **Claude Code plugin: `/draftwise` slash commands.** New `.claude-plugin/marketplace.json` at repo root declares a single `draftwise` plugin with `source: ./plugin`. Inside `plugin/` lives the install manifest (`.claude-plugin/plugin.json`) plus a single skill `skills/draftwise/SKILL.md` that routes user input to per-verb references at `skills/draftwise/reference/<verb>.md` (one per CLI verb: init, new, scan, explain, tech, tasks, list, show, scaffold). Each reference walks the model through how to drive that verb in chat — collect inputs, shell out to the npm-installed `draftwise` CLI, parse the structured handoff or streamed output, report back. Pattern: 1 skill / N commands / shells out to the underlying CLI. Users install via `/plugin marketplace add 4nkur/draftwise` then `/plugin install draftwise` in Claude Code; the npm CLI install (`npm i -g draftwise`) is the prerequisite. Plugin name = skill name = `draftwise` so the slash form is `/draftwise <verb>` (no `<plugin>:<skill>` namespacing in command logs). Plugin is distributed separately from the npm package — `package.json` `files` does not include the plugin directories. SKILL.md includes a "Setup gates" table making the verb-dependency chain explicit (`init` is bootstrap; `tech` requires a product spec; `tasks` requires a tech spec; etc.) and a "Conversation standards" section that pulls in the eight collaboration principles from `src/ai/prompts/principles.js` by reference, so the chat-driven flow matches what the CLI's api-mode synthesis enforces. Per-verb references add pre-flight gate checks (catch missing prerequisites in chat instead of letting the CLI throw), tone-shaping guidance for ambiguous flag questions, idea-concreteness check for `new` (one-word ideas get one elaboration ask before invoking), and review nudges for `tech` / `tasks`. README's Quick Start gains a 3-line install snippet for the plugin path. Closes #42. — Ankur

### Changed

Expand Down
Loading