InvestorBOT is an open-source market research terminal for testing machine-learning trading ideas with historical and intraday data. It combines a Python research backend, walk-forward validation, explicit BUY / SELL / HOLD readings, paper-trading records, news scoring, and a React dashboard.
Research software only. InvestorBOT cannot guarantee profit and is not financial advice. Market data can be delayed, incomplete, or subject to provider terms. Validate every model out of sample and use paper trading before risking money.
The project was built to make quantitative research more accessible and interpretable. Instead of presenting a probability without context, InvestorBOT exposes:
- an explicit action:
BUY,SELL, orHOLD - a directional bias:
BULLISH,BEARISH, orNEUTRAL - model probability and expected next-period return
- proposed action, stop, and target prices when a trade is actionable
- walk-forward performance and reliability verdicts
- transaction-cost-aware backtest metrics
- paper-trading results
- company news sentiment and event-risk context
It supports ordinary Yahoo Finance symbols and Borsa Istanbul symbols such as THYAO.IS, ASELS.IS, and ENTRA.IS. Turkish stock prices are displayed in Turkish lira.
| Component | Purpose |
|---|---|
trading_lab/ |
Data loading, features, models, backtests, walk-forward validation, news, risk, signals, paper trading, and FastAPI |
dashboard/ |
React/Vite terminal dashboard using TradingView Lightweight Charts |
notebooks/signallab_pro_research.ipynb |
Primary Google Colab research and training notebook |
notebooks/colab_starter.ipynb |
Smaller Colab starter workflow |
research_sources/backend_upgrade_notes.md |
High-level research conclusions applied to the backend |
The backend currently supports:
- logistic regression
- random forest
- Extra Trees
- gradient boosting
- histogram gradient boosting
- a soft-voting ensemble
- faster random-forest and Extra-Trees baselines
- symbol-specific checkpoints
- a global multi-symbol model
Model quality is judged with more than classification accuracy. Reports include ROC AUC, walk-forward fold return, positive-fold rate, profit factor, maximum drawdown, expectancy, exposure, Sharpe ratio, trade count, and win rate.
- BUY / BULLISH: probability is above the configured buy threshold.
- SELL / BEARISH: probability is below the configured sell threshold.
- HOLD / NEUTRAL: probability is between the thresholds or reliability gates reject the trade.
- WEAK: insufficient out-of-sample evidence.
- MODERATE: some evidence, but paper confirmation is still required.
- ROBUST: stronger walk-forward consistency; still not a guarantee.
Conflicting signals from external technical summaries and InvestorBOT should be treated as a reason to wait, not as proof that either system is certainly correct.
git clone https://github.com/voltcap/InvestBOT.git
cd InvestBOT
py -3 -m venv .venv
.\.venv\Scripts\Activate.ps1
python -m pip install -r requirements.txt
python -m uvicorn trading_lab.api:app --host 127.0.0.1 --port 8000 --reloadAPI documentation is available at http://127.0.0.1:8000/docs.
In another terminal:
cd dashboard
npm.cmd install
Copy-Item .env.example .env
npm.cmd run devOpen http://127.0.0.1:5173.
For a fully local setup, change dashboard/.env to:
VITE_API_BASE=http://127.0.0.1:8000The primary notebook expects the project at:
/content/drive/MyDrive/Investment
Start FastAPI and expose it with ngrok:
!pip install -q pyngrok uvicorn fastapi
from getpass import getpass
from pyngrok import ngrok
ngrok.kill()
ngrok.set_auth_token(getpass("ngrok authtoken: "))
public_url = ngrok.connect(8000)
print(public_url)Then start the server in a separate Colab cell:
!uvicorn trading_lab.api:app --host 0.0.0.0 --port 8000Set the printed HTTPS endpoint locally in dashboard/.env:
VITE_API_BASE=https://your-ngrok-domain.ngrok-free.devRestart Vite after changing the environment file. Never commit .env or an ngrok authtoken.
The primary notebook defaults to 5-minute BIST research:
DAYTRADING_MODE = True
DAYTRADING_PERIOD = "60d"
DAYTRADING_INTERVAL = "5m"
BENCHMARK = NoneThe intraday BIST benchmark is disabled because Yahoo timestamps for Turkish stocks and index/US benchmark data can fail to align, producing an empty feature frame. A licensed, timestamp-consistent BIST feed is preferable for production research.
Yahoo generally limits how much intraday history is available. The project uses 60d / 5m rather than requesting several years of five-minute bars.
Trained models are stored locally in models/ or model_checkpoints/. These directories are intentionally ignored:
- model artefacts can be large
- checkpoints can become stale
- publishing them may imply a reliability they have not earned
New users should train and validate their own checkpoints against current data.
yfinanceaccesses publicly available Yahoo Finance interfaces and is intended for research/personal use under Yahoo's terms.- BIST data may be delayed and is subject to licensing and distribution restrictions.
- TradingView Lightweight Charts is used for chart rendering and attributed in the dashboard as required by its Apache 2.0 notice.
- News feeds may be incomplete and should not be treated as authoritative or real-time.
No provider credentials are required by the repository. Secrets belong in local environment variables or interactive prompts, never in source files or notebooks.
Before committing changes:
git status --short
git grep -n -I -E "api[_-]?key|auth[_-]?token|client[_-]?secret|BEGIN .*PRIVATE KEY"The repository ignores .env files, private keys, model checkpoints, paper journals, caches, build output, and local data exports.
- No model or terminal can guarantee profitable trades.
- The FastAPI analysis route may train a model on first use, so an uncached symbol can be slow.
- Five-minute Yahoo data is not broker-grade real-time data.
- Symbol-specific models may not generalise to unseen securities.
- The global model must be retrained when its feature schema, timeframe, market, or benchmark setup changes.
- News sentiment is a supporting risk signal, not an independent trading system.
- Broker execution is intentionally not enabled.
python -m compileall trading_lab
cd dashboard
npm.cmd install
npm.cmd run buildIssues and pull requests are welcome. Please include:
- the market and timeframe tested
- a leakage-safe validation method
- transaction-cost assumptions
- walk-forward results
- any new data-provider licensing constraints
Keep live brokerage execution out of default flows and preserve explicit, accessible signal wording.
