@cleocode/core 2026.6.14 → 2026.6.17
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/check/pr-gate.d.ts +6 -2
- package/dist/check/pr-gate.d.ts.map +1 -1
- package/dist/check/pr-gate.js +14 -32
- package/dist/check/pr-gate.js.map +1 -1
- package/dist/config/config-repair.d.ts +70 -0
- package/dist/config/config-repair.d.ts.map +1 -0
- package/dist/config/config-repair.js +248 -0
- package/dist/config/config-repair.js.map +1 -0
- package/dist/config/registry.d.ts.map +1 -1
- package/dist/config/registry.js +4 -4
- package/dist/config/registry.js.map +1 -1
- package/dist/config.d.ts.map +1 -1
- package/dist/config.js +11 -10
- package/dist/config.js.map +1 -1
- package/dist/docs/export-document.js +58 -16
- package/dist/docs/export-document.js.map +2 -2
- package/dist/gc/cleanup.d.ts +23 -8
- package/dist/gc/cleanup.d.ts.map +1 -1
- package/dist/gc/cleanup.js +287 -22
- package/dist/gc/cleanup.js.map +1 -1
- package/dist/gc/janitor.d.ts +149 -0
- package/dist/gc/janitor.d.ts.map +1 -0
- package/dist/gc/janitor.js +760 -0
- package/dist/gc/janitor.js.map +1 -0
- package/dist/internal.d.ts +1 -0
- package/dist/internal.d.ts.map +1 -1
- package/dist/internal.js +3 -0
- package/dist/internal.js.map +1 -1
- package/dist/llm/cli-ops.d.ts +31 -4
- package/dist/llm/cli-ops.d.ts.map +1 -1
- package/dist/llm/cli-ops.js +110 -26
- package/dist/llm/cli-ops.js.map +1 -1
- package/dist/llm/credential-pool.d.ts +62 -0
- package/dist/llm/credential-pool.d.ts.map +1 -1
- package/dist/llm/credential-pool.js +161 -0
- package/dist/llm/credential-pool.js.map +1 -1
- package/dist/llm/cross-provider-selector.d.ts +254 -0
- package/dist/llm/cross-provider-selector.d.ts.map +1 -0
- package/dist/llm/cross-provider-selector.js +635 -0
- package/dist/llm/cross-provider-selector.js.map +1 -0
- package/dist/llm/index.d.ts +2 -0
- package/dist/llm/index.d.ts.map +1 -1
- package/dist/llm/index.js +1 -0
- package/dist/llm/index.js.map +1 -1
- package/dist/llm/local-model-fit.d.ts +260 -0
- package/dist/llm/local-model-fit.d.ts.map +1 -0
- package/dist/llm/local-model-fit.js +563 -0
- package/dist/llm/local-model-fit.js.map +1 -0
- package/dist/llm/plugin-facade.js +883 -231
- package/dist/llm/plugin-facade.js.map +3 -3
- package/dist/llm/provider-registry/builtin/ollama.d.ts +18 -0
- package/dist/llm/provider-registry/builtin/ollama.d.ts.map +1 -1
- package/dist/llm/provider-registry/builtin/ollama.js +20 -2
- package/dist/llm/provider-registry/builtin/ollama.js.map +1 -1
- package/dist/llm/role-resolver.d.ts.map +1 -1
- package/dist/llm/role-resolver.js +45 -10
- package/dist/llm/role-resolver.js.map +1 -1
- package/dist/llm/transports/codex-responses.d.ts +111 -88
- package/dist/llm/transports/codex-responses.d.ts.map +1 -1
- package/dist/llm/transports/codex-responses.js +456 -258
- package/dist/llm/transports/codex-responses.js.map +1 -1
- package/dist/release/index.d.ts +2 -2
- package/dist/release/index.d.ts.map +1 -1
- package/dist/release/index.js +1 -1
- package/dist/release/index.js.map +1 -1
- package/dist/release/reconcile.d.ts +97 -0
- package/dist/release/reconcile.d.ts.map +1 -1
- package/dist/release/reconcile.js +412 -5
- package/dist/release/reconcile.js.map +1 -1
- package/dist/resources/backend.d.ts +155 -0
- package/dist/resources/backend.d.ts.map +1 -0
- package/dist/resources/backend.js +23 -0
- package/dist/resources/backend.js.map +1 -0
- package/dist/resources/linux-backend.d.ts +167 -0
- package/dist/resources/linux-backend.d.ts.map +1 -0
- package/dist/resources/linux-backend.js +259 -0
- package/dist/resources/linux-backend.js.map +1 -0
- package/dist/resources/monitor.d.ts +230 -0
- package/dist/resources/monitor.d.ts.map +1 -0
- package/dist/resources/monitor.js +255 -0
- package/dist/resources/monitor.js.map +1 -0
- package/dist/resources/spawn-wrapper.d.ts +265 -0
- package/dist/resources/spawn-wrapper.d.ts.map +1 -0
- package/dist/resources/spawn-wrapper.js +304 -0
- package/dist/resources/spawn-wrapper.js.map +1 -0
- package/dist/selfimprove/budget.d.ts +11 -2
- package/dist/selfimprove/budget.d.ts.map +1 -1
- package/dist/selfimprove/budget.js +11 -2
- package/dist/selfimprove/budget.js.map +1 -1
- package/dist/selfimprove/fix-gen-context.d.ts +172 -0
- package/dist/selfimprove/fix-gen-context.d.ts.map +1 -0
- package/dist/selfimprove/fix-gen-context.js +218 -0
- package/dist/selfimprove/fix-gen-context.js.map +1 -0
- package/dist/selfimprove/fix-gen.d.ts +285 -0
- package/dist/selfimprove/fix-gen.d.ts.map +1 -0
- package/dist/selfimprove/fix-gen.js +346 -0
- package/dist/selfimprove/fix-gen.js.map +1 -0
- package/dist/selfimprove/op-source-map.d.ts +92 -0
- package/dist/selfimprove/op-source-map.d.ts.map +1 -0
- package/dist/selfimprove/op-source-map.js +187 -0
- package/dist/selfimprove/op-source-map.js.map +1 -0
- package/dist/selfimprove/probe-helper.d.ts +61 -0
- package/dist/selfimprove/probe-helper.d.ts.map +1 -0
- package/dist/selfimprove/probe-helper.js +64 -0
- package/dist/selfimprove/probe-helper.js.map +1 -0
- package/dist/selfimprove/run-loop.d.ts +44 -4
- package/dist/selfimprove/run-loop.d.ts.map +1 -1
- package/dist/selfimprove/run-loop.js +73 -6
- package/dist/selfimprove/run-loop.js.map +1 -1
- package/dist/selfimprove/scenarios/seeded-code-regression/golden.json +18 -0
- package/dist/selfimprove/scenarios/seeded-code-regression/scenario.json +12 -0
- package/dist/sentient/cross-project-hygiene.d.ts +11 -2
- package/dist/sentient/cross-project-hygiene.d.ts.map +1 -1
- package/dist/sentient/cross-project-hygiene.js +73 -10
- package/dist/sentient/cross-project-hygiene.js.map +1 -1
- package/dist/sentient/daemon.d.ts.map +1 -1
- package/dist/sentient/daemon.js +7 -2
- package/dist/sentient/daemon.js.map +1 -1
- package/dist/sentient/worktree-dispatch.d.ts.map +1 -1
- package/dist/sentient/worktree-dispatch.js +8 -1
- package/dist/sentient/worktree-dispatch.js.map +1 -1
- package/dist/setup/index.d.ts +1 -0
- package/dist/setup/index.d.ts.map +1 -1
- package/dist/setup/index.js +1 -0
- package/dist/setup/index.js.map +1 -1
- package/dist/setup/sections/models-roles.d.ts +32 -1
- package/dist/setup/sections/models-roles.d.ts.map +1 -1
- package/dist/setup/sections/models-roles.js +118 -19
- package/dist/setup/sections/models-roles.js.map +1 -1
- package/dist/setup/whoami-summary.d.ts +34 -0
- package/dist/setup/whoami-summary.d.ts.map +1 -0
- package/dist/setup/whoami-summary.js +106 -0
- package/dist/setup/whoami-summary.js.map +1 -0
- package/dist/spawn/branch-lock.d.ts.map +1 -1
- package/dist/spawn/branch-lock.js +7 -1
- package/dist/spawn/branch-lock.js.map +1 -1
- package/dist/store/attachment-repair.d.ts +110 -0
- package/dist/store/attachment-repair.d.ts.map +1 -0
- package/dist/store/attachment-repair.js +326 -0
- package/dist/store/attachment-repair.js.map +1 -0
- package/dist/store/attachment-store.d.ts.map +1 -1
- package/dist/store/attachment-store.js +24 -7
- package/dist/store/attachment-store.js.map +1 -1
- package/dist/tasks/evidence.d.ts +34 -2
- package/dist/tasks/evidence.d.ts.map +1 -1
- package/dist/tasks/evidence.js +293 -35
- package/dist/tasks/evidence.js.map +1 -1
- package/dist/verification/verify-tools.d.ts.map +1 -1
- package/dist/verification/verify-tools.js +5 -6
- package/dist/verification/verify-tools.js.map +1 -1
- package/package.json +22 -12
- package/templates/workflows/release-prepare.yml.tmpl +48 -2
|
@@ -0,0 +1,254 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Cross-provider provisioning-aware LLM selection (DHQ-081 · T11978).
|
|
3
|
+
*
|
|
4
|
+
* ## Problem
|
|
5
|
+
*
|
|
6
|
+
* `selectProviderModel` in `role-resolver.ts` (tier 8) falls back to
|
|
7
|
+
* `IMPLICIT_FALLBACK_PROVIDER = 'anthropic'` unconditionally when all 7
|
|
8
|
+
* config tiers miss. This means a machine with only `OPENAI_API_KEY` set
|
|
9
|
+
* still resolves to `anthropic` and returns `credential: null`, causing a
|
|
10
|
+
* silent 401 / graceful-degradation miss.
|
|
11
|
+
*
|
|
12
|
+
* ## Fix
|
|
13
|
+
*
|
|
14
|
+
* When all config tiers miss, instead of immediately returning the hardcoded
|
|
15
|
+
* `anthropic` fallback, `selectBestProvisioned` is called. It:
|
|
16
|
+
*
|
|
17
|
+
* 1. Enumerates all {@link BUILTIN_PROVIDER_IDS} (11 providers).
|
|
18
|
+
* 2. **Refresh-on-use (T11986 · DHQ-087)**: for any provider with an
|
|
19
|
+
* expired-but-refreshable OAuth credential, attempts a refresh BEFORE
|
|
20
|
+
* the provisioning probe so the selector sees a valid token instead of
|
|
21
|
+
* silently filtering the provider as "not-provisioned".
|
|
22
|
+
* 3. Probes which are provisioned (have a non-exhausted, non-expired
|
|
23
|
+
* credential in the cred store OR a non-empty env var).
|
|
24
|
+
* 4. Ranks provisioned providers by `scoreProvider(provider, taskTier)`.
|
|
25
|
+
* 5. Returns the winner's `SelectedProviderModel`, or `null` if nothing
|
|
26
|
+
* is provisioned (caller falls through to the anthropic implicit fallback,
|
|
27
|
+
* preserving backward compat).
|
|
28
|
+
*
|
|
29
|
+
* ## Gate-13 compliance
|
|
30
|
+
*
|
|
31
|
+
* This module:
|
|
32
|
+
* - MUST NOT construct any transport or SDK client.
|
|
33
|
+
* - MUST NOT read `process.env.*_API_KEY` directly — delegates to the
|
|
34
|
+
* credential layer (`resolveCredentials`, `pickCredentialForProviderSync`).
|
|
35
|
+
* - MUST NOT define a new exported `resolveLLMFor*` function.
|
|
36
|
+
* - MUST NOT hardcode model-id literals outside the provider-registry SSoT.
|
|
37
|
+
*
|
|
38
|
+
* @module llm/cross-provider-selector
|
|
39
|
+
* @task T11978
|
|
40
|
+
* @task T11986
|
|
41
|
+
* @epic T11679
|
|
42
|
+
*/
|
|
43
|
+
import type { ResolutionSource } from '@cleocode/contracts';
|
|
44
|
+
import type { ProviderTier } from '@cleocode/contracts/llm/provider-profile.js';
|
|
45
|
+
import type { ModelTransport } from './types-config.js';
|
|
46
|
+
/**
|
|
47
|
+
* The canonical set of builtin provider IDs that the cross-provider selector
|
|
48
|
+
* enumerates. Mirrors `BuiltinProviderId` (contracts/src/llm/provider-id.ts).
|
|
49
|
+
* Defined here as a runtime array so we can iterate without importing the
|
|
50
|
+
* union type.
|
|
51
|
+
*
|
|
52
|
+
* @task T11978
|
|
53
|
+
*/
|
|
54
|
+
export declare const BUILTIN_PROVIDER_IDS: ReadonlyArray<ModelTransport>;
|
|
55
|
+
/**
|
|
56
|
+
* Bias added for frontier/standard cloud providers that hold a valid credential.
|
|
57
|
+
* This ensures a provisioned frontier cloud provider (anthropic, openai) outranks
|
|
58
|
+
* a merely-running local ollama for frontier-tier tasks.
|
|
59
|
+
*
|
|
60
|
+
* Rationale (Q1 ratification): +60 on top of frontier's TIER_BASE=100 → score
|
|
61
|
+
* 160 ≥ local's TIER_BASE=120 + LOCALITY_BONUS=30 = 150.
|
|
62
|
+
*
|
|
63
|
+
* @task T11978
|
|
64
|
+
*/
|
|
65
|
+
export declare const PROVISIONED_CLOUD_BIAS = 60;
|
|
66
|
+
/**
|
|
67
|
+
* Internal shape returned by {@link selectBestProvisioned}.
|
|
68
|
+
* Mirrors the `SelectedProviderModel` interface in `role-resolver.ts`.
|
|
69
|
+
* Kept internal — callers receive `SelectedProviderModel` via the role-resolver.
|
|
70
|
+
*
|
|
71
|
+
* @internal
|
|
72
|
+
*/
|
|
73
|
+
export interface SelectedProviderModel {
|
|
74
|
+
provider: ModelTransport;
|
|
75
|
+
model: string;
|
|
76
|
+
credentialLabel: string | undefined;
|
|
77
|
+
source: ResolutionSource;
|
|
78
|
+
}
|
|
79
|
+
/**
|
|
80
|
+
* Provisioning state and score for a single provider.
|
|
81
|
+
*
|
|
82
|
+
* @task T11978
|
|
83
|
+
*/
|
|
84
|
+
export interface ProviderEnumeration {
|
|
85
|
+
/** Provider canonical ID. */
|
|
86
|
+
id: ModelTransport;
|
|
87
|
+
/** Human-readable display name (from provider registry, or the id string). */
|
|
88
|
+
displayName: string;
|
|
89
|
+
/** Capability tier (from provider registry). */
|
|
90
|
+
tier: ProviderTier;
|
|
91
|
+
/** Whether the provider has at least one usable credential. */
|
|
92
|
+
provisioningState: 'provisioned' | 'not-provisioned';
|
|
93
|
+
/**
|
|
94
|
+
* Credential reachability.
|
|
95
|
+
* `'auth-reachable'` — has a non-expired, non-invalid, non-exhausted credential.
|
|
96
|
+
* `'no-credential'` — no credential at all.
|
|
97
|
+
* `'credential-expired'` — credential exists but is expired.
|
|
98
|
+
* `'credential-invalid'` — credential exists but is marked invalid/exhausted.
|
|
99
|
+
*/
|
|
100
|
+
reachabilityState: 'auth-reachable' | 'no-credential' | 'credential-expired' | 'credential-invalid';
|
|
101
|
+
/**
|
|
102
|
+
* Whether the local ollama daemon is reachable.
|
|
103
|
+
* `null` for non-local providers (tier !== 'local').
|
|
104
|
+
*/
|
|
105
|
+
machineRunnable: boolean | null;
|
|
106
|
+
/** Number of credentials in the store for this provider. */
|
|
107
|
+
credentialCount: number;
|
|
108
|
+
/** Score from the cross-provider scoring function (null if not provisioned). */
|
|
109
|
+
resolverScore: number | null;
|
|
110
|
+
/**
|
|
111
|
+
* The model that would be selected by the catalog resolver for this provider.
|
|
112
|
+
* `null` if no catalog is available.
|
|
113
|
+
*/
|
|
114
|
+
wouldPickModel: string | null;
|
|
115
|
+
/** Reason for selection. */
|
|
116
|
+
wouldPickReason: 'cross-provider-best' | 'implicit-fallback' | 'not-selected';
|
|
117
|
+
}
|
|
118
|
+
/**
|
|
119
|
+
* Reset ollama probe cache for testing.
|
|
120
|
+
* @internal
|
|
121
|
+
*/
|
|
122
|
+
export declare function _resetOllamaProbeCache(): void;
|
|
123
|
+
/**
|
|
124
|
+
* Check whether the ollama daemon is listening at `baseUrl`.
|
|
125
|
+
*
|
|
126
|
+
* Uses a lightweight HTTP GET with a 200ms timeout. Result is cached in-process
|
|
127
|
+
* for {@link OLLAMA_PROBE_TTL_MS} (30 seconds) to avoid hammering localhost on
|
|
128
|
+
* every resolve call.
|
|
129
|
+
*
|
|
130
|
+
* Gate-13 note: this is a vanilla `fetch` call to probe localhost, NOT a
|
|
131
|
+
* transport/SDK client construction — Gate-13 does not cover network utility calls.
|
|
132
|
+
*
|
|
133
|
+
* @param baseUrl - Ollama base URL (default: `http://localhost:11434`).
|
|
134
|
+
* @returns `true` if the daemon responded with HTTP 200, `false` otherwise.
|
|
135
|
+
*
|
|
136
|
+
* @task T11978
|
|
137
|
+
*/
|
|
138
|
+
export declare function probeOllamaAlive(baseUrl: string): Promise<boolean>;
|
|
139
|
+
/**
|
|
140
|
+
* Select the appropriate ollama default model based on available RAM (DHQ-081 Q2).
|
|
141
|
+
*
|
|
142
|
+
* RAM gating uses `os.totalmem()` (Node.js built-in, no native addon required).
|
|
143
|
+
* VRAM detection is out-of-scope (deferred to T11982 wizard task).
|
|
144
|
+
*
|
|
145
|
+
* Resolution:
|
|
146
|
+
* - RAM ≥ 8 GB → `gemma4:e4b` for frontier/standard; `gemma4:e2b` for fast/local.
|
|
147
|
+
* - 4 GB ≤ RAM < 8 GB → `gemma4:e2b` for all tiers.
|
|
148
|
+
* - RAM < 4 GB → `qwen2:0.5b` (proof-of-life only; logged as WARNING).
|
|
149
|
+
*
|
|
150
|
+
* Note: `qwen2:0.5b` MUST NOT be selected as a resolver default. It is a
|
|
151
|
+
* last-resort proof-of-life floor for under-resourced machines.
|
|
152
|
+
*
|
|
153
|
+
* These string literals live here (the one allowed location outside
|
|
154
|
+
* `ollama.ts`) because they are DEFAULTS within the selector logic. The
|
|
155
|
+
* profile's `defaultModel`/`defaultAuxModel` fields are the primary SSoT;
|
|
156
|
+
* the selector reads them via `getProviderProfile('ollama')` when available
|
|
157
|
+
* and only falls back to these when the profile is unavailable (defensive).
|
|
158
|
+
*
|
|
159
|
+
* Tags live-verified 2026-06-11 on ollama.com/library/gemma4:
|
|
160
|
+
* - gemma4:e2b = 7.2 GB (Q4_K_M), edge 2B effective params, ≥ 4 GB RAM
|
|
161
|
+
* - gemma4:e4b = 9.6 GB (Q4_K_M), edge 4B effective params, ≥ 8 GB RAM
|
|
162
|
+
* If the catalog does not yet have a `gemma4` family entry, the resolver
|
|
163
|
+
* logs a hint to run `cleo llm refresh-catalog`.
|
|
164
|
+
*
|
|
165
|
+
* @param tier - The task tier for which a model is being selected.
|
|
166
|
+
* @param ramBytesOverride - Override `os.totalmem()` for testing.
|
|
167
|
+
* @returns The model ID string to use for ollama.
|
|
168
|
+
*
|
|
169
|
+
* @task T11978
|
|
170
|
+
*/
|
|
171
|
+
export declare function ollamaDefaultModelForTier(tier: ProviderTier, ramBytesOverride?: number): string;
|
|
172
|
+
/**
|
|
173
|
+
* Score a provisioned provider for a given task tier.
|
|
174
|
+
*
|
|
175
|
+
* Higher score = preferred. Tie-break by credential priority (lower priority
|
|
176
|
+
* value = higher user-assigned trust) is handled in {@link selectBestProvisioned}.
|
|
177
|
+
*
|
|
178
|
+
* Scoring formula:
|
|
179
|
+
* ```
|
|
180
|
+
* score = TIER_BASE[tier]
|
|
181
|
+
* + TASK_MATCH_BONUS (if tier aligns with taskTier)
|
|
182
|
+
* + LOCALITY_BONUS (local + daemon alive)
|
|
183
|
+
* + PROVISIONED_CLOUD_BIAS (frontier/standard cloud providers with valid cred)
|
|
184
|
+
* - COST_PENALTY (capped at MAX_COST_PENALTY)
|
|
185
|
+
* ```
|
|
186
|
+
*
|
|
187
|
+
* @param provider - The provider transport ID.
|
|
188
|
+
* @param providerTier - The capability tier of the provider.
|
|
189
|
+
* @param taskTier - The capability tier required by the current task.
|
|
190
|
+
* @param ollamaAlive - Whether the ollama daemon is currently reachable.
|
|
191
|
+
* @param costInputPerMillion - Cost per 1M input tokens (from catalog), or 0.
|
|
192
|
+
* @returns The numeric score (higher = preferred).
|
|
193
|
+
*
|
|
194
|
+
* @task T11978
|
|
195
|
+
*/
|
|
196
|
+
export declare function scoreProvider(provider: ModelTransport, providerTier: ProviderTier, taskTier: ProviderTier, ollamaAlive: boolean, costInputPerMillion: number): number;
|
|
197
|
+
/**
|
|
198
|
+
* Map a role name to a task tier for scoring purposes.
|
|
199
|
+
*
|
|
200
|
+
* @param role - The LLM role name.
|
|
201
|
+
* @returns The task tier for the role.
|
|
202
|
+
*
|
|
203
|
+
* @task T11978
|
|
204
|
+
*/
|
|
205
|
+
export declare function roleTierFor(role: string): ProviderTier;
|
|
206
|
+
/**
|
|
207
|
+
* Enumerate all builtin providers with their provisioning state and scores.
|
|
208
|
+
*
|
|
209
|
+
* Used by `cleo llm providers` and `cleo llm health` subcommands to display
|
|
210
|
+
* the full provisioning landscape to the user.
|
|
211
|
+
*
|
|
212
|
+
* @param taskTier - The task tier to score against (defaults to `'frontier'`).
|
|
213
|
+
* @returns Array of provider enumeration records.
|
|
214
|
+
*
|
|
215
|
+
* @task T11978
|
|
216
|
+
*/
|
|
217
|
+
export declare function enumerateProvisionedProviders(taskTier?: ProviderTier): Promise<ProviderEnumeration[]>;
|
|
218
|
+
/**
|
|
219
|
+
* Select the best provisioned provider for the given role.
|
|
220
|
+
*
|
|
221
|
+
* Called at tier 8 of `selectProviderModel` in `role-resolver.ts`, replacing
|
|
222
|
+
* the unconditional `IMPLICIT_FALLBACK_PROVIDER = 'anthropic'` hardcode.
|
|
223
|
+
*
|
|
224
|
+
* ## Algorithm
|
|
225
|
+
*
|
|
226
|
+
* 1. Enumerate all {@link BUILTIN_PROVIDER_IDS}.
|
|
227
|
+
* 2. Filter to those that are provisioned (cred store or env var).
|
|
228
|
+
* 3. Score each provisioned provider.
|
|
229
|
+
* 4. Pick the highest scorer. Tie-break: lowest credential priority value.
|
|
230
|
+
* 5. Resolve the model via catalog (`resolveProviderDefaultModel`) or
|
|
231
|
+
* provider profile `defaultModel`.
|
|
232
|
+
* 6. For ollama: gate model selection on `os.totalmem()`.
|
|
233
|
+
*
|
|
234
|
+
* ## When nothing is provisioned
|
|
235
|
+
*
|
|
236
|
+
* Returns `null`. The caller falls through to the hardcoded anthropic fallback,
|
|
237
|
+
* preserving backward compatibility.
|
|
238
|
+
*
|
|
239
|
+
* ## Gate-13 compliance
|
|
240
|
+
*
|
|
241
|
+
* Does NOT construct any transport or SDK client. Does NOT read
|
|
242
|
+
* `process.env.*_API_KEY` directly (delegates to credential layer).
|
|
243
|
+
* Does NOT define a new `resolveLLMFor*` function.
|
|
244
|
+
*
|
|
245
|
+
* @param role - The LLM role name (used to derive `taskTier`).
|
|
246
|
+
* @param opts - Options including `projectRoot`.
|
|
247
|
+
* @returns The best {@link SelectedProviderModel}, or `null` if nothing is provisioned.
|
|
248
|
+
*
|
|
249
|
+
* @task T11978
|
|
250
|
+
*/
|
|
251
|
+
export declare function selectBestProvisioned(role: string, opts: {
|
|
252
|
+
projectRoot: string;
|
|
253
|
+
}): Promise<SelectedProviderModel | null>;
|
|
254
|
+
//# sourceMappingURL=cross-provider-selector.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"cross-provider-selector.d.ts","sourceRoot":"","sources":["../../src/llm/cross-provider-selector.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAyCG;AAGH,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAC;AAC5D,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,6CAA6C,CAAC;AAKhF,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AAQxD;;;;;;;GAOG;AACH,eAAO,MAAM,oBAAoB,EAAE,aAAa,CAAC,cAAc,CAYrD,CAAC;AAgBX;;;;;;;;;GASG;AACH,eAAO,MAAM,sBAAsB,KAAK,CAAC;AA0CzC;;;;;;GAMG;AACH,MAAM,WAAW,qBAAqB;IACpC,QAAQ,EAAE,cAAc,CAAC;IACzB,KAAK,EAAE,MAAM,CAAC;IACd,eAAe,EAAE,MAAM,GAAG,SAAS,CAAC;IACpC,MAAM,EAAE,gBAAgB,CAAC;CAC1B;AAED;;;;GAI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