iiTahmin.com
AI & Model30 April 2026·iTahmin Editor

How Does the iTahmin AI Model Work? — Live Predictions with LSTM

iTahmin's live prediction system is powered by our own LSTM-based AI model trained in-house. This article explains, in plain language, what the model has learned, which predictions it produces, and how it integrates with our live data pipeline.

Training data: 94k matches, 843k samples

The model was trained on 93,725 finished football matches. From each match, we sliced the timeline at minutes 10, 20, 30, … 90 — yielding a total of 843,525 training samples. Each sample contains the statistics up to that minute (shots, corners, cards, possession, xG and more) and the actual final result of the match. In short, the model learned the answer to: "Given these stats so far, how do similar matches typically end?"

What is LSTM and why we chose it

LSTM (Long Short-Term Memory) is a neural network type designed to understand sequential data. Classical statistical models look at a single snapshot ("current score + current stats"). LSTM, on the other hand, sees the flow of the match: high tempo at minute 10, drop at minute 30, home team takes control after minute 60 — it captures these patterns.

Architecture:

  • 90-minute time series
  • 42 features (shots, shots-on-target, corners, possession, xG, odds, last-5-match form etc.)
  • 2 LSTM layers (256 + 128 units)
  • Multi-output: 1X2, score prediction, FT Over, HT Over

What the model predicts

  1. Match result (1X2): Home win / draw / away win percentages
  2. Full-time score prediction: e.g. 2-1
  3. Half-time score prediction: Meaningful only before minute 45
  4. Full-time Over/Under: 0.5, 1.5, 2.5, 3.5, 4.5, 5.5 — probability for each
  5. Half-time Over/Under: 0.5, 1.5, 2.5
  6. Top 10 most likely scores: Computed via Poisson distribution

How it works during live matches

The system polls the data provider every 15-60 seconds. When new data arrives:

  1. All accumulated minute-by-minute snapshots are sent to the AI server.
  2. The model is already loaded in RAM and produces a prediction in roughly 200 milliseconds.
  3. The probability output validates our rule-based engine — only predictions that AI also confirms are shown to users.

Thanks to this dual check, "rule fired but AI is uncertain" cases lead to no prediction at all — our success rate measurably improves with this filter.

Consistency rules

The raw model output is never shown directly. These checks apply:

  • If the current score is 2-1, the prediction can never be lower than 2-1.
  • The 0.5 Over probability is always greater than or equal to the 1.5 Over (monotonic).
  • If the current total is 3 goals, "Over 2.5" is already 100% — it is not displayed.
  • After minute 45, no half-time prediction is generated.

These rules block mathematically impossible outputs from reaching the user.

Ongoing work

  • Weekly retraining: Newly finished matches are automatically appended to the training set every week.
  • Corner and card predictions: The current model is goal-focused; corner and card outputs will be added in a future iteration.
  • Error analysis dashboard: The admin panel includes an "AI yes" vs "AI no" success comparison per prediction type, allowing weak signals to be identified quickly.

At iTahmin, AI never decides alone — it supports and validates our rule-based engine. Every published prediction has both a statistical rule and AI confirmation behind it.