feat: add ecc2 graph observations

This commit is contained in:
Affaan Mustafa
2026-04-10 06:02:24 -07:00
parent 727d9380cb
commit 77c9082deb
4 changed files with 610 additions and 28 deletions

View File

@@ -190,12 +190,26 @@ pub struct ContextGraphEntityDetail {
pub incoming: Vec<ContextGraphRelation>,
}
#[derive(Debug, Clone, Serialize, Deserialize, PartialEq, Eq)]
pub struct ContextGraphObservation {
pub id: i64,
pub session_id: Option<String>,
pub entity_id: i64,
pub entity_type: String,
pub entity_name: String,
pub observation_type: String,
pub summary: String,
pub details: BTreeMap<String, String>,
pub created_at: DateTime<Utc>,
}
#[derive(Debug, Clone, Serialize, Deserialize, PartialEq, Eq)]
pub struct ContextGraphRecallEntry {
pub entity: ContextGraphEntity,
pub score: u64,
pub matched_terms: Vec<String>,
pub relation_count: usize,
pub observation_count: usize,
}
#[derive(Debug, Clone, Default, Serialize, Deserialize, PartialEq, Eq)]