Two starter scripts:
| File | Purpose |
|---|---|
simple_bot.py |
Paper-trade memecoins using /v1/snapshot decisions |
trajectories_explorer.py |
Inspect labeled lifecycle data from /v1/trajectories |
Both require an API key — email dbrouill@gmail.com to get one.
export RAVINE_API_KEY=your_key
python trajectories_explorer.py # top recent homeruns
python trajectories_explorer.py --label loss # losers (most are losers!)
python trajectories_explorer.py --label win --json | jq '.rows[0]'Each row carries the T+0/T+5/T+15/T+30/T+1h/T+24h capture of a labeled token. Train your own model, validate a thesis, or build a "what did winners look like at T+5?" dashboard.
A 100-line paper-trading bot that consumes ravine-api to make exit-or-hold decisions on Solana memecoins.
Pure paper. No wallet. No real orders. Pedagogical demo.
Every 3 minutes:
- Calls
GET /v1/snapshotfor live token list - Opens a paper position on healthy tokens (ravine HOLD, p_rupture < 0.30, fresh entry)
- Closes positions when ravine flags
QUANTUM_EXIT_NOWor p_rupture ≥ 0.70 - Logs everything to
simple_bot.jsonl
pip install requests # or use stdlib urllib (no deps)
python simple_bot.pyWatch the log:
tail -f simple_bot.jsonl | jq -c 'select(.event=="PAPER_SELL")'PAPER_STAKE_USD = 5.0— paper position sizePOLL_S = 180— match the ravine-api 3-min refreshlen(positions) < 3— max concurrent positions- Entry filter:
decision == "HOLD" and p < 0.30 and n_obs >= 6 and 0.0 <= roi_so_far <= 0.15
- Not financial advice
- Not a full trading bot (no wallet, no slippage, no real PnL)
- Not optimized — it's a starting point
Fork this and add:
- Real wallet integration (Jupiter swap aggregator + Solana SDK)
- Better entry logic (combine multiple signals)
- Custom thresholds calibrated to your risk profile
- Persistence + restart-resume
The ravine-api is one tool in the chain. Compose it with your own data and execution layer.
If you start running this 24/7 and see meaningful PnL movement, you'll quickly hit the free tier ceilings:
| Free | Pro |
|---|---|
| 10K calls/day | unlimited |
| 3-min snapshot | 30-second snapshot |
| top 50 tokens | top 200+ |
| alpha wallet counts | full wallet IDs (copy-tradeable) |
| poll-only | webhooks on EXIT_NOW |
Most serious bots upgrade once they're consistent. Pro is $49/mo or 2 SOL/mo: https://kno-innovation.com/api/#pro
MIT.