Commit Graph

8 Commits

Author SHA1 Message Date
Stefan d28914ca35 Add horizontal evaluation bar to analysis page 2025-12-01 10:28:19 +01:00
Stefan 3e8c16b9c2 analysis 2025-11-27 21:23:54 +01:00
Stefan c319904f00 feat: Add debug mode to inspect LLM prompts and responses
- Add DebugContext to track all LLM interactions
- Create DebugPanel component with floating UI
- Track prompts/responses in Tutor component (move analysis, hints, questions)
- Track prompts/responses in Analysis page (move commentary)
- Add NEXT_PUBLIC_DEBUG environment variable to enable/disable
- Include metadata (FEN, personality, language, etc.) in debug entries
- Add copy-to-clipboard and clear functionality
- Add DEBUG_MODE.md documentation
2025-11-27 18:20:12 +01:00
Stefan 6b50eba05f feat: Add back button and simplify navigation on analysis page
- Import ArrowLeft icon and useRouter from Next.js
- Add back button below header that navigates to home (/)
- Simplify Previous/Next buttons to show only chevron icons
- Remove text labels from navigation buttons for cleaner UI
- Add aria-labels for accessibility
- Consistent with play page navigation pattern
2025-11-27 12:40:21 +01:00
Stefan d3fea58e8e feat: Update analysis page to use multiple opening detection
- Import lookupPossibleOpenings and buildMoveSequenceFromSteps
- Build move sequence from steps array up to currentIndex
- Lookup up to 5 possible openings per position
- Update prompt to include all possible openings
- Update UI to show single opening name or count of possibilities
- Consistent with play page opening detection
2025-11-27 12:38:31 +01:00
Stefan aa389613cb feat: Add chat session to analysis page
- Import ChatSession from @google/generative-ai
- Add chatSession state to maintain conversation history
- Initialize chat session with personality and language context
- Replace stateless generateContent() with chatSession.sendMessage()
- Add FEN before/after to move analysis prompts
- Chat history is preserved when navigating between moves
- LLM can now provide context-aware commentary across the game
2025-11-27 12:36:40 +01:00
Stefan af2ea1c39e fix: Resolve build errors after merging feature branches
- Fix TypeScript errors in analysis page with non-null assertions
- Fix Chessboard component API usage to use options prop
- Fix Analyze Game button placement to be always visible
2025-11-27 09:52:36 +01:00
stefan-kp 05f14d30a1 Add analysis page tests for PGN walkthrough 2025-11-26 21:33:45 +01:00