






















Claude Code is most interesting when it builds a working project, not when it only generates snippets. For this experiment, I used a Claude Code-style workflow to build a small World Cup 2026 match predictor: fixture data, a transparent Elo/Poisson prediction model, charts, and real LLM-generated match previews through Crazyrouter.
This is an analytics and developer workflow demo. It is not betting advice.
The live API layer was tested through:

A sports prediction dashboard is a useful coding-agent demo because it forces the agent to do more than write UI code:
That makes it a better article than a generic “Claude Code project ideas” list. The project produces real files, real numbers and real API traces.
For this demo, I used public fixture information available on World Cup schedule pages and focused on early tournament matches around June 11-18, 2026. The fetched pages confirmed the tournament format: 48 teams, 104 matches, 16 stadiums, group-stage fixtures, and early fixtures such as Mexico vs South Africa, South Korea vs Czechia, USA vs Paraguay and Brazil vs Morocco.
The local demo data is intentionally small and reproducible:
fixtures.json — nine early fixtures;team_ratings_seed.json — seed Elo-style ratings for demo purposes;predictions.json — model output for each match;crazyrouter_test_results.json — raw LLM API test summary.The model is deliberately simple. A production system should replace the seed ratings with live Elo/FIFA ranking data, injury data, lineups, odds, travel, rest days and result updates.
The predictor combines three simple ideas:
The core idea looks like this:
Then the script enumerates likely scorelines, estimates home/draw/away probabilities, and saves a prediction object for each fixture.
Here are the first seven predictions from the demo run:
| Date | Match | Group | xG | Home / Draw / Away | Pick |
|---|---|---|---|---|---|
| 2026-06-11 | Mexico vs South Africa | A | 1.68-0.98 | 55.8% / 24.2% / 19.9% | Mexico |
| 2026-06-11 | South Korea vs Czechia | A | 1.35-1.21 | 40.1% / 26.6% / 33.3% | South Korea |
| 2026-06-12 | USA vs Paraguay | D | 1.53-1.14 | 48.2% / 25.5% / 26.3% | USA |
| 2026-06-13 | Brazil vs Morocco | C | 1.64-0.92 | 54.9% / 24.7% / 20.4% | Brazil |
| 2026-06-13 | Qatar vs Canada | B | 1.1-1.46 | 27.8% / 26.1% / 46.1% | Canada |
| 2026-06-14 | Germany vs Curaçao | E | 2.08-0.48 | 75.1% / 17.7% / 7.2% | Germany |
| 2026-06-14 | Netherlands vs Japan | F | 1.53-1.03 | 49.5% / 25.7% / 24.8% | Netherlands |

Notice the USA vs Paraguay example: the model gives the USA a slight edge, but not a dominant one. The home win probability is 48.2%, while draw plus Paraguay win is 51.8%. That is exactly the kind of uncertainty a good demo should preserve.
After generating model probabilities, the script asked four model routes to turn the USA vs Paraguay model output into a structured JSON match preview.
Task:
The Crazyrouter model-list endpoint also worked:
The chat-completion test results:
| Model | HTTP | Latency | Prompt tokens | Completion tokens | Total tokens | Valid JSON |
|---|---|---|---|---|---|---|
gpt-4o-mini | 200 | 4.53s | 305 | 292 | 597 | True |
gpt-5.5 | 200 | 6.28s | 600 | 278 | 878 | True |
gemini-2.5-flash | 200 | 11.33s | 327 | 356 | 683 | False |
qwen-plus | 200 | 8.13s | 325 | 177 | 502 | True |

Three routes returned valid JSON:
gpt-4o-minigpt-5.5qwen-plusOne route returned HTTP 200 but failed JSON validation:
gemini-2.5-flashThat failure is not a problem for the article; it is the article. In production AI workflows, HTTP 200 is not enough. A coding agent should build validators, retries and fallback routes.
A valid output example from gpt-4o-mini:
A robust Claude Code workflow should not simply call an LLM and trust the text. It should build an execution pipeline:
This is the practical reason to use an AI API gateway. You can route the same task through multiple models while keeping one API base URL and one client shape.
The demo folder contains:
The key API client configuration is standard OpenAI-compatible code:
Do not add UTM parameters to API base URLs. UTM belongs on human-facing links only.
This is a strong Claude Code project because the deliverable is not one function. It is a pipeline with data files, modeling code, API calls, raw logs and visual assets.
For an article/demo, a transparent Elo/Poisson model is better than a black-box “AI says Brazil wins” answer. The LLM should explain the model, not replace the model.
The Gemini route returned HTTP 200 but invalid JSON in this constrained test. That is a real production lesson: validate the output and fallback automatically.
The same request shape worked across GPT, Gemini and Qwen-style routes. That makes model comparison and fallback easier than wiring every provider directly.
This demo intentionally keeps the model small. It does not include:
So the predictions should be read as a coding and data workflow demonstration, not as betting recommendations.
A stronger version could add:
Yes: Claude Code can build a credible World Cup 2026 match predictor demo, as long as the project is framed correctly.
The right architecture is:
In this run, Crazyrouter returned 262 models from /v1/models, and three of four tested model routes produced valid JSON match previews. The failed JSON route is useful evidence too: real AI projects need validation and fallback, not just prompts.
If you want to build Claude Code projects that compare multiple AI models through one API layer, start with Crazyrouter.
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。