Skip to main content

Crate incident_correlation

Crate incident_correlation 

Source
Expand description

§incident-correlation

Walks the Kinetic Gain Protocol Suite document graph starting from an AI Incident Card and emits a structured remediation plan.

§What it answers

When something goes wrong with a deployed AI system, the operator writes an AI Incident Card that references the affected pieces — usually a tool, an agent, or a specific vendor’s AEO entity. The honest question after that is: what else does this incident touch?

  • Which agent-cards depend on the affected tool?
  • Which decision-cards approved the affected vendor?
  • Which AEO entities declare the affected entity in their authority chain?
  • Which active conditions on those decisions might now be in breach?

IncidentCorrelator::correlate walks the graph and returns a RemediationPlan with each affected node + a suggested action.

§Design

  • The graph is a petgraph::Graph of SuiteNodes.
  • Edges are typed (SuiteEdge::DependsOn, [SuiteEdge::ApprovedBy], SuiteEdge::Mentions), so the correlator can answer “what depends on X” with one BFS over a typed edge filter.
  • The whole pipeline is synchronous because graph work doesn’t need an executor. tokio only shows up in dev-deps for the test harness.

§Composes with

Re-exports§

pub use correlator::IncidentCorrelator;
pub use error::CorrelationError;
pub use graph::SuiteEdge;
pub use graph::SuiteGraph;
pub use graph::SuiteNode;
pub use model::IncidentCard;
pub use model::NodeKind;
pub use plan::Action;
pub use plan::AffectedNode;
pub use plan::RemediationPlan;

Modules§

audit_stream
Optional audit-stream-py producer. Gated behind the audit-stream Cargo feature so the core graph crate stays sync and HTTP-free. Optional audit-stream-py integration.
correlator
BFS over the Suite graph that turns an incident card into a remediation plan.
error
Crate-wide error type.
graph
The Suite graph.
model
Serialisable types.
plan
Output types — what the correlator hands back.