Skip to content

codervisor/lean-spec

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

LeanSpec

LeanSpec Logo

CI Status npm version npm downloads License

Documentation中文文档Live ExamplesTutorials


Ship faster with higher quality. Lean specs that both humans and AI understand.

LeanSpec brings agile principles to SDD (Spec-Driven Development)—small, focused documents (<2,000 tokens) that keep you and your AI aligned.


Quick Start

# Try with a tutorial project
npx lean-spec init --example dark-theme
cd dark-theme && npm install && npm start

# Or add to your existing project
npm install -g lean-spec && lean-spec init

Visualize your project:

lean-spec board    # Kanban view
lean-spec stats    # Project metrics
lean-spec ui       # Web UI at localhost:3000

Next: Your First Spec with AI (10 min tutorial)


Why LeanSpec?

High velocity + High quality. Other SDD frameworks add process overhead (multi-step workflows, rigid templates). Vibe coding is fast but chaotic (no shared understanding). LeanSpec hits the sweet spot:

  • Fast iteration - Living documents that grow with your code
  • AI performance - Small specs = better AI output (context rot is real)
  • Always current - Lightweight enough that you actually update them

📖 Compare with Spec Kit, OpenSpec, Kiro →


AI Integration

Works with any AI coding assistant via MCP or CLI:

{
  "mcpServers": {
    "lean-spec": { "command": "npx", "args": ["@leanspec/mcp"] }
  }
}

Compatible with: VS Code Copilot, Cursor, Windsurf, Claude Code, Gemini CLI, and more.

📖 Full AI integration guide →


Features

Feature Description
📊 Kanban Board lean-spec board - visual project tracking
🔍 Smart Search lean-spec search - find specs by content or metadata
🔗 Dependencies Track spec relationships with depends_on and related
🎨 Web UI lean-spec ui - browser-based dashboard
📈 Project Stats lean-spec stats - health metrics and bottleneck detection
🤖 AI-Native MCP server + CLI for AI assistants
🖥️ Desktop App Native Tauri shell with tray + shortcuts (pnpm dev:desktop)

Kanban Board View


Desktop App

The new @leanspec/desktop package wraps the Next.js UI in a lightweight Tauri shell for local, multi-project workflows:

# Launch the desktop shell with hot reload
pnpm install
pnpm dev:desktop

# Produce signed installers + embedded UI bundle
pnpm build:desktop

Key capabilities:

  • Frameless window with custom title bar + native controls
  • Global shortcuts (Cmd/Ctrl+Shift+L to toggle, Cmd/Ctrl+Shift+K to open the project switcher, Cmd/Ctrl+Shift+N to add a spec)
  • Shared project registry + native folder picker backed by ~/.lean-spec/projects.json
  • System tray with recent projects, background notifications, and update checks
  • Embedded Next.js standalone build for offline packaging (macOS .dmg, Windows .msi/.exe, Linux .AppImage/.deb/.rpm)

See packages/desktop/README.md for configuration details.


Developer Workflow

Common development tasks using pnpm:

# Development
pnpm install             # Install dependencies
pnpm build               # Build all packages
pnpm dev                 # Start dev mode (UI + Core)
pnpm dev:web             # UI only
pnpm dev:cli             # CLI only
pnpm dev:desktop         # Desktop app

# Testing
pnpm test                # Run all tests
pnpm test:ui             # Tests with UI
pnpm test:coverage       # Coverage report
pnpm typecheck           # Type check all packages

# Rust
pnpm rust:build          # Build Rust packages (release)
pnpm rust:build:dev      # Build Rust (dev, faster)
pnpm rust:test           # Run Rust tests
pnpm rust:check          # Quick Rust check
pnpm rust:clippy         # Rust linting
pnpm rust:fmt            # Format Rust code

# CLI (run locally)
pnpm cli board           # Show spec board
pnpm cli list            # List specs
pnpm cli create my-feat  # Create new spec
pnpm cli validate        # Validate specs

# Documentation
pnpm docs:dev            # Start docs site
pnpm docs:build          # Build docs

# Release
pnpm pre-release         # Run all pre-release checks
pnpm prepare-publish     # Prepare for npm publish
pnpm restore-packages    # Restore after publish

See package.json for all available scripts.


Documentation

📖 Full Documentation · CLI Reference · First Principles · FAQ · 中文文档

Community

💬 Discussions · 🐛 Issues · 🤝 Contributing · 📋 Changelog · 📄 LICENSE


Contact Me | 联系我

If you find LeanSpec helpful, feel free to add me on WeChat (note "LeanSpec") to join the discussion group.

如果您觉得 LeanSpec 对您有帮助,欢迎添加微信(备注 "LeanSpec")加入交流群。

WeChat Contact | 微信联系