Open-source AI Security Operations Center: alert fusion, LLM-agent triage, MITRE ATT&CK investigation, and a replayable decision ledger for every agent step. Self-hostable, runs with no API keys, MIT licensed. Ships an MCP server for Claude, Cursor and Continue.
Python agentic-aiai-securityalert-triageblue-teamcybersecuritydetection-engineeringincident-responselanggraphllm-agentsmcpmitre-attackmodel-context-protocolpurple-teamsecurity-operationsself-hostedsiemsoarsocthreat-detectionthreat-intelligence
fix(web): QA fixes — null safety, button wiring, mobile sidebar
Beenu Arora8f914a737ecf
diff --git a/AGENTS.md b/AGENTS.mdindex 040b7cbc0..c6e47939a 100644--- a/AGENTS.md+++ b/AGENTS.md@@ -6,6 +6,9 @@- Before pushing to GitHub, ensure no secrets, API keys, tokens, or sensitive data are present in any public repo files.- Host codebase on GitHub once fully built out; keep documentation in sync.- Never edit plan files directly — implement the plan as specified without modifying the plan document itself.+- After every significant change, push code and update documentation on GitHub immediately — don't wait to be asked.+- Benchmark data and documentation must be transparent about what is synthetic vs. real; never present fabricated metrics as actual measured performance.+- When the task is clear, act autonomously — don't ask unnecessary clarifying questions.## Learned Workspace Facts@@ -32,3 +35,5 @@- v1.4 eval harness conventions:- Synthetic dataset is fixed at 200 incidents (`services/agents/tests/eval_data/synthetic_incidents.json`) plus an aligned synthetic telemetry corpus (`synthetic_telemetry.jsonl`). Three of the four metrics (`alert_reduction`, `investigation_completeness`, `response_quality`) are substrate self-consistency gates, not agent accuracy scores; only `mitre_accuracy` measures the live agent. The benchmark page (`apps/docs/docs/benchmark.md`) explains which is which.- PRs touching the agent, orchestrator graph, prompts, tools, RAG corpus, or detection content must re-grade against the harness and include before/after deltas in the PR body if any axis regresses.+- Project website at `tryaisoc.com`; domain registered through Cloudflare.+- Production hosting target is Fly.io for backend services.diff --git a/apps/web/src/app/(app)/purple-team/page.tsx b/apps/web/src/app/(app)/purple-team/page.tsxindex 992eca113..8de5045a8 100644--- a/apps/web/src/app/(app)/purple-team/page.tsx+++ b/apps/web/src/app/(app)/purple-team/page.tsx@@ -246,10 +246,11 @@ function CoverageHeatmap() {const resolved = data ?? MOCK_COVERAGEconst {- summary = MOCK_COVERAGE.summary,+ summary: rawSummary,tactics = MOCK_COVERAGE.tactics,techniques = MOCK_COVERAGE.techniques,} = resolved+ const summary = rawSummary ?? MOCK_COVERAGE.summary// Index drift status by technique_id for O(1) lookup while rendering cells.const driftByTid = new Map<string, DriftTechnique>()diff --git a/apps/web/src/components/alerts/AlertsView.tsx b/apps/web/src/components/alerts/AlertsView.tsxindex 65714c1da..37552766a 100644--- a/apps/web/src/components/alerts/AlertsView.tsx+++ b/apps/web/src/components/alerts/AlertsView.tsx@@ -3,6 +3,7 @@import { useState, useCallback } from 'react';import useSWR from 'swr';import Link from 'next/link';+import toast from 'react-hot-toast';import { alertsApi, type Alert, type AlertFilters, type ConfidenceLabel } from '@/lib/api';import { clsx } from 'clsx';import { formatDistanceToNow } from 'date-fns';@@ -294,7 +295,10 @@ export function AlertsView() {Alerts</button></div>- <button className="bg-blue-600 hover:bg-blue-500 text-white text-sm px-4 py-2 rounded-lg transition-colors">+ <button+ onClick={() => toast('Manual alert creation is coming soon.', { icon: '🔔' })}+ className="bg-blue-600 hover:bg-blue-500 text-white text-sm px-4 py-2 rounded-lg transition-colors"+ >+ Create Alert</button></div>diff --git a/apps/web/src/components/cases/CasesView.tsx b/apps/web/src/components/cases/CasesView.tsxindex 225c2dabd..dc07e37ae 100644--- a/apps/web/src/components/cases/CasesView.tsx+++ b/apps/web/src/components/cases/CasesView.tsx@@ -3,6 +3,7 @@import { useState } from 'react';import useSWR from 'swr';import Link from 'next/link';+import toast from 'react-hot-toast';import { casesApi, type Case } from '@/lib/api';import { clsx } from 'clsx';import { format } from 'date-fns';@@ -150,7 +151,10 @@ export function CasesView() {<h1 className="text-xl font-semibold text-gray-100">Cases</h1><p className="text-sm text-gray-500 mt-0.5">Manage security investigations and incidents</p></div>- <button className="flex items-center gap-2 bg-blue-600 hover:bg-blue-500 text-white text-sm font-medium px-4 py-2 rounded-lg transition-colors">+ <button+ onClick={() => toast('Case creation wizard is coming soon.', { icon: '📋' })}+ className="flex items-center gap-2 bg-blue-600 hover:bg-blue-500 text-white text-sm font-medium px-4 py-2 rounded-lg transition-colors"+ ><svg className="w-4 h-4" fill="none" viewBox="0 0 24 24" stroke="currentColor"><path strokeLinecap="round" strokeLinejoin="round" strokeWidth={2} d="M12 4v16m8-8H4" /></svg>diff --git a/apps/web/src/components/layout/AppShell.tsx b/apps/web/src/components/layout/AppShell.tsxindex 208cf3ac8..aa3b1fc00 100644--- a/apps/web/src/components/layout/AppShell.tsx+++ b/apps/web/src/components/layout/AppShell.tsx@@ -21,7 +21,7 @@ export function AppShell({ children }: AppShellProps) {<div className="min-h-screen bg-[#0a0d14]"><DemoBanner /><Sidebar />- <div className="ml-60">+ <div className="md:ml-60"><TopBar demoOffset={demo} /><main className={`${topPadClass} min-h-screen`}><div className="p-6">{children}</div>diff --git a/apps/web/src/components/layout/Sidebar.tsx b/apps/web/src/components/layout/Sidebar.tsxindex 0e381090b..87ebc2441 100644--- a/apps/web/src/components/layout/Sidebar.tsx+++ b/apps/web/src/components/layout/Sidebar.tsx@@ -1,5 +1,6 @@'use client';+import { useState } from 'react';import Link from 'next/link';import { usePathname } from 'next/navigation';import { clsx } from 'clsx';@@ -234,6 +235,7 @@ const navSections: NavSection[] = [export function Sidebar() {const pathname = usePathname();+ const [mobileOpen, setMobileOpen] = useState(false);const isActive = (href: string) => {if (href === '/dashboard') return pathname === '/dashboard';@@ -241,7 +243,31 @@ export function Sidebar() {};return (- <aside className="fixed inset-y-0 left-0 w-60 flex flex-col bg-gray-900/95 border-r border-gray-800/60 z-30">+ <>+ {/* Mobile hamburger */}+ <button+ type="button"+ aria-label="Open navigation"+ onClick={() => setMobileOpen(true)}+ className="md:hidden fixed top-4 left-4 z-40 p-2 rounded-lg bg-gray-800/90 text-gray-300 hover:text-white"+ >+ <svg className="w-5 h-5" fill="none" viewBox="0 0 24 24" stroke="currentColor">+ <path strokeLinecap="round" strokeLinejoin="round" strokeWidth={2} d="M4 6h16M4 12h16M4 18h16" />+ </svg>+ </button>++ {/* Backdrop */}+ {mobileOpen && (+ <div+ className="md:hidden fixed inset-0 z-30 bg-black/60"+ onClick={() => setMobileOpen(false)}+ />+ )}++ <aside className={clsx(+ 'fixed inset-y-0 left-0 w-60 flex flex-col bg-gray-900/95 border-r border-gray-800/60 z-40 transition-transform duration-200',+ mobileOpen ? 'translate-x-0' : '-translate-x-full md:translate-x-0'+ )}>{/* Logo */}<div className="flex items-center gap-3 px-5 h-16 border-b border-gray-800/60"><div className="flex-shrink-0 w-8 h-8 rounded-lg bg-blue-600/20 border border-blue-600/30 flex items-center justify-center">@@ -277,6 +303,7 @@ export function Sidebar() {<li key={item.href}><Linkhref={item.href}+ onClick={() => setMobileOpen(false)}className={clsx('flex items-center gap-3 px-3 py-2 rounded-lg text-sm font-medium transition-all duration-150',active@@ -318,5 +345,6 @@ export function Sidebar() {</div></div></aside>+ </>);}