Spec-driven story coordination for humans and AI agents — MCP server + web dashboard over plain markdown.
Project description
diatagma
Spec-driven story coordination for humans and AI agents.
Markdown spec files are the source of truth. Diatagma provides an MCP server for AI agents and a web dashboard for humans — both read and write the same plain markdown files with YAML frontmatter.
Features
- Spec-driven workflow — write spec → derive tests from behavior → implement → verify
- Plain markdown specs — prefixed, numbered files in a
.tasks/directory with structured YAML frontmatter - Typed file extensions —
.story.md,.epic.md,.spike.mdfor instant identification - MCP server — AI agents create, query, claim, and update stories via typed tools
- Web dashboard — kanban board, filterable list, dependency graph, inline editing (React + Litestar)
- Dependency DAG — networkx-powered blocking/unblocking with cycle detection
- Priority scoring — WSJF-style composite ranking (business value, story points, blockers, age, due dates)
- No database — filesystem is the source of truth, SQLite is just a read cache
- Changelog — append-only audit trail of all mutations with agent attribution
- ADR + research docs — architectural decisions and spike findings as traceable knowledge
- Configurable — templates, schemas, priority weights, sprints, lifecycle hooks
Quick Start
# Install
uv add diatagma
# Initialize a .tasks/ directory in your project
diatagma init
# Start the web dashboard
diatagma serve
# Start the MCP server (for AI agent integration)
diatagma mcp
Spec File Format
---
id: CORE-042
title: "Implement retry logic for API calls"
status: in-progress
type: feature
tags: [api, resilience]
business_value: 300
story_points: 5
parent: CORE-040
sprint: "Sprint 3"
assignee: claude-agent-abc
due_date: 2026-04-15
dependencies: [CORE-041]
created: 2026-03-27
---
## Description
Add exponential backoff retry logic to all external API calls.
## Context
Production incidents showed cascading failures when upstream APIs had transient errors.
See [ADR-005](docs/adr/005-retry-strategy.md) for the chosen approach.
## Behavior
### Scenario: Transient API failure recovers
- **Given** an external API call that fails with a 503
- **When** the retry logic is triggered
- **Then** it retries up to 3 times with exponential backoff and jitter
### Scenario: Persistent failure trips circuit breaker
- **Given** 5 consecutive API failures
- **When** the next call is attempted
- **Then** the circuit breaker opens and fails fast for 30 seconds
## Constraints
- Max 3 retries with jitter
- Circuit breaker timeout: 30s
## Verification
- [ ] All external API calls use retry with exponential backoff
- [ ] Circuit breaker opens after 5 consecutive failures
- [ ] Retry metrics exposed via logging
## References
- [ADR-005: Retry Strategy](docs/adr/005-retry-strategy.md)
- [Research: Circuit Breaker Patterns](docs/research/260320_circuit-breaker-patterns.md)
## Implementation Notes
Directory Structure
.tasks/
├── .gitignore # Always ignores .cache/
├── .cache/ # SQLite read cache (gitignored)
├── config/
│ ├── settings.yaml # Tool behavior settings
│ ├── prefixes.yaml # Prefix definitions
│ ├── schema.yaml # Frontmatter validation rules
│ ├── priority.yaml # WSJF scoring weights
│ ├── sprints.yaml # Sprint boundaries
│ ├── hooks.yaml # Lifecycle hooks
│ └── templates/
│ ├── story.md # Story body template
│ ├── epic.md # Epic body template
│ └── spike.md # Spike/research template
├── roadmap.md # Phased roadmap with narrative
├── changelog.md # Append-only mutation log
├── backlog/ # Not yet scheduled
├── archive/ # Completed/cancelled
├── CORE-042-retry-logic.story.md
├── CORE-040-api-hardening.epic.md
└── ...
docs/
├── spec.md # Product specification
├── architecture.md # System architecture + diagrams
├── adr/ # Architecture Decision Records
│ ├── 001-slug.md
│ └── template.md
└── research/ # Date-prefixed research docs
└── YYMMDD_slug.md
License
Apache 2.0
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file diatagma-0.1.0.tar.gz.
File metadata
- Download URL: diatagma-0.1.0.tar.gz
- Upload date:
- Size: 265.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6845f58c8a8044b65490f3d11cad0a69c1701de5f7206a7f9774e9af45454b68
|
|
| MD5 |
41a88f67a913bf932a5aa6279fb0db51
|
|
| BLAKE2b-256 |
e00f07d7ab1eecfbcbfabdb6051ae4ba9f633bc5191c58a07b565cf5387038d6
|
Provenance
The following attestation bundles were made for diatagma-0.1.0.tar.gz:
Publisher:
release.yml on SerPeter/diatagma
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
diatagma-0.1.0.tar.gz -
Subject digest:
6845f58c8a8044b65490f3d11cad0a69c1701de5f7206a7f9774e9af45454b68 - Sigstore transparency entry: 1553160308
- Sigstore integration time:
-
Permalink:
SerPeter/diatagma@e80ff13c0f34568b94e211989de52ec821e5cc91 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/SerPeter
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@e80ff13c0f34568b94e211989de52ec821e5cc91 -
Trigger Event:
workflow_dispatch
-
Statement type:
File details
Details for the file diatagma-0.1.0-py3-none-any.whl.
File metadata
- Download URL: diatagma-0.1.0-py3-none-any.whl
- Upload date:
- Size: 77.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
82c24ce9f471e9ee55da5142ed49a0bbd867cd19c5caf825269aff05f6566948
|
|
| MD5 |
39ee5f978233d1b9c45a5c26ef16c075
|
|
| BLAKE2b-256 |
683bc9d5577dfa8484827253ceb67717efbd45704668e7b5e4a8e1e352485e48
|
Provenance
The following attestation bundles were made for diatagma-0.1.0-py3-none-any.whl:
Publisher:
release.yml on SerPeter/diatagma
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
diatagma-0.1.0-py3-none-any.whl -
Subject digest:
82c24ce9f471e9ee55da5142ed49a0bbd867cd19c5caf825269aff05f6566948 - Sigstore transparency entry: 1553160315
- Sigstore integration time:
-
Permalink:
SerPeter/diatagma@e80ff13c0f34568b94e211989de52ec821e5cc91 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/SerPeter
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@e80ff13c0f34568b94e211989de52ec821e5cc91 -
Trigger Event:
workflow_dispatch
-
Statement type: