chore: harden knowledge graph storage and clear common clippy warnings

Enforce stable 1:1 entity embeddings, relationship endpoint auth, and
user-scoped deletes; align schemas/migrations and resolve common crate
clippy findings.
This commit is contained in:
Per Stark
2026-05-28 21:46:35 +02:00
parent 189adb1a5f
commit 5724f11dc1
17 changed files with 533 additions and 209 deletions
+1 -1
View File
@@ -86,7 +86,7 @@ pub async fn delete_text_content(
// Delete the text content and any related data
TextChunk::delete_by_source_id(&text_content.id, &state.db).await?;
KnowledgeEntity::delete_by_source_id(&text_content.id, &state.db).await?;
KnowledgeRelationship::delete_relationships_by_source_id(&text_content.id, &state.db).await?;
KnowledgeRelationship::delete_relationships_by_source_id(&text_content.id, &user.id, &state.db).await?;
state
.db
.delete_item::<TextContent>(&text_content.id)