Predict F1 Race Winners with OpenAI GPT-4o, Historical Data & Slack Alerts
Ready for 3.0Ready for 3.0. This template uses no nodes that n8n 3.0 removes. No removed nodes, versions or helpers found. Static check, last run 2026-10-19.
Nodes used (17)
- Schedule Trigger
n8n-nodes-base.scheduleTrigger - Edit Fields (Set)
n8n-nodes-base.set - HTTP Request
n8n-nodes-base.httpRequest - Code
n8n-nodes-base.code - AI Agent
@n8n/n8n-nodes-langchain.agent - OpenAI Chat Model
@n8n/n8n-nodes-langchain.lmChatOpenAi - Http Request Tool
n8n-nodes-base.httpRequestTool - Simple Vector Store
@n8n/n8n-nodes-langchain.vectorStoreInMemory - Embeddings OpenAI
@n8n/n8n-nodes-langchain.embeddingsOpenAi - Default Data Loader
@n8n/n8n-nodes-langchain.documentDefaultDataLoader - Recursive Character Text Splitter
@n8n/n8n-nodes-langchain.textSplitterRecursiveCharacterTextSplitter - If
n8n-nodes-base.if - Postgres
n8n-nodes-base.postgres - Slack
n8n-nodes-base.slack - Google Sheets
n8n-nodes-base.googleSheets - Aggregate
n8n-nodes-base.aggregate - Code Tool
@n8n/n8n-nodes-langchain.toolCode
What it does
How It Works Every day at 8 AM, the workflow automatically retrieves the latest F1 data—including driver standings, qualifying results, race schedules, and circuit information. All sources are merged into a unified dataset, and driver performance metrics are computed using historical trends. An AI agent, enhanced with vectorized race history, evaluates patterns and generates race-winner predictions. When the confidence score exceeds the defined threshold, the system pushes an automated Slack alert and records the full analysis in the database and Google Sheets. Setup Steps 1. Update the workflow configuration with: newsApiUrl, weatherApiUrl, historicalYears, and confidenceThreshold. 2. Connect PostgreSQL using the schema: predictiondate, predictedwinner, confidencescore, predictionsource, dataversion, fullanalysis. 3. Provide the Slack channel ID for sending high-confidence alerts. 4. Specify the Google Sheets document ID and sheet name for prediction logging. 5. Test connectivity to the Ergast API (no authentication required). Prerequisites OpenAI account (GPT-4o access), Slack workspace admin access, PostgreSQL instance, Google Sheets account, n8n instance with LangChain community nodes enabled. Customization Extend by adding constructor predictions (modify AI prompt). Integrate Discord or Teams instead of Slack. Benefits Saves time by automating data collection, improves accuracy using multiple performance metrics and historical patterns.