HKUDS/Vibe-Trading
A self-hosted trading agent for evidence-linked research and inspectable backtests
Automated SPDX check for reference only — not legal advice. Disclaimer
GitHub Star History
Full-history star trajectory from GitHub official history. Switch ranges or hover any point for exact counts.
Evidence-Backed Technical Brief
AI Deep ReviewArchitecture & Core Mechanics
Vibe-Trading is a Python 3.11+ research agent with a web interface and CLI. Its manifest lists LangChain, LangChain Core, LangChain OpenAI, LangGraph, and LangGraph Checkpoint; the tree separates agent/ from frontend/. A backtest request moves from interpreting the strategy and benchmark to fetching historical bars and running the strategy. The run directory preserves the strategy, trades, and equity curve, allowing a reviewer to inspect the work rather than rely on the generated summary.
In v0.1.20 the session kernel replays an append-only thread.jsonl so that a follow-up can see prior tool calls and results. Messages arriving during execution queue instead of being rejected; sessions can be forked, compacted on demand, or assigned their own model. This working state is distinct from versioned research artifacts, which preserve conclusions and evidence for comparison over time. REST supports workflows such as Alpha Zoo, while MCP exposes callable tools such as portfolio_risk_xray.
Key Capabilities & Differentiators
The workflow spans SEC filing excerpts with original links, uploaded documents, factor research, strategy backtests, and paper portfolios. Alpha Zoo can benchmark libraries such as Alpha101 and GTJA across horizons; Research Lab adds cost and walk-forward studies to completed runs. Backtests can model A-share price limits, crypto funding, or futures margin. Options Lab adds multi-leg payoff analysis, Greeks, implied-volatility surfaces, and strategy comparison.
The loader supports 27 market-data sources. In automatic mode it chooses a fallback chain by market; during backtests it retries only symbols left without bars after validation and aggregation. Explicit local sources and local: symbols never fall back to the network. Paper trading tracks fills and NAV separately from live execution, which requires a supported broker and an authorized, stoppable mandate. Connector count is not execution coverage: OpenAlgo is the 20th connector and is read-only.
Trade-offs & Limitations
Compared with a standalone backtester, Vibe-Trading reduces the handoffs between research, code execution, validation, and follow-up. The cost is a larger reproducibility surface: prompt interpretation, model choice, data routing, and engine changes can all affect comparisons. Pin the strategy, data source and date range, and application version for a repeatable study. Unlike a broker-first terminal, the agent is most useful as a research and simulation workspace; live use calls for separate verification of connector permissions and mandate limits.
Risk X-Ray illustrates why output semantics matter. Its drawdowns describe a constant-weight return model, not account NAV or strategy P&L; for backtests it uses average executed basket weights and excludes fees and cash flows. Missing interior returns or invalid model wealth make drawdown periods unavailable rather than indicating zero risk. Also, v0.1.20 no longer rewrites or redacts answers through the grounding gate. Evidence references and saved run artifacts remain useful for review, but are not a substitute for checking conclusions before acting on them.
Hardware & Deployment Guide
For a direct install, use Python 3.11+, pip install vibe-trading-ai, vibe-trading init, then vibe-trading. Compose builds from the repository, reads agent/.env, binds 127.0.0.1:8899 on the host, and mounts the vibe-runs volume at /app/agent/runs. Its host-side Ollama default is http://host.docker.internal:11434, overridable with OLLAMA_BASE_URL; the supplied Linux host-gateway mapping requires Docker Engine 20.10+ and Compose v2.
With a remote model endpoint, size the application host for backtests, history storage, and concurrent jobs. With Ollama, budget inference resources separately based on the selected model and concurrency; there is no fixed VRAM figure. Local bars can keep backtest data loading off the network, but the model and other tools still determine whether the full workflow is offline. For v0.1.20, back up ~/.vibe-trading/sessions before first start and rebaseline affected benchmark, RSI/Bollinger, and Alpha Zoo comparisons; v0.1.19 introduced versioned research artifacts.
thread.jsonl per session, with replay, queued messages, forks, compaction, and per-session model selection.local sources and local: symbols never fall back to the network.artifacts/risk_xray.json and artifacts/risk_xray.md and exposes the analysis through portfolio_risk_xray over MCP.Researchers and small teams that want to turn natural-language questions into evidence-linked reports, inspectable backtests, and paper portfolios before considering live orders.
You only need a deterministic backtest runner, require an end-to-end offline workflow without first validating every dependency, or need production order execution on a broker whose permissions have not been verified.
Quick Start & Installation
pip install vibe-trading-ai
vibe-trading init
vibe-tradingComparison vs. Top Agents & Frameworks Alternatives
Full comparison →| Repository | Stars | 7d Trend | Stack | License | Core Positioning |
|---|---|---|---|---|---|
| Vibe-Trading ★ | 39.6k | +490 | Python | MIT | A self-hosted trading agent for evidence-linked research and inspectable backtes |
| nanobot | 50.5k | +157 | Python | MIT | A self-hosted Python gateway for personal AI across web, terminal and chat. |
| daily_stock_analysis | 75.9k | +870 | Python | MIT | A Python Agent workbench for multi-market watchlist research and scheduled repor |
| FinceptTerminal | 34.5k | +217 | C++ | AGPL-3.0 | A native C++20/Qt6 terminal for financial research, quant analytics, and AI agen |
AI Context Briefing (for Claude / Cursor / Windsurf)
Standardized architecture summary & quickstart commands ready to paste into coding agents.
curl -sL https://repoforai.com/repo/HKUDS/Vibe-Trading.md
Active README embeds unlock Hot-Tier 6h Telemetry Refresh automatically (zero pay-to-rank).
Frequently Asked Questions about Vibe-Trading
How should I integrate Vibe-Trading with an existing research application?
portfolio_risk_xray. The web UI and CLI support follow-ups backed by replayable thread.jsonl sessions. Treat session history and exported research as distinct: a session preserves the working conversation, while a versioned artifact records a conclusion and its evidence for later comparison.Do I need a GPU, and what determines runtime overhead?
Can we self-host this commercially, and what else should we check?
When is this a better choice than a standalone backtester or broker terminal?
Upstream README & Documentation
This profile focuses on independent engineering analysis and live telemetry. Read the full upstream README, changelog, and examples directly on GitHub.
Top 10 Breakout Open-Source AI Repos, Every Thursday
Signal-only digest of fast-growing AI repos, SPDX license alerts, and architecture picks. Zero spam.
Zero spam · 1-click unsubscribe · Privacy Policy