From 5f8858c978387bb80e741b9eea4ee2e15cc9d276 Mon Sep 17 00:00:00 2001 From: hbyang Date: Thu, 11 Jun 2026 11:50:36 +0900 Subject: [PATCH] =?UTF-8?q?fix(ai):=20=EC=9B=94=EB=93=9C=EC=BB=B5=20?= =?UTF-8?q?=EC=A4=91=EB=A6=BD=20=EA=B2=BD=EA=B8=B0=EC=9E=A5=20=EB=AA=85?= =?UTF-8?q?=EC=8B=9C=20=E2=80=94=20=EC=9E=98=EB=AA=BB=EB=90=9C=20'?= =?UTF-8?q?=ED=99=88=20=EC=9D=B4=EC=A0=90'=20=EC=98=88=EC=B8=A1=20?= =?UTF-8?q?=EA=B7=BC=EA=B1=B0=20=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit AI 프롬프트가 Team A를 home으로 단정해 "홈 경기 이점" 같은 오류 근거가 생성됨. 조별리그는 중립 경기장(개최국 멕시코/미국/캐나다만 홈)임을 명시. Co-Authored-By: Claude Opus 4.8 (1M context) --- backend/app/services/ai.py | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/backend/app/services/ai.py b/backend/app/services/ai.py index 52ecfb3..4257404 100644 --- a/backend/app/services/ai.py +++ b/backend/app/services/ai.py @@ -34,9 +34,13 @@ class MatchContext: def _prompt(ctx: MatchContext) -> str: return ( - f"You are a football match analyst. Predict the result of this match.\n" - f"Match: {ctx.team_a} (Team A, home) vs {ctx.team_b} (Team B, away)\n" - f"Venue: {ctx.venue}\nKickoff: {ctx.kickoff}\n\n" + f"You are a football match analyst. Predict the result of this " + f"2026 FIFA World Cup match.\n" + f"Team A: {ctx.team_a}\nTeam B: {ctx.team_b}\n" + f"Venue: {ctx.venue}\nKickoff: {ctx.kickoff}\n" + f"Important: World Cup group-stage matches are played at NEUTRAL venues. " + f"Neither team has home advantage unless it is a host nation " + f"(Mexico, USA, or Canada). Do NOT claim home advantage otherwise.\n\n" f"Predict the final regulation-time score. " f"Respond with a single JSON object and nothing else, with keys:\n" f' "scoreA": integer 0-9 (Team A goals),\n'