Skip to content

Latest commit

 

History

History
104 lines (82 loc) · 1.97 KB

File metadata and controls

104 lines (82 loc) · 1.97 KB

Prompt Bootstrapping

The MCP server automatically bootstraps Spec Kit prompts on first use.

How It Works

1. Check for Existing Prompts

On startup, the server searches for .kiro/prompts/ directory:

  • Starts from current working directory
  • Walks up the directory tree (up to 5 levels)
  • If found with speckit.*.md files, uses them

2. Bootstrap if Not Found

If prompts don't exist, the server bootstraps them:

Option A: Local Source (Development)

If SPECKIT_SOURCE environment variable is set:

export SPECKIT_SOURCE=/path/to/spec-kit

The server copies prompts from $SPECKIT_SOURCE/templates/commands/*.md

Option B: GitHub (Production)

Downloads prompts from:

https://raw.githubusercontent.com/github/spec-kit/main/templates/commands/

Downloads these files:

  • constitution.md
  • specify.md
  • clarify.md
  • plan.md
  • tasks.md
  • implement.md
  • analyze.md
  • checklist.md

3. Cache Prompts

Prompts are saved to .kiro/prompts/ as:

  • speckit.constitution.md
  • speckit.specify.md
  • etc.

4. Serve via MCP

All prompts are exposed through the MCP protocol for use by Kiro CLI or other clients.

Configuration

Kiro CLI with Local Source

{
  "mcpServers": {
    "speckit": {
      "command": "mcp-speckit-kiro",
      "env": {
        "SPECKIT_SOURCE": "/Users/you/projects/spec-kit"
      }
    }
  }
}

Kiro CLI with GitHub (Default)

{
  "mcpServers": {
    "speckit": {
      "command": "mcp-speckit-kiro"
    }
  }
}

Manual Bootstrap

You can also manually bootstrap prompts:

# From GitHub
cd your-project
mcp-speckit-kiro  # Will auto-bootstrap on first prompt list

# From local source
export SPECKIT_SOURCE=/path/to/spec-kit
cd your-project
mcp-speckit-kiro

Updating Prompts

To get the latest prompts:

  1. Delete .kiro/prompts/ directory
  2. Restart the MCP server
  3. Prompts will be re-downloaded

Or manually update:

rm -rf .kiro/prompts
# Next MCP invocation will re-bootstrap