Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
61 changes: 60 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -320,10 +320,12 @@ Our research and experimentation focus on:
## 🔧 Prerequisites

- **Linux/macOS/Windows**
- [Supported](#-supported-ai-agents) AI coding agent.
- [Supported](#-supported-ai-agents) AI coding agent
- [uv](https://docs.astral.sh/uv/) for package management
- [Python 3.11+](https://www.python.org/downloads/)
- [Git](https://git-scm.com/downloads)
- **[Rust and cargo](https://rustup.rs/)** - Required for ontology-driven code generation
- **[ggen](https://crates.io/crates/ggen)** - Transform RDF ontologies into typed code (`cargo install ggen`)

If you encounter issues with an agent, please open an issue so we can refine the integration.

Expand All @@ -332,6 +334,63 @@ If you encounter issues with an agent, please open an issue so we can refine the
- **[Complete Spec-Driven Development Methodology](./spec-driven.md)** - Deep dive into the full process
- **[Detailed Walkthrough](#-detailed-process)** - Step-by-step implementation guide

## 🧬 Ontology as Source Code

Your domain ontology in RDF is the authoritative source. [ggen](https://crates.io/crates/ggen) compiles it into type-safe implementations across any language.

### Ontology-Driven Development

Software systems are defined in RDF ontologies and compiled into executable code:

- **Single Source of Truth**: RDF ontology defines your domain model
- **Deterministic Compilation**: Same ontology → identical code, always
- **Semantic Inference**: SPARQL materializes implicit knowledge
- **Multi-language Native**: One ontology → Python, TypeScript, Rust, Java, C#, Go
- **Machine + Human Readable**: Both compilers and domain experts understand RDF

### Quick Setup

1. Install Rust and cargo:
```bash
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
```

2. Install ggen:
```bash
cargo install ggen
```

3. Initialize ggen in your project:
```bash
# From your spec-kit project root
cp templates/ggen.toml .
cp -r templates/schema .
cp -r templates/ggen .
```

4. Compile your ontology:
```bash
ggen sync
```

### The Development Workflow

Software is built with Spec-Kit through this process:

1. **Specify** (`/speckit.specify`) - Capture requirements and user stories
2. **Model** - Formalize domain knowledge in RDF ontology (compile target)
3. **Plan** (`/speckit.plan`) - Choose architecture and target runtimes
4. **Compile** - Run `ggen sync` to generate type systems for all targets
5. **Tasks** (`/speckit.tasks`) - Break down business logic implementation
6. **Implement** (`/speckit.implement`) - Write logic against generated types
7. **Evolve** - Modify ontology, recompile, types update automatically

**The ontology is your source code. Generated classes are build artifacts.**

When your domain understanding changes, you update the ontology and recompile. Types update automatically across all target languages.

See the [ggen documentation](./templates/ggen/README.md) organized by the [Diátaxis framework](https://diataxis.fr/).

---

## 📋 Detailed Process
Expand Down
Loading