This repository was archived by the owner on Sep 3, 2025. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 642
(feat): ai-assisted tactical reports #6135
Merged
Merged
Conversation
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
Contributor
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
Adds end-to-end support for AI-assisted tactical report generation from Slack conversations, including service logic, API exposure, and frontend integration.
- Implements
generate_tactical_reportin the AI service with logging and error handling. - Exposes a new FastAPI GET endpoint
/incidents/{id}/report/tactical/generateguarded by incident edit permissions. - Integrates Vuex store action, API client method, and UI button with loading state to draft reports in the incident report dialog.
Reviewed Changes
Copilot reviewed 8 out of 8 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| tests/ai/test_ai_service.py | Added comprehensive tests for generate_tactical_report scenarios |
| src/dispatch/static/dispatch/src/incident/store.js | Added Vuex state, mutations, and action for tactical report loading |
| src/dispatch/static/dispatch/src/incident/api.js | Added generateTacticalReport API client call |
| src/dispatch/static/dispatch/src/incident/ReportDialog.vue | Added "Draft with GenAI" button and loading indicator |
| src/dispatch/incident/views.py | New GET endpoint for AI-driven tactical report generation |
| src/dispatch/ai/service.py | Implemented tactical report generation logic |
| src/dispatch/ai/models.py | Introduced TacticalReport and TacticalReportResponse models |
| src/dispatch/ai/enums.py | Added tactical_report_created event description |
Comments suppressed due to low confidence (1)
src/dispatch/ai/service.py:716
- The docstring still references a
channel_idparameter that no longer exists. Update the Args section to reflect the actual parameters (db_session,incident,project,important_reaction).
channel_id (str): The channel ID to target when fetching conversation history
whitdog47
approved these changes
Jul 16, 2025
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
Key Changes
Next steps