In agentic AI applications, blindly sending every user prompt to massive cloud-based LLMs incurs heavy token costs, network latency, and billing overhead. Our project, Tokenomics, tackles AMD Hackathon Track 1 by introducing a highly intelligent 3-Stage Routing Cascade designed to achieve maximum benchmark accuracy while driving commercial API token consumption as close to zero as mathematically possible. Our architecture classifies and resolves requests through three strict tiers: 1. Stage 1 (Deterministic Solvers - 0 Token Spend): Before querying any neural network, our router intercepts structured problems. Using advanced regex rules and SymPy equation evaluation, our agent solves math calculations, sentiment analysis, and Named Entity Recognition (NER) instantaneously. This yields 100% precision with 0 API tokens and 0ms latency. 2. Stage 2 (Local Edge Inference - 0 API Spend): For general natural language tasks like summarization, factual Q&A, and code debugging, prompts are routed to our locally hosted Qwen2.5-1.5B-Instruct-GGUF model running via llama-cpp-python directly on edge compute. 3. Stage 3 (Optimized Fireworks API): Only when a task involves complex logic puzzles or code generation does our router escalate to commercial Fireworks endpoints. Even here, we apply strict token-shaving techniques—such as disabling hidden reasoning tokens (enable_thinking=False) and compressing system prompts under 15 tokens—to guarantee the lowest billing score on the leaderboard.
Category tags: