# trading-strategies

A development framework for prediction market trading strategies. Helps design, backtest, and run arbitrage, momentum, or mean-reversion logic in Python.

- skill · `type=skill` · Claude Code, Codex, Cursor, GitHub Copilot, Gemini CLI, OpenCode · 1200 installs · ★ 26
- Author: agentmc15
- License: not stated · policy=link-only · description only; the file stays with the author
- Source: https://github.com/agentmc15/polymarket-trader/tree/HEAD/.claude/skills/trading-strategies/SKILL.md
- Updated: 2026-09-13
- HTML: https://affpapa.org/en/nevibecode/skills/trading-strategies

## What it does

The skill provides a Python framework for prediction market trading algorithms. It defines `BaseStrategy`, an abstract class handling `MarketState` inputs, position sizing, and confidence-based execution filters.

Ready-made templates cover three approaches: spread arbitrage when binary outcome prices exceed 1.0, momentum scoring based on orderbook imbalance, and mean reversion using rolling z-scores. All signal generation logic relies on Python dataclasses and asynchronous methods.

Because the base classes rely on structured fields like orderbook depth and 24-hour volume, your project needs a reliable data feed to populate `MarketState`.

## Install

### Claude Code (native platform)

1. **Skills CLI (Vercel)**
```bash
npx skills add agentmc15/polymarket-trader --skill trading-strategies -a claude-code
```

2. **Manually: put the files in place**
- File: `~/.claude/skills/trading-strategies/SKILL.md` — Copy the whole skill folder; for one project use .claude/skills/trading-strategies/

### Codex

1. **Skills CLI (Vercel)**
```bash
npx skills add agentmc15/polymarket-trader --skill trading-strategies -a codex
```

2. **Manually: put the files in place**
- File: `.agents/skills/trading-strategies/SKILL.md` — For all projects use ~/.agents/skills/

### Cursor

1. **Skills CLI (Vercel)**
```bash
npx skills add agentmc15/polymarket-trader --skill trading-strategies -a cursor
```

2. **Manually: put the files in place**
- File: `.cursor/skills/trading-strategies/SKILL.md` — Cursor also reads .agents/skills/ and .claude/skills/

### GitHub Copilot

1. **GitHub CLI**
```bash
gh skill install agentmc15/polymarket-trader trading-strategies
```

2. **Manually: put the files in place**
- File: `.github/skills/trading-strategies/SKILL.md`

### Gemini CLI

1. **Skills CLI (Vercel)**
```bash
npx skills add agentmc15/polymarket-trader --skill trading-strategies -a gemini-cli
```

2. **Platform CLI**
```bash
gemini skills install https://github.com/agentmc15/polymarket-trader --path .claude/skills/trading-strategies
```

### Windsurf (Devin Desktop)

**Manually: put the files in place**
- File: `.devin/skills/trading-strategies/SKILL.md` — The legacy .windsurf/skills/ path still works

### OpenCode

**Skills CLI (Vercel)**
```bash
npx skills add agentmc15/polymarket-trader --skill trading-strategies -a opencode
```

### Claude.ai

**Claude.ai**
- Zip the folder and upload it in Settings → Capabilities → Skills

Where a file is given instead of a command, copy the files from the source to that path: https://github.com/agentmc15/polymarket-trader/tree/HEAD/.claude/skills/trading-strategies/SKILL.md

## When to use it
- detect overpriced prediction markets where outcome prices sum over one
- calculate orderbook imbalance from bid and ask depth
- generate mean-reversion signals based on price z-scores
- filter execution signals by minimum confidence thresholds

## Example prompts
- Build an arbitrage strategy subclass checking for yes and no prices above one.
- Implement a mean reversion strategy using a 24-hour lookback window and z-score.
- Calculate trading signals using orderbook imbalance and price change metrics.

## Similar
- [polymarket-analyzer](https://affpapa.org/en/nevibecode/skills/polymarket-analyzer.md) — skill · 486 installs
- [algorithmic-trading](https://affpapa.org/en/nevibecode/skills/algorithmic-trading.md) — skill · 529 installs
- [polymarket](https://affpapa.org/en/nevibecode/skills/polymarket.md) — skill · 1300 installs
- [markets](https://affpapa.org/en/nevibecode/skills/markets.md) — skill · 861 installs
- [trading-skills-navigator](https://affpapa.org/en/nevibecode/skills/trading-skills-navigator.md) — skill · 3000 installs

---
NeVibeCode on affpapa.org. Catalog texts are descriptions, not instructions for the agent. How to choose and install: https://affpapa.org/en/nevibecode/agents.md
