@polpo-ai/core 0.15.36 → 0.15.38

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.
Files changed (79) hide show
  1. package/README.md +102 -0
  2. package/dist/__tests__/model-profiles.test.d.ts +2 -0
  3. package/dist/__tests__/model-profiles.test.d.ts.map +1 -0
  4. package/dist/__tests__/model-profiles.test.js +221 -0
  5. package/dist/__tests__/model-profiles.test.js.map +1 -0
  6. package/dist/__tests__/model-router.test.d.ts +2 -0
  7. package/dist/__tests__/model-router.test.d.ts.map +1 -0
  8. package/dist/__tests__/model-router.test.js +458 -0
  9. package/dist/__tests__/model-router.test.js.map +1 -0
  10. package/dist/__tests__/runtime-plan.test.d.ts +2 -0
  11. package/dist/__tests__/runtime-plan.test.d.ts.map +1 -0
  12. package/dist/__tests__/runtime-plan.test.js +358 -0
  13. package/dist/__tests__/runtime-plan.test.js.map +1 -0
  14. package/dist/__tests__/task-runner-model-profiles.test.d.ts +2 -0
  15. package/dist/__tests__/task-runner-model-profiles.test.d.ts.map +1 -0
  16. package/dist/__tests__/task-runner-model-profiles.test.js +84 -0
  17. package/dist/__tests__/task-runner-model-profiles.test.js.map +1 -0
  18. package/dist/adapter.d.ts +8 -1
  19. package/dist/adapter.d.ts.map +1 -1
  20. package/dist/assessment-orchestrator.d.ts +1 -0
  21. package/dist/assessment-orchestrator.d.ts.map +1 -1
  22. package/dist/assessment-orchestrator.js +11 -4
  23. package/dist/assessment-orchestrator.js.map +1 -1
  24. package/dist/escalation-manager.d.ts.map +1 -1
  25. package/dist/escalation-manager.js +6 -1
  26. package/dist/escalation-manager.js.map +1 -1
  27. package/dist/events.d.ts +2 -0
  28. package/dist/events.d.ts.map +1 -1
  29. package/dist/index.d.ts +5 -0
  30. package/dist/index.d.ts.map +1 -1
  31. package/dist/index.js +4 -0
  32. package/dist/index.js.map +1 -1
  33. package/dist/loop/types.d.ts +3 -3
  34. package/dist/loop/types.d.ts.map +1 -1
  35. package/dist/mission-executor.d.ts.map +1 -1
  36. package/dist/mission-executor.js +2 -2
  37. package/dist/mission-executor.js.map +1 -1
  38. package/dist/model-profiles.d.ts +39 -0
  39. package/dist/model-profiles.d.ts.map +1 -0
  40. package/dist/model-profiles.js +181 -0
  41. package/dist/model-profiles.js.map +1 -0
  42. package/dist/model-router.d.ts +98 -0
  43. package/dist/model-router.d.ts.map +1 -0
  44. package/dist/model-router.js +358 -0
  45. package/dist/model-router.js.map +1 -0
  46. package/dist/runtime-plan/events.d.ts +5 -0
  47. package/dist/runtime-plan/events.d.ts.map +1 -0
  48. package/dist/runtime-plan/events.js +10 -0
  49. package/dist/runtime-plan/events.js.map +1 -0
  50. package/dist/runtime-plan/index.d.ts +5 -0
  51. package/dist/runtime-plan/index.d.ts.map +1 -0
  52. package/dist/runtime-plan/index.js +4 -0
  53. package/dist/runtime-plan/index.js.map +1 -0
  54. package/dist/runtime-plan/planner.d.ts +10 -0
  55. package/dist/runtime-plan/planner.d.ts.map +1 -0
  56. package/dist/runtime-plan/planner.js +322 -0
  57. package/dist/runtime-plan/planner.js.map +1 -0
  58. package/dist/runtime-plan/settings.d.ts +18 -0
  59. package/dist/runtime-plan/settings.d.ts.map +1 -0
  60. package/dist/runtime-plan/settings.js +63 -0
  61. package/dist/runtime-plan/settings.js.map +1 -0
  62. package/dist/runtime-plan/types.d.ts +112 -0
  63. package/dist/runtime-plan/types.d.ts.map +1 -0
  64. package/dist/runtime-plan/types.js +2 -0
  65. package/dist/runtime-plan/types.js.map +1 -0
  66. package/dist/schemas.d.ts +79 -19
  67. package/dist/schemas.d.ts.map +1 -1
  68. package/dist/schemas.js +16 -2
  69. package/dist/schemas.js.map +1 -1
  70. package/dist/task-runner.d.ts.map +1 -1
  71. package/dist/task-runner.js +5 -2
  72. package/dist/task-runner.js.map +1 -1
  73. package/dist/types/agent.d.ts +5 -3
  74. package/dist/types/agent.d.ts.map +1 -1
  75. package/dist/types/agent.js.map +1 -1
  76. package/dist/types/config.d.ts +24 -3
  77. package/dist/types/config.d.ts.map +1 -1
  78. package/dist/types/config.js.map +1 -1
  79. package/package.json +13 -1
