ltcai 4.0.0 → 4.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +42 -33
- package/desktop/electron/main.cjs +44 -0
- package/docs/CHANGELOG.md +106 -0
- package/docs/REALTIME_COLLABORATION.md +3 -3
- package/docs/V3_FRONTEND.md +9 -8
- package/docs/V4_1_FRONTEND_ARCHITECTURE_REVIEW.md +65 -0
- package/docs/V4_1_FRONTEND_MIGRATION_REPORT.md +70 -0
- package/docs/V4_1_VALIDATION_REPORT.md +47 -0
- package/docs/V4_DIGITAL_BRAIN_RECOVERY.md +95 -45
- package/docs/kg-schema.md +6 -2
- package/docs/spec-vs-impl.md +10 -10
- package/frontend/index.html +24 -0
- package/frontend/openapi.json +14190 -0
- package/frontend/src/App.tsx +184 -0
- package/frontend/src/api/client.ts +317 -0
- package/frontend/src/api/openapi.ts +16637 -0
- package/frontend/src/components/primitives.tsx +204 -0
- package/frontend/src/components/ui/badge.tsx +27 -0
- package/frontend/src/components/ui/button.tsx +37 -0
- package/frontend/src/components/ui/card.tsx +22 -0
- package/frontend/src/components/ui/input.tsx +16 -0
- package/frontend/src/components/ui/textarea.tsx +16 -0
- package/frontend/src/lib/utils.ts +33 -0
- package/frontend/src/main.tsx +23 -0
- package/frontend/src/pages/Act.tsx +245 -0
- package/frontend/src/pages/Ask.tsx +200 -0
- package/frontend/src/pages/Brain.tsx +267 -0
- package/frontend/src/pages/Capture.tsx +158 -0
- package/frontend/src/pages/Library.tsx +187 -0
- package/frontend/src/pages/System.tsx +344 -0
- package/frontend/src/routes.ts +85 -0
- package/frontend/src/store/appStore.ts +54 -0
- package/frontend/src/styles.css +107 -0
- package/kg_schema.py +2 -603
- package/knowledge_graph.py +37 -4958
- package/latticeai/__init__.py +1 -1
- package/latticeai/api/admin.py +15 -16
- package/latticeai/api/agents.py +13 -6
- package/latticeai/api/auth.py +19 -11
- package/latticeai/api/invitations.py +100 -0
- package/latticeai/api/knowledge_graph.py +4 -11
- package/latticeai/api/plugins.py +3 -6
- package/latticeai/api/realtime.py +4 -7
- package/latticeai/api/setup.py +5 -4
- package/latticeai/api/static_routes.py +13 -16
- package/latticeai/api/ui_redirects.py +26 -0
- package/latticeai/api/workflow_designer.py +39 -6
- package/latticeai/api/workspace.py +24 -10
- package/latticeai/app_factory.py +88 -17
- package/latticeai/brain/_kg_common.py +1123 -0
- package/latticeai/brain/discovery.py +1455 -0
- package/latticeai/brain/documents.py +218 -0
- package/latticeai/brain/ingest.py +644 -0
- package/latticeai/brain/projection.py +561 -0
- package/latticeai/brain/provenance.py +401 -0
- package/latticeai/brain/retrieval.py +1316 -0
- package/latticeai/brain/schema.py +640 -0
- package/latticeai/brain/store.py +216 -0
- package/latticeai/brain/write_master.py +225 -0
- package/latticeai/core/invitations.py +131 -0
- package/latticeai/core/marketplace.py +1 -1
- package/latticeai/core/multi_agent.py +1 -1
- package/latticeai/core/policy.py +54 -0
- package/latticeai/core/realtime.py +65 -44
- package/latticeai/core/sessions.py +31 -5
- package/latticeai/core/users.py +147 -0
- package/latticeai/core/workspace_os.py +420 -20
- package/latticeai/services/agent_runtime.py +242 -4
- package/latticeai/services/run_executor.py +328 -0
- package/latticeai/services/workspace_service.py +27 -19
- package/package.json +54 -27
- package/scripts/build_frontend_assets.mjs +38 -0
- package/scripts/bump_version.py +1 -1
- package/scripts/export_openapi.py +31 -0
- package/scripts/lint_frontend.mjs +86 -0
- package/scripts/run_python.mjs +47 -0
- package/src-tauri/Cargo.lock +4833 -0
- package/src-tauri/Cargo.toml +19 -0
- package/src-tauri/build.rs +3 -0
- package/src-tauri/capabilities/default.json +7 -0
- package/src-tauri/src/main.rs +78 -0
- package/src-tauri/tauri.conf.json +36 -0
- package/static/app/asset-manifest.json +32 -0
- package/static/app/assets/core-CwxXejkd.js +2 -0
- package/static/app/assets/core-CwxXejkd.js.map +1 -0
- package/static/app/assets/index-CJRAzNnf.js +333 -0
- package/static/app/assets/index-CJRAzNnf.js.map +1 -0
- package/static/app/assets/index-CSwBBgf4.css +2 -0
- package/static/app/index.html +25 -0
- package/static/manifest.json +2 -2
- package/static/sw.js +4 -4
- package/scripts/build_v3_assets.mjs +0 -170
- package/scripts/lint_v3.mjs +0 -97
- package/static/account.html +0 -113
- package/static/activity.html +0 -73
- package/static/admin.html +0 -486
- package/static/agents.html +0 -139
- package/static/chat.html +0 -841
- package/static/css/reference/account.css +0 -439
- package/static/css/reference/admin.css +0 -610
- package/static/css/reference/base.css +0 -1661
- package/static/css/reference/chat.css +0 -4623
- package/static/css/reference/graph.css +0 -1016
- package/static/css/responsive.css +0 -861
- package/static/graph.html +0 -122
- package/static/platform.css +0 -104
- package/static/plugins.html +0 -136
- package/static/scripts/account.js +0 -238
- package/static/scripts/admin.js +0 -1614
- package/static/scripts/chat.js +0 -5081
- package/static/scripts/graph.js +0 -1804
- package/static/scripts/platform.js +0 -64
- package/static/scripts/ux.js +0 -167
- package/static/scripts/workspace.js +0 -948
- package/static/v3/asset-manifest.json +0 -56
- package/static/v3/css/lattice.base.49deefb5.css +0 -128
- package/static/v3/css/lattice.base.css +0 -128
- package/static/v3/css/lattice.components.cde18231.css +0 -472
- package/static/v3/css/lattice.components.css +0 -472
- package/static/v3/css/lattice.shell.29d36d85.css +0 -452
- package/static/v3/css/lattice.shell.css +0 -452
- package/static/v3/css/lattice.tokens.304cbc40.css +0 -135
- package/static/v3/css/lattice.tokens.css +0 -135
- package/static/v3/css/lattice.views.0a18b6c5.css +0 -360
- package/static/v3/css/lattice.views.css +0 -360
- package/static/v3/index.html +0 -68
- package/static/v3/js/app.356e6452.js +0 -26
- package/static/v3/js/app.js +0 -26
- package/static/v3/js/core/api.7a308b89.js +0 -568
- package/static/v3/js/core/api.js +0 -568
- package/static/v3/js/core/components.f25b3b93.js +0 -230
- package/static/v3/js/core/components.js +0 -230
- package/static/v3/js/core/dom.a2773eb0.js +0 -148
- package/static/v3/js/core/dom.js +0 -148
- package/static/v3/js/core/router.584570f2.js +0 -37
- package/static/v3/js/core/router.js +0 -37
- package/static/v3/js/core/routes.7222343d.js +0 -93
- package/static/v3/js/core/routes.js +0 -93
- package/static/v3/js/core/shell.a1657f20.js +0 -391
- package/static/v3/js/core/shell.js +0 -391
- package/static/v3/js/core/store.204a08b2.js +0 -113
- package/static/v3/js/core/store.js +0 -113
- package/static/v3/js/views/admin-audit.660a1fb1.js +0 -185
- package/static/v3/js/views/admin-audit.js +0 -185
- package/static/v3/js/views/admin-permissions.a7ae5f09.js +0 -177
- package/static/v3/js/views/admin-permissions.js +0 -177
- package/static/v3/js/views/admin-policies.3658fd86.js +0 -102
- package/static/v3/js/views/admin-policies.js +0 -102
- package/static/v3/js/views/admin-private-vpc.7d342d36.js +0 -135
- package/static/v3/js/views/admin-private-vpc.js +0 -135
- package/static/v3/js/views/admin-security.07c66b72.js +0 -180
- package/static/v3/js/views/admin-security.js +0 -180
- package/static/v3/js/views/admin-users.03bac88c.js +0 -168
- package/static/v3/js/views/admin-users.js +0 -168
- package/static/v3/js/views/agents.014d0b74.js +0 -541
- package/static/v3/js/views/agents.js +0 -541
- package/static/v3/js/views/chat.e6dd7dd0.js +0 -601
- package/static/v3/js/views/chat.js +0 -601
- package/static/v3/js/views/files.adad14c1.js +0 -365
- package/static/v3/js/views/files.js +0 -365
- package/static/v3/js/views/graph-canvas.17c15d65.js +0 -509
- package/static/v3/js/views/graph-canvas.js +0 -509
- package/static/v3/js/views/home.24f8b8ae.js +0 -200
- package/static/v3/js/views/home.js +0 -200
- package/static/v3/js/views/hooks.37895880.js +0 -220
- package/static/v3/js/views/hooks.js +0 -220
- package/static/v3/js/views/hybrid-search.2fb63ed9.js +0 -194
- package/static/v3/js/views/hybrid-search.js +0 -194
- package/static/v3/js/views/knowledge-graph.5e40cbeb.js +0 -509
- package/static/v3/js/views/knowledge-graph.js +0 -509
- package/static/v3/js/views/marketplace.ab0583d4.js +0 -141
- package/static/v3/js/views/marketplace.js +0 -141
- package/static/v3/js/views/mcp.99b5c6a7.js +0 -114
- package/static/v3/js/views/mcp.js +0 -114
- package/static/v3/js/views/memory.4ebdf474.js +0 -147
- package/static/v3/js/views/memory.js +0 -147
- package/static/v3/js/views/models.a1ffa147.js +0 -256
- package/static/v3/js/views/models.js +0 -256
- package/static/v3/js/views/my-computer.d9d9ae1c.js +0 -463
- package/static/v3/js/views/my-computer.js +0 -463
- package/static/v3/js/views/pipeline.c522f1ce.js +0 -157
- package/static/v3/js/views/pipeline.js +0 -157
- package/static/v3/js/views/planning.9ac3e313.js +0 -153
- package/static/v3/js/views/planning.js +0 -153
- package/static/v3/js/views/settings.8631fa5e.js +0 -318
- package/static/v3/js/views/settings.js +0 -318
- package/static/v3/js/views/skills.c6c2f965.js +0 -109
- package/static/v3/js/views/skills.js +0 -109
- package/static/v3/js/views/tools.e4f11276.js +0 -108
- package/static/v3/js/views/tools.js +0 -108
- package/static/v3/js/views/workflows.26c57290.js +0 -128
- package/static/v3/js/views/workflows.js +0 -128
- package/static/workflows.html +0 -146
- package/static/workspace.css +0 -1121
- package/static/workspace.html +0 -357
package/README.md
CHANGED
|
@@ -56,10 +56,10 @@ workspace around the work itself:
|
|
|
56
56
|
LM Studio; nothing leaves your machine unless you opt in.
|
|
57
57
|
- **Use cloud models only when you choose** — bring an API key for cloud LLMs
|
|
58
58
|
when you want them, not by default.
|
|
59
|
-
- **Inspect every agent run** —
|
|
60
|
-
retries, and
|
|
61
|
-
|
|
62
|
-
|
|
59
|
+
- **Inspect every agent run** — runs persist queued/running/final state, plans,
|
|
60
|
+
reviews, retries, cancellation, and replayable logs. With a loaded model the
|
|
61
|
+
v4 runner uses it; without one, deterministic simulation mode is explicitly
|
|
62
|
+
labeled and does not call a model.
|
|
63
63
|
|
|
64
64
|
Lattice AI is not a clone of ChatGPT, Claude, Cursor, Obsidian, or Notion. It
|
|
65
65
|
sits in a different place: a **workspace** that ties local/self-hosted AI, your
|
|
@@ -75,8 +75,8 @@ and workflows together — and runs on your own hardware.
|
|
|
75
75
|
Knowledge Graph.
|
|
76
76
|
- Run local models through MLX, Ollama, or LM Studio, and use cloud LLMs only when
|
|
77
77
|
you want to.
|
|
78
|
-
- Define agent workflows and replay their run records step by step
|
|
79
|
-
|
|
78
|
+
- Define agent workflows and replay their run records step by step, including
|
|
79
|
+
live tool execution, approval pauses, and cooperative cancellation.
|
|
80
80
|
- Separate personal work from organization work.
|
|
81
81
|
- Switch between Basic, Advanced, and Admin modes depending on your role.
|
|
82
82
|
|
|
@@ -115,9 +115,9 @@ connect — context that stays useful even when you switch models.
|
|
|
115
115
|

