How divya2842/ai-soc-investigation-agent works
This is an AI-assisted SOC investigation platform. Analysts authenticate, review alerts or look up IOCs, then launch an investigation that gathers logs and evidence, extracts and enriches indicators, maps MITRE techniques, scores risk, and produces an AI-assisted summary and report. Response actions are recommendations for human review, not automatic remediation. The README documents the broad investigation stages; source-index references and excerpts support the shown internal calls, while unsampled route and service details are represented only at subsystem level.
Main entry points: investigation_graph.py Investigation graph · main.py FastAPI application · investigations.py Investigation API · App.tsx React application
Components 27
Analyst interface
- React application
frontend/src/App.tsx - Alert views
frontend/src/pages/AlertDetail.tsx - IOC lookup
frontend/src/pages/IocLookup.tsx - API client
frontend/src/services/api.ts - Auth client
frontend/src/services/auth.ts
API and access
- FastAPI application
backend/app/main.py - Authentication API
backend/app/api/auth.py - Alert API
backend/app/api/alerts.py - Investigation API
backend/app/api/investigations.py - IOC API
backend/app/api/iocs.py - JWT security
backend/app/security/auth.py
Investigation analysis
- Investigation graph
backend/app/agents/investigation_graph.py - IOC extraction
backend/app/services/ioc/extract.py - Log correlation
backend/app/services/logs/source.py - IOC enrichment
backend/app/services/ioc/enrichment/router.py - ATT&CK mapping
backend/app/services/mitre/attack.py - ATLAS mapping
backend/app/services/mitre/atlas.py - Risk analysis
backend/app/services/risk/score.py - Evidence retrieval
backend/app/services/rag/retriever.py - LLM analysis
backend/app/services/llm/groq_client.py
Persistence and reporting
- Investigation reports
backend/app/services/reporting/report_builder.py - SOC database
backend/app/database/session.py - Audit records
backend/app/services/audit.py
External services
- Threat-intel providers
backend/app/services/ioc/enrichment/external.py - Groq
- Email delivery
backend/app/services/emailservice.py
Other components
- SOC analyst
Connections 34
- SOC analyst → React application: uses
- React application → Alert views: routes to
frontend/src/main.tsx - React application → IOC lookup: routes to
frontend/src/main.tsx - Alert views → API client: requests data
frontend/src/pages/AlertDetail.tsx - IOC lookup → API client: requests data
frontend/src/pages/IocLookup.tsx - React application → Auth client: logs out via
frontend/src/App.tsx - API client → FastAPI application: calls REST API
frontend/src/services/api.ts - Auth client → Authentication API: calls auth API
frontend/src/services/auth.ts - FastAPI application → Authentication API: mounts routes
backend/app/main.py - FastAPI application → Alert API: mounts routes
backend/app/main.py - FastAPI application → Investigation API: mounts routes
backend/app/main.py - FastAPI application → IOC API: mounts routes
backend/app/main.py - FastAPI application → JWT security: protects routes
backend/app/main.py - Authentication API → JWT security: uses JWT
backend/app/api/auth.py - Authentication API → Email delivery: sends recovery email
backend/app/api/auth.py - Investigation API → Investigation graph: runs investigation
backend/app/api/investigations.py - Investigation API → Investigation reports: builds report
backend/app/api/investigations.py - Investigation API → SOC database: reads and writes
backend/app/api/investigations.py - Investigation API → Audit records: records activity
backend/app/api/investigations.py - FastAPI application → SOC database: initializes
backend/app/main.py - Investigation graph → IOC extraction: extracts indicators
backend/app/agents/investigation_graph.py - Investigation graph → Log correlation: collects log evidence
backend/app/agents/investigation_graph.py - Investigation graph → IOC enrichment: enriches indicators
backend/app/agents/investigation_graph.py - Investigation graph → ATT&CK mapping: maps techniques
backend/app/agents/investigation_graph.py - Investigation graph → ATLAS mapping: maps AI threats
backend/app/agents/investigation_graph.py - Investigation graph → Risk analysis: scores evidence
backend/app/agents/investigation_graph.py - Investigation graph → Evidence retrieval: retrieves context
backend/app/agents/investigation_graph.py - Investigation graph → LLM analysis: requests summary
backend/app/agents/investigation_graph.py - Investigation graph → Audit records: records events
backend/app/agents/investigation_graph.py - IOC enrichment → Threat-intel providers: queries providers
backend/app/services/ioc/enrichment/router.py - LLM analysis → Groq: generates analysis
- Investigation graph → Investigation reports: produces analyst report
- SOC analyst → Investigation reports: reviews results
- SOC analyst → Investigation API: requests investigation