@zenalexa/unicli 0.224.1 → 0.225.1
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/AGENTS.md +5 -5
- package/README.md +92 -92
- package/README.zh-CN.md +69 -69
- package/dist/adapters/_electron/desktop-shared.d.ts.map +1 -1
- package/dist/adapters/_electron/desktop-shared.js +2 -1
- package/dist/adapters/_electron/desktop-shared.js.map +1 -1
- package/dist/adapters/_electron/shared.d.ts +6 -0
- package/dist/adapters/_electron/shared.d.ts.map +1 -1
- package/dist/adapters/_electron/shared.js +9 -0
- package/dist/adapters/_electron/shared.js.map +1 -1
- package/dist/adapters/antigravity/extra.js +4 -1
- package/dist/adapters/antigravity/extra.js.map +1 -1
- package/dist/adapters/chatwise/extra.js +4 -1
- package/dist/adapters/chatwise/extra.js.map +1 -1
- package/dist/adapters/codex/codex.js +3 -1
- package/dist/adapters/codex/codex.js.map +1 -1
- package/dist/adapters/codex/extra.js +4 -1
- package/dist/adapters/codex/extra.js.map +1 -1
- package/dist/adapters/codex/projects.d.ts.map +1 -1
- package/dist/adapters/codex/projects.js +3 -1
- package/dist/adapters/codex/projects.js.map +1 -1
- package/dist/adapters/cursor/cursor.js +6 -1
- package/dist/adapters/cursor/cursor.js.map +1 -1
- package/dist/adapters/discord-app/discord-app.js +10 -1
- package/dist/adapters/discord-app/discord-app.js.map +1 -1
- package/dist/adapters/notion-app/notion-app.js +11 -1
- package/dist/adapters/notion-app/notion-app.js.map +1 -1
- package/dist/adapters/spotify/api.js +36 -6
- package/dist/adapters/spotify/api.js.map +1 -1
- package/dist/adapters/xiaohongshu/browser-state.d.ts +2 -1
- package/dist/adapters/xiaohongshu/browser-state.d.ts.map +1 -1
- package/dist/adapters/xiaohongshu/browser-state.js +56 -2
- package/dist/adapters/xiaohongshu/browser-state.js.map +1 -1
- package/dist/adapters/xiaohongshu/feed.d.ts +24 -0
- package/dist/adapters/xiaohongshu/feed.d.ts.map +1 -0
- package/dist/adapters/xiaohongshu/feed.js +82 -0
- package/dist/adapters/xiaohongshu/feed.js.map +1 -0
- package/dist/adapters/xueqiu/extra.js +2 -2
- package/dist/adapters/xueqiu/extra.js.map +1 -1
- package/dist/browser/cdp-client.d.ts +15 -1
- package/dist/browser/cdp-client.d.ts.map +1 -1
- package/dist/browser/cdp-client.js +45 -16
- package/dist/browser/cdp-client.js.map +1 -1
- package/dist/browser/daemon.js +29 -7
- package/dist/browser/daemon.js.map +1 -1
- package/dist/browser/launcher.d.ts.map +1 -1
- package/dist/browser/launcher.js +22 -8
- package/dist/browser/launcher.js.map +1 -1
- package/dist/browser/local-profiles.d.ts +2 -0
- package/dist/browser/local-profiles.d.ts.map +1 -1
- package/dist/browser/local-profiles.js +42 -2
- package/dist/browser/local-profiles.js.map +1 -1
- package/dist/browser/page.d.ts +2 -2
- package/dist/browser/page.d.ts.map +1 -1
- package/dist/browser/page.js +2 -2
- package/dist/browser/page.js.map +1 -1
- package/dist/browser/protocol.d.ts +7 -0
- package/dist/browser/protocol.d.ts.map +1 -1
- package/dist/browser/protocol.js +5 -0
- package/dist/browser/protocol.js.map +1 -1
- package/dist/cli.d.ts.map +1 -1
- package/dist/cli.js +4 -3
- package/dist/cli.js.map +1 -1
- package/dist/commands/architecture.d.ts +3 -1
- package/dist/commands/architecture.d.ts.map +1 -1
- package/dist/commands/architecture.js +13 -5
- package/dist/commands/architecture.js.map +1 -1
- package/dist/commands/browser/index.d.ts.map +1 -1
- package/dist/commands/browser/index.js +26 -4
- package/dist/commands/browser/index.js.map +1 -1
- package/dist/commands/delivery.d.ts.map +1 -1
- package/dist/commands/delivery.js.map +1 -1
- package/dist/commands/describe.d.ts.map +1 -1
- package/dist/commands/describe.js +104 -9
- package/dist/commands/describe.js.map +1 -1
- package/dist/commands/dispatch.d.ts.map +1 -1
- package/dist/commands/dispatch.js +3 -13
- package/dist/commands/dispatch.js.map +1 -1
- package/dist/commands/do.d.ts +16 -13
- package/dist/commands/do.d.ts.map +1 -1
- package/dist/commands/do.js +72 -18
- package/dist/commands/do.js.map +1 -1
- package/dist/commands/social.d.ts.map +1 -1
- package/dist/commands/social.js +3 -13
- package/dist/commands/social.js.map +1 -1
- package/dist/core/architecture-tree.d.ts +26 -6
- package/dist/core/architecture-tree.d.ts.map +1 -1
- package/dist/core/architecture-tree.js +184 -40
- package/dist/core/architecture-tree.js.map +1 -1
- package/dist/core/capability-matrix.d.ts +63 -0
- package/dist/core/capability-matrix.d.ts.map +1 -0
- package/dist/core/capability-matrix.js +316 -0
- package/dist/core/capability-matrix.js.map +1 -0
- package/dist/core/command-contract-lint.d.ts.map +1 -1
- package/dist/core/command-contract-lint.js +3 -1
- package/dist/core/command-contract-lint.js.map +1 -1
- package/dist/core/command-contract.d.ts +10 -3
- package/dist/core/command-contract.d.ts.map +1 -1
- package/dist/core/command-contract.js +87 -5
- package/dist/core/command-contract.js.map +1 -1
- package/dist/discovery/aliases.d.ts.map +1 -1
- package/dist/discovery/aliases.js +26 -0
- package/dist/discovery/aliases.js.map +1 -1
- package/dist/discovery/core-catalog.d.ts +1 -0
- package/dist/discovery/core-catalog.d.ts.map +1 -1
- package/dist/discovery/core-catalog.js +22 -5
- package/dist/discovery/core-catalog.js.map +1 -1
- package/dist/discovery/intents.d.ts +31 -4
- package/dist/discovery/intents.d.ts.map +1 -1
- package/dist/discovery/intents.js +166 -3
- package/dist/discovery/intents.js.map +1 -1
- package/dist/discovery/loader.d.ts.map +1 -1
- package/dist/discovery/loader.js +3 -0
- package/dist/discovery/loader.js.map +1 -1
- package/dist/discovery/search.d.ts.map +1 -1
- package/dist/discovery/search.js +10 -1
- package/dist/discovery/search.js.map +1 -1
- package/dist/engine/cascade.d.ts.map +1 -1
- package/dist/engine/cascade.js +21 -25
- package/dist/engine/cascade.js.map +1 -1
- package/dist/engine/chromium-cookies.d.ts +27 -0
- package/dist/engine/chromium-cookies.d.ts.map +1 -1
- package/dist/engine/chromium-cookies.js +53 -14
- package/dist/engine/chromium-cookies.js.map +1 -1
- package/dist/engine/cookie-capture.d.ts +30 -0
- package/dist/engine/cookie-capture.d.ts.map +1 -0
- package/dist/engine/cookie-capture.js +104 -0
- package/dist/engine/cookie-capture.js.map +1 -0
- package/dist/engine/cookie-extractor.d.ts.map +1 -1
- package/dist/engine/cookie-extractor.js +4 -12
- package/dist/engine/cookie-extractor.js.map +1 -1
- package/dist/engine/cookie-refresh.d.ts +59 -8
- package/dist/engine/cookie-refresh.d.ts.map +1 -1
- package/dist/engine/cookie-refresh.js +80 -58
- package/dist/engine/cookie-refresh.js.map +1 -1
- package/dist/engine/cookie-source.d.ts +110 -0
- package/dist/engine/cookie-source.d.ts.map +1 -0
- package/dist/engine/cookie-source.js +207 -0
- package/dist/engine/cookie-source.js.map +1 -0
- package/dist/engine/cookies.d.ts +37 -25
- package/dist/engine/cookies.d.ts.map +1 -1
- package/dist/engine/cookies.js +58 -157
- package/dist/engine/cookies.js.map +1 -1
- package/dist/engine/delivery/index.d.ts +2 -1
- package/dist/engine/delivery/index.d.ts.map +1 -1
- package/dist/engine/delivery/index.js +2 -1
- package/dist/engine/delivery/index.js.map +1 -1
- package/dist/engine/delivery/spec.d.ts +44 -0
- package/dist/engine/delivery/spec.d.ts.map +1 -0
- package/dist/engine/delivery/spec.js +82 -0
- package/dist/engine/delivery/spec.js.map +1 -0
- package/dist/engine/executor.d.ts +17 -6
- package/dist/engine/executor.d.ts.map +1 -1
- package/dist/engine/executor.js +131 -68
- package/dist/engine/executor.js.map +1 -1
- package/dist/engine/kernel/stages.d.ts.map +1 -1
- package/dist/engine/kernel/stages.js +14 -4
- package/dist/engine/kernel/stages.js.map +1 -1
- package/dist/engine/objective/catalog.d.ts +23 -0
- package/dist/engine/objective/catalog.d.ts.map +1 -0
- package/dist/engine/objective/catalog.js +42 -0
- package/dist/engine/objective/catalog.js.map +1 -0
- package/dist/engine/objective/delivery.d.ts +18 -0
- package/dist/engine/objective/delivery.d.ts.map +1 -0
- package/dist/engine/objective/delivery.js +64 -0
- package/dist/engine/objective/delivery.js.map +1 -0
- package/dist/engine/objective/index.d.ts +20 -0
- package/dist/engine/objective/index.d.ts.map +1 -0
- package/dist/engine/objective/index.js +20 -0
- package/dist/engine/objective/index.js.map +1 -0
- package/dist/engine/objective/media-playback.d.ts +17 -0
- package/dist/engine/objective/media-playback.d.ts.map +1 -0
- package/dist/engine/objective/media-playback.js +186 -0
- package/dist/engine/objective/media-playback.js.map +1 -0
- package/dist/engine/objective/output.d.ts +20 -0
- package/dist/engine/objective/output.d.ts.map +1 -0
- package/dist/engine/objective/output.js +88 -0
- package/dist/engine/objective/output.js.map +1 -0
- package/dist/engine/objective/planner.d.ts +17 -0
- package/dist/engine/objective/planner.d.ts.map +1 -0
- package/dist/engine/objective/planner.js +60 -0
- package/dist/engine/objective/planner.js.map +1 -0
- package/dist/engine/objective/types.d.ts +66 -0
- package/dist/engine/objective/types.d.ts.map +1 -0
- package/dist/engine/objective/types.js +16 -0
- package/dist/engine/objective/types.js.map +1 -0
- package/dist/engine/runtime.d.ts.map +1 -1
- package/dist/engine/runtime.js +9 -4
- package/dist/engine/runtime.js.map +1 -1
- package/dist/engine/step-observer.d.ts +62 -0
- package/dist/engine/step-observer.d.ts.map +1 -0
- package/dist/engine/step-observer.js +38 -0
- package/dist/engine/step-observer.js.map +1 -0
- package/dist/engine/steps/browser-helpers.d.ts.map +1 -1
- package/dist/engine/steps/browser-helpers.js +36 -8
- package/dist/engine/steps/browser-helpers.js.map +1 -1
- package/dist/engine/steps/fetch-text.d.ts.map +1 -1
- package/dist/engine/steps/fetch-text.js +106 -33
- package/dist/engine/steps/fetch-text.js.map +1 -1
- package/dist/engine/steps/fetch.d.ts +20 -0
- package/dist/engine/steps/fetch.d.ts.map +1 -1
- package/dist/engine/steps/fetch.js.map +1 -1
- package/dist/engine/steps/index.d.ts +2 -0
- package/dist/engine/steps/index.d.ts.map +1 -1
- package/dist/engine/steps/index.js +2 -0
- package/dist/engine/steps/index.js.map +1 -1
- package/dist/engine/steps/split-text.d.ts +26 -0
- package/dist/engine/steps/split-text.d.ts.map +1 -0
- package/dist/engine/steps/split-text.js +89 -0
- package/dist/engine/steps/split-text.js.map +1 -0
- package/dist/engine/steps/to-entries.d.ts +9 -0
- package/dist/engine/steps/to-entries.d.ts.map +1 -0
- package/dist/engine/steps/to-entries.js +27 -0
- package/dist/engine/steps/to-entries.js.map +1 -0
- package/dist/fast-path/handlers/discovery.d.ts.map +1 -1
- package/dist/fast-path/handlers/discovery.js +7 -7
- package/dist/fast-path/handlers/discovery.js.map +1 -1
- package/dist/manifest-compact.txt +3 -2
- package/dist/manifest.json +183 -17
- package/dist/mcp/tools.js +1 -1
- package/dist/mcp/tools.js.map +1 -1
- package/dist/output/auth-guidance.d.ts +17 -3
- package/dist/output/auth-guidance.d.ts.map +1 -1
- package/dist/output/auth-guidance.js +27 -3
- package/dist/output/auth-guidance.js.map +1 -1
- package/dist/output/error-map.d.ts.map +1 -1
- package/dist/output/error-map.js +4 -0
- package/dist/output/error-map.js.map +1 -1
- package/package.json +4 -2
- package/server.json +2 -2
- package/skills/unicli/SKILL.md +1 -1
- package/skills/unicli-claude-code/SKILL.md +1 -1
- package/skills/unicli-hermes/SKILL.md +1 -1
- package/src/adapters/12306/price.yaml +91 -0
- package/src/adapters/12306/stations.yaml +52 -0
- package/src/adapters/12306/trains.yaml +129 -0
- package/src/adapters/_electron/desktop-shared.ts +5 -1
- package/src/adapters/_electron/shared.ts +15 -0
- package/src/adapters/antigravity/extra.ts +10 -1
- package/src/adapters/chatwise/extra.ts +10 -1
- package/src/adapters/codex/codex.ts +6 -0
- package/src/adapters/codex/extra.ts +10 -1
- package/src/adapters/codex/projects.ts +9 -1
- package/src/adapters/cursor/cursor.ts +9 -0
- package/src/adapters/discord-app/discord-app.ts +16 -1
- package/src/adapters/macos/brightness.yaml +6 -3
- package/src/adapters/macos/calendar-list.yaml +9 -11
- package/src/adapters/macos/calendar-today.yaml +1 -1
- package/src/adapters/macos/safari-url.yaml +8 -4
- package/src/adapters/maoyan/hot.yaml +1 -1
- package/src/adapters/notion-app/notion-app.ts +17 -1
- package/src/adapters/spotify/api.ts +54 -8
- package/src/adapters/weibo/trending.yaml +2 -0
- package/src/adapters/xiaohongshu/browser-state.ts +59 -2
- package/src/adapters/xiaohongshu/feed.ts +103 -0
- package/src/adapters/xueqiu/extra.ts +5 -2
|
@@ -1,18 +1,19 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* @owner src/core/architecture-tree.ts
|
|
3
|
-
* @does Builds the callable Uni-CLI architecture tree and
|
|
4
|
-
* @needs src/core/command-contract, src/types
|
|
3
|
+
* @does Builds the callable Uni-CLI computer-control architecture tree and audit from adapter and core command contracts.
|
|
4
|
+
* @needs src/core/command-contract, src/discovery/core-catalog, src/types
|
|
5
5
|
* @feeds src/commands/architecture.ts, tests/unit/core/architecture-tree.test.ts
|
|
6
6
|
* @breaks Propagates command-contract construction errors when adapter metadata is malformed.
|
|
7
|
-
* @invariants
|
|
7
|
+
* @invariants Computer-control order is stable: intent, select, govern, act, observe, diagnose, repair-or-reroute, deliver, expose.
|
|
8
8
|
* @side-effects none
|
|
9
|
-
* @perf O(commands) over
|
|
9
|
+
* @perf O(commands) over loaded adapter and core command registries; allocates one inventory entry per command.
|
|
10
10
|
* @concurrency Pure and reentrant; no shared mutable state.
|
|
11
11
|
* @test tests/unit/core/architecture-tree.test.ts
|
|
12
12
|
* @stability experimental
|
|
13
13
|
* @since 2026-05-26
|
|
14
14
|
*/
|
|
15
|
-
import { buildCommandContract } from "./command-contract.js";
|
|
15
|
+
import { buildCommandContract, buildCoreCommandContract, } from "./command-contract.js";
|
|
16
|
+
import { buildArchitectureCapabilityMatrix, buildArchitectureWorkflowReadiness, } from "./capability-matrix.js";
|
|
16
17
|
import { AdapterType } from "../types.js";
|
|
17
18
|
export const COMMAND_LIFECYCLE_STEPS = [
|
|
18
19
|
"create",
|
|
@@ -22,6 +23,17 @@ export const COMMAND_LIFECYCLE_STEPS = [
|
|
|
22
23
|
"repair",
|
|
23
24
|
"publish",
|
|
24
25
|
];
|
|
26
|
+
export const COMPUTER_CONTROL_STAGES = [
|
|
27
|
+
"intent",
|
|
28
|
+
"select",
|
|
29
|
+
"govern",
|
|
30
|
+
"act",
|
|
31
|
+
"observe",
|
|
32
|
+
"diagnose",
|
|
33
|
+
"repair-or-reroute",
|
|
34
|
+
"deliver",
|
|
35
|
+
"expose",
|
|
36
|
+
];
|
|
25
37
|
function commandRef(adapter, commandName) {
|
|
26
38
|
return `${adapter.name}.${commandName}`;
|
|
27
39
|
}
|
|
@@ -34,6 +46,12 @@ function isLocalComputerUseCommand(adapter, command, targetSurface) {
|
|
|
34
46
|
capability.startsWith("compute.") ||
|
|
35
47
|
capability.startsWith("visual."));
|
|
36
48
|
}
|
|
49
|
+
function commandCapabilities(command) {
|
|
50
|
+
return Array.from(new Set([
|
|
51
|
+
...(command.capabilities ?? []),
|
|
52
|
+
...(command.minimum_capability ? [command.minimum_capability] : []),
|
|
53
|
+
])).sort();
|
|
54
|
+
}
|
|
37
55
|
function collectCommandInventory(adapters) {
|
|
38
56
|
const entries = [];
|
|
39
57
|
for (const adapter of adapters) {
|
|
@@ -44,35 +62,93 @@ function collectCommandInventory(adapters) {
|
|
|
44
62
|
command,
|
|
45
63
|
});
|
|
46
64
|
const targetSurface = contract.effect.target_surface;
|
|
65
|
+
const capabilities = commandCapabilities(command);
|
|
47
66
|
entries.push({
|
|
48
67
|
ref: commandRef(adapter, commandName),
|
|
49
68
|
site: adapter.name,
|
|
50
69
|
command: commandName,
|
|
70
|
+
source_kind: "adapter",
|
|
51
71
|
adapter_type: adapter.type,
|
|
52
72
|
target_surface: targetSurface,
|
|
73
|
+
...(adapter.category ? { category: adapter.category } : {}),
|
|
53
74
|
...(contract.identity.source_path
|
|
54
75
|
? { source_path: contract.identity.source_path }
|
|
55
76
|
: {}),
|
|
56
77
|
safety_class: contract.effect.safety_class,
|
|
78
|
+
operation_effect: contract.effect.operation_effect,
|
|
57
79
|
...(command.minimum_capability
|
|
58
80
|
? { minimum_capability: command.minimum_capability }
|
|
59
81
|
: {}),
|
|
82
|
+
capabilities,
|
|
83
|
+
uses_browser: contract.effect.browser,
|
|
60
84
|
is_local_computer_use: isLocalComputerUseCommand(adapter, command, targetSurface),
|
|
61
85
|
});
|
|
62
86
|
}
|
|
63
87
|
}
|
|
64
88
|
return entries.sort((leftEntry, rightEntry) => leftEntry.ref.localeCompare(rightEntry.ref));
|
|
65
89
|
}
|
|
90
|
+
function isLocalComputerUseCoreCommand(command, targetSurface) {
|
|
91
|
+
return targetSurface === "desktop" || command.type === AdapterType.DESKTOP;
|
|
92
|
+
}
|
|
93
|
+
function collectCoreCommandInventory(coreCommands = []) {
|
|
94
|
+
return coreCommands.map((command) => {
|
|
95
|
+
const contract = buildCoreCommandContract({ command });
|
|
96
|
+
const targetSurface = contract.effect.target_surface;
|
|
97
|
+
return {
|
|
98
|
+
ref: `${command.site}.${command.command}`,
|
|
99
|
+
site: command.site,
|
|
100
|
+
command: command.command,
|
|
101
|
+
source_kind: "core",
|
|
102
|
+
adapter_type: command.type,
|
|
103
|
+
target_surface: targetSurface,
|
|
104
|
+
category: command.category,
|
|
105
|
+
...(contract.identity.source_path
|
|
106
|
+
? { source_path: contract.identity.source_path }
|
|
107
|
+
: {}),
|
|
108
|
+
safety_class: contract.effect.safety_class,
|
|
109
|
+
operation_effect: contract.effect.operation_effect,
|
|
110
|
+
capabilities: [],
|
|
111
|
+
uses_browser: contract.effect.browser,
|
|
112
|
+
is_local_computer_use: isLocalComputerUseCoreCommand(command, targetSurface),
|
|
113
|
+
};
|
|
114
|
+
});
|
|
115
|
+
}
|
|
116
|
+
function collectFullCommandInventory(input) {
|
|
117
|
+
return [
|
|
118
|
+
...collectCommandInventory(input.adapters),
|
|
119
|
+
...collectCoreCommandInventory(input.coreCommands),
|
|
120
|
+
].sort((leftEntry, rightEntry) => leftEntry.ref.localeCompare(rightEntry.ref));
|
|
121
|
+
}
|
|
66
122
|
function node(input) {
|
|
67
123
|
return { ...input, children: input.children ?? [] };
|
|
68
124
|
}
|
|
125
|
+
const CONTROL_STAGE_DESCRIPTIONS = {
|
|
126
|
+
intent: "Accept human or agent intent without preloading a giant tool list.",
|
|
127
|
+
select: "Choose the smallest operation boundary that can act on the target software.",
|
|
128
|
+
govern: "Evaluate permission profile, risk, capability scope, and local policy before action.",
|
|
129
|
+
act: "Invoke the selected software substrate through the shared kernel.",
|
|
130
|
+
observe: "Return data, context, retryability, timing, and evidence through one envelope.",
|
|
131
|
+
diagnose: "Classify failure as auth, policy, missing context, upstream drift, environment trouble, or adapter defect.",
|
|
132
|
+
"repair-or-reroute": "Bound the next experiment by source path, evidence, alternatives, and verification command.",
|
|
133
|
+
deliver: "Decide whether the objective is satisfied, still active, blocked, or exhausted.",
|
|
134
|
+
expose: "Expose the same operation through CLI, MCP, ACP, HTTP, docs, skills, and scripts.",
|
|
135
|
+
};
|
|
136
|
+
function controlStageNodes() {
|
|
137
|
+
return COMPUTER_CONTROL_STAGES.map((stage) => node({
|
|
138
|
+
id: `control-${stage}`,
|
|
139
|
+
label: stage,
|
|
140
|
+
kind: "control-stage",
|
|
141
|
+
priority: "P0",
|
|
142
|
+
description: CONTROL_STAGE_DESCRIPTIONS[stage],
|
|
143
|
+
}));
|
|
144
|
+
}
|
|
69
145
|
function lifecycleNodes() {
|
|
70
146
|
return COMMAND_LIFECYCLE_STEPS.map((step) => node({
|
|
71
147
|
id: `lifecycle-${step}`,
|
|
72
148
|
label: step,
|
|
73
149
|
kind: "lifecycle",
|
|
74
|
-
priority: "
|
|
75
|
-
description: `
|
|
150
|
+
priority: "P1",
|
|
151
|
+
description: `Internal authoring lifecycle step: ${step}.`,
|
|
76
152
|
}));
|
|
77
153
|
}
|
|
78
154
|
function buildRootNode(summary) {
|
|
@@ -81,65 +157,118 @@ function buildRootNode(summary) {
|
|
|
81
157
|
label: "Uni-CLI",
|
|
82
158
|
kind: "root",
|
|
83
159
|
priority: "P0",
|
|
84
|
-
description: "
|
|
160
|
+
description: "Universal computer-control platform for agents: intent, governed action, evidence, delivery, and repair across software substrates.",
|
|
85
161
|
command_count: summary.total_commands,
|
|
86
162
|
children: [
|
|
87
163
|
node({
|
|
88
|
-
id: "
|
|
89
|
-
label: "
|
|
164
|
+
id: "computer-control-platform",
|
|
165
|
+
label: "Computer-control platform",
|
|
90
166
|
kind: "group",
|
|
91
167
|
priority: "P0",
|
|
92
|
-
description: "
|
|
168
|
+
description: "Top-level product loop: an agent controls a computer through governed, observable, repairable operations.",
|
|
169
|
+
command_count: summary.total_commands,
|
|
170
|
+
children: controlStageNodes(),
|
|
171
|
+
}),
|
|
172
|
+
node({
|
|
173
|
+
id: "operation-contract",
|
|
174
|
+
label: "Operation contract",
|
|
175
|
+
kind: "runtime",
|
|
176
|
+
priority: "P0",
|
|
177
|
+
description: "Agent-callable action identity, args, output, auth posture, safety, capability, source path, and repair path.",
|
|
178
|
+
command_count: summary.total_commands,
|
|
179
|
+
}),
|
|
180
|
+
node({
|
|
181
|
+
id: "control-kernel",
|
|
182
|
+
label: "Control kernel",
|
|
183
|
+
kind: "runtime",
|
|
184
|
+
priority: "P0",
|
|
185
|
+
description: "Validate, harden, authorize, invoke a substrate, observe, and envelope without wrapper-specific semantics.",
|
|
186
|
+
command_count: summary.total_commands,
|
|
187
|
+
}),
|
|
188
|
+
node({
|
|
189
|
+
id: "action-substrates",
|
|
190
|
+
label: "Action substrates",
|
|
191
|
+
kind: "group",
|
|
192
|
+
priority: "P0",
|
|
193
|
+
description: "Concrete technical boundaries below the platform: useful, swappable, and never the top-level product identity.",
|
|
194
|
+
command_count: summary.total_commands,
|
|
93
195
|
children: [
|
|
94
196
|
node({
|
|
95
|
-
id: "
|
|
96
|
-
label: "
|
|
97
|
-
kind: "
|
|
197
|
+
id: "web-api-substrate",
|
|
198
|
+
label: "Web and API",
|
|
199
|
+
kind: "substrate",
|
|
98
200
|
priority: "P0",
|
|
99
|
-
description: "
|
|
100
|
-
command_count: summary.total_commands,
|
|
201
|
+
description: "HTTP, RSS, cookies, headers, browser-intercept flows, downloads, uploads, publishing, and extraction.",
|
|
101
202
|
}),
|
|
102
203
|
node({
|
|
103
|
-
id: "
|
|
104
|
-
label: "
|
|
105
|
-
kind: "
|
|
204
|
+
id: "browser-substrate",
|
|
205
|
+
label: "Browser",
|
|
206
|
+
kind: "substrate",
|
|
106
207
|
priority: "P0",
|
|
107
|
-
description: "
|
|
108
|
-
command_count: summary.total_commands,
|
|
208
|
+
description: "CDP navigation, refs, DOM and accessibility snapshots, network capture, clicks, typing, screenshots, and render-aware evidence.",
|
|
109
209
|
}),
|
|
110
210
|
node({
|
|
111
|
-
id: "
|
|
112
|
-
label: "
|
|
113
|
-
kind: "
|
|
211
|
+
id: "desktop-os-substrate",
|
|
212
|
+
label: "Desktop and OS",
|
|
213
|
+
kind: "substrate",
|
|
114
214
|
priority: "P0",
|
|
115
|
-
description: "
|
|
215
|
+
description: "Installed apps, macOS Accessibility, UIA, AT-SPI, screenshots, app actions, clipboard, calendar, brightness, and OS state.",
|
|
116
216
|
command_count: summary.local_computer_use_commands,
|
|
117
217
|
}),
|
|
118
218
|
node({
|
|
119
|
-
id: "
|
|
120
|
-
label: "
|
|
121
|
-
kind: "
|
|
219
|
+
id: "local-tool-substrate",
|
|
220
|
+
label: "Local tools and files",
|
|
221
|
+
kind: "substrate",
|
|
122
222
|
priority: "P0",
|
|
123
|
-
description: "
|
|
124
|
-
|
|
223
|
+
description: "Subprocess bridges, external binaries, paper/PDF workflows, media tools, developer CLIs, and file transformations.",
|
|
224
|
+
}),
|
|
225
|
+
node({
|
|
226
|
+
id: "protocol-substrate",
|
|
227
|
+
label: "Agent protocols",
|
|
228
|
+
kind: "substrate",
|
|
229
|
+
priority: "P1",
|
|
230
|
+
description: "MCP, ACP, Streamable HTTP, JSON streams, generated agent configs, and skills as exposure or action boundaries.",
|
|
231
|
+
}),
|
|
232
|
+
node({
|
|
233
|
+
id: "visual-substrate",
|
|
234
|
+
label: "Visual fallback",
|
|
235
|
+
kind: "substrate",
|
|
236
|
+
priority: "P2",
|
|
237
|
+
description: "Screenshot-driven action path, valid only when it can see, act, and verify post-state evidence.",
|
|
125
238
|
}),
|
|
126
239
|
],
|
|
127
240
|
}),
|
|
128
241
|
node({
|
|
129
|
-
id: "
|
|
130
|
-
label: "
|
|
131
|
-
kind: "
|
|
242
|
+
id: "evidence-delivery-loop",
|
|
243
|
+
label: "Evidence and delivery loop",
|
|
244
|
+
kind: "runtime",
|
|
132
245
|
priority: "P0",
|
|
133
|
-
description: "
|
|
246
|
+
description: "AgentEnvelope, run traces, post-state evidence, objective gates, trajectory, reroute, and bounded repair.",
|
|
247
|
+
command_count: summary.total_commands,
|
|
248
|
+
}),
|
|
249
|
+
node({
|
|
250
|
+
id: "runtime-exposure",
|
|
251
|
+
label: "Runtime exposure",
|
|
252
|
+
kind: "surface",
|
|
253
|
+
priority: "P1",
|
|
254
|
+
description: "CLI, MCP, ACP, HTTP, docs, llms.txt, AGENTS.md, generated configs, and skills expose the same operation contracts.",
|
|
255
|
+
command_count: summary.total_commands,
|
|
256
|
+
}),
|
|
257
|
+
node({
|
|
258
|
+
id: "internal-authoring-cycle",
|
|
259
|
+
label: "Internal authoring cycle",
|
|
260
|
+
kind: "group",
|
|
261
|
+
priority: "P1",
|
|
262
|
+
description: "Create, discover, invoke, observe, repair, and publish operations; this is internal machinery, not product identity.",
|
|
134
263
|
command_count: summary.total_commands,
|
|
135
264
|
children: lifecycleNodes(),
|
|
136
265
|
}),
|
|
137
266
|
node({
|
|
138
|
-
id: "
|
|
139
|
-
label: "
|
|
267
|
+
id: "non-product-identities",
|
|
268
|
+
label: "Non-product identities",
|
|
140
269
|
kind: "group",
|
|
141
270
|
priority: "P2",
|
|
142
|
-
description: "
|
|
271
|
+
description: "Surfaces Uni-CLI can use or expose but must not collapse into.",
|
|
143
272
|
children: [
|
|
144
273
|
node({
|
|
145
274
|
id: "expanded-mcp",
|
|
@@ -175,21 +304,28 @@ function buildRootNode(summary) {
|
|
|
175
304
|
});
|
|
176
305
|
}
|
|
177
306
|
export function buildArchitectureTree(input) {
|
|
178
|
-
const commandInventory =
|
|
307
|
+
const commandInventory = collectFullCommandInventory(input);
|
|
308
|
+
const capabilityMatrix = buildArchitectureCapabilityMatrix(commandInventory);
|
|
309
|
+
const workflowReadiness = buildArchitectureWorkflowReadiness(commandInventory);
|
|
179
310
|
const localComputerUseCommands = commandInventory.filter((entry) => entry.is_local_computer_use).length;
|
|
180
311
|
const missingSourcePathCommands = commandInventory.filter((entry) => entry.source_path === undefined).length;
|
|
181
312
|
const summary = {
|
|
182
|
-
total_sites:
|
|
313
|
+
total_sites: new Set(commandInventory.map((entry) => entry.site)).size,
|
|
183
314
|
total_commands: commandInventory.length,
|
|
315
|
+
adapter_commands: commandInventory.filter((entry) => entry.source_kind === "adapter").length,
|
|
316
|
+
core_commands: commandInventory.filter((entry) => entry.source_kind === "core").length,
|
|
184
317
|
local_computer_use_commands: localComputerUseCommands,
|
|
185
318
|
missing_source_path_commands: missingSourcePathCommands,
|
|
186
319
|
};
|
|
187
320
|
return {
|
|
188
321
|
schema_version: "architecture-tree.v1",
|
|
322
|
+
control_stages: COMPUTER_CONTROL_STAGES,
|
|
189
323
|
lifecycle_steps: COMMAND_LIFECYCLE_STEPS,
|
|
190
324
|
summary,
|
|
191
325
|
root: buildRootNode(summary),
|
|
192
326
|
command_inventory: commandInventory,
|
|
327
|
+
capability_matrix: capabilityMatrix,
|
|
328
|
+
workflow_readiness: workflowReadiness,
|
|
193
329
|
};
|
|
194
330
|
}
|
|
195
331
|
export function auditArchitectureTree(input) {
|
|
@@ -201,13 +337,21 @@ export function auditArchitectureTree(input) {
|
|
|
201
337
|
schema_version: "architecture-audit.v1",
|
|
202
338
|
total_sites: tree.summary.total_sites,
|
|
203
339
|
total_commands: tree.summary.total_commands,
|
|
340
|
+
adapter_commands: tree.summary.adapter_commands,
|
|
341
|
+
core_commands: tree.summary.core_commands,
|
|
204
342
|
local_computer_use_commands: tree.summary.local_computer_use_commands,
|
|
343
|
+
control_stages: COMPUTER_CONTROL_STAGES,
|
|
205
344
|
lifecycle_steps: COMMAND_LIFECYCLE_STEPS,
|
|
345
|
+
capability_matrix: tree.capability_matrix,
|
|
346
|
+
workflow_readiness: tree.workflow_readiness,
|
|
206
347
|
missing_source_paths: missingSourcePaths,
|
|
207
|
-
|
|
348
|
+
non_product_identities: [
|
|
208
349
|
"expanded-mcp",
|
|
209
350
|
"visual-fallback",
|
|
210
351
|
"typescript-adapters",
|
|
352
|
+
"browser-automation-only",
|
|
353
|
+
"computer-use-sandbox-only",
|
|
354
|
+
"per-site-wrapper-only",
|
|
211
355
|
],
|
|
212
356
|
ready_for_full_rewrite: tree.summary.total_commands > 0 && missingSourcePaths.length === 0,
|
|
213
357
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"architecture-tree.js","sourceRoot":"","sources":["../../src/core/architecture-tree.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AAEH,OAAO,
|
|
1
|
+
{"version":3,"file":"architecture-tree.js","sourceRoot":"","sources":["../../src/core/architecture-tree.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AAEH,OAAO,EACL,oBAAoB,EACpB,wBAAwB,GACzB,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EACL,iCAAiC,EACjC,kCAAkC,GAGnC,MAAM,wBAAwB,CAAC;AAEhC,OAAO,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAO1C,MAAM,CAAC,MAAM,uBAAuB,GAAG;IACrC,QAAQ;IACR,UAAU;IACV,QAAQ;IACR,SAAS;IACT,QAAQ;IACR,SAAS;CACD,CAAC;AAEX,MAAM,CAAC,MAAM,uBAAuB,GAAG;IACrC,QAAQ;IACR,QAAQ;IACR,QAAQ;IACR,KAAK;IACL,SAAS;IACT,UAAU;IACV,mBAAmB;IACnB,SAAS;IACT,QAAQ;CACA,CAAC;AAmFX,SAAS,UAAU,CAAC,OAAwB,EAA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AC;SAClD,GAAG,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;IAE7B,OAAO;QACL,cAAc,EAAE,uBAAuB;QACvC,WAAW,EAAE,IAAI,CAAC,OAAO,CAAC,WAAW;QACrC,cAAc,EAAE,IAAI,CAAC,OAAO,CAAC,cAAc;QAC3C,gBAAgB,EAAE,IAAI,CAAC,OAAO,CAAC,gBAAgB;QAC/C,aAAa,EAAE,IAAI,CAAC,OAAO,CAAC,aAAa;QACzC,2BAA2B,EAAE,IAAI,CAAC,OAAO,CAAC,2BAA2B;QACrE,cAAc,EAAE,uBAAuB;QACvC,eAAe,EAAE,uBAAuB;QACxC,iBAAiB,EAAE,IAAI,CAAC,iBAAiB;QACzC,kBAAkB,EAAE,IAAI,CAAC,kBAAkB;QAC3C,oBAAoB,EAAE,kBAAkB;QACxC,sBAAsB,EAAE;YACtB,cAAc;YACd,iBAAiB;YACjB,qBAAqB;YACrB,yBAAyB;YACzB,2BAA2B;YAC3B,uBAAuB;SACxB;QACD,sBAAsB,EACpB,IAAI,CAAC,OAAO,CAAC,cAAc,GAAG,CAAC,IAAI,kBAAkB,CAAC,MAAM,KAAK,CAAC;KACrE,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @owner src/core/capability-matrix.ts
|
|
3
|
+
* @does Builds live-catalog substrate and workflow readiness matrices for agent-to-computer control.
|
|
4
|
+
* @needs command inventory rows from src/core/architecture-tree.ts
|
|
5
|
+
* @feeds architecture tree/audit payloads and architecture regression tests.
|
|
6
|
+
* @breaks Misclassification overstates what Uni-CLI can control, especially visual or workflow coverage.
|
|
7
|
+
* @invariants Readiness is catalog-derived only; live verification must be represented as required next evidence, not implied success.
|
|
8
|
+
* @side-effects none
|
|
9
|
+
* @perf O(commands * surfaces + commands * workflows), bounded by catalog size.
|
|
10
|
+
* @concurrency pure and reentrant.
|
|
11
|
+
* @test tests/unit/core/capability-matrix.test.ts
|
|
12
|
+
* @stability experimental
|
|
13
|
+
* @since 2026-05-31
|
|
14
|
+
*/
|
|
15
|
+
export declare const CAPABILITY_SURFACES: readonly ["web", "browser", "desktop", "system", "protocol", "bridge"];
|
|
16
|
+
export type ArchitectureCapabilitySurface = (typeof CAPABILITY_SURFACES)[number];
|
|
17
|
+
export type WorkflowReadinessStatus = "cataloged" | "partial" | "gap";
|
|
18
|
+
export interface CapabilityMatrixInventoryEntry {
|
|
19
|
+
ref: string;
|
|
20
|
+
site: string;
|
|
21
|
+
command: string;
|
|
22
|
+
source_kind: "adapter" | "core";
|
|
23
|
+
adapter_type: string;
|
|
24
|
+
target_surface: string;
|
|
25
|
+
category?: string;
|
|
26
|
+
source_path?: string;
|
|
27
|
+
safety_class: string;
|
|
28
|
+
operation_effect: string;
|
|
29
|
+
minimum_capability?: string;
|
|
30
|
+
capabilities: readonly string[];
|
|
31
|
+
uses_browser: boolean;
|
|
32
|
+
is_local_computer_use: boolean;
|
|
33
|
+
}
|
|
34
|
+
export interface ArchitectureCapabilityMatrixEntry {
|
|
35
|
+
surface: ArchitectureCapabilitySurface;
|
|
36
|
+
command_count: number;
|
|
37
|
+
adapter_commands: number;
|
|
38
|
+
core_commands: number;
|
|
39
|
+
write_commands: number;
|
|
40
|
+
auth_or_write_commands: number;
|
|
41
|
+
local_computer_use_commands: number;
|
|
42
|
+
source_path_coverage: {
|
|
43
|
+
present: number;
|
|
44
|
+
missing: number;
|
|
45
|
+
};
|
|
46
|
+
representative_commands: string[];
|
|
47
|
+
}
|
|
48
|
+
export interface ArchitectureWorkflowReadiness {
|
|
49
|
+
id: string;
|
|
50
|
+
label: string;
|
|
51
|
+
vehicle_assistant_analogy: string;
|
|
52
|
+
readiness: WorkflowReadinessStatus;
|
|
53
|
+
command_count: number;
|
|
54
|
+
action_command_count: number;
|
|
55
|
+
surfaces: ArchitectureCapabilitySurface[];
|
|
56
|
+
representative_commands: string[];
|
|
57
|
+
required_next_evidence: string[];
|
|
58
|
+
gap?: string;
|
|
59
|
+
}
|
|
60
|
+
export declare function surfacesForCapabilityEntry(entry: CapabilityMatrixInventoryEntry): ArchitectureCapabilitySurface[];
|
|
61
|
+
export declare function buildArchitectureCapabilityMatrix(entries: readonly CapabilityMatrixInventoryEntry[]): ArchitectureCapabilityMatrixEntry[];
|
|
62
|
+
export declare function buildArchitectureWorkflowReadiness(entries: readonly CapabilityMatrixInventoryEntry[]): ArchitectureWorkflowReadiness[];
|
|
63
|
+
//# sourceMappingURL=capability-matrix.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"capability-matrix.d.ts","sourceRoot":"","sources":["../../src/core/capability-matrix.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AAEH,eAAO,MAAM,mBAAmB,wEAOtB,CAAC;AAEX,MAAM,MAAM,6BAA6B,GACvC,CAAC,OAAO,mBAAmB,CAAC,CAAC,MAAM,CAAC,CAAC;AAEvC,MAAM,MAAM,uBAAuB,GAAG,WAAW,GAAG,SAAS,GAAG,KAAK,CAAC;AAEtE,MAAM,WAAW,8BAA8B;IAC7C,GAAG,EAAE,MAAM,CAAC;IACZ,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,MAAM,CAAC;IAChB,WAAW,EAAE,SAAS,GAAG,MAAM,CAAC;IAChC,YAAY,EAAE,MAAM,CAAC;IACrB,cAAc,EAAE,MAAM,CAAC;IACvB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,YAAY,EAAE,MAAM,CAAC;IACrB,gBAAgB,EAAE,MAAM,CAAC;IACzB,kBAAkB,CAAC,EAAE,MAAM,CAAC;IAC5B,YAAY,EAAE,SAAS,MAAM,EAAE,CAAC;IAChC,YAAY,EAAE,OAAO,CAAC;IACtB,qBAAqB,EAAE,OAAO,CAAC;CAChC;AAED,MAAM,WAAW,iCAAiC;IAChD,OAAO,EAAE,6BAA6B,CAAC;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