Skip to content

[FEAT]: AI-Powered Incident Similarity Search for Historical Incident Analysis #287

@Mahendrareddy2006

Description

@Mahendrareddy2006

name: 🚀 Feature Request
about: Suggest an idea or a new capability for FireForm.
title: "[FEAT]: AI-Powered Incident Similarity Search for Historical Incident Analysis"
labels: enhancement, ai, analytics
assignees: ''

📝 Description
Fire departments often encounter recurring incident patterns such as warehouse fires, vehicle collisions, or hazardous material spills. While FireForm focuses on transforming natural language reports into structured forms, it currently does not provide a way to analyze or reference past incidents when processing new reports.

This feature proposes introducing an Incident Similarity Search system that allows FireForm to compare new incident descriptions with previously recorded incidents and return the most similar historical cases.

By leveraging semantic embeddings and vector search, FireForm could provide responders or analysts with relevant past incidents that share similar characteristics.

💡 Rationale
Emergency response teams frequently benefit from reviewing similar past incidents when documenting or analyzing a new event. However, searching manually through historical reports is time-consuming and inefficient.

Introducing similarity search would provide several advantages:

  1. Enables responders to reference similar past incidents quickly
    2 .Supports learning from previous emergency responses
  2. Helps identify recurring patterns in incident data
  3. Enhances FireForm's capabilities beyond form filling toward incident analysis
  4. Provides a foundation for future analytics and decision-support tools

This aligns with FireForm’s broader goal of transforming incident descriptions into structured, actionable data.

🛠️ Proposed Solution
Introduce an AI-powered similarity search layer that stores embeddings of processed incident reports and allows semantic search over them.

Proposed pipeline:

Incident Description
→ LLM Structured Extraction
→ Generate Semantic Embedding
→ Store Embedding in Incident Database
→ Query Vector Database for Similar Incidents
→ Return Top Similar Incident Reports

Example workflow:

Input incident description:

"Large warehouse fire involving chemical storage containers."

Similarity search result:

  1. Chemical warehouse fire – Texas (2023)
  2. Industrial storage facility fire – Chicago (2022)
  3. Factory chemical spill and fire – California (2021)

Implementation outline:

  1. Generate embeddings for incident descriptions using models such as sentence-transformers
  2. Store embeddings in a vector database (e.g., FAISS, ChromaDB, or similar)
  3. Create a search function that retrieves the most similar incidents
  4. Integrate the similarity search into the incident processing pipeline
  5. Optionally expose an API endpoint for querying similar incidents

Possible integration points:

  1. src/controller.py for pipeline integration
  2. New module such as src/incident_similarity.py
  3. Optional API endpoint in FastAPI for similarity queries

✅ Acceptance Criteria

  1. Incident descriptions are converted into semantic embeddings
  2. Embeddings are stored in a searchable vector database
  3. New incident reports can be compared against stored incidents
  4. The system returns a ranked list of similar incidents
  5. The feature integrates without breaking existing form-filling workflows
  6. Unit tests verify embedding generation and similarity search behavior

📌 Additional Context
This feature could serve as a foundation for future FireForm capabilities such as:

  1. Incident pattern analysis
  2. Risk prediction for similar incidents
  3. Decision support for responders
  4. Historical analytics dashboards

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions