Overview
Syllabus
0:00 Demo of the App
2:16 Perplexity Sonar API with DeepSeek and Structured Output
3:36 Kalshi API and events as context
4:13 Grok3 has pretty good analysis of prediction markets
6:56 These models are more willing to speculate
7:21 Testing responses in Perplexity Sonar Reasoning playground
8:23 Going beyond an assistant to an agent
9:07 Getting the code from my Github
10:09 Python code walkthrough, dependencies, environment
11:32 Running the Streamlit app, caching Kalshi event data
12:40 Events vs. Markets, my Super Bowl and Kendrick Lamar bets
14:55 Event and category json, pagination, caching for speed
17:23 Quick Streamlit UI component review
18:33 Matching search term, capturing markdown for context
19:53 Evaluate Bet button, callback function, odds markdown as context
20:47 Evaluate bet function, Perplexity payload, system prompt
21:57 Pydantic model for contract data
22:49 Perplexity JSON output is in beta, not 100% reliable
23:47 Displaying the analysis in a dialog
24:58 Language models are not deterministic, not 100% reliable
26:05 Why I called it an assistant and not an agent
26:45 Wrapping up: do you want more prediction market content?
Taught by
Part Time Larry