kyyn-core 0.1.11

Core vocabulary for kyyn: registry, links, query AST, plugin and validation contracts for typed, git-backed knowledge bases.
Documentation
//! Validation outcome types — the wire vocabulary of the validator protocol.
//!
//! Two severities: `Error` blocks an accept; `Warning` is surfaced but never
//! blocks. These are (de)serializable because they cross the process boundary
//! between the engine and a KB's compiled `schema/` validator.

use serde::{Deserialize, Serialize};

/// How bad a violation is: `Error` blocks accept, `Warning` is advisory.
#[derive(Debug, Clone, Copy, PartialEq, Eq, Serialize, Deserialize)]
pub enum Severity {
    Error,
    Warning,
}

/// One broken invariant, tied to the file that breaks it.
#[derive(Debug, Clone, Serialize, Deserialize)]
pub struct Violation {
    /// Repo-relative path of the offending file.
    pub path: String,
    pub severity: Severity,
    pub message: String,
}