Official CLI v4
A thin HTTP client for Hedge Layer research, Feed, Signal, and Quote workflows.
Install and authenticate
Node.js 22 or later is required.
npm install -g @hedge-layer/cli
hl auth login
hl feed ensemble --limit 25 --output candidates.json
hl signal analyze "https://polymarket.com/event/example-market"
hl quote example-market --action buy --outcome yes --cash 25Create a token in Settings. The CLI stores it in ~/.hedgelayer/config.json. hl auth logout removes that file only.
Quote
hl quote calls POST /api/quote. It previews public Polymarket book/fee economics and never signs or submits an order. Use exactly one of --cash or --shares; cash is BUY-only.
# Cash-sized BUY
hl quote example-market --action buy --outcome yes --cash 25
# Share-sized BUY or SELL
hl quote example-market --action buy --outcome no --shares 50 --route passive
hl quote example-market --action sell --outcome yes --shares 20
# Add an owned Signal and manual capital, then save the refreshed preview
hl quote example-market --action buy --outcome yes --cash 25 \
--signal-id <forecast-id> --capital 1000 --save
# Machine-readable output
hl --json quote example-market --action buy --outcome yes --cash 25Signal
Signal estimates probability and uncertainty. URL mode is Polymarket; structured market JSON can represent Polymarket or Kalshi.
hl signal analyze "https://polymarket.com/event/example-market"
hl signal analyze "https://polymarket.com/event/example-market" --context "Recent source notes"
hl signal analyze --market ./market.json
cat market.json | hl signal analyze --market -Feed
Feed runs deterministic Polymarket screens. Ensemble combines several discovery lenses, de-duplicates by slug, and writes a reusable candidate file.
hl feed lp-opportunity
hl feed liquid-new-or-long
hl feed --tag crypto --sort-by movement --limit 25
hl feed ensemble --limit 25 --output candidates.jsonResearch and briefs
hl brief "US China trade war tariffs"
hl research
hl research run "US election forecasting"
hl research list
hl research show <id>
hl research delete <id>Account commands
hl auth login
hl auth status
hl auth logout
hl profileGlobal options
--json— machine-readable output.--api-url <url>— override the API base.--token <token>— override the stored token.--verbose— show HTTP request details.--no-color— disable ANSI color.
Command boundaries
v4 has no wallet, asset-transfer, order, or execution command groups. There are no compatibility shims; obsolete commands fail as unknown.