Skip to content

asraym/gafferOSv2

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

21 Commits
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

gafferOSv2 ⚽

A tactical intelligence system for semi-professional football teams, combining match data and machine learning to generate data-driven insights and decision support.


πŸš€ Overview

gafferOSv2 uses historical match data (StatsBomb) and engineered performance metrics to:

  • Predict match outcomes
  • Analyze team strengths (attack vs defense dynamics)
  • Model team form and matchup differences
  • Lay the foundation for tactical decision-making (e.g., formation adjustments)

βš™οΈ Current Progress

  • PostgreSQL database and REST API implemented
  • 1100+ matches processed (La Liga, UCL, Premier League)
  • 30+ engineered features from match data
  • Rolling form and team-vs-opponent differential features
  • Exploratory Data Analysis completed
  • Initial XGBoost model trained (WIP, ~74% accuracy)

πŸ“Š Key Insights

  • Match outcomes are primarily driven by:

    • Offensive output
    • Defensive solidity
    • Shot quality
  • Home advantage has a measurable impact

  • Several features are highly correlated, requiring pruning

  • Teams exhibit strong tactical identity:

    • ~63% of matches use their most common formation

🧠 Core Idea

Rather than asking:

β€œWhich formation is best?”

gafferOS aims to answer:

β€œWhat is the best tactical adjustment for this team in this situation?”

This is achieved by:

  • Learning team tendencies (form + formation identity)
  • Comparing realistic tactical variations
  • Evaluating outcomes using the trained model

πŸ› οΈ Tech Stack

Python β€’ FastAPI β€’ PostgreSQL β€’ XGBoost


πŸ”„ Pipeline

Data β†’ Feature Engineering β†’ ML Model β†’ API β†’ Tactical Insights

πŸ“ Structure

backend/
β”œβ”€β”€ api/        # REST endpoints
β”œβ”€β”€ core/       # business logic
β”œβ”€β”€ db/         # database models
β”œβ”€β”€ ml/         # data + training pipeline
└── main.py

🎯 Goal

To make practical tactical analytics accessible to teams without elite-level resources.


πŸ“„ Status

Active development β€” evolving from prediction system to tactical decision engine

About

ML-powered tactical intelligence system for football teams. Analyzes match data to predict outcomes, identify team dynamics, and recommend data-driven tactical adjustments. Built with StatsBomb data, XGBoost, FastAPI, and PostgreSQL.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages