markets
npx skills add https://github.com/machina-sports/sports-skills --skill markets
Agent 安装分布
Skill 文档
Markets Orchestration
Bridges ESPN live schedules (NBA, NFL, MLB, NHL, WNBA, CFB, CBB) with Kalshi and Polymarket prediction markets.
Quick Start
# Today's games with matching prediction markets
sports-skills markets get_todays_markets --sport=nba
# Search for a team across both exchanges
sports-skills markets search_entity --query="Lakers"
# Compare ESPN odds vs prediction market prices for a game
sports-skills markets compare_odds --sport=nba --event_id=401234567
# Sports-filtered market listing (no political/weather noise)
sports-skills markets get_sport_markets --sport=nfl
# Unified ESPN schedule
sports-skills markets get_sport_schedule --sport=nba
# Normalize a price from any source
sports-skills markets normalize_price --price=0.65 --source=polymarket
# Full evaluation: ESPN odds + market price â devig â edge â Kelly
sports-skills markets evaluate_market --sport=nba --event_id=401234567
Python SDK:
from sports_skills import markets
markets.get_todays_markets(sport="nba")
markets.search_entity(query="Lakers")
markets.compare_odds(sport="nba", event_id="401234567")
markets.get_sport_markets(sport="nfl")
markets.get_sport_schedule(sport="nba", date="2025-02-26")
markets.normalize_price(price=0.65, source="polymarket")
markets.evaluate_market(sport="nba", event_id="401234567")
Commands
| Command | Required | Optional | Description |
|---|---|---|---|
get_todays_markets |
sport, date | Fetch ESPN schedule â search both exchanges â unified dashboard | |
search_entity |
query | sport | Search Kalshi + Polymarket for a team/player/event name |
compare_odds |
sport, event_id | ESPN odds + prediction market prices â normalized side-by-side + arb check | |
get_sport_markets |
sport | status, limit | Sports-filtered market listing on both platforms |
get_sport_schedule |
sport, date | Unified ESPN schedule across one or all sports | |
normalize_price |
price, source | Convert any source format to common {implied_prob, american, decimal} | |
evaluate_market |
sport, event_id | token_id, kalshi_ticker, outcome | ESPN odds + market price â devig â edge â Kelly |
Supported Sports
| Sport | Key | Kalshi Series |
|---|---|---|
| NFL | nfl |
KXNFL |
| NBA | nba |
KXNBA |
| MLB | mlb |
KXMLB |
| NHL | nhl |
KXNHL |
| WNBA | wnba |
KXWNBA |
| College Football | cfb |
KXCFB |
| College Basketball | cbb |
KXCBB |
Workflows
Today’s NBA Dashboard
Show all NBA games today with matching prediction market odds.
sports-skills markets get_todays_markets --sport=nba
Returns each game with:
- ESPN game info (teams, time, status)
- ESPN DraftKings odds (American format)
- Matching Kalshi markets (scoped to KXNBA series)
- Matching Polymarket markets (text search, sports-filtered)
Find Arb on a Specific Game
- Get the ESPN event ID from the schedule:
sports-skills markets get_sport_schedule --sport=nba - Compare odds across all sources:
sports-skills markets compare_odds --sport=nba --event_id=401234567 - If arbitrage is detected, the response includes allocation percentages and guaranteed ROI.
Compare ESPN vs Polymarket
sports-skills markets compare_odds --sport=nba --event_id=401234567- Response includes ESPN odds normalized to probability + Polymarket prices side-by-side
- Arbitrage check runs automatically using
betting.find_arbitrage
Full Bet Evaluation
sports-skills markets evaluate_market --sport=nba --event_id=401234567- Fetches ESPN odds, searches for matching prediction market price
- Pipes through
betting.evaluate_bet: devig â edge â Kelly - Returns fair probability, edge percentage, EV, Kelly fraction, and recommendation
Search for a Team
Find all prediction markets related to a team:
sports-skills markets search_entity --query="Chiefs" --sport=nfl
Returns Kalshi events (scoped to KXNFL) and Polymarket markets matching “Chiefs”.
Price Normalization
Different sources use different formats:
| Source | Format | Example | Meaning |
|---|---|---|---|
| ESPN | American odds | -150 |
Favorite, implied 60% |
| Polymarket | Probability (0-1) | 0.65 |
65% implied probability |
| Kalshi | Integer (0-100) | 65 |
65% implied probability |
normalize_price converts any format to a common structure:
{
"implied_probability": 0.65,
"american": -185.7,
"decimal": 1.5385,
"source": "polymarket"
}
Examples
User: “What NBA games are on today and what are the prediction market odds?”
â markets.get_todays_markets(sport="nba")
User: “Find me Lakers markets on Kalshi and Polymarket”
â markets.search_entity(query="Lakers", sport="nba")
User: “Compare the odds for this Celtics game across ESPN and Polymarket”
â markets.compare_odds(sport="nba", event_id="<id>")
User: “Is there edge on the Chiefs game?”
â markets.evaluate_market(sport="nfl", event_id="<id>")
User: “Show me all NFL prediction markets”
â markets.get_sport_markets(sport="nfl")
User: “Convert a Polymarket price of 65 cents to American odds”
â markets.normalize_price(price=0.65, source="polymarket")
Partial Results
If one source is unavailable (e.g., Kalshi is down), the module returns what it has with warnings:
{
"status": true,
"data": {
"games": [...],
"warnings": ["Kalshi search failed: connection timeout"]
}
}
This ensures you always get usable data even when a source is temporarily unavailable.