|
|
116
116
|
|
|
117
117
|
The agent runner turns a goal into an inspectable, replayable run record — roles,
|
|
118
|
-
logs, review, and
|
|
119
|
-
|
|
120
|
-
|
|
118
|
+
logs, review, retry, and cancellation state — that you can read back step by
|
|
119
|
+
step. Runs execute asynchronously and use the loaded model when one is available;
|
|
120
|
+
otherwise they are labeled as simulation.
|
|
121
121
|
|
|
122
122
|
### Extend with hooks and the local runtime
|
|
123
123
|
|
|
@@ -203,34 +203,34 @@ npm run dev
|
|
|
203
203
|
|
|
204
204
|
## Latest Release
|
|
205
205
|
|
|
206
|
-
###
|
|
207
|
-
|
|
208
|
-
- **
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
-
|
|
222
|
-
|
|
223
|
-
- **
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
206
|
+
### v4.1.0 RC — Frontend & Desktop Rebuild
|
|
207
|
+
|
|
208
|
+
- **React desktop SPA** — `/app` is now a React + TypeScript + Vite application
|
|
209
|
+
with TanStack Query, Zustand, React Flow, Cytoscape.js, Tailwind CSS, and
|
|
210
|
+
local shadcn-style primitives.
|
|
211
|
+
- **Generated API client** — frontend JSON calls consume the existing FastAPI
|
|
212
|
+
contract through a generated OpenAPI TypeScript client; streaming chat and
|
|
213
|
+
multipart upload remain honest fetch special cases.
|
|
214
|
+
- **Tauri-first desktop shell** — Tauri 2.0 is the primary desktop target,
|
|
215
|
+
launching the local backend by default; Electron is retained as a fallback
|
|
216
|
+
shell only.
|
|
217
|
+
- **Graph-first navigation** — the primary surfaces are Brain, Ask, Capture,
|
|
218
|
+
Act, Library, and System, with old `/app#...` routes mapped into the new
|
|
219
|
+
capability groups.
|
|
220
|
+
- **No CDN / offline-capable** — shipped app assets are built into
|
|
221
|
+
`static/app`, service-worker precached, and verified to avoid CDN
|
|
222
|
+
dependencies.
|
|
223
|
+
- **v4.0.1 capability preservation** — Brain Core, storage, agent/workflow
|
|
224
|
+
runtime, privacy model, local-first operation, and backend API contracts are
|
|
225
|
+
preserved.
|
|
226
|
+
|
|
227
|
+
See [RELEASE_NOTES_v4.1.0.md](RELEASE_NOTES_v4.1.0.md),
|
|
227
228
|
[docs/kg-schema.md](docs/kg-schema.md),
|
|
228
|
-
[docs/RUNTIME_HOOK_COVERAGE_v3.6.0.md](docs/RUNTIME_HOOK_COVERAGE_v3.6.0.md), and
|
|
229
229
|
[FEATURE_STATUS.md](FEATURE_STATUS.md).
|
|
230
230
|
|
|
231
231
|
## How it works — every source converges into the graph
|
|
232
232
|
|
|
233
|
-
As of
|
|
233
|
+
As of v4.1.0, data sources flow through the brain ingestion pipeline into
|
|
234
234
|
the Knowledge Graph — no source bypasses it, none becomes an isolated silo:
|
|
235
235
|
|
|
236
236
|
```text
|
|
@@ -264,6 +264,9 @@ For the deeper design, see [ARCHITECTURE.md](ARCHITECTURE.md) and
|
|
|
264
264
|
|
|
265
265
|
- [ARCHITECTURE.md](ARCHITECTURE.md) — workspace, graph, pipeline, and model overview
|
|
266
266
|
- [docs/architecture.md](docs/architecture.md) — full architecture reference
|
|
267
|
+
- [docs/V4_1_FRONTEND_ARCHITECTURE_REVIEW.md](docs/V4_1_FRONTEND_ARCHITECTURE_REVIEW.md) — v4.1.0 frontend and desktop architecture review
|
|
268
|
+
- [docs/V4_1_FRONTEND_MIGRATION_REPORT.md](docs/V4_1_FRONTEND_MIGRATION_REPORT.md) — v4.1.0 capability migration report
|
|
269
|
+
- [docs/V4_1_VALIDATION_REPORT.md](docs/V4_1_VALIDATION_REPORT.md) — v4.1.0 validation report
|
|
267
270
|
- [docs/V3_BACKEND_ARCHITECTURE.md](docs/V3_BACKEND_ARCHITECTURE.md) — backend storage, search, and retrieval
|
|
268
271
|
|
|
269
272
|
### Knowledge and retrieval
|
|
@@ -282,6 +285,9 @@ For the deeper design, see [ARCHITECTURE.md](ARCHITECTURE.md) and
|
|
|
282
285
|
### Releases
|
|
283
286
|
|
|
284
287
|
- [RELEASE_NOTES.md](RELEASE_NOTES.md) — current release notes
|
|
288
|
+
- [RELEASE_NOTES_v4.1.0.md](RELEASE_NOTES_v4.1.0.md)
|
|
289
|
+
- [RELEASE_NOTES_v4.0.1.md](RELEASE_NOTES_v4.0.1.md)
|
|
290
|
+
- [RELEASE_NOTES_v4.0.0.md](RELEASE_NOTES_v4.0.0.md)
|
|
285
291
|
- [RELEASE_NOTES_v3.6.0.md](RELEASE_NOTES_v3.6.0.md)
|
|
286
292
|
- [RELEASE_NOTES_v3.5.0.md](RELEASE_NOTES_v3.5.0.md)
|
|
287
293
|
- [RELEASE_NOTES_v3.4.1.md](RELEASE_NOTES_v3.4.1.md)
|
|
@@ -292,7 +298,10 @@ For the deeper design, see [ARCHITECTURE.md](ARCHITECTURE.md) and
|
|
|
292
298
|
|
|
293
299
|
| Version | Theme |
|
|
294
300
|
| --- | --- |
|
|
295
|
-
| **
|
|
301
|
+
| **4.1.0** | Frontend & Desktop Rebuild RC — React/Vite/OpenAPI desktop SPA, Tauri 2.0 primary shell, graph-first navigation, and legacy static frontend removal |
|
|
302
|
+
| **4.0.1** | Digital Brain Platform maintenance — closes post-tag v4 gaps with durable async runs, stable identity/workspace state, full `/app` parity, and legacy UI retirement |
|
|
303
|
+
| **4.0.0** | Digital Brain Platform — decomposed brain store, v2 write-mastered Knowledge Graph, durable memory/context, real workflow/agent foundations, signed brain exchange |
|
|
304
|
+
| 3.6.0 | Knowledge Graph First — unified ingestion pipeline, formalized entity/relationship model, browser/web ingestion, local export/import/backup, provenance, KG as the primary surface |
|
|
296
305
|
| 3.5.0 | Foundation stabilization & verification — OIDC verifier, trusted-proxy gating, runtime hook coverage, `tools/` package, reproducible artifacts |
|
|
297
306
|
| 3.4.1 | Runtime completion — full hooks lifecycle, real Local Agent probes, Connect Folder and Folder Watch verified end-to-end |
|
|
298
307
|
| 3.4.0 | Platform completion — hooks execution, uploads in Files, vision image input, agent run trigger, on-device Local Agent / Connect Folder / Folder Watch |
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
const { app, BrowserWindow } = require("electron");
|
|
2
|
+
const { spawn } = require("node:child_process");
|
|
3
|
+
const path = require("node:path");
|
|
4
|
+
|
|
5
|
+
const origin = process.env.LATTICEAI_DESKTOP_BACKEND_ORIGIN || "http://127.0.0.1:8765";
|
|
6
|
+
let backend = null;
|
|
7
|
+
|
|
8
|
+
function startBackend() {
|
|
9
|
+
if (process.env.LATTICEAI_DESKTOP_NO_BACKEND) return;
|
|
10
|
+
const command = process.env.LATTICEAI_DESKTOP_BACKEND_CMD || "python3 ltcai_cli.py --host 127.0.0.1 --port 8765";
|
|
11
|
+
const [bin, ...args] = command.split(/\s+/).filter(Boolean);
|
|
12
|
+
if (!bin) return;
|
|
13
|
+
backend = spawn(bin, args, {
|
|
14
|
+
cwd: process.env.LATTICEAI_DESKTOP_BACKEND_CWD || path.resolve(__dirname, "../.."),
|
|
15
|
+
env: { ...process.env, LATTICEAI_HOST: "127.0.0.1", LATTICEAI_PORT: "8765", LATTICEAI_TUNNEL: "false" },
|
|
16
|
+
stdio: "ignore",
|
|
17
|
+
});
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
function createWindow() {
|
|
21
|
+
const win = new BrowserWindow({
|
|
22
|
+
width: 1440,
|
|
23
|
+
height: 920,
|
|
24
|
+
minWidth: 1024,
|
|
25
|
+
minHeight: 720,
|
|
26
|
+
title: "Lattice AI",
|
|
27
|
+
webPreferences: {
|
|
28
|
+
contextIsolation: true,
|
|
29
|
+
nodeIntegration: false,
|
|
30
|
+
sandbox: true,
|
|
31
|
+
},
|
|
32
|
+
});
|
|
33
|
+
win.loadURL(`${origin}/app`);
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
app.whenReady().then(() => {
|
|
37
|
+
startBackend();
|
|
38
|
+
createWindow();
|
|
39
|
+
});
|
|
40
|
+
|
|
41
|
+
app.on("window-all-closed", () => {
|
|
42
|
+
if (backend) backend.kill();
|
|
43
|
+
if (process.platform !== "darwin") app.quit();
|
|
44
|
+
});
|
package/docs/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,111 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## [4.1.0] - 2026-06-12
|
|
4
|
+
|
|
5
|
+
> Frontend & Desktop Rebuild release candidate. The existing FastAPI backend,
|
|
6
|
+
> Brain Core, storage architecture, and agent/workflow runtime remain the
|
|
7
|
+
> source of truth; the frontend and desktop shell are replaced by a React/Vite
|
|
8
|
+
> desktop architecture.
|
|
9
|
+
|
|
10
|
+
### Added
|
|
11
|
+
|
|
12
|
+
- React + TypeScript + Vite SPA under `frontend/`, using TanStack Query,
|
|
13
|
+
Zustand, React Flow, Cytoscape.js, Tailwind CSS, local shadcn-style
|
|
14
|
+
primitives, and a generated OpenAPI TypeScript client.
|
|
15
|
+
- Tauri 2.0 desktop shell under `src-tauri/` that launches the local backend
|
|
16
|
+
and exposes the backend origin to the SPA; Electron fallback shell retained
|
|
17
|
+
under `desktop/electron/`.
|
|
18
|
+
- Primary graph-first navigation: Brain, Ask, Capture, Act, Library, System.
|
|
19
|
+
- OpenAPI export/generation script and frontend lint guard for generated-client
|
|
20
|
+
usage, no-CDN static assets, and stale frontend references.
|
|
21
|
+
|
|
22
|
+
### Changed
|
|
23
|
+
|
|
24
|
+
- `/app` now serves the built React/Vite bundle from `static/app`.
|
|
25
|
+
- Legacy static v3 frontend assets and v3 build/lint scripts are removed after
|
|
26
|
+
capability parity was migrated into the new React surfaces.
|
|
27
|
+
- Release/build scripts now build Vite app assets and preserve Python, npm, and
|
|
28
|
+
VSIX packaging flows at version `4.1.0`.
|
|
29
|
+
- npm Python-backed scripts use `scripts/run_python.mjs` to prefer
|
|
30
|
+
`LTCAI_PYTHON` or the repo virtualenv before falling back to system Python.
|
|
31
|
+
|
|
32
|
+
### Validation Scope
|
|
33
|
+
|
|
34
|
+
- Python compile check, ruff, unit tests, live integration tests, frontend lint,
|
|
35
|
+
TypeScript build, Playwright visual tests, desktop shell checks, no-CDN
|
|
36
|
+
verification, release artifact validation, wheel smoke, and npm pack dry-run.
|
|
37
|
+
|
|
38
|
+
### Expected Artifacts
|
|
39
|
+
|
|
40
|
+
- `dist/ltcai-4.1.0-py3-none-any.whl`
|
|
41
|
+
- `dist/ltcai-4.1.0.tar.gz`
|
|
42
|
+
- `dist/ltcai-4.1.0.vsix`
|
|
43
|
+
- `ltcai-4.1.0.tgz`
|
|
44
|
+
|
|
45
|
+
## [4.0.1] - 2026-06-12
|
|
46
|
+
|
|
47
|
+
> Digital Brain Platform maintenance release for commits on `main` after tag
|
|
48
|
+
> `v4.0.0`. This release does not publish to PyPI, npm, the VS Code
|
|
49
|
+
> Marketplace, or Open VSX; artifacts are built and attached to GitHub Release
|
|
50
|
+
> `v4.0.1` only.
|
|
51
|
+
|
|
52
|
+
### Added
|
|
53
|
+
|
|
54
|
+
- Durable async run executor for agent/workflow runs, including persisted
|
|
55
|
+
queued/running/final states, realtime SSE progress, cooperative cancellation,
|
|
56
|
+
and startup reconciliation of orphaned active runs.
|
|
57
|
+
- Stable user UUID migration, centralized policy enforcement, local invitation
|
|
58
|
+
tokens, and SQLite-backed Workspace OS state with JSON compatibility
|
|
59
|
+
mirroring.
|
|
60
|
+
- Complete `/app` SPA parity surfaces for account/profile/password, workspace
|
|
61
|
+
and organization administration, invitations, snapshots/time-machine with
|
|
62
|
+
merge-restore, activity/presence, run approvals/cancellation, workflow
|
|
63
|
+
triggers, Brain Network pairing/push, chat context trace, and Knowledge Graph
|
|
64
|
+
provenance coverage.
|
|
65
|
+
|
|
66
|
+
### Changed
|
|
67
|
+
|
|
68
|
+
- Retired legacy static HTML/CSS/JS UI pages and legacy visual specs. Legacy GET
|
|
69
|
+
routes now redirect into the matching `/app` surface.
|
|
70
|
+
- Added en/ko i18n runtime coverage for the shell, routes, and new parity views,
|
|
71
|
+
guarded by `scripts/lint_v3.mjs`.
|
|
72
|
+
- Bumped synchronized package/runtime versions to `4.0.1`.
|
|
73
|
+
|
|
74
|
+
### Expected Artifacts
|
|
75
|
+
|
|
76
|
+
- `dist/ltcai-4.0.1-py3-none-any.whl`
|
|
77
|
+
- `dist/ltcai-4.0.1.tar.gz`
|
|
78
|
+
- `dist/ltcai-4.0.1.vsix`
|
|
79
|
+
- `ltcai-4.0.1.tgz`
|
|
80
|
+
|
|
81
|
+
## [4.0.0] - 2026-06-12
|
|
82
|
+
|
|
83
|
+
> Digital Brain Platform. The Knowledge Graph is now the durable brain store
|
|
84
|
+
> spine: focused `latticeai/brain/` modules own graph storage, schema, ingestion,
|
|
85
|
+
> provenance, retrieval, and document structure, while root modules remain
|
|
86
|
+
> compatibility shims.
|
|
87
|
+
|
|
88
|
+
### Changed
|
|
89
|
+
|
|
90
|
+
- Decomposed the monolithic Knowledge Graph implementation into focused
|
|
91
|
+
`latticeai/brain/` modules, with every new module kept below 1,500 lines.
|
|
92
|
+
- Flipped graph writes to `nodes_v2` / `edges_v2` as the authoritative write
|
|
93
|
+
path; legacy tables are maintained as a compatibility projection.
|
|
94
|
+
- Added one-time pre-flip SQLite backup, `PRAGMA user_version=4`, schema-version
|
|
95
|
+
reporting, and fail-closed protection for newer DB formats.
|
|
96
|
+
- Added the durable async run executor for agent/workflow runs: persisted
|
|
97
|
+
queued/running/final states, realtime SSE progress, cooperative cancellation,
|
|
98
|
+
and startup reconciliation of orphaned active runs.
|
|
99
|
+
- Added stable user UUID migration, centralized RBAC policy enforcement, local
|
|
100
|
+
invitation tokens, and SQLite-backed Workspace OS state with JSON compatibility
|
|
101
|
+
mirroring and no durable-history truncation.
|
|
102
|
+
- Retired the legacy static UI pages in favor of the v4 `/app` SPA. Legacy GET
|
|
103
|
+
routes redirect into `/app`; new parity views cover token-native account,
|
|
104
|
+
workspace/org management, invitations, snapshots/time-machine with
|
|
105
|
+
merge-restore, activity/presence, run approvals/cancellation, workflow
|
|
106
|
+
triggers, Brain Network peer pairing/push, chat context trace, and Knowledge
|
|
107
|
+
Graph provenance coverage, with en/ko i18n gated by frontend lint.
|
|
108
|
+
|
|
3
109
|
## [3.6.0] - 2026-06-10
|
|
4
110
|
|
|
5
111
|
> Knowledge Graph First. The Knowledge Graph becomes the primary architecture:
|
|
@@ -41,7 +41,7 @@ The bus is **in-process** (one server, local-first) and fans events out to
|
|
|
41
41
|
in-memory subscriber queues.
|
|
42
42
|
|
|
43
43
|
> **Compatibility.** This subsystem is purely additive. It introduces new
|
|
44
|
-
> `/realtime/*` endpoints and an `/activity` page, and it attaches to the
|
|
44
|
+
> `/realtime/*` endpoints and an `/app#/activity` page, and it attaches to the
|
|
45
45
|
> existing `WorkspaceOSStore` through an optional `event_sink` hook. No v1.x
|
|
46
46
|
> data shape, API, or behavior changes. With zero subscribers the bus is a
|
|
47
47
|
> no-op, so single-user local mode behaves exactly as before.
|
|
@@ -274,8 +274,8 @@ router is mounted in `server_app.py` with the live bus, the auth helpers, and
|
|
|
274
274
|
|
|
275
275
|
### `GET /activity`
|
|
276
276
|
|
|
277
|
-
|
|
278
|
-
|
|
277
|
+
Compatibility redirect to `/app#/activity`. The Activity UI is part of the v4
|
|
278
|
+
SPA and reads `/realtime/feed`, `/realtime/presence`, and `/workspace/time-machine`.
|
|
279
279
|
|
|
280
280
|
### `GET /realtime/stream`
|
|
281
281
|
|
package/docs/V3_FRONTEND.md
CHANGED
|
@@ -6,9 +6,9 @@
|
|
|
6
6
|
|
|
7
7
|
Entry point: **`/app`** (served by `latticeai/api/static_routes.py` →
|
|
8
8
|
`static/v3/index.html`). Login, auto-login after registration, SSO callback, and
|
|
9
|
-
the PWA manifest land on `/app`.
|
|
10
|
-
`/chat`, `/graph`, `/admin`, …)
|
|
11
|
-
|
|
9
|
+
the PWA manifest land on `/app`. Legacy multi-page static screens have been
|
|
10
|
+
deleted; compatibility routes (`/workspace`, `/chat`, `/graph`, `/admin`, …)
|
|
11
|
+
redirect into their `/app#/...` views.
|
|
12
12
|
|
|
13
13
|
---
|
|
14
14
|
|
|
@@ -31,11 +31,12 @@ One declarative table (`static/v3/js/core/routes.js`) drives the nav rail, the
|
|
|
31
31
|
command palette, the router, breadcrumbs, and lazy view loading.
|
|
32
32
|
|
|
33
33
|
```
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
34
|
+
Brain Knowledge Graph · Hybrid Search · Memory
|
|
35
|
+
Ask Chat
|
|
36
|
+
Capture Files · Pipeline*
|
|
37
|
+
Act Agents* · Runs* · Workflows* · Planning* · Hooks*
|
|
38
|
+
Library Models · Skills* · MCP* · Marketplace*
|
|
39
|
+
System Overview · Account · Workspaces · Snapshots · Activity · Network* · Settings · My Computer*
|
|
39
40
|
Administration Users · Permissions · Audit Logs · Security · Policies · Private VPC (admin mode)
|
|
40
41
|
```
|
|
41
42
|
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
# v4.1.0 Frontend Architecture Review
|
|
2
|
+
|
|
3
|
+
## Scope
|
|
4
|
+
|
|
5
|
+
This review covers the v4.1.0 replacement of the `/app` frontend and desktop
|
|
6
|
+
shell. It does not redesign Brain Core, storage, backend API contracts, or the
|
|
7
|
+
agent/workflow runtime.
|
|
8
|
+
|
|
9
|
+
## Baseline
|
|
10
|
+
|
|
11
|
+
v4.0.1 served a static frontend assembled under `static/v3` with bespoke build
|
|
12
|
+
and lint scripts. Capability parity existed, but the implementation duplicated
|
|
13
|
+
view systems, carried legacy static route assumptions, and could not cleanly
|
|
14
|
+
share typed API contracts with the FastAPI backend.
|
|
15
|
+
|
|
16
|
+
## Target Architecture
|
|
17
|
+
|
|
18
|
+
- Desktop shell: Tauri 2.0 primary, Electron fallback only.
|
|
19
|
+
- Frontend: React, TypeScript, Vite, TanStack Query, Zustand, React Flow,
|
|
20
|
+
Cytoscape.js, Tailwind CSS, local shadcn-style primitives.
|
|
21
|
+
- API: generated OpenAPI TypeScript client from the existing FastAPI app.
|
|
22
|
+
- Runtime: single client-side SPA, no SSR, no CDN.
|
|
23
|
+
- Backend: existing FastAPI app remains the source of truth.
|
|
24
|
+
|
|
25
|
+
## Implemented Architecture
|
|
26
|
+
|
|
27
|
+
- `frontend/` owns the React/Vite source.
|
|
28
|
+
- `frontend/src/api/openapi.ts` is generated from `frontend/openapi.json`.
|
|
29
|
+
- `frontend/src/api/client.ts` wraps generated-client JSON calls and keeps
|
|
30
|
+
streaming chat plus multipart upload as explicit fetch special cases.
|
|
31
|
+
- `frontend/src/routes.ts` defines Brain, Ask, Capture, Act, Library, System and
|
|
32
|
+
maps legacy hash routes into those groups.
|
|
33
|
+
- `static/app` is the shipped build output and is served by `/app`.
|
|
34
|
+
- `src-tauri/` contains the Tauri 2.0 shell and backend-origin bridge.
|
|
35
|
+
- `desktop/electron/` contains the fallback shell.
|
|
36
|
+
- `static/sw.js` precaches the React app manifest/assets for offline-capable
|
|
37
|
+
local startup.
|
|
38
|
+
|
|
39
|
+
## Boundary Decisions
|
|
40
|
+
|
|
41
|
+
- The backend contract was preserved; only the frontend consumer changed.
|
|
42
|
+
- Brain Core and storage modules were not modified for UI convenience.
|
|
43
|
+
- No CDN fallback was introduced; all visual/runtime dependencies are bundled.
|
|
44
|
+
- No demo-only controls were added. Unavailable capabilities render explicit
|
|
45
|
+
unavailable/error states based on API responses.
|
|
46
|
+
- npm runtime installs are kept lean: React/Vite/Tauri/Electron toolchains are
|
|
47
|
+
development dependencies because the distributable app ships built assets.
|
|
48
|
+
|
|
49
|
+
## Capability Mapping
|
|
50
|
+
|
|
51
|
+
| v4.0.1 capability | v4.1.0 surface |
|
|
52
|
+
| --- | --- |
|
|
53
|
+
| Knowledge Graph, hybrid search, memory, provenance, portability | Brain |
|
|
54
|
+
| Chat, conversations, context trace, attachments | Ask |
|
|
55
|
+
| Uploads, connected folders, local runtime, URL capture, index pipeline | Capture |
|
|
56
|
+
| Agents, runs, approvals, workflows, triggers, hooks, tools | Act |
|
|
57
|
+
| Models, embeddings, skills, MCP, templates/plugins | Library |
|
|
58
|
+
| Account, auth, workspaces, snapshots, activity, network, settings, admin/security | System |
|
|
59
|
+
|
|
60
|
+
## Residual Risk
|
|
61
|
+
|
|
62
|
+
- The first Vite bundle is larger than 500 kB after minification because graph,
|
|
63
|
+
workflow, and app shell libraries are included in the initial desktop SPA
|
|
64
|
+
bundle. This is a performance optimization target, not a capability blocker,
|
|
65
|
+
and the build remains fully local/offline.
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
# v4.1.0 Frontend Migration Report
|
|
2
|
+
|
|
3
|
+
## Objective
|
|
4
|
+
|
|
5
|
+
Replace the v4.0.1 static frontend implementation with the Digital Brain
|
|
6
|
+
desktop architecture while preserving capabilities, user data, backend API
|
|
7
|
+
contracts, and local-first/offline operation.
|
|
8
|
+
|
|
9
|
+
## Migration Summary
|
|
10
|
+
|
|
11
|
+
- Added React + TypeScript + Vite source under `frontend/`.
|
|
12
|
+
- Added generated OpenAPI schema/client files under `frontend/openapi.json` and
|
|
13
|
+
`frontend/src/api/openapi.ts`.
|
|
14
|
+
- Added React capability pages for Brain, Ask, Capture, Act, Library, System.
|
|
15
|
+
- Added Tauri 2.0 desktop shell under `src-tauri/`.
|
|
16
|
+
- Added Electron fallback shell under `desktop/electron/`.
|
|
17
|
+
- Replaced `/app` static serving with `static/app/index.html`.
|
|
18
|
+
- Replaced v3 asset build/lint scripts with Vite build and frontend lint guards.
|
|
19
|
+
- Removed `static/v3` and retired `scripts/build_v3_assets.mjs` /
|
|
20
|
+
`scripts/lint_v3.mjs`.
|
|
21
|
+
- Updated package metadata so Python wheel/sdist, npm tgz, and VSIX builds ship
|
|
22
|
+
the new `static/app` assets.
|
|
23
|
+
|
|
24
|
+
## Compatibility
|
|
25
|
+
|
|
26
|
+
- Existing FastAPI routes are preserved.
|
|
27
|
+
- The generated OpenAPI client is produced from the live app schema.
|
|
28
|
+
- Legacy app hash routes are mapped into the new primary navigation groups.
|
|
29
|
+
- Service worker caching now targets the Vite app manifest instead of v3 assets.
|
|
30
|
+
- User data formats, Brain database files, Workspace OS state, snapshots,
|
|
31
|
+
conversations, memories, and graph data are not migrated or destructively
|
|
32
|
+
changed by the frontend rebuild.
|
|
33
|
+
|
|
34
|
+
## Capability Parity
|
|
35
|
+
|
|
36
|
+
| Capability | Migration result |
|
|
37
|
+
| --- | --- |
|
|
38
|
+
| Brain graph exploration | Cytoscape.js graph view in Brain |
|
|
39
|
+
| Hybrid search | Brain search tab backed by `/api/search/hybrid` |
|
|
40
|
+
| Memory recall | Brain memory tab backed by memory APIs |
|
|
41
|
+
| Provenance and portability | Brain provenance/portability actions |
|
|
42
|
+
| Chat and context trace | Ask surface with streaming chat and context panel |
|
|
43
|
+
| Conversation management | Ask history backed by conversation APIs |
|
|
44
|
+
| Document upload | Capture upload using multipart backend endpoint |
|
|
45
|
+
| Connected folders/local runtime | Capture desktop/local runtime APIs |
|
|
46
|
+
| Index pipeline and URL capture | Capture pipeline/browser ingestion APIs |
|
|
47
|
+
| Agents and run records | Act agents/runs/approvals backed by runtime APIs |
|
|
48
|
+
| Workflow graph | Act React Flow visualization and workflow APIs |
|
|
49
|
+
| Triggers, hooks, tools | Act surfaces backed by trigger/hook/tool APIs |
|
|
50
|
+
| Models and embeddings | Library model/embedding APIs |
|
|
51
|
+
| Skills, MCP, templates/plugins | Library registry APIs |
|
|
52
|
+
| Account/auth/profile/password | System account APIs |
|
|
53
|
+
| Workspaces/invitations | System workspace APIs |
|
|
54
|
+
| Snapshots/time-machine | System snapshot APIs |
|
|
55
|
+
| Activity/presence/network | System activity and network APIs |
|
|
56
|
+
| Admin/security/settings | System admin and settings APIs |
|
|
57
|
+
|
|
58
|
+
## Removed Frontend Debt
|
|
59
|
+
|
|
60
|
+
- Duplicate static v3 view modules.
|
|
61
|
+
- Legacy frontend build pipeline.
|
|
62
|
+
- Legacy v3 frontend lint script.
|
|
63
|
+
- Static v3 asset tree in release packages.
|
|
64
|
+
- Direct current-release references to v4.0.1 in latest docs.
|
|
65
|
+
|
|
66
|
+
## Data Preservation
|
|
67
|
+
|
|
68
|
+
No user data migration is required for v4.1.0. All persisted state remains owned
|
|
69
|
+
by the existing backend stores. The frontend rebuild only changes the client and
|
|
70
|
+
desktop shell used to access those stores.
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
# v4.1.0 Validation Report
|
|
2
|
+
|
|
3
|
+
## Summary
|
|
4
|
+
|
|
5
|
+
v4.1.0 RC validation passed for the React/Vite frontend, Tauri desktop shell,
|
|
6
|
+
FastAPI backend compatibility, release artifacts, and installed-wheel smoke.
|
|
7
|
+
|
|
8
|
+
## Commands Run
|
|
9
|
+
|
|
10
|
+
| Area | Command | Result |
|
|
11
|
+
| --- | --- | --- |
|
|
12
|
+
| OpenAPI generation | `npm run frontend:openapi` | Pass; generated 308 paths |
|
|
13
|
+
| Static app build | `npm run build:assets` | Pass; wrote `static/app/asset-manifest.json` |
|
|
14
|
+
| Frontend lint / no CDN / API compatibility | `npm run lint` | Pass; scanned 28 frontend/static files; OpenAPI exposes 308 paths |
|
|
15
|
+
| TypeScript build | `npm run typecheck` | Pass; frontend TS + VS Code extension build |
|
|
16
|
+
| Python compile | `npm run check:python` | Pass; compiled 206 modules |
|
|
17
|
+
| Ruff | `node scripts/run_python.mjs -m ruff check .` | Pass |
|
|
18
|
+
| Unit tests | `npm run test:unit -- --tb=short` | Pass; 585 passed, 2 warnings |
|
|
19
|
+
| Live integration tests | `LTCAI_TEST_BASE_URL=http://127.0.0.1:8899 npm run test:integration -- --tb=short` | Pass; 9 passed |
|
|
20
|
+
| Playwright visual/offline tests | `npx playwright test tests/visual/v3.spec.js` | Pass; 12 passed |
|
|
21
|
+
| Tauri cargo check | `npm run desktop:tauri:check` | Pass |
|
|
22
|
+
| Tauri desktop build | `LATTICEAI_DESKTOP_NO_BACKEND=1 npm run desktop:tauri:build` | Pass; built `.app` and DMG |
|
|
23
|
+
| Electron fallback syntax/version | `node --check desktop/electron/main.cjs && npx electron --version` | Pass; Electron v42.4.0 |
|
|
24
|
+
| Release artifacts | `npm run release:artifacts` plus resumed `npm pack && npm run package:vsix` | Pass |
|
|
25
|
+
| Artifact validation | `npm run release:validate` | Pass; exact v4.1.0 wheel/sdist/VSIX/tgz found |
|
|
26
|
+
| Wheel smoke | `node scripts/run_python.mjs scripts/wheel_smoke.py --wheel dist/ltcai-4.1.0-py3-none-any.whl` | Pass; imports 19 modules and `/health` reports 4.1.0 |
|
|
27
|
+
| npm pack dry-run | `npm pack --dry-run` | Pass; `ltcai-4.1.0.tgz`, 259 files, 2.9 MB |
|
|
28
|
+
|
|
29
|
+
## Generated Artifacts
|
|
30
|
+
|
|
31
|
+
- `dist/ltcai-4.1.0-py3-none-any.whl`
|
|
32
|
+
- `dist/ltcai-4.1.0.tar.gz`
|
|
33
|
+
- `dist/ltcai-4.1.0.vsix`
|
|
34
|
+
- `ltcai-4.1.0.tgz`
|
|
35
|
+
- `src-tauri/target/release/bundle/macos/Lattice AI.app`
|
|
36
|
+
- `src-tauri/target/release/bundle/dmg/Lattice AI_4.1.0_aarch64.dmg`
|
|
37
|
+
|
|
38
|
+
## Notes
|
|
39
|
+
|
|
40
|
+
- Vite reports one large initial bundle warning after minification. The app
|
|
41
|
+
remains fully local/offline and passes visual/offline startup validation.
|
|
42
|
+
- `cargo check` reports a future-incompatibility warning in transitive
|
|
43
|
+
`block v0.1.6`; the current Tauri 2.0 build passes on Rust 1.96.
|
|
44
|
+
- Release artifact validation warns that historical artifacts remain in
|
|
45
|
+
`dist/`; this is expected and reinforces the rule to upload only exact
|
|
46
|
+
v4.1.0 filenames, never `dist/*`.
|
|
47
|
+
- No external registry publish was performed.
|