Skip to content
Development
Command

/loki-spec-status

Check whether the spec has drifted from its lock using Loki's living-spec drift detection, and summarize the report.

From plugin
loki-mode
1k3 skills3 commands2 MCP
Install
> /plugin marketplace add asklokesh/loki-mode
> /plugin install loki-mode@loki-mode

How it fires

How this command gets triggered: by you, by Claude, or both.

  • Fires itselfClaude auto-loads it when your prompt matches the work.
  • You can call itInvoke it directly when you want it.
  • Slash command/loki-spec-status

Context preview

What this command does when you run it.

Check whether the spec has drifted from its lock using Loki's living-spec drift detection, and summarize the report.

Command definition

loki-spec-status.md
description: Check whether the spec has drifted from its lock using Loki's living-spec drift detection, and summarize the report.
argument-hint: "[spec-path] (default: prd.md / .loki/generated-prd.md)"
allowed-tools: Bash(loki spec:*), Read

Check whether the spec is still true: the spec is the contract; Loki keeps it true. This runs deterministic drift detection (no LLM cost) comparing the current spec against its lock.

Steps:

1. If there is no lock yet, the status command will say so. In that case, offer to create one:

   loki spec lock $ARGUMENTS

The lock (`.loki/spec/spec.lock`) is a deterministic map of spec requirements (checklist items and headings) to content hashes, plus repo HEAD at lock time.

2. Run the drift check:

   loki spec status $ARGUMENTS

Exit 0 means in sync (SPEC-TRUE); exit 1 means drift detected (SPEC-DRIFTED). It writes `.loki/spec/drift-report.json`.

3. Read `.loki/spec/drift-report.json` and summarize for the user:

  • The verdict: SPEC-TRUE or SPEC-DRIFTED.
  • Counts of ADDED, REMOVED, and CHANGED requirements, then list each one.
  • Whether code changed since the locked HEAD (files, insertions, deletions).

4. If drifted, explain the choice clearly:

  • If the code is the source of truth and the spec should follow, the human

updates the spec, then runs `loki spec sync $ARGUMENTS` to re-lock.

  • If the spec is correct and the code lags, the change set is incomplete.

This MVP never auto-rewrites the spec. Re-locking via `loki spec sync` is an explicit human action after review. Do not run `sync` automatically; ask first.

Report only what the drift report shows. Do not infer requirements that are not in the spec.

Read more
Ships withloki-mode

Multi-agent autonomous SDLC framework. Spec to deployed app. PRD, GitHub issue, OpenAPI/JSON/YAML, or one-line brief. 5 AI providers, 8 quality gates.

Get the whole plugin
Stats
1,035
Stars
200
Forks
Active
Maintenance
Shell
Language
1h ago
Last commit
7mo ago
Created

Repo: asklokesh/loki-mode