gsd-pi 0.1.0 → 0.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (39) hide show
  1. package/LICENSE +39 -0
  2. package/README.md +72 -27
  3. package/package.json +11 -1
  4. package/src/resources/extensions/bg-shell/index.ts +347 -143
  5. package/src/resources/extensions/gsd/activity-log.ts +22 -1
  6. package/src/resources/extensions/gsd/tests/activity-log-prune.test.ts +327 -0
  7. package/src/resources/extensions/gsd/tests/auto-preflight.test.ts +56 -0
  8. package/src/resources/extensions/gsd/tests/auto-supervisor.test.mjs +53 -0
  9. package/src/resources/extensions/gsd/tests/complete-milestone.test.ts +225 -0
  10. package/src/resources/extensions/gsd/tests/cost-projection.test.ts +160 -0
  11. package/src/resources/extensions/gsd/tests/derive-state-deps.test.ts +341 -0
  12. package/src/resources/extensions/gsd/tests/derive-state.test.ts +637 -0
  13. package/src/resources/extensions/gsd/tests/doctor.test.ts +505 -0
  14. package/src/resources/extensions/gsd/tests/metrics-io.test.ts +201 -0
  15. package/src/resources/extensions/gsd/tests/metrics.test.ts +217 -0
  16. package/src/resources/extensions/gsd/tests/must-have-parser.test.ts +309 -0
  17. package/src/resources/extensions/gsd/tests/parsers.test.ts +1257 -0
  18. package/src/resources/extensions/gsd/tests/plan-milestone.test.ts +163 -0
  19. package/src/resources/extensions/gsd/tests/plan-quality-validator.test.ts +386 -0
  20. package/src/resources/extensions/gsd/tests/reassess-prompt.test.ts +171 -0
  21. package/src/resources/extensions/gsd/tests/replan-slice.test.ts +523 -0
  22. package/src/resources/extensions/gsd/tests/requirements.test.ts +125 -0
  23. package/src/resources/extensions/gsd/tests/resolve-ts-hooks.mjs +17 -0
  24. package/src/resources/extensions/gsd/tests/resolve-ts.mjs +11 -0
  25. package/src/resources/extensions/gsd/tests/run-uat.test.ts +348 -0
  26. package/src/resources/extensions/gsd/tests/unit-runtime.test.ts +247 -0
  27. package/src/resources/extensions/gsd/tests/workspace-index.test.ts +94 -0
  28. package/src/resources/extensions/gsd/tests/worktree.test.ts +149 -0
  29. package/src/resources/extensions/search-the-web/cache.ts +8 -0
  30. package/src/resources/extensions/search-the-web/format.ts +144 -20
  31. package/src/resources/extensions/search-the-web/http.ts +92 -1
  32. package/src/resources/extensions/search-the-web/index.ts +37 -17
  33. package/src/resources/extensions/search-the-web/tool-fetch-page.ts +249 -104
  34. package/src/resources/extensions/search-the-web/tool-llm-context.ts +404 -0
  35. package/src/resources/extensions/search-the-web/tool-search.ts +156 -77
  36. package/src/resources/extensions/plan-mode/README.md +0 -65
  37. package/src/resources/extensions/plan-mode/index.ts +0 -521
  38. package/src/resources/extensions/plan-mode/utils.ts +0 -168
  39. package/src/resources/extensions/worktree/index.ts +0 -420
