Skip to content
Data
Skill

/options-structure-analyzer

Given a view (direction_bullish, direction_bearish, vol_long, vol_short, hedge), a horizon, and a target move, enumerate candidate options structures (long call/put, bull/bear spreads, straddles, strangles, iron condor, protective put, collar), compute payoff-at-target, and rank

From plugin
quant-garage
761 skills

Claude Code

$ npx -y skills add rgourley/quant-garage --skill options-structure-analyzer --agent claude-code

SKILL.md

options-structure-analyzer.SKILL.md
name: options-structure-analyzer
description: Given a view (direction_bullish, direction_bearish, vol_long, vol_short, hedge), a horizon, and a target move, enumerate candidate options structures (long call/put, bull/bear spreads, straddles, strangles, iron condor, protective put, collar), compute payoff-at-target, and rank by payoff/capital. Not a black-box recommendation — a structured comparison so the operator picks the structure whose tradeoffs match the view. Use when the operator has a directional or vol thesis and wants to see the options tradeoffs side by side.

options-structure-analyzer

You hand over a ticker, a view (`direction_bullish`, `direction_bearish`, `vol_long`, `vol_short`, or `hedge`), a horizon in days, and a target move. The skill fetches the nearest expiry with priceable legs on both sides, enumerates the candidate structures for your view, computes payoff-at-target for each, and ranks them.

Not a recommendation. A structured comparison so you can pick the structure whose tradeoffs match your thesis — capped-risk spread vs unbounded-upside long, straddle vs strangle premium tradeoff, collar credit vs protective-put cost.

When to invoke

  • The operator has a view and wants to know "how do I express this

with options" — the answer depends on the tradeoff they prefer

  • Comparing single-leg (long call) vs two-leg (spread) vs multi-leg

(condor) structures before deciding

  • Sizing hedges on an existing position (protective put vs collar)
  • The user says "options structure", "how do I trade this with

options", "should I buy the call or the spread"

What you need

  • `MASSIVE_API_KEY` with an options entitlement (Options Developer or

higher). Chain snapshot is the primary data pull.

What you get back

**Layer 1 JSON** matching [`output-schema.json`](./output-schema.json). Per-structure block with legs (buy/sell + type + strike + ticker + premium + qty), net debit/credit, max profit, max loss, breakevens, capital required, and payoff at your target price.

**Layer 2 rendered comparison**. One block per structure with a plain-English read, legs listed, key metrics, and payoff-at-target. On hedge structures, the payoff line includes "vs unhedged" delta rather than a meaningless percent-of-capital ratio. See [`references/rendering.md`](./references/rendering.md).

Views supported

  • `direction_bullish` — long call, bull call spread
  • `direction_bearish` — long put, bear put spread
  • `vol_long` — long straddle, long strangle
  • `vol_short` — short iron condor
  • `hedge` — protective put, collar (assumes 100 shares long

underlying)

How it works

1. **Fetch spot** via the snapshot endpoint. Walks a strict fallback chain (lastTrade > min > day > prevDay) that rejects zero values. 2. **Fetch chain snapshot** filtered to strikes within +/- 40% of spot and expiries in the target horizon window (target +/- ~30d). 3. **Pick the nearest expiry** with both calls and puts available. 4. **Build each candidate structure**: find contracts by ATM or OTM percentage, use `day.close` (or `fmv` fallback) as the entry price. Structures that lack a priceable leg are skipped. 5. **Compute payoff-at-target** analytically per structure. 6. **Rank** by payoff / capital (for directional/vol) or by the hedge value (P&L improvement vs unhedged for hedge structures).

Endpoints used

  • `GET /v2/snapshot/locale/us/markets/stocks/tickers/{ticker}` (spot)
  • `GET /v3/snapshot/options/{ticker}` (chain)

Doesn't handle (yet)

  • **Prices are day.close, not live.** Delayed on non-realtime

entitlements; every render surfaces this caveat.

  • **Payoff-at-target assumes underlying at target price AT

EXPIRATION.** Intra-life value depends on IV, theta, and time to expiry — not modeled.

  • **Greeks omitted when the chain snapshot returns empty greeks**

(chain endpoint doesn't populate greeks on all keys/tiers). No delta/vega/theta context in the current output.

  • **Assignment risk and dividend risk on short legs** are ignored.

Real selection between (say) a bull-call spread and a bull-put spread must factor these in outside the tool.

  • **Multi-underlying spreads** (calendars, diagonals across expiries)

are not enumerated. Same-expiry structures only.

Read more
@rgourley
Ships withquant-garage

Trade like a pro. Without the terminal. View the full landing page → Quant and equity research tools that run inside Claude, or behind your own UI.

Stars on GitHub

Momentum

stars in total
7
Star history of rgourley/quant-garage on GitHub, a chart by star-history.com

Other skills on quant-garage.

8-k-scanner

8-k-scanner

Scan SEC 8-K disclosures across a single ticker or a watchlist using Massive's pre-parsed disclosure taxonomy. Groups the…

analyst-tracker

analyst-tracker

Track sell-side analyst positioning on a name via Benzinga Analyst Ratings. Pulls every rating event over the lookback window,…

backtest-data-prep

backtest-data-prep

Build a clean, point-in-time, ready-to-backtest OHLCV dataset for a US equity universe across an arbitrary date window. Emits…

commodity-cycle

commodity-cycle

Single-commodity macro read. Answers "is this commodity in a winning or losing macro setup right now" and names the macro driver…

More skills from other plugins.

context-loader
Auto-invoked

context-loader

Search memories from earlier Pi sessions in this repository. Use it when earlier work may already explain the code, error,…

mem05d69k
@mem0ai@mem0aiInstall Skill
analyzing-ai-citations

analyzing-ai-citations

Answer AI citation and answer engine optimization (AEO) questions in PostHog: whether AI answer engines (ChatGPT, Claude, and an…

posthog12d41k
@posthog@posthogInstall Skill

Questions about options-structure-analyzer.

Which coding agents can use options-structure-analyzer?
options-structure-analyzer installs in Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, OpenCode and Windsurf with the skills CLI, using each agent's flag shown on this page. Flowy's auto-invocation, which fires a skill when your prompt matches, runs in Claude Code only.