Inspiration

When our team first met on Friday, we were throwing around ideas when one of us casually mentioned losing a sports bet on Polymarket. We laughed and then realized something... we all seem to lose more bets than we win, which sparked a bigger question. Why are retail traders making decisions without structured analysis? One teammate wanted to build something AI-focused. Another wanted to work with APIs and live data. The third was interested in trading systems and quantitative modeling. Instead of choosing one direction, we combined all three. BrightBet was born as an AI-powered decision engine that analyzes prediction market trades and returns a structured confidence score, helping users answer a simple but powerful question... “Is this trade good or not?”

What it does

BrightBet offers a simple yet creative UI where dynamic ASCII planets rotate in a circle which represent the different categories of trades on Polymarket. The user can type in the search bar a question about a trade or any specific trade they find, and we scrape financial articles and wikis for all the information related to the question. We then feed this to a Groq AI model that calculates a sentiment of bullish or bearish and a confidence score of that trade. We also display all related quantitative data like GPA, Interest rates, stock trends, related reddit forums, and more. This gives the user a good idea of the direction the trade is predicted to go and whether entering the trade is a good idea or not. Additionally, certain premium AI-generated insights are protected behind a paywall using our X402 Stripe integration, allowing users to securely complete microtransactions before accessing advanced analysis.

How we built it

We built BrightBet using a modular full-stack architecture that combines real-time data aggregation, AI inference, and immersive visualization. Our Python FastAPI backend ingests live trade data from Polymarket and financial data from Finnhub, structures and normalizes the context, and sends it to the Groq API (Llama 3) to generate structured sentiment analysis and confidence scores. We deployed a Cloudflare Workers API gateway written in TypeScript to securely manage routing, secrets, and low-latency edge requests through endpoints like /get-ai-opinion and /visualize. On the frontend, we built an interactive solar-system-inspired interface using Next.js and Three.js, allowing users to explore trades visually and trigger AI-powered analysis dynamically. Together, this serverless, distributed architecture enables scalable, real-time trade evaluation with a clean separation between data ingestion, inference, and visualization. We also implemented the X402 protocol with Stripe to manage paywalled endpoints, ensuring seamless payment processing and secure access to premium AI-generated content.

Challenges we ran into

One of our first challenges was deciding on a frontend theme that would stand out while still being intuitive. We landed on a solar system concept but implementing that vision with Three.js proved more complex than expected. Creating fully interactive 3D “planets,” managing camera controls, object selection, lighting, and smooth rendering required us to quickly learn and debug unfamiliar graphics concepts.

On the backend, we faced challenges integrating multiple APIs with different schemas, rate limits, and latency patterns. Normalizing data from Polymarket and Finnhub into a consistent structure for AI inference required careful data validation and transformation. Additionally, coordinating requests between the frontend, Cloudflare Workers, the Python inference service, and the Groq API introduced distributed system complexity, especially when debugging asynchronous API calls. Overall, balancing ambitious architecture with hackathon time constraints pushed us to think critically about system design, modularity, and performance.

Accomplishments that we're proud of

Just for starters, we think the UI is super cool and unique. We knew we wanted to go for a solar system theme, but incorporating the dynamic ASCII planets was our own creative touch to a what could've been basic frontend. Beyond the visuals, we are incredibly proud of the robust microservice topology we built in a single weekend. We successfully decoupled our logic into three tiers: a dynamic React front-end, a TypeScript Cloudflare Worker acting as our secure edge gateway, and a Python/FastAPI Quant Engine.

What we learned

As a team I think the thing we are most proud of is all the things we learned about designing a system from scratch. It was a bit ambitious for us as we were tackling never before seen challenge but are coming out with so more insight on how to design a system from front to back. As corny as it sounds, we are also super proud of the friendship that three guys from completely different schools and parts of the world can make in just a short 36 hours. We went from just hackathon teammates to friends exploring campus and getting food together which is super special. Overall, we learned about the important of collaboration and openness of ideas, as well as more technical system design and handling advanced and multilayered APIs.

What's next for BrightBet

BrightBet can easily be taken to the next level by evolving from a decision support tool into a fully automated quantitative trading assistant. One major next step is implementing historical back testing, allowing us to track AI generated confidence scores against real market outcomes to measure calibration, precision, and long term profitability. By storing past predictions and comparing them to resolved Polymarket events, we could quantify model performance and iteratively refine prompts, weighting strategies, or feature selection.

We also plan to introduce simulated and live trade execution, enabling users to place trades directly through the platform. With asynchronous trade execution pipelines, BrightBet could automatically act on high confidence signals while logging execution timing, slippage, and outcome performance. Over time, this data could power reinforcement learning loops that dynamically adjust confidence thresholds and risk parameters.

Additional expansions include portfolio tracking, risk adjusted scoring, volatility modeling, and expanding beyond prediction markets into broader financial instruments. Ultimately, the vision is to transform BrightBet into a self improving, AI driven quantitative trading engine that not only analyzes markets but learns from them.

Built With

Share this project:

Updates