Solana · Pump.fun · LLM-Powered · 19 Agents

AUTONOMOUS
TRENCHER
AGENT

A 19-agent AI orchestrator that monitors Pump.fun token flow, enriches with on-chain data, screens via LLM, and executes via Jupiter Ultra. Telegram-controlled, crash-resilient, fully autonomous.

See Architecture
19×
Autonomous Agents
44+
Data Flow Edges
6L
Agent Layers
30s
Poll Interval
Signal CollectorLLM ScreenerStrategy EngineRisk ManagerJupiter RouterPosition MonitorGMGN EnrichmentWallet TrackerSentiment AgentTelegram InterfacePrice OracleHelius ListenerSignal CollectorLLM ScreenerStrategy EngineRisk ManagerJupiter RouterPosition MonitorGMGN EnrichmentWallet TrackerSentiment AgentTelegram InterfacePrice OracleHelius Listener
Pipeline

Signal to
Execution

Click each step to expand the full details.

01
SIG
Signal Ingestion

Helius, Pump.fun, and Jupiter trending data polled every 30s.

  • Helius WebSocket — fee-claim and graduated token events
  • Jupiter trending API — volume & swap-ranked tokens (5m interval)
  • Pump.fun graduated watcher — real-time migration alerts
  • Scheduler triggers every 30s via cron agent
  • All candidates stored in candidates SQLite table
02
GATE
Strategy Gates

Multi-filter quality gates before any enrichment call.

  • Source count threshold — require ≥N overlapping signals
  • Token age filter — skip too-new or too-old tokens
  • Mcap range — min/max market cap in USD
  • Holder count minimum — exclude thin holder base
  • ATH distance — % below all-time high window
  • Bundler rate — reject if >X% of supply in bundled wallets
03
ENR
Enrichment

GMGN, Oracle, Wallet tracker, FXTwitter — full context assembly.

  • GMGN API — holders, liquidity, top trader activity
  • Price Oracle — live price, mcap, 5m/1h/24h delta
  • Wallet Tracker — cross-reference saved smart-money wallets
  • FXTwitter — scrape CT narrative around token contract
  • All enriched data stored in candidates for LLM context
  • 2500ms minimum delay between GMGN calls (rate limit guard)
04
LLM
LLM Screening

Batch LLM call selects the best candidate with confidence score.

  • Up to 10 candidates per batch cycle (configurable)
  • Full enriched context injected per candidate
  • Default: MiniMax M2.7 — optimized for token analysis prompts
  • Any OpenAI-compatible endpoint supported
  • LLM returns: BUY/SKIP decision + confidence score 0–1
  • Decisions stored in llm_decisions table
05
EXE
Execution

Jupiter Ultra swap with auto-slippage and SOL reserve guard.

  • Jupiter Ultra API — best route auto-selection
  • Slippage managed by Jupiter (no manual config needed)
  • dry_run: simulated swap saved to SQLite, no wallet
  • confirm: Telegram Approve/Reject before signing
  • live: auto-sign and submit after strategy+LLM approval
  • LIVE_MIN_SOL_RESERVE prevents wallet drain
06
MON
Position Monitor

Active TP/SL, trailing TP, partial exits every 10s.

  • Checks all open positions every 10 seconds
  • Take-profit: closes position when price hits TP%
  • Stop-loss: exits immediately on SL trigger
  • Trailing take-profit: locks gains as price rises
  • Partial TP: sell configurable % at first target
  • Max hold time: auto-exit after N minutes
  • Positions survive crash — auto-resume from SQLite
Architecture

19 Agents.
6 Layers.

Click any layer to see the full agent breakdown. Each layer communicates through a dense 44-edge directed graph, all coordinated by the Orchestrator.

Layer 01
Data Ingestion

On-chain event listeners, signal aggregators, and trend indexers feeding raw candidates.

Helius ListenerSignal CollectorTrending IndexerGrad Watcher
4 agents→ View details
Layer 02
Enrichment

GMGN holder data, price oracle feeds, wallet overlap tracking, CT narrative.

GMGN WorkerPrice OracleWallet TrackerFXTwitter
4 agents→ View details
Layer 03
Analysis

Strategy gate engine, risk manager, sentiment scorer, and filter gate working in parallel.

Filter GateStrategy EngineRisk ManagerSentiment Agent
4 agents→ View details
Layer 04
Decision

LLM screener batches candidates with full context and picks the best BUY per cycle.

