trading-ops: Command for Claude Code

.claude/commands/discover.md

discover is a command for Claude Code from l3lackcurtains/trading-ops. It costs 27 tokens per session (551 once invoked), scanned A, original, MIT.

A command that finds investment candidates with Finviz, a website that screens stocks using financial and market filters. It uses the project's current macro regime, meaning its broad market conditions.

In plain words
What is it for?
It saves a dated list of stocks matching regime, quality, growth, value, or defense criteria.
Why use it?
It applies the project's filter rules and handles empty results instead of building a screen from scratch.

Command for Claude Code

Written for Claude Code: $ARGUMENTS substitution.

This is l3lackcurtains/trading-ops's own configuration. It tells Claude Code how to work on trading-ops 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 trading-ops configures →

Reuse

Borrowing it

Nothing to install: this file belongs to l3lackcurtains/trading-ops. 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/l3lackcurtains/trading-ops/main/.claude/commands/discover.md
Clone the repo
git clone --depth 1 https://github.com/l3lackcurtains/trading-ops

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 discover

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

Your own site · 80×15
<a href="https://agentmods.dev/commands/l3lackcurtains/trading-ops/discover"><img src="https://agentmods.dev/badge/commands/l3lackcurtains/trading-ops/discover.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 27 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 551 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.00027 $0.00551
Opus 5 $0.00014 $0.00275
Sonnet 5 $0.00005 $0.00110
Haiku 4.5 $0.00003 $0.00055

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

Security

Grade A, and why

discover 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 9d 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.

.claude/commands/discover.md · 32 lines

What it actually says

Run a screener: $ARGUMENTS

Protocol in guide/discover-rules.md. Read it before starting if you haven't this session — it has the verified Finviz filter prefix reference, all preset filter sets (r1/r2/r3/r4/quality/growth/value/defense), 0-results fallback strategy, and the SCREENS folder structure.

Steps

  1. Read guide/discover-rules.md for the filter syntax and presets.

  2. Read scanned/MACRO/current.md to anchor the screen to the current quadrant. If MACRO is older than 7 days, warn the user and offer to run /scan-macro first.

  3. Determine preset from $ARGUMENTS:

    • Bare regime tag (r1 / r2 / r3 / r4) → use the strict-regime preset
    • Theme tag (quality / growth / value / defense) → use the named preset
    • Mixed (r3-defense) → combine, document the mix
    • Empty → use the regime-default preset (whatever regime MACRO currently flags)
  4. Build the Finviz screener URL per discover-rules.md filter prefix reference. Validate filter codes — the doc has the verified prefixes (fa_opmargin not fa_opermargin, etc.). A wrong prefix returns 0 silently.

  5. Run the screen via WebFetch on the constructed URL. Extract candidates with their filter-relevant metrics.

  6. 0-results fallback per discover-rules.md § 0-results fallback — if the strict preset returns 0 results, document the strict run, then progressively relax filters (per the documented relaxation order) and re-run. Note every relaxation step in the saved file.

  7. Save to scanned/SCREENS/<YYYY-MM-DD>-<preset>.md (or <YYYY-MM-DD>.md for the default preset). Use the screen-file structure spec in discover-rules.md.

  8. Update scanned/INDEX.md § Recent screens — append the new screen entry.

  9. Self-improvement loop per guide/scan/style.md § Process self-improvement — surface any process problems (broken filter codes, ambiguous instructions, missing edge cases) at the end of your reply. Wait for user consent before editing the rules.

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. 9d ago First seen · 32 lines · 27 tokens per session scan A 2ca30809bd08

Subscribe to this mod's changes

discover is a command published in the GitHub repository l3lackcurtains/trading-ops (56 stars, last pushed 4mo ago), licensed MIT. It adds 27 tokens to every session and 551 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-30.