← Back to news
OpenSpec: Specify Before Coding, Keep Humans in Control

Photo: Sebastiaan ter Burg / Wikimedia Commons — CC BY 2.0 (https://creativecommons.org/licenses/by/2.0/). Original photograph; header may be resized or cropped.

23/10/2026

OpenSpec: Specify Before Coding, Keep Humans in Control

OpenSpec: make the agreement durable before the agent writes code

The expensive part of AI-assisted development is often not generating a patch. It is discovering, during review, that the patch solves a different problem from the one the team intended. OpenSpec addresses that gap with a lightweight, versioned specification layer for coding assistants. Instead of leaving the agreement inside a conversation, it gives each change a proposal, behavioral requirements, technical decisions when needed, and an implementation checklist. The senior engineer can review that agreement before implementation becomes expensive.

The practical reason to revisit it now is the October 6 release, v1.14.1. Its improvements include more resilient specification writing, stricter handling of overly long requirements during validation, and a clearer distinction between completing tasks and being ready to archive. This is an adoption guide grounded in official documentation, not a benchmark or a claim that we have measured productivity gains. The examples below are proposed engineering workflows, not reported customer results.

What it is, and what it is not

OpenSpec is an MIT-licensed CLI and a collection of instructions integrated with existing AI coding tools. It is not a new foundation model, a replacement IDE, or a service that independently understands your business. Your assistant still reads the repository and writes the implementation. OpenSpec supplies a shared structure for deciding what that implementation should accomplish. Its documentation lists integrations with Claude Code, Cursor, Codex, and many other assistants; check the supported-tools page for your exact client.

The distinction from an AGENTS.md file is useful. Repository-wide instructions describe persistent conventions: architectural boundaries, test commands, naming, and forbidden operations. A change specification describes one decision: what is being added, modified, or removed, and which observable behaviors must hold. You usually need both, but they should not duplicate each other. Keep enduring rules short and link the active change rather than copying a product document into every prompt.

What the October release changes in practice

In v1.14.1, agents are instructed to write each capability specification as it is drafted, rather than planning every file before writing any. Interrupted planning therefore has a better chance of leaving useful artifacts behind. The release also fixes verification with custom schemas by locating specification and design artifacts through their output paths. These are workflow reliability improvements; they do not establish that generated requirements or verification conclusions are correct.

Two changes matter especially for governance. A requirement longer than 500 characters becomes a warning that makes strict validation fail. That encourages smaller, reviewable requirements, not simplistic systems. And when every task is checked, apply now asks for review rather than declaring the change ready to archive. The dashboard also excludes archived changes. None of this replaces approval rules in your repository, and this article does not assume v1.14.1 is the newest available package.

Install deliberately, then initialize one repository

The current installation documentation requires Node.js 20.19.0 or newer. Check with node --version. The documented npm installation is npm install -g @fission-ai/openspec@latest; Homebrew users can use brew install openspec. Verify the installation with openspec --version. For a controlled team evaluation, agree on a tested release and record it rather than silently letting every developer evaluate a different version. Package installation and model access are separate concerns.

From a clean feature branch in a disposable or noncritical repository, run openspec init and choose your assistant integration. The CLI also supports explicit selection, such as openspec init --tools claude,cursor. Inspect the generated files with Git before committing anything. OpenSpec installs instructions and skills into client-specific locations and creates project configuration. Restart the client if its new commands do not appear. Do not initialize every tool merely because the selector offers it.

Understand the files before delegating work

The documented change layout is openspec/changes/<change-name>/. Its proposal explains why the change exists and its scope; capability specifications state testable behavior; a design document records technical choices when needed; tasks provide the implementation checklist. Main specifications live under openspec/specs/. Archiving incorporates the change requirements into those main specifications and moves the change folder into the archive. These are readable files, not an opaque database.

That portability is a meaningful benefit for teams that switch assistants or need to resume work after an interrupted session. But checked boxes are only recorded claims. They do not prove a test passed or a requirement was implemented. Attach verification evidence to the pull request: commands, relevant output, the commit being tested, and unresolved risks. Keep the specification and its code changes in the same review whenever practical so the reviewer sees their relationship.

The core loop: explore, propose, correct, apply, archive

Start with exploration when the problem is ambiguous. Ask the assistant to investigate the existing implementation, identify boundaries, and list unresolved questions without writing code. The quickstart describes explore as a thinking mode, then propose as a step that writes the reviewable plan and stops before implementation. Plain-language requests work across supported clients; the exact skill or slash-command spelling varies. Do not assume every workflow is installed by the default profile.

Read the proposal first, the requirements second, and the task list third. Correct the files directly or ask the assistant to revise them. Only then open a fresh implementation session and ask it to apply the named change. A fresh context reduces conversational baggage, while the files preserve the approved intent. Before archive, review implementation evidence and the requirement diff. Treat archiving as maintaining the system record, not as permission to merge, deploy, or declare an incident resolved.

Use case one: rate limiting with actual product boundaries

Consider a public API that needs rate limiting. A vague prompt can produce plausible middleware while missing tenant identity, reverse proxies, retries, or operational failure modes. Ask OpenSpec to propose one bounded change. A useful review starts with questions: is the limit per authenticated tenant, API key, account, or IP address? Which endpoints are excluded? What happens when the backing store is unavailable? Who can change thresholds? These are product and operational decisions, not details the agent should quietly invent.

Turn each approved answer into observable scenarios. Requests below the threshold remain unaffected; excess traffic receives the agreed status and headers; one tenant cannot consume another tenant's allowance; health checks remain available according to policy. Then ask for unit tests around the limiter, integration tests around identity extraction, and a deployment plan with monitoring. Reject tasks that introduce unrelated authentication refactors. The potential gain is fewer late redesigns because the difficult questions were answered before middleware was generated.

Use case two: a compatibility-preserving API migration

Suppose a service must move from one response format to another without breaking existing consumers. Use a change specification to distinguish the desired contract from the current implementation. Record supported clients, version negotiation, nullability, pagination, error formats, and the deprecation window. An assistant can inspect call sites and propose a compatibility matrix, but the owner of the API must approve which behaviors remain contractual. Existing code is evidence of behavior, not automatic proof of intended policy.

Break implementation into reversible steps: introduce an adapter, add contract tests, migrate one consumer, observe, and retire the old path only after explicit approval. Require examples of old and new responses using synthetic data. A reviewer should be able to trace every modified requirement to a test and every breaking change to a decision. OpenSpec helps maintain that trace in files; it does not discover external consumers or guarantee that your test suite represents them.

Use case three: stabilize a flaky integration test

Specification-driven work is useful for maintenance, not only features. For a flaky integration test, begin with a proposal whose goal is preserving the behavioral assertion while removing nondeterministic setup. State non-goals explicitly: no disabling the test, no broad timeout inflation, no replacing an integration assertion with a mock merely to obtain a green run. Ask the assistant to gather failure logs, inspect shared resources, and propose competing explanations before modifying the suite.

The requirement might describe isolation between test executions and deterministic cleanup after failures. Implementation tasks could separate fixtures, control the clock, or replace sleeps with observable readiness checks. Request repeated execution in the relevant environment and preserve failures instead of reporting only the last successful run. The human reviewer decides whether the new test still protects the product. OpenSpec's role is keeping that acceptance boundary visible while the agent explores a deceptively easy fix.

Use case four: refactor a payment boundary without changing behavior

A refactor is dangerous when an assistant interprets cleanliness as permission to change semantics. For a payment adapter extraction, specify the behavior that must remain invariant: idempotency handling, rounding policy, retry classification, duplicate webhook processing, and audit visibility. Have the assistant map the current call graph and list uncertainties. Do not ask it to infer financial policy from variable names. Any ambiguity affecting money requires a domain owner, not a more confident prompt.

Keep the change narrow and require characterization tests before moving logic. Review the specification diff separately from the implementation diff: an ostensibly structural refactor should not smuggle in new business behavior. Ask for a rollback path and explicit treatment of partially completed operations. This workflow can make delegation practical because the engineer concentrates on boundaries and evidence, while the agent handles repetitive edits. It cannot eliminate the need for payment expertise or production safeguards.

Write requirements that can survive an adversarial review

A requirement such as “the endpoint should be fast and secure” is a wish, not an acceptance criterion. Prefer one observable obligation, its relevant conditions, and its failure behavior. Separate authorization from latency and error handling. Include negative cases: missing identity, malformed input, unavailable dependencies, concurrent operations, and retry after partial failure. The release's length warning can encourage decomposition, but a short requirement can still be wrong or omit the most important case.

Ask a second review pass to challenge the specification without implementing it. Useful questions include: which terms are undefined, which scenarios contradict each other, and what behavior would satisfy the text while disappointing a customer? Keep unresolved decisions visible rather than letting the agent turn assumptions into requirements. The human approval should refer to the actual reviewed revision. A changed specification needs renewed review when it changes risk or behavior, even if implementation has already started.

Validation, verification, and approval are different activities

The CLI offers openspec validate for structural checks; inspect openspec validate --help for the installed version and strict-mode options. Structural validation can detect malformed or incomplete artifacts according to the tool's rules. It cannot establish business correctness. The optional verify workflow inspects the relationship between implementation and artifacts, but an assistant's conclusion is still a review aid, not a substitute for independently executed tests or specialist review.

Keep three records distinct: the validator outcome, the executed software checks, and the human decision. A passing parser does not imply a passing integration test, and a passing integration test does not authorize deployment. For important changes, require reviewer ownership, branch protection, and CI checks outside the agent session. OpenSpec explicitly favors a fluid workflow without rigid phase gates. If your organization needs mandatory approval, enforce it through actual repository and delivery controls.

Security and privacy still belong to the surrounding toolchain

OpenSpec's CLI and the assistant that consumes its files have different responsibilities. The assistant may send repository content to a model provider or invoke local commands according to its own configuration. Installing a planning layer does not change those permissions. Evaluate authentication, data retention, model access, filesystem boundaries, network access, and secret handling in the client you actually use. Never place production credentials, customer records, or incident secrets into a specification to make the prompt more convenient.

The project documents anonymous usage telemetry, enabled by default outside CI, limited to command names and version rather than arguments, paths, or content. Documented opt-outs include export OPENSPEC_TELEMETRY=0 or export DO_NOT_TRACK=1. Apply your organization's policy rather than assuming an open-source license means no telemetry. Treat generated instructions and third-party schemas as executable workflow dependencies: review their provenance and changes before giving an agent access to sensitive repositories.

Keep updates and collaboration boring

The package and the generated project instructions do not update as one invisible unit. After changing the installed CLI version, run openspec update in each relevant project and review what changed. Record the CLI version and selected workflows in onboarding notes. Avoid unreviewed global profile changes that make two engineers run different processes in the same repository. Optional workflows and client-specific invocation syntax deserve a small team convention rather than repeated guessing.

Parallel work needs ordinary Git discipline. Two agents editing the same capability specification can create semantic conflicts even when Git merges cleanly. Assign ownership, use isolated branches or worktrees, and rebase against the latest accepted specification before archiving. Keep one coherent change per folder and avoid generating a grand specification for the entire application. Start with a real maintenance task whose reviewer can judge the result without learning a new process for several days.

Measure the saved work, not the generated document volume

A sensible pilot compares similar tasks and records total engineering effort: planning, agent execution, interruptions, review, rework, and follow-up defects. Also record whether the reviewer could identify the acceptance criteria quickly and whether a second engineer could resume from the files. The relevant outcome is a trustworthy change reaching acceptance with less wasted effort. More generated Markdown, fewer typed characters, and a convincing assistant summary are not sufficient evidence of higher productivity.

Expect overhead. Tiny wording fixes, isolated dependency bumps, and obvious one-line corrections may not justify a change folder. For ambiguous, cross-cutting work, a short specification can prevent expensive divergence. Do not promise a universal percentage improvement: this guide provides no measured speedup. Decide in advance what would make the pilot fail, such as longer review queues, stale specifications, or requirements rewritten after implementation solely to make the work appear compliant.

A practical adoption checklist

  • Install from the official documentation, verify the version, and initialize only the assistant integrations you need.
  • Pick one bounded change with a named human owner and explicit non-goals.
  • Review observable requirements before implementation; keep unresolved business decisions visible.
  • Run structural validation and real software checks separately, preserving their evidence.
  • Review specification changes and code together; archive only after the agreed review.
  • Keep merge, release, credentials, and production access under existing human-controlled safeguards.

OpenSpec is most useful when it makes an engineering agreement easier to inspect, correct, and carry between sessions. Its October release improves the mechanics of that agreement; the surrounding team still supplies its authority. Let the assistant accelerate investigation, artifact drafting, and implementation. Keep responsibility for scope, acceptance, and production consequences with the engineers who understand the system.

The selected header photograph shows a Wikimedia developer community event in 2013. It is an illustration of collaborative engineering, not a screenshot of OpenSpec or evidence of the project's use at that event.