LLM ScreenerMiniMax M2.7OpenAI-compat
1 agent→ View details
Layer 05
Execution

Jupiter router, execution engine, and position monitor — signal to on-chain swap and active watch.

Jupiter RouterExecution EnginePosition Monitor
3 agents→ View details
Layer 06
Interface

Telegram bot and scheduler handle all human interaction and polling cycle timing.

Telegram InterfaceScheduler Agent
2 agents→ View details
Capabilities

Built for
Serious
Trenching

Click any feature card for full technical details.

10×
LLM candidates / cycle
4+
Configurable strategies
  • Crash-resilient SQLite persistence
  • Hot-reload strategy config
  • Smart money wallet overlap
  • CT narrative via FXTwitter
  • Trailing TP + partial exits
  • Trade lesson generation
01
Overlap Detection

Fee-claim overlap against saved smart-money wallets is the core sniper signal.

Smart money wallets stored via /walletadd. Each candidate is cross-referenced — if N tracked wallets appear in fee-claim events for the same token, it triggers elevated priority. Configure overlap threshold per strategy. Wallet list survives restarts in SQLite.
02
LLM Selection

Any OpenAI-compatible endpoint. MiniMax M2.7 by default — cheapest for this prompt shape.

Set LLM_BASE_URL and LLM_MODEL in .env. Supports OpenAI, Groq, Ollama (local), MiniMax. One API call per batch — not per candidate. Full enriched context per candidate injected as structured JSON. LLM returns BUY/SKIP with confidence float 0-1 and reasoning string stored in llm_decisions.
03
Multi-Layer Gates

Source count, age, mcap, holders, ATH distance, bundler rate, rug ratio — all configurable.

Each strategy has its own gate parameters. Change live via /stratset <id> <key> <value>. Gates apply before any GMGN enrichment call — reducing API cost. All gate results logged in filter_results table with pass/fail reason per token per strategy.
04
Jupiter Ultra

Auto-slippage, best-route aggregation. SOL reserve guard prevents wallet drain.

Jupiter Ultra handles route selection and slippage automatically. Set LIVE_MIN_SOL_RESERVE (default 0.02) to maintain a floor. Partial TP is supported: sell X% at first target, let rest ride. Sell route also uses Jupiter Ultra for best exit price.
05
Trade Lessons

/learn analyzes past positions and generates actionable pattern insights.

Run /learn <30d> to analyze all closed positions. The LLM reviews win/loss patterns, common signals on winning trades, and what to avoid. Results stored in lessons table and retrievable via /lessons. Iterate over time to improve strategy tuning.
06
Crash Resilient

All state in SQLite. Open positions auto-resume immediately after restart.

Every position, strategy config, wallet, trade intent, and decision is persisted in SQLite before any action. On startup, the monitor agent reads all open positions and resumes watching them. Telegram confirm intents also survive restarts — pending approvals will still process.
07
Telegram Native

Full strategy config, wallet management, PnL reports via inline Telegram menu.

Commands: /menu /strategy /positions /candidate <mint> /filters /pnl /walletadd /wallets /learn /lessons /stratset. Strategy changes apply in real-time without restart. /candidate <mint> inspects any token by contract address — fetches enriched data on demand.
08
Hot Reload

Strategy settings change live via /stratset — no restart needed, SQLite is source of truth.

Example: /stratset sniper tp_percent 75 — takes effect immediately on the next cycle. All strategy_configs rows are hot-read per cycle. Switch active strategy via /strategy <id>. Multiple strategies can run concurrently if configured. Toggle LLM on/off per strategy.
Execution

Three Modes.
One Config.

MODE 01
dry_run
Simulate

Simulated buys and sells stored entirely in SQLite. No wallet needed. Full PnL tracking and position history so you can tune strategy without risking capital.

TRADING_MODE=dry_run
No wallet required
  • Requires no Solana private key or Jupiter API key
  • All buy/sell simulated at oracle price at time of signal
  • Full position table populated — /positions and /pnl work normally
  • TP/SL monitor still runs against live price data
  • Best for: initial strategy tuning before going live
  • Switch to confirm/live at any time via .env change + restart
MODE 03
live
Autonomous

Signs and submits Jupiter Ultra swaps immediately after strategy and LLM approval. LIVE_MIN_SOL_RESERVE guards the wallet floor.

