How techygarg/lattice works
Purpose and Runtime Model
Lattice is a repository-distributed framework of Markdown AI-agent skills, not an application service. It guides coding assistants through design, implementation, and review while persisting project context in a target project's .lattice/ directory. Primary user entry points are chat commands supplied by installed skills, beginning with /lattice-init; local installation is via tools/install.sh.
Paths: README.md, tools/install.sh, skills/molecules/lattice-init/SKILL.md.
Canonical Skill Library
The canonical content is organized as composable skill tiers:
• Atoms enforce focused engineering disciplines.
• Molecules orchestrate multi-step delivery workflows using atoms.
• Refiners interview teams and create project-specific standards/templates.
These are declarative instruction packages consumed by an AI runtime; SKILL.md files are the behavior boundary, with references/assets supplying detailed rules and output templates.
Paths: skills/atoms/architecture/SKILL.md, skills/molecules/design-blueprint/SKILL.md, skills/refiners/architecture-refiner/SKILL.md.
Delivery Pipeline
The principal flow is requirements → design → implementation → review. requirement-forge produces feature specifications under the consuming project’s .lattice/requirements/; design-blueprint turns approved requirements and living context into a design; code-forge implements against that design and quality atoms; review evaluates changes and retains insights for later work. bug-fix and refactor-safely provide alternate defect and structural-change paths.
Paths: skills/molecules/requirement-forge/SKILL.md, skills/molecules/code-forge/SKILL.md, skills/molecules/review/SKILL.md.
Living Context and Initialization
lattice-init is the onboarding/control entry point for a target repository: it scans context, recommends refiners, and establishes .lattice/config.yaml. Refiners then capture architectural, DDD, clean-code, requirements, language, and review conventions. This separates Lattice’s reusable framework from per-project decisions and accumulating artifacts.
Paths: skills/molecules/lattice-init/SKILL.md, skills/refiners/ddd-refiner/SKILL.md, docs/configuration.md.
Architecture Discovery Boundary
For existing codebases, architecture-compass precedes feature work. It analyzes the repository and runs a structured judgment/interview process to establish an agreed architectural direction. The resulting guidance constrains subsequent requirements, design, and code skills rather than directly changing application code.
Paths: skills/molecules/architecture-compass/SKILL.md, skills/molecules/architecture-compass/references/interview-guide.md, docs/architecture-compass.md.
Distribution and Host Integrations
Lattice supports Claude Code, Cursor-compatible skill discovery, and Codex-compatible packaging. The root skills/ tree is replicated/flattened into the Codex plugin package, while Claude/Cursor marketplaces expose plugin metadata. There is no backend, database, or required external operational service; execution depends on the host AI assistant and filesystem access to the target project.
Paths: .claude-plugin/plugin.json, .agents/plugins/marketplace.json, plugins/lattice/.codex-plugin/plugin.json.
Maintenance and Governance
dev-skills/ contains a separate contributor-facing skill set for evolving Lattice itself, distinct from distributable end-user skills. Repository governance and automated security scanning protect the content supply chain.
Paths: dev-skills/README.md, AGENTS.md, .github/workflows/security.yml.
Main entry points: requirement-forge/SKILL.md requirement-forge · lattice-init/SKILL.md lattice-init · security.yml Security scanning · design-blueprint/SKILL.md design-blueprint
Components 18
Canonical Skill Library
Reusable declarative instruction packages.
- Refiners · Create project-specific conventions and templates.
skills/refiners/architecture-refiner/SKILL.md - DDD refiner
skills/refiners/ddd-refiner/SKILL.md - Atoms · Focused rules consumed by workflow skills.
skills/atoms/architecture/SKILL.md
Delivery Workflows
Feature and change delivery paths.
- design-blueprint · Turns approved requirements and context into a design.
skills/molecules/design-blueprint/SKILL.md - requirement-forge · Produces feature specifications in project context.
skills/molecules/requirement-forge/SKILL.md - code-forge · Implements an approved design using quality atoms.
skills/molecules/code-forge/SKILL.md - review · Evaluates changes and retains insights.
skills/molecules/review/SKILL.md - architecture-compass · Establishes agreed direction for existing codebases.
skills/molecules/architecture-compass/SKILL.md - Architecture interview guide
skills/molecules/architecture-compass/references/interview-guide.md - Bug fix & safe refactor · Defect and structural-change workflows.
Target Project Context
Project-local decisions and accumulated artifacts.
- lattice-init · Chat-command entry point that establishes project context.
skills/molecules/lattice-init/SKILL.md - .lattice/ context · Configuration, requirements, standards, and retained insights.
Distribution & Governance
Installation, host packaging, and content protection.
- Local installer
tools/install.sh - Claude/Cursor metadata · Plugin and marketplace discovery metadata.
.claude-plugin/plugin.json - Codex plugin package · Flattened replication of the root skill tree.
plugins/lattice/.codex-plugin/plugin.json - Contributor skills · Separate skills for evolving Lattice itself.
dev-skills/README.md - Security scanning · Protects the skill content supply chain.
.github/workflows/security.yml
Other components
- Host AI assistant · Executes skills with target filesystem access.
Connections 22
- Local installer → Claude/Cursor metadata: installs for discovery
- Claude/Cursor metadata → Host AI assistant: exposes skills
- Codex plugin package → Host AI assistant: packages skills
- Host AI assistant → lattice-init: runs command
- lattice-init → .lattice/ context: creates config and context
- lattice-init → Refiners: recommends
- Refiners → .lattice/ context: captures standards
- DDD refiner → .lattice/ context: captures domain conventions
- architecture-compass → Architecture interview guide: uses
- architecture-compass → .lattice/ context: records architectural direction
- .lattice/ context → requirement-forge: constrains
- requirement-forge → .lattice/ context: writes specifications
- requirement-forge → design-blueprint: approved requirements
- .lattice/ context → design-blueprint: living context
- design-blueprint → code-forge: approved design
- Atoms → code-forge: quality disciplines
- code-forge → review: changes
- review → .lattice/ context: retains insights
- Bug fix & safe refactor → .lattice/ context: uses project standards
- Security scanning → Claude/Cursor metadata: scans distributable content
- Security scanning → Codex plugin package: scans package
- Contributor skills → Security scanning: maintains governed content