@zergai/ztc 0.2.3-dev.35760740177 → 0.2.5-dev.36050717543
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 +7 -8
- package/dist/agent/backends/codex_auth.js +3 -0
- package/dist/agent/backends/types.d.ts +9 -0
- package/dist/agent/commands/debug.js +6 -4
- package/dist/agent/tools/adaptation.js +3 -3
- package/dist/web/mirror_stream.js +7 -3
- package/dist/zlm-embed.mjs +4 -1
- package/package.json +3 -3
package/README.md
CHANGED
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
An autonomous AI agent for the terminal. ZTC combines Claude-style conversational coding with native computer control, multi-agent orchestration, and a Voyager-inspired routine system for autonomous operation in graphical applications.
|
|
11
11
|
|
|
12
12
|
```
|
|
13
|
-
╭─ ZTC v0.2.0-canary.
|
|
13
|
+
╭─ ZTC v0.2.0-canary.2 ───────────────────────────────────────────────╮
|
|
14
14
|
│ Provider: Anthropic Model: claude-sonnet-4-20250514 │
|
|
15
15
|
│ Working directory: ~/projects/my-app Branch: main │
|
|
16
16
|
╰───────────────────────────────────────────────────────────────────╯
|
|
@@ -30,17 +30,16 @@ An autonomous AI agent for the terminal. ZTC combines Claude-style conversationa
|
|
|
30
30
|
|
|
31
31
|
## Quick Start
|
|
32
32
|
|
|
33
|
-
The ZergAI organization distribution is `@zergai/ztc
|
|
34
|
-
|
|
35
|
-
`npm install -g @zergai/ztc@next`. It provides the same `ztc` and `zerg` commands,
|
|
33
|
+
The ZergAI organization distribution is `@zergai/ztc` for the 0.2 canary.
|
|
34
|
+
Install it with `npm install -g @zergai/ztc`. It provides the same `ztc` and `zerg` commands,
|
|
36
35
|
license, and package exports; use `@zergai/ztc/<export>` for scoped imports.
|
|
37
36
|
Install only one distribution globally because the command names overlap.
|
|
38
|
-
Existing stable users can keep the legacy package below;
|
|
37
|
+
Existing stable users can keep the legacy package below; canary releases do not
|
|
39
38
|
move `zerg-ztc@latest` from the 0.1 line.
|
|
40
39
|
|
|
41
40
|
```bash
|
|
42
|
-
# Install the
|
|
43
|
-
npm install -g
|
|
41
|
+
# Install the 0.2 canary CLI
|
|
42
|
+
npm install -g @zergai/ztc
|
|
44
43
|
|
|
45
44
|
# Start with a read-only inspection of a real project
|
|
46
45
|
ztc --cwd /path/to/project --plan
|
|
@@ -112,7 +111,7 @@ npm start
|
|
|
112
111
|
- One authentication route: Zerg Router (`/auth login` or `ztc auth login`), provider API key (`/config key`), or Claude Code CLI OAuth (`claude setup-token` + `CLAUDE_CODE_OAUTH_TOKEN`)
|
|
113
112
|
|
|
114
113
|
The JS and headless surfaces support macOS, Linux, and Windows.
|
|
115
|
-
Native payload support for the `0.2.0-canary.
|
|
114
|
+
Native payload support for the `0.2.0-canary.2` npm prerelease is `darwin-arm64`
|
|
116
115
|
only (`aarch64-apple-darwin`). Interactive TUI, desktop, audio,
|
|
117
116
|
and computer-control binaries from this prerelease are supported only on Apple
|
|
118
117
|
Silicon macOS. Other platforms may use the JavaScript/headless APIs, but this
|
|
@@ -337,6 +337,9 @@ export class CodexAuthBackend {
|
|
|
337
337
|
stream: true,
|
|
338
338
|
store: false,
|
|
339
339
|
};
|
|
340
|
+
if (request.outputFormat !== undefined) {
|
|
341
|
+
body.text = { format: request.outputFormat };
|
|
342
|
+
}
|
|
340
343
|
if (tools.length > 0) {
|
|
341
344
|
body.tools = tools;
|
|
342
345
|
body.tool_choice = 'auto';
|
|
@@ -89,6 +89,15 @@ export interface BackendRequest {
|
|
|
89
89
|
system: string;
|
|
90
90
|
messages: LlmMessage[];
|
|
91
91
|
tools: ToolDefinition[];
|
|
92
|
+
/** Explicit Responses text format for Codex subscription inference callers. */
|
|
93
|
+
outputFormat?: {
|
|
94
|
+
type: 'text' | 'json_object';
|
|
95
|
+
} | {
|
|
96
|
+
type: 'json_schema';
|
|
97
|
+
name: string;
|
|
98
|
+
schema: Record<string, unknown>;
|
|
99
|
+
strict?: boolean;
|
|
100
|
+
};
|
|
92
101
|
/** Router-owned retry plan. Only ZRouter transports put this on the wire. */
|
|
93
102
|
routePlan?: {
|
|
94
103
|
fallbacks: string[];
|
|
@@ -9,14 +9,16 @@ import { attachMiniZdePane } from '../../zerg/mini_zde_render.js';
|
|
|
9
9
|
import { summarizeLoadedManifestYaml, summarizeManifestYaml } from '../../zerg/mini_zde_state.js';
|
|
10
10
|
/**
|
|
11
11
|
* Walk upward from `startDir` looking for the repo's bundled headlines
|
|
12
|
-
* manifest.
|
|
12
|
+
* manifest. Matches `<repo>/zerg/zaai/...` and the installed `/app/zaai/...` layout.
|
|
13
13
|
*/
|
|
14
14
|
function findHeadlinesManifestPath(startDir = process.cwd()) {
|
|
15
15
|
let current = resolve(startDir);
|
|
16
16
|
while (true) {
|
|
17
|
-
const
|
|
18
|
-
|
|
19
|
-
|
|
17
|
+
for (const suite of [join(current, 'zerg', 'zaai'), join(current, 'zaai')]) {
|
|
18
|
+
const candidate = join(suite, 'domains', 'core', 'headlines', 'headlines.yaml');
|
|
19
|
+
if (existsSync(candidate)) {
|
|
20
|
+
return candidate;
|
|
21
|
+
}
|
|
20
22
|
}
|
|
21
23
|
const parent = dirname(current);
|
|
22
24
|
if (parent === current) {
|
|
@@ -171,12 +171,12 @@ export const adaptationRunTool = {
|
|
|
171
171
|
...(args.api_auth_headers ? { api_auth_headers: JSON.parse(args.api_auth_headers) } : {}),
|
|
172
172
|
};
|
|
173
173
|
// Derive output_dir (mirrors cli.py) for adaptation.log.
|
|
174
|
-
// cli.py sits at zerg/zaai/domains/connector_generation/cli.py;
|
|
175
|
-
// parent reaches
|
|
174
|
+
// cli.py sits at zerg/zaai/domains/connector_generation/cli.py; 4 ups from its
|
|
175
|
+
// parent reaches the monorepo root, which has dcaig/ as a direct child
|
|
176
176
|
// (matches cli.py's Python-side workspace derivation at cli.py:90-91).
|
|
177
177
|
const workspace = process.env.ZERG_WORKSPACE_ROOT
|
|
178
178
|
|| (() => {
|
|
179
|
-
const derived = resolve(dirname(runnerPath), '..', '..', '..');
|
|
179
|
+
const derived = resolve(dirname(runnerPath), '..', '..', '..', '..');
|
|
180
180
|
if (!existsSync(resolve(derived, 'dcaig'))) {
|
|
181
181
|
throw new Error(`Derived workspace ${derived} has no dcaig/ child. Set ZERG_WORKSPACE_ROOT explicitly.`);
|
|
182
182
|
}
|
|
@@ -1829,14 +1829,18 @@ export class MirrorStreamServer {
|
|
|
1829
1829
|
const override = process.env.ZERG_CV_STATE_PATH;
|
|
1830
1830
|
if (override)
|
|
1831
1831
|
return override;
|
|
1832
|
+
const zaaiRoot = process.env.ZAAI_ROOT;
|
|
1833
|
+
if (zaaiRoot) {
|
|
1834
|
+
return resolve(zaaiRoot, 'domains', 'zcloud', 'modules', 'cv', 'cv_runner', 'state.json');
|
|
1835
|
+
}
|
|
1832
1836
|
const repoRoot = process.env.ZERG_REPO_ROOT;
|
|
1833
1837
|
if (repoRoot) {
|
|
1834
|
-
return resolve(repoRoot, 'zaai', 'domains', 'zcloud', 'modules', 'cv', 'cv_runner', 'state.json');
|
|
1838
|
+
return resolve(repoRoot, 'zerg', 'zaai', 'domains', 'zcloud', 'modules', 'cv', 'cv_runner', 'state.json');
|
|
1835
1839
|
}
|
|
1836
1840
|
// Walk up from this file: ztc/src/web/mirror_stream.ts -> repo root.
|
|
1837
1841
|
const here = fileURLToPath(import.meta.url);
|
|
1838
1842
|
const fallbackRoot = resolve(here, '..', '..', '..', '..');
|
|
1839
|
-
return resolve(fallbackRoot, 'zaai', 'domains', 'zcloud', 'modules', 'cv', 'cv_runner', 'state.json');
|
|
1843
|
+
return resolve(fallbackRoot, 'zerg', 'zaai', 'domains', 'zcloud', 'modules', 'cv', 'cv_runner', 'state.json');
|
|
1840
1844
|
}
|
|
1841
1845
|
/**
|
|
1842
1846
|
* GET /cv/snapshot — replaces the old Django /api/cv/snapshot endpoint.
|
|
@@ -1855,7 +1859,7 @@ export class MirrorStreamServer {
|
|
|
1855
1859
|
catch (error) {
|
|
1856
1860
|
// Missing file with no override env vars set → return empty snapshot.
|
|
1857
1861
|
// This mirrors the Django endpoint's "soft 200" path for fresh repos.
|
|
1858
|
-
const overridden = !!(process.env.ZERG_CV_STATE_PATH || process.env.ZERG_REPO_ROOT);
|
|
1862
|
+
const overridden = !!(process.env.ZERG_CV_STATE_PATH || process.env.ZERG_REPO_ROOT || process.env.ZAAI_ROOT);
|
|
1859
1863
|
if (!overridden && error.code === 'ENOENT') {
|
|
1860
1864
|
res.writeHead(200, { 'Content-Type': 'application/json' });
|
|
1861
1865
|
res.end(JSON.stringify({ schema_version: SCHEMA_VERSION, scenarios: [] }));
|
package/dist/zlm-embed.mjs
CHANGED
|
@@ -2408,6 +2408,9 @@ var init_codex_auth = __esm({
|
|
|
2408
2408
|
stream: true,
|
|
2409
2409
|
store: false
|
|
2410
2410
|
};
|
|
2411
|
+
if (request.outputFormat !== void 0) {
|
|
2412
|
+
body.text = { format: request.outputFormat };
|
|
2413
|
+
}
|
|
2411
2414
|
if (tools.length > 0) {
|
|
2412
2415
|
body.tools = tools;
|
|
2413
2416
|
body.tool_choice = "auto";
|
|
@@ -12130,7 +12133,7 @@ var invokeSkillTool = makeInvokeSkillTool(resolveAmbientSkills);
|
|
|
12130
12133
|
// src/zlm.ts
|
|
12131
12134
|
var ZLM_EMBED_API_VERSION = "zerglang.ztc-embed/1";
|
|
12132
12135
|
var ZLM_STDIO_PROTOCOL = "zerglang.ztc-host/1";
|
|
12133
|
-
var ZLM_ZTC_VERSION = true ? "0.2.
|
|
12136
|
+
var ZLM_ZTC_VERSION = true ? "0.2.5-dev.36050717543" : "development";
|
|
12134
12137
|
var ZLM_MAX_HOST_TOOLS = 64;
|
|
12135
12138
|
var ZLM_MAX_SYSTEM_PROMPT_BYTES = 128 * 1024;
|
|
12136
12139
|
var ZLM_HOST_APPROVAL_CAPABILITIES = Object.freeze([
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@zergai/ztc",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.5-dev.36050717543",
|
|
4
4
|
"description": "Zerg Terminal Client - CLI agent for continual AI systems",
|
|
5
5
|
"license": "SEE LICENSE IN LICENSE.md",
|
|
6
6
|
"repository": {
|
|
@@ -238,8 +238,8 @@
|
|
|
238
238
|
"zergRelease": {
|
|
239
239
|
"branch": "development",
|
|
240
240
|
"channel": "dev",
|
|
241
|
-
"sourceCommit": "
|
|
242
|
-
"sourceVersion": "0.2.0-canary.
|
|
241
|
+
"sourceCommit": "5c80769ed0fc7484860d00d0e9e5e303f8d46bfe",
|
|
242
|
+
"sourceVersion": "0.2.0-canary.2"
|
|
243
243
|
},
|
|
244
244
|
"publishConfig": {
|
|
245
245
|
"tag": "dev",
|