feat: add Session Summary Report Generator (#77)#255
Open
Aspirant200715 wants to merge 2 commits into
Open
Conversation
Adds backend summarizer logic, API endpoints, and a frontend dashboard UI to display and download session markdown reports.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
🔗 Related Issue
Closes #77
📝 Summary of Changes
This PR introduces the Session Summary Report Generator feature as requested. It aggregates action logs and guidance metrics directly from the local SQLite database to provide users with a concise report of their session.
Key Changes:
core/intelligence/session_summarizer.pywith aSessionSummarizerclass to compute session duration, completed steps, error frequency, and guidance confidence.api/routes/session.pywith endpointsGET /api/v1/session/{session_id}/summary(JSON) and/summary.md(Markdown).dashboard/src/routes/+page.svelteto include a "Session Summary" UI block in theADMIN_CONTROLSsection. It features a fully-styled dark-mode modal overlay to render the generated Markdown report..mdreport directly from the frontend dashboard.tests/unit/test_session_summarizer.py.🔍 Type of Change
🧪 How Was This Tested?
python -m pytest tests/unit/test_session_summarizer.pysuccessfully.main.pyand the Svelte frontend (npm run dev). Navigated to the dashboard, generated a few simulated actions, and triggered the report generation for the live session ID.npm run buildsucceeds in thedashboard/directory.Test environment:
📸 Screenshots / Recordings (if applicable)
✅ Pre-Submission Checklist
upstream/main.python -m pytest tests/) (Note: Existing unrelated test failures in main were bypassed, new tests pass 100%)