Successfully integrated two Cambrian MCP servers as separate action providers for comprehensive blockchain data and AI-powered research capabilities into the multi-agent trading system.
Previous Implementation: Single unified provider handling both servers New Implementation: Two separate providers for better separation of concerns
- Clear Separation: Data operations vs AI/social intelligence
- Independent Configuration: Each provider can be configured separately
- Selective Access: Agents can use one or both providers as needed
- Better Maintainability: Easier to update and debug individual providers
- Type Safety: More specific action signatures per provider
- URL:
https://cambrian-mcp-server-prod-981646676182.us-central1.run.app/mcp - Purpose: DeFi and on-chain data (Solana/EVM focus)
- Capabilities:
- Trending tokens analysis
- Token security metrics
- Price and volume data
- Pool liquidity metrics
- Trader leaderboards
- DEX analytics
- URL:
https://mcp.deep42.org/mcp - Purpose: AI-powered research and social intelligence
- Capabilities:
- AI Orchestration Agent - Multi-tool blockchain research
- Social data and sentiment analysis
- GitHub developer intelligence
- Influencer credibility rankings
- Alpha signal detection
- Project discovery
- Content generation
- Initial: November 23, 2025
- Deep42 Integration: November 23, 2025
- Provider Split: November 23, 2025 (v2)
- Installed
@modelcontextprotocol/sdk@1.22.0via Bun - Package provides MCP client capabilities for connecting to external MCP servers
Files:
app/providers/cambrianDataActionProvider.ts(450+ lines)app/providers/deep42ActionProvider.ts(780+ lines)
Architecture:
- Two independent providers for specialized functionality
- Each provider connects to its respective MCP server
- Unified JSON-RPC interface for all MCP tool calls
- Proper error handling and logging for both providers
- Agents can use one or both providers as needed
Provider: cambrianDataActionProvider
Class: CambrianDataActionProvider
Server: Cambrian Data MCP
-
getTrendingTokens- Solana trending tokens by price/volume- Parameters: orderBy, limit, offset
- Returns: Trending token list with metrics
-
getTokenSecurity- Token security analysis- Parameters: tokenAddress
- Returns: Security scores, risk indicators
-
getTokenPriceVolume- Price and volume data- Parameters: tokenAddress, timeframe (1h-24h)
- Returns: Current price, volume, changes
-
getTraderLeaderboard- Top traders for tokens- Parameters: tokenAddress, interval
- Returns: Top traders, statistics, volumes
Provider: deep42ActionProvider
Class: Deep42ActionProvider
Server: Deep42 MCP
Deep42 Actions:
-
askDeep42Agent⭐ MOST POWERFUL - AI orchestration agent- Parameters: question, continueChatId (optional)
- Uses AI to orchestrate multiple tools automatically
- Provides comprehensive blockchain research
- Supports multi-turn conversations
-
querySocialData- Social data and sentiment agent- Parameters: question, conversationContext (optional)
- Returns: Alpha signals, sentiment, influencer insights
-
getInfluencerCredibility- Influencer rankings- Parameters: minTweets, limit, tokenFocus, timeWindow
- Returns: Credibility scores, track records
-
detectAlphaTweets- High-alpha tweet detection- Parameters: limit, tokenFilter
- Returns: Early signals, opportunities, insights
-
searchProjects- Blockchain project discovery- Parameters: query, technology, category, chain, socialActivity, limit, hasGithub
- Returns: DeFi, NFT, gaming, infra projects
-
analyzeTokenSocial- Deep social analysis for tokens- Parameters: tokenSymbol, daysBack, granularity
- Returns: Sentiment, engagement, influencer mentions
-
getTrendingMomentum⭐ NEW - Trending momentum detection- Parameters: lookbackHours, minVelocity, limit, granularity
- Returns: Tokens with momentum scores, velocities, quality metrics, sentiment
- Business Value: Early trend detection, risk assessment, market timing
File: app/api/agent/prepare-agentkit.ts
Changes:
- Imported
cambrianDataActionProvideranddeep42ActionProvider - Initialized provider instances separately
- Added to provider map with distinct keys:
cambrianData: cambrianDataProviderdeep42: deep42Provider
- Included in default providers list for agents without specific config
File: data/agents.json
Updated Agent:
{
"id": "cambrian-bot",
"name": "Cambrian Social Researcher",
"description": "Social data analyst providing insights from Deep42/Cambrian API",
"strategiesFile": "strategies_cambrian.json",
"triggerHistoryFile": "trigger_history_cambrian.json",
"providers": ["cambrianData", "deep42", "pyth", "dexScreener", "walletAssets"],
"systemPrompt": "...",
"tone": "analytical",
"isActive": true,
"createdAt": 1732400000000
}Agent Capabilities:
- Solana token data (trending, security, price/volume, traders)
- Social sentiment analysis
- Community engagement metrics
- Trending token identification with momentum detection
- Project reputation assessment
- Influencer credibility tracking
- Alpha signal detection
- Analytical tone focused on actionable intelligence
Files:
data/strategies_cambrian.json- Empty array (ready for strategies)data/trigger_history_cambrian.json- Empty array (ready for events)
File: .env.local
Added:
# Cambrian API for social data via MCP
CAMBRIAN_API_KEY=qvhzvNP8K5sGpmlC0xul4MIKCOGqGRRHFile: AGENTS.md
Added Sections:
-
Available Agents - Updated Cambrian Social Researcher (Agent #5)
- Now uses both cambrianData and deep42 providers
- Updated capabilities list
-
Provider System - Split provider descriptions
cambrianData: DeFi/on-chain data (Solana/EVM)deep42: AI-powered social intelligence
-
Model Context Protocol (MCP) Integration - Updated section
- Two separate MCP server URLs
- Two separate provider implementations
- Benefits of separated architecture
- Updated available MCP actions (now 11 total: 4 data + 7 social/AI)
Cambrian Data MCP Server Deep42 MCP Server
↓ ↓
HTTP Transport with API Key HTTP Transport with API Key
↓ ↓
CambrianDataActionProvider Deep42ActionProvider
↓ ↓
AgentKit ActionProvider Interface AgentKit ActionProvider Interface
↓ ↓
└──────────────┬──────────────────────┘
↓
AI Agents (can call both sets of actions)- Standardized Protocol: MCP provides consistent way for AI to interact with external APIs
- Separation of Concerns: Two providers, each focused on specific domain (data vs intelligence)
- API Logic Isolation: API logic stays on respective MCP servers
- Dynamic Capabilities: Tools can be updated server-side without client changes
- Flexible Integration: Easy to add to existing agent workflows, use one or both providers
- Independent Scaling: Each provider can be updated/maintained independently
New Files:
app/providers/cambrianDataActionProvider.ts(450 lines)app/providers/deep42ActionProvider.ts(780 lines)data/strategies_cambrian.jsondata/trigger_history_cambrian.json
Modified Files:
app/api/agent/prepare-agentkit.ts(updated imports and provider map)data/agents.json(updated Cambrian agent providers)AGENTS.md(updated provider system and MCP sections)CAMBRIAN_MCP_IMPLEMENTATION.md(this file, v2 update).env.local(CAMBRIAN_API_KEY)package.json(added @modelcontextprotocol/sdk dependency)bun.lock(updated)
Deleted Files:
app/providers/cambrianActionProvider.ts(replaced by two separate providers)
// User: "What Solana tokens are trending?"
// Agent: Calls getTrendingTokens from cambrianData provider
// Returns: Trending tokens with price changes and volumes
// User: "Show me social momentum for these tokens"
// Agent: Calls getTrendingMomentum from deep42 provider
// Returns: Tokens with high social velocity and quality scores
// User: "What's the sentiment for SOL?"
// Agent: Calls analyzeTokenSocial from deep42 provider
// Returns: Sentiment analysis, engagement metrics, community insightsTo give any agent access to DeFi data or social intelligence:
{
"id": "warren-debuffett",
"providers": ["fearAndGreed", "pyth", "swap", "walletAssets", "dexScreener", "cambrianData", "deep42"]
}-
Test Cambrian Data MCP actions (cambrianData provider):
- Query trending Solana tokens:
getTrendingTokens({ orderBy: "price_change_percentage", limit: 10 }) - Check token security:
getTokenSecurity({ tokenAddress: "So11111111111111111111111111111111111111112" }) - Get price/volume:
getTokenPriceVolume({ tokenAddress: "So11111111111111111111111111111111111112", timeframe: "24h" }) - Get trader leaderboard:
getTraderLeaderboard({ tokenAddress: "...", interval: "24 HOUR" })
- Query trending Solana tokens:
-
Test Deep42 AI-powered actions (deep42 provider):
- Ask AI agent:
askDeep42Agent({ question: "What are the top trending tokens on Solana?" }) - Query social data:
querySocialData({ question: "Show me alpha signals for SOL" }) - Detect alpha tweets:
detectAlphaTweets({ limit: 5 }) - Get influencer rankings:
getInfluencerCredibility({ limit: 10, tokenFocus: "SOL" }) - Search projects:
searchProjects({ category: "DeFi", chain: "solana", limit: 10 }) - Analyze token social:
analyzeTokenSocial({ tokenSymbol: "SOL", daysBack: 7 }) - Get trending momentum:
getTrendingMomentum({ lookbackHours: 24, minVelocity: 1.5, limit: 15 })
- Ask AI agent:
-
Integration testing:
- Start dev server:
bun run dev - Select Cambrian bot in UI
- Test both data-focused and AI-focused questions
- Test trending momentum specifically
- Verify API calls in console logs
- Confirm both providers work independently and together
- Start dev server:
- Solana: trending_tokens, token_security, price_volume, traders_leaderboard, pool transactions, wallet balances
- EVM: Aerodrome, AlienBase, Clones, PancakeSwap, SushiSwap, Uniswap V3 pools
- Price Data: current prices, hourly/daily aggregations, OHLCV data
- DEX Analytics: pool info, liquidity maps, fee metrics, volume analysis
executeDeep42Agent: AI orchestration with multi-tool accessquerySocialDataAgent: Social sentiment and alpha signalsqueryGithubAgent: Developer intelligence (direct/enhanced/hybrid modes)getInfluencerCredibility: Influencer rankings and track recordsdetectAlphaTweets: High-alpha tweet detectiongetTrendingMomentum⭐ NEW: Trending momentum with velocity metricsanalyzeTwitterUserAlphaMetrics: User-specific alpha analysissearchDiscoveredProjects: Project discovery across chainsgetSocialAssociations: Token-influencer associationsqueryRepositoryMarketData: GitHub repo market correlationsgetSentimentShifts: Major sentiment shift detectiongetTokenSocialAnalysis: Deep social analysis for tokensexecuteContentGenerationPipeline: Content generationexecuteResearchPipeline(deprecated): Multi-stage research
Specialization & Scalability:
- Data Server: Optimized for high-frequency on-chain queries, DEX analytics, price feeds
- Deep42 Server: AI-powered analysis, social intelligence, GitHub research
Benefits:
- Separation of concerns (data vs AI)
- Independent scaling and optimization
- Specialized infrastructure for different workloads
- Better fault tolerance (one server down doesn't affect the other)
-
askDeep42Agent(Deep42 provider) - The AI orchestrator that can:- Automatically select and combine multiple tools
- Provide comprehensive research reports
- Support multi-turn conversations with context
- Adapt to complex, open-ended questions
-
getTrendingMomentum(Deep42 provider) ⭐ NEW - Momentum detection:- Early trend detection with velocity metrics
- Quality scores and sentiment analysis
- Risk assessment via engagement patterns
- Market timing insights
- Filter by lookback period and minimum velocity
-
Social Intelligence Stack (Deep42 provider) - Unique competitive advantage:
- Real-time alpha tweet detection
- Influencer credibility tracking
- Sentiment shift detection
- Project discovery with social metrics
- Trending momentum analysis
-
On-Chain + Social Fusion - Combine both providers:
- Get trending tokens from Cambrian Data MCP
- Analyze social momentum from Deep42 MCP
- Cross-reference trader leaderboards with influencer credibility
- Make informed decisions with complete picture
-
Enhanced Provider Coordination:
- Cross-provider query optimization
- Caching layer for frequently accessed data
- Unified error handling across providers
-
Additional Social Metrics:
- Time-series momentum tracking
- Network analysis and influence graphs
- Sentiment trends over time with visualization
-
Strategy Integration:
- Create social momentum-based trading strategies
- Combine Fear & Greed Index with trending momentum
- Alert system for viral tokens and velocity spikes
- Automated trading based on momentum thresholds
- MCP SDK package installed
- Cambrian Data Action Provider created with proper MCP structure
- Deep42 Action Provider created with proper MCP structure
- Both providers registered in AgentKit setup
- Cambrian agent updated with both providers
- Trending momentum action added to Deep42 provider
- Data files exist for agent
- Environment variable configured
- Documentation updated in AGENTS.md and CAMBRIAN_MCP_IMPLEMENTATION.md
- No linting errors
- All todos completed
IMPLEMENTATION COMPLETE v2 ✅
All planned features have been implemented successfully, including:
- Provider split into two separate providers
- Trending momentum endpoint added
- Documentation updated to reflect new architecture
The Cambrian MCP integration is ready for testing and use with improved separation of concerns.