@jini-ai/agent-runtime 0.3.10 → 0.4.0
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 +103 -0
- package/README.md +34 -17
- package/dist/acp-model-probe.d.ts +6 -4
- package/dist/acp-model-probe.js +3 -3
- package/dist/agent-protocol/acp/account-failure.d.ts +4 -2
- package/dist/agent-protocol/acp/account-failure.js +1 -1
- package/dist/agent-protocol/acp/json.d.ts +6 -6
- package/dist/agent-protocol/acp/json.js +3 -3
- package/dist/agent-protocol/acp/models.d.ts +10 -5
- package/dist/agent-protocol/acp/models.js +32 -31
- package/dist/agent-protocol/acp/session-params.d.ts +3 -1
- package/dist/agent-protocol/acp/session-params.js +2 -1
- package/dist/agent-protocol/acp/session.d.ts +28 -22
- package/dist/agent-protocol/acp/session.js +181 -147
- package/dist/agent-protocol/acp/text-suppression.d.ts +1 -1
- package/dist/agent-protocol/acp/text-suppression.js +1 -1
- package/dist/agent-protocol/acp/types.d.ts +3 -2
- package/dist/agent-protocol/acp/updates.d.ts +11 -11
- package/dist/agent-protocol/acp/updates.js +2 -2
- package/dist/agent-protocol/core/json-line-stream.d.ts +24 -8
- package/dist/agent-protocol/core/json-line-stream.js +8 -8
- package/dist/agent-protocol/pi-rpc/events.d.ts +5 -1
- package/dist/agent-protocol/pi-rpc/events.js +36 -36
- package/dist/agent-protocol/pi-rpc/internal.d.ts +4 -1
- package/dist/agent-protocol/pi-rpc/models.d.ts +3 -1
- package/dist/agent-protocol/pi-rpc/models.js +1 -1
- package/dist/agent-protocol/pi-rpc/session.d.ts +1 -1
- package/dist/agent-protocol/pi-rpc/session.js +33 -32
- package/dist/amr-model-cache.d.ts +12 -4
- package/dist/amr-model-cache.js +17 -21
- package/dist/amr-profile-resolver.d.ts +3 -1
- package/dist/anthropic-live-models.js +0 -0
- package/dist/artifact-taxonomy.d.ts +6 -2
- package/dist/auth.d.ts +52 -15
- package/dist/auth.js +36 -36
- package/dist/claude-code-models.js +2 -2
- package/dist/claude-stream.d.ts +22 -3
- package/dist/claude-stream.js +24 -8
- package/dist/copilot-stream.d.ts +7 -3
- package/dist/copilot-stream.js +3 -3
- package/dist/defs/aider.d.ts +8 -1
- package/dist/defs/aider.js +2 -2
- package/dist/defs/amp.d.ts +8 -1
- package/dist/defs/amp.js +2 -2
- package/dist/defs/amr.d.ts +22 -6
- package/dist/defs/amr.js +23 -23
- package/dist/defs/antigravity.d.ts +15 -4
- package/dist/defs/antigravity.js +9 -8
- package/dist/defs/auggie.d.ts +4 -1
- package/dist/defs/auggie.js +1 -1
- package/dist/defs/claude.d.ts +12 -2
- package/dist/defs/claude.js +5 -5
- package/dist/defs/cline.d.ts +4 -1
- package/dist/defs/cline.js +1 -1
- package/dist/defs/codebuddy.d.ts +8 -1
- package/dist/defs/codebuddy.js +2 -2
- package/dist/defs/codex.d.ts +18 -4
- package/dist/defs/codex.js +7 -7
- package/dist/defs/copilot.d.ts +8 -1
- package/dist/defs/copilot.js +2 -2
- package/dist/defs/crush.d.ts +8 -1
- package/dist/defs/crush.js +1 -1
- package/dist/defs/cursor-agent.d.ts +14 -3
- package/dist/defs/cursor-agent.js +5 -5
- package/dist/defs/deepseek.d.ts +8 -1
- package/dist/defs/deepseek.js +2 -2
- package/dist/defs/devin.d.ts +12 -2
- package/dist/defs/devin.js +3 -3
- package/dist/defs/droid.d.ts +8 -1
- package/dist/defs/droid.js +1 -1
- package/dist/defs/gemini.d.ts +8 -1
- package/dist/defs/gemini.js +1 -1
- package/dist/defs/goose.d.ts +4 -1
- package/dist/defs/goose.js +1 -1
- package/dist/defs/grok-build.d.ts +11 -2
- package/dist/defs/grok-build.js +3 -3
- package/dist/defs/hermes.d.ts +4 -1
- package/dist/defs/hermes.js +2 -2
- package/dist/defs/kilo.d.ts +4 -1
- package/dist/defs/kilo.js +2 -2
- package/dist/defs/kimi.d.ts +4 -1
- package/dist/defs/kimi.js +2 -2
- package/dist/defs/kiro.d.ts +4 -1
- package/dist/defs/kiro.js +2 -2
- package/dist/defs/mimo.d.ts +8 -1
- package/dist/defs/mimo.js +2 -2
- package/dist/defs/opencode.d.ts +9 -2
- package/dist/defs/opencode.js +2 -2
- package/dist/defs/pi.d.ts +12 -2
- package/dist/defs/pi.js +9 -9
- package/dist/defs/qoder.d.ts +8 -1
- package/dist/defs/qoder.js +2 -2
- package/dist/defs/qwen.d.ts +8 -1
- package/dist/defs/qwen.js +2 -2
- package/dist/defs/reasonix.d.ts +4 -1
- package/dist/defs/reasonix.js +3 -3
- package/dist/defs/shared.d.ts +4 -2
- package/dist/defs/shared.js +2 -2
- package/dist/defs/trae-cli.d.ts +12 -2
- package/dist/defs/trae-cli.js +3 -3
- package/dist/defs/vibe.d.ts +4 -1
- package/dist/defs/vibe.js +2 -2
- package/dist/detection.d.ts +19 -4
- package/dist/detection.js +33 -33
- package/dist/diagnostics.d.ts +14 -3
- package/dist/diagnostics.js +5 -5
- package/dist/env.d.ts +16 -4
- package/dist/env.js +7 -7
- package/dist/executables.d.ts +24 -8
- package/dist/executables.js +13 -13
- package/dist/index.d.ts +228 -4
- package/dist/index.js +230 -6
- package/dist/invocation.d.ts +6 -1
- package/dist/invocation.js +2 -2
- package/dist/json-event-stream.d.ts +7 -2
- package/dist/json-event-stream.js +3 -3
- package/dist/launch.d.ts +12 -2
- package/dist/launch.js +3 -3
- package/dist/log-file.d.ts +4 -1
- package/dist/log-file.js +2 -2
- package/dist/mcp.d.ts +6 -3
- package/dist/mcp.js +1 -1
- package/dist/metadata.d.ts +7 -3
- package/dist/metadata.js +1 -1
- package/dist/mmd-routes.d.ts +22 -6
- package/dist/mmd-routes.js +14 -14
- package/dist/model-catalog-cache.d.ts +50 -0
- package/dist/model-catalog-cache.js +61 -0
- package/dist/model-loading-state.d.ts +10 -0
- package/dist/model-loading-state.js +23 -0
- package/dist/model-registry.d.ts +28 -7
- package/dist/model-registry.js +11 -8
- package/dist/models.d.ts +31 -6
- package/dist/models.js +6 -6
- package/dist/opencode-log.d.ts +12 -4
- package/dist/opencode-log.js +8 -8
- package/dist/paths.d.ts +6 -2
- package/dist/paths.js +3 -3
- package/dist/pi-models.d.ts +3 -1
- package/dist/pi-models.js +2 -2
- package/dist/prompt-budget.d.ts +17 -4
- package/dist/prompt-budget.js +3 -3
- package/dist/prompt-file.d.ts +5 -1
- package/dist/prompt-file.js +1 -1
- package/dist/providers/aihubmix.d.ts +34 -9
- package/dist/providers/aihubmix.js +26 -26
- package/dist/providers/anthropic-messages.d.ts +77 -20
- package/dist/providers/anthropic-messages.js +53 -50
- package/dist/providers/azure-chat.d.ts +21 -7
- package/dist/providers/azure-chat.js +18 -16
- package/dist/providers/connection-guard.d.ts +45 -31
- package/dist/providers/connection-guard.js +40 -143
- package/dist/providers/connection-test.d.ts +1 -1
- package/dist/providers/connection-test.js +13 -30
- package/dist/providers/elevenlabs.d.ts +7 -2
- package/dist/providers/elevenlabs.js +4 -4
- package/dist/providers/google-messages.d.ts +44 -10
- package/dist/providers/google-messages.js +36 -34
- package/dist/providers/google-schema.d.ts +26 -0
- package/dist/providers/google-schema.js +253 -0
- package/dist/providers/google.d.ts +21 -6
- package/dist/providers/google.js +10 -10
- package/dist/providers/index.d.ts +3 -2
- package/dist/providers/index.js +3 -2
- package/dist/providers/model-catalog.d.ts +1 -1
- package/dist/providers/model-catalog.js +14 -27
- package/dist/providers/oauth-callback-server.d.ts +1 -1
- package/dist/providers/oauth-callback-server.js +3 -2
- package/dist/providers/oauth-credentials.d.ts +7 -1
- package/dist/providers/oauth-credentials.js +5 -5
- package/dist/providers/oauth-provider.d.ts +2 -2
- package/dist/providers/oauth-provider.js +20 -25
- package/dist/providers/oauth-tokens.d.ts +26 -6
- package/dist/providers/oauth-tokens.js +9 -9
- package/dist/providers/ollama-chat.d.ts +66 -31
- package/dist/providers/ollama-chat.js +64 -61
- package/dist/providers/openai-chat.d.ts +77 -22
- package/dist/providers/openai-chat.js +71 -67
- package/dist/providers/pkce.d.ts +33 -20
- package/dist/providers/pkce.js +75 -146
- package/dist/providers/sse-decode.d.ts +3 -1
- package/dist/providers/sse-decode.js +1 -1
- package/dist/providers/token-params.d.ts +16 -5
- package/dist/providers/token-params.js +6 -6
- package/dist/providers/tool-turn-types.d.ts +89 -0
- package/dist/providers/tool-turn-types.js +2 -0
- package/dist/providers/tool-turn.d.ts +10 -0
- package/dist/providers/tool-turn.js +252 -0
- package/dist/qoder-stream.d.ts +7 -3
- package/dist/qoder-stream.js +3 -3
- package/dist/registry.d.ts +6 -2
- package/dist/registry.js +4 -4
- package/dist/resolution.d.ts +5 -1
- package/dist/resolution.js +3 -3
- package/dist/role-marker-guard.d.ts +9 -5
- package/dist/role-marker-guard.js +5 -5
- package/dist/terminal-launch.d.ts +6 -1
- package/dist/terminal-launch.js +2 -2
- package/dist/types.d.ts +22 -6
- package/package.json +43 -4
package/dist/defs/goose.js
CHANGED
|
@@ -15,7 +15,7 @@ export const gooseAgentDef = {
|
|
|
15
15
|
name: 'goose',
|
|
16
16
|
bin: 'goose',
|
|
17
17
|
versionArgs: ['--version'],
|
|
18
|
-
fetchModels: async (resolvedBin, env) => detectAcpModels({
|
|
18
|
+
fetchModels: async ({ resolvedBin, env }) => (({ bin, args, ...optionalArgs }) => detectAcpModels({ bin, args }, optionalArgs))({
|
|
19
19
|
bin: resolvedBin,
|
|
20
20
|
args: ['acp'],
|
|
21
21
|
env,
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
import type { RuntimeModelOption } from '../types.js';
|
|
2
|
-
export declare function parseGrokBuildModels(stdout
|
|
2
|
+
export declare function parseGrokBuildModels({ stdout }: {
|
|
3
|
+
stdout: string;
|
|
4
|
+
}): RuntimeModelOption[];
|
|
3
5
|
export declare const grokBuildAgentDef: {
|
|
4
6
|
id: string;
|
|
5
7
|
name: string;
|
|
@@ -12,7 +14,14 @@ export declare const grokBuildAgentDef: {
|
|
|
12
14
|
parse: typeof parseGrokBuildModels;
|
|
13
15
|
};
|
|
14
16
|
fallbackModels: RuntimeModelOption[];
|
|
15
|
-
buildArgs: (
|
|
17
|
+
buildArgs: ({ prompt: _prompt, imagePaths: _imagePaths }: {
|
|
18
|
+
prompt: string;
|
|
19
|
+
imagePaths: string[];
|
|
20
|
+
}, { extraAllowedDirs: _extra, options, runtimeContext }?: {
|
|
21
|
+
extraAllowedDirs?: string[];
|
|
22
|
+
options?: import("../types.js").RuntimeBuildOptions;
|
|
23
|
+
runtimeContext?: import("../types.js").RuntimeContext;
|
|
24
|
+
} | undefined) => string[];
|
|
16
25
|
reasoningOptions: {
|
|
17
26
|
id: string;
|
|
18
27
|
label: string;
|
package/dist/defs/grok-build.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Ported from OD's `apps/daemon/src/runtimes/defs/grok-build.ts` with
|
|
3
3
|
* several product-named comment mentions reworded to generic
|
|
4
|
-
* host-application phrasing (no behavior change; see `
|
|
4
|
+
* host-application phrasing (no behavior change; see `archived provenance ledger` for
|
|
5
5
|
* the exact original wording).
|
|
6
6
|
*/
|
|
7
7
|
import { DEFAULT_MODEL_OPTION } from './shared.js';
|
|
8
8
|
const GROK_MODEL_ID_RE = /^\*?\s*-?\s*(grok-[a-z0-9][a-z0-9._-]*)(?:\s+\(default\))?\s*$/i;
|
|
9
|
-
export function parseGrokBuildModels(stdout) {
|
|
9
|
+
export function parseGrokBuildModels({ stdout }) {
|
|
10
10
|
const seen = new Set();
|
|
11
11
|
const out = [DEFAULT_MODEL_OPTION];
|
|
12
12
|
for (const rawLine of String(stdout || '').split('\n')) {
|
|
@@ -76,7 +76,7 @@ export const grokBuildAgentDef = {
|
|
|
76
76
|
// Grok Build CLI v0.1.212+ enforces `-p, --single <PROMPT>` as
|
|
77
77
|
// value-required, while a host's composed prompts can exceed safe argv
|
|
78
78
|
// budgets. Use the CLI's explicit prompt-file transport instead.
|
|
79
|
-
buildArgs: (_prompt, _imagePaths, _extra = [], options = {}, runtimeContext = {}) => {
|
|
79
|
+
buildArgs: ({ prompt: _prompt, imagePaths: _imagePaths }, { extraAllowedDirs: _extra = [], options = {}, runtimeContext = {} } = {}) => {
|
|
80
80
|
if (!runtimeContext.promptFilePath) {
|
|
81
81
|
throw new Error('grok-build requires runtimeContext.promptFilePath');
|
|
82
82
|
}
|
package/dist/defs/hermes.d.ts
CHANGED
|
@@ -3,7 +3,10 @@ export declare const hermesAgentDef: {
|
|
|
3
3
|
name: string;
|
|
4
4
|
bin: string;
|
|
5
5
|
versionArgs: string[];
|
|
6
|
-
fetchModels: (resolvedBin
|
|
6
|
+
fetchModels: ({ resolvedBin, env }: {
|
|
7
|
+
resolvedBin: string;
|
|
8
|
+
env: import("../types.js").RuntimeEnv;
|
|
9
|
+
}) => Promise<import("../types.js").RuntimeModelOption[]>;
|
|
7
10
|
fallbackModels: import("../types.js").RuntimeModelOption[];
|
|
8
11
|
buildArgs: () => string[];
|
|
9
12
|
streamFormat: string;
|
package/dist/defs/hermes.js
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
/** Ported verbatim from OD's `apps/daemon/src/runtimes/defs/hermes.ts` (import path adjusted only). See `
|
|
1
|
+
/** Ported verbatim from OD's `apps/daemon/src/runtimes/defs/hermes.ts` (import path adjusted only). See `archived provenance ledger`. */
|
|
2
2
|
import { detectAcpModels, DEFAULT_MODEL_OPTION } from './shared.js';
|
|
3
3
|
export const hermesAgentDef = {
|
|
4
4
|
id: 'hermes',
|
|
5
5
|
name: 'Hermes',
|
|
6
6
|
bin: 'hermes',
|
|
7
7
|
versionArgs: ['--version'],
|
|
8
|
-
fetchModels: async (resolvedBin, env) => detectAcpModels({
|
|
8
|
+
fetchModels: async ({ resolvedBin, env }) => (({ bin, args, ...optionalArgs }) => detectAcpModels({ bin, args }, optionalArgs))({
|
|
9
9
|
bin: resolvedBin,
|
|
10
10
|
args: ['acp', '--accept-hooks'],
|
|
11
11
|
env,
|
package/dist/defs/kilo.d.ts
CHANGED
|
@@ -3,7 +3,10 @@ export declare const kiloAgentDef: {
|
|
|
3
3
|
name: string;
|
|
4
4
|
bin: string;
|
|
5
5
|
versionArgs: string[];
|
|
6
|
-
fetchModels: (resolvedBin
|
|
6
|
+
fetchModels: ({ resolvedBin, env }: {
|
|
7
|
+
resolvedBin: string;
|
|
8
|
+
env: import("../types.js").RuntimeEnv;
|
|
9
|
+
}) => Promise<import("../types.js").RuntimeModelOption[]>;
|
|
7
10
|
fallbackModels: import("../types.js").RuntimeModelOption[];
|
|
8
11
|
buildArgs: () => string[];
|
|
9
12
|
streamFormat: string;
|
package/dist/defs/kilo.js
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
/** Ported verbatim from OD's `apps/daemon/src/runtimes/defs/kilo.ts` (import path adjusted only). See `
|
|
1
|
+
/** Ported verbatim from OD's `apps/daemon/src/runtimes/defs/kilo.ts` (import path adjusted only). See `archived provenance ledger`. */
|
|
2
2
|
import { detectAcpModels, DEFAULT_MODEL_OPTION } from './shared.js';
|
|
3
3
|
export const kiloAgentDef = {
|
|
4
4
|
id: 'kilo',
|
|
5
5
|
name: 'Kilo',
|
|
6
6
|
bin: 'kilo',
|
|
7
7
|
versionArgs: ['--version'],
|
|
8
|
-
fetchModels: async (resolvedBin, env) => detectAcpModels({
|
|
8
|
+
fetchModels: async ({ resolvedBin, env }) => (({ bin, args, ...optionalArgs }) => detectAcpModels({ bin, args }, optionalArgs))({
|
|
9
9
|
bin: resolvedBin,
|
|
10
10
|
args: ['acp'],
|
|
11
11
|
env,
|
package/dist/defs/kimi.d.ts
CHANGED
|
@@ -4,7 +4,10 @@ export declare const kimiAgentDef: {
|
|
|
4
4
|
bin: string;
|
|
5
5
|
versionArgs: string[];
|
|
6
6
|
fallbackModels: import("../types.js").RuntimeModelOption[];
|
|
7
|
-
fetchModels: (resolvedBin
|
|
7
|
+
fetchModels: ({ resolvedBin, env }: {
|
|
8
|
+
resolvedBin: string;
|
|
9
|
+
env: import("../types.js").RuntimeEnv;
|
|
10
|
+
}) => Promise<import("../types.js").RuntimeModelOption[]>;
|
|
8
11
|
buildArgs: () => string[];
|
|
9
12
|
streamFormat: string;
|
|
10
13
|
mcpDiscovery: string;
|
package/dist/defs/kimi.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/** Ported verbatim from OD's `apps/daemon/src/runtimes/defs/kimi.ts` (import path adjusted only). See `
|
|
1
|
+
/** Ported verbatim from OD's `apps/daemon/src/runtimes/defs/kimi.ts` (import path adjusted only). See `archived provenance ledger`. */
|
|
2
2
|
import { detectAcpModels, DEFAULT_MODEL_OPTION } from './shared.js';
|
|
3
3
|
export const kimiAgentDef = {
|
|
4
4
|
id: 'kimi',
|
|
@@ -11,7 +11,7 @@ export const kimiAgentDef = {
|
|
|
11
11
|
{ id: 'moonshot-v1-8k', label: 'moonshot-v1-8k' },
|
|
12
12
|
{ id: 'moonshot-v1-32k', label: 'moonshot-v1-32k' },
|
|
13
13
|
],
|
|
14
|
-
fetchModels: async (resolvedBin, env) => detectAcpModels({
|
|
14
|
+
fetchModels: async ({ resolvedBin, env }) => (({ bin, args, ...optionalArgs }) => detectAcpModels({ bin, args }, optionalArgs))({
|
|
15
15
|
bin: resolvedBin,
|
|
16
16
|
args: ['acp'],
|
|
17
17
|
env,
|
package/dist/defs/kiro.d.ts
CHANGED
|
@@ -3,7 +3,10 @@ export declare const kiroAgentDef: {
|
|
|
3
3
|
name: string;
|
|
4
4
|
bin: string;
|
|
5
5
|
versionArgs: string[];
|
|
6
|
-
fetchModels: (resolvedBin
|
|
6
|
+
fetchModels: ({ resolvedBin, env }: {
|
|
7
|
+
resolvedBin: string;
|
|
8
|
+
env: import("../types.js").RuntimeEnv;
|
|
9
|
+
}) => Promise<import("../types.js").RuntimeModelOption[]>;
|
|
7
10
|
fallbackModels: import("../types.js").RuntimeModelOption[];
|
|
8
11
|
buildArgs: () => string[];
|
|
9
12
|
streamFormat: string;
|
package/dist/defs/kiro.js
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
/** Ported verbatim from OD's `apps/daemon/src/runtimes/defs/kiro.ts` (import path adjusted only). See `
|
|
1
|
+
/** Ported verbatim from OD's `apps/daemon/src/runtimes/defs/kiro.ts` (import path adjusted only). See `archived provenance ledger`. */
|
|
2
2
|
import { detectAcpModels, DEFAULT_MODEL_OPTION } from './shared.js';
|
|
3
3
|
export const kiroAgentDef = {
|
|
4
4
|
id: 'kiro',
|
|
5
5
|
name: 'Kiro CLI',
|
|
6
6
|
bin: 'kiro-cli',
|
|
7
7
|
versionArgs: ['--version'],
|
|
8
|
-
fetchModels: async (resolvedBin, env) => detectAcpModels({
|
|
8
|
+
fetchModels: async ({ resolvedBin, env }) => (({ bin, args, ...optionalArgs }) => detectAcpModels({ bin, args }, optionalArgs))({
|
|
9
9
|
bin: resolvedBin,
|
|
10
10
|
args: ['acp'],
|
|
11
11
|
env,
|
package/dist/defs/mimo.d.ts
CHANGED
|
@@ -4,7 +4,14 @@ export declare const mimoAgentDef: {
|
|
|
4
4
|
bin: string;
|
|
5
5
|
versionArgs: string[];
|
|
6
6
|
fallbackModels: import("../types.js").RuntimeModelOption[];
|
|
7
|
-
buildArgs: (
|
|
7
|
+
buildArgs: ({ prompt: _prompt, imagePaths: _imagePaths }: {
|
|
8
|
+
prompt: string;
|
|
9
|
+
imagePaths: string[];
|
|
10
|
+
}, { extraAllowedDirs: _extra, options }?: {
|
|
11
|
+
extraAllowedDirs?: string[];
|
|
12
|
+
options?: import("../types.js").RuntimeBuildOptions;
|
|
13
|
+
runtimeContext?: import("../types.js").RuntimeContext;
|
|
14
|
+
} | undefined) => string[];
|
|
8
15
|
promptViaStdin: true;
|
|
9
16
|
streamFormat: string;
|
|
10
17
|
eventParser: string;
|
package/dist/defs/mimo.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/** Ported verbatim from OD's `apps/daemon/src/runtimes/defs/mimo.ts` (import path adjusted only). See `
|
|
1
|
+
/** Ported verbatim from OD's `apps/daemon/src/runtimes/defs/mimo.ts` (import path adjusted only). See `archived provenance ledger`. */
|
|
2
2
|
import { DEFAULT_MODEL_OPTION } from './shared.js';
|
|
3
3
|
export const mimoAgentDef = {
|
|
4
4
|
id: 'mimo',
|
|
@@ -6,7 +6,7 @@ export const mimoAgentDef = {
|
|
|
6
6
|
bin: 'mimo',
|
|
7
7
|
versionArgs: ['--version'],
|
|
8
8
|
fallbackModels: [DEFAULT_MODEL_OPTION],
|
|
9
|
-
buildArgs: (_prompt, _imagePaths, _extra, options = {}) => {
|
|
9
|
+
buildArgs: ({ prompt: _prompt, imagePaths: _imagePaths }, { extraAllowedDirs: _extra, options = {} } = {}) => {
|
|
10
10
|
const args = ['run', '--format', 'json'];
|
|
11
11
|
if (options.model && options.model !== 'default') {
|
|
12
12
|
args.push('--model', options.model);
|
package/dist/defs/opencode.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/** Ported verbatim from OD's `apps/daemon/src/runtimes/defs/opencode.ts` (import path adjusted only). See `
|
|
1
|
+
/** Ported verbatim from OD's `apps/daemon/src/runtimes/defs/opencode.ts` (import path adjusted only). See `archived provenance ledger`. */
|
|
2
2
|
import { parseLineSeparatedModels } from './shared.js';
|
|
3
3
|
export declare const opencodeAgentDef: {
|
|
4
4
|
id: string;
|
|
@@ -17,7 +17,14 @@ export declare const opencodeAgentDef: {
|
|
|
17
17
|
};
|
|
18
18
|
fallbackModels: import("../types.js").RuntimeModelOption[];
|
|
19
19
|
fallbackModelsAssertedAt: string;
|
|
20
|
-
buildArgs: (
|
|
20
|
+
buildArgs: ({ prompt: _prompt, imagePaths: _imagePaths }: {
|
|
21
|
+
prompt: string;
|
|
22
|
+
imagePaths: string[];
|
|
23
|
+
}, { extraAllowedDirs: _extra, options, runtimeContext }?: {
|
|
24
|
+
extraAllowedDirs?: string[];
|
|
25
|
+
options?: import("../types.js").RuntimeBuildOptions;
|
|
26
|
+
runtimeContext?: import("../types.js").RuntimeContext;
|
|
27
|
+
} | undefined) => string[];
|
|
21
28
|
promptViaStdin: true;
|
|
22
29
|
resumesSessionViaCli: true;
|
|
23
30
|
capturesSessionIdFromStream: true;
|
package/dist/defs/opencode.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/** Ported verbatim from OD's `apps/daemon/src/runtimes/defs/opencode.ts` (import path adjusted only). See `
|
|
1
|
+
/** Ported verbatim from OD's `apps/daemon/src/runtimes/defs/opencode.ts` (import path adjusted only). See `archived provenance ledger`. */
|
|
2
2
|
import { DEFAULT_MODEL_OPTION, parseLineSeparatedModels } from './shared.js';
|
|
3
3
|
import { agentCapabilities } from '../capabilities.js';
|
|
4
4
|
const SKIP_PERMISSIONS_FLAG = '--dangerously-skip-permissions';
|
|
@@ -47,7 +47,7 @@ export const opencodeAgentDef = {
|
|
|
47
47
|
// avoid Windows `spawn ENAMETOOLONG` while preserving OpenCode's
|
|
48
48
|
// structured stream. A literal `-` is parsed as a positional message by
|
|
49
49
|
// OpenCode 1.14.x and can surface as "Session not found".
|
|
50
|
-
buildArgs: (_prompt, _imagePaths, _extra, options = {}, runtimeContext = {}) => {
|
|
50
|
+
buildArgs: ({ prompt: _prompt, imagePaths: _imagePaths }, { extraAllowedDirs: _extra, options = {}, runtimeContext = {} } = {}) => {
|
|
51
51
|
const args = [
|
|
52
52
|
'run',
|
|
53
53
|
'--format',
|
package/dist/defs/pi.d.ts
CHANGED
|
@@ -4,14 +4,24 @@ export declare const piAgentDef: {
|
|
|
4
4
|
bin: string;
|
|
5
5
|
versionArgs: string[];
|
|
6
6
|
versionProbeTimeoutMs: number;
|
|
7
|
-
fetchModels: (resolvedBin
|
|
7
|
+
fetchModels: ({ resolvedBin, env }: {
|
|
8
|
+
resolvedBin: string;
|
|
9
|
+
env: import("../types.js").RuntimeEnv;
|
|
10
|
+
}) => Promise<import("../types.js").RuntimeModelOption[] | null>;
|
|
8
11
|
fallbackModels: import("../types.js").RuntimeModelOption[];
|
|
9
12
|
fallbackModelsAssertedAt: string;
|
|
10
13
|
reasoningOptions: {
|
|
11
14
|
id: string;
|
|
12
15
|
label: string;
|
|
13
16
|
}[];
|
|
14
|
-
buildArgs: (
|
|
17
|
+
buildArgs: ({ prompt: _prompt, imagePaths: _imagePaths }: {
|
|
18
|
+
prompt: string;
|
|
19
|
+
imagePaths: string[];
|
|
20
|
+
}, { extraAllowedDirs, options, runtimeContext }?: {
|
|
21
|
+
extraAllowedDirs?: string[];
|
|
22
|
+
options?: import("../types.js").RuntimeBuildOptions;
|
|
23
|
+
runtimeContext?: import("../types.js").RuntimeContext;
|
|
24
|
+
} | undefined) => string[];
|
|
15
25
|
promptViaStdin: true;
|
|
16
26
|
streamFormat: string;
|
|
17
27
|
imageDelivery: "native";
|
package/dist/defs/pi.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/** Ported verbatim from OD's `apps/daemon/src/runtimes/defs/pi.ts` (import path adjusted only). See `
|
|
1
|
+
/** Ported verbatim from OD's `apps/daemon/src/runtimes/defs/pi.ts` (import path adjusted only). See `archived provenance ledger`. */
|
|
2
2
|
import path from 'node:path';
|
|
3
3
|
import { DEFAULT_MODEL_OPTION, execAgentFile, parsePiModels } from './shared.js';
|
|
4
4
|
export const piAgentDef = {
|
|
@@ -13,14 +13,14 @@ export const piAgentDef = {
|
|
|
13
13
|
versionProbeTimeoutMs: 15_000,
|
|
14
14
|
// `pi --list-models` prints a TSV table to stderr (not stdout),
|
|
15
15
|
// so we use a custom fetchModels that reads stderr.
|
|
16
|
-
fetchModels: async (resolvedBin, env) => {
|
|
16
|
+
fetchModels: async ({ resolvedBin, env }) => {
|
|
17
17
|
try {
|
|
18
|
-
const { stderr } = await execAgentFile(resolvedBin, ['--list-models'], {
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
const parsed = parsePiModels(stderr);
|
|
18
|
+
const { stderr } = await execAgentFile({ command: resolvedBin, args: ['--list-models'] }, { options: {
|
|
19
|
+
env,
|
|
20
|
+
timeout: 60_000, // Windows: 20s exceeded under parallel detection load
|
|
21
|
+
maxBuffer: 8 * 1024 * 1024,
|
|
22
|
+
} });
|
|
23
|
+
const parsed = parsePiModels({ stdout: stderr });
|
|
24
24
|
if (!parsed || parsed.length === 0)
|
|
25
25
|
return null;
|
|
26
26
|
return parsed;
|
|
@@ -64,7 +64,7 @@ export const piAgentDef = {
|
|
|
64
64
|
// pi's RPC mode drives the entire conversation over stdio JSON-RPC.
|
|
65
65
|
// The daemon sends a `prompt` command and pi streams back typed events.
|
|
66
66
|
// No prompt in argv — avoids ENAMETOOLONG and keeps the protocol clean.
|
|
67
|
-
buildArgs: (_prompt, _imagePaths, extraAllowedDirs = [], options = {}, runtimeContext = {}) => {
|
|
67
|
+
buildArgs: ({ prompt: _prompt, imagePaths: _imagePaths }, { extraAllowedDirs = [], options = {}, runtimeContext = {} } = {}) => {
|
|
68
68
|
const args = ['--mode', 'rpc'];
|
|
69
69
|
if (options.model && options.model !== 'default') {
|
|
70
70
|
// pi --model accepts patterns ("sonnet", "anthropic/claude-sonnet-4-5",
|
package/dist/defs/qoder.d.ts
CHANGED
|
@@ -4,7 +4,14 @@ export declare const qoderAgentDef: {
|
|
|
4
4
|
bin: string;
|
|
5
5
|
versionArgs: string[];
|
|
6
6
|
fallbackModels: import("../types.js").RuntimeModelOption[];
|
|
7
|
-
buildArgs: (
|
|
7
|
+
buildArgs: ({ prompt: _prompt, imagePaths }: {
|
|
8
|
+
prompt: string;
|
|
9
|
+
imagePaths: string[];
|
|
10
|
+
}, { extraAllowedDirs, options, runtimeContext }?: {
|
|
11
|
+
extraAllowedDirs?: string[];
|
|
12
|
+
options?: import("../types.js").RuntimeBuildOptions;
|
|
13
|
+
runtimeContext?: import("../types.js").RuntimeContext;
|
|
14
|
+
} | undefined) => string[];
|
|
8
15
|
promptViaStdin: true;
|
|
9
16
|
streamFormat: string;
|
|
10
17
|
imageDelivery: "native";
|
package/dist/defs/qoder.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/** Ported verbatim from OD's `apps/daemon/src/runtimes/defs/qoder.ts` (import path adjusted only). See `
|
|
1
|
+
/** Ported verbatim from OD's `apps/daemon/src/runtimes/defs/qoder.ts` (import path adjusted only). See `archived provenance ledger`. */
|
|
2
2
|
import path from 'node:path';
|
|
3
3
|
import { DEFAULT_MODEL_OPTION } from './shared.js';
|
|
4
4
|
export const qoderAgentDef = {
|
|
@@ -23,7 +23,7 @@ export const qoderAgentDef = {
|
|
|
23
23
|
// QODER_PERSONAL_ACCESS_TOKEN for automation. Do not add that token to
|
|
24
24
|
// static adapter env; unlike Gemini's workspace trust flag it is a user
|
|
25
25
|
// secret and already flows through the inherited process environment.
|
|
26
|
-
buildArgs: (_prompt, imagePaths, extraAllowedDirs = [], options = {}, runtimeContext = {}) => {
|
|
26
|
+
buildArgs: ({ prompt: _prompt, imagePaths }, { extraAllowedDirs = [], options = {}, runtimeContext = {} } = {}) => {
|
|
27
27
|
const args = [
|
|
28
28
|
'-p',
|
|
29
29
|
'--output-format',
|
package/dist/defs/qwen.d.ts
CHANGED
|
@@ -4,7 +4,14 @@ export declare const qwenAgentDef: {
|
|
|
4
4
|
bin: string;
|
|
5
5
|
versionArgs: string[];
|
|
6
6
|
fallbackModels: import("../types.js").RuntimeModelOption[];
|
|
7
|
-
buildArgs: (
|
|
7
|
+
buildArgs: ({ prompt: _prompt, imagePaths: _imagePaths }: {
|
|
8
|
+
prompt: string;
|
|
9
|
+
imagePaths: string[];
|
|
10
|
+
}, { extraAllowedDirs: _extra, options }?: {
|
|
11
|
+
extraAllowedDirs?: string[];
|
|
12
|
+
options?: import("../types.js").RuntimeBuildOptions;
|
|
13
|
+
runtimeContext?: import("../types.js").RuntimeContext;
|
|
14
|
+
} | undefined) => string[];
|
|
8
15
|
promptViaStdin: true;
|
|
9
16
|
streamFormat: string;
|
|
10
17
|
};
|
package/dist/defs/qwen.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/** Ported verbatim from OD's `apps/daemon/src/runtimes/defs/qwen.ts` (import path adjusted only). See `
|
|
1
|
+
/** Ported verbatim from OD's `apps/daemon/src/runtimes/defs/qwen.ts` (import path adjusted only). See `archived provenance ledger`. */
|
|
2
2
|
import { DEFAULT_MODEL_OPTION } from './shared.js';
|
|
3
3
|
export const qwenAgentDef = {
|
|
4
4
|
id: 'qwen',
|
|
@@ -15,7 +15,7 @@ export const qwenAgentDef = {
|
|
|
15
15
|
// Gemini-CLI fork and supports the same `--yolo` non-interactive mode.
|
|
16
16
|
// Qwen Code reads from piped stdin when no positional prompt is supplied.
|
|
17
17
|
// Current Qwen treats/rejects a bare `-` rather than needing it as a stdin sentinel.
|
|
18
|
-
buildArgs: (_prompt, _imagePaths, _extra, options = {}) => {
|
|
18
|
+
buildArgs: ({ prompt: _prompt, imagePaths: _imagePaths }, { extraAllowedDirs: _extra, options = {} } = {}) => {
|
|
19
19
|
const args = [];
|
|
20
20
|
// See `RuntimeBuildOptions.permissionMode`'s doc: bypass is the default (unchanged
|
|
21
21
|
// behavior) unless a caller explicitly opts into a restricted run.
|
package/dist/defs/reasonix.d.ts
CHANGED
|
@@ -4,7 +4,10 @@ export declare const reasonixAgentDef: {
|
|
|
4
4
|
bin: string;
|
|
5
5
|
fallbackBins: string[];
|
|
6
6
|
versionArgs: string[];
|
|
7
|
-
fetchModels: (resolvedBin
|
|
7
|
+
fetchModels: ({ resolvedBin, env }: {
|
|
8
|
+
resolvedBin: string;
|
|
9
|
+
env: import("../types.js").RuntimeEnv;
|
|
10
|
+
}) => Promise<import("../types.js").RuntimeModelOption[]>;
|
|
8
11
|
buildArgs: () => string[];
|
|
9
12
|
streamFormat: string;
|
|
10
13
|
mcpDiscovery: string;
|
package/dist/defs/reasonix.js
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* product-specific system-prompt block via
|
|
5
5
|
* `env.REASONIX_ACP_SYSTEM_APPEND` — a `DESIGN_INSTRUCTIONS` constant that
|
|
6
6
|
* literally named the host product and instructed the model to wrap output
|
|
7
|
-
* in that product's own artifact-tag convention (see `
|
|
7
|
+
* in that product's own artifact-tag convention (see `archived provenance ledger` for
|
|
8
8
|
* the exact original text). That is genuine product-specific prompt
|
|
9
9
|
* content baked into what's supposed to be a pure declarative def literal,
|
|
10
10
|
* not the generic ACP-transport config the rest of this file is. It is
|
|
@@ -19,7 +19,7 @@
|
|
|
19
19
|
* central dispatch every def's overlay delivery goes through) and
|
|
20
20
|
* `computeChildEnv`, not through this file's own static `env` object
|
|
21
21
|
* below (that one is fixed at def-load time, computed once; the overlay
|
|
22
|
-
* varies per run and per host). See `
|
|
22
|
+
* varies per run and per host). See `archived provenance ledger`.
|
|
23
23
|
*/
|
|
24
24
|
import os from 'node:os';
|
|
25
25
|
import path from 'node:path';
|
|
@@ -40,7 +40,7 @@ export const reasonixAgentDef = {
|
|
|
40
40
|
bin: 'reasonix',
|
|
41
41
|
fallbackBins: ['dsnix'],
|
|
42
42
|
versionArgs: ['--version'],
|
|
43
|
-
fetchModels: async (resolvedBin, env) => detectAcpModels({
|
|
43
|
+
fetchModels: async ({ resolvedBin, env }) => (({ bin, args, ...optionalArgs }) => detectAcpModels({ bin, args }, optionalArgs))({
|
|
44
44
|
bin: resolvedBin,
|
|
45
45
|
args: ['acp'],
|
|
46
46
|
env,
|
package/dist/defs/shared.d.ts
CHANGED
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
* Ported from OD's `apps/daemon/src/runtimes/defs/shared.ts` — the origin
|
|
11
11
|
* imported `detectAcpModels` from `../../acp.js` and `parsePiModels` from
|
|
12
12
|
* `../../pi-rpc.js` directly; here they come from this package's own
|
|
13
|
-
* port/vendor modules instead. See `
|
|
13
|
+
* port/vendor modules instead. See `archived provenance ledger`.
|
|
14
14
|
*/
|
|
15
15
|
import { detectAcpModels } from '../acp-model-probe.js';
|
|
16
16
|
import { parsePiModels } from '../pi-models.js';
|
|
@@ -49,5 +49,7 @@ export { detectAcpModels, parsePiModels, execAgentFile, DEFAULT_MODEL_OPTION };
|
|
|
49
49
|
*/
|
|
50
50
|
export declare function buildClaudeMcpConfigArgs(runtimeContext: RuntimeContext): string[];
|
|
51
51
|
export declare function clampCodexReasoning(modelId: string | null | undefined, effort: string | null | undefined): string | null | undefined;
|
|
52
|
-
export declare function parseLineSeparatedModels(stdout
|
|
52
|
+
export declare function parseLineSeparatedModels({ stdout }: {
|
|
53
|
+
stdout: string;
|
|
54
|
+
}): RuntimeModelOption[];
|
|
53
55
|
//# sourceMappingURL=shared.d.ts.map
|
package/dist/defs/shared.js
CHANGED
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
* Ported from OD's `apps/daemon/src/runtimes/defs/shared.ts` — the origin
|
|
11
11
|
* imported `detectAcpModels` from `../../acp.js` and `parsePiModels` from
|
|
12
12
|
* `../../pi-rpc.js` directly; here they come from this package's own
|
|
13
|
-
* port/vendor modules instead. See `
|
|
13
|
+
* port/vendor modules instead. See `archived provenance ledger`.
|
|
14
14
|
*/
|
|
15
15
|
import { detectAcpModels } from '../acp-model-probe.js';
|
|
16
16
|
import { parsePiModels } from '../pi-models.js';
|
|
@@ -74,7 +74,7 @@ export function clampCodexReasoning(modelId, effort) {
|
|
|
74
74
|
}
|
|
75
75
|
// Parse one-id-per-line stdout from `<cli> models` and prepend the synthetic
|
|
76
76
|
// default option. Used by opencode / cursor-agent.
|
|
77
|
-
export function parseLineSeparatedModels(stdout) {
|
|
77
|
+
export function parseLineSeparatedModels({ stdout }) {
|
|
78
78
|
const ids = String(stdout || '')
|
|
79
79
|
.split('\n')
|
|
80
80
|
.map((line) => line.trim())
|
package/dist/defs/trae-cli.d.ts
CHANGED
|
@@ -4,9 +4,19 @@ export declare const traeCliAgentDef: {
|
|
|
4
4
|
bin: string;
|
|
5
5
|
versionArgs: string[];
|
|
6
6
|
versionProbeTimeoutMs: number;
|
|
7
|
-
fetchModels: (resolvedBin
|
|
7
|
+
fetchModels: ({ resolvedBin, env }: {
|
|
8
|
+
resolvedBin: string;
|
|
9
|
+
env: import("../types.js").RuntimeEnv;
|
|
10
|
+
}) => Promise<import("../types.js").RuntimeModelOption[]>;
|
|
8
11
|
fallbackModels: import("../types.js").RuntimeModelOption[];
|
|
9
|
-
buildArgs: (
|
|
12
|
+
buildArgs: ({ prompt: _prompt, imagePaths: _imagePaths }: {
|
|
13
|
+
prompt: string;
|
|
14
|
+
imagePaths: string[];
|
|
15
|
+
}, { extraAllowedDirs: _extra, options }?: {
|
|
16
|
+
extraAllowedDirs?: string[];
|
|
17
|
+
options?: import("../types.js").RuntimeBuildOptions;
|
|
18
|
+
runtimeContext?: import("../types.js").RuntimeContext;
|
|
19
|
+
} | undefined) => string[];
|
|
10
20
|
streamFormat: string;
|
|
11
21
|
mcpDiscovery: string;
|
|
12
22
|
externalMcpInjection: "acp-merge";
|
package/dist/defs/trae-cli.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/** Ported verbatim from OD's `apps/daemon/src/runtimes/defs/trae-cli.ts` (import path adjusted only). See `
|
|
1
|
+
/** Ported verbatim from OD's `apps/daemon/src/runtimes/defs/trae-cli.ts` (import path adjusted only). See `archived provenance ledger`. */
|
|
2
2
|
import { detectAcpModels, DEFAULT_MODEL_OPTION } from './shared.js';
|
|
3
3
|
export const traeCliAgentDef = {
|
|
4
4
|
id: 'trae-cli',
|
|
@@ -6,7 +6,7 @@ export const traeCliAgentDef = {
|
|
|
6
6
|
bin: 'traecli',
|
|
7
7
|
versionArgs: ['--version'],
|
|
8
8
|
versionProbeTimeoutMs: 10_000,
|
|
9
|
-
fetchModels: async (resolvedBin, env) => detectAcpModels({
|
|
9
|
+
fetchModels: async ({ resolvedBin, env }) => (({ bin, args, ...optionalArgs }) => detectAcpModels({ bin, args }, optionalArgs))({
|
|
10
10
|
bin: resolvedBin,
|
|
11
11
|
args: ['acp', 'serve'],
|
|
12
12
|
env,
|
|
@@ -16,7 +16,7 @@ export const traeCliAgentDef = {
|
|
|
16
16
|
fallbackModels: [DEFAULT_MODEL_OPTION],
|
|
17
17
|
// See `RuntimeBuildOptions.permissionMode`'s doc: bypass is the default (unchanged
|
|
18
18
|
// behavior) unless a caller explicitly opts into a restricted run.
|
|
19
|
-
buildArgs: (_prompt, _imagePaths, _extra, options = {}) => options.permissionMode === 'restricted' ? ['acp', 'serve'] : ['acp', 'serve', '--yolo'],
|
|
19
|
+
buildArgs: ({ prompt: _prompt, imagePaths: _imagePaths }, { extraAllowedDirs: _extra, options = {} } = {}) => options.permissionMode === 'restricted' ? ['acp', 'serve'] : ['acp', 'serve', '--yolo'],
|
|
20
20
|
streamFormat: 'acp-json-rpc',
|
|
21
21
|
mcpDiscovery: 'mature-acp',
|
|
22
22
|
externalMcpInjection: 'acp-merge',
|
package/dist/defs/vibe.d.ts
CHANGED
|
@@ -3,7 +3,10 @@ export declare const vibeAgentDef: {
|
|
|
3
3
|
name: string;
|
|
4
4
|
bin: string;
|
|
5
5
|
versionArgs: string[];
|
|
6
|
-
fetchModels: (resolvedBin
|
|
6
|
+
fetchModels: ({ resolvedBin, env }: {
|
|
7
|
+
resolvedBin: string;
|
|
8
|
+
env: import("../types.js").RuntimeEnv;
|
|
9
|
+
}) => Promise<import("../types.js").RuntimeModelOption[]>;
|
|
7
10
|
fallbackModels: import("../types.js").RuntimeModelOption[];
|
|
8
11
|
buildArgs: () => never[];
|
|
9
12
|
streamFormat: string;
|
package/dist/defs/vibe.js
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
/** Ported verbatim from OD's `apps/daemon/src/runtimes/defs/vibe.ts` (import path adjusted only). See `
|
|
1
|
+
/** Ported verbatim from OD's `apps/daemon/src/runtimes/defs/vibe.ts` (import path adjusted only). See `archived provenance ledger`. */
|
|
2
2
|
import { detectAcpModels, DEFAULT_MODEL_OPTION } from './shared.js';
|
|
3
3
|
export const vibeAgentDef = {
|
|
4
4
|
id: 'vibe',
|
|
5
5
|
name: 'Mistral Vibe CLI',
|
|
6
6
|
bin: 'vibe-acp',
|
|
7
7
|
versionArgs: ['--version'],
|
|
8
|
-
fetchModels: async (resolvedBin, env) => detectAcpModels({
|
|
8
|
+
fetchModels: async ({ resolvedBin, env }) => (({ bin, args, ...optionalArgs }) => detectAcpModels({ bin, args }, optionalArgs))({
|
|
9
9
|
bin: resolvedBin,
|
|
10
10
|
args: [],
|
|
11
11
|
env,
|
package/dist/detection.d.ts
CHANGED
|
@@ -23,7 +23,11 @@ type FetchedRuntimeModels = {
|
|
|
23
23
|
* @param env - The env the run will spawn with.
|
|
24
24
|
* @complexity O(1) after the first call per def + path; the first call costs one `--help` spawn (5 s cap).
|
|
25
25
|
*/
|
|
26
|
-
export declare function ensureAgentCapabilities(def
|
|
26
|
+
export declare function ensureAgentCapabilities({ def, launchPath, env }: {
|
|
27
|
+
def: RuntimeAgentDef;
|
|
28
|
+
launchPath: string;
|
|
29
|
+
env: NodeJS.ProcessEnv;
|
|
30
|
+
}): Promise<void>;
|
|
27
31
|
/** Result of {@link probeAgentModels}: the models to surface and where they came from. */
|
|
28
32
|
export type ProbedAgentModels = FetchedRuntimeModels;
|
|
29
33
|
/**
|
|
@@ -38,8 +42,16 @@ export type ProbedAgentModels = FetchedRuntimeModels;
|
|
|
38
42
|
* `source: 'fallback'` (including when the binary is not found). Never rejects.
|
|
39
43
|
* @complexity At most one model-listing spawn, bounded by the def's own timeout.
|
|
40
44
|
*/
|
|
41
|
-
export declare function probeAgentModels(def
|
|
42
|
-
|
|
45
|
+
export declare function probeAgentModels({ def }: {
|
|
46
|
+
def: RuntimeAgentDef;
|
|
47
|
+
}, { configuredEnv, amrProfileResolver }?: {
|
|
48
|
+
configuredEnv?: Record<string, string>;
|
|
49
|
+
amrProfileResolver?: AmrProfileResolver;
|
|
50
|
+
}): Promise<ProbedAgentModels>;
|
|
51
|
+
export declare function detectAgents({}: {}, { configuredEnvByAgent, amrProfileResolver }?: {
|
|
52
|
+
configuredEnvByAgent?: Record<string, Record<string, string>>;
|
|
53
|
+
amrProfileResolver?: AmrProfileResolver;
|
|
54
|
+
}): Promise<(Omit<RuntimeAgentDef, "buildArgs" | "listModels" | "fetchModels" | "deriveReasoningOptions" | "fallbackModels" | "fallbackModelsAssertedAt" | "helpArgs" | "capabilityFlags" | "fallbackBins" | "versionProbeTimeoutMs" | "maxPromptArgBytes" | "env" | "inactivityTimeoutMs" | "authProbe" | "needsAgentLogFile" | "stdoutPolicy" | "runtimeLock"> & {
|
|
43
55
|
models: RuntimeModelOption[];
|
|
44
56
|
modelsSource: RuntimeModelSource;
|
|
45
57
|
available: boolean;
|
|
@@ -49,6 +61,9 @@ export declare function detectAgents(configuredEnvByAgent?: Record<string, Recor
|
|
|
49
61
|
version?: string | null;
|
|
50
62
|
diagnostics?: AgentDiagnostic[];
|
|
51
63
|
})[]>;
|
|
52
|
-
export declare function detectAgentsStream(
|
|
64
|
+
export declare function detectAgentsStream({}: {}, { configuredEnvByAgent, amrProfileResolver }?: {
|
|
65
|
+
configuredEnvByAgent?: Record<string, Record<string, string>>;
|
|
66
|
+
amrProfileResolver?: AmrProfileResolver;
|
|
67
|
+
}): AsyncGenerator<DetectedAgent>;
|
|
53
68
|
export {};
|
|
54
69
|
//# sourceMappingURL=detection.d.ts.map
|