Skip to main content

spec-init

PyPI version Python versions MIT License

Throughspec - spec-driven, drift-proof, token-lean scaffolding for Claude Code. spec-init bootstraps a project around a deterministic, spec-first SDLC: you make the decisions, Claude does the heavy lifting, and a fixed structure keeps the work from drifting.

The same CLI ships on PyPI (this package) and npm from one source-of-truth template tree, verified byte-for-byte.

Install

# recommended (isolated)
pipx install spec-init
spec-init my-project

# or regular pip
pip install spec-init
spec-init my-project

Requires Python ≥ 3.10.

Quickstart

# scaffold, then open in Claude Code and run /spec-requirements
spec-init my-project
cd my-project

Run with no arguments in a terminal for an interactive welcome (new-vs-existing, persona, integrations). In a non-interactive shell (CI, pipes) it prints help instead, so scripts are unaffected.

spec-init <name> scaffolds the canonical Throughspec tree:

my-project/
├── CLAUDE.md
├── README.md
├── CHANGELOG.md
├── SECURITY.md
├── CONTRIBUTING.md
├── claude/
│   ├── srs.md
│   ├── plan.md
│   ├── context.md
│   ├── features.md
│   ├── design-decisions.md
│   └── learnings.md
├── design/
│   └── design.md
├── .claude/
│   ├── skills/
│   └── agents/
└── .spec-init/base/    # pristine snapshot for upgrade

Commands

Command Purpose
spec-init With no args on a terminal, launch the interactive welcome
spec-init init <name> Scaffold a new project into <name>/
spec-init reinit [dir] Adopt Throughspec in an existing project in place (non-destructive)
spec-init customize --add / --remove <name> Toggle an integration in an existing project
spec-init customize --persona <name> Swap the CLAUDE.md persona block
spec-init add-skill <name> Copy one skill from the payload catalog into .claude/skills/
spec-init upgrade Three-way-merge a newer template payload into an existing project
spec-init doctor Verify a scaffolded project's shape

Flags

  • --persona vibe|student|engineer|team - which CLAUDE.md persona block to keep.
  • --integrations <csv> - activate integrations at scaffold time (see below).
  • --force - overwrite an existing directory (init) or replace existing spec files (reinit).
  • --dry-run - print the plan without writing files.
  • -h, --help / -v, --version.

Integrations

Opt-in, free/open-source tools layered in without touching your source. Add at scaffold time (--integrations graphify,caveman) or later (spec-init customize --add obsidian); remove with customize --remove <name>.

graphify, obsidian, caveman, agentmemory, openwiki, ponytail, opencodereview.

See the Integrations docs for what each does.

Both channels produce byte-identical scaffolded trees for every persona/integration combination, enforced by a cross-language parity test.

The .spec-init/base/ snapshot

init writes a pristine copy of the payload into <project>/.spec-init/base/. upgrade uses it as the common ancestor for its three-way merge; doctor checks it exists. Don't edit files under .spec-init/ - they are the CLI's private state.

Links

License

MIT © Vishal Patil

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

spec_init-1.2.0.tar.gz (81.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

spec_init-1.2.0-py3-none-any.whl (120.2 kB view details)

Uploaded Python 3

File details

Details for the file spec_init-1.2.0.tar.gz.

File metadata

  • Download URL: spec_init-1.2.0.tar.gz
  • Upload date:
  • Size: 81.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.32 {"installer":{"name":"uv","version":"0.11.32","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for spec_init-1.2.0.tar.gz
Algorithm Hash digest
SHA256 b4b6000cbc543cba39e277772844c7c8da6cf1bbf5783e28708d6cc9916805c4
MD5 01712207dad122dff588c86542c09534
BLAKE2b-256 6a11883c8c36a29e444633f09e1cb517912481135ed836fde0d9fa8f68cb44ae

See more details on using hashes here.

File details

Details for the file spec_init-1.2.0-py3-none-any.whl.

File metadata

  • Download URL: spec_init-1.2.0-py3-none-any.whl
  • Upload date:
  • Size: 120.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.32 {"installer":{"name":"uv","version":"0.11.32","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for spec_init-1.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 80e0e5e993f3f18fff8cd2b1c49c97a032d942061aa4cdabd14728d794f45004
MD5 f1dff2778933158f4220529f660aa8d6
BLAKE2b-256 09120191d547d63a4b6764d8e05b8d63376380b7368924f381f4975211022694

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

1.2.0 This release

2 files

1.1.0

2 files

1.0.0

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page