@krishivpb60/aether-ai-cli 1.3.4 → 1.3.6
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/HIGHLIGHTS.md +13 -0
- package/package.json +1 -1
- package/src/ai/telemetry.js +56 -3
- package/src/chat.js +2184 -1692
- package/src/cli.js +31 -0
- package/src/dashboard.js +112 -0
- package/src/telemetry-server.js +855 -0
- package/src/ui/dashboard.html +834 -0
- package/test/autopilot-debug.test.js +91 -0
- package/test/git-tui.test.js +94 -0
- package/test/telemetry.test.js +104 -0
package/HIGHLIGHTS.md
CHANGED
|
@@ -1,3 +1,16 @@
|
|
|
1
|
+
# Aether CLI v1.3.6 Highlights
|
|
2
|
+
- **DX Fixes & Upgrades (Git TUI, Autopilot, Dashboard)**:
|
|
3
|
+
- Fixes non-interactive Git TUI test hangs in git-initialized home directories.
|
|
4
|
+
- Fixes visual HUD telemetry version rendering.
|
|
5
|
+
- Updates project package-lock mappings.
|
|
6
|
+
|
|
7
|
+
# Aether CLI v1.3.5 Highlights
|
|
8
|
+
- **Visual Telemetry Dashboard HUD (`aether dashboard` / `aether telemetry`)**:
|
|
9
|
+
- Adds a local zero-dependency Web Server hosting a cyberpunk observability dashboard HUD.
|
|
10
|
+
- Displays real-time request latencies, query success rates, model token distributions, and active failover mesh topologies.
|
|
11
|
+
- Persistent storage preserves historical metrics across CLI executions in `~/.aether/telemetry.json`.
|
|
12
|
+
- Offline-compatible custom SVG chart engine allows telemetry visualization without an internet connection.
|
|
13
|
+
|
|
1
14
|
# Aether CLI v1.3.4 Highlights
|
|
2
15
|
- **AI-Powered Workspace Search & Code Indexer (`/search`)**:
|
|
3
16
|
- Adds `/search <query>` slash command to scan all workspace text files for keyword matches, showing line numbers and code snippets.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@krishivpb60/aether-ai-cli",
|
|
3
|
-
"version": "1.3.
|
|
3
|
+
"version": "1.3.6",
|
|
4
4
|
"description": "Aether Core AI — A cyberpunk command-line AI assistant with multi-mode reasoning, 12-node failover mesh, file context injection, and offline fallbacks.",
|
|
5
5
|
"main": "src/cli.js",
|
|
6
6
|
"bin": {
|
package/src/ai/telemetry.js
CHANGED
|
@@ -3,11 +3,48 @@
|
|
|
3
3
|
// Logs request latencies, prompt speeds, and meshes provider logs.
|
|
4
4
|
// ═══════════════════════════════════════════════════════════
|
|
5
5
|
|
|
6
|
+
import { readFileSync, writeFileSync, existsSync, mkdirSync, unlinkSync } from "node:fs";
|
|
7
|
+
import { join } from "node:path";
|
|
8
|
+
import { homedir } from "node:os";
|
|
6
9
|
import { getSessionTokenStats, getBreakdownByModel } from "./tokens.js";
|
|
7
10
|
import { getActiveProviders, PROVIDERS } from "./providers.js";
|
|
8
11
|
import { listSessions } from "../config.js";
|
|
9
12
|
|
|
10
|
-
const
|
|
13
|
+
const CONFIG_DIR = join(homedir(), ".aether");
|
|
14
|
+
const TELEMETRY_FILE = join(CONFIG_DIR, "telemetry.json");
|
|
15
|
+
|
|
16
|
+
/**
|
|
17
|
+
* Loads telemetry logs from disk.
|
|
18
|
+
* @returns {Array}
|
|
19
|
+
*/
|
|
20
|
+
function loadTelemetryFromDisk() {
|
|
21
|
+
try {
|
|
22
|
+
if (existsSync(TELEMETRY_FILE)) {
|
|
23
|
+
const raw = readFileSync(TELEMETRY_FILE, "utf-8");
|
|
24
|
+
return JSON.parse(raw);
|
|
25
|
+
}
|
|
26
|
+
} catch {
|
|
27
|
+
// ignore
|
|
28
|
+
}
|
|
29
|
+
return [];
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
/**
|
|
33
|
+
* Saves telemetry logs to disk.
|
|
34
|
+
* @param {Array} logs
|
|
35
|
+
*/
|
|
36
|
+
function saveTelemetryToDisk(logs) {
|
|
37
|
+
try {
|
|
38
|
+
if (!existsSync(CONFIG_DIR)) {
|
|
39
|
+
mkdirSync(CONFIG_DIR, { recursive: true });
|
|
40
|
+
}
|
|
41
|
+
writeFileSync(TELEMETRY_FILE, JSON.stringify(logs, null, 2), "utf-8");
|
|
42
|
+
} catch {
|
|
43
|
+
// ignore
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
const latencyLogs = loadTelemetryFromDisk();
|
|
11
48
|
|
|
12
49
|
/**
|
|
13
50
|
* Records telemetry metrics for an AI call.
|
|
@@ -29,10 +66,12 @@ export function recordLatency(provider, model, latencyMs, promptTokens, completi
|
|
|
29
66
|
success: !!success,
|
|
30
67
|
});
|
|
31
68
|
|
|
32
|
-
// Limit to last
|
|
33
|
-
if (latencyLogs.length >
|
|
69
|
+
// Limit to last 100 entries for historical visualization
|
|
70
|
+
if (latencyLogs.length > 100) {
|
|
34
71
|
latencyLogs.shift();
|
|
35
72
|
}
|
|
73
|
+
|
|
74
|
+
saveTelemetryToDisk(latencyLogs);
|
|
36
75
|
}
|
|
37
76
|
|
|
38
77
|
/**
|
|
@@ -43,6 +82,20 @@ export function getLatencyLogs() {
|
|
|
43
82
|
return latencyLogs;
|
|
44
83
|
}
|
|
45
84
|
|
|
85
|
+
/**
|
|
86
|
+
* Clears all telemetry logs.
|
|
87
|
+
*/
|
|
88
|
+
export function clearTelemetryLogs() {
|
|
89
|
+
latencyLogs.length = 0;
|
|
90
|
+
try {
|
|
91
|
+
if (existsSync(TELEMETRY_FILE)) {
|
|
92
|
+
unlinkSync(TELEMETRY_FILE);
|
|
93
|
+
}
|
|
94
|
+
} catch {
|
|
95
|
+
// ignore
|
|
96
|
+
}
|
|
97
|
+
}
|
|
98
|
+
|
|
46
99
|
/**
|
|
47
100
|
* Gathers all metrics needed for the web dashboard visualization.
|
|
48
101
|
* @param {object} config - Aether configuration object
|