Crucible
Architecture-first development framework for AI-native applications
Crucible helps teams maintain architectural integrity through formal architecture definitions, automated validation, and seamless Claude Code integration.
Installation
Option 1: Using cargo-binstall (Recommended - Fast)
If you have cargo-binstall installed:
This downloads prebuilt binaries from GitHub releases, making installation much faster than compiling from source.
Don't have cargo-binstall? Install it with:
Option 2: From crates.io (Standard)
This compiles from source and may take a few minutes.
Option 3: From GitHub (Latest Development)
This installs the latest unreleased version from the main branch.
Verify Installation
Quick Start
# Create a new project with architecture
# Or initialize in an existing project
# Reinitialize existing project (requires confirmation)
# Validate architecture
# Initialize Claude Code integration (optional - init does this automatically)
Claude Code Integration
Crucible includes 8 native slash commands for Claude Code, automatically generated on crucible init:
Essential Commands:
/crucible:validate- Run architecture validation with actionable fixes/crucible:architecture- Design architecture for new features (architecture-first TDD)/crucible:init- Initialize Crucible in current project
Module Management:
/crucible:module- Create or update module definitions interactively/crucible:review- Comprehensive architecture review with health scoring
Sync & Analysis:
/crucible:sync- Sync architecture ↔ code bidirectionally/crucible:analyze- Deep dive into module dependencies and usage/crucible:diff- Show git-style differences between architecture and code
Example Workflow
# 1. Initialize project (auto-creates slash commands)
# 2. In Claude Code, design architecture
# 3. Write tests (TDD approach)
# [Write failing tests based on architecture]
# 4. Implement feature
# [Implement to make tests pass]
# 5. Validate compliance
# 6. Keep architecture in sync
See docs/CLAUDE_CODE_INTEGRATION.md for complete documentation.
Project Structure
.crucible/- Crucible's own architecture definitioncrucible-core/- Core library implementationcrucible-cli/- Command-line interfacespec/- Specification documents
Development
This project uses Crucible to define its own architecture. Before making changes:
- Update
crucible-core/.crucible/definitions - Validate:
crucible validate --path crucible-core/.crucible --strict - Implement changes
- Run tests:
cargo test --all
Pre-push Checks
Before pushing to main, run all CI checks locally:
This runs:
- Code formatting check (
cargo fmt) - Clippy lints (
cargo clippy) - Release build
- Architecture validation
- All tests
- Documentation check
See scripts/README.md for setup as a Git hook.
License
Crucible uses dual licensing:
-
Specification (
spec/): CC0 1.0 Universal (Public Domain) The Crucible specification, schema, and examples are freely available for anyone to implement. -
Implementation (
crucible-core/,crucible-cli/): Apache License 2.0 The Rust implementation code is licensed under Apache 2.0.
See spec/LICENSING.md for detailed licensing information.