package/LICENSE ADDED
@@ -0,0 +1,39 @@
1
+ Business Source License 1.1
2
+
3
+ Licensor: Lex Christopherson
4
+ Licensed Work: GSD (gsd-pi)
5
+ Additional Use Grant: None
6
+ Change Date: 2029-03-10
7
+ Change License: MIT
8
+
9
+ Parameters
10
+
11
+ Licensor: Lex Christopherson
12
+ Licensed Work: The Licensed Work is (c) 2026 Lex Christopherson
13
+
14
+ Use Limitation: You may not use the Licensed Work for a Commercial Purpose.
15
+ A "Commercial Purpose" means use in a commercial product or service, or use
16
+ on behalf of a for-profit entity, unless you have received a separate
17
+ commercial license from the Licensor.
18
+
19
+ On the Change Date, or the fourth anniversary of the first publicly available
20
+ distribution of a specific version of the Licensed Work under this License,
21
+ whichever comes first, the Licensor grants you rights under the terms of the
22
+ Change License, and the rights granted in the paragraph above terminate.
23
+
24
+ For purposes of this License:
25
+
26
+ "Commercial Purpose" means use intended for or directed toward commercial
27
+ advantage or monetary compensation.
28
+
29
+ The Licensor may make additional grants beyond those described above. Any
30
+ additional grants will be described in the Additional Use Grant above.
31
+
32
+ Notice
33
+
34
+ The Business Source License (this document, or the "License") is not an
35
+ Open Source license. However, the Licensed Work will eventually be made
36
+ available under an Open Source License, as stated in this License.
37
+
38
+ License text copyright (c) 2017 MariaDB Corporation Ab, All Rights Reserved.
39
+ "Business Source License" is a trademark of MariaDB Corporation Ab.
package/README.md CHANGED
@@ -4,6 +4,11 @@
4
4
 
