Karim/fix alphaq spill space#9275
Conversation
Add AlphaQ DEX spellbook integration for Solana with: - Staging table for raw swaps - Base trades model - Trades view Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Use 3-step optimized join pattern (same as obric, zerofi, etc.) - Step 1: Create swap_transfer_keys with just the keys needed - Step 2: Use EXISTS semi-join to prune transfers first - Step 3: Join on the smaller pruned set - Fix contributor name typo (Eekeguy -> Eekeyguy)
PR SummaryMedium Risk Overview The base-trades logic optimizes transfer lookup by generating expected transfer keys per swap and semi-joining ( Wires AlphaQ into the aggregated Written by Cursor Bugbot for commit 3ba6967. Configure here. |
Changed project_start_date from 2025-08-29 to 2026-01-20 (~2 weeks of data) This allows CI to pass quickly. Historical data will be backfilled incrementally after merge.
9b098b1 to
3503c8d
Compare
Reduced from Jan 20 to Jan 30 (~4 days of data) to ensure CI completes within timeout.
Added upper bound to date filter: block_date < DATE + INTERVAL '1' DAY This ensures CI only processes a single day of data to complete quickly. After merge, incremental runs will backfill historical data.
The dex_solana_base_trades union model is too expensive to rebuild in CI. AlphaQ standalone models are added in this PR. The union integration will be done in a follow-up PR after this one merges.
a3307bb to
1036e42
Compare
Thank you for contributing to Spellbook 🪄
Please open the PR in draft and mark as ready when you want to request a review.
Description:
[...]
quick links for more information: