Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add commands/rand/mnemosyne/project-constitutiongit clone --depth 1 https://github.com/rand/mnemosyneWhat it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00014 | $0.01049 |
| Opus 5 | $0.00007 | $0.00524 |
| Sonnet 5 | $0.00003 | $0.00210 |
| Haiku 4.5 | $0.00001 | $0.00105 |
Grade A, and why
project-constitution scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 125 lines — stays where its author put it; the contents beside it link to each section on GitHub.
I will help you create or update your project's constitution. This establishes the core principles, quality gates, and constraints that guide all development work.
Usage:
/project-constitution- Create new or update existing constitution/project-constitution --show- Display current constitution
Instructions for me:
-
Check for existing constitution:
- Look for
.mnemosyne/artifacts/constitution/project-constitution.md - If exists, parse YAML frontmatter to get current version
- If updating, increment version appropriately (major for breaking changes, minor for additions, patch for fixes)
- Look for
-
Gather constitution content (if creating new):
- Ask the user about:
- Core Principles: 3-7 fundamental principles (e.g., "Performance First", "Type Safety", "Developer Experience")
- Quality Gates: Specific, measurable standards (e.g., "90%+ test coverage on critical path", "Sub-200ms p95 latency")
- Constraints: Technical or business constraints (e.g., "Rust-only for performance-critical code", "No external API dependencies")
- Architecture Decisions: Key technical choices (e.g., "Event-sourced for audit trail", "PostgreSQL for primary storage")
- Ask the user about:
-
Format constitution as markdown:
--- type: constitution id: constitution name: Project Constitution version: <semver> created_at: <ISO 8601 timestamp> updated_at: <ISO 8601 timestamp> memory_id: <will be filled after storage> references: [] --- # Project Constitution ## Core Principles 1. **[Principle Name]**: [Description] 2. **[Principle Name]**: [Description] ... ## Quality Gates ### Testing - [ ] Critical path: 90%+ coverage - [ ] Integration tests for all public APIs - [ ] E2E tests for user workflows ### Performance - [ ] Sub-200ms p95 latency for queries - [ ] Memory usage under 100MB baseline ### Code Quality - [ ] All compiler warnings addressed - [ ] No TODO/FIXME in committed code - [ ] Type-safe error handling ## Constraints - **[Constraint Category]**: [Description] ... ## Architecture Decisions - **[Decision Area]**: [Choice and rationale] ... -
Write constitution file:
- Create/update
.mnemosyne/artifacts/constitution/project-constitution.md - Ensure
.mnemosyne/artifacts/constitution/directory exists
- Create/update
-
Store memory entry:
- Use Mnemosyne CLI:
mnemosyne remember - Arguments:
- Content: First 500 chars of constitution + "...see .mnemosyne/artifacts/constitution/project-constitution.md for full text"
- Namespace:
project:<project-name>(detect from git root directory name) - Importance: 9 (constitutions are critical)
- Type: constitution
- Tags: constitution,principles,quality-gates
- Context: "Project constitution defining core principles and quality gates"
- Capture memory_id from output
- Use Mnemosyne CLI:
-
Update artifact with memory_id:
- Read the artifact file
- Update
memory_idfield in YAML frontmatter - Write back to file
-
Display confirmation:
✓ Constitution created/updated successfully Version: <version> Location: .mnemosyne/artifacts/constitution/project-constitution.md Memory ID: <memory_id> Core Principles: <count> Quality Gates: <count> Constraints: <count> Architecture Decisions: <count> Next steps: - Review with team: cat .mnemosyne/artifacts/constitution/project-constitution.md - Create feature spec: /feature-specify <description> - Update constitution: /project-constitution -
Error handling:
- If
.mnemosyne/artifacts/doesn't exist: "Error: Artifact directory not initialized. Run 'mnemosyne artifact init' first" - If user cancels: "Constitution creation cancelled"
- If Mnemosyne not available: "Error: Mnemosyne not available. Check installation."
- If
Special behaviors:
- If
--showflag: Display current constitution from file (if exists) or "No constitution found" - Interactive mode: Ask questions one at a time to build constitution
- Validation: Ensure at least 3 principles, 3 quality gates before saving
- Version bumping: Explain what changed and why version was incremented
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 2d ago First seen · 125 lines · 14 tokens per session scan A 08b84533a464
project-constitution is a command published in the GitHub repository rand/mnemosyne (84 stars, last pushed 9mo ago), licensed MIT. It adds 14 tokens to every session and 1,049 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other commands, from other repositories
hatch3r-bug-plan
Diagnose a complex incident -- reproduce the symptom, rank root-cause hypotheses, design the fix path, and emit regression coverage items as a board-ready investigation.
hatch3r-debug
Standalone debug-and-fix workflow — add strategic debug logging, collect runtime logs from the user, perform root cause analysis, implement the fix, and clean up all debug artifacts.
hatch3r-feature-plan
Design a new capability -- draft user stories, acceptance criteria, data model, API surface, and sub-issue breakdown as an epic-shaped todo.md for greenfield features.
story-6.1.4
Story ID: 6.1.4 Epic: Epic-6.1 - Agent Identity System Wave: Wave 1 (Foundation) Status: 📋 Ready to Start Priority: 🔴 Critical Owner: Dev (Dex) Created: 2025-01-14 Updated: 2025-01-17 (v4 - Unified System Integration) Duration: 2.5 days (20 hours) Investment: $250.00.
hatch3r-bug-pipeline
Run a known-cause bug fix through a 3-phase test-first pipeline -- reproduce + root-cause, regression-test + fix together, then root-cause-depth review -- with full sub-agent delegation.
hatch3r-incident-response
Drive a live production incident through a structured lifecycle -- triage + topology, bounded-autonomy mitigation, stakeholder communication, then a blameless post-mortem with runbook -- via delegated sub-agents.