joplin-llm-wiki: Command for Claude Code

.cursor/commands/spectra-apply.md

/spectra-apply is a command for Claude Code, Cursor from gcake119/joplin-llm-wiki. It costs 13 tokens per session (3,845 once invoked), scanned A, original, MIT.

A command for carrying out the tasks listed in a Spectra change, where Spectra is the project's change-management tool.

In plain words
What is it for?
Selecting an active or parked change, implementing its unchecked tasks, and marking completed tasks with file-based checkboxes.
Why use it?
It provides a repeatable way to choose the right change and track implementation progress in the change's task file.

Command for Claude CodeCursor

Written for Cursor and Claude Code: installed under .cursor/, but also a Claude Code command (commands/*.md). Also seen: names the AskUserQuestion tool.

This is gcake119/joplin-llm-wiki's own configuration. It tells Claude Code and Cursor how to work on joplin-llm-wiki itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything joplin-llm-wiki configures →

Reuse

Borrowing it

Nothing to install: this file belongs to gcake119/joplin-llm-wiki. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/gcake119/joplin-llm-wiki/main/.cursor/commands/spectra-apply.md
Clone the repo
git clone --depth 1 https://github.com/gcake119/joplin-llm-wiki

Made for: Claude Code, Cursor.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for /spectra-apply

README.md
[![agentmods](https://agentmods.dev/badge/commands/gcake119/joplin-llm-wiki/spectra-apply/github.svg)](https://agentmods.dev/commands/gcake119/joplin-llm-wiki/spectra-apply)
Your own site
<a href="https://agentmods.dev/commands/gcake119/joplin-llm-wiki/spectra-apply"><img src="https://agentmods.dev/badge/commands/gcake119/joplin-llm-wiki/spectra-apply/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for /spectra-apply

Your own site · 80×15
<a href="https://agentmods.dev/commands/gcake119/joplin-llm-wiki/spectra-apply"><img src="https://agentmods.dev/badge/commands/gcake119/joplin-llm-wiki/spectra-apply.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 13 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 3,845 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00013 $0.03845
Opus 5 $0.00006 $0.01922
Sonnet 5 $0.00003 $0.00769
Haiku 4.5 $0.00001 $0.00384

Measured 12d ago against content hash a3719d947bbf, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-12, from the pricing page.

Security

Grade A, and why

/spectra-apply scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 12d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.cursor/commands/spectra-apply.md · 338 lines

How it starts

The opening of the file, as written. The whole thing — 338 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Implement tasks from a Spectra change.

Input: Optionally specify a change name (e.g., /spectra:apply add-auth). If omitted, check if it can be inferred from conversation context. If vague or ambiguous you MUST prompt for available changes.

Task tracking is file-based only. The tasks file's markdown checkboxes (- [ ] / - [x]) are the single source of truth for progress. Do NOT use any external task management system, built-in task tracker, or todo tool. When a task is done, edit the checkbox in the tasks file — that is the only way to record progress.

Prerequisites: This skill requires the spectra CLI. If any spectra command fails with "command not found" or similar, report the error and STOP.

Steps

  1. Select the change

    If a name is provided, use it. Otherwise:

    • Infer from conversation context if the user mentioned a change
    • Auto-select if only one active change exists
    • If ambiguous, run spectra list --json AND spectra list --parked --json to get all available changes (including parked ones). Parked changes should be annotated with "(parked)" in the selection list. Use the AskUserQuestion tool to let the user select

    Always announce: "Using change: " and how to override (e.g., /spectra:apply <other>).

  2. Check status to understand the schema

    spectra status --change "<name>" --json
    

    If the command fails: show the error and STOP.

    If the command succeeds, check whether the change is parked (status can succeed even for parked changes):

    spectra list --parked --json
    

    Look for the change name in the parked array of the JSON output.

    • If the change IS in the parked list (it's parked): Inform the user that this change is currently parked(暫存). Use the AskUserQuestion tool to ask whether to continue. Two options:

      • Continue: Unpark the change and proceed with apply
      • Cancel: Stop the workflow

      If the user chooses to continue:

      spectra unpark "<name>"
      

      Then mark it as in-progress:

      spectra in-progress add "<name>"
      

      This is a silent operation — do not show the output to the user.

      Then re-run spectra status --change "<name>" --json and continue normally.

      If there is no AskUserQuestion tool available (non-Claude-Code environment): Inform the user that this change is currently parked(暫存)and ask via plain text whether to unpark and continue, or cancel. Wait for the user's response. If the user confirms, run spectra unpark "<name>", then set spectra in-progress add "<name>", and continue normally.

    • If the change is NOT in the parked list: mark it as in-progress and proceed normally.

      spectra in-progress add "<name>"
      

      This is a silent operation — do not show the output to the user.

    Parse the JSON to understand:

    • schemaName: The workflow being used (e.g., "spec-driven")
    • Which artifact contains the tasks (typically "tasks" for spec-driven, check status for others)
  3. Get apply instructions

    spectra instructions apply --change "<name>" --json
    

    This returns:

    • Context file paths (varies by schema)
    • Progress (total, complete, remaining)
    • Task list with status
    • Dynamic instruction based on current state

    Handle states:

    • If state: "blocked" (missing artifacts): show message, suggest using /spectra:propose to create the change artifacts first
    • If state: "all_done": congratulate, suggest archive
    • Otherwise: proceed to implementation

3b. Preflight check

If the apply instructions JSON includes a preflight field, act on its status:

  • "clean": silently continue — no output needed.
  • "warnings": display a brief summary, then continue automatically:
    ⚠ Preflight warnings:
    - Drifted files (modified after change was created): <list paths>
    - Change is <N> days old
    Continuing...
    
    Only show the lines that are relevant (skip drifted if none, skip staleness if not stale).
  • "critical": display missing files with their source artifact, then use the AskUserQuestion tool to ask the user:

Read the full file on GitHub · 338 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 12d ago First seen · 338 lines · 13 tokens per session scan A a3719d947bbf

Subscribe to this mod's changes

/spectra-apply is a command published in the GitHub repository gcake119/joplin-llm-wiki (2 stars, last pushed 3mo ago), licensed MIT. It adds 13 tokens to every session and 3,845 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.