5
5
  **The evolution of [Get Shit Done](https://github.com/glittercowboy/get-shit-done) — now a real coding agent.**
6
6
 
7
+ [![npm version](https://img.shields.io/npm/v/gsd-pi?style=for-the-badge&logo=npm&logoColor=white&color=CB3837)](https://www.npmjs.com/package/gsd-pi)
8
+ [![npm downloads](https://img.shields.io/npm/dm/gsd-pi?style=for-the-badge&logo=npm&logoColor=white&color=CB3837)](https://www.npmjs.com/package/gsd-pi)
9
+ [![GitHub stars](https://img.shields.io/github/stars/glittercowboy/gsd-pi?style=for-the-badge&logo=github&color=181717)](https://github.com/glittercowboy/gsd-pi)
10
+ [![License](https://img.shields.io/badge/license-BSL%201.1-blue?style=for-the-badge)](LICENSE)
11
+
7
12
  The original GSD went viral as a prompt framework for Claude Code. It worked, but it was fighting the tool — injecting prompts through slash commands, hoping the LLM would follow instructions, with no actual control over context windows, sessions, or execution.
8
13
 
9
14
  This version is different. GSD is now a standalone CLI built on the [Pi SDK](https://github.com/nicholasgasior/pi-coding-agent), which gives it direct TypeScript access to the agent harness itself. That means GSD can actually *do* what v1 could only *ask* the LLM to do: clear context between tasks, inject exactly the right files at dispatch time, manage git branches, track cost and tokens, detect stuck loops, recover from crashes, and auto-advance through an entire milestone without human intervention.
@@ -11,7 +16,7 @@ This version is different. GSD is now a standalone CLI built on the [Pi SDK](htt
11
16
  One command. Walk away. Come back to a built project with clean git history.
12
17
 
13
18
  ```bash
14
- npm install -g @glittercowboy/gsd
19
+ npm install -g gsd-pi
15
20
  gsd
16
21
  ```
17
22
 
@@ -113,49 +118,57 @@ The wizard is the on-ramp. Auto mode is the highway.
113
118
 
114
119
  ## Getting Started
115
120
 
116
- ### Install
117
-
118
- ```bash
119
- npm install -g @glittercowboy/gsd
120
- ```
121
-
122
- Requires Node.js ≥ 20.6.0. Installs Chromium via Playwright for browser-based verification (non-fatal if it fails).
123
-
124
- ### First Run
121
+ ### Install and run
125
122
 
126
123
  ```bash
124
+ npm install -g gsd-pi
127
125
  cd your-project
128
126
  gsd
129
127
  ```
130
128
 
131
- On first launch, GSD prompts for optional API keys:
132
- - **Brave Search** — for web research during planning
133
- - **Context7** — for up-to-date library documentation
134
- - **Jina** — for web page content extraction
129
+ That's it. GSD walks you through describing what you want to build, creates a roadmap, and starts working. When you're ready to let it run autonomously:
135
130
 
136
- All optional. Press Enter to skip any. Keys are stored in `~/.gsd/agent/auth.json` and loaded automatically on subsequent launches.
131
+ ```
132
+ /gsd auto
133
+ ```
137
134
 
138
- ### Start Building
135
+ Walk away. Come back to a built project with clean git history.
139
136
 
140
- The wizard walks you through describing what you want to build. Once you approve the roadmap:
137
+ ### The two-terminal workflow
141
138
 
142
- ```
139
+ GSD is designed for you to keep working while it builds. Open two terminals in the same project:
140
+
141
+ **Terminal 1 — auto mode (let it run)**
142
+ ```bash
143
+ gsd
143
144
  /gsd auto
144
145
  ```
145
146
 
146
- Walk away. GSD will research, plan, execute, verify, commit, and advance through every slice until the milestone is complete.
147
+ **Terminal 2 steer while it works**
148
+ ```bash
149
+ gsd
150
+ /gsd discuss # talk through architecture decisions
151
+ /gsd status # check progress
152
+ /gsd queue # queue the next milestone
153
+ ```
154
+
155
+ Auto mode reads state from `.gsd/` files on disk. Your discussions and decisions in terminal 2 are picked up automatically at the next phase boundary. You don't need to stop auto mode to influence what it does next.
156
+
157
+ ### First launch
158
+
159
+ On first run, GSD prompts for optional API keys (Brave Search, Context7, Jina) for web research and documentation tools. All optional — press Enter to skip. Keys are stored in `~/.gsd/agent/auth.json`.
147
160
 
148
161
  ### Commands
149
162
 
150
163
  | Command | What it does |
151
164
  |---------|-------------|
152
165
  | `/gsd` | Contextual wizard — reads state, shows what's next |
153
- | `/gsd auto` | Start auto mode (fresh session per unit, loops until done) |
166
+ | `/gsd auto` | Autonomous mode researches, plans, executes, commits, repeats |
154
167
  | `/gsd stop` | Stop auto mode gracefully |
155
- | `/gsd status` | Progress dashboard overlay |
168
+ | `/gsd discuss` | Discuss architecture and decisions (works alongside auto mode) |
169
+ | `/gsd status` | Progress dashboard |
156
170
  | `/gsd queue` | Queue future milestones (safe during auto mode) |
157
- | `/gsd discuss` | Discuss implementation decisions before planning |
158
- | `/gsd prefs` | Manage skill preferences (global/project) |
171
+ | `/gsd prefs` | Model selection, timeouts, budget ceiling |
159
172
  | `/gsd doctor` | Validate `.gsd/` integrity, find and fix issues |
160
173
  | `Ctrl+Alt+G` | Toggle dashboard overlay |
161
174
 
@@ -315,8 +328,8 @@ gsd (CLI binary)
315
328
 
316
329
  ## Requirements
317
330
 
318
- - **Node.js** ≥ 20.6.0
319
- - **Anthropic API key** — handled by Pi's built-in auth flow on first launch
331
+ - **Node.js** ≥ 20.6.0 (22+ recommended)
332
+ - **An LLM provider** — any of the 20+ supported providers (see [Use Any Model](#use-any-model))
320
333
  - **Git** — initialized automatically if missing
321
334
 
322
335
  Optional:
@@ -326,9 +339,41 @@ Optional:
326
339
 
327
340
  ---
328
341
 
342
+ ## Use Any Model
343
+
344
+ GSD isn't locked to one provider. It runs on the [Pi SDK](https://github.com/nicholasgasior/pi-coding-agent), which supports **20+ model providers** out of the box. Use different models for different phases — Opus for planning, Sonnet for execution, a fast model for research.
345
+
346
+ ### Built-in Providers
347
+
348
+ Anthropic, OpenAI, Google (Gemini), OpenRouter, GitHub Copilot, Amazon Bedrock, Azure OpenAI, Google Vertex, Groq, Cerebras, Mistral, xAI, HuggingFace, Vercel AI Gateway, and more.
349
+
350
+ ### OAuth / Max Plans
351
+
352
+ If you have a **Claude Max**, **Codex**, or **GitHub Copilot** subscription, you can use those directly — Pi handles the OAuth flow. No API key needed.
353
+
354
+ ### OpenRouter
355
+
356
+ [OpenRouter](https://openrouter.ai) gives you access to hundreds of models through a single API key. Use it to run GSD with Llama, DeepSeek, Qwen, or anything else OpenRouter supports.
357
+
358
+ ### Per-Phase Model Selection
359
+
360
+ In your preferences (`/gsd prefs`), assign different models to different phases:
361
+
362
+ ```yaml
363
+ models:
364
+ research: openrouter/deepseek/deepseek-r1
365
+ planning: claude-opus-4-6
366
+ execution: claude-sonnet-4-6
367
+ completion: claude-sonnet-4-6
368
+ ```
369
+
370
+ Use expensive models where quality matters (planning, complex execution) and cheaper/faster models where speed matters (research, simple completions). GSD tracks cost per-model so you can see exactly where your budget goes.
371
+
372
+ ---
373
+
329
374
  ## License
330
375
 
331
- MIT
376
+ [Business Source License 1.1](LICENSE)
332
377
 
333
378
  ---
334
379
 
@@ -336,6 +381,6 @@ MIT
336
381
 
337
382
  **The original GSD showed what was possible. This version delivers it.**
338
383
 
339
- **`npm install -g @glittercowboy/gsd && gsd`**
384
+ **`npm install -g gsd-pi && gsd`**
340
385
 
341
386
  </div>
package/package.json CHANGED
@@ -1,7 +1,16 @@
1
1
  {
2
2
  "name": "gsd-pi",
3
- "version": "0.1.0",
3
+ "version": "0.1.2",
4
4
  "description": "GSD — Get Stuff Done coding agent",
5
+ "license": "BUSL-1.1",
6
+ "repository": {
7
+ "type": "git",
8
+ "url": "git+https://github.com/glittercowboy/gsd-pi.git"
9
+ },
10
+ "homepage": "https://github.com/glittercowboy/gsd-pi#readme",
11
+ "bugs": {
12
+ "url": "https://github.com/glittercowboy/gsd-pi/issues"
13
+ },
5
14
  "type": "module",
6
15
  "bin": {
7
16
  "gsd": "dist/loader.js"
@@ -24,6 +33,7 @@
24
33
  "scripts": {
25
34
  "build": "tsc && npm run copy-themes",
26
35
  "copy-themes": "node -e \"const{mkdirSync,cpSync}=require('fs');const{resolve}=require('path');const src=resolve(__dirname,'node_modules/@mariozechner/pi-coding-agent/dist/modes/interactive/theme');mkdirSync('pkg/dist/modes/interactive/theme',{recursive:true});cpSync(src,'pkg/dist/modes/interactive/theme',{recursive:true})\"",
36
+ "test": "node --import ./src/resources/extensions/gsd/tests/resolve-ts.mjs --experimental-strip-types --test 'src/resources/extensions/gsd/tests/*.test.ts' 'src/resources/extensions/gsd/tests/*.test.mjs' 'src/tests/*.test.ts'",
27
37
  "dev": "tsc --watch",
28
38
  "postinstall": "node scripts/postinstall.js",
29
39
  "prepublishOnly": "npm run build"