Skip to main content

Requirements validation and traceability tools - L-Space connects all libraries

Project description

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 validate

# 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

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

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"
type = "core"

[directories]
spec = "spec"
code = ["src"]

[patterns]
prefix = "REQ"
id_template = "{prefix}-{type}{id}"

[rules.hierarchy]
allowed_implements = ["dev -> ops, prd", "ops -> prd"]

[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 validate --mode combined

CLI Commands

elspais validate       Validate requirements format, links, and hashes
elspais fix            Auto-fix spec file issues (hashes, formatting)
elspais trace          Generate traceability matrix (markdown, html, csv)
elspais viewer         Start interactive viewer server
elspais health         Check repository and configuration health
elspais doctor         Diagnose environment and installation health
elspais analyze        Analyze hierarchy, orphans, or coverage
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 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.

Links

Project details


Download files

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

Source Distribution

elspais-0.114.49.tar.gz (1.2 MB view details)

Uploaded Source

Built Distribution

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

elspais-0.114.49-py3-none-any.whl (619.1 kB view details)

Uploaded Python 3

File details

Details for the file elspais-0.114.49.tar.gz.

File metadata

  • Download URL: elspais-0.114.49.tar.gz
  • Upload date:
  • Size: 1.2 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.13

File hashes

Hashes for elspais-0.114.49.tar.gz
Algorithm Hash digest
SHA256 4c8297e0f0f7de83d2be29195cb2d241b141c07e0e6e7dfdbe3c6360f1dae2db
MD5 9b95d1ebfa63a0987a1c367c54f28db3
BLAKE2b-256 e897dcc31e2dd0993207637363498874f8b97d2105e504e443008adf7fc99a4c

See more details on using hashes here.

File details

Details for the file elspais-0.114.49-py3-none-any.whl.

File metadata

  • Download URL: elspais-0.114.49-py3-none-any.whl
  • Upload date:
  • Size: 619.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.13

File hashes

Hashes for elspais-0.114.49-py3-none-any.whl
Algorithm Hash digest
SHA256 caf08a82cdc240474eec1f843c9285f107e9d27e69f2a5949567efad33c5e4d2
MD5 030903ae689e0f843de63a8a71155ef6
BLAKE2b-256 ddd03c6c2bd8c3969b019850a9e4ffafac58f09240fef6acca4ff0d1995a592c

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page