@tangle-network/agent-interface 0.6.0 → 0.8.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/dist/agent-profile.d.ts +7 -4
- package/dist/harness.d.ts +40 -0
- package/dist/harness.js +32 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +1 -0
- package/dist/profile-schema.d.ts +2 -0
- package/dist/profile-schema.js +1 -1
- package/package.json +1 -1
package/dist/agent-profile.d.ts
CHANGED
|
@@ -87,11 +87,14 @@ export interface AgentProfileResources {
|
|
|
87
87
|
/**
|
|
88
88
|
* Portable reasoning/thinking effort. Backends map it to their native control at materialization:
|
|
89
89
|
* codex `model_reasoning_effort`, kimi `--thinking`/`--no-thinking`, claude thinking budget.
|
|
90
|
-
* Ordered low→high:
|
|
91
|
-
*
|
|
92
|
-
*
|
|
90
|
+
* Ordered low→high:
|
|
91
|
+
* - `none` — extended thinking OFF (no reasoning budget at all)
|
|
92
|
+
* - `minimal` — thinking ON, the lowest budget (distinct from `none`)
|
|
93
|
+
* - `low` / `medium` / `high` / `xhigh`
|
|
94
|
+
* - `ultracode` — maximum (claude-code's "ultracode" run mode; codex's `max` reconciles here).
|
|
95
|
+
* A backend without a matching native tier clamps to its nearest (e.g. codex maps `xhigh`/`ultracode` → `high`).
|
|
93
96
|
*/
|
|
94
|
-
export type ReasoningEffort = 'none' | 'low' | 'medium' | 'high' | 'xhigh' | 'ultracode';
|
|
97
|
+
export type ReasoningEffort = 'none' | 'minimal' | 'low' | 'medium' | 'high' | 'xhigh' | 'ultracode';
|
|
95
98
|
/**
|
|
96
99
|
* Model selection hints for backends.
|
|
97
100
|
*/
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
/**
|
|
3
|
+
* The execution runner for an agent — WHICH runtime materializes and runs an `AgentProfile`.
|
|
4
|
+
*
|
|
5
|
+
* Harness is an EXECUTION concern chosen by the caller/executor per run, NOT part of the portable
|
|
6
|
+
* profile identity: the same `AgentProfile` (prompt/model/skills/tools/mcp/subagents) runs on any
|
|
7
|
+
* harness. This is the single shared enum every layer references instead of keeping its own copy
|
|
8
|
+
* (session control, the profile materializer, the cli-bridge backends, VB profile specs).
|
|
9
|
+
*
|
|
10
|
+
* `cli-base` is the router-backed mode — a plain multi-turn router call (a reviewer, a cheap judge,
|
|
11
|
+
* a one-shot) with no full coding-agent harness. The rest are full agentic harnesses run in a
|
|
12
|
+
* sandbox or locally via the CLI bridge.
|
|
13
|
+
*
|
|
14
|
+
* Some values are input aliases that collapse to a base runner (`claude`/`claudish` → `claude-code`,
|
|
15
|
+
* `kimi` → `kimi-code`); normalize with {@link canonicalizeHarness} before keying per-runner config.
|
|
16
|
+
*/
|
|
17
|
+
export type HarnessType = "claude-code" | "claude" | "claudish" | "nanoclaw" | "codex" | "opencode" | "kimi-code" | "kimi" | "pi" | "gemini" | "hermes" | "openclaw" | "amp" | "factory-droids" | "acp" | "cli-base";
|
|
18
|
+
/** Runtime validator for {@link HarnessType}. Kept in lockstep with the type by the drift guard below. */
|
|
19
|
+
export declare const harnessTypeSchema: z.ZodEnum<{
|
|
20
|
+
"claude-code": "claude-code";
|
|
21
|
+
claude: "claude";
|
|
22
|
+
claudish: "claudish";
|
|
23
|
+
nanoclaw: "nanoclaw";
|
|
24
|
+
codex: "codex";
|
|
25
|
+
opencode: "opencode";
|
|
26
|
+
"kimi-code": "kimi-code";
|
|
27
|
+
kimi: "kimi";
|
|
28
|
+
pi: "pi";
|
|
29
|
+
gemini: "gemini";
|
|
30
|
+
hermes: "hermes";
|
|
31
|
+
openclaw: "openclaw";
|
|
32
|
+
amp: "amp";
|
|
33
|
+
"factory-droids": "factory-droids";
|
|
34
|
+
acp: "acp";
|
|
35
|
+
"cli-base": "cli-base";
|
|
36
|
+
}>;
|
|
37
|
+
/** Input alias → canonical base runner. Aliases accept legacy/shorthand harness names. */
|
|
38
|
+
export declare const harnessAliases: Partial<Record<HarnessType, HarnessType>>;
|
|
39
|
+
/** Collapse an alias to its base runner (idempotent on canonical values). */
|
|
40
|
+
export declare function canonicalizeHarness(harness: HarnessType): HarnessType;
|
package/dist/harness.js
ADDED
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
/** Runtime validator for {@link HarnessType}. Kept in lockstep with the type by the drift guard below. */
|
|
3
|
+
export const harnessTypeSchema = z.enum([
|
|
4
|
+
"claude-code",
|
|
5
|
+
"claude",
|
|
6
|
+
"claudish",
|
|
7
|
+
"nanoclaw",
|
|
8
|
+
"codex",
|
|
9
|
+
"opencode",
|
|
10
|
+
"kimi-code",
|
|
11
|
+
"kimi",
|
|
12
|
+
"pi",
|
|
13
|
+
"gemini",
|
|
14
|
+
"hermes",
|
|
15
|
+
"openclaw",
|
|
16
|
+
"amp",
|
|
17
|
+
"factory-droids",
|
|
18
|
+
"acp",
|
|
19
|
+
"cli-base",
|
|
20
|
+
]);
|
|
21
|
+
/** Input alias → canonical base runner. Aliases accept legacy/shorthand harness names. */
|
|
22
|
+
export const harnessAliases = {
|
|
23
|
+
claude: "claude-code",
|
|
24
|
+
claudish: "claude-code",
|
|
25
|
+
kimi: "kimi-code",
|
|
26
|
+
};
|
|
27
|
+
/** Collapse an alias to its base runner (idempotent on canonical values). */
|
|
28
|
+
export function canonicalizeHarness(harness) {
|
|
29
|
+
return harnessAliases[harness] ?? harness;
|
|
30
|
+
}
|
|
31
|
+
const _harnessSchemaMatchesType = true;
|
|
32
|
+
void _harnessSchemaMatchesType;
|
package/dist/index.d.ts
CHANGED
package/dist/index.js
CHANGED
package/dist/profile-schema.d.ts
CHANGED
|
@@ -118,6 +118,7 @@ export declare const agentProfileModelHintsSchema: z.ZodObject<{
|
|
|
118
118
|
provider: z.ZodOptional<z.ZodString>;
|
|
119
119
|
reasoningEffort: z.ZodOptional<z.ZodEnum<{
|
|
120
120
|
none: "none";
|
|
121
|
+
minimal: "minimal";
|
|
121
122
|
low: "low";
|
|
122
123
|
medium: "medium";
|
|
123
124
|
high: "high";
|
|
@@ -211,6 +212,7 @@ export declare const agentProfileSchema: z.ZodObject<{
|
|
|
211
212
|
provider: z.ZodOptional<z.ZodString>;
|
|
212
213
|
reasoningEffort: z.ZodOptional<z.ZodEnum<{
|
|
213
214
|
none: "none";
|
|
215
|
+
minimal: "minimal";
|
|
214
216
|
low: "low";
|
|
215
217
|
medium: "medium";
|
|
216
218
|
high: "high";
|
package/dist/profile-schema.js
CHANGED
|
@@ -37,7 +37,7 @@ export const agentProfileModelHintsSchema = z.object({
|
|
|
37
37
|
default: z.string().optional(),
|
|
38
38
|
small: z.string().optional(),
|
|
39
39
|
provider: z.string().optional(),
|
|
40
|
-
reasoningEffort: z.enum(['none', 'low', 'medium', 'high', 'xhigh', 'ultracode']).optional(),
|
|
40
|
+
reasoningEffort: z.enum(['none', 'minimal', 'low', 'medium', 'high', 'xhigh', 'ultracode']).optional(),
|
|
41
41
|
metadata: z.record(z.string(), z.unknown()).optional(),
|
|
42
42
|
});
|
|
43
43
|
export const agentProfilePromptSchema = z.object({
|