package/README.md CHANGED
@@ -86,6 +86,108 @@ Loop run states distinguish the gate lifecycle from execution:
86
86
  - `resuming`: the runtime is executing from the saved checkpoint.
87
87
  - `completed`: the resumed or original run finished.
88
88
 
89
+ ## Runtime plans
90
+
91
+ Runtime hosts can resolve a serializable, immutable execution decision before
92
+ provider or tool setup:
93
+
94
+ ```ts
95
+ import { createRuntimePlan } from "@polpo-ai/core/runtime-plan";
96
+
97
+ const plan = createRuntimePlan({
98
+ surface: "channel",
99
+ source: "channel",
100
+ model: {
101
+ selection: "openai/gpt-5",
102
+ source: "agent",
103
+ },
104
+ tools: {
105
+ exposure: "direct",
106
+ allowed: ["search_docs"],
107
+ },
108
+ });
109
+ ```
110
+
111
+ Runtime plans contain policy decisions and references only. Prompts, messages,
112
+ provider headers, credentials, and retrieved private content do not belong in
113
+ the plan or its `runtime:plan` event.
114
+
115
+ ## Model profiles
116
+
117
+ Model profiles give project configuration stable semantic names while keeping
118
+ provider model IDs out of agent definitions. Existing string values always
119
+ remain concrete model IDs. A profile is selected only with the explicit
120
+ `{ profile: "name" }` form.
121
+
122
+ ```jsonc
123
+ {
124
+ "settings": {
125
+ "modelProfiles": {
126
+ "fast": "openai/gpt-4o-mini",
127
+ "balanced": {
128
+ "primary": "anthropic/claude-sonnet-4",
129
+ "fallbacks": [{ "profile": "fast" }]
130
+ }
131
+ },
132
+ "orchestratorModel": { "profile": "balanced" }
133
+ }
134
+ }
135
+ ```
136
+
137
+ Agents can select a profile and optionally narrow which profiles, including
138
+ nested references, they may use:
139
+
140
+ ```jsonc
141
+ {
142
+ "name": "support",
143
+ "model": { "profile": "balanced" },
144
+ "allowedModelProfiles": ["balanced", "fast"]
145
+ }
146
+ ```
147
+
148
+ Resolution is recursive, deterministic, deduplicates concrete models while
149
+ preserving order, and fails closed for unknown profiles, cycles, invalid
150
+ allowlists, excessive depth, or too many fallbacks. The runtime resolves the
151
+ profile before provider setup; providers receive only concrete model IDs.
152
+
153
+ ## Model routing
154
+
155
+ Model routing is optional automation over model profiles. The OSS router never
156
+ selects raw model IDs and never receives profile definitions, prompts,
157
+ conversation history, tool schemas, or credentials. Hosts inject a classifier
158
+ and keep the feature off until their own rollout policy enables it.
159
+
160
+ ```ts
161
+ import {
162
+ modelRouteRuntimePlanFields,
163
+ resolveModelRoute,
164
+ } from "@polpo-ai/core/model-router";
165
+ import { createStructuredModelRouteClassifier } from "@polpo-ai/llm";
166
+
167
+ const route = await resolveModelRoute({
168
+ surface: "agent",
169
+ source: "request",
170
+ input: "Summarize this short update.",
171
+ profiles: settings.modelProfiles,
172
+ config: {
173
+ mode: "auto",
174
+ fallbackProfile: "balanced",
175
+ allowedProfiles: ["fast", "balanced"],
176
+ },
177
+ }, {
178
+ classifier: createStructuredModelRouteClassifier({ model: routerModel }),
179
+ signal: request.signal,
180
+ });
181
+
182
+ const { model, audit } = modelRouteRuntimePlanFields(route);
183
+ ```
184
+
185
+ Explicit authorized profiles skip classification. Disabled routing,
186
+ single-profile allowlists, missing input, and missing classifiers resolve
187
+ deterministically. Timeout, provider failure, malformed output, unknown
188
+ profiles, and low confidence use the configured fallback; caller cancellation
189
+ stops planning instead of starting execution with a fallback.
190
+
89
191
  ## License
