[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"project-11251":3},{"id":4,"name":5,"fullName":6,"owner":7,"repo":5,"description":8,"homepage":9,"htmlUrl":9,"language":10,"languages":9,"totalLinesOfCode":9,"stars":11,"forks":12,"watchers":13,"openIssues":14,"contributorsCount":14,"subscribersCount":14,"size":14,"stars1d":14,"stars7d":14,"stars30d":14,"stars90d":14,"forks30d":14,"starsTrendScore":14,"compositeScore":15,"rankGlobal":9,"rankLanguage":9,"license":9,"archived":16,"fork":16,"defaultBranch":17,"hasWiki":16,"hasPages":16,"topics":18,"createdAt":9,"pushedAt":9,"updatedAt":19,"readmeContent":20,"aiSummary":21,"trendingCount":14,"starSnapshotCount":14,"syncStatus":22,"lastSyncTime":23,"discoverSource":24},11251,"polymarket-trading-bot-example","LacaveSeb\u002Fpolymarket-trading-bot-example","LacaveSeb","polymarket trading bot polymarket trading bot polymarket trading bot polymarket trading bot polymarket trading bot",null,"TypeScript",99,417,112,0,7.86,false,"main",[],"2026-06-12 02:02:30","# Polymarket BTC 15-Minute Trading Bot\n\n[![Node.js 20+](https:\u002F\u002Fimg.shields.io\u002Fbadge\u002Fnode-20+-339933.svg)](https:\u002F\u002Fnodejs.org\u002F)\n[![License: MIT](https:\u002F\u002Fimg.shields.io\u002Fbadge\u002FLicense-MIT-yellow.svg)](https:\u002F\u002Fopensource.org\u002Flicenses\u002FMIT)\n[![Polymarket](https:\u002F\u002Fimg.shields.io\u002Fbadge\u002FPolymarket-CLOB-purple)](https:\u002F\u002Fpolymarket.com)\n[![Redis](https:\u002F\u002Fimg.shields.io\u002Fbadge\u002FRedis-optional-red.svg)](https:\u002F\u002Fredis.io\u002F)\n\nTypeScript bot for **Polymarket 15-minute BTC up\u002Fdown markets**: Gamma market discovery, CLOB quotes, weighted signal fusion, risk checks, and optional live orders via `@polymarket\u002Fclob-client`.\n\n## Prerequisites\n\n- Node.js 20+\n- Redis (optional) — `btc_trading:simulation_mode` toggle\n- Polymarket wallet private key (`POLYMARKET_PK`) for live trading; CLOB API credentials are derived each run unless you set `POLYMARKET_API_*` in `.env`\n\n## Quick start\n\n### Step 1: Install\n\n\n```bash\ngit clone https:\u002F\u002Fgithub.com\u002FLacaveSeb\u002Fpolymarket-trading-bot-example.git\ncd polymarket-trading-bot-example\nnpm install\nnpm run bot              # development (tsx)\n```\n\nProduction build:\n\n```bash\nnpm run build\nnpm start\n```\n\n## Configuration\n\nCreate `.env` in the **repository root** (same folder as `package.json`). The app loads it via `process.cwd()`.\n\n```env\nPOLYMARKET_PK=\n# Optional — override auto-derived CLOB credentials:\n# POLYMARKET_API_KEY=\n# POLYMARKET_API_SECRET=\n# POLYMARKET_PASSPHRASE=\nPOLYMARKET_FUNDER=\nPOLYMARKET_CHAIN_ID=137\n\nREDIS_HOST=localhost\nREDIS_PORT=6379\nREDIS_DB=2\n\nMARKET_BUY_USD=1\nLOG_LEVEL=info\nGRAFANA_METRICS_PORT=8000\n```\n\n## CLI\n\n| Flag | Description |\n|------|-------------|\n| `--live` | Live trading (requires credentials; real funds at risk) |\n| `--no-grafana` | Disable Prometheus `\u002Fmetrics` server |\n| `--test-mode` | Forces simulation + shorter paper-trade horizon |\n\nDefault is **simulation** (paper trades, `paper_trades.json`).\n\n## Architecture (high level)\n\n```mermaid\nflowchart LR\n  Gamma[Gamma API] --> Markets[Market registry]\n  CLOB[CLOB REST] --> Quotes[Quotes \u002F book]\n  Markets --> Bot[Btc15mBot]\n  Quotes --> Bot\n  Coinbase[Coinbase] --> Bot\n  FNG[Fear and Greed] --> Bot\n  Bot --> Fusion[Fusion engine]\n  Fusion --> Risk[Risk engine]\n  Risk --> Exec[CLOB client or paper]\n```\n\n## Project structure\n\n```text\n├── package.json\n├── tsconfig.json\n├── src\u002F\n│   ├── index.ts\n│   ├── app\u002F                 # Gamma + main bot loop\n│   ├── config\u002F\n│   ├── core\u002Fstrategy-brain\u002F\n│   ├── data-sources\u002F\n│   ├── domain\u002F\n│   ├── execution\u002F\n│   ├── feedback\u002F\n│   └── monitoring\u002F\n└── grafana\u002F                 # dashboard.json (import manually in Grafana)\n```\n\n## Monitoring\n\nWith Grafana exporter enabled, metrics are exposed at `http:\u002F\u002Flocalhost:8000\u002Fmetrics` (Prometheus format).\n\n## Disclaimer\n\nTrading involves significant risk. This software is for educational purposes. Past performance does not guarantee future results. The authors are not responsible for financial losses. Use simulation mode first; only trade amounts you can afford to lose.\n\n## Acknowledgments\n\n- [Polymarket](https:\u002F\u002Fpolymarket.com) — CLOB and markets  \n- [clob-client](https:\u002F\u002Fgithub.com\u002FPolymarket\u002Fclob-client) — TypeScript SDK  ","该项目是一个针对Polymarket平台15分钟BTC涨跌市场的交易机器人，使用TypeScript编写。其核心功能包括Gamma市场发现、CLOB报价、加权信号融合及风险检查，并支持通过`@polymarket\u002Fclob-client`进行实时订单操作。该机器人可选配Redis以增强性能，并提供了模拟交易模式用于测试策略。适用于对加密货币短期波动感兴趣的交易者或希望学习自动化交易系统构建的开发者。",2,"2026-05-29 03:38:59","CREATED_QUERY"]