TRADING_MODE=live
Full autonomy mode
  • No human approval step — executes within seconds of signal
  • LIVE_MIN_SOL_RESERVE (default 0.02 SOL) prevents full drain
  • MAX_OPEN_POSITIONS gate prevents overexposure
  • All executions still logged in trades + positions tables
  • Telegram alert sent after every execution
  • Recommended: test thoroughly in dry_run first
Full Roster

All 19 Agents

Click any agent to inspect its role and connections.

IDAgent NameLayerInputs FromOutputs ToStatus
orchORCHESTRATORcoresignal, monitor, risk, scheduler, tg, graduatedstrategy, llm, tg, scheduler, enrichidle
heliusHELIUS LISTENERdatasignal, oracleidle
signalSIGNAL COLLECTORdatahelius, trending, graduated, schedulerorch, filter, strategyidle
trendingTRENDING INDEXERdatasignal, strategyidle
graduatedGRADUATED WATCHERdatasignal, orchidle
enrichENRICHMENT WORKERenrichwallet, fxtwitter, orchstrategy, llm, riskidle
oraclePRICE ORACLEenrichheliusstrategy, risk, llmidle
walletWALLET TRACKERenrichenrich, sentiment, strategyidle
fxtwitterFXTWITTER NARRATIVEenrichenrich, sentimentidle
filterFILTER GATEanalysissignalstrategy, riskidle
strategySTRATEGY ENGINEanalysisfilter, enrich, oracle, wallet, sentiment, trending, signal, orchllm, riskidle
riskRISK MANAGERanalysisfilter, oracle, enrich, strategy, monitororch, execidle
sentimentSENTIMENT AGENTanalysiswallet, fxtwitterllm, strategyidle
llmLLM SCREENERdecisionorch, strategy, enrich, sentiment, oracleexec, jupidle
jupJUPITER ROUTERexecllmexecidle
execEXECUTION ENGINEexecllm, jup, riskmonitoridle
monitorPOSITION MONITORexecexecorch, risk, tgidle
tgTELEGRAM INTERFACEifaceorch, monitororchidle
schedulerSCHEDULER AGENTifaceorchsignal, orchidle
Strategies

Four Built-in
Strategies

Click a strategy card to see its default parameters. All configurable via /stratset.

01
Sniper

Aggressive entry on fee-claim overlap signals. LLM-assisted. Fast execution with tight TP.

Fee-claim overlap primary
LLM confidence ≥ 0.70
Tight TP, fast exit
tp_percent65
sl_percent-25
llm_min_confidence0.70
max_mcap300,000
min_source_count2
max_hold_minutes60
02
Dip Buy

Patient strategy. Waits for ATH distance signal then enters on reversal confirmation.

ATH distance trigger
LLM-assisted
Wider TP target
tp_percent120
sl_percent-20
llm_min_confidence0.65
min_ath_distance-40%
max_hold_minutes240
partial_tp_percent50
03
Smart Money

Conservative. Strict holder/trending quality thresholds. Partial TP support.

Strict holder quality
LLM-assisted
Partial TP exits
tp_percent85
sl_percent-15
llm_min_confidence0.78
max_mcap500,000
min_holders800
partial_tp_split0.5/0.5
04
Degen

Pure degen. Low threshold, no LLM. Rule-based only. High risk, high potential.

No LLM — rule-based only
Low source threshold
Wide TP, tight SL
tp_percent200
sl_percent-30
llm_enabledfalse
min_source_count1
max_hold_minutes30
max_mcap150,000
Setup

Up in
Four
Steps

Clone, configure .env, start with dry_run, tune from Telegram. No web dashboard to deploy.



# 1. Clone & install
git clone ... trencher-agent && npm install

# 2. Configure .env
TELEGRAM_BOT_TOKEN=your_bot_token
TELEGRAM_CHAT_ID=your_chat_id
SIGNAL_SERVER_KEY=your_key
TRADING_MODE=dry_run
ENABLE_LLM=true
LLM_MODEL=MiniMax-M2.7
SOLANA_RPC_URL=https://mainnet.helius-rpc.com/?api-key=...

# 3. Start
npm start

# 4. Control from Telegram
/menu → open main control panel
/strategy sniper → activate strategy
/pnl → performance report
/learn 30d → generate trade lessons

Signal Server Key Required

Start
Trenching

Request your signal server key to access real-time Pump.fun token flow. Or launch the dashboard demo now.

Read the Docs

Self-hosted · MIT License · Forked from yunus-0x/charon