specced 0.1.0__tar.gz

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 (83) hide show
  1. specced-0.1.0/.gitignore +22 -0
  2. specced-0.1.0/LICENSE +21 -0
  3. specced-0.1.0/NOTICE +20 -0
  4. specced-0.1.0/PKG-INFO +169 -0
  5. specced-0.1.0/README.md +127 -0
  6. specced-0.1.0/pyproject.toml +58 -0
  7. specced-0.1.0/src/specced/__init__.py +11 -0
  8. specced-0.1.0/src/specced/_paths.py +11 -0
  9. specced-0.1.0/src/specced/cli.py +178 -0
  10. specced-0.1.0/src/specced/detect.py +299 -0
  11. specced-0.1.0/src/specced/scaffold.py +761 -0
  12. specced-0.1.0/src/specced/templates/code-review/README.md +25 -0
  13. specced-0.1.0/src/specced/templates/code-review/_template.md +21 -0
  14. specced-0.1.0/src/specced/templates/mcp/servers.json +36 -0
  15. specced-0.1.0/src/specced/templates/presets/go.json +16 -0
  16. specced-0.1.0/src/specced/templates/presets/java-spring.json +16 -0
  17. specced-0.1.0/src/specced/templates/presets/node-express.json +16 -0
  18. specced-0.1.0/src/specced/templates/presets/node-next.json +16 -0
  19. specced-0.1.0/src/specced/templates/presets/node-react.json +16 -0
  20. specced-0.1.0/src/specced/templates/presets/node-svelte.json +16 -0
  21. specced-0.1.0/src/specced/templates/presets/node.json +16 -0
  22. specced-0.1.0/src/specced/templates/presets/python-django.json +16 -0
  23. specced-0.1.0/src/specced/templates/presets/python-fastapi.json +26 -0
  24. specced-0.1.0/src/specced/templates/presets/python.json +16 -0
  25. specced-0.1.0/src/specced/templates/presets/ruby-rails.json +16 -0
  26. specced-0.1.0/src/specced/templates/presets/rust.json +16 -0
  27. specced-0.1.0/src/specced/templates/project/CONSTITUTION.md.tmpl +60 -0
  28. specced-0.1.0/src/specced/templates/project/Makefile.tmpl +27 -0
  29. specced-0.1.0/src/specced/templates/project/mcp.json.tmpl +9 -0
  30. specced-0.1.0/src/specced/templates/project/settings.json.tmpl +27 -0
  31. specced-0.1.0/src/specced/templates/rules/README.md +26 -0
  32. specced-0.1.0/src/specced/templates/rules/_template.md +28 -0
  33. specced-0.1.0/src/specced/templates/skills/add-integration/SKILL.md +67 -0
  34. specced-0.1.0/src/specced/templates/skills/api-endpoint/SKILL.md +72 -0
  35. specced-0.1.0/src/specced/templates/skills/background-worker/SKILL.md +50 -0
  36. specced-0.1.0/src/specced/templates/skills/capture-rule/SKILL.md +50 -0
  37. specced-0.1.0/src/specced/templates/skills/code-review/SKILL.md +40 -0
  38. specced-0.1.0/src/specced/templates/skills/db-migration/SKILL.md +62 -0
  39. specced-0.1.0/src/specced/templates/skills/debug-issue/SKILL.md +47 -0
  40. specced-0.1.0/src/specced/templates/skills/decision-record/SKILL.md +62 -0
  41. specced-0.1.0/src/specced/templates/skills/dependency-upgrade/SKILL.md +63 -0
  42. specced-0.1.0/src/specced/templates/skills/new-domain-skill/SKILL.md +52 -0
  43. specced-0.1.0/src/specced/templates/skills/perf-investigation/SKILL.md +81 -0
  44. specced-0.1.0/src/specced/templates/skills/prepare-pr/SKILL.md +80 -0
  45. specced-0.1.0/src/specced/templates/skills/refactor/SKILL.md +53 -0
  46. specced-0.1.0/src/specced/templates/skills/regen-client/SKILL.md +79 -0
  47. specced-0.1.0/src/specced/templates/skills/release/SKILL.md +62 -0
  48. specced-0.1.0/src/specced/templates/skills/repo-task-proof-loop/AGENTS.md +29 -0
  49. specced-0.1.0/src/specced/templates/skills/repo-task-proof-loop/CLAUDE.md +33 -0
  50. specced-0.1.0/src/specced/templates/skills/repo-task-proof-loop/LICENSE +201 -0
  51. specced-0.1.0/src/specced/templates/skills/repo-task-proof-loop/README.md +181 -0
  52. specced-0.1.0/src/specced/templates/skills/repo-task-proof-loop/SKILL.md +255 -0
  53. specced-0.1.0/src/specced/templates/skills/repo-task-proof-loop/VERIFICATION.md +35 -0
  54. specced-0.1.0/src/specced/templates/skills/repo-task-proof-loop/agents/openai.yaml +6 -0
  55. specced-0.1.0/src/specced/templates/skills/repo-task-proof-loop/assets/schemas/evidence.schema.json +77 -0
  56. specced-0.1.0/src/specced/templates/skills/repo-task-proof-loop/assets/schemas/verdict.schema.json +62 -0
  57. specced-0.1.0/src/specced/templates/skills/repo-task-proof-loop/assets/templates/claude/task-builder.md.tmpl +39 -0
  58. specced-0.1.0/src/specced/templates/skills/repo-task-proof-loop/assets/templates/claude/task-fixer.md.tmpl +27 -0
  59. specced-0.1.0/src/specced/templates/skills/repo-task-proof-loop/assets/templates/claude/task-spec-freezer.md.tmpl +31 -0
  60. specced-0.1.0/src/specced/templates/skills/repo-task-proof-loop/assets/templates/claude/task-verifier.md.tmpl +36 -0
  61. specced-0.1.0/src/specced/templates/skills/repo-task-proof-loop/assets/templates/codex/task-builder.toml.tmpl +41 -0
  62. specced-0.1.0/src/specced/templates/skills/repo-task-proof-loop/assets/templates/codex/task-fixer.toml.tmpl +28 -0
  63. specced-0.1.0/src/specced/templates/skills/repo-task-proof-loop/assets/templates/codex/task-spec-freezer.toml.tmpl +30 -0
  64. specced-0.1.0/src/specced/templates/skills/repo-task-proof-loop/assets/templates/codex/task-verifier.toml.tmpl +36 -0
  65. specced-0.1.0/src/specced/templates/skills/repo-task-proof-loop/assets/templates/evidence.json.tmpl +20 -0
  66. specced-0.1.0/src/specced/templates/skills/repo-task-proof-loop/assets/templates/evidence.md.tmpl +27 -0
  67. specced-0.1.0/src/specced/templates/skills/repo-task-proof-loop/assets/templates/managed-block-agents.md.tmpl +31 -0
  68. specced-0.1.0/src/specced/templates/skills/repo-task-proof-loop/assets/templates/managed-block-claude.md.tmpl +35 -0
  69. specced-0.1.0/src/specced/templates/skills/repo-task-proof-loop/assets/templates/problems.md.tmpl +17 -0
  70. specced-0.1.0/src/specced/templates/skills/repo-task-proof-loop/assets/templates/raw.build.txt.tmpl +1 -0
  71. specced-0.1.0/src/specced/templates/skills/repo-task-proof-loop/assets/templates/raw.lint.txt.tmpl +1 -0
  72. specced-0.1.0/src/specced/templates/skills/repo-task-proof-loop/assets/templates/raw.test-integration.txt.tmpl +1 -0
  73. specced-0.1.0/src/specced/templates/skills/repo-task-proof-loop/assets/templates/raw.test-unit.txt.tmpl +1 -0
  74. specced-0.1.0/src/specced/templates/skills/repo-task-proof-loop/assets/templates/spec.md.tmpl +51 -0
  75. specced-0.1.0/src/specced/templates/skills/repo-task-proof-loop/assets/templates/verdict.json.tmpl +13 -0
  76. specced-0.1.0/src/specced/templates/skills/repo-task-proof-loop/references/COMMANDS.md +396 -0
  77. specced-0.1.0/src/specced/templates/skills/repo-task-proof-loop/references/REFERENCE.md +183 -0
  78. specced-0.1.0/src/specced/templates/skills/repo-task-proof-loop/references/SCHEMAS.md +127 -0
  79. specced-0.1.0/src/specced/templates/skills/repo-task-proof-loop/references/SUBAGENTS.md +206 -0
  80. specced-0.1.0/src/specced/templates/skills/repo-task-proof-loop/scripts/task_loop.py +710 -0
  81. specced-0.1.0/src/specced/templates/skills/repo-task-proof-loop/scripts/verify_package.py +519 -0
  82. specced-0.1.0/src/specced/templates/skills/security-review/SKILL.md +85 -0
  83. specced-0.1.0/src/specced/templates/skills/write-tests/SKILL.md +78 -0
