ScoutR is an autonomous, agent-driven transfer intelligence platform for football clubs. Designed for sporting directors, it replaces manual spreadsheet scouting with a unified, natural-language interface. ScoutR continuously monitors 50+ leagues, finds tactical and financial fits, and delivers comprehensive, ready-to-act dossier reports in seconds.
ScoutR is built with a modern, decoupled architecture featuring a Python/FastAPI backend and a React/Next.js frontend. The core intelligence is powered by Google's Gemini 2.5 Flash model, orchestrated via LangGraph.
- Framework Code:
Python 3.10+,FastAPI - Agent Orchestration:
LangGraph,LangChain - AI Model:
Gemini 2.5 Flash(vialangchain-google-genai) - Vector Store:
ChromaDB(Local embedded for fast similarity search of player metrics) - Relational Data:
SQLite(Financials, contract expiries, structured player data) - Caching Layer:
MongoDB(Two-tier query caching for instant repeated query resolution) - Streaming:
sse-starletteto stream agent reasoning live to the client - Deployment: Hosted on Vultr for high-performance, low-latency API execution
- Framework:
Next.js 14(App Router) - Styling:
Tailwind CSS v4, Custom Native CSS for landing page - UI Components:
React,shadcn/ui,Framer Motion(Micro-animations) - Data Fetching: Real-time Server-Sent Events (SSE) parsing for live agent reasoning
- Export: One-click PDF Dossier generation via browser print APIs
ScoutR operates through four specialized, autonomous agents orchestrated by LangGraph working in parallel:
- Scout Agent (Natural Language Search): Takes a plain-English query (e.g., "Find me a left-back under 24, comfortable in a high press under €10M"), parses it into structured criteria using Gemini, and executes a hybrid search against ChromaDB and SQLite.
- Valuation Agent (Market Fee Intelligence): Analyses contract expiry dates, comparable market values, and player age to calculate an estimated, realistic transfer fee range and assess selling club pressure.
- Tactical Fit Agent (Formation Compatibility): Evaluates progressive carries, pressure success rates, and positional data to score how well a player fits the buying club's tactical system (e.g., high-pressing 4-3-3), providing a plain-English tactical summary.
- Monitoring Agent (24/7 Target Watch): (In Development) Designed to watch shortlists and send alerts on contract changes, rival scouting activity, or club financial issues.
- Built ingestion scripts to process raw StatsBomb event data and Transfermarkt financials.
- Constructed a ChromaDB vector store mapping complex positional nuances (e.g. mapping "right-back" queries to "right wing back", "right center back", etc.).
- Implemented a solid fallback mechanism: if ChromaDB is empty, the system automatically falls back to curated mock data.
- Implemented a
/query/streamendpoint in FastAPI that yields Server-Sent Events (SSE). - Optimized LangGraph orchestration to run multiple agent tasks concurrently using
asyncio.gather(), drastically reducing latency. - Added a MongoDB Caching Layer that hashes query criteria and caches the final dossier output, resulting in near-instantaneous responses for repeated queries.
- Built a stunning, cinematic landing page (
/) utilizing a scroll-driven canvas frame sequence (192 frames) and glassmorphism styling. - Developed the
/appdashboard featuring:- A live transfer budget gauge with animated number tickers.
- A chat interface that streams the agent's "thought process" in real-time (e.g., "[Agent] Analyzing tactical fit...").
- Beautiful dossier cards displaying the final candidate results, complete with radar-style stats, scout summaries, and fee ranges.
- Fixed critical frontend streaming bugs, specifically a CRLF line-ending issue where the SSE parser failed to split
\r\n\r\nchunks natively, ensuring smooth and reliable UI updates.
- Refined UI aesthetics by ensuring consistent accessibility (e.g., contrasting CTA buttons, bright white helper text).
- Implemented "Export to PDF" functionality directly within the dossier cards.
- Navigate to the
backend/directory:cd backend - Create and activate a virtual environment:
python -m venv venvandvenv\Scripts\activate - Install dependencies:
pip install -r requirements.txt - Create a
.envfile with your API keys:GEMINI_API_KEY=your_google_ai_key MONGO_URI=mongodb://localhost:27017
- Run the server:
uvicorn app.main:app --reload --port 8000
- Navigate to the
frontend/directory:cd frontend - Install dependencies:
npm install - Start the dev server:
npm run dev - Open
http://localhost:3000to view the landing page, orhttp://localhost:3000/appfor the dashboard.
Made for sporting directors who can't afford to be second.