The crab does not walk forward. The crab does not walk backward. The crab walks sideways β straight to 100x.
An autonomous AI meme agent for $CRAB β a token on pump.fun on Solana.
CA: FzoFZ2XTypgojG9iE3Kuo58ocHFs5zVKDhqwa4Utpump
Fueled by crab brain.
The agent wakes up on a schedule and picks one of 5 modes at random:
| Mode | Description |
|---|---|
hype |
Maximum bullish crab energy |
roast |
Destroys other meme coins |
lore |
Deep $CRAB lore drops |
alpha |
Fake insider whale alpha |
crabwalk |
Sideways metaphors for 100x |
It fetches live token stats from the pump.fun API (price, market cap, volume, holders), and generates a tweet. Optionally posts it to Twitter/X automatically.
git clone https://github.com/adaEggs/crab-agent
cd crab-agent
npm installcp .env.example .envFill in .env:
AI_API_KEY=your_key
CRAB_MINT_ADDRESS=FzoFZ2XTypgojG9iE3Kuo58ocHFs5zVKDhqwa4Utpump # $CRAB mint on pump.fun
TWITTER_API_KEY=... # Twitter developer app credentials
TWITTER_API_SECRET=...
TWITTER_ACCESS_TOKEN=...
TWITTER_ACCESS_SECRET=...
POST_ENABLED=false # flip to true when ready to go live
POST_INTERVAL_MS=3600000 # 1 hour between posts# Dry run β generate one tweet, don't post
npm run dev
# Generate one tweet and exit
npm run once
# Run live agent loop
POST_ENABLED=true npm startπ¦ CRAB AGENT AWAKENS β MODE: LORE
they said the crab was just a meme
they did not know the crab was a mirror
reflecting your portfolio back at you
$CRAB has no roadmap. only claws. π¦
π¦ CRAB AGENT AWAKENS β MODE: ROAST
$PEPE ran out of ideas in 2023
$DOGE is a dog that forgot how to bark
$WIF is a hat with no head
the crab needs nothing.
the crab already won.
pump.fun/CRAB
The agent does not select meme modes randomly. It uses quantum-assisted stochastic wavefunction collapse across an 8-qubit Hilbert space.
|Οβ© = Ξ£ Ξ±α΅’|modeα΅’β© β Hβ8 β oracle β diffusion β measure β mode
Circuit steps:
- Qubit register initialised in ground state
|0β©β8 - Hadamard gate applied β uniform superposition over all meme modes
- Register entangled with market sentiment (pump.fun volume data)
- Two Grover iterations for amplitude amplification
- Decoherence check β environment coupling collapses wavefunction
- Born rule measurement selects final mode
Sample terminal output:
β initialising qubit register...
β applying Hadamard gate Hβ8...
β entangling with market sentiment qubit...
β sentiment_qubit entangled bias_index=1
β grover_iter=1 oracle_target=lore
β grover_iter=2 oracle_target=hype
β env_coupling=0.005821 decoherence=true
β β decoherence detected β collapsing to classical fallback
β measuring wavefunction...
β β wavefunction collapsed mode=roast confidence=91.3%
Gate fidelity: 94.7% β remaining 5.3% lost to crab noise.
The agent remembers everything across restarts via data/memory.json.
Post history β stores every tweet ever generated with timestamps and market conditions. Before posting, runs a duplicate fingerprint check against the last 50 posts. If it generates something too similar, it automatically regenerates (up to 3 attempts).
Market history β records a snapshot every hour: price, market cap, volume, holders. Builds a rolling 30-day dataset used to detect trends and compute averages.
Holder growth tracking β tracks holder count delta each cycle, computing growth rate (holders/hr), peak holders, and trend direction (surging / growing / stable / declining / bleeding).
Every cycle the agent classifies the current market state into one of 5 regimes, each with a different posting strategy:
| Regime | Condition | Strategy |
|---|---|---|
MOON |
Pumping hard, holders surging | 60% hype, 25% alpha |
ACCUMULATION |
Steady growth, quiet phase | 35% lore, 30% alpha |
CONSOLIDATION |
Near ATH, holding | 35% crabwalk, 25% hype |
COOLDOWN |
Volume dropping | 40% lore, 30% roast |
COPE |
Bleeding | 50% roast, 30% lore |
Mode selection uses Thompson sampling β a Bayesian multi-armed bandit algorithm. Each mode has a score (0β1) updated after every post based on holder growth as an engagement proxy. Modes that correlate with holder growth get picked more often. Modes that don't, get picked less β but never zero (exploration is preserved).
Final mode = 60% Thompson (learned) + 40% Quantum (chaos).
The crab's personality evolves every 10 posts:
- Aggression β rises during MOON, drops during COPE
- Lore depth β increases permanently over time (the crab grows wiser)
- Roast frequency β spikes during dumps
Personality traits unlock as milestones:
| Trait | Unlocks at |
|---|---|
seasoned_crab |
10 posts |
ancient_crab |
50 posts |
prophet_crab |
100 posts |
popular_crab |
500+ holders |
moon_crab |
MOON regime |
Each trait changes the crab's voice in the prompt β a prophet_crab speaks in riddles, a moon_crab has witnessed the pump and knows what's coming.
The docs/ folder contains the GitHub Pages site β enable it in your repo settings under Pages β Source β docs folder.
| File | URL |
|---|---|
docs/index.html |
your-username.github.io/crab-agent |
docs/demo.html |
your-username.github.io/crab-agent/demo.html |
crab-agent/
βββ src/
β βββ agent.js β main loop, full pipeline
β βββ pumpfun.js β live token stats from pump.fun
β βββ twitter.js β Twitter API v2 posting
β βββ prompts.js β prompt file loader
β βββ logger.js β coloured terminal output
β βββ quantum/
β β βββ quantumEngine.js β 8-qubit wavefunction mode selector
β βββ memory/
β β βββ memoryStore.js β JSON persistence layer
β βββ learning/
β βββ learningEngine.js β regime detection + Thompson sampling + personality
βββ docs/
β βββ index.html β one-page project website (GitHub Pages)
β βββ demo.html β 1280x720 animated terminal demo
β βββ crab-mascot.png β crab logo used by website
βββ data/
β βββ memory.json β persistent agent memory (auto-generated)
βββ assets/
β βββ banner.svg β GitHub README banner
β βββ logo.svg β square token logo
β βββ crab-mascot.png β crab mascot image
βββ prompts/
β βββ crab_system.txt β base crab personality
βββ scripts/
β βββ push_to_github.sh
βββ .env.example
βββ package.json
- Go to developer.twitter.com
- Create a new project + app
- Enable OAuth 1.0a with Read & Write permissions
- Generate access token + secret
- Copy all 4 credentials into
.env
railway init
railway upSet env vars in the Railway dashboard.
npm install -g pm2
POST_ENABLED=true pm2 start src/agent.js --name crab-agent
pm2 saveEdit prompts/crab_system.txt to change the agent's personality, tone, and rules.
Edit the MODES array in src/agent.js to add or remove posting modes.
Change POST_INTERVAL_MS to control posting frequency (default: 1 hour).
MIT β do whatever you want, the crab is free
built for $CRAB on pump.fun β’ walks sideways