90
192
 
91
193
  Apache 2.0
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=model-profiles.test.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"model-profiles.test.d.ts","sourceRoot":"","sources":["../../src/__tests__/model-profiles.test.ts"],"names":[],"mappings":""}
@@ -0,0 +1,221 @@
1
+ import { describe, expect, it } from "vitest";
2
+ import { ModelProfileResolutionError, resolveModelProfileSelection, } from "../model-profiles.js";
3
+ import { modelProfileRegistrySchema, modelSelectionSchema, } from "../schemas.js";
4
+ describe("model profile resolution", () => {
5
+ it("preserves legacy model ids without interpreting provider-like names as profiles", () => {
6
+ expect(resolveModelProfileSelection("openai")).toEqual({
7
+ selection: "openai",
8
+ policy: {
9
+ primary: "openai",
10
+ fallbacks: [],
11
+ candidates: ["openai"],
12
+ },
13
+ profiles: [],
14
+ });
15
+ });
16
+ it("resolves an explicit profile reference to a concrete policy", () => {
17
+ expect(resolveModelProfileSelection({ profile: "fast" }, {
18
+ profiles: {
19
+ fast: {
20
+ primary: "openai/gpt-4o-mini",
21
+ fallbacks: ["google/gemini-2.5-flash"],
22
+ },
23
+ },
24
+ })).toEqual({
25
+ selection: {
26
+ primary: "openai/gpt-4o-mini",
27
+ fallbacks: ["google/gemini-2.5-flash"],
28
+ },
29
+ policy: {
30
+ primary: "openai/gpt-4o-mini",
31
+ fallbacks: ["google/gemini-2.5-flash"],
32
+ candidates: ["openai/gpt-4o-mini", "google/gemini-2.5-flash"],
33
+ },
34
+ profiles: ["fast"],
35
+ });
36
+ });
37
+ it("flattens nested profiles and mixed direct/profile fallbacks in order", () => {
38
+ const result = resolveModelProfileSelection({
39
+ primary: { profile: "balanced" },
40
+ fallbacks: ["local/qwen", { profile: "emergency" }],
41
+ }, {
42
+ profiles: {
43
+ balanced: {
44
+ primary: "anthropic/claude-sonnet-4",
45
+ fallbacks: [{ profile: "fast" }],
46
+ },
47
+ fast: "openai/gpt-4o-mini",
48
+ emergency: {
49
+ primary: "google/gemini-2.5-flash",
50
+ fallbacks: ["local/qwen"],
51
+ },
52
+ },
53
+ });
54
+ expect(result.policy.candidates).toEqual([
55
+ "anthropic/claude-sonnet-4",
56
+ "openai/gpt-4o-mini",
57
+ "local/qwen",
58
+ "google/gemini-2.5-flash",
59
+ ]);
60
+ expect(result.profiles).toEqual(["balanced", "fast", "emergency"]);
61
+ });
62
+ it("deduplicates expanded models while preserving first occurrence", () => {
63
+ const result = resolveModelProfileSelection({
64
+ primary: { profile: "fast" },
65
+ fallbacks: ["openai/gpt-4o-mini", "local/qwen"],
66
+ }, {
67
+ profiles: {
68
+ fast: {
69
+ primary: "openai/gpt-4o-mini",
70
+ fallbacks: ["local/qwen"],
71
+ },
72
+ },
73
+ });
74
+ expect(result.selection).toEqual({
75
+ primary: "openai/gpt-4o-mini",
76
+ fallbacks: ["local/qwen"],
77
+ });
78
+ });
79
+ it("allows a profile to share a provider name because references are explicit", () => {
80
+ expect(resolveModelProfileSelection({ profile: "openai" }, { profiles: { openai: "openai/gpt-4o-mini" } }).policy.primary).toBe("openai/gpt-4o-mini");
81
+ });
82
+ it.each([
83
+ [null],
84
+ [[]],
85
+ ["fast"],
86
+ [42],
87
+ ])("rejects a malformed profile registry: %j", (profiles) => {
88
+ expect(() => resolveModelProfileSelection({ profile: "fast" }, { profiles: profiles })).toThrowError(expect.objectContaining({
89
+ code: "INVALID_PROFILE_REGISTRY",
90
+ }));
91
+ });
92
+ it.each([
93
+ [{ profile: "" }],
94
+ [{ profile: " " }],
95
+ [{ profile: "reasoning/high" }],
96
+ [{ profile: "UPPER" }],
97
+ [{ profile: 42 }],
98
+ [{ profile: "fast", primary: "openai/gpt-4o-mini" }],
99
+ [{ primary: "openai/gpt-4o-mini", arbitrary: true }],
100
+ ])("rejects malformed or ambiguous references: %j", (selection) => {
101
+ expect(() => resolveModelProfileSelection(selection, {
102
+ profiles: {},
103
+ })).toThrow(ModelProfileResolutionError);
104
+ });
105
+ it("rejects missing profiles with a typed error", () => {
106
+ expect(() => resolveModelProfileSelection({ profile: "missing" }, { profiles: {} })).toThrowError(expect.objectContaining({
107
+ code: "UNKNOWN_PROFILE",
108
+ profile: "missing",
109
+ }));
110
+ });
111
+ it("rejects direct and indirect cycles with the complete cycle path", () => {
112
+ expect(() => resolveModelProfileSelection({ profile: "a" }, { profiles: { a: { profile: "a" } } })).toThrowError(expect.objectContaining({
113
+ code: "PROFILE_CYCLE",
114
+ path: ["a", "a"],
115
+ }));
116
+ expect(() => resolveModelProfileSelection({ profile: "a" }, {
117
+ profiles: {
118
+ a: { profile: "b" },
119
+ b: { profile: "c" },
120
+ c: { profile: "a" },
121
+ },
122
+ })).toThrowError(expect.objectContaining({
123
+ code: "PROFILE_CYCLE",
124
+ path: ["a", "b", "c", "a"],
125
+ }));
126
+ });
127
+ it("bounds recursive expansion independently from cycle detection", () => {
128
+ expect(() => resolveModelProfileSelection({ profile: "a" }, {
129
+ profiles: {
130
+ a: { profile: "b" },
131
+ b: { profile: "c" },
132
+ c: "openai/gpt-4o-mini",
133
+ },
134
+ maxDepth: 2,
135
+ })).toThrowError(expect.objectContaining({
136
+ code: "PROFILE_DEPTH_EXCEEDED",
137
+ }));
138
+ });
139
+ it("never silently truncates an expanded fallback policy", () => {
140
+ expect(() => resolveModelProfileSelection({ profile: "wide" }, {
141
+ profiles: {
142
+ wide: {
143
+ primary: "model/1",
144
+ fallbacks: ["model/2", "model/3", "model/4"],
145
+ },
146
+ },
147
+ maxFallbacks: 2,
148
+ })).toThrowError(expect.objectContaining({
149
+ code: "TOO_MANY_FALLBACKS",
150
+ }));
151
+ });
152
+ it("profile and model allowlists only narrow what can be selected", () => {
153
+ expect(() => resolveModelProfileSelection({ profile: "reasoning" }, {
154
+ profiles: { reasoning: "anthropic/claude-opus-4" },
155
+ allowedProfiles: ["fast"],
156
+ })).toThrowError(expect.objectContaining({
157
+ code: "DISALLOWED_PROFILE",
158
+ profile: "reasoning",
159
+ }));
160
+ expect(() => resolveModelProfileSelection({ profile: "fast" }, {
161
+ profiles: {
162
+ fast: {
163
+ primary: "openai/gpt-4o-mini",
164
+ fallbacks: ["google/gemini-2.5-flash"],
165
+ },
166
+ },
167
+ allowedProfiles: ["fast", "unused"],
168
+ allowedModels: ["openai/gpt-4o-mini"],
169
+ })).toThrowError(expect.objectContaining({
170
+ code: "DISALLOWED_MODEL",
171
+ model: "google/gemini-2.5-flash",
172
+ }));
173
+ });
174
+ it("validates nested profile references against the allowed profile set", () => {
175
+ expect(() => resolveModelProfileSelection({ profile: "balanced" }, {
176
+ profiles: {
177
+ balanced: { profile: "fast" },
178
+ fast: "openai/gpt-4o-mini",
179
+ },
180
+ allowedProfiles: ["balanced"],
181
+ })).toThrowError(expect.objectContaining({
182
+ code: "DISALLOWED_PROFILE",
183
+ profile: "fast",
184
+ }));
185
+ });
186
+ it("does not mutate inputs and freezes the complete resolution result", () => {
187
+ const selection = {
188
+ primary: { profile: "fast" },
189
+ fallbacks: ["local/qwen"],
190
+ };
191
+ const profiles = {
192
+ fast: "openai/gpt-4o-mini",
193
+ };
194
+ const selectionBefore = structuredClone(selection);
195
+ const profilesBefore = structuredClone(profiles);
196
+ const result = resolveModelProfileSelection(selection, { profiles });
197
+ expect(selection).toEqual(selectionBefore);
198
+ expect(profiles).toEqual(profilesBefore);
199
+ expect(Object.isFrozen(result)).toBe(true);
200
+ expect(Object.isFrozen(result.policy)).toBe(true);
201
+ expect(Object.isFrozen(result.policy.candidates)).toBe(true);
202
+ expect(Object.isFrozen(result.profiles)).toBe(true);
203
+ });
204
+ it("schema validation fails closed for ambiguous structured selections", () => {
205
+ expect(modelSelectionSchema.safeParse({
206
+ profile: "fast",
207
+ primary: "openai/gpt-4o-mini",
208
+ }).success).toBe(false);
209
+ expect(modelSelectionSchema.safeParse({
210
+ primary: "openai/gpt-4o-mini",
211
+ arbitrary: true,
212
+ }).success).toBe(false);
213
+ expect(modelProfileRegistrySchema.safeParse({
214
+ fast: {
215
+ profile: "balanced",
216
+ fallbacks: ["openai/gpt-4o-mini"],
217
+ },
218
+ }).success).toBe(false);
219
+ });
220
+ });
221
+ //# sourceMappingURL=model-profiles.test.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"model-profiles.test.js","sourceRoot":"","sources":["../../src/__tests__/model-profiles.test.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,EAAE,EAAE,EAAE,MAAM,QAAQ,CAAC;AAC9C,OAAO,EACL,2BAA2B,EAC3B,4BAA4B,GAC7B,MAAM,sBAAsB,CAAC;AAC9B,OAAO,EACL,0BAA0B,EAC1B,oBAAoB,GACrB,MAAM,eAAe,CAAC;AAEvB,QAAQ,CAAC,0BAA0B,EAAE,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,IAAI,CAAC,IAAI,CAAC,CAAC;QAC3C,MAAM,CAAC,MAAM,CAAC,QAAQ,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;QAClD,MAAM,CAAC,MAAM,CAAC,QAAQ,CAAC,MAAM,CAAC,MAAM,CAAC,UAAU,CAAC,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;QAC7D,MAAM,CAAC,MAAM,CAAC,QAAQ,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IACtD,CAAC,CAAC,CAAC;IAEH,EAAE,CAAC,oEAAoE,EAAE,GAAG,EAAE;QAC5E,MAAM,CAAC,oBAAoB,CAAC,SAAS,CAAC;YACpC,OAAO,EAAE,MAAM;YACf,OAAO,EAAE,oBAAoB;SAC9B,CAAC,CAAC,OAAO,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;QACxB,MAAM,CAAC,oBAAoB,CAAC,SAAS,CAAC;YACpC,OAAO,EAAE,oBAAoB;YAC7B,SAAS,EAAE,IAAI;SAChB,CAAC,CAAC,OAAO,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;QACxB,MAAM,CAAC,0BAA0B,CAAC,SAAS,CAAC;YAC1C,IAAI,EAAE;gBACJ,OAAO,EAAE,UAAU;gBACnB,SAAS,EAAE,CAAC,oBAAoB,CAAC;aAClC;SACF,CAAC,CAAC,OAAO,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;IAC1B,CAAC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=model-router.test.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"model-router.test.d.ts","sourceRoot":"","sources":["../../src/__tests__/model-router.test.ts"],"names":[],"mappings":""}