W4: graph store + emission + home graph view

This commit is contained in:
Amos
2026-08-22 10:30:00 +03:00
parent 9a99b01159
commit 8728573253
8 changed files with 1297 additions and 11 deletions
+15
View File
@@ -0,0 +1,15 @@
import { foldStaleChats, graphSnapshot } from "@/src/core/graph";
/**
* The home graph view's data endpoint (W4; vision §1 "Home page"). Folds any
* chat whose updatedAt outstrips its emission checkpoint first (partial
* sessions deposit value), then returns nodes, edges, derived node states,
* and the session titles/provenance for node click-through.
*/
export const dynamic = "force-dynamic";
export async function GET() {
foldStaleChats();
return Response.json(graphSnapshot());
}