GitHub Spec Kit: A Practical Introduction to Spec-Driven Development

Posted on Tue 14 April 2026 in GenAI

"The issue isn't the coding agent's coding ability, but our approach.
We treat coding agents like search engines when we should be treating them
more like literal-minded pair programmers."

— Den Delimarsky, GitHub Principal Product Manager


The Problem With Vibe Coding

If you've used an AI coding assistant, you've experienced vibe coding — you throw a high-level prompt at the AI, wait for output, then spend an hour tweaking because the result isn't what you had in mind.

The AI isn't bad at coding. The problem is how we talk to it.

Without context, AI coding agents fill the gaps with assumptions. Those assumptions compound across a session. By the time you're implementing feature three, the agent has forgotten the constraints you mentioned in prompt one. You end up with code that works for the demo but drifts away from your actual architecture.

Spec-Driven Development (SDD) is the fix.


What Is Spec-Driven Development?

SDD asks you to define your project's goals, architecture, and constraints upfront — in structured documents called specs — before a single line of code is generated. The AI coding assistant then references these specs as a persistent source of truth throughout the entire development process.

Think of it like handing a contractor blueprints instead of saying "build me something nice." The blueprints don't limit creativity — they eliminate misinterpretation.


What Is GitHub Spec Kit?

GitHub Spec Kit is an open-source toolkit released by GitHub that operationalizes SDD. It works with AI coding assistants including GitHub Copilot, Claude, Cursor, Gemini, and others.

At its core, Spec Kit gives your AI assistant a single source of truth about your project — a set of structured documents that define the what, the how, and the rules of your build.

That source of truth has four components:

Document Purpose
constitution.md Non-negotiable rules — tech stack, coding standards, architectural choices
spec.md What you are building — features, pages, user flows
plan.md How you will build it — components, architecture, dependencies
tasks.md Atomic work items broken down for the AI to execute

These files live inside your repository under .github/, making your specs version-controlled and shareable — just like your code.


Project Structure

When you initialize a Spec Kit project, it scaffolds the following:

.github/
  copilot-instructions.md    Agent behaviour instructions
  constitution.md            Project-level rules
  specs/
    spec.md                  What you're building
    plan.md                  How you're building it
    tasks.md                 Work breakdown

Installation

Spec Kit is installed via uvx, from the uv Python package ecosystem.

macOS / Linux:

curl -LsSf https://astral.sh/uv/install.sh | sh
uv tool install specify-cli --from git+https://github.com/github/spec-kit.git

Windows (PowerShell):

powershell -ExecutionPolicy ByPass -c "irm https://astral.sh/uv/install.ps1 | iex"
uv tool install specify-cli --from git+https://github.com/github/spec-kit.git

Initialize a new project:

specify init my-project

The CLI walks you through agent selection (Copilot, Claude, Gemini, Cursor, etc.) and preferred shell type (Bash or PowerShell).


The Seven Slash Commands

Spec Kit's entire workflow is driven by seven slash commands. Each maps to a stage in the development lifecycle.

/constitution

Sets the non-negotiable project rules — stack, standards, architecture. Every other command refers back to this file.

/constitution
This project will be a React + Vite SPA using TypeScript.
Styling via Tailwind CSS.
API calls via Axios.
State management via useState + Context API.

/specify

Describes what you are building — features, pages, user interactions.

/specify
Build a bookstore frontend with three pages:
- Product Listing (grid of books fetched from mock API)
- Product Detail (book info + Add to Cart button)
- Shopping Cart (item list, quantity control, running total, remove option)

/clarify

Optional but valuable — surfaces ambiguities in the spec before planning begins. Ensures you and the AI share the same understanding of scope before any architecture decisions are made.

/plan

Translates the spec into a concrete technical plan — components, file structure, dependencies.

/plan
Use ProductListPage to fetch data.
Use ProductCard component for individual book display.
Use CartContext for shared cart state across pages.

/tasks

Breaks the plan into atomic, executable chunks of work. The AI agent works through these one at a time.

/analyze

Validates your specs and plans for logical consistency before implementation. A pre-flight check — catches contradictions or gaps before they become bugs.

/implement

Triggers the actual build. The AI agent generates code, scaffolds files, and wires components together — using all the accumulated context from the previous steps.


Greenfield vs. Brownfield

Spec Kit works for both new and existing projects.

Greenfield: Start with the constitution, build out the spec, then plan, then implement. The AI has full context from day one.

Brownfield: Document what already exists into the spec files first. This gives the AI a map of your current codebase before making any changes — preventing it from overwriting decisions that already exist.

This is the important distinction: Spec Kit is not just a scaffolding tool. It is a communication protocol between you and the AI agent, applicable at any stage of a project's life.


Supported AI Agents

At the time of writing, Spec Kit officially supports:

  • GitHub Copilot
  • Claude (Anthropic)
  • Google Gemini
  • Cursor
  • Windsurf
  • Qwen
  • Codex
  • Opencode
  • Kilocode
  • Auggie
  • Root

Strengths and Limitations

Where It Shines

  • Complex, multi-feature projects with intricate dependencies benefit most. Detailed upfront specs reduce the compounding drift that kills large AI-assisted builds.
  • Team environments where multiple people (or agents) need to stay aligned on architecture and constraints.
  • Consistency across sessions — because specs are files in your repo, a new session picks up exactly where the last one left off.

Where It May Be Overkill

  • Simple, single-purpose scripts or tools — the setup and documentation overhead outweighs the benefit for quick tasks.
  • Early-stage exploration — if you're still figuring out what you're building, writing a constitution first can feel premature. Spec Kit rewards projects where the problem is understood before the building starts.

Why This Matters for Serious Engineers

Vibe coding is a liability in production. It produces:

  • Code that works in the demo but breaks under edge cases
  • Inconsistent patterns across the codebase
  • No clear architectural ownership
  • AI that loses context halfway through a session

Spec Kit enforces a discipline most good engineers already know: specify before you build. It wraps that discipline in a format that AI agents can consume reliably — and that your team can version, review, and update like any other project artifact.

For bootcamp instructors, team leads, and solo builders shipping real products, this is the difference between using AI as a toy and using it as a production-grade engineering tool.


Quick Reference

Concept What It Means
Spec-Driven Development Define before you build — goals, architecture, constraints
Constitution Project-level non-negotiables (stack, standards)
Spec Feature-level description of what to build
Plan Technical blueprint of how to build it
Tasks Atomic work items for the AI agent to execute
Spec Kit GitHub's open-source CLI + methodology that ties it all together

Resources

  • GitHub Repo: https://github.com/github/spec-kit
  • Official Announcement: https://github.blog/ai-and-ml/generative-ai/spec-driven-development-with-ai-get-started-with-a-new-open-source-toolkit/
  • Microsoft Learn Module: https://learn.microsoft.com/en-us/training/modules/spec-driven-development-github-spec-kit-enterprise-developers/
  • LogRocket Deep Dive: https://blog.logrocket.com/github-spec-kit/
  • InfoWorld Analysis: https://www.infoworld.com/article/4062524/spec-driven-ai-coding-with-githubs-spec-kit.html

Published on Kactii Academy Blog | #genaiexploring #kactii #learninggenai #genai