- Add extractTwitterTokens() to detect $TOKEN mentions (e.g., $BONK, $SOL)
- Add extractContractAddresses() for Solana (base58) and Ethereum (0x) addresses
- Add extractTradingPairs() to detect TOKEN/SOL, TOKEN/USDT patterns
- Update extractPageContext() to use new detection functions
- Add detectedTokens field to PageContext interface
- Create DetectedTokensList component to display detected tokens
- Integrate DetectedTokensList into ChatInterface
- Add handleDetectedTokenClick to analyze selected tokens
- Support auto-detection on Twitter, generic pages, and DexScreener
Implements Task 2: Multi-Page Token Detection
Part of hybrid token detection system (manual search + auto-detect)
- Add search input field to ChatHeader component
- Search bar works on any page, not just DexScreener
- Supports token symbol, name, or contract address search
- Add onTokenSearch callback to handle search queries
- Implement token analysis widget display on search
- Part of hybrid token detection system (manual + auto-detect)
Implements Task 1: Add Universal Token Search Bar
- Create scripts/fix-build-paths.js to convert absolute paths to relative
- Update build script to run fix-build-paths.js after plasmo build
- Add build:raw script for raw plasmo build without fix
Problem: Plasmo generates HTML with absolute paths (href="/file.css")
which causes ERR_FILE_NOT_FOUND in Chrome extensions.
Solution: Post-build script replaces /path with ./path
- Fix escaped quotes in ThreadGeneratorPanel.tsx (root cause of build error)
- Update tsconfig.json to use jsx: react-jsx instead of preserve
- Upgrade Plasmo to v0.90.5 (latest version)
- Build now succeeds in 4.7s
Root Cause: ThreadGeneratorPanel.tsx had escaped quotes (\") instead of
normal quotes ("), causing SWC parser to fail with 'Unexpected token div' error.
This was a file encoding issue, not a Plasmo version issue.
Fixes #build-error
- Remove 'engines' field from package.json (workaround for Plasmo issue #1040)
- Fix operator precedence in ChatInterface condition
- Resolves 'Failed to resolve popup.tsx' error
Note: Still encountering 'Unexpected token div' JSX error during build.
This appears to be a separate Plasmo bundler issue unrelated to our code changes.
- Add sidepanel folder to Tailwind content paths (root cause of broken CSS)
- Fix ChatInterface layout: group ChatInput and QuickCapture properly
- Remove sticky positioning from QuickCapture (now in flex container)
- Make TokenInfoCard buttons more compact for narrow screens
- Improve TokenAnalysisWidget button layout with flex-wrap
- Create 5 widget wrappers for inline chat display:
* WhaleActivityWidget - Wraps WhaleActivityFeed for whale transaction display
* TradingSuggestionWidget - Wraps TradingSuggestionPanel for entry/exit suggestions
* PortfolioWidget - Wraps PortfolioPanel for portfolio tracking
* ChartCaptureWidget - Wraps ChartCapturePanel for chart screenshots
* ThreadGeneratorWidget - Wraps ThreadGeneratorPanel for Twitter threads
- Update widgets/index.ts to export new widgets with Epic grouping
- Update ChatMessages.tsx:
* Add 5 new widget types to MessageWidget union
* Import new widget components and their types
* Add renderWidget cases for all new widgets with proper callbacks
* Update component documentation to list all supported widgets
- Widget integration pattern:
* Widgets wrap panels in containers with consistent styling
* All widgets support callback props for user interactions
* Widgets can be embedded inline in assistant messages
* Widget actions are handled via onWidgetAction callback
Enables AI to display Epic 2, 3, 4 panels inline in chat conversations
- Add TokenAnalysisPanel.tsx for comprehensive token analysis
* AI-generated summary with buy/hold/sell/avoid recommendation
* Contract analysis (verified, renounced, proxy, source code)
* Holder distribution with top 10% concentration
* Liquidity analysis with LP lock status and duration
* Volume trends and trading activity metrics
* Price history (ATH/ATL, 7d/30d changes, volatility)
* Social sentiment analysis (Twitter, Telegram, Reddit)
- Add TradingSuggestionPanel.tsx for entry/exit suggestions
* Entry zone recommendations with reasoning
* Multiple take-profit targets (3 levels) with confidence scores
* Stop-loss suggestions with invalidation reasoning
* Risk/reward ratio calculation and assessment
* Technical analysis levels (support/resistance)
* AI reasoning and invalidation conditions
- Add PortfolioPanel.tsx for portfolio tracking
* Total portfolio value with 24h change
* Holdings list with current value and P&L tracking
* Performance analytics (best/worst performers, win rate)
* Quick actions per token (analyze, alert, view)
* Manual position entry support
- Add comprehensive mock data for all Epic 3 components
* MOCK_TOKEN_ANALYSIS with realistic metrics
* MOCK_TRADING_SUGGESTION with entry/exit levels
* MOCK_PORTFOLIO with 5 holdings and analytics
Implements Stories 3.1, 3.2, 3.3 from Epic 3: Trading Intelligence
- Add crypto_realtime.py with get_live_token_price and get_live_token_data tools
- Register real-time tools in registry.py (no dependencies required)
- Export tool factories in __init__.py
- Create LiveTokenPriceToolUI component for real-time price display
- Create LiveTokenDataToolUI component for comprehensive market data
- Register tool-ui components in new-chat page
Hybrid Architecture:
- RAG (search_knowledge_base): Historical context, trends from indexed data
- Real-time tools: Current prices, live market data via direct API calls
- AI agent decides which to use based on query intent
- Added DexScreener connect form and config components
- Added connector icon, benefits, and documentation
- Updated connector enums and types
- Added dexscreener.mdx documentation
This completes the DexScreener integration UI for the frontend.
- Added DEXSCREENER_CONNECTOR to _CONNECTOR_TYPE_TO_SEARCHABLE in chat_deepagent.py
- This fixes LLM's inability to search DexScreener data despite it being indexed
- Root cause: connector was enabled in DB but missing from mapping, causing it to be filtered out
- Verified: LLM now successfully retrieves WETH price (~$2,442) with DexScreener citations
Related files:
- chat_deepagent.py: Added connector mapping
- knowledge_base.py: Added debug logging for DexScreener search
- connector_service.py: Fixed metadata field names (base_symbol, quote_symbol, dex)
- 85_add_dexscreener_connector.py: Migration for connector type
- Import DexScreenerIndexer in schedule_checker_task.py
- Enable periodic sync support for DexScreener connector
- Ensures automated token data updates work correctly
- Add Story 1.1: DexScreener Connector Backend (complete)
- Add Story 1.2: DexScreener Connector Frontend UI (ready for dev)
- Add implementation plan with architecture decisions
- Include assets and documentation structure
- Stories follow BMAD methodology for AI-driven development
- Add pytest, pytest-asyncio, pytest-mock to dev dependencies
- Configure pytest in pyproject.toml with async support
- Create tests directory structure with conftest.py
- Set up unit test framework for connector testing
- Enable automated testing for backend components
- Create app/utils/airtable_token_utils.py for token refresh logic
- Update all connectors to use centralized token refresh function
- Affected connectors: airtable, clickup, confluence, discord, jira, notion, slack, teams
- Improves code reusability and maintainability
- No functional changes, pure refactoring
Core Implementation:
- Add DexScreenerConnector class with public API integration
- Implement token pair data fetching and indexing
- Add API routes: add, delete, test endpoints
- Register connector in task indexers and Celery tasks
- Add DEXSCREENER_CONNECTOR enum to database models
Features:
- Support up to 50 tokens per connector
- Track prices, volume, liquidity across multiple DEXs
- EVM and Solana address validation
- Periodic sync support
- No API key required (public DexScreener API)
API Endpoints:
- POST /api/v1/connectors/dexscreener/add
- DELETE /api/v1/connectors/dexscreener
- GET /api/v1/connectors/dexscreener/test
All endpoints require JWT authentication ✅
Integration tests passing ✅
Ready for production deployment ✅
- Add Alembic migration 85 to add DEXSCREENER_CONNECTOR enum value
- Migration uses IF NOT EXISTS for safe production deployment
- Add integration test script for DexScreener API endpoints
- Verify all endpoints require JWT authentication
- Confirm migration successfully applied (DB version 85)
Story 1.1 Backend: Complete ✅
- All API endpoints functional (add, delete, test)
- Database schema synchronized
- Integration tests passing
- Ready for Story 1.2 (Frontend UI)
Introduce a new incentive task type, REDDIT_FOLLOW, to encourage users to join the SurfSense community on Reddit. This includes a title, description, pages reward, and action URL for the task.
Gmail indexer was using a hardcoded 30-day default instead of respecting
last_indexed_at like other connectors. Now uses calculate_date_range()
for consistent behavior (last_indexed_at → now, or 365 days for first run).