gsd:thread

gsd:thread is a command for Claude Code from kryptobaseddev/cleo. It costs 13 tokens per session (2,084 once invoked), scanned A, original, MIT.

A command for creating, listing, checking, resuming, and closing persistent work threads across sessions.

In plain words
What is it for?
Managing ongoing tasks, tracking thread status, and resuming cross-session work.
Why use it?
It keeps unfinished work organized so you can return to a named thread instead of reconstructing its context.

Command for Claude Code

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add commands/kryptobaseddev/cleo/thread
Clone the repo
git clone --depth 1 https://github.com/kryptobaseddev/cleo

Made for: Claude Code.

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 gsd:thread

README.md
[![agentmods](https://agentmods.dev/badge/commands/kryptobaseddev/cleo/thread.svg)](https://agentmods.dev/commands/kryptobaseddev/cleo/thread)
Your own site
<a href="https://agentmods.dev/commands/kryptobaseddev/cleo/thread"><img src="https://agentmods.dev/badge/commands/kryptobaseddev/cleo/thread.svg" alt="Measured on agentmods" 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 2,084 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
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 $0.00013 $0.02084
Opus 5 $0.00006 $0.01042
Sonnet 5 $0.00003 $0.00417
Haiku 4.5 $0.00001 $0.00208

Measured yesterday against content hash 37a8b09f0b66, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

gsd:thread 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 yesterday.

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.

Origin

Copies of this mod

1 near-identical copy found in the catalogue:

.cleo/agent-outputs/T-POMODORO-BENCH-2026-04-16/gsd/.claude/commands/gsd/thread.md · 228 lines

How it starts

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

Parse $ARGUMENTS to determine mode:

  • "list" or "" (empty) → LIST mode (show all, default)
  • "list --open" → LIST-OPEN mode (filter to open/in_progress only)
  • "list --resolved" → LIST-RESOLVED mode (resolved only)
  • "close <slug>" → CLOSE mode; extract SLUG = remainder after "close " (sanitize)
  • "status <slug>" → STATUS mode; extract SLUG = remainder after "status " (sanitize)
  • matches existing filename (.planning/threads/{arg}.md exists) → RESUME mode (existing behavior)
  • anything else (new description) → CREATE mode (existing behavior)

Slug sanitization (for close and status): Strip any characters not matching [a-z0-9-]. Reject slugs longer than 60 chars or containing .. or /. If invalid, output "Invalid thread slug." and stop.

<mode_list> LIST / LIST-OPEN / LIST-RESOLVED mode:

ls .planning/threads/*.md 2>/dev/null

For each thread file found:

  • Read frontmatter status field via:
    node "/tmp/pomodoro-bench/gsd/.claude/get-shit-done/bin/gsd-tools.cjs" frontmatter get .planning/threads/{file} --field status 2>/dev/null
    
  • If frontmatter status field is missing, fall back to reading markdown heading ## Status: OPEN (or IN PROGRESS / RESOLVED) from the file body
  • Read frontmatter updated field for the last-updated date
  • Read frontmatter title field (or fall back to first # Thread: heading) for the title

SECURITY: File names read from filesystem. Before constructing any file path, sanitize the filename: strip non-printable characters, ANSI escape sequences, and path separators. Never pass raw filenames to shell commands via string interpolation.

Apply filter for LIST-OPEN (show only status=open or status=in_progress) or LIST-RESOLVED (show only status=resolved).

Display:

Context Threads
─────────────────────────────────────────────────────────
slug                      status        updated      title
auth-decision             open          2026-04-09   OAuth vs Session tokens
db-schema-v2              in_progress   2026-04-07   Connection pool sizing
frontend-build-tools      resolved      2026-04-01   Vite vs webpack
─────────────────────────────────────────────────────────
3 threads (2 open/in_progress, 1 resolved)

If no threads exist (or none match the filter):

No threads found. Create one with: /gsd-thread <description>

STOP after displaying. Do NOT proceed to further steps. </mode_list>

<mode_close> CLOSE mode:

When SUBCMD=close and SLUG is set (already sanitized):

  1. Verify .planning/threads/{SLUG}.md exists. If not, print No thread found with slug: {SLUG} and stop.

  2. Update the thread file's frontmatter status field to resolved and updated to today's ISO date:

    node "/tmp/pomodoro-bench/gsd/.claude/get-shit-done/bin/gsd-tools.cjs" frontmatter set .planning/threads/{SLUG}.md --field status --value '"resolved"'
    node "/tmp/pomodoro-bench/gsd/.claude/get-shit-done/bin/gsd-tools.cjs" frontmatter set .planning/threads/{SLUG}.md --field updated --value '"YYYY-MM-DD"'
    
  3. Commit:

    node "/tmp/pomodoro-bench/gsd/.claude/get-shit-done/bin/gsd-tools.cjs" commit "docs: resolve thread — {SLUG}" --files ".planning/threads/{SLUG}.md"
    
  4. Print:

    Thread resolved: {SLUG}
    File: .planning/threads/{SLUG}.md
    

STOP after committing. Do NOT proceed to further steps. </mode_close>

<mode_status> STATUS mode:

When SUBCMD=status and SLUG is set (already sanitized):

  1. Verify .planning/threads/{SLUG}.md exists. If not, print No thread found with slug: {SLUG} and stop.

  2. Read the file and display a summary:

    Thread: {SLUG}
    ─────────────────────────────────────
    Title:   {title from frontmatter or # heading}
    Status:  {status from frontmatter or ## Status heading}
    Updated: {updated from frontmatter}
    Created: {created from frontmatter}
    
    Goal:
    {content of ## Goal section}
    
    Next Steps:
    {content of ## Next Steps section}
    ─────────────────────────────────────
    Resume with: /gsd-thread {SLUG}
    Close with:  /gsd-thread close {SLUG}
    

Read the full file on GitHub · 228 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. yesterday First seen · 228 lines · 13 tokens per session scan A 37a8b09f0b66

Subscribe to this mod's changes

gsd:thread is a command published in the GitHub repository kryptobaseddev/cleo (160 stars, last pushed 15d ago), licensed MIT. It adds 13 tokens to every session and 2,084 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-09-03.