GGitHub采集材料
LLM交易智能体的图表分析与风控
发布时间未知 · 北京时间
原文与观测指标
1 个来源GGitHub
查看原文 LLM交易智能体的图表分析与风控
qrak星标138采集时的累计值
每小时增长待观察星标 / 小时 · 观测区间平均值
最近提交10-28 14:24提交时间不是项目发布时间
发布时间:未知 · 首次发现 10-28 14:30 · 北京时间
指标采集:10-28 14:30 · 指标已取得
项目文档有线索安装说明有线索使用说明有线索示例有线索
仅反映文档与示例线索,未实际运行项目。
摘要
项目用多模态模型分析BTC/USDC图表、技术指标、新闻和已平仓交易记忆,再通过确定性风控规则决定模拟交易,并提供运行步骤和结果账本。材料注明默认纸面交易,报告数据不构成盈利优势证据。
摘要由 AI 生成,请以原文为准。观测历史 · 最近 1 条 展开 / 收起
缺失不计为零;增长只比较同一指标来源的有效记录,按实际间隔折算每小时。上游缓存可能延迟数值更新。
| 采集时间 · 北京时间 | 指标 | 数值 | 来源 | 状态 |
|---|---|---|---|---|
| 10-28 14:30:38 | Star | 138 | GitHub 公开页面 | 已取得 |
采集原文 展开 / 收起
LLM_trader
LLM trading agent for BTC/USDC: chart vision, 768D memory of its own closed trades, deterministic risk gates and a public live dashboard.…
项目说明 展开 / 收起
Semantic Signal — an LLM trading agent that reads charts and remembers its closed trades Read this in: English · Polski · 中文 · 日本語 · 한국어 · Español · Deutsch · Português · Русский A single bot on BTC/USDC. Every four hours it renders the candles into a 1920×1080 chart, sends the image together with 79 Numba-compiled indicators, the news context and its own closed-trade memory to a multimodal model, and passes the answer through deterministic risk gates before booking a paper trade. Paper trading by default; no real funds are involved. Live dashboard semanticsignal.qrak.org Showcase site qrak.org — source: qrak/semantic-signal-site Result ledger docs/RESULTS.md Agent rules AGENTS.md Results Window: 2026-09-20 → 2026-10-26 (36 days), BTC/USDC, 4h candles, 10 000 USDC simulated capital. Source: the bot's own ledger (data/trading/), reproducible with python scripts/results_report.py. metric bot buy & hold Return +0.14% (+$13.95) −1.49% Closed trades 12 — Win rate 41.7% (5W / 5L) — Profit factor 1.41 — Sharpe / Sortino 0.19 / 0.36 — Max drawdown −0.25% — Best / worst trade +4.06% / −2.60% — Inference cost $6.02 (8.1M in / 3.8M out tokens) — Net after inference +$7.93 — Analyses 48 cycles, median 266 s, $0.0121 each — Over those 36 days the bot returned +0.14% while the underlying fell 1.49%. That is ~1.6 percentage points on twelve trades — not evidence of an edge. The paper book records zero fees, so the number is gross of trading costs; at a 0.15% round trip the gain would be roughly erased. Two trades are excluded from the statistics because their sandbox fills diverged from the real market. The numbers above are the 2026-10-26 measurement; the inference cost and cycle totals move with every cycle the bot runs. Method, per-trade table and the reproduction command: docs/RESULTS.md. Quick start git clone https://github.com/qrak/LLM_trader.git && cd LLM_trader python -m venv .venv && source .venv/bin/activate # Windows: .venv\Scripts\Activate.ps1 pip install -r requirements.txt -c constraints.txt cp keys.env.example keys.env # or export one provider key; `provider = local` needs none python start.py # dashboard at http://localhost:8000 Python 3.13 only, ~3 GB of disk, one API key (or a local LM Studio server). Platform launchers, Windows quirks and the full secret table: docs/SETUP.md. Features Feature Notes Brain with memory ChromaDB stores closed-trade experiences, semantic rules and blocked trades. Each prompt carries the 3 nearest trades, win rate over the 20 nearest, 3 learned rules and up to 5 post-mortems, not the whole database. Chart vision A 1920×1080 candlestick PNG is sent with the numeric indicator stack, so the model can read pattern geometry from the image as well as from the numbers. Reflection Rules learned from closed trades carry a surprise ratio, abs(realized − expected) / expected, so outcomes driven by noise are discounted. Claim validation Model-reported trend strength is compared with the computed ADX, pattern quality is replaced by a deterministic scorer, and the EV framework is computed from the bot's own closed trades. Risk pipeline Guard chain, an R/R floor the brain can only raise, and dynamic SL/TP. With the executor live, the stop runs against the real market; the exchange leg is a backstop. RAG news RSS + Crawl4AI + CoinGecko/DeFiLlama/Alternative.me, relevance-scored locally and capped by the prompt budget. Multi-provider A configurable chain: provider = all walks Google → DeepSeek → LM Studio → OpenRouter → BlockRun (a chart goes Google → DeepSeek → OpenRouter → BlockRun), and a failed provider degrades to the next one inside the same cycle. This deployment runs provider = deepseek. Tests 2,514 collected tests covering LLM output corruption, async races, rate-limit backoff, closed-loop feedback and spot/futures wiring, with real temporary SQLite and ChromaDB. Long version, with the file that implements each of them: docs/FEATURES.md. Architecture flowchart TB subgraph Data["Data Sources"] EX["Exchanges (CCXT) → OHLCV + Order Book + Trade Flow"] NEWS["RSS Feeds + Crawl4AI + trafilatura"] FUND["CoinGecko + DeFiLlama + Alternative.me"] end subgraph Analysis["Analysis Engine"] TC["Technical Calculator<br/>79 Numba-compiled indicator functions"] PE["Pattern Engine<br/>Deterministic indicator patterns"] CG["Chart Generator<br/>1920×1080 PNG"] RAG["RAG Engine<br/>News relevance scoring"] end subgraph Brain["🧠 Brain Layer"] VM["Vector Memory<br/>ChromaDB (3 collections)<br/>Experiences + Rules +<br/>Blocked trades"] REFL["Reflection Engine<br/>Rules from closed trades"] CTX["Context Builder<br/>Similarity retrieval +<br/>surprise ratio + confidence calibration"] end subgraph Execution["Paper Execution"] RP["Risk Manager<br/>SL/TP, sizing, R:R,<br/>friction tracking"] GP["Guard Pipeline<br/>Symbol → Size"] STRAT["Trading Strategy<br/>ExitMonitor +<br/>PositionStatusMonitor"] end Data --> Analysis Analysis --> Brain Brain --> AI["AI Provider<br/>(DeepSeek / Gemini / OpenRouter / LM Studio / BlockRun)"] AI --> RP --> GP --> STRAT STRAT -.->|Closed trade feedback| Brain Loading Testing python -m pytest tests -q # 2,514 tests, ~145 s ruff check src scripts start.py # clean pyright src start.py # 0 errors Four areas — domain_trading (signals, orders, exits, risk, post-mortem), domain_brain (vector memory, rules, scoring), domain_rag_indicators (news pipeline, indicator maths) and domain_infra (providers, dashboard, persistence) — plus a Playwright check of the admin UI, marked integration so CI skips it. Parametrisation multiplies the collected count, so it is larger than the number of def test_ functions. CI runs the same gates on every push: ruff, pyright, pytest -m "not integration" and CodeQL. The showcase site is built and deployed from its own repository. Documentation map File Scope AGENTS.md Authority, architecture, config, code/security conventions, verification gates — plus one file per package (8 total) docs/FEATURES.md Every feature in detail, with the implement