@0perator/operator 0.1.60 → 0.1.62
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/CHANGELOG.md +25 -1
- package/dist/cli.js +21 -21
- package/dist/router/models.js +13 -4
- package/dist/session.js +1 -1
- package/dist/tools/registry.js +27 -4
- package/dist/ui/AuthScreen.js +1 -1
- package/dist/ui/Header.js +8 -2
- package/package.json +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,9 +1,33 @@
|
|
|
1
1
|
# Operator (kode-tsi) — Changelog
|
|
2
2
|
|
|
3
|
-
Operator is AXE's terminal coding agent (npm `@0perator/operator`), running on
|
|
3
|
+
Operator is AXE's terminal coding agent (npm `@0perator/operator`), running on AXE's local model.
|
|
4
4
|
Newest first. Every release bumps `src/cli.tsx` VERSION + `package.json`, adds an entry here, and ships to
|
|
5
5
|
npm + both git remotes (memjar/kode, axetechnologies/kode). Test counts are the full suite at that release.
|
|
6
6
|
|
|
7
|
+
## 0.1.62 — 2026-09-23
|
|
8
|
+
- **Naming: the internal model name is gone from every user-facing surface.** The only outward names are
|
|
9
|
+
"axe" / "Operator" / "0perator"; the internal model name never appears in anything a user sees.
|
|
10
|
+
- Renamed the user-facing model ids `aurora-1m` / `aurora-128k` → `operator-1m` / `operator-128k`
|
|
11
|
+
(labels "Operator 1M" / "Operator 128K"). The OLD ids are kept as working **aliases** (findModel
|
|
12
|
+
normalizes them), so a persisted `settings.activeModel: "aurora-1m"`, a `/model aurora-1m`, or any
|
|
13
|
+
muscle memory keeps resolving — the rename loses nothing.
|
|
14
|
+
- Swept the HELP text, boot masthead, status line, `/model` picker, sign-in copy, service/endpoint
|
|
15
|
+
labels, capacity/error messages, and the system prompt (so the model itself won't echo the name).
|
|
16
|
+
- Internal ids/vars/config, endpoint hostnames, and the served model name (`aurora-code-1`) are
|
|
17
|
+
untouched. Also cleaned kode-mobile + kode-web user-facing strings ("JL1" → "your Mac", etc.).
|
|
18
|
+
- Tests: 379/379 (incl. a new alias regression test proving the legacy `aurora-*` ids still resolve).
|
|
19
|
+
|
|
20
|
+
## 0.1.61 — 2026-09-22
|
|
21
|
+
- **Fix: search glob honored without ripgrep (CI red).** 's glob (e.g. "*.ts") is now enforced by a JS post-filter on the result lines (basename fnmatch) in BOTH the ripgrep and grep-fallback paths — grep's --include / rg's -g have platform-varying semantics (GNU grep on CI let "*.ts" through), so the tool no longer trusts the flag alone. Fixes the 0.1.60 CI failure (ubuntu has no rg → grep fallback). Verified on the grep path with rg hidden.
|
|
22
|
+
- Tests: 379/379 (search glob now green on the no-rg path).
|
|
23
|
+
|
|
24
|
+
## 0.1.61 — 2026-09-22
|
|
25
|
+
- **Fix: `search` glob honored without ripgrep (CI red on 0.1.60).** The glob (e.g. "*.ts") is now enforced
|
|
26
|
+
by a JS post-filter over the result lines (basename fnmatch) in BOTH the ripgrep and grep-fallback paths.
|
|
27
|
+
grep's `--include` and rg's `-g` have platform-varying semantics — GNU grep on CI (ubuntu, no rg) let
|
|
28
|
+
"*.ts" through — so the tool no longer trusts the underlying flag alone. Verified on the grep path with rg
|
|
29
|
+
hidden. Tests: 379/379.
|
|
30
|
+
|
|
7
31
|
## 0.1.60 — 2026-09-22
|
|
8
32
|
- **`http_request` tool (capability #5).** A real HTTP client beyond `web_fetch`'s GET-and-scrape: any method
|
|
9
33
|
(GET/POST/PUT/PATCH/DELETE/HEAD), custom headers, a JSON (`json`) or raw (`body`) payload, bearer/basic auth,
|
package/dist/cli.js
CHANGED
|
@@ -24,7 +24,7 @@ import { homedir, hostname } from "node:os";
|
|
|
24
24
|
import { createHash } from "node:crypto";
|
|
25
25
|
// RELEASE CHECKLIST (every bump): update this + package.json "version", ADD A CHANGELOG.md ENTRY
|
|
26
26
|
// (improvements / fixes / tests), run the suite, then publish to npm + push both remotes.
|
|
27
|
-
const VERSION = "0.1.
|
|
27
|
+
const VERSION = "0.1.62";
|
|
28
28
|
// operator/settings.json (override path via KODE_TSI_SETTINGS), env vars still win — see config/settings.ts.
|
|
29
29
|
const settings = loadSettings();
|
|
30
30
|
// Propagate the resolved sandbox mode to the tool layer (registry reads KODE_SANDBOX at exec time).
|
|
@@ -145,7 +145,7 @@ const emitTelemetry = settings.telemetry.enabled !== false;
|
|
|
145
145
|
// and `operator+` serve the same single tier (the air/1m/saddle roster collapsed once Aurora ran true
|
|
146
146
|
// 1,048,576-token context at full speed). No size-based routing decision remains.
|
|
147
147
|
function buildRouter() {
|
|
148
|
-
const aurora = { name: "
|
|
148
|
+
const aurora = { name: "operator-1m", base: settings.endpoints.aurora.base, model: settings.endpoints.aurora.model, ctxLimit: settings.endpoints.aurora.ctxWindow };
|
|
149
149
|
// Primary first; the optional failover is only reached via the router's health-gated recover() when
|
|
150
150
|
// the primary errors (routeBySize always picks aurora at index 0 since 1M fits every prompt).
|
|
151
151
|
const eps = [aurora];
|
|
@@ -215,13 +215,13 @@ const EMBODIMENT_GUIDE = settings.computer.enabled
|
|
|
215
215
|
`hand-write osascript to scrape a GUI — it will error on Electron apps.`)
|
|
216
216
|
: "";
|
|
217
217
|
const SYSTEM_PROMPT = (settings.systemPrompt ??
|
|
218
|
-
`You are Operator, AXE's terminal coding agent — built by AXE, running on AXE's
|
|
218
|
+
`You are Operator, AXE's terminal coding agent — built by AXE, running on AXE's own model. Refer to ` +
|
|
219
219
|
`yourself as Operator and to the platform as AXE; never call yourself or the platform Claude, ` +
|
|
220
220
|
`Anthropic, or any other vendor. When you encounter files or directories on disk named "claude", ` +
|
|
221
221
|
`".claude", "anthropic", etc., describe them neutrally (by their literal path, or as "AI tooling ` +
|
|
222
222
|
`files") — do not attribute them to a vendor. Use your tools to inspect and edit the ` +
|
|
223
223
|
`workspace; prefer doing over explaining. Answer concisely.\n## This machine\nWorking dir: ${process.cwd()}` +
|
|
224
|
-
`\nContext window: 1,048,576 tokens (1M) — you run on
|
|
224
|
+
`\nContext window: 1,048,576 tokens (1M) — you run on AXE's model served locally with a full ` +
|
|
225
225
|
`1M-token context. You can hold very large files and long histories; do not claim a smaller limit.` +
|
|
226
226
|
`\n## Parallel tool calls\nWhen the next few steps are INDEPENDENT of each other — reading several ` +
|
|
227
227
|
`files, running several greps/checks, inspecting multiple unrelated things — issue them as multiple ` +
|
|
@@ -231,7 +231,7 @@ const SYSTEM_PROMPT = (settings.systemPrompt ??
|
|
|
231
231
|
`almost always faster and is the default you should reach for; do not artificially serialize work ` +
|
|
232
232
|
`that has no real dependency.` +
|
|
233
233
|
`\n## Sub-agents\nFor independent, parallelizable subtasks (search a large tree, draft a file, a long ` +
|
|
234
|
-
`build) call spawn_agent with a fully self-contained instruction — it runs on another
|
|
234
|
+
`build) call spawn_agent with a fully self-contained instruction — it runs on another session ` +
|
|
235
235
|
`in parallel and posts its result back here; keep working meanwhile. The user watches each sub-agent's ` +
|
|
236
236
|
`live tokens + time in the background panel. Don't delegate trivial work you can do inline, and don't ` +
|
|
237
237
|
`spawn many at once — they all share this one model.` +
|
|
@@ -256,14 +256,14 @@ const MAX_BG = 4; // concurrent background sub-agents — all share the single A
|
|
|
256
256
|
const HELP = [
|
|
257
257
|
"commands:",
|
|
258
258
|
" /help this list",
|
|
259
|
-
" /model [id] pick a model:
|
|
260
|
-
" /endpoints show the
|
|
261
|
-
" /services ensure/inspect the service lever (
|
|
259
|
+
" /model [id] pick a model: operator-1m · operator-128k · moa (mixture-of-agents)",
|
|
260
|
+
" /endpoints show the Operator endpoint + live health",
|
|
261
|
+
" /services ensure/inspect the service lever (Operator+autopilot+searxng); /services stop",
|
|
262
262
|
" /audit [n] recent tool + control-plane events from the audit trail (default 15)",
|
|
263
263
|
" /dashboard launch the live swarm console (watches every Operator session)",
|
|
264
264
|
" /plan plan mode: read-only research + propose a plan (/plan again to execute)",
|
|
265
265
|
" /mode [plan|manual|auto] set operating mode (plan · manual · autonomous); also Shift+Tab to cycle",
|
|
266
|
-
" /think extended reasoning:
|
|
266
|
+
" /think extended reasoning: Operator thinks before answering (/think again = off)",
|
|
267
267
|
" /ultrathink deep, exhaustive reasoning for hard problems (/ultrathink again = off)",
|
|
268
268
|
" /compact force-compact the conversation now",
|
|
269
269
|
" /remember <note> store a note to recall in future sessions",
|
|
@@ -287,10 +287,10 @@ const HELP = [
|
|
|
287
287
|
// everything below still runs with the same local privilege a `prompt` frame already has today.
|
|
288
288
|
const REMOTE_SAFE_COMMANDS = [
|
|
289
289
|
{ name: "help", description: "list available commands" },
|
|
290
|
-
{ name: "model", description: "pick a model:
|
|
290
|
+
{ name: "model", description: "pick a model: operator-1m · operator-128k · moa (mixture-of-agents)", args: "[id]" },
|
|
291
291
|
{ name: "route", description: "pin routing to an endpoint, or auto (by size)", args: "[endpoint|auto]" },
|
|
292
|
-
{ name: "endpoints", description: "show the
|
|
293
|
-
{ name: "services", description: "ensure/inspect the service lever (
|
|
292
|
+
{ name: "endpoints", description: "show the Operator endpoint + live health" },
|
|
293
|
+
{ name: "services", description: "ensure/inspect the service lever (Operator+autopilot+searxng); stop searxng", args: "[stop]" },
|
|
294
294
|
{ name: "audit", description: "recent tool + control-plane events from the audit trail", args: "[n]" },
|
|
295
295
|
{ name: "dashboard", description: "launch the live swarm console" },
|
|
296
296
|
{ name: "plan", description: "toggle plan mode (read-only research + propose a plan)" },
|
|
@@ -326,7 +326,7 @@ function Root() {
|
|
|
326
326
|
const [liveTools, setLiveTools] = useState([]); // one row per call in the CURRENT batch,
|
|
327
327
|
// live: seeded "running" by onToolStart, each flips to done/error independently as onToolResult fires
|
|
328
328
|
// for it — see ui/liveTools.ts. Cleared once the batch settles (onToolBatch).
|
|
329
|
-
const [route, setRoute] = useState("
|
|
329
|
+
const [route, setRoute] = useState("operator-1m");
|
|
330
330
|
const [ctxPct, setCtxPct] = useState(0);
|
|
331
331
|
const [metrics, setMetrics] = useState(""); // last turn's "N tok · X tok/s · Ys" for the status rule
|
|
332
332
|
const [liveTok, setLiveTok] = useState(0); // live output-token count for the CURRENT turn — animates the
|
|
@@ -425,7 +425,7 @@ function Root() {
|
|
|
425
425
|
if (!mgr)
|
|
426
426
|
return "background manager not ready yet — retry in a moment";
|
|
427
427
|
if (mgr.activeCount() >= MAX_BG)
|
|
428
|
-
return `at capacity: ${MAX_BG} sub-agents already running on the single
|
|
428
|
+
return `at capacity: ${MAX_BG} sub-agents already running on the single Operator 1M endpoint — wait for one to finish (see the background panel) before spawning more`;
|
|
429
429
|
const id = mgr.spawn(task);
|
|
430
430
|
return `spawned background sub-agent ${id} — it posts its result here when done. Keep working; watch its live tokens + time in the background panel.`;
|
|
431
431
|
},
|
|
@@ -439,7 +439,7 @@ function Root() {
|
|
|
439
439
|
bgRef.current = new BackgroundAgents(() => new Session({
|
|
440
440
|
systemPrompt: SYSTEM_PROMPT,
|
|
441
441
|
router: new AuroraRouter([
|
|
442
|
-
{ name: "
|
|
442
|
+
{ name: "operator-1m", base: settings.endpoints.aurora.base, model: settings.endpoints.aurora.model, ctxLimit: settings.endpoints.aurora.ctxWindow },
|
|
443
443
|
]),
|
|
444
444
|
maxTokens: settings.maxTokens,
|
|
445
445
|
temperature: settings.temperature,
|
|
@@ -902,7 +902,7 @@ function Root() {
|
|
|
902
902
|
const on = s.currentThinkMode() !== "think";
|
|
903
903
|
s.setThinkMode(on ? "think" : "off");
|
|
904
904
|
setThinkMode(on ? "think" : "off");
|
|
905
|
-
sys(on ? "✲ think ON —
|
|
905
|
+
sys(on ? "✲ think ON — Operator reasons (shown dimmed) before answering. /think again to turn off."
|
|
906
906
|
: "think off — back to fast direct answers.");
|
|
907
907
|
break;
|
|
908
908
|
}
|
|
@@ -910,7 +910,7 @@ function Root() {
|
|
|
910
910
|
const on = s.currentThinkMode() !== "ultrathink";
|
|
911
911
|
s.setThinkMode(on ? "ultrathink" : "off");
|
|
912
912
|
setThinkMode(on ? "ultrathink" : "off");
|
|
913
|
-
sys(on ? "✲✲ ultrathink ON —
|
|
913
|
+
sys(on ? "✲✲ ultrathink ON — Operator reasons deeply + exhaustively before answering (slower, deeper). /ultrathink again to turn off."
|
|
914
914
|
: "ultrathink off — back to fast direct answers.");
|
|
915
915
|
break;
|
|
916
916
|
}
|
|
@@ -983,7 +983,7 @@ function Root() {
|
|
|
983
983
|
if (arg === "stop") {
|
|
984
984
|
const { stopSessionServices } = await import("./services/preflight.js");
|
|
985
985
|
await stopSessionServices({ searxng: true });
|
|
986
|
-
sys("stopped session-scoped services (SearXNG).
|
|
986
|
+
sys("stopped session-scoped services (SearXNG). Operator + autopilot are shared and stay up.");
|
|
987
987
|
break;
|
|
988
988
|
}
|
|
989
989
|
sys("checking services…");
|
|
@@ -1115,9 +1115,9 @@ function Root() {
|
|
|
1115
1115
|
return () => clearInterval(id);
|
|
1116
1116
|
}, [status]);
|
|
1117
1117
|
if (boot === "checking")
|
|
1118
|
-
return _jsx(Text, { dimColor: true, children: bootDetail || "connecting to
|
|
1118
|
+
return _jsx(Text, { dimColor: true, children: bootDetail || "connecting to Operator…" });
|
|
1119
1119
|
if (boot === "down") {
|
|
1120
|
-
return (_jsxs(Box, { flexDirection: "column", children: [_jsx(Text, { color: "red", children: "Can't reach
|
|
1120
|
+
return (_jsxs(Box, { flexDirection: "column", children: [_jsx(Text, { color: "red", children: "Can't reach Operator on the configured endpoint." }), bootDetail ? _jsx(Text, { dimColor: true, children: bootDetail }) : null, _jsx(Text, { dimColor: true, children: "The Operator model is launchd-owned. Recover it with: launchctl kickstart -k gui/$(id -u)/com.imi.aurora-serve" })] }));
|
|
1121
1121
|
}
|
|
1122
1122
|
// While a turn runs, show a LIVE line: braille spinner + climbing token count + live tok/s + elapsed
|
|
1123
1123
|
// seconds. When idle, show the last turn's final "N tok · X tok/s · Ys". Never freeze on the previous
|
|
@@ -1158,5 +1158,5 @@ if (!process.stdin.isTTY) {
|
|
|
1158
1158
|
}
|
|
1159
1159
|
// Boot masthead (design #29) — printed ONCE to stdout before Ink mounts, so the big gradient wordmark
|
|
1160
1160
|
// lives in permanent scrollback and never enters Ink's dynamic-frame redraw (reflow-safe by construction).
|
|
1161
|
-
process.stdout.write(mastheadLines(`
|
|
1161
|
+
process.stdout.write(mastheadLines(`Operator · 1M · v${VERSION}`).join("\n") + "\n");
|
|
1162
1162
|
render(_jsx(Root, {}));
|
package/dist/router/models.js
CHANGED
|
@@ -1,7 +1,15 @@
|
|
|
1
|
-
export const DEFAULT_MODEL_ID = "
|
|
1
|
+
export const DEFAULT_MODEL_ID = "operator-1m";
|
|
2
|
+
// Back-compat aliases: the user-facing ids were renamed aurora-* -> operator-* (the outward name is
|
|
3
|
+
// Operator; "aurora" is the internal model, never shown). The OLD ids still resolve — a persisted
|
|
4
|
+
// settings.activeModel: "aurora-1m", a `/model aurora-1m`, or any muscle memory keeps working — so the
|
|
5
|
+
// rename loses nothing. The served model name ("aurora-code-1") + endpoints stay internal, untouched.
|
|
6
|
+
export const MODEL_ALIASES = {
|
|
7
|
+
"aurora-1m": "operator-1m",
|
|
8
|
+
"aurora-128k": "operator-128k",
|
|
9
|
+
};
|
|
2
10
|
export const BUILTIN_MODELS = [
|
|
3
|
-
{ id: "
|
|
4
|
-
{ id: "
|
|
11
|
+
{ id: "operator-1m", label: "Operator 1M", kind: "single", desc: "1,048,576-token context (:8097)", endpoint: "http://127.0.0.1:8097/v1", model: "aurora-code-1", ctx: 1048576 },
|
|
12
|
+
{ id: "operator-128k", label: "Operator 128K", kind: "single", desc: "128K context, lighter RAM (:8096)", endpoint: "http://127.0.0.1:8096/v1", model: "aurora-code-1", ctx: 131072 },
|
|
5
13
|
{ id: "moa", label: "MOA (Mixture of Agents)", kind: "orchestrated", desc: "fan out to proposers, synthesize with an aggregator" },
|
|
6
14
|
];
|
|
7
15
|
/** The runtime registry: the built-ins, with any settings.models entries merged in (overriding a
|
|
@@ -15,7 +23,8 @@ export function modelRegistry(overrides) {
|
|
|
15
23
|
return [...byId.values()];
|
|
16
24
|
}
|
|
17
25
|
export function findModel(registry, id) {
|
|
18
|
-
|
|
26
|
+
const canon = MODEL_ALIASES[id] ?? id; // aurora-1m -> operator-1m (old ids keep resolving)
|
|
27
|
+
return registry.find((m) => m.id === canon);
|
|
19
28
|
}
|
|
20
29
|
/** Pure selection reducer for /model — no I/O (no settings read/write, no router mutation), so it's
|
|
21
30
|
* directly testable. The moa-needs-config check lives in Session.setModel (it needs settings.moa,
|
package/dist/session.js
CHANGED
|
@@ -410,7 +410,7 @@ export class Session {
|
|
|
410
410
|
if (!survivors.length) {
|
|
411
411
|
h.onRoute?.(active.id, this.ctxPct());
|
|
412
412
|
this.modelId = DEFAULT_MODEL_ID; // fall back for this and future turns until /model moa retries
|
|
413
|
-
const note = "MOA: every proposer failed or timed out — falling back to
|
|
413
|
+
const note = "MOA: every proposer failed or timed out — falling back to operator-1m for this reply.\n\n";
|
|
414
414
|
h.onDelta?.(note);
|
|
415
415
|
const res = await this.execute(text, h, this.router, this.sysWithThink());
|
|
416
416
|
return { ...res, content: note + res.content };
|
package/dist/tools/registry.js
CHANGED
|
@@ -243,6 +243,27 @@ function capMatches(stdout) {
|
|
|
243
243
|
out += `\n…[${lines.length - GREP_MAXLINES} more matching lines — narrow the pattern or pass a path/glob]`;
|
|
244
244
|
return out;
|
|
245
245
|
}
|
|
246
|
+
// A tiny fnmatch over a filename: `*` → any run, `?` → one char. Used to POST-FILTER search results by
|
|
247
|
+
// `glob` in JS so the filter is honored regardless of the underlying tool: ripgrep's -g and grep's
|
|
248
|
+
// --include have different (and platform-varying) semantics — notably GNU grep on CI let "*.ts" through —
|
|
249
|
+
// so we never trust the tool's flag alone.
|
|
250
|
+
function globToRegExp(glob) {
|
|
251
|
+
const re = glob.replace(/[.+^${}()|[\]\\]/g, "\\$&").replace(/\*/g, ".*").replace(/\?/g, ".");
|
|
252
|
+
return new RegExp(`^${re}$`);
|
|
253
|
+
}
|
|
254
|
+
function filterLinesByGlob(stdout, glob) {
|
|
255
|
+
if (!glob)
|
|
256
|
+
return stdout;
|
|
257
|
+
const re = globToRegExp(glob);
|
|
258
|
+
return stdout.split("\n").filter((line) => {
|
|
259
|
+
if (!line.trim())
|
|
260
|
+
return false;
|
|
261
|
+
// content line "path:lineno:…" or files-only "path"; the file path is up to the first ":".
|
|
262
|
+
const p = line.includes(":") ? line.slice(0, line.indexOf(":")) : line;
|
|
263
|
+
const base = p.split("/").pop() ?? p;
|
|
264
|
+
return re.test(base);
|
|
265
|
+
}).join("\n");
|
|
266
|
+
}
|
|
246
267
|
// Fast search backed by ripgrep — parallel, .gitignore-aware, skips binaries/hidden files, so it stays
|
|
247
268
|
// scoped and quick instead of `find ~/ | grep | grep` over the whole home tree. Falls back to grep with
|
|
248
269
|
// the SAME scoping + caps when rg isn't installed, so the tool always works. `files_with_matches` returns
|
|
@@ -254,6 +275,8 @@ async function ripgrepSearch(args) {
|
|
|
254
275
|
return "error: no pattern given";
|
|
255
276
|
const filesOnly = !!args.files_with_matches;
|
|
256
277
|
const glob = args.glob ? str(args.glob) : "";
|
|
278
|
+
// Belt-and-suspenders over rg -g / grep --include: always JS-filter the output by the glob too.
|
|
279
|
+
const capG = (s) => capMatches(filterLinesByGlob(s, glob));
|
|
257
280
|
const grepFallback = async () => {
|
|
258
281
|
// rg absent — same intent via grep: recursive, skip .git/node_modules, honor glob + files-only.
|
|
259
282
|
const gflags = ["-rns", "-I", "--exclude-dir=.git", "--exclude-dir=node_modules", "--exclude=.operator-session.json"];
|
|
@@ -263,11 +286,11 @@ async function ripgrepSearch(args) {
|
|
|
263
286
|
gflags.push(`--include=${glob}`);
|
|
264
287
|
try {
|
|
265
288
|
const { stdout } = await pexecFile("grep", [...gflags, "-E", pattern, path], { maxBuffer: 10 * 1024 * 1024, timeout: 20_000, killSignal: "SIGKILL" });
|
|
266
|
-
return
|
|
289
|
+
return capG(stdout);
|
|
267
290
|
}
|
|
268
291
|
catch (ge) {
|
|
269
292
|
if (ge.stdout && String(ge.stdout).trim())
|
|
270
|
-
return
|
|
293
|
+
return capG(String(ge.stdout));
|
|
271
294
|
if (ge.code === 1)
|
|
272
295
|
return "(no matches)";
|
|
273
296
|
if (ge.killed)
|
|
@@ -282,13 +305,13 @@ async function ripgrepSearch(args) {
|
|
|
282
305
|
rgArgs.push("-e", pattern, path);
|
|
283
306
|
try {
|
|
284
307
|
const { stdout } = await pexecFile("rg", rgArgs, { maxBuffer: 10 * 1024 * 1024, timeout: 20_000, killSignal: "SIGKILL" });
|
|
285
|
-
return
|
|
308
|
+
return capG(stdout);
|
|
286
309
|
}
|
|
287
310
|
catch (e) {
|
|
288
311
|
if (e.code === "ENOENT")
|
|
289
312
|
return grepFallback(); // ripgrep not installed → grep
|
|
290
313
|
if (e.stdout && String(e.stdout).trim())
|
|
291
|
-
return
|
|
314
|
+
return capG(String(e.stdout));
|
|
292
315
|
if (e.code === 1)
|
|
293
316
|
return "(no matches)";
|
|
294
317
|
if (e.killed)
|
package/dist/ui/AuthScreen.js
CHANGED
|
@@ -13,5 +13,5 @@ export function AuthScreen({ version, ctxWindow, authBase, pending, error, onCho
|
|
|
13
13
|
else if (key.return || c === "g")
|
|
14
14
|
onChoice("guest");
|
|
15
15
|
});
|
|
16
|
-
return (_jsxs(Box, { flexDirection: "column", children: [_jsx(Masthead, { info: `
|
|
16
|
+
return (_jsxs(Box, { flexDirection: "column", children: [_jsx(Masthead, { info: `Operator${ctxWindow && ctxWindow >= 1_000_000 ? " · 1M" : ""} · v${version}` }), _jsx(Box, { marginTop: 1, flexDirection: "column", paddingLeft: 1, children: pending ? (_jsxs(_Fragment, { children: [_jsxs(Text, { children: ["Signing in \u2014 open ", _jsx(Text, { color: "cyanBright", children: pending.url })] }), _jsxs(Text, { children: ["and enter code ", _jsx(Text, { bold: true, color: "whiteBright", children: pending.userCode })] }), _jsx(Text, { dimColor: true, children: "Waiting for approval in your browser\u2026 (Esc to cancel)" })] })) : (_jsxs(_Fragment, { children: [_jsx(Text, { color: "whiteBright", children: "Welcome to Operator." }), _jsx(Text, { dimColor: true, children: "A local terminal coding agent on your own model." }), _jsxs(Box, { marginTop: 1, flexDirection: "column", children: [_jsxs(Text, { children: [_jsx(Text, { color: "magentaBright", bold: true, children: " s" }), " Sign in ", _jsx(Text, { dimColor: true, children: "\u2014 connect your account (browser approval)" })] }), _jsxs(Text, { children: [_jsx(Text, { color: "magentaBright", bold: true, children: " u" }), " Create account ", _jsxs(Text, { dimColor: true, children: ["\u2014 register at ", authBase.replace(/^https?:\/\//, "")] })] }), _jsxs(Text, { children: [_jsx(Text, { color: "magentaBright", bold: true, children: " \u21B5" }), " Continue as guest ", _jsx(Text, { dimColor: true, children: "\u2014 no account needed; sign in later with /login" })] })] }), error ? _jsx(Box, { marginTop: 1, children: _jsx(Text, { color: "red", children: error }) }) : null] })) })] }));
|
|
17
17
|
}
|
package/dist/ui/Header.js
CHANGED
|
@@ -10,10 +10,16 @@ function tierLabel(ctx) {
|
|
|
10
10
|
return `${Math.round(ctx / 1000)}K`;
|
|
11
11
|
return String(ctx);
|
|
12
12
|
}
|
|
13
|
-
|
|
13
|
+
// The status line shows the OUTWARD name only: the internal model ids (operator-1m, or the legacy
|
|
14
|
+
// aurora-* alias) collapse to "Operator" — the tier (· 1M) is appended separately below, so
|
|
15
|
+
// "operator-1m" would just be redundant. MOA and any custom /model id pass through unchanged.
|
|
16
|
+
function prettyRoute(r) {
|
|
17
|
+
return /^(operator|aurora)(-|$)/i.test(r) ? "Operator" : r;
|
|
18
|
+
}
|
|
19
|
+
export function Header({ version, route = "operator", ctxWindow, user, build }) {
|
|
14
20
|
const cols = process.stdout.columns ?? 80;
|
|
15
21
|
const tier = tierLabel(ctxWindow);
|
|
16
|
-
const model = `${route}${tier ? ` · ${tier}` : ""}`; //
|
|
22
|
+
const model = `${prettyRoute(route)}${tier ? ` · ${tier}` : ""}`; // Operator · 1M
|
|
17
23
|
const who = user ? `⬤ ${user}` : "guest"; // ⬤ email | guest
|
|
18
24
|
const left = ` ${STAR} OPERATOR`;
|
|
19
25
|
const right = `${model} · v${version}${build ? ` ·${build}` : ""} · ${who} `;
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@0perator/operator",
|
|
3
|
-
"version": "0.1.
|
|
4
|
-
"description": "Operator (KODE)
|
|
3
|
+
"version": "0.1.62",
|
|
4
|
+
"description": "Operator (KODE) \u2014 TypeScript + Ink terminal coding agent. Full-frame render, single-engine core shared across CLI/web/mobile; runs against a local Aurora model.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
7
7
|
"operator": "dist/cli.js",
|