trd

trd is a command for Claude Code from HigorAlves/orc. It costs 40 tokens per session (1,454 once invoked), scanned A, original, MIT.

A command for writing a Technical Requirements Document (TRD), which records the technical design, constraints, and agreements for a complex change.

In plain words
What is it for?
Creating a numbered file in docs/trds/, optionally using an existing product requirements document or Jira ticket as input.
Why use it?
It gives engineers and services a shared written contract when a product specification is not detailed enough technically.

Command for Claude Code

Written for Claude Code: allowed-tools in frontmatter. Also seen: $skill-name invocation.

Good fit Creating a numbered file in docs/trds/, optionally using an existing product requirements document or Jira ticket as input.

Compare 6 commands from other repositories ↓
Install with agentmods
npx agentmods add commands/higoralves/orc/trd
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.

Clone the repo
git clone --depth 1 https://github.com/HigorAlves/orc

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 trd

README.md
[![agentmods](https://agentmods.dev/badge/commands/higoralves/orc/trd/github.svg)](https://agentmods.dev/commands/higoralves/orc/trd)
Your own site
<a href="https://agentmods.dev/commands/higoralves/orc/trd"><img src="https://agentmods.dev/badge/commands/higoralves/orc/trd/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 trd

Your own site · 80×15
<a href="https://agentmods.dev/commands/higoralves/orc/trd"><img src="https://agentmods.dev/badge/commands/higoralves/orc/trd.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 40 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,454 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.00040 $0.01454
Opus 5.5 $0.00016 $0.00582
Sonnet 5.5 $0.00008 $0.00291
Haiku 4.5 $0.00004 $0.00145

Measured 25d ago against content hash ddc93eaa579d, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

trd 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 25d 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.

codex/orc/content/commands/trd.md · 113 lines

How it starts

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

$orc-trd

Author a new TRD following orc-trd-writing. Lives at docs/trds/NNNN-<kebab-title>.md.

Arguments

  • <title> — optional. Short noun phrase describing the contract being pinned down (e.g. "webhook retry contract"). If omitted, prompts via the available user-question tool (or ask in chat).
  • --from-prd NNNN — optional. Reads docs/prds/NNNN-*.md and seeds the TRD's Goals, Constraints, and Linked PRD(s) sections from it.
  • --from-jira <KEY> — optional. Seeds Linked tickets and (if useful) the Background / context section from a Jira ticket via orc-jira-cli.

Workflow

Phase 1 — Confirm a TRD is warranted

Invoke orc-trd-writing. Apply its "all of these are true" test:

  • A PRD (or equivalent product spec) has settled the "what & why."
  • Non-trivial technical surface area (new APIs / data / failure modes / dependencies / contracts).
  • Multiple engineers / services / repos need to agree on the contract.

If borderline, print the Gate headline (**⛔ Gate — is this TRD-worthy?**, per orc-callouts), then the available user-question tool (or ask in chat):

  • "Yes, write the TRD"
  • "Smaller — single design note in code instead"
  • "RFC needed first — alternatives are still being debated → $orc-rfc"
  • "ADR instead — single decision to record, not a contract → $orc-adr"
  • "Just a plan — go straight to $orc-plan"

Phase 2 — Locate docs/trds/

If the directory doesn't exist, create it and add a one-line docs/trds/README.md linking to orc-trd-writing. Find the next sequence:

ls docs/trds 2>/dev/null | grep -E '^[0-9]{4}-' | sort | tail -1

Increment to get the new four-digit sequence (0001 if first).

Phase 3 — Gather inputs

If --from-prd NNNN was passed:

  1. Resolve the PRD path: ls docs/prds/NNNN-*.md → exactly one file expected. If zero matches, surface and ask user to confirm/correct. If multiple, surface and ask.
  2. Read the PRD. Extract:
    • Title → suggest as the TRD's title prefix.
    • Problem + Audience + Success metrics → seed the Goals and Background / context sections.
    • Constraints / out-of-scope from the PRD → seed Constraints and Non-goals.
    • Linked tickets → carry forward into Linked tickets.

Read the full file on GitHub · 113 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. 25d ago Changed · -1 tokens per session ddc93eaa579d
  2. 3mo ago First seen · 113 lines · 41 tokens per session scan A c7b091a4f3e6

Subscribe to this mod's changes

trd is a command published in the GitHub repository HigorAlves/orc (7 stars, last pushed 3d ago), licensed MIT. It adds 40 tokens to every session and 1,454 once invoked, about $0.0002 per session on Opus 5.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.

Related

trd compared with commands from other repositories

trd next to 6 commands from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
trdHigorAlves/orcCommand73d agoMITA40Claude Code
parallax-statusMaster0fFate/parallax-claudecodeCommand01mo agoMITA13Claude Code
checklistgithub/spec-kitCommand153ktodayMITA13Claude Code
clarifygithub/spec-kitCommand153ktodayMITA27Claude Code
analyzegithub/spec-kitCommand153ktodayMITA26Claude Code
specifygithub/spec-kitCommand153ktodayMITA13Claude Code
convergegithub/spec-kitCommand153ktodayMITA35Claude Code