@cryptiklemur/lattice 1.44.0 → 1.44.2
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/client/src/router.tsx
CHANGED
|
@@ -511,8 +511,6 @@ function IndexPage() {
|
|
|
511
511
|
content = <SettingsView />;
|
|
512
512
|
} else if (viewName === "project-settings") {
|
|
513
513
|
content = <ProjectSettingsView />;
|
|
514
|
-
} else if (hasWorkspaceTab) {
|
|
515
|
-
content = <WorkspaceView />;
|
|
516
514
|
} else if (viewName === "dashboard") {
|
|
517
515
|
content = <DashboardView />;
|
|
518
516
|
} else if (viewName === "project-dashboard") {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cryptiklemur/lattice",
|
|
3
|
-
"version": "1.44.
|
|
3
|
+
"version": "1.44.2",
|
|
4
4
|
"description": "Multi-machine agentic dashboard for Claude Code. Monitor sessions, manage MCP servers and skills, orchestrate across mesh-networked nodes.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "Aaron Scherer <me@aaronscherer.me>",
|
package/server/src/daemon.ts
CHANGED
|
@@ -321,6 +321,16 @@ export async function startDaemon(portOverride?: number | null): Promise<void> {
|
|
|
321
321
|
addClient(ws);
|
|
322
322
|
log.ws("Client connected: %s", ws.data.id);
|
|
323
323
|
sendTo(ws.data.id, { type: "mesh:nodes", nodes: buildNodesMessage() });
|
|
324
|
+
var connectConfig = loadConfig();
|
|
325
|
+
var connectIdentity = loadOrCreateIdentity();
|
|
326
|
+
var localProjects = connectConfig.projects.map(function (p: typeof connectConfig.projects[number]) {
|
|
327
|
+
return { slug: p.slug, path: p.path, title: p.title, nodeId: connectIdentity.id, nodeName: connectConfig.name, isRemote: false, ideProjectName: detectIdeProjectName(p.path), activeSessions: getActiveSessionCountForProject(p.path) };
|
|
328
|
+
});
|
|
329
|
+
var connectRemoteProjects = getAllRemoteProjects(connectIdentity.id);
|
|
330
|
+
sendTo(ws.data.id, {
|
|
331
|
+
type: "projects:list",
|
|
332
|
+
projects: localProjects.concat(connectRemoteProjects as unknown as typeof localProjects),
|
|
333
|
+
});
|
|
324
334
|
},
|
|
325
335
|
message(ws: ServerWebSocket<WsData>, message: string | Buffer) {
|
|
326
336
|
var now = Date.now();
|
|
@@ -189,9 +189,16 @@ export async function getContextBreakdown(projectSlug: string, sessionId: string
|
|
|
189
189
|
var instructionsTokens = countTokens(globalClaudeMd + globalRulesContent + projectClaudeMd + projectLocalClaudeMd);
|
|
190
190
|
var memoryTokens = countTokens(memoryContent + memoryIndex);
|
|
191
191
|
|
|
192
|
-
// Parse session
|
|
193
|
-
var
|
|
194
|
-
var
|
|
192
|
+
// Parse session — read last 2MB for recent context (avoids reading 35MB+ files)
|
|
193
|
+
var { openSync, readSync: fsReadSync, fstatSync: fsFstatSync, closeSync: fsCloseSync } = require("node:fs") as typeof import("node:fs");
|
|
194
|
+
var fd = openSync(sessionFile, "r");
|
|
195
|
+
var fileStat = fsFstatSync(fd);
|
|
196
|
+
var readSize = Math.min(fileStat.size, 2 * 1024 * 1024);
|
|
197
|
+
var readBuf = Buffer.alloc(readSize);
|
|
198
|
+
fsReadSync(fd, readBuf, 0, readSize, fileStat.size - readSize);
|
|
199
|
+
fsCloseSync(fd);
|
|
200
|
+
var content = readBuf.toString("utf-8");
|
|
201
|
+
var lines = content.split("\n").filter(function (l) { return l.length > 0; });
|
|
195
202
|
|
|
196
203
|
// Extract tool info
|
|
197
204
|
var toolCounts = extractToolsFromSession(lines);
|
|
@@ -294,8 +294,16 @@ export async function getSessionUsage(projectSlug: string, sessionId: string): P
|
|
|
294
294
|
if (!existsSync(sessionFile)) return null;
|
|
295
295
|
|
|
296
296
|
try {
|
|
297
|
-
var
|
|
298
|
-
var
|
|
297
|
+
var { openSync, readSync, fstatSync, closeSync } = require("node:fs") as typeof import("node:fs");
|
|
298
|
+
var fd = openSync(sessionFile, "r");
|
|
299
|
+
var stat = fstatSync(fd);
|
|
300
|
+
var tailSize = Math.min(stat.size, 512 * 1024);
|
|
301
|
+
var buf = Buffer.alloc(tailSize);
|
|
302
|
+
readSync(fd, buf, 0, tailSize, stat.size - tailSize);
|
|
303
|
+
closeSync(fd);
|
|
304
|
+
|
|
305
|
+
var text = buf.toString("utf-8");
|
|
306
|
+
var lines = text.split("\n");
|
|
299
307
|
|
|
300
308
|
for (var i = lines.length - 1; i >= 0; i--) {
|
|
301
309
|
var line = lines[i].trim();
|