Spec Kitty Documentation

repository·main·Indexed 23 days ago

https://github.com/priivacy-ai/spec-kitty

A spec-driven development framework and CLI that converts product intent into governed AI coding workflows. It features a modular 2.x architecture based on event-sourced persistence, interface-first design, and local-first operation. The system manages the lifecycle of AI tasks using isolated worktrees and stores specs, plans, and review states in Git. Documentation includes CLI reference, Orchestrator API, and detailed architectural guides on domain containers like Kitty-core, Doctrine, and Charter.

Tokens
253.9K
Snippets
400
Records
1.1K
Agent score
77%

What's inside Spec Kitty

  1. Overview of the spec-kitty kernel

    main

    The kernel package is a zero-dependency, minimal Python utility library that serves as the foundation for the spec-kitty ecosystem. It provides low-level, shared utilities used by specify_cli, charter, and doctrine.

    It is designed as a 'dependency floor' to prevent cyclic imports. The core architecture follows a strict hierarchy where kernel is a leaf node and never imports from any other spec-kitty package.

  2. Overview of Charter Ownership Consolidation and Neutrality Hardening Contracts

    main

    The 'Charter Ownership Consolidation and Neutrality Hardening' mission is an internal refactor that introduces a new lint module. It does not introduce new CLI commands or new public HTTP/RPC APIs. Instead, it focuses on preserving existing surfaces and introducing new, stable contracts.

    These contracts are testable specifications of behavior designed to ensure stability and compliance with functional (FR) and non-functional (NFR) requirements.

  3. Overview of Software-Dev Content Templates

    main

    The Software-Dev Content Templates provide output artifact scaffolds specifically designed for the software development mission. These templates are used to shape the structure and consistency of the following artifacts produced during mission execution:

    • Specs: Formal specifications for software components or features.
    • Plans: High-level execution strategies.
    • Task Breakdowns: Granular decompositions of work.
    • Work Package Prompts: Structured prompts used to drive execution of specific work units.
  4. Overview of the Runtime & State Overhaul engineering notes

    main

    The Runtime & State Overhaul engineering notes document the design exploration for unifying mission execution context across the coord/main/lane topology. The goal is to resolve structural failures where different command surfaces independently re-derive mission state, leading to disagreements between reads, writes, and prompts.

    Note: This directory contains the grounding layer for the design and is not yet a set of final Architecture Decision Records (ADRs). It captures problem evidence, architectural intent, and governing doctrine to anchor design conversations in evidence.

    Key Project Links:

    • Parent Epic: #1619 (Unify mission execution context)
    • Redesign Tracker: #1666 (Execution-state & context domain-boundary redesign)
    • Anchor Issue: #1619
  5. Overview of Safe Sync Daemon Orphan Cleanup contracts

    main

    The Safe Sync Daemon Orphan Cleanup mission is governed by normative interface contracts. These are primarily CLI/process contracts rather than RESTful interfaces. The main product surfaces are the spec-kitty auth doctor command and the /api/health loopback endpoint.

    There are three primary technical contracts:

    1. Cleanup classification engine (pure): Defined in cleanup-classification.md.
    2. auth doctor --json / --reset --json output: Defined in auth-doctor-json.md.
    3. /api/health payload (extended): Defined in health-payload.md.

    Additionally, several behavioral contracts are enforced via tests, including startup auto-clean logic, --reset safety guards, self-retirement transitions, and network boundary constraints.

  6. Overview of Tool Config Scripts

    main
    The scripts/tool_configs/ directory contains modular glue scripts designed to improve day-to-day usability. These scripts handle environment and bootstrap logic (such as shared Python virtual environment activation) to ensure that user-facing setup remains consistent across different shells and platforms, without altering the core behavior of Spec Kitty.
  7. Use Writing Styleguides for prose and documentation quality

    main

    Writing Styleguides in Spec Kitty are used to enforce quality standards for written prose and documentation. They are specifically scoped to ensure consistency in glossary definitions, doctrine descriptions, and other user-facing text.

    Currently, the available writing styleguide is:

    • kitty-glossary-writing.styleguide.yaml: Scoped to the glossary. It enforces 8 principles for writing glossary terms, focusing on being "clear over clever," avoiding "buzzword soup," and utilizing HiC terminology.
  8. Use Documentation Content Templates for output artifact scaffolds

    main

    The documentation mission provides scaffolds for creating documentation artifacts. These templates are organized into two main categories:

    • Divio-type content templates: Located in the divio/ directory, these follow the Divio 4-type structure: tutorial, how-to, reference, and explanation.
    • Generator configuration templates: Located in the generators/ directory, these provide configurations for API documentation generators such as JSDoc and Sphinx.

    Additionally, the mission includes scaffolds for mission-specific plan and spec documents.

  9. Understand the Mission-Lifecycle Tooling Friction contracts

    main

    The Mission-Lifecycle Tooling Friction mission focuses on hardening existing spec-kitty surfaces rather than introducing new external APIs. The deliverables are behavioral improvements to the following existing components:

    • CLI: Changes to command behavior (e.g., specify, backfill-topology).
    • Doctrine: Improvements to authoring and frontmatter handling.
    • Validator: Enhanced linting and guard logic.
    • Migration: Refined scope for topology updates.

    Success is measured by executable acceptance tests defined in acceptance-matrix.json. If you are developing or verifying these surfaces, ensure your changes satisfy the specific behavioral contracts and negative invariants (properties that must not happen) associated with each Functional Requirement (FR).

  10. Technical Context and Requirements for Spec Kitty

    main

    Spec Kitty is a cross-platform CLI tool (Linux, macOS, Windows 10+) built as a single Python package (src/specify_cli/). It requires Python 3.11+.

    Key Storage Locations

    Spec Kitty manages various configuration and profile files across different formats:

    • YAML: .kittify/config.yaml and agent profiles with frontmatter (.claude/agents/, .github/agents/, .augment/agents/).
    • TOML: Codex agent profiles (.codex/agents/).
    • JSON: Amazon Q agent config (~/.aws/amazonq/cli-agents/), plugin manifests (.claude-plugin/plugin.json, .codex-plugin/plugin.json), and skill manifests (.kittify/command-skills-manifest.json, .kittify/skills-manifest.json).
    • JSONL: Event logs.

    Performance and Constraints

    • spec-kitty upgrade should complete in $\le 30$s.
    • spec-kitty plugin build should complete in $\le 60$s.
    • doctor tool-surfaces should complete in $\le 5$s.
    • The --yes flag must never overwrite drifted files automatically.
  11. Understand the purpose of the plan-context-bootstrap-fix wave handoff package

    main
    The plan-context-bootstrap-fix wave is a handoff package containing canonical artifacts designed for downstream replay. It provides the necessary context and state to allow subsequent processes or agents to resume or replay specific planning and bootstrapping operations. To identify the specific identity anchor for this package, refer to the namespace.json file within the package.