@zalom/plastic 1.0.0-alpha.10 → 1.0.0-alpha.12
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.
- package/PLASTIC.md +106 -475
- package/README.md +43 -60
- package/deprecations.yml +2 -2
- package/package.json +1 -1
- package/scripts/install.rb +19 -8
- package/skills/auto/SKILL.md +4 -0
- package/skills/auto/references/agent-architecture.md +60 -0
- package/skills/continuing/SKILL.md +4 -0
- package/skills/continuing/references/context-management.md +32 -0
- package/skills/creating-intent/SKILL.md +5 -0
- package/skills/creating-intent/references/lifecycle.md +74 -0
- package/skills/creating-intent/references/wikilinks.md +8 -0
- package/skills/creating-project/SKILL.md +4 -0
- package/skills/creating-project/references/hubs-projects.md +55 -0
- package/skills/doctor/SKILL.md +5 -1
- package/skills/doctor/references/gates-stuck-detection.md +38 -0
- package/skills/evaluating-skills/SKILL.md +140 -0
- package/skills/evaluating-skills/assets/eval-template.json +12 -0
- package/skills/evaluating-skills/evals/evals.json +75 -0
- package/skills/evaluating-skills/references/convention-checks.md +76 -0
- package/skills/evaluating-skills/references/eval-methodology.md +154 -0
- package/skills/install/SKILL.md +25 -1
- package/skills/linking-intents/SKILL.md +4 -0
- package/skills/linking-intents/references/zettelkasten.md +33 -0
- package/skills/managing-index/SKILL.md +4 -0
- package/skills/releasing/SKILL.md +33 -3
- package/skills/releasing/references/deprecations.md +44 -0
- package/skills/savepoint/SKILL.md +4 -0
- package/skills/savepoint/references/context-management.md +32 -0
- package/skills/update/SKILL.md +79 -26
- package/skills/writing-instructions/SKILL.md +159 -0
- package/skills/writing-instructions/references/agentskills-spec.md +135 -0
package/README.md
CHANGED
|
@@ -1,87 +1,70 @@
|
|
|
1
1
|
# Plastic
|
|
2
2
|
|
|
3
|
-
>
|
|
4
|
-
>
|
|
3
|
+
> **Alpha software.** Expect breaking changes between releases.
|
|
4
|
+
> Install: `npx @zalom/plastic@alpha --claude`
|
|
5
5
|
|
|
6
|
-
|
|
6
|
+
Intent-driven idea development system for AI coding agents. Named after
|
|
7
|
+
**neuroplasticity** — adaptive, malleable, dynamic, resilient.
|
|
7
8
|
|
|
8
|
-
Plastic
|
|
9
|
+
Plastic thinks in **intents**, not tasks. An intent is a desire — something
|
|
10
|
+
you want to accomplish, explore, or understand. Intents are atomic thoughts
|
|
11
|
+
that get developed through two nested processes.
|
|
9
12
|
|
|
10
|
-
##
|
|
13
|
+
## The Two Cycles
|
|
11
14
|
|
|
12
|
-
|
|
15
|
+
**Coordinator loop (B→O→R):** Brainstorm → Organize → Review. The human and
|
|
16
|
+
agent explore ideas, structure them into intents, and validate the results.
|
|
17
|
+
This loop runs continuously across sessions.
|
|
13
18
|
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
```
|
|
19
|
+
**Intent lifecycle (W→W→H→E):** Why → What → How → Execute. Each intent moves
|
|
20
|
+
from motivation through specification, planning, to delivery. Intents produce
|
|
21
|
+
artifacts: `spec.md`, `plan.md`, `checklist.md`, `outcome.md`.
|
|
18
22
|
|
|
19
|
-
|
|
23
|
+
## Install
|
|
20
24
|
|
|
21
|
-
|
|
22
|
-
```
|
|
23
|
-
/plugin add plastic@plastic
|
|
24
|
-
```
|
|
25
|
+
Plastic requires Ruby (pre-installed on macOS/Linux) and Node.js 18+.
|
|
25
26
|
|
|
26
|
-
|
|
27
|
+
```bash
|
|
28
|
+
# Alpha (current — active development)
|
|
29
|
+
npx @zalom/plastic@alpha --claude
|
|
27
30
|
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
+
# Beta (when available — API-stable, bug hunting)
|
|
32
|
+
npx @zalom/plastic@beta --claude
|
|
33
|
+
|
|
34
|
+
# Stable (when available — general use)
|
|
35
|
+
npx @zalom/plastic --claude
|
|
31
36
|
```
|
|
32
37
|
|
|
33
|
-
|
|
38
|
+
Replace `--claude` with `--codex` for Codex CLI, `--hermes` for Hermes, or
|
|
39
|
+
`--all` for all supported agents.
|
|
34
40
|
|
|
35
|
-
|
|
41
|
+
### Updating
|
|
36
42
|
|
|
37
|
-
|
|
38
|
-
/plastic:install
|
|
39
|
-
```
|
|
40
|
-
|
|
41
|
-
**Local (testing):** Intents stored per-project in `.plastic/`. Useful for trying Plastic in a single project.
|
|
43
|
+
From within your agent, say "update plastic" or run:
|
|
42
44
|
|
|
43
|
-
```
|
|
44
|
-
/plastic
|
|
45
|
+
```bash
|
|
46
|
+
npx @zalom/plastic@alpha --claude
|
|
45
47
|
```
|
|
46
48
|
|
|
47
|
-
|
|
49
|
+
The `plastic:update` command shows available versions across all channels and
|
|
50
|
+
lets you choose which to install.
|
|
48
51
|
|
|
49
|
-
|
|
52
|
+
## Quick Start
|
|
50
53
|
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
```
|
|
54
|
-
.plastic/
|
|
55
|
-
├── AGENTS.md # Conventions contract for all agents
|
|
56
|
-
├── config.yml # Plugin configuration
|
|
57
|
-
├── INDEX.md # Brain's entry point
|
|
58
|
-
└── store/
|
|
59
|
-
└── ID--three-to-five-words/
|
|
60
|
-
├── {ID}--{slug}.md # Always present (e.g., 1a1--design-plastic.md)
|
|
61
|
-
├── spec.md # Optional (brainstorming output)
|
|
62
|
-
├── plan.md # Optional (implementation plan)
|
|
63
|
-
├── checklist.md # Optional (progress tracking)
|
|
64
|
-
└── savepoint.md # Optional (session state)
|
|
65
|
-
```
|
|
54
|
+
After installation, run `/clear` to load Plastic conventions, then:
|
|
66
55
|
|
|
67
|
-
|
|
56
|
+
1. Say "new intent" or run `/plastic:creating-intent` to create your first intent
|
|
57
|
+
2. Describe what you want to accomplish
|
|
58
|
+
3. Use `/plastic:brainstorming` to explore the design
|
|
59
|
+
4. Use `/plastic:writing-plans` to create an implementation plan
|
|
60
|
+
5. Use `/plastic:executing-plan` to deliver it
|
|
68
61
|
|
|
69
|
-
|
|
70
|
-
|-------|---------|
|
|
71
|
-
| `install` | Initialize `.plastic/` in a new project |
|
|
72
|
-
| `creating-intent` | Create a new intent with directory, hash, and INDEX.md entry |
|
|
73
|
-
| `savepoint` | Save active intent state before context reset |
|
|
74
|
-
| `continuing` | Resume from savepoint after `/clear` |
|
|
75
|
-
| `linking-intents` | Connect intents via Zettelkasten links |
|
|
76
|
-
| `managing-index` | Curate INDEX.md structure note |
|
|
77
|
-
| `executing-plan` | Execute plans via subagent-driven (default) or inline mode |
|
|
62
|
+
Or say "auto" to let the agent handle the full lifecycle autonomously.
|
|
78
63
|
|
|
79
|
-
##
|
|
64
|
+
## Conventions
|
|
80
65
|
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
| `intent-curator` | Maintains INDEX.md health, suggests links |
|
|
84
|
-
| `future-intent-researcher` | Researches parked future intents |
|
|
66
|
+
All conventions live in `AGENTS.md`, distributed to `~/.plastic/AGENTS.md`
|
|
67
|
+
during installation. Run `plastic:doctor` to check installation health.
|
|
85
68
|
|
|
86
69
|
## License
|
|
87
70
|
|
package/deprecations.yml
CHANGED
|
@@ -13,10 +13,10 @@
|
|
|
13
13
|
|
|
14
14
|
deprecations:
|
|
15
15
|
- id: cc-plugin-to-npx
|
|
16
|
-
severity:
|
|
16
|
+
severity: warning
|
|
17
17
|
summary: "Plastic distribution is moving from Claude Code plugin to npx install"
|
|
18
18
|
migration_steps:
|
|
19
|
-
- "Install new distribution: npx @zalom/plastic@
|
|
19
|
+
- "Install new distribution: npx @zalom/plastic@alpha --claude"
|
|
20
20
|
- "Verify: check that ~/.plastic/ is intact and hooks work"
|
|
21
21
|
- "Remove old plugin: /plugin remove plastic"
|
|
22
22
|
introduced: "1.0.0"
|
package/package.json
CHANGED
package/scripts/install.rb
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
# frozen_string_literal: true
|
|
4
4
|
|
|
5
5
|
# Plastic installer — runs via npx shim or directly.
|
|
6
|
-
# Usage: ruby scripts/install.rb [--claude] [--codex] [--hermes] [--all] [--uninstall] [--force] [--help]
|
|
6
|
+
# Usage: ruby scripts/install.rb [--claude] [--codex] [--hermes] [--all] [--alpha] [--beta] [--latest] [--uninstall] [--force] [--help]
|
|
7
7
|
|
|
8
8
|
require "json"
|
|
9
9
|
require "yaml"
|
|
@@ -71,7 +71,7 @@ end
|
|
|
71
71
|
# --- Flag parsing ---
|
|
72
72
|
|
|
73
73
|
def parse_flags(argv)
|
|
74
|
-
flags = { agents: [], force: false, uninstall: false, help: false }
|
|
74
|
+
flags = { agents: [], force: false, uninstall: false, help: false, channel: "latest" }
|
|
75
75
|
|
|
76
76
|
argv.each do |arg|
|
|
77
77
|
case arg
|
|
@@ -79,6 +79,9 @@ def parse_flags(argv)
|
|
|
79
79
|
when "--force" then flags[:force] = true
|
|
80
80
|
when "--uninstall" then flags[:uninstall] = true
|
|
81
81
|
when "--help", "-h" then flags[:help] = true
|
|
82
|
+
when "--alpha" then flags[:channel] = "alpha"
|
|
83
|
+
when "--beta" then flags[:channel] = "beta"
|
|
84
|
+
when "--latest" then flags[:channel] = "latest"
|
|
82
85
|
else
|
|
83
86
|
agent = AGENTS.find { |a| a[:flag] == arg }
|
|
84
87
|
flags[:agents] << agent[:key] if agent
|
|
@@ -115,22 +118,30 @@ def show_help
|
|
|
115
118
|
plastic - Intent-driven idea development system
|
|
116
119
|
|
|
117
120
|
Usage:
|
|
118
|
-
npx @zalom/plastic
|
|
121
|
+
npx @zalom/plastic [options]
|
|
119
122
|
|
|
120
|
-
|
|
123
|
+
Agent options:
|
|
121
124
|
--claude Install for Claude Code
|
|
122
125
|
--codex Install for Codex CLI
|
|
123
126
|
--hermes Install for Hermes
|
|
124
127
|
--all Install for all supported agents
|
|
128
|
+
|
|
129
|
+
Channel options:
|
|
130
|
+
--latest Install from stable channel (default)
|
|
131
|
+
--beta Install from beta channel
|
|
132
|
+
--alpha Install from alpha channel
|
|
133
|
+
|
|
134
|
+
Other options:
|
|
125
135
|
--force Overwrite existing files without prompting
|
|
126
136
|
--uninstall Remove Plastic from agent directories
|
|
127
137
|
-h, --help Show this help
|
|
128
138
|
|
|
129
139
|
Examples:
|
|
130
|
-
npx @zalom/plastic
|
|
131
|
-
npx @zalom/plastic@
|
|
132
|
-
npx @zalom/plastic@
|
|
133
|
-
npx @zalom/plastic
|
|
140
|
+
npx @zalom/plastic --claude Install stable for Claude Code
|
|
141
|
+
npx @zalom/plastic@alpha --claude Install alpha for Claude Code
|
|
142
|
+
npx @zalom/plastic@beta --claude Install beta for Claude Code
|
|
143
|
+
npx @zalom/plastic --all Install stable for all agents
|
|
144
|
+
npx @zalom/plastic --uninstall Remove from agent directories
|
|
134
145
|
|
|
135
146
|
HELP
|
|
136
147
|
end
|
package/skills/auto/SKILL.md
CHANGED
|
@@ -139,3 +139,7 @@ If the agent gets stuck (can't resolve a gap, dependency is missing, tests fail
|
|
|
139
139
|
2. Write `savepoint.md` with current state
|
|
140
140
|
3. Notify user: "Blocked on intent [ID] — [name]: [description]. Savepoint written."
|
|
141
141
|
4. **STOP.** Do not attempt workarounds that could leave the project in a broken state.
|
|
142
|
+
|
|
143
|
+
## References
|
|
144
|
+
|
|
145
|
+
- Read `references/agent-architecture.md` for the full agent hierarchy (Main Orchestrator, Project Orchestrators, coordination loop) when dispatching agents or understanding autonomous delivery scope
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
# Agent Architecture
|
|
2
|
+
|
|
3
|
+
## Main Orchestrator
|
|
4
|
+
|
|
5
|
+
The Main Orchestrator manages the global store (Main Knowledge Base). It:
|
|
6
|
+
- Recognizes, creates, updates, and groups intents
|
|
7
|
+
- Spawns Project Orchestrators for registered projects
|
|
8
|
+
- Receives contributions back from Project Orchestrators
|
|
9
|
+
- Is the only agent that runs in a loop (continuous Build→Observe→Repeat)
|
|
10
|
+
|
|
11
|
+
## Project Orchestrators
|
|
12
|
+
|
|
13
|
+
Project Orchestrators manage project stores (Project Knowledge Bases). They:
|
|
14
|
+
- Care about intents and execution within their project
|
|
15
|
+
- Spawn teams to develop and execute intents
|
|
16
|
+
- Contribute back to the Main Orchestrator when new intents are born
|
|
17
|
+
that could enrich the Main Knowledge Base
|
|
18
|
+
|
|
19
|
+
Rules:
|
|
20
|
+
- 1 Main Orchestrator : 1 Global Store (`~/.plastic/`)
|
|
21
|
+
- 1 Main Orchestrator : N Project Orchestrators
|
|
22
|
+
- 1 Project Orchestrator : 1 Project Store
|
|
23
|
+
- 1 Agent : 1 Intent (exclusive assignment)
|
|
24
|
+
- 1 Agent : N Sub-agents (for parallel Actions within an intent)
|
|
25
|
+
|
|
26
|
+
## Two Modes
|
|
27
|
+
|
|
28
|
+
- **Human-driven:** Human chats with Main Orchestrator, creates intents,
|
|
29
|
+
brainstorms, then Main Orchestrator dispatches Project Orchestrators and
|
|
30
|
+
Agents for execution.
|
|
31
|
+
- **Autonomous:** Human gives Main Orchestrator a starting intent with defined
|
|
32
|
+
outcomes. Main Orchestrator runs the full cycle — Agents do the lifecycle
|
|
33
|
+
(What→Why→How→Exec), Main Orchestrator reviews Insights, spawns next intents,
|
|
34
|
+
dispatches again.
|
|
35
|
+
|
|
36
|
+
## Autonomous Delivery
|
|
37
|
+
|
|
38
|
+
Human owns What and Why for human-initiated intents. Agent assists (research,
|
|
39
|
+
exploration) but human drives until handoff. When Why is complete — or human
|
|
40
|
+
triggers `plastic:auto` — the agent takes over How and Exec autonomously.
|
|
41
|
+
|
|
42
|
+
- **Safe-by-default:** Agent always prefers non-destructive routes (rename vs
|
|
43
|
+
delete, additive migrations, backups before changes). Destructive actions on
|
|
44
|
+
existing projects require human approval unless `--skip-permissions` is set.
|
|
45
|
+
- **One agent per intent.** Agent follows the full W→W→H→E lifecycle.
|
|
46
|
+
- **Notification only on:** finish or hard stop (blocked on destructive action,
|
|
47
|
+
unresolvable error). No progress reports — `## Insights` tracks everything.
|
|
48
|
+
- **Greenfield autonomy:** During initial project creation, all decisions are
|
|
49
|
+
non-destructive (nothing to destroy). Agent has full autonomy for greenfield choices.
|
|
50
|
+
- **Autonomous decisions** are logged in `## Insights` with `(autonomous)` marker.
|
|
51
|
+
|
|
52
|
+
## Coordinator Loop
|
|
53
|
+
|
|
54
|
+
When "work on Project X":
|
|
55
|
+
1. Read `projects.yml` → find project path
|
|
56
|
+
2. Load global config (defaults)
|
|
57
|
+
3. Load project config (overrides)
|
|
58
|
+
4. Load global INDEX.md → find hub intents tagged `project-<name>`
|
|
59
|
+
5. Load project INDEX.md → tactical intents
|
|
60
|
+
6. Coordinator has full picture, dispatches Agent teams
|
|
@@ -102,3 +102,7 @@ Auto-commit all triage changes.
|
|
|
102
102
|
2. **Project context** — if in a registered project, show governing intent + tactical intents
|
|
103
103
|
3. **Stale future intents** — surface for triage
|
|
104
104
|
4. **Fresh future intents** — offer as next work
|
|
105
|
+
|
|
106
|
+
## References
|
|
107
|
+
|
|
108
|
+
- Read `references/context-management.md` for the full save/continue protocol when resuming from a savepoint or when the resume flow needs debugging
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
# Context Management (Start-Save-Continue)
|
|
2
|
+
|
|
3
|
+
## Save Point
|
|
4
|
+
Triggered by PreCompact hook or manually:
|
|
5
|
+
1. Find active intent(s) from `~/.plastic/INDEX.md`
|
|
6
|
+
2. Update active intent's `checklist.md` (check off completed items)
|
|
7
|
+
3. Update active intent's `savepoint.md` (in-progress, next steps, blockers, discoveries)
|
|
8
|
+
4. Add observations to `## Insights`
|
|
9
|
+
5. Update INDEX.md
|
|
10
|
+
6. Commit: `cd ~/.plastic && git add . && git commit -m "chore: savepoint — [intent name]"`
|
|
11
|
+
7. Notify user to `/clear`
|
|
12
|
+
|
|
13
|
+
## Continue
|
|
14
|
+
Triggered by UserPromptSubmit hook when user says "continue". Priority order:
|
|
15
|
+
|
|
16
|
+
**1. Active intents first (resume work):**
|
|
17
|
+
1. Read INDEX.md → find active intent(s)
|
|
18
|
+
2. Read active intent's `intent.md` → what and why
|
|
19
|
+
3. Read active intent's `savepoint.md` → where we left off
|
|
20
|
+
4. Read active intent's `checklist.md` → what's next
|
|
21
|
+
5. Announce: intent name, current state, next step, blockers
|
|
22
|
+
6. Resume
|
|
23
|
+
|
|
24
|
+
**2. No active intents → offer future intents:**
|
|
25
|
+
1. List all future intents from INDEX.md
|
|
26
|
+
2. Present them as options
|
|
27
|
+
3. When user picks one, move to Active in INDEX.md
|
|
28
|
+
|
|
29
|
+
**3. Stale future intents (untouched 3+ days) → triage:**
|
|
30
|
+
- **activate** — start working on it now
|
|
31
|
+
- **abandon** — mark as abandoned
|
|
32
|
+
- **defer to agent** — implement, research, or ideate
|
|
@@ -120,3 +120,8 @@ cd <store-root> && git add . && git commit -m "feat: create intent ID — [name]
|
|
|
120
120
|
### 8. Announce
|
|
121
121
|
|
|
122
122
|
"Created intent ID — [name]. Placed in: [Active|Future]. Store: [global|project:<slug>|local]."
|
|
123
|
+
|
|
124
|
+
## References
|
|
125
|
+
|
|
126
|
+
- Read `references/lifecycle.md` for the full What→Why→How→Exec stage detail, filesystem-as-schema conventions, and creating-intent step-by-step
|
|
127
|
+
- Read `references/wikilinks.md` for the wikilink syntax table when adding `## Links` to intents
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
# Building an Intent — Full Lifecycle Detail
|
|
2
|
+
|
|
3
|
+
## What → `## Intent` section
|
|
4
|
+
|
|
5
|
+
The desire. One paragraph. What the human or agent wants.
|
|
6
|
+
This exists from the moment the intent is created.
|
|
7
|
+
|
|
8
|
+
**Deliverable:** `{ID}--{slug}.md`
|
|
9
|
+
|
|
10
|
+
## Why → `## Context` + `### Decisions` sections
|
|
11
|
+
|
|
12
|
+
Why this intent exists. Grows over time through brainstorming and exploration.
|
|
13
|
+
|
|
14
|
+
- **Context** — what we knew going in + what we decided along the way
|
|
15
|
+
- **Decisions** — main premises derived from Context plus decisions from brainstorming/grilling
|
|
16
|
+
- Decisions are Why-level: "status belongs on actions because multiple workstreams", not How-level: "use ACTION_N.md files"
|
|
17
|
+
|
|
18
|
+
**Deliverable:** `spec.md` (consolidated specification from Context + Decisions + brainstorming)
|
|
19
|
+
|
|
20
|
+
## How → Planning and preparation
|
|
21
|
+
|
|
22
|
+
Research decisions, create the implementation plan, define actions.
|
|
23
|
+
|
|
24
|
+
**Deliverable:** `plan.md` + `actions/` + `checklist.md` (execution registry with checkboxes covering all actions)
|
|
25
|
+
|
|
26
|
+
## Exec → Execute actions
|
|
27
|
+
|
|
28
|
+
Execute actions from the plan, track progress via checklist.
|
|
29
|
+
|
|
30
|
+
**Deliverable:** `outcome.md` (detailed result). `## Outcome` in intent.md = short summary written as last step.
|
|
31
|
+
|
|
32
|
+
## `## Insights` — Append-only work log
|
|
33
|
+
|
|
34
|
+
Captured throughout ALL stages. One-liner bullet points.
|
|
35
|
+
Never modified, only appended.
|
|
36
|
+
|
|
37
|
+
Tracks: stage transitions, decisions, shifts, blocks, cancellations, material for future intents.
|
|
38
|
+
This is how execution is tracked. When this intent completes, Insights
|
|
39
|
+
is where to look for what comes next. New intents spawned from Insights
|
|
40
|
+
appear in the `chain` field.
|
|
41
|
+
|
|
42
|
+
## `## Links`
|
|
43
|
+
|
|
44
|
+
Wikilinks for Obsidian graph navigation. Human-facing counterpart to the
|
|
45
|
+
frontmatter knowledge graph.
|
|
46
|
+
|
|
47
|
+
## Conventions — Filesystem as Schema
|
|
48
|
+
|
|
49
|
+
State is derived from what exists, not from what's declared.
|
|
50
|
+
|
|
51
|
+
| Convention | Signal |
|
|
52
|
+
|---|---|
|
|
53
|
+
| No `## Context` | Intent is fleeting (quick capture, non-actionable) |
|
|
54
|
+
| `## Context` has content | Intent is permanent (developed, actionable) |
|
|
55
|
+
| `## Outcome` has content | Intent is done |
|
|
56
|
+
| `## Insights` has `(autonomous)` entries | Intent is/was being delivered autonomously |
|
|
57
|
+
|
|
58
|
+
### Transitions
|
|
59
|
+
|
|
60
|
+
- Fleeting → permanent: add `## Context` (one-way, also makes it actionable)
|
|
61
|
+
- There is no separate "non-actionable → actionable" transition — permanence implies actionability
|
|
62
|
+
- Even research intents are actionable: the research itself is the action, the conclusion is the outcome
|
|
63
|
+
|
|
64
|
+
## Creating an Intent — Full Steps
|
|
65
|
+
|
|
66
|
+
1. Determine the target store: `~/.plastic/store/` for global intents (default), `~/.plastic/projects/{slug}/store/` for project intents
|
|
67
|
+
2. Determine the Folgezettel ID: If root (no parent), find highest root number +1. If branch, run `"${CLAUDE_PLUGIN_ROOT}/scripts/folgezettel-id" <parent_id> <store_path>`
|
|
68
|
+
3. Create the intent directory in the chosen store (e.g., `ID--three-to-five-words`)
|
|
69
|
+
4. Create `{ID}--{slug}.md` with frontmatter (id, intent, sources, chain, created, author, tags)
|
|
70
|
+
5. Write `## Intent` — the What
|
|
71
|
+
6. Add remaining sections: `## Context`, `## Outcome`, `## Insights`, `## Links`
|
|
72
|
+
7. Update the appropriate `INDEX.md` — add to Active section and appropriate cluster
|
|
73
|
+
|
|
74
|
+
A fleeting intent can skip `## Context` — just `## Intent` and empty sections.
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
# Wikilink Conventions
|
|
2
|
+
|
|
3
|
+
| Syntax | Meaning |
|
|
4
|
+
|--------|---------|
|
|
5
|
+
| `[[ID]]` | Link to intent in same store (e.g., `[[1a1]]`) |
|
|
6
|
+
| `[[ID\|display text]]` | Link with human-readable label |
|
|
7
|
+
| `[[global:ID]]` | Link to intent in `~/.plastic/store/` |
|
|
8
|
+
| `[[project-slug:ID]]` | Link to intent in `~/.plastic/projects/{slug}/store/` |
|
|
@@ -164,3 +164,7 @@ Log in `## Insights` of each founding intent:
|
|
|
164
164
|
|
|
165
165
|
Announce to user:
|
|
166
166
|
> "Project `<slug>` created at `<path>`. AGENTS.md populated with [N] decisions from [founding intent IDs]. Tactical mirror `1` is now the active intent in the project store."
|
|
167
|
+
|
|
168
|
+
## References
|
|
169
|
+
|
|
170
|
+
- Read `references/hubs-projects.md` for the full hub/project relationship model, project creation flow, and cross-linking conventions
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
# Hubs and Projects
|
|
2
|
+
|
|
3
|
+
## Hubs
|
|
4
|
+
|
|
5
|
+
A Hub is a cloud of intents around related topics. Hubs emerge naturally from
|
|
6
|
+
Folgezettel branching — intents that spawn in the same direction cluster.
|
|
7
|
+
|
|
8
|
+
- A Hub can spawn a Project. The Hub holds the founding ideas.
|
|
9
|
+
- A single intent can also spawn a Project.
|
|
10
|
+
- Hub-spawned projects revolve around different ideas around related topics.
|
|
11
|
+
- Intent-spawned projects revolve around the single founding intent.
|
|
12
|
+
- A Project is the deliverable outcome of one or more intents.
|
|
13
|
+
|
|
14
|
+
Hubs are represented as clusters in INDEX.md.
|
|
15
|
+
|
|
16
|
+
## Projects — Full Detail
|
|
17
|
+
|
|
18
|
+
A Project is a deliverable grouping of intents. Projects have two stores:
|
|
19
|
+
|
|
20
|
+
- **Global store** (`~/.plastic/store/`): strategic intents
|
|
21
|
+
- **Project store** (`~/.plastic/projects/{slug}/store/`): tactical intents
|
|
22
|
+
|
|
23
|
+
`projects.yml` maps project slugs to codebase paths:
|
|
24
|
+
```yaml
|
|
25
|
+
projects:
|
|
26
|
+
plastic:
|
|
27
|
+
path: "/path/to/plastic"
|
|
28
|
+
remote: "git@github.com:org/plastic.git"
|
|
29
|
+
registered: '2026-05-26'
|
|
30
|
+
status: active
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
Config resolution: `~/.plastic/projects/{slug}/config.yml` overrides `~/.plastic/config.yml`.
|
|
34
|
+
|
|
35
|
+
Cross-linking: project intents reference global intents via `[[global:ID]]`. Global intents reference project intents via `[[project-slug:ID]]`.
|
|
36
|
+
|
|
37
|
+
## Privacy and Collaboration
|
|
38
|
+
|
|
39
|
+
**Plastic is personal.** All intent data lives under `~/.plastic/` — one location,
|
|
40
|
+
one git repo, never pushed. Each person has their own intent store.
|
|
41
|
+
|
|
42
|
+
Collaboration happens through pull requests and project conventions, not shared intents.
|
|
43
|
+
When an intent delivers something that changes how a project works, the decision gets
|
|
44
|
+
written into the project's shared files (README, docs, config). The intents themselves
|
|
45
|
+
are private working memory.
|
|
46
|
+
|
|
47
|
+
## Project Creation Flow
|
|
48
|
+
|
|
49
|
+
When an implementation intent spawns a project:
|
|
50
|
+
1. Determine project path from config `project_roots` or intent context
|
|
51
|
+
2. `gh repo create --private` (agent-created repos are always private by default)
|
|
52
|
+
3. Set up project directory, git init, AGENTS.md with founding intent decisions
|
|
53
|
+
4. Register in `projects.yml`
|
|
54
|
+
5. Create tactical mirror in project store
|
|
55
|
+
6. The global intent completes; the tactical mirror becomes the active intent
|
package/skills/doctor/SKILL.md
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
---
|
|
2
|
-
name: doctor
|
|
2
|
+
name: plastic:doctor
|
|
3
3
|
description: Use when diagnosing Plastic installation health, after updates, or when something seems broken. Runs checks and reports findings with fix options.
|
|
4
4
|
---
|
|
5
5
|
|
|
@@ -110,3 +110,7 @@ This keeps the update flow clean when nothing is wrong.
|
|
|
110
110
|
- The script outputs JSON to stdout. Any diagnostic errors go to stderr.
|
|
111
111
|
- Non-zero exit codes mean "issues found", not "script crashed".
|
|
112
112
|
Always parse stdout regardless of exit code.
|
|
113
|
+
|
|
114
|
+
## References
|
|
115
|
+
|
|
116
|
+
- Read `references/gates-stuck-detection.md` for the full gate enforcement table, bridge file pattern, and stuck detection thresholds when diagnosing gate failures or stuck agents
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
# Gate Enforcement and Stuck Detection
|
|
2
|
+
|
|
3
|
+
## Bridge File Pattern
|
|
4
|
+
|
|
5
|
+
`/tmp/plastic-{session}.json` is the hot cache; the filesystem is the authority.
|
|
6
|
+
SessionStart rebuilds the bridge file from the filesystem — the bridge is always disposable.
|
|
7
|
+
|
|
8
|
+
## Gate Taxonomy
|
|
9
|
+
|
|
10
|
+
| Gate type | Purpose |
|
|
11
|
+
|---|---|
|
|
12
|
+
| **Pre-flight** | Prerequisites exist? |
|
|
13
|
+
| **Revision** | New info invalidated prior work? |
|
|
14
|
+
| **Escalation** | Blocked items surface to user |
|
|
15
|
+
| **Abort** | Inconsistent state detected |
|
|
16
|
+
|
|
17
|
+
## Full Gate Enforcement
|
|
18
|
+
|
|
19
|
+
| Gate | Blocked action | Required prerequisite |
|
|
20
|
+
|---|---|---|
|
|
21
|
+
| Pre-flight | Cannot write `plan.md` | `spec.md` must exist |
|
|
22
|
+
| Pre-flight | Cannot create `actions/` | `spec.md` must exist |
|
|
23
|
+
| Pre-flight | Cannot write `outcome.md` | `checklist.md` must exist with all items checked |
|
|
24
|
+
| Revision | Cannot proceed to Exec | Context changed after spec.md — re-derive spec |
|
|
25
|
+
| Abort | Cannot complete intent | `outcome.md` exists but checklist has unchecked items |
|
|
26
|
+
|
|
27
|
+
Hard blocking — hooks exit with code 2 when gates fail.
|
|
28
|
+
|
|
29
|
+
## Stuck Detection
|
|
30
|
+
|
|
31
|
+
| Condition | Threshold | Action |
|
|
32
|
+
|---|---|---|
|
|
33
|
+
| Consecutive gate failures | 3+ | Warning |
|
|
34
|
+
| Consecutive gate failures | 5+ | Force savepoint + escalate |
|
|
35
|
+
| No activity | 5+ min | Warning |
|
|
36
|
+
| No activity | 10+ min | Force savepoint + escalate |
|
|
37
|
+
| Context pressure | 80% | Warning |
|
|
38
|
+
| Context pressure | 90% | Force savepoint |
|