Skip to main content

elspais

"L-Space is the ultimate library, connecting all libraries everywhere through the sheer weight of accumulated knowledge." — Terry Pratchett

elspais is a requirements validation and traceability tool for teams managing formal requirements across one or more repositories. It validates requirement formats, enforces hierarchy rules, tracks changes with content hashes, and generates traceability matrices linking requirements to code and tests.

Installation

# Homebrew (macOS/Linux)
brew install anspar-org/anspar/elspais

# pipx (isolated install)
pipx install elspais

# pip
pip install elspais

Optional extras

pip install elspais[trace-view]    # Static HTML traceability view
pip install elspais[trace-review]  # Interactive viewer server
pip install elspais[mcp]           # MCP server for AI integration
pip install elspais[all]           # Everything

Quick Start

# Initialize configuration
elspais init

# Validate requirements
elspais checks

# Auto-fix hashes and formatting
elspais fix

# Generate traceability matrix
elspais trace --format html

# Interactive viewer (live server)
elspais viewer

# Built-in documentation
elspais docs

MCP Server (AI Integration)

elspais includes an MCP server for use with Claude Code, Claude Desktop, and other MCP-compatible clients.

# Install the MCP extra
pip install elspais[mcp]

# Register with Claude Code (all projects) and Claude Desktop
elspais mcp install --global --desktop

# Each shell supplies the daemon's address before launching the client
eval "$(elspais mcp env)"

The MCP server provides tools for searching requirements, navigating hierarchies, checking coverage, and drafting mutations — all operating on the live traceability graph.

Mutations use optimistic concurrency: several writers (agents and the viewer GUI) can share one daemon, so every mutation requires a version token from a prior read and stale writes are rejected rather than silently overwriting. See elspais docs concurrency for the protocol.

Requirement Format

Requirements are written in Markdown:

# REQ-d00001: Requirement Title

**Level**: Dev | **Status**: Active | **Implements**: REQ-p00001

## Assertions

A. The system SHALL provide user authentication via email/password.
B. Sessions SHALL expire after 30 minutes of inactivity.

*End* *Requirement Title* | **Hash**: a1b2c3d4
---
  • Hierarchy: PRD (product) → OPS (operations) → DEV (development)
  • Traceability: Children reference parents via Implements:
  • Assertions: Labeled A-Z, using SHALL for normative statements
  • Hash footer: SHA-256 content hash for change detection

Configuration

Create .elspais.toml in your repository root (or run elspais init):

[project]
name = "my-project"
namespace = "REQ"

[levels.prd]
rank = 1
letter = "p"
implements = ["prd"]

[levels.ops]
rank = 2
letter = "o"
implements = ["ops", "prd"]

[levels.dev]
rank = 3
letter = "d"
implements = ["dev", "ops", "prd"]

[scanning.spec]
directories = ["spec"]

[scanning.code]
directories = ["src"]

[id-patterns]
canonical = "{namespace}-{level.letter}{component}"

[rules.format]
require_hash = true
require_assertions = true

See docs/configuration.md for full reference.

Multi-Repository Support

Link associated repositories that extend a core requirement set:

elspais init --type associated --associated-prefix CAL
elspais associate ../core-repo
elspais checks

CLI Commands

elspais checks         Verify requirements traceability and configuration
elspais fix            Auto-fix spec file issues (hashes, formatting)
elspais trace          Generate traceability matrix (markdown, html, csv)
elspais viewer         Start interactive viewer server
elspais doctor         Diagnose environment and installation health
elspais analysis       Analyze foundational requirement importance
elspais changed        Detect git changes to spec files
elspais edit           Edit requirements in-place
elspais config         View and modify configuration
elspais associate      Manage associate repository links
elspais link suggest   Suggest requirement links for unlinked tests
elspais pdf            Compile spec files into PDF
elspais mcp            MCP server commands
elspais docs           Built-in user guide
elspais example        Requirement format examples

Run elspais <command> --help for detailed usage. See src/elspais/docs/cli/commands.md for full documentation.

Development

git clone https://github.com/anspar/elspais.git
cd elspais
pip install -e ".[dev]"
pytest

License

GNU Affero General Public License v3 (AGPL-3.0) — see LICENSE.

Metadata

Release files for elspais 0.123.3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for elspais 0.123.3
File Size Uploaded
elspais-0.123.3.tar.gz 2.4 MB Details

Built distribution (wheel)

Table of built distributions (wheels) for elspais 0.123.3
File Interpreter ABI Platform
elspais-0.123.3-py3-none-any.whl Python 3 none any Details

Total release size: 3.5 MB

Release files / elspais-0.123.3.tar.gz

Download URL elspais-0.123.3.tar.gz
Size 2.4 MB
Tags Source
SHA-256 checksum
How to use checksums
12947db913e7bec31cce9e25f7396d468cc0f8c95785929bd8e005847b527b05
BLAKE2b-256 checksum
How to use checksums
0d94de2ce8fe2070a007f7c73cbda3649a0f9fc456fe979697e6414f8bda5a52
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.14

Release files / elspais-0.123.3-py3-none-any.whl

Download URL elspais-0.123.3-py3-none-any.whl
Size 1.1 MB
Tags Python 3
SHA-256 checksum
How to use checksums
4b9ec86938706589e1548712075e52803536abc133c2c6f294a9c7ef1e893c46
BLAKE2b-256 checksum
How to use checksums
ed35e0b5fbbe4937d099efc03364dd952fa8ca7c70fe70839b38651c1b1ca443
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.14

Release history Release notifications | RSS feed

This release

0.123.3 This release

2 release files

0.84.2

2 release files

0.84.1

2 release files

0.84.0

2 release files

0.82.1

2 release files

0.82.0

2 release files

0.81.0

2 release files

0.80.0

2 release files

0.79.0

2 release files

0.76.1

2 release files

0.76.0

2 release files

0.75.0

2 release files

0.74.0

2 release files

0.73.2

2 release files

0.73.1

2 release files

0.73.0

2 release files

0.72.0

2 release files

0.66.0

2 release files

0.65.0

2 release files

0.64.1

2 release files

0.64.0

2 release files

0.63.3

2 release files

0.59.0

2 release files

0.58.0

2 release files

0.57.0

2 release files

0.56.1

2 release files

0.54.1

2 release files

0.54.0

2 release files

0.11.2

2 release files

0.11.1

2 release files

0.11.0

2 release files

0.9.3

2 release files

0.9.1

2 release 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