@@ -0,0 +1,22 @@
1
+ # Python
2
+ __pycache__/
3
+ *.py[cod]
4
+ *.egg-info/
5
+ .eggs/
6
+ build/
7
+ dist/
8
+ .venv/
9
+ venv/
10
+ .mypy_cache/
11
+ .ruff_cache/
12
+ .pytest_cache/
13
+
14
+ # OS / editor
15
+ .DS_Store
16
+ .idea/
17
+ .vscode/
18
+
19
+ # Claude Code session-local settings (per-user, not shared)
20
+ .claude/settings.local.json
21
+
22
+ # specced never ignores its own templates; target repos manage their own .specced/
specced-0.1.0/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 Norik Saroyan
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
specced-0.1.0/NOTICE ADDED
@@ -0,0 +1,20 @@
1
+ specced
2
+ Copyright (c) 2026 Norik Saroyan
3
+ Licensed under the MIT License (see LICENSE).
4
+
5
+ ================================================================================
6
+ Bundled third-party components
7
+ ================================================================================
8
+
9
+ This distribution vendors the "repo-task-proof-loop" skill, which is the
10
+ proof-loop engine specced installs into target repositories.
11
+
12
+ Component: repo-task-proof-loop
13
+ Author: OpenAI
14
+ License: Apache License 2.0
15
+ Location: src/specced/templates/skills/repo-task-proof-loop/
16
+ License text: src/specced/templates/skills/repo-task-proof-loop/LICENSE
17
+
18
+ The component is redistributed unmodified under the terms of the Apache License
19
+ 2.0. specced layers its own scaffolding (rules, code-review, constitution, MCP,
20
+ Makefile vocabulary, and the bootstrap interview) around it; that layer is MIT.
specced-0.1.0/PKG-INFO ADDED
@@ -0,0 +1,169 @@
1
+ Metadata-Version: 2.4
2
+ Name: specced
3
+ Version: 0.1.0
4
+ Summary: Interview-driven bootstrap for a reusable agentic coding setup: proof-loop engine + project rules + skills, installed into any repo.
5
+ Project-URL: Homepage, https://github.com/NoroSaroyan/specced
6
+ Project-URL: Issues, https://github.com/NoroSaroyan/specced/issues
7
+ Author-email: Norik Saroyan <noriksaroyan@gmail.com>
8
+ License: MIT License
9
+
10
+ Copyright (c) 2026 Norik Saroyan
11
+
12
+ Permission is hereby granted, free of charge, to any person obtaining a copy
13
+ of this software and associated documentation files (the "Software"), to deal
14
+ in the Software without restriction, including without limitation the rights
15
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
16
+ copies of the Software, and to permit persons to whom the Software is
17
+ furnished to do so, subject to the following conditions:
18
+
19
+ The above copyright notice and this permission notice shall be included in all
20
+ copies or substantial portions of the Software.
21
+
22
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
23
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
24
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
25
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
26
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
27
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
28
+ SOFTWARE.
29
+ License-File: LICENSE
30
+ License-File: NOTICE
31
+ Keywords: agentic,claude-code,codex,coding-agent,proof-loop,scaffold,spec-driven
32
+ Classifier: Development Status :: 3 - Alpha
33
+ Classifier: Intended Audience :: Developers
34
+ Classifier: Programming Language :: Python :: 3
35
+ Classifier: Topic :: Software Development :: Code Generators
36
+ Requires-Python: >=3.10
37
+ Provides-Extra: dev
38
+ Requires-Dist: build; extra == 'dev'
39
+ Requires-Dist: pytest>=7; extra == 'dev'
40
+ Requires-Dist: ruff>=0.6; extra == 'dev'
41
+ Description-Content-Type: text/markdown
42
+
43
+ # specced
44
+
45
+ Install a reusable, **interview-driven agentic coding setup** into any repo — one
46
+ command instead of copy-pasting `.claude/`, `.codex/`, `CONSTITUTION.md`, and the
47
+ proof-loop scaffolding between projects.
48
+
49
+ specced is two things sharing one set of templates:
50
+
51
+ - a **uv-installable CLI** that does the deterministic, agent-agnostic scaffolding, and
52
+ - a **Claude Code plugin** whose `specced-bootstrap` skill *interviews you* — detects
53
+ your stack, asks a few sharp questions, and writes the project-specific content.
54
+
55
+ ## What you get
56
+
57
+ specced installs three layers into a repo:
58
+
59
+ 1. **The engine** — the [`repo-task-proof-loop`](src/specced/templates/skills/repo-task-proof-loop)
60
+ skill (spec-freeze → build → evidence → fresh-verify → fix, with durable
61
+ `.agent/tasks/<ID>/` artifacts). Vendored from OpenAI, Apache-2.0 — see [NOTICE](NOTICE).
62
+ 2. **The structure** — four project agents (`.claude/agents/` + `.codex/agents/`),
63
+ managed blocks in `CLAUDE.md`/`AGENTS.md`, a Stop-hook formatter, skeletons for
64
+ `.claude/rules/`, `.claude/code-review/`, `.mcp.json`, and a `Makefile` verification
65
+ vocabulary — plus an **agent-experience layer**: a pre-authorized permission
66
+ allowlist, an orientation block, and a machine-readable checks map (`.specced/`).
67
+ 3. **The content** *(interview)* — your real `CONSTITUTION.md`, per-track rules,
68
+ review dimensions, MCP servers, and `make` targets — authored to fit *this* repo.
69
+
70
+ ## Install
71
+
72
+ ```bash
73
+ uv tool install specced # or: uvx --from git+https://github.com/NoroSaroyan/specced specced
74
+ ```
75
+
76
+ In Claude Code, add the marketplace and install the plugin:
77
+
78
+ ```
79
+ /plugin marketplace add NoroSaroyan/specced
80
+ /plugin install specced
81
+ ```
82
+
83
+ ## Quickstart
84
+
85
+ From inside the target repo, in Claude Code:
86
+
87
+ ```
88
+ /specced:init
89
+ ```
90
+
91
+ This runs the interview: it detects your stack, asks what matters, runs
92
+ `specced init` for the mechanics, then writes your constitution, rules, review
93
+ dimensions, MCP servers, and Makefile targets. Add `--minimal` to author all
94
+ content by hand.
95
+
96
+ Then start your first task with the installed engine:
97
+
98
+ ```
99
+ init my-first-task # via the repo-task-proof-loop skill
100
+ ```
101
+
102
+ ## Documentation
103
+
104
+ Full docs in [`docs/`](docs/index.md):
105
+ [Getting started](docs/getting-started.md) ·
106
+ [Concepts](docs/concepts.md) ·
107
+ [The proof loop](docs/proof-loop.md) ·
108
+ [CLI reference](docs/cli-reference.md) ·
109
+ [Skills](docs/skills.md) ·
110
+ [Presets](docs/presets.md) ·
111
+ [FAQ](docs/faq.md)
112
+
113
+ ## CLI reference
114
+
115
+ ```
116
+ specced detect Inspect the repo: languages, tracks, infra,
117
+ suggested preset + MCP servers (JSON).
118
+ specced presets List stack presets.
119
+ specced init [--preset NAME|auto] [--minimal] [--force] [--format-cmd "…"]
120
+ Install / refresh the setup (idempotent).
121
+ specced add-mcp <names…> [--force] Add MCP servers to .mcp.json from the catalog.
122
+ specced add-skill <name> [--force] Install a library skill into .claude/skills/.
123
+ specced list-skills List available library skills.
124
+ specced sync Refresh engine + agents + managed blocks.
125
+ specced doctor Verify the setup is consistent.
126
+ specced status Show installed components, presets, mcp catalog, config.
127
+ specced version Print specced + engine versions.
128
+ ```
129
+
130
+ **12 presets** (`go`, `rust`, `python-fastapi`, `python-django`, `python`,
131
+ `node-next`, `node-svelte`, `node-react`, `node-express`, `node`, `java-spring`,
132
+ `ruby-rails` — see [docs/presets.md](docs/presets.md)) and a **17-skill library**
133
+ (code-review, api-endpoint, db-migration, add-integration, background-worker,
134
+ regen-client, write-tests, debug-issue, refactor, dependency-upgrade,
135
+ perf-investigation, security-review, release, prepare-pr, new-domain-skill,
136
+ decision-record, capture-rule — see [docs/skills.md](docs/skills.md)).
137
+
138
+ Every command prints JSON, so the interview agent can read exactly what happened.
139
+ State is recorded in `.specced/config.json`.
140
+
141
+ ## How it works
142
+
143
+ The CLI is the mechanical half: it copies the vendored engine, installs the static
144
+ agent + managed-block templates verbatim (the same files the engine itself would
145
+ write), and lays down create-if-absent skeletons for the content layer. The plugin
146
+ is the intelligent half: the `specced-bootstrap` skill detects, interviews, calls
147
+ the CLI, then replaces the skeletons with real content. One template tree, two
148
+ surfaces.
149
+
150
+ ## Develop
151
+
152
+ ```bash
153
+ make install # uv venv + editable install with dev extras
154
+ make verify # ruff format --check + ruff check + pytest + build (the CI gate)
155
+ ```
156
+
157
+ See [CONTRIBUTING.md](CONTRIBUTING.md) and [docs/architecture.md](docs/architecture.md).
158
+
159
+ ## Status
160
+
161
+ v0.1 — interview-first, with stack detection, 12 presets, a 7-server MCP catalog, a
162
+ 17-skill library, an agent-experience layer, and GitHub repo-as-code (Terraform under
163
+ `infra/terraform/github/`). Roadmap: a `specced update` that diffs managed content
164
+ across versions, more presets/skills, and PyPI publication.
165
+
166
+ ## License
167
+
168
+ specced is MIT (see [LICENSE](LICENSE)). It bundles the Apache-2.0
169
+ `repo-task-proof-loop` engine unmodified; attribution in [NOTICE](NOTICE).
@@ -0,0 +1,127 @@
1
+ # specced
2
+
3
+ Install a reusable, **interview-driven agentic coding setup** into any repo — one
4
+ command instead of copy-pasting `.claude/`, `.codex/`, `CONSTITUTION.md`, and the
5
+ proof-loop scaffolding between projects.
6
+
7
+ specced is two things sharing one set of templates:
8
+
9
+ - a **uv-installable CLI** that does the deterministic, agent-agnostic scaffolding, and
10
+ - a **Claude Code plugin** whose `specced-bootstrap` skill *interviews you* — detects
11
+ your stack, asks a few sharp questions, and writes the project-specific content.
12
+
13
+ ## What you get
14
+
15
+ specced installs three layers into a repo:
16
+
17
+ 1. **The engine** — the [`repo-task-proof-loop`](src/specced/templates/skills/repo-task-proof-loop)
18
+ skill (spec-freeze → build → evidence → fresh-verify → fix, with durable
19
+ `.agent/tasks/<ID>/` artifacts). Vendored from OpenAI, Apache-2.0 — see [NOTICE](NOTICE).
20
+ 2. **The structure** — four project agents (`.claude/agents/` + `.codex/agents/`),
21
+ managed blocks in `CLAUDE.md`/`AGENTS.md`, a Stop-hook formatter, skeletons for
22
+ `.claude/rules/`, `.claude/code-review/`, `.mcp.json`, and a `Makefile` verification
23
+ vocabulary — plus an **agent-experience layer**: a pre-authorized permission
24
+ allowlist, an orientation block, and a machine-readable checks map (`.specced/`).
25
+ 3. **The content** *(interview)* — your real `CONSTITUTION.md`, per-track rules,
26
+ review dimensions, MCP servers, and `make` targets — authored to fit *this* repo.
27
+
28
+ ## Install
29
+
30
+ ```bash
31
+ uv tool install specced # or: uvx --from git+https://github.com/NoroSaroyan/specced specced
32
+ ```
33
+
34
+ In Claude Code, add the marketplace and install the plugin:
35
+
36
+ ```
37
+ /plugin marketplace add NoroSaroyan/specced
38
+ /plugin install specced
39
+ ```
40
+
41
+ ## Quickstart
42
+
43
+ From inside the target repo, in Claude Code:
44
+
45
+ ```
46
+ /specced:init
47
+ ```
48
+
49
+ This runs the interview: it detects your stack, asks what matters, runs
50
+ `specced init` for the mechanics, then writes your constitution, rules, review
51
+ dimensions, MCP servers, and Makefile targets. Add `--minimal` to author all
52
+ content by hand.
53
+
54
+ Then start your first task with the installed engine:
55
+
56
+ ```
57
+ init my-first-task # via the repo-task-proof-loop skill
58
+ ```
59
+
60
+ ## Documentation
61
+
62
+ Full docs in [`docs/`](docs/index.md):
63
+ [Getting started](docs/getting-started.md) ·
64
+ [Concepts](docs/concepts.md) ·
65
+ [The proof loop](docs/proof-loop.md) ·
66
+ [CLI reference](docs/cli-reference.md) ·
67
+ [Skills](docs/skills.md) ·
68
+ [Presets](docs/presets.md) ·
69
+ [FAQ](docs/faq.md)
70
+
71
+ ## CLI reference
72
+
73
+ ```
74
+ specced detect Inspect the repo: languages, tracks, infra,
75
+ suggested preset + MCP servers (JSON).
76
+ specced presets List stack presets.
77
+ specced init [--preset NAME|auto] [--minimal] [--force] [--format-cmd "…"]
78
+ Install / refresh the setup (idempotent).
79
+ specced add-mcp <names…> [--force] Add MCP servers to .mcp.json from the catalog.
80
+ specced add-skill <name> [--force] Install a library skill into .claude/skills/.
81
+ specced list-skills List available library skills.
82
+ specced sync Refresh engine + agents + managed blocks.
83
+ specced doctor Verify the setup is consistent.
84
+ specced status Show installed components, presets, mcp catalog, config.
85
+ specced version Print specced + engine versions.
86
+ ```
87
+
88
+ **12 presets** (`go`, `rust`, `python-fastapi`, `python-django`, `python`,
89
+ `node-next`, `node-svelte`, `node-react`, `node-express`, `node`, `java-spring`,
90
+ `ruby-rails` — see [docs/presets.md](docs/presets.md)) and a **17-skill library**
91
+ (code-review, api-endpoint, db-migration, add-integration, background-worker,
92
+ regen-client, write-tests, debug-issue, refactor, dependency-upgrade,
93
+ perf-investigation, security-review, release, prepare-pr, new-domain-skill,
94
+ decision-record, capture-rule — see [docs/skills.md](docs/skills.md)).
95
+
96
+ Every command prints JSON, so the interview agent can read exactly what happened.
97
+ State is recorded in `.specced/config.json`.
98
+
99
+ ## How it works
100
+
101
+ The CLI is the mechanical half: it copies the vendored engine, installs the static
102
+ agent + managed-block templates verbatim (the same files the engine itself would
103
+ write), and lays down create-if-absent skeletons for the content layer. The plugin
104
+ is the intelligent half: the `specced-bootstrap` skill detects, interviews, calls
105
+ the CLI, then replaces the skeletons with real content. One template tree, two
106
+ surfaces.
107
+
108
+ ## Develop
109
+
110
+ ```bash
111
+ make install # uv venv + editable install with dev extras
112
+ make verify # ruff format --check + ruff check + pytest + build (the CI gate)
113
+ ```
114
+
115
+ See [CONTRIBUTING.md](CONTRIBUTING.md) and [docs/architecture.md](docs/architecture.md).
116
+
117
+ ## Status
118
+
119
+ v0.1 — interview-first, with stack detection, 12 presets, a 7-server MCP catalog, a
120
+ 17-skill library, an agent-experience layer, and GitHub repo-as-code (Terraform under
121
+ `infra/terraform/github/`). Roadmap: a `specced update` that diffs managed content
122
+ across versions, more presets/skills, and PyPI publication.
123
+
124
+ ## License
125
+
126
+ specced is MIT (see [LICENSE](LICENSE)). It bundles the Apache-2.0
127
+ `repo-task-proof-loop` engine unmodified; attribution in [NOTICE](NOTICE).
@@ -0,0 +1,58 @@
1
+ [build-system]
2
+ requires = ["hatchling"]
3
+ build-backend = "hatchling.build"
4
+
5
+ [project]
6
+ name = "specced"
7
+ version = "0.1.0"
8
+ description = "Interview-driven bootstrap for a reusable agentic coding setup: proof-loop engine + project rules + skills, installed into any repo."
9
+ readme = "README.md"
10
+ requires-python = ">=3.10"
11
+ license = { file = "LICENSE" }
12
+ authors = [{ name = "Norik Saroyan", email = "noriksaroyan@gmail.com" }]
13
+ keywords = [
14
+ "claude-code",
15
+ "agentic",
16
+ "coding-agent",
17
+ "scaffold",
18
+ "proof-loop",
19
+ "spec-driven",
20
+ "codex",
21
+ ]
22
+ classifiers = [
23
+ "Development Status :: 3 - Alpha",
24
+ "Intended Audience :: Developers",
25
+ "Programming Language :: Python :: 3",
26
+ "Topic :: Software Development :: Code Generators",
27
+ ]
28
+
29
+ [project.scripts]
30
+ specced = "specced.cli:main"
31
+
32
+ [project.optional-dependencies]
33
+ dev = ["pytest>=7", "ruff>=0.6", "build"]
34
+
35
+ [project.urls]
36
+ Homepage = "https://github.com/NoroSaroyan/specced"
37
+ Issues = "https://github.com/NoroSaroyan/specced/issues"
38
+
39
+ [tool.hatch.build.targets.wheel]
40
+ packages = ["src/specced"]
41
+
42
+ [tool.hatch.build.targets.sdist]
43
+ include = ["/src", "/README.md", "/LICENSE", "/NOTICE"]
44
+
45
+ [tool.ruff]
46
+ line-length = 100
47
+ target-version = "py310"
48
+ # Never lint the bundled templates (they include the vendored engine + example code).
49
+ extend-exclude = ["src/specced/templates"]
50
+
51
+ [tool.ruff.lint]
52
+ select = ["E", "F", "I", "UP", "B"]
53
+ ignore = ["E501"] # line length is owned by the formatter
54
+
55
+ [tool.pytest.ini_options]
56
+ pythonpath = ["src"]
57
+ testpaths = ["tests"]
58
+ addopts = "-q"
@@ -0,0 +1,11 @@
1
+ """specced — install a reusable, interview-driven agentic coding setup into any repo.
2
+
3
+ The Python package is the *deterministic* half of specced: it scaffolds the
4
+ proof-loop engine, project-scoped agents, managed guide blocks, and the
5
+ Layer-2 structure (constitution, rules, code-review, mcp, Makefile vocabulary).
6
+
7
+ The *intelligent* half — the interview that fills in project-specific content —
8
+ lives in the Claude Code plugin under ``plugin/`` and drives this CLI.
9
+ """
10
+
11
+ __version__ = "0.1.0"
@@ -0,0 +1,11 @@
1
+ """Resource-path resolution shared by scaffold and detect (avoids an import cycle)."""
2
+
3
+ from __future__ import annotations
4
+
5
+ from importlib.resources import files
6
+ from pathlib import Path
7
+
8
+
9
+ def templates_dir() -> Path:
10
+ """Path to the bundled templates directory (works for editable + wheel)."""
11
+ return Path(str(files("specced"))) / "templates"
@@ -0,0 +1,178 @@
1
+ """specced command-line interface.
2
+
3
+ Thin wrapper over :mod:`specced.scaffold`. Every command prints a JSON result to
4
+ stdout so the interview agent (or a human) can read exactly what happened.
5
+ """
6
+
7
+ from __future__ import annotations
8
+
9
+ import argparse
10
+ import json
11
+ from pathlib import Path
12
+ from typing import Any
13
+
14
+ from . import scaffold
15
+
16
+
17
+ def _repo_root(args: argparse.Namespace) -> Path:
18
+ start = Path(args.repo_root).resolve() if args.repo_root else Path.cwd()
19
+ return scaffold.discover_repo_root(start)
20
+
21
+
22
+ def _emit(payload: dict[str, Any]) -> None:
23
+ print(json.dumps(payload, indent=2))
24
+
25
+
26
+ def cmd_init(args: argparse.Namespace) -> int:
27
+ _emit(
28
+ scaffold.init_repo(
29
+ _repo_root(args),
30
+ minimal=args.minimal,
31
+ force=args.force,
32
+ format_cmd=args.format_cmd,
33
+ preset=args.preset,
34
+ )
35
+ )
36
+ return 0
37
+
38
+
39
+ def cmd_detect(args: argparse.Namespace) -> int:
40
+ _emit(scaffold.detect_repo(_repo_root(args)))
41
+ return 0
42
+
43
+
44
+ def cmd_presets(args: argparse.Namespace) -> int:
45
+ _emit({"presets": scaffold.list_presets()})
46
+ return 0
47
+
48
+
49
+ def cmd_add_mcp(args: argparse.Namespace) -> int:
50
+ result = scaffold.compose_mcp(_repo_root(args), args.names, force=args.force)
51
+ _emit(result)
52
+ return 1 if result["unknown"] else 0
53
+
54
+
55
+ def cmd_add_skill(args: argparse.Namespace) -> int:
56
+ result = scaffold.add_skill(_repo_root(args), args.name, force=args.force)
57
+ _emit(result)
58
+ return 0 if result.get("ok") else 1
59
+
60
+
61
+ def cmd_list_skills(args: argparse.Namespace) -> int:
62
+ _emit({"library_skills": scaffold.list_library_skills()})
63
+ return 0
64
+
65
+
66
+ def cmd_sync(args: argparse.Namespace) -> int:
67
+ _emit(scaffold.sync(_repo_root(args)))
68
+ return 0
69
+
70
+
71
+ def cmd_doctor(args: argparse.Namespace) -> int:
72
+ result = scaffold.doctor(_repo_root(args))
73
+ _emit(result)
74
+ return 0 if result["ok"] else 1
75
+
76
+
77
+ def cmd_status(args: argparse.Namespace) -> int:
78
+ _emit(scaffold.status(_repo_root(args)))
79
+ return 0
80
+
81
+
82
+ def cmd_version(args: argparse.Namespace) -> int:
83
+ _emit({"specced": scaffold.SPECCED_VERSION, "engine": scaffold.engine_version()})
84
+ return 0
85
+
86
+
87
+ def build_parser() -> argparse.ArgumentParser:
88
+ parser = argparse.ArgumentParser(
89
+ prog="specced",
90
+ description="Install and manage the specced agentic coding setup in a repo.",
91
+ )
92
+
93
+ common = argparse.ArgumentParser(add_help=False)
94
+ common.add_argument(
95
+ "--repo-root",
96
+ default=None,
97
+ help="Path inside the target repo. Defaults to the current directory.",
98
+ )
99
+
100
+ sub = parser.add_subparsers(dest="command", required=True)
101
+
102
+ p_init = sub.add_parser(
103
+ "init", parents=[common], help="Install the setup into the repo (idempotent)."
104
+ )
105
+ p_init.add_argument(
106
+ "--preset",
107
+ default=None,
108
+ help="Stack preset name, or 'auto' to detect (see: specced presets).",
109
+ )
110
+ p_init.add_argument(
111
+ "--minimal",
112
+ action="store_true",
113
+ help="Install only the engine, agents, managed blocks, and config "
114
+ "(skip Layer-2 content files so the interview can author them).",
115
+ )
116
+ p_init.add_argument("--force", action="store_true", help="Overwrite existing files.")
117
+ p_init.add_argument(
118
+ "--format-cmd",
119
+ default=None,
120
+ help="Format+lint command for the Stop hook (default: 'make fmt lint').",
121
+ )
122
+ p_init.set_defaults(func=cmd_init)
123
+
124
+ p_detect = sub.add_parser(
125
+ "detect", parents=[common], help="Inspect the repo and report stack signals (JSON)."
126
+ )
127
+ p_detect.set_defaults(func=cmd_detect)
128
+
129
+ p_presets = sub.add_parser("presets", help="List available stack presets.")
130
+ p_presets.set_defaults(func=cmd_presets)
131
+
132
+ p_mcp = sub.add_parser(
133
+ "add-mcp", parents=[common], help="Add MCP servers to .mcp.json from the catalog."
134
+ )
135
+ p_mcp.add_argument(
136
+ "names", nargs="+", help="Server names (see 'mcp_catalog' in: specced status)."
137
+ )
138
+ p_mcp.add_argument("--force", action="store_true", help="Overwrite an existing server entry.")
139
+ p_mcp.set_defaults(func=cmd_add_mcp)
140
+
141
+ p_add = sub.add_parser(
142
+ "add-skill", parents=[common], help="Install a domain skill from the library."
143
+ )
144
+ p_add.add_argument("name", help="Library skill name (see: specced list-skills).")
145
+ p_add.add_argument("--force", action="store_true", help="Replace if already present.")
146
+ p_add.set_defaults(func=cmd_add_skill)
147
+
148
+ p_list = sub.add_parser("list-skills", help="List available library skills.")
149
+ p_list.set_defaults(func=cmd_list_skills)
150
+
151
+ p_sync = sub.add_parser(
152
+ "sync",
153
+ parents=[common],
154
+ help="Refresh engine + agents + managed blocks to this specced version.",
155
+ )
156
+ p_sync.set_defaults(func=cmd_sync)
157
+
158
+ p_doctor = sub.add_parser("doctor", parents=[common], help="Verify the setup is consistent.")
159
+ p_doctor.set_defaults(func=cmd_doctor)
160
+
161
+ p_status = sub.add_parser(
162
+ "status", parents=[common], help="Show installed components and config."
163
+ )
164
+ p_status.set_defaults(func=cmd_status)
165
+
166
+ p_version = sub.add_parser("version", help="Print specced and engine versions.")
167
+ p_version.set_defaults(func=cmd_version)
168
+
169
+ return parser
170
+
171
+
172
+ def main(argv: list[str] | None = None) -> int:
173
+ args = build_parser().parse_args(argv)
174
+ return int(args.func(args))
175
+
176
+
177
+ if __name__ == "__main__":
178
+ raise SystemExit(main())