@genesislcap/ai-assistant 15.33.1 → 15.34.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/dist/ai-assistant.api.json +1021 -6
- package/dist/ai-assistant.d.ts +209 -5
- package/dist/chat-driver.cjs +90 -0
- package/dist/chat-driver.cjs.map +3 -3
- package/dist/chat-driver.mjs +86 -0
- package/dist/chat-driver.mjs.map +3 -3
- package/dist/custom-elements.json +329 -3
- package/dist/dts/chat-driver-node.d.ts +2 -2
- package/dist/dts/chat-driver-node.d.ts.map +1 -1
- package/dist/dts/components/settings-modal/settings-modal.styles.d.ts.map +1 -1
- package/dist/dts/components/settings-modal/settings-modal.template.d.ts.map +1 -1
- package/dist/dts/index.d.ts +2 -0
- package/dist/dts/index.d.ts.map +1 -1
- package/dist/dts/main/budget-controller.d.ts +38 -6
- package/dist/dts/main/budget-controller.d.ts.map +1 -1
- package/dist/dts/main/main.d.ts +22 -4
- package/dist/dts/main/main.d.ts.map +1 -1
- package/dist/dts/main/main.types.d.ts +25 -0
- package/dist/dts/main/main.types.d.ts.map +1 -1
- package/dist/dts/provider/tiered-provider-switcher.d.ts +123 -0
- package/dist/dts/provider/tiered-provider-switcher.d.ts.map +1 -0
- package/dist/dts/state/ai-assistant-slice.d.ts +34 -0
- package/dist/dts/state/ai-assistant-slice.d.ts.map +1 -1
- package/dist/dts/state/session-store.d.ts.map +1 -1
- package/dist/esm/chat-driver-node.js +11 -1
- package/dist/esm/components/settings-modal/settings-modal.styles.js +75 -0
- package/dist/esm/components/settings-modal/settings-modal.template.js +56 -4
- package/dist/esm/index.js +1 -0
- package/dist/esm/main/budget-controller.js +178 -6
- package/dist/esm/main/main.js +20 -0
- package/dist/esm/provider/tiered-provider-switcher.js +142 -0
- package/dist/esm/state/ai-assistant-slice.js +17 -3
- package/docs/styling.md +24 -0
- package/package.json +18 -17
- package/sandbox/sandbox.ts +52 -0
- package/scripts/smoke-chat-driver-node.mjs +86 -0
|
@@ -15014,7 +15014,7 @@
|
|
|
15014
15014
|
{
|
|
15015
15015
|
"kind": "Method",
|
|
15016
15016
|
"canonicalReference": "@genesislcap/ai-assistant!FoundationAiAssistant#setVendorBudget:member(1)",
|
|
15017
|
-
"docComment": "/**\n * Feed (or clear) one vendor's AI-spend figures for the settings-modal budget meter — the numeric companion to {@link FoundationAiAssistant.setVendorBlocked}, and like it a host-driven write: the element meters nothing itself.\n *\n * The meter renders a row for exactly the vendors that currently HAVE figures. An **unlimited** vendor (the budget endpoint reports `unlimited: true` / `limitUsd: null`) is expressed by never feeding it — there is deliberately no \"unlimited\" figure shape, because a bar with no cap has nothing truthful to fill to. `spentUsd` MAY exceed `budgetUsd` (the last allowed call can overshoot the cap): the row's text shows the real figures and only the bar clamps.\n *\n * Returns `false` — and warns once, not per call — instead of throwing when `vendor` is not a budgeted vendor (`BUDGETED_VENDORS`, the proxy's own metered list) or either figure is not a finite number `>= 0`. Invalid input changes no state. Idempotent: re-feeding a vendor's current figures is a no-op, so hosts can re-feed unconditionally after every turn.\n *\n * `false` ALSO means \"not stored, because the element is not ready yet\": a feed that lands before the element has its session store (a host calling ahead of the first append, or during a pop-out remount) stores nothing and says so, rather than reporting a write that never happened. That case is transient and needs no host handling — the documented per-turn re-feed is what recovers it — so it is deliberately NOT warned about; the warn-once channel is for garbage input only.\n *\n * `figures` is nullish-checked at run time, so `undefined` behaves exactly like `null` and CLEARS that vendor's row. Untyped JS hosts feed this straight from `GET /api/budget`, where a per-vendor lookup that misses yields `undefined`, not `null` — and \"no figures\" coherently means \"no row\". The `| null` parameter type is unchanged for typed callers; the runtime is deliberately the more forgiving of the two.\n *\n * The intended feed is the platform budget endpoint:\n * ```ts\n * // `vendors` is an OBJECT keyed by vendor id, not an array.\n * const { vendors } = await (await fetch('/api/budget')).json();\n * for (const v of Object.values(vendors)) {\n * if (v.unlimited || v.limitUsd == null) {\n * assistantEl.setVendorBudget(v.vendor, null); // clear stale figures after a cap is lifted\n * continue;\n * }\n * assistantEl.setVendorBudget(v.vendor, { budgetUsd: v.limitUsd, spentUsd: v.spentUsd });\n * }\n * ```\n *\n * Re-run it on mount and after each turn. Scope and lifetime follow the rest of the session slice (per `stateKey`, survives pop-in/out and \"Clear\" / \"New chat\") — except that the figures are NOT persisted to the session snapshot: the server is authoritative and the host re-feeds at boot, so a persisted copy could only show stale dollars after a reload.\n *\n * @beta\n */\n",
|
|
15017
|
+
"docComment": "/**\n * Feed (or clear) one vendor's AI-spend figures for the settings-modal budget meter — the numeric companion to {@link FoundationAiAssistant.setVendorBlocked}, and like it a host-driven write: the element meters nothing itself.\n *\n * The meter renders a row for exactly the vendors that currently HAVE figures. An **unlimited** vendor (the budget endpoint reports `unlimited: true` / `limitUsd: null`) is expressed by never feeding it — there is deliberately no \"unlimited\" figure shape, because a bar with no cap has nothing truthful to fill to. `spentUsd` MAY exceed `budgetUsd` (the last allowed call can overshoot the cap): the row's text shows the real figures and only the bar clamps.\n *\n * Returns `false` — and warns once, not per call — instead of throwing when `vendor` is not a budgeted vendor (`BUDGETED_VENDORS`, the proxy's own metered list) or either figure is not a finite number `>= 0`. Invalid input changes no state. Idempotent: re-feeding a vendor's current figures is a no-op, so hosts can re-feed unconditionally after every turn.\n *\n * `false` ALSO means \"not stored, because the element is not ready yet\": a feed that lands before the element has its session store (a host calling ahead of the first append, or during a pop-out remount) stores nothing and says so, rather than reporting a write that never happened. That case is transient and needs no host handling — the documented per-turn re-feed is what recovers it — so it is deliberately NOT warned about; the warn-once channel is for garbage input only.\n *\n * `figures` is nullish-checked at run time, so `undefined` behaves exactly like `null` and CLEARS that vendor's row. Untyped JS hosts feed this straight from `GET /api/budget`, where a per-vendor lookup that misses yields `undefined`, not `null` — and \"no figures\" coherently means \"no row\". The `| null` parameter type is unchanged for typed callers; the runtime is deliberately the more forgiving of the two.\n *\n * The intended feed is the platform budget endpoint:\n * ```ts\n * // `vendors` is an OBJECT keyed by vendor id, not an array.\n * const { vendors } = await (await fetch('/api/budget')).json();\n * for (const v of Object.values(vendors)) {\n * if (v.unlimited || v.limitUsd == null) {\n * assistantEl.setVendorBudget(v.vendor, null); // clear stale figures after a cap is lifted\n * continue;\n * }\n * assistantEl.setVendorBudget(v.vendor, { budgetUsd: v.limitUsd, spentUsd: v.spentUsd });\n * }\n * ```\n *\n * A host that meters its spend by source can pass an optional `segments` breakdown, and the vendor's bar is drawn stacked with a legend naming each one (NEW-15):\n * ```ts\n * assistantEl.setVendorBudget('anthropic', {\n * budgetUsd: 50,\n * spentUsd: 12.5,\n * segments: [\n * { id: 'app', label: 'App', spentUsd: 9 },\n * { id: 'batch', label: 'Batch jobs', spentUsd: 3.5 },\n * ],\n * });\n * ```\n *\n * The labels are yours — the assistant has no vocabulary for what a host spends money on. Segments may add up to less than `spentUsd` (the remainder draws unlabelled) but never to more; a breakdown that does, or that is otherwise malformed, is dropped with a debug log and the single bar renders. Omit `segments` entirely and nothing about the meter changes.\n *\n * Re-run it on mount and after each turn. Scope and lifetime follow the rest of the session slice (per `stateKey`, survives pop-in/out and \"Clear\" / \"New chat\") — except that the figures are NOT persisted to the session snapshot: the server is authoritative and the host re-feeds at boot, so a persisted copy could only show stale dollars after a reload.\n *\n * @beta\n */\n",
|
|
15018
15018
|
"excerptTokens": [
|
|
15019
15019
|
{
|
|
15020
15020
|
"kind": "Content",
|
|
@@ -15028,9 +15028,14 @@
|
|
|
15028
15028
|
"kind": "Content",
|
|
15029
15029
|
"text": ", figures: "
|
|
15030
15030
|
},
|
|
15031
|
+
{
|
|
15032
|
+
"kind": "Reference",
|
|
15033
|
+
"text": "VendorBudgetFigures",
|
|
15034
|
+
"canonicalReference": "@genesislcap/ai-assistant!VendorBudgetFigures:interface"
|
|
15035
|
+
},
|
|
15031
15036
|
{
|
|
15032
15037
|
"kind": "Content",
|
|
15033
|
-
"text": "
|
|
15038
|
+
"text": " | null"
|
|
15034
15039
|
},
|
|
15035
15040
|
{
|
|
15036
15041
|
"kind": "Content",
|
|
@@ -15047,8 +15052,8 @@
|
|
|
15047
15052
|
],
|
|
15048
15053
|
"isStatic": false,
|
|
15049
15054
|
"returnTypeTokenRange": {
|
|
15050
|
-
"startIndex":
|
|
15051
|
-
"endIndex":
|
|
15055
|
+
"startIndex": 6,
|
|
15056
|
+
"endIndex": 7
|
|
15052
15057
|
},
|
|
15053
15058
|
"releaseTag": "Beta",
|
|
15054
15059
|
"isProtected": false,
|
|
@@ -15066,7 +15071,7 @@
|
|
|
15066
15071
|
"parameterName": "figures",
|
|
15067
15072
|
"parameterTypeTokenRange": {
|
|
15068
15073
|
"startIndex": 3,
|
|
15069
|
-
"endIndex":
|
|
15074
|
+
"endIndex": 5
|
|
15070
15075
|
},
|
|
15071
15076
|
"isOptional": false
|
|
15072
15077
|
}
|
|
@@ -19321,6 +19326,83 @@
|
|
|
19321
19326
|
"endIndex": 6
|
|
19322
19327
|
}
|
|
19323
19328
|
},
|
|
19329
|
+
{
|
|
19330
|
+
"kind": "Function",
|
|
19331
|
+
"canonicalReference": "@genesislcap/ai-assistant!registerTieredAIProviders:function(1)",
|
|
19332
|
+
"docComment": "/**\n * Build a {@link TieredAIProviderSwitcher} — which registers the tier-shaped provider registry — and put it on the {@link (AIProviderSwitcher:variable)} token. Call once at app bootstrap.\n *\n * @remarks\n *\n * Everything here is synchronous and has to stay that way. `foundation-ai-assistant` resolves the switcher and registry tokens as it connects, and an element that connects first caches the no-op fallback — so an `await` above this call costs the whole page load its providers. Load a stored vendor preference AFTER it, through {@link TieredAIProviderSwitcher.adoptPersistedVendor}.\n *\n * @beta\n */\n",
|
|
19333
|
+
"excerptTokens": [
|
|
19334
|
+
{
|
|
19335
|
+
"kind": "Content",
|
|
19336
|
+
"text": "export declare function registerTieredAIProviders(container: "
|
|
19337
|
+
},
|
|
19338
|
+
{
|
|
19339
|
+
"kind": "Reference",
|
|
19340
|
+
"text": "Container",
|
|
19341
|
+
"canonicalReference": "@microsoft/fast-foundation!Container:interface"
|
|
19342
|
+
},
|
|
19343
|
+
{
|
|
19344
|
+
"kind": "Content",
|
|
19345
|
+
"text": ", options: "
|
|
19346
|
+
},
|
|
19347
|
+
{
|
|
19348
|
+
"kind": "Reference",
|
|
19349
|
+
"text": "Omit",
|
|
19350
|
+
"canonicalReference": "!Omit:type"
|
|
19351
|
+
},
|
|
19352
|
+
{
|
|
19353
|
+
"kind": "Content",
|
|
19354
|
+
"text": "<"
|
|
19355
|
+
},
|
|
19356
|
+
{
|
|
19357
|
+
"kind": "Reference",
|
|
19358
|
+
"text": "TieredAIProviderSwitcherOptions",
|
|
19359
|
+
"canonicalReference": "@genesislcap/ai-assistant!TieredAIProviderSwitcherOptions:interface"
|
|
19360
|
+
},
|
|
19361
|
+
{
|
|
19362
|
+
"kind": "Content",
|
|
19363
|
+
"text": ", 'container'>"
|
|
19364
|
+
},
|
|
19365
|
+
{
|
|
19366
|
+
"kind": "Content",
|
|
19367
|
+
"text": "): "
|
|
19368
|
+
},
|
|
19369
|
+
{
|
|
19370
|
+
"kind": "Reference",
|
|
19371
|
+
"text": "TieredAIProviderSwitcher",
|
|
19372
|
+
"canonicalReference": "@genesislcap/ai-assistant!TieredAIProviderSwitcher:class"
|
|
19373
|
+
},
|
|
19374
|
+
{
|
|
19375
|
+
"kind": "Content",
|
|
19376
|
+
"text": ";"
|
|
19377
|
+
}
|
|
19378
|
+
],
|
|
19379
|
+
"fileUrlPath": "src/provider/tiered-provider-switcher.ts",
|
|
19380
|
+
"returnTypeTokenRange": {
|
|
19381
|
+
"startIndex": 8,
|
|
19382
|
+
"endIndex": 9
|
|
19383
|
+
},
|
|
19384
|
+
"releaseTag": "Beta",
|
|
19385
|
+
"overloadIndex": 1,
|
|
19386
|
+
"parameters": [
|
|
19387
|
+
{
|
|
19388
|
+
"parameterName": "container",
|
|
19389
|
+
"parameterTypeTokenRange": {
|
|
19390
|
+
"startIndex": 1,
|
|
19391
|
+
"endIndex": 2
|
|
19392
|
+
},
|
|
19393
|
+
"isOptional": false
|
|
19394
|
+
},
|
|
19395
|
+
{
|
|
19396
|
+
"parameterName": "options",
|
|
19397
|
+
"parameterTypeTokenRange": {
|
|
19398
|
+
"startIndex": 3,
|
|
19399
|
+
"endIndex": 7
|
|
19400
|
+
},
|
|
19401
|
+
"isOptional": false
|
|
19402
|
+
}
|
|
19403
|
+
],
|
|
19404
|
+
"name": "registerTieredAIProviders"
|
|
19405
|
+
},
|
|
19324
19406
|
{
|
|
19325
19407
|
"kind": "Variable",
|
|
19326
19408
|
"canonicalReference": "@genesislcap/ai-assistant!REQUEST_CONTINUATION_TOOL:var",
|
|
@@ -20753,6 +20835,38 @@
|
|
|
20753
20835
|
"endIndex": 2
|
|
20754
20836
|
}
|
|
20755
20837
|
},
|
|
20838
|
+
{
|
|
20839
|
+
"kind": "PropertySignature",
|
|
20840
|
+
"canonicalReference": "@genesislcap/ai-assistant!SettingsBudgetRow#segments:member",
|
|
20841
|
+
"docComment": "/**\n * The stacked bar's pieces when the host broke this vendor's spend down, and `undefined` when it did not — in which case the row renders the design system's single progress bar, exactly as before (NEW-15).\n */\n",
|
|
20842
|
+
"excerptTokens": [
|
|
20843
|
+
{
|
|
20844
|
+
"kind": "Content",
|
|
20845
|
+
"text": "segments?: "
|
|
20846
|
+
},
|
|
20847
|
+
{
|
|
20848
|
+
"kind": "Reference",
|
|
20849
|
+
"text": "SettingsBudgetSegment",
|
|
20850
|
+
"canonicalReference": "@genesislcap/ai-assistant!SettingsBudgetSegment:interface"
|
|
20851
|
+
},
|
|
20852
|
+
{
|
|
20853
|
+
"kind": "Content",
|
|
20854
|
+
"text": "[]"
|
|
20855
|
+
},
|
|
20856
|
+
{
|
|
20857
|
+
"kind": "Content",
|
|
20858
|
+
"text": ";"
|
|
20859
|
+
}
|
|
20860
|
+
],
|
|
20861
|
+
"isReadonly": false,
|
|
20862
|
+
"isOptional": true,
|
|
20863
|
+
"releaseTag": "Beta",
|
|
20864
|
+
"name": "segments",
|
|
20865
|
+
"propertyTypeTokenRange": {
|
|
20866
|
+
"startIndex": 1,
|
|
20867
|
+
"endIndex": 3
|
|
20868
|
+
}
|
|
20869
|
+
},
|
|
20756
20870
|
{
|
|
20757
20871
|
"kind": "PropertySignature",
|
|
20758
20872
|
"canonicalReference": "@genesislcap/ai-assistant!SettingsBudgetRow#vendor:member",
|
|
@@ -20783,6 +20897,186 @@
|
|
|
20783
20897
|
],
|
|
20784
20898
|
"extendsTokenRanges": []
|
|
20785
20899
|
},
|
|
20900
|
+
{
|
|
20901
|
+
"kind": "Interface",
|
|
20902
|
+
"canonicalReference": "@genesislcap/ai-assistant!SettingsBudgetSegment:interface",
|
|
20903
|
+
"docComment": "/**\n * One piece of a stacked budget bar, pre-computed — see {@link SettingsBudgetRow.segments}.\n *\n * @beta\n */\n",
|
|
20904
|
+
"excerptTokens": [
|
|
20905
|
+
{
|
|
20906
|
+
"kind": "Content",
|
|
20907
|
+
"text": "export interface SettingsBudgetSegment "
|
|
20908
|
+
}
|
|
20909
|
+
],
|
|
20910
|
+
"fileUrlPath": "src/main/main.types.ts",
|
|
20911
|
+
"releaseTag": "Beta",
|
|
20912
|
+
"name": "SettingsBudgetSegment",
|
|
20913
|
+
"preserveMemberOrder": false,
|
|
20914
|
+
"members": [
|
|
20915
|
+
{
|
|
20916
|
+
"kind": "PropertySignature",
|
|
20917
|
+
"canonicalReference": "@genesislcap/ai-assistant!SettingsBudgetSegment#figures:member",
|
|
20918
|
+
"docComment": "/**\n * This piece's spend, e.g. `$12.34`. Empty for the remainder.\n */\n",
|
|
20919
|
+
"excerptTokens": [
|
|
20920
|
+
{
|
|
20921
|
+
"kind": "Content",
|
|
20922
|
+
"text": "figures: "
|
|
20923
|
+
},
|
|
20924
|
+
{
|
|
20925
|
+
"kind": "Content",
|
|
20926
|
+
"text": "string"
|
|
20927
|
+
},
|
|
20928
|
+
{
|
|
20929
|
+
"kind": "Content",
|
|
20930
|
+
"text": ";"
|
|
20931
|
+
}
|
|
20932
|
+
],
|
|
20933
|
+
"isReadonly": false,
|
|
20934
|
+
"isOptional": false,
|
|
20935
|
+
"releaseTag": "Beta",
|
|
20936
|
+
"name": "figures",
|
|
20937
|
+
"propertyTypeTokenRange": {
|
|
20938
|
+
"startIndex": 1,
|
|
20939
|
+
"endIndex": 2
|
|
20940
|
+
}
|
|
20941
|
+
},
|
|
20942
|
+
{
|
|
20943
|
+
"kind": "PropertySignature",
|
|
20944
|
+
"canonicalReference": "@genesislcap/ai-assistant!SettingsBudgetSegment#id:member",
|
|
20945
|
+
"docComment": "/**\n * The host's segment id, or the platform's own id for the unattributed remainder.\n */\n",
|
|
20946
|
+
"excerptTokens": [
|
|
20947
|
+
{
|
|
20948
|
+
"kind": "Content",
|
|
20949
|
+
"text": "id: "
|
|
20950
|
+
},
|
|
20951
|
+
{
|
|
20952
|
+
"kind": "Content",
|
|
20953
|
+
"text": "string"
|
|
20954
|
+
},
|
|
20955
|
+
{
|
|
20956
|
+
"kind": "Content",
|
|
20957
|
+
"text": ";"
|
|
20958
|
+
}
|
|
20959
|
+
],
|
|
20960
|
+
"isReadonly": false,
|
|
20961
|
+
"isOptional": false,
|
|
20962
|
+
"releaseTag": "Beta",
|
|
20963
|
+
"name": "id",
|
|
20964
|
+
"propertyTypeTokenRange": {
|
|
20965
|
+
"startIndex": 1,
|
|
20966
|
+
"endIndex": 2
|
|
20967
|
+
}
|
|
20968
|
+
},
|
|
20969
|
+
{
|
|
20970
|
+
"kind": "PropertySignature",
|
|
20971
|
+
"canonicalReference": "@genesislcap/ai-assistant!SettingsBudgetSegment#label:member",
|
|
20972
|
+
"docComment": "/**\n * The host's label. Empty for the remainder, which the legend does not list.\n */\n",
|
|
20973
|
+
"excerptTokens": [
|
|
20974
|
+
{
|
|
20975
|
+
"kind": "Content",
|
|
20976
|
+
"text": "label: "
|
|
20977
|
+
},
|
|
20978
|
+
{
|
|
20979
|
+
"kind": "Content",
|
|
20980
|
+
"text": "string"
|
|
20981
|
+
},
|
|
20982
|
+
{
|
|
20983
|
+
"kind": "Content",
|
|
20984
|
+
"text": ";"
|
|
20985
|
+
}
|
|
20986
|
+
],
|
|
20987
|
+
"isReadonly": false,
|
|
20988
|
+
"isOptional": false,
|
|
20989
|
+
"releaseTag": "Beta",
|
|
20990
|
+
"name": "label",
|
|
20991
|
+
"propertyTypeTokenRange": {
|
|
20992
|
+
"startIndex": 1,
|
|
20993
|
+
"endIndex": 2
|
|
20994
|
+
}
|
|
20995
|
+
},
|
|
20996
|
+
{
|
|
20997
|
+
"kind": "PropertySignature",
|
|
20998
|
+
"canonicalReference": "@genesislcap/ai-assistant!SettingsBudgetSegment#legend:member",
|
|
20999
|
+
"docComment": "/**\n * Whether this piece appears in the legend — false for the unattributed remainder.\n */\n",
|
|
21000
|
+
"excerptTokens": [
|
|
21001
|
+
{
|
|
21002
|
+
"kind": "Content",
|
|
21003
|
+
"text": "legend: "
|
|
21004
|
+
},
|
|
21005
|
+
{
|
|
21006
|
+
"kind": "Content",
|
|
21007
|
+
"text": "boolean"
|
|
21008
|
+
},
|
|
21009
|
+
{
|
|
21010
|
+
"kind": "Content",
|
|
21011
|
+
"text": ";"
|
|
21012
|
+
}
|
|
21013
|
+
],
|
|
21014
|
+
"isReadonly": false,
|
|
21015
|
+
"isOptional": false,
|
|
21016
|
+
"releaseTag": "Beta",
|
|
21017
|
+
"name": "legend",
|
|
21018
|
+
"propertyTypeTokenRange": {
|
|
21019
|
+
"startIndex": 1,
|
|
21020
|
+
"endIndex": 2
|
|
21021
|
+
}
|
|
21022
|
+
},
|
|
21023
|
+
{
|
|
21024
|
+
"kind": "PropertySignature",
|
|
21025
|
+
"canonicalReference": "@genesislcap/ai-assistant!SettingsBudgetSegment#tone:member",
|
|
21026
|
+
"docComment": "/**\n * Alpha applied to the design system's accent, so the pieces read as one measure.\n */\n",
|
|
21027
|
+
"excerptTokens": [
|
|
21028
|
+
{
|
|
21029
|
+
"kind": "Content",
|
|
21030
|
+
"text": "tone: "
|
|
21031
|
+
},
|
|
21032
|
+
{
|
|
21033
|
+
"kind": "Content",
|
|
21034
|
+
"text": "number"
|
|
21035
|
+
},
|
|
21036
|
+
{
|
|
21037
|
+
"kind": "Content",
|
|
21038
|
+
"text": ";"
|
|
21039
|
+
}
|
|
21040
|
+
],
|
|
21041
|
+
"isReadonly": false,
|
|
21042
|
+
"isOptional": false,
|
|
21043
|
+
"releaseTag": "Beta",
|
|
21044
|
+
"name": "tone",
|
|
21045
|
+
"propertyTypeTokenRange": {
|
|
21046
|
+
"startIndex": 1,
|
|
21047
|
+
"endIndex": 2
|
|
21048
|
+
}
|
|
21049
|
+
},
|
|
21050
|
+
{
|
|
21051
|
+
"kind": "PropertySignature",
|
|
21052
|
+
"canonicalReference": "@genesislcap/ai-assistant!SettingsBudgetSegment#widthPercent:member",
|
|
21053
|
+
"docComment": "/**\n * Width as a percentage of the row's full track, already scaled to the clamped bar.\n */\n",
|
|
21054
|
+
"excerptTokens": [
|
|
21055
|
+
{
|
|
21056
|
+
"kind": "Content",
|
|
21057
|
+
"text": "widthPercent: "
|
|
21058
|
+
},
|
|
21059
|
+
{
|
|
21060
|
+
"kind": "Content",
|
|
21061
|
+
"text": "number"
|
|
21062
|
+
},
|
|
21063
|
+
{
|
|
21064
|
+
"kind": "Content",
|
|
21065
|
+
"text": ";"
|
|
21066
|
+
}
|
|
21067
|
+
],
|
|
21068
|
+
"isReadonly": false,
|
|
21069
|
+
"isOptional": false,
|
|
21070
|
+
"releaseTag": "Beta",
|
|
21071
|
+
"name": "widthPercent",
|
|
21072
|
+
"propertyTypeTokenRange": {
|
|
21073
|
+
"startIndex": 1,
|
|
21074
|
+
"endIndex": 2
|
|
21075
|
+
}
|
|
21076
|
+
}
|
|
21077
|
+
],
|
|
21078
|
+
"extendsTokenRanges": []
|
|
21079
|
+
},
|
|
20786
21080
|
{
|
|
20787
21081
|
"kind": "Interface",
|
|
20788
21082
|
"canonicalReference": "@genesislcap/ai-assistant!SettingsContextUsage:interface",
|
|
@@ -22681,7 +22975,525 @@
|
|
|
22681
22975
|
}
|
|
22682
22976
|
},
|
|
22683
22977
|
{
|
|
22684
|
-
"kind": "
|
|
22978
|
+
"kind": "Class",
|
|
22979
|
+
"canonicalReference": "@genesislcap/ai-assistant!TieredAIProviderSwitcher:class",
|
|
22980
|
+
"docComment": "/**\n * Which cloud vendor backs the tier-shaped provider registry, plus the means to move it at runtime (GENC-1610).\n *\n * @remarks\n *\n * Upstreamed from Genesis Create, which has run this shape in production: a registry keyed by tier (`low` / `high` / `reasoning`), a vendor switch that rebuilds it in place, and the other vendor kept alive as a standby entry. Agents keep resolving tier names, so a switch never touches agent config.\n *\n * Register it on the {@link (AIProviderSwitcher:interface)} DI token — via {@link registerTieredAIProviders} — and the settings modal's vendor UI (or an app's own control) drives it.\n *\n * @beta\n */\n",
|
|
22981
|
+
"excerptTokens": [
|
|
22982
|
+
{
|
|
22983
|
+
"kind": "Content",
|
|
22984
|
+
"text": "export declare class TieredAIProviderSwitcher implements "
|
|
22985
|
+
},
|
|
22986
|
+
{
|
|
22987
|
+
"kind": "Reference",
|
|
22988
|
+
"text": "AIProviderSwitcher",
|
|
22989
|
+
"canonicalReference": "@genesislcap/ai-assistant!AIProviderSwitcher:interface"
|
|
22990
|
+
},
|
|
22991
|
+
{
|
|
22992
|
+
"kind": "Content",
|
|
22993
|
+
"text": " "
|
|
22994
|
+
}
|
|
22995
|
+
],
|
|
22996
|
+
"fileUrlPath": "src/provider/tiered-provider-switcher.ts",
|
|
22997
|
+
"releaseTag": "Beta",
|
|
22998
|
+
"isAbstract": false,
|
|
22999
|
+
"name": "TieredAIProviderSwitcher",
|
|
23000
|
+
"preserveMemberOrder": false,
|
|
23001
|
+
"members": [
|
|
23002
|
+
{
|
|
23003
|
+
"kind": "Constructor",
|
|
23004
|
+
"canonicalReference": "@genesislcap/ai-assistant!TieredAIProviderSwitcher:constructor(1)",
|
|
23005
|
+
"docComment": "/**\n * Constructs a new instance of the `TieredAIProviderSwitcher` class\n */\n",
|
|
23006
|
+
"excerptTokens": [
|
|
23007
|
+
{
|
|
23008
|
+
"kind": "Content",
|
|
23009
|
+
"text": "constructor(options: "
|
|
23010
|
+
},
|
|
23011
|
+
{
|
|
23012
|
+
"kind": "Reference",
|
|
23013
|
+
"text": "TieredAIProviderSwitcherOptions",
|
|
23014
|
+
"canonicalReference": "@genesislcap/ai-assistant!TieredAIProviderSwitcherOptions:interface"
|
|
23015
|
+
},
|
|
23016
|
+
{
|
|
23017
|
+
"kind": "Content",
|
|
23018
|
+
"text": ");"
|
|
23019
|
+
}
|
|
23020
|
+
],
|
|
23021
|
+
"releaseTag": "Beta",
|
|
23022
|
+
"isProtected": false,
|
|
23023
|
+
"overloadIndex": 1,
|
|
23024
|
+
"parameters": [
|
|
23025
|
+
{
|
|
23026
|
+
"parameterName": "options",
|
|
23027
|
+
"parameterTypeTokenRange": {
|
|
23028
|
+
"startIndex": 1,
|
|
23029
|
+
"endIndex": 2
|
|
23030
|
+
},
|
|
23031
|
+
"isOptional": false
|
|
23032
|
+
}
|
|
23033
|
+
]
|
|
23034
|
+
},
|
|
23035
|
+
{
|
|
23036
|
+
"kind": "Method",
|
|
23037
|
+
"canonicalReference": "@genesislcap/ai-assistant!TieredAIProviderSwitcher#adoptPersistedVendor:member(1)",
|
|
23038
|
+
"docComment": "/**\n * Adopt a vendor the app read back from its own store — the same registry move as {@link TieredAIProviderSwitcher.switchTo}, without the `onSwitch` callback, because this value came FROM the store and writing it back would be a pointless round-trip on load.\n *\n * Exists because registration has to stay synchronous: an element that connects before the token is registered caches the platform's no-op fallback, so an app cannot await its stored preference before constructing this. It boots on `initialVendor` and adopts the stored one a moment later, through a registry that is mutable and held by reference.\n */\n",
|
|
23039
|
+
"excerptTokens": [
|
|
23040
|
+
{
|
|
23041
|
+
"kind": "Content",
|
|
23042
|
+
"text": "adoptPersistedVendor(vendor: "
|
|
23043
|
+
},
|
|
23044
|
+
{
|
|
23045
|
+
"kind": "Content",
|
|
23046
|
+
"text": "string"
|
|
23047
|
+
},
|
|
23048
|
+
{
|
|
23049
|
+
"kind": "Content",
|
|
23050
|
+
"text": "): "
|
|
23051
|
+
},
|
|
23052
|
+
{
|
|
23053
|
+
"kind": "Content",
|
|
23054
|
+
"text": "void"
|
|
23055
|
+
},
|
|
23056
|
+
{
|
|
23057
|
+
"kind": "Content",
|
|
23058
|
+
"text": ";"
|
|
23059
|
+
}
|
|
23060
|
+
],
|
|
23061
|
+
"isStatic": false,
|
|
23062
|
+
"returnTypeTokenRange": {
|
|
23063
|
+
"startIndex": 3,
|
|
23064
|
+
"endIndex": 4
|
|
23065
|
+
},
|
|
23066
|
+
"releaseTag": "Beta",
|
|
23067
|
+
"isProtected": false,
|
|
23068
|
+
"overloadIndex": 1,
|
|
23069
|
+
"parameters": [
|
|
23070
|
+
{
|
|
23071
|
+
"parameterName": "vendor",
|
|
23072
|
+
"parameterTypeTokenRange": {
|
|
23073
|
+
"startIndex": 1,
|
|
23074
|
+
"endIndex": 2
|
|
23075
|
+
},
|
|
23076
|
+
"isOptional": false
|
|
23077
|
+
}
|
|
23078
|
+
],
|
|
23079
|
+
"isOptional": false,
|
|
23080
|
+
"isAbstract": false,
|
|
23081
|
+
"name": "adoptPersistedVendor"
|
|
23082
|
+
},
|
|
23083
|
+
{
|
|
23084
|
+
"kind": "Method",
|
|
23085
|
+
"canonicalReference": "@genesislcap/ai-assistant!TieredAIProviderSwitcher#subscribe:member(1)",
|
|
23086
|
+
"docComment": "",
|
|
23087
|
+
"excerptTokens": [
|
|
23088
|
+
{
|
|
23089
|
+
"kind": "Content",
|
|
23090
|
+
"text": "subscribe(listener: "
|
|
23091
|
+
},
|
|
23092
|
+
{
|
|
23093
|
+
"kind": "Content",
|
|
23094
|
+
"text": "(vendor: string) => void"
|
|
23095
|
+
},
|
|
23096
|
+
{
|
|
23097
|
+
"kind": "Content",
|
|
23098
|
+
"text": "): "
|
|
23099
|
+
},
|
|
23100
|
+
{
|
|
23101
|
+
"kind": "Content",
|
|
23102
|
+
"text": "() => void"
|
|
23103
|
+
},
|
|
23104
|
+
{
|
|
23105
|
+
"kind": "Content",
|
|
23106
|
+
"text": ";"
|
|
23107
|
+
}
|
|
23108
|
+
],
|
|
23109
|
+
"isStatic": false,
|
|
23110
|
+
"returnTypeTokenRange": {
|
|
23111
|
+
"startIndex": 3,
|
|
23112
|
+
"endIndex": 4
|
|
23113
|
+
},
|
|
23114
|
+
"releaseTag": "Beta",
|
|
23115
|
+
"isProtected": false,
|
|
23116
|
+
"overloadIndex": 1,
|
|
23117
|
+
"parameters": [
|
|
23118
|
+
{
|
|
23119
|
+
"parameterName": "listener",
|
|
23120
|
+
"parameterTypeTokenRange": {
|
|
23121
|
+
"startIndex": 1,
|
|
23122
|
+
"endIndex": 2
|
|
23123
|
+
},
|
|
23124
|
+
"isOptional": false
|
|
23125
|
+
}
|
|
23126
|
+
],
|
|
23127
|
+
"isOptional": false,
|
|
23128
|
+
"isAbstract": false,
|
|
23129
|
+
"name": "subscribe"
|
|
23130
|
+
},
|
|
23131
|
+
{
|
|
23132
|
+
"kind": "Method",
|
|
23133
|
+
"canonicalReference": "@genesislcap/ai-assistant!TieredAIProviderSwitcher#switchTo:member(1)",
|
|
23134
|
+
"docComment": "/**\n * A user-driven switch: move the registry, then tell the app so it can persist the choice. An unknown vendor is ignored.\n */\n",
|
|
23135
|
+
"excerptTokens": [
|
|
23136
|
+
{
|
|
23137
|
+
"kind": "Content",
|
|
23138
|
+
"text": "switchTo(vendor: "
|
|
23139
|
+
},
|
|
23140
|
+
{
|
|
23141
|
+
"kind": "Content",
|
|
23142
|
+
"text": "string"
|
|
23143
|
+
},
|
|
23144
|
+
{
|
|
23145
|
+
"kind": "Content",
|
|
23146
|
+
"text": "): "
|
|
23147
|
+
},
|
|
23148
|
+
{
|
|
23149
|
+
"kind": "Content",
|
|
23150
|
+
"text": "void"
|
|
23151
|
+
},
|
|
23152
|
+
{
|
|
23153
|
+
"kind": "Content",
|
|
23154
|
+
"text": ";"
|
|
23155
|
+
}
|
|
23156
|
+
],
|
|
23157
|
+
"isStatic": false,
|
|
23158
|
+
"returnTypeTokenRange": {
|
|
23159
|
+
"startIndex": 3,
|
|
23160
|
+
"endIndex": 4
|
|
23161
|
+
},
|
|
23162
|
+
"releaseTag": "Beta",
|
|
23163
|
+
"isProtected": false,
|
|
23164
|
+
"overloadIndex": 1,
|
|
23165
|
+
"parameters": [
|
|
23166
|
+
{
|
|
23167
|
+
"parameterName": "vendor",
|
|
23168
|
+
"parameterTypeTokenRange": {
|
|
23169
|
+
"startIndex": 1,
|
|
23170
|
+
"endIndex": 2
|
|
23171
|
+
},
|
|
23172
|
+
"isOptional": false
|
|
23173
|
+
}
|
|
23174
|
+
],
|
|
23175
|
+
"isOptional": false,
|
|
23176
|
+
"isAbstract": false,
|
|
23177
|
+
"name": "switchTo"
|
|
23178
|
+
},
|
|
23179
|
+
{
|
|
23180
|
+
"kind": "Property",
|
|
23181
|
+
"canonicalReference": "@genesislcap/ai-assistant!TieredAIProviderSwitcher#vendor:member",
|
|
23182
|
+
"docComment": "",
|
|
23183
|
+
"excerptTokens": [
|
|
23184
|
+
{
|
|
23185
|
+
"kind": "Content",
|
|
23186
|
+
"text": "get vendor(): "
|
|
23187
|
+
},
|
|
23188
|
+
{
|
|
23189
|
+
"kind": "Reference",
|
|
23190
|
+
"text": "AITierVendor",
|
|
23191
|
+
"canonicalReference": "@genesislcap/foundation-ai!AITierVendor:type"
|
|
23192
|
+
},
|
|
23193
|
+
{
|
|
23194
|
+
"kind": "Content",
|
|
23195
|
+
"text": ";"
|
|
23196
|
+
}
|
|
23197
|
+
],
|
|
23198
|
+
"isReadonly": true,
|
|
23199
|
+
"isOptional": false,
|
|
23200
|
+
"releaseTag": "Beta",
|
|
23201
|
+
"name": "vendor",
|
|
23202
|
+
"propertyTypeTokenRange": {
|
|
23203
|
+
"startIndex": 1,
|
|
23204
|
+
"endIndex": 2
|
|
23205
|
+
},
|
|
23206
|
+
"isStatic": false,
|
|
23207
|
+
"isProtected": false,
|
|
23208
|
+
"isAbstract": false
|
|
23209
|
+
},
|
|
23210
|
+
{
|
|
23211
|
+
"kind": "Property",
|
|
23212
|
+
"canonicalReference": "@genesislcap/ai-assistant!TieredAIProviderSwitcher#vendors:member",
|
|
23213
|
+
"docComment": "",
|
|
23214
|
+
"excerptTokens": [
|
|
23215
|
+
{
|
|
23216
|
+
"kind": "Content",
|
|
23217
|
+
"text": "readonly vendors: "
|
|
23218
|
+
},
|
|
23219
|
+
{
|
|
23220
|
+
"kind": "Content",
|
|
23221
|
+
"text": "readonly "
|
|
23222
|
+
},
|
|
23223
|
+
{
|
|
23224
|
+
"kind": "Reference",
|
|
23225
|
+
"text": "AITierVendor",
|
|
23226
|
+
"canonicalReference": "@genesislcap/foundation-ai!AITierVendor:type"
|
|
23227
|
+
},
|
|
23228
|
+
{
|
|
23229
|
+
"kind": "Content",
|
|
23230
|
+
"text": "[]"
|
|
23231
|
+
},
|
|
23232
|
+
{
|
|
23233
|
+
"kind": "Content",
|
|
23234
|
+
"text": ";"
|
|
23235
|
+
}
|
|
23236
|
+
],
|
|
23237
|
+
"isReadonly": true,
|
|
23238
|
+
"isOptional": false,
|
|
23239
|
+
"releaseTag": "Beta",
|
|
23240
|
+
"name": "vendors",
|
|
23241
|
+
"propertyTypeTokenRange": {
|
|
23242
|
+
"startIndex": 1,
|
|
23243
|
+
"endIndex": 4
|
|
23244
|
+
},
|
|
23245
|
+
"isStatic": false,
|
|
23246
|
+
"isProtected": false,
|
|
23247
|
+
"isAbstract": false
|
|
23248
|
+
}
|
|
23249
|
+
],
|
|
23250
|
+
"implementsTokenRanges": [
|
|
23251
|
+
{
|
|
23252
|
+
"startIndex": 1,
|
|
23253
|
+
"endIndex": 2
|
|
23254
|
+
}
|
|
23255
|
+
]
|
|
23256
|
+
},
|
|
23257
|
+
{
|
|
23258
|
+
"kind": "Interface",
|
|
23259
|
+
"canonicalReference": "@genesislcap/ai-assistant!TieredAIProviderSwitcherOptions:interface",
|
|
23260
|
+
"docComment": "/**\n * Options for {@link TieredAIProviderSwitcher}.\n *\n * @beta\n */\n",
|
|
23261
|
+
"excerptTokens": [
|
|
23262
|
+
{
|
|
23263
|
+
"kind": "Content",
|
|
23264
|
+
"text": "export interface TieredAIProviderSwitcherOptions "
|
|
23265
|
+
}
|
|
23266
|
+
],
|
|
23267
|
+
"fileUrlPath": "src/provider/tiered-provider-switcher.ts",
|
|
23268
|
+
"releaseTag": "Beta",
|
|
23269
|
+
"name": "TieredAIProviderSwitcherOptions",
|
|
23270
|
+
"preserveMemberOrder": false,
|
|
23271
|
+
"members": [
|
|
23272
|
+
{
|
|
23273
|
+
"kind": "PropertySignature",
|
|
23274
|
+
"canonicalReference": "@genesislcap/ai-assistant!TieredAIProviderSwitcherOptions#container:member",
|
|
23275
|
+
"docComment": "/**\n * DI container the provider registry is registered on.\n */\n",
|
|
23276
|
+
"excerptTokens": [
|
|
23277
|
+
{
|
|
23278
|
+
"kind": "Content",
|
|
23279
|
+
"text": "container: "
|
|
23280
|
+
},
|
|
23281
|
+
{
|
|
23282
|
+
"kind": "Reference",
|
|
23283
|
+
"text": "Container",
|
|
23284
|
+
"canonicalReference": "@microsoft/fast-foundation!Container:interface"
|
|
23285
|
+
},
|
|
23286
|
+
{
|
|
23287
|
+
"kind": "Content",
|
|
23288
|
+
"text": ";"
|
|
23289
|
+
}
|
|
23290
|
+
],
|
|
23291
|
+
"isReadonly": false,
|
|
23292
|
+
"isOptional": false,
|
|
23293
|
+
"releaseTag": "Beta",
|
|
23294
|
+
"name": "container",
|
|
23295
|
+
"propertyTypeTokenRange": {
|
|
23296
|
+
"startIndex": 1,
|
|
23297
|
+
"endIndex": 2
|
|
23298
|
+
}
|
|
23299
|
+
},
|
|
23300
|
+
{
|
|
23301
|
+
"kind": "PropertySignature",
|
|
23302
|
+
"canonicalReference": "@genesislcap/ai-assistant!TieredAIProviderSwitcherOptions#defaultTier:member",
|
|
23303
|
+
"docComment": "/**\n * Which tier the registry resolves for a caller that names no provider. Defaults to `'high'`.\n *\n * High rather than the cheapest, because of what resolves through it: an orchestrated turn classifies against the REGISTRY DEFAULT, so the classifier sees the session's accumulated history on whatever model this names. On the smallest-window tier, a session grown to size on a bigger model can hand the classifier a history that no longer fits — and the routing turn fails at the moment it was supposed to hand off to a model that could have taken it.\n */\n",
|
|
23304
|
+
"excerptTokens": [
|
|
23305
|
+
{
|
|
23306
|
+
"kind": "Content",
|
|
23307
|
+
"text": "defaultTier?: "
|
|
23308
|
+
},
|
|
23309
|
+
{
|
|
23310
|
+
"kind": "Reference",
|
|
23311
|
+
"text": "AITierId",
|
|
23312
|
+
"canonicalReference": "@genesislcap/foundation-ai!AITierId:type"
|
|
23313
|
+
},
|
|
23314
|
+
{
|
|
23315
|
+
"kind": "Content",
|
|
23316
|
+
"text": ";"
|
|
23317
|
+
}
|
|
23318
|
+
],
|
|
23319
|
+
"isReadonly": false,
|
|
23320
|
+
"isOptional": true,
|
|
23321
|
+
"releaseTag": "Beta",
|
|
23322
|
+
"name": "defaultTier",
|
|
23323
|
+
"propertyTypeTokenRange": {
|
|
23324
|
+
"startIndex": 1,
|
|
23325
|
+
"endIndex": 2
|
|
23326
|
+
}
|
|
23327
|
+
},
|
|
23328
|
+
{
|
|
23329
|
+
"kind": "PropertySignature",
|
|
23330
|
+
"canonicalReference": "@genesislcap/ai-assistant!TieredAIProviderSwitcherOptions#initialVendor:member",
|
|
23331
|
+
"docComment": "/**\n * The vendor to boot on. Required, and deliberately so: the platform has no opinion about which cloud vendor an app should use, and a silent default would make one app's choice look like a platform decision.\n */\n",
|
|
23332
|
+
"excerptTokens": [
|
|
23333
|
+
{
|
|
23334
|
+
"kind": "Content",
|
|
23335
|
+
"text": "initialVendor: "
|
|
23336
|
+
},
|
|
23337
|
+
{
|
|
23338
|
+
"kind": "Reference",
|
|
23339
|
+
"text": "AITierVendor",
|
|
23340
|
+
"canonicalReference": "@genesislcap/foundation-ai!AITierVendor:type"
|
|
23341
|
+
},
|
|
23342
|
+
{
|
|
23343
|
+
"kind": "Content",
|
|
23344
|
+
"text": ";"
|
|
23345
|
+
}
|
|
23346
|
+
],
|
|
23347
|
+
"isReadonly": false,
|
|
23348
|
+
"isOptional": false,
|
|
23349
|
+
"releaseTag": "Beta",
|
|
23350
|
+
"name": "initialVendor",
|
|
23351
|
+
"propertyTypeTokenRange": {
|
|
23352
|
+
"startIndex": 1,
|
|
23353
|
+
"endIndex": 2
|
|
23354
|
+
}
|
|
23355
|
+
},
|
|
23356
|
+
{
|
|
23357
|
+
"kind": "PropertySignature",
|
|
23358
|
+
"canonicalReference": "@genesislcap/ai-assistant!TieredAIProviderSwitcherOptions#onSwitch:member",
|
|
23359
|
+
"docComment": "/**\n * Called when {@link TieredAIProviderSwitcher.switchTo} accepts a vendor — the hook for an app that persists the user's choice.\n *\n * Fires even when the chosen vendor is the one already active. That is not a redundant call: during boot the registry shows this app's initial vendor while a stored preference may still be loading, so \"confirm what I can see\" and \"leave it alone\" are different acts.\n */\n",
|
|
23360
|
+
"excerptTokens": [
|
|
23361
|
+
{
|
|
23362
|
+
"kind": "Content",
|
|
23363
|
+
"text": "onSwitch?: "
|
|
23364
|
+
},
|
|
23365
|
+
{
|
|
23366
|
+
"kind": "Content",
|
|
23367
|
+
"text": "(vendor: "
|
|
23368
|
+
},
|
|
23369
|
+
{
|
|
23370
|
+
"kind": "Reference",
|
|
23371
|
+
"text": "AITierVendor",
|
|
23372
|
+
"canonicalReference": "@genesislcap/foundation-ai!AITierVendor:type"
|
|
23373
|
+
},
|
|
23374
|
+
{
|
|
23375
|
+
"kind": "Content",
|
|
23376
|
+
"text": ") => void"
|
|
23377
|
+
},
|
|
23378
|
+
{
|
|
23379
|
+
"kind": "Content",
|
|
23380
|
+
"text": ";"
|
|
23381
|
+
}
|
|
23382
|
+
],
|
|
23383
|
+
"isReadonly": false,
|
|
23384
|
+
"isOptional": true,
|
|
23385
|
+
"releaseTag": "Beta",
|
|
23386
|
+
"name": "onSwitch",
|
|
23387
|
+
"propertyTypeTokenRange": {
|
|
23388
|
+
"startIndex": 1,
|
|
23389
|
+
"endIndex": 4
|
|
23390
|
+
}
|
|
23391
|
+
},
|
|
23392
|
+
{
|
|
23393
|
+
"kind": "PropertySignature",
|
|
23394
|
+
"canonicalReference": "@genesislcap/ai-assistant!TieredAIProviderSwitcherOptions#serverEndpoint:member",
|
|
23395
|
+
"docComment": "/**\n * Where each vendor's tiers post, as a function of the vendor — for example one that returns `/gwf/ai-service/<vendor>/chat`.\n *\n * A function and never a plain string, because the switcher builds MORE than one vendor: the active one, a standby for each other vendor, and every tier again after a switch. A single string would send all of them to the one vendor's proxy, so picking the other vendor in settings would post Anthropic-shaped requests to a Gemini route — failing on every turn rather than at bootstrap. An app that only ever reaches one vendor narrows `vendors` and still passes a function; it just ignores its argument.\n */\n",
|
|
23396
|
+
"excerptTokens": [
|
|
23397
|
+
{
|
|
23398
|
+
"kind": "Content",
|
|
23399
|
+
"text": "serverEndpoint: "
|
|
23400
|
+
},
|
|
23401
|
+
{
|
|
23402
|
+
"kind": "Content",
|
|
23403
|
+
"text": "(vendor: "
|
|
23404
|
+
},
|
|
23405
|
+
{
|
|
23406
|
+
"kind": "Reference",
|
|
23407
|
+
"text": "AITierVendor",
|
|
23408
|
+
"canonicalReference": "@genesislcap/foundation-ai!AITierVendor:type"
|
|
23409
|
+
},
|
|
23410
|
+
{
|
|
23411
|
+
"kind": "Content",
|
|
23412
|
+
"text": ") => string"
|
|
23413
|
+
},
|
|
23414
|
+
{
|
|
23415
|
+
"kind": "Content",
|
|
23416
|
+
"text": ";"
|
|
23417
|
+
}
|
|
23418
|
+
],
|
|
23419
|
+
"isReadonly": false,
|
|
23420
|
+
"isOptional": false,
|
|
23421
|
+
"releaseTag": "Beta",
|
|
23422
|
+
"name": "serverEndpoint",
|
|
23423
|
+
"propertyTypeTokenRange": {
|
|
23424
|
+
"startIndex": 1,
|
|
23425
|
+
"endIndex": 4
|
|
23426
|
+
}
|
|
23427
|
+
},
|
|
23428
|
+
{
|
|
23429
|
+
"kind": "PropertySignature",
|
|
23430
|
+
"canonicalReference": "@genesislcap/ai-assistant!TieredAIProviderSwitcherOptions#tiers:member",
|
|
23431
|
+
"docComment": "/**\n * The tier table to build from. Defaults to the platform's.\n */\n",
|
|
23432
|
+
"excerptTokens": [
|
|
23433
|
+
{
|
|
23434
|
+
"kind": "Content",
|
|
23435
|
+
"text": "tiers?: "
|
|
23436
|
+
},
|
|
23437
|
+
{
|
|
23438
|
+
"kind": "Reference",
|
|
23439
|
+
"text": "AITiers",
|
|
23440
|
+
"canonicalReference": "@genesislcap/foundation-ai!AITiers:interface"
|
|
23441
|
+
},
|
|
23442
|
+
{
|
|
23443
|
+
"kind": "Content",
|
|
23444
|
+
"text": ";"
|
|
23445
|
+
}
|
|
23446
|
+
],
|
|
23447
|
+
"isReadonly": false,
|
|
23448
|
+
"isOptional": true,
|
|
23449
|
+
"releaseTag": "Beta",
|
|
23450
|
+
"name": "tiers",
|
|
23451
|
+
"propertyTypeTokenRange": {
|
|
23452
|
+
"startIndex": 1,
|
|
23453
|
+
"endIndex": 2
|
|
23454
|
+
}
|
|
23455
|
+
},
|
|
23456
|
+
{
|
|
23457
|
+
"kind": "PropertySignature",
|
|
23458
|
+
"canonicalReference": "@genesislcap/ai-assistant!TieredAIProviderSwitcherOptions#vendors:member",
|
|
23459
|
+
"docComment": "/**\n * The vendors this app can switch between. Defaults to every vendor in the table.\n *\n * Narrow it when the app's proxy can only reach one: the others would otherwise report a status, and the assistant's partial-wall UX reads statuses — so a walled vendor would offer \"switch to the other one\" about a vendor that has no key behind it.\n */\n",
|
|
23460
|
+
"excerptTokens": [
|
|
23461
|
+
{
|
|
23462
|
+
"kind": "Content",
|
|
23463
|
+
"text": "vendors?: "
|
|
23464
|
+
},
|
|
23465
|
+
{
|
|
23466
|
+
"kind": "Content",
|
|
23467
|
+
"text": "readonly "
|
|
23468
|
+
},
|
|
23469
|
+
{
|
|
23470
|
+
"kind": "Reference",
|
|
23471
|
+
"text": "AITierVendor",
|
|
23472
|
+
"canonicalReference": "@genesislcap/foundation-ai!AITierVendor:type"
|
|
23473
|
+
},
|
|
23474
|
+
{
|
|
23475
|
+
"kind": "Content",
|
|
23476
|
+
"text": "[]"
|
|
23477
|
+
},
|
|
23478
|
+
{
|
|
23479
|
+
"kind": "Content",
|
|
23480
|
+
"text": ";"
|
|
23481
|
+
}
|
|
23482
|
+
],
|
|
23483
|
+
"isReadonly": false,
|
|
23484
|
+
"isOptional": true,
|
|
23485
|
+
"releaseTag": "Beta",
|
|
23486
|
+
"name": "vendors",
|
|
23487
|
+
"propertyTypeTokenRange": {
|
|
23488
|
+
"startIndex": 1,
|
|
23489
|
+
"endIndex": 4
|
|
23490
|
+
}
|
|
23491
|
+
}
|
|
23492
|
+
],
|
|
23493
|
+
"extendsTokenRanges": []
|
|
23494
|
+
},
|
|
23495
|
+
{
|
|
23496
|
+
"kind": "TypeAlias",
|
|
22685
23497
|
"canonicalReference": "@genesislcap/ai-assistant!TimelineMessage:type",
|
|
22686
23498
|
"docComment": "/**\n * A chat message lifted into the debug-log timeline as a `kind: 'message'` entry.\n *\n * @beta\n */\n",
|
|
22687
23499
|
"excerptTokens": [
|
|
@@ -23673,6 +24485,209 @@
|
|
|
23673
24485
|
"endIndex": 0
|
|
23674
24486
|
}
|
|
23675
24487
|
},
|
|
24488
|
+
{
|
|
24489
|
+
"kind": "Interface",
|
|
24490
|
+
"canonicalReference": "@genesislcap/ai-assistant!VendorBudgetFigures:interface",
|
|
24491
|
+
"docComment": "/**\n * One vendor's AI-spend figures, as fed by the host from the budget endpoint (GENC-1464 — the settings-modal budget meter).\n *\n * Dollars, not a percentage: the meter's text shows the real figures (spend CAN exceed the cap — the last allowed call may overshoot it), and only the bar clamps. Storing a pre-computed percentage would destroy the overshoot.\n *\n * @beta\n */\n",
|
|
24492
|
+
"excerptTokens": [
|
|
24493
|
+
{
|
|
24494
|
+
"kind": "Content",
|
|
24495
|
+
"text": "export interface VendorBudgetFigures "
|
|
24496
|
+
}
|
|
24497
|
+
],
|
|
24498
|
+
"fileUrlPath": "src/state/ai-assistant-slice.ts",
|
|
24499
|
+
"releaseTag": "Beta",
|
|
24500
|
+
"name": "VendorBudgetFigures",
|
|
24501
|
+
"preserveMemberOrder": false,
|
|
24502
|
+
"members": [
|
|
24503
|
+
{
|
|
24504
|
+
"kind": "PropertySignature",
|
|
24505
|
+
"canonicalReference": "@genesislcap/ai-assistant!VendorBudgetFigures#budgetUsd:member",
|
|
24506
|
+
"docComment": "/**\n * The vendor's budget cap in USD. Finite and `>= 0`.\n */\n",
|
|
24507
|
+
"excerptTokens": [
|
|
24508
|
+
{
|
|
24509
|
+
"kind": "Content",
|
|
24510
|
+
"text": "budgetUsd: "
|
|
24511
|
+
},
|
|
24512
|
+
{
|
|
24513
|
+
"kind": "Content",
|
|
24514
|
+
"text": "number"
|
|
24515
|
+
},
|
|
24516
|
+
{
|
|
24517
|
+
"kind": "Content",
|
|
24518
|
+
"text": ";"
|
|
24519
|
+
}
|
|
24520
|
+
],
|
|
24521
|
+
"isReadonly": false,
|
|
24522
|
+
"isOptional": false,
|
|
24523
|
+
"releaseTag": "Beta",
|
|
24524
|
+
"name": "budgetUsd",
|
|
24525
|
+
"propertyTypeTokenRange": {
|
|
24526
|
+
"startIndex": 1,
|
|
24527
|
+
"endIndex": 2
|
|
24528
|
+
}
|
|
24529
|
+
},
|
|
24530
|
+
{
|
|
24531
|
+
"kind": "PropertySignature",
|
|
24532
|
+
"canonicalReference": "@genesislcap/ai-assistant!VendorBudgetFigures#segments:member",
|
|
24533
|
+
"docComment": "/**\n * Optional breakdown of {@link VendorBudgetFigures.spentUsd} by whatever the host meters spend by — a surface, a team, an environment. Given, the vendor's bar is drawn stacked with a legend; omitted, it is the single bar it has always been.\n *\n * Host-named, with no platform vocabulary: the assistant has no idea what a host's spend sources are, and inventing labels for them is how a product word ends up in the platform. Segments may cover less than the total (the remainder simply draws unlabelled); they may not cover more, which would be a breakdown of a figure other than the one on screen.\n *\n * ORDER IS SIGNIFICANT: the bar and legend are drawn in array order, and the first segment gets the strongest tone (full strength whenever the whole spend is attributed). Feed the sources in a fixed, meaningful order — the one you want drawn first, first — and keep it across re-feeds; a host that re-sorts its sources per response moves the strongest tone between them with no change in the money.\n */\n",
|
|
24534
|
+
"excerptTokens": [
|
|
24535
|
+
{
|
|
24536
|
+
"kind": "Content",
|
|
24537
|
+
"text": "segments?: "
|
|
24538
|
+
},
|
|
24539
|
+
{
|
|
24540
|
+
"kind": "Reference",
|
|
24541
|
+
"text": "VendorBudgetSegment",
|
|
24542
|
+
"canonicalReference": "@genesislcap/ai-assistant!VendorBudgetSegment:interface"
|
|
24543
|
+
},
|
|
24544
|
+
{
|
|
24545
|
+
"kind": "Content",
|
|
24546
|
+
"text": "[]"
|
|
24547
|
+
},
|
|
24548
|
+
{
|
|
24549
|
+
"kind": "Content",
|
|
24550
|
+
"text": ";"
|
|
24551
|
+
}
|
|
24552
|
+
],
|
|
24553
|
+
"isReadonly": false,
|
|
24554
|
+
"isOptional": true,
|
|
24555
|
+
"releaseTag": "Beta",
|
|
24556
|
+
"name": "segments",
|
|
24557
|
+
"propertyTypeTokenRange": {
|
|
24558
|
+
"startIndex": 1,
|
|
24559
|
+
"endIndex": 3
|
|
24560
|
+
}
|
|
24561
|
+
},
|
|
24562
|
+
{
|
|
24563
|
+
"kind": "PropertySignature",
|
|
24564
|
+
"canonicalReference": "@genesislcap/ai-assistant!VendorBudgetFigures#spentUsd:member",
|
|
24565
|
+
"docComment": "/**\n * Metered spend against that cap in USD. Finite and `>= 0`; may exceed the cap.\n */\n",
|
|
24566
|
+
"excerptTokens": [
|
|
24567
|
+
{
|
|
24568
|
+
"kind": "Content",
|
|
24569
|
+
"text": "spentUsd: "
|
|
24570
|
+
},
|
|
24571
|
+
{
|
|
24572
|
+
"kind": "Content",
|
|
24573
|
+
"text": "number"
|
|
24574
|
+
},
|
|
24575
|
+
{
|
|
24576
|
+
"kind": "Content",
|
|
24577
|
+
"text": ";"
|
|
24578
|
+
}
|
|
24579
|
+
],
|
|
24580
|
+
"isReadonly": false,
|
|
24581
|
+
"isOptional": false,
|
|
24582
|
+
"releaseTag": "Beta",
|
|
24583
|
+
"name": "spentUsd",
|
|
24584
|
+
"propertyTypeTokenRange": {
|
|
24585
|
+
"startIndex": 1,
|
|
24586
|
+
"endIndex": 2
|
|
24587
|
+
}
|
|
24588
|
+
}
|
|
24589
|
+
],
|
|
24590
|
+
"extendsTokenRanges": []
|
|
24591
|
+
},
|
|
24592
|
+
{
|
|
24593
|
+
"kind": "Interface",
|
|
24594
|
+
"canonicalReference": "@genesislcap/ai-assistant!VendorBudgetSegment:interface",
|
|
24595
|
+
"docComment": "/**\n * One slice of a vendor's spend — see {@link VendorBudgetFigures.segments}.\n *\n * @beta\n */\n",
|
|
24596
|
+
"excerptTokens": [
|
|
24597
|
+
{
|
|
24598
|
+
"kind": "Content",
|
|
24599
|
+
"text": "export interface VendorBudgetSegment "
|
|
24600
|
+
}
|
|
24601
|
+
],
|
|
24602
|
+
"fileUrlPath": "src/state/ai-assistant-slice.ts",
|
|
24603
|
+
"releaseTag": "Beta",
|
|
24604
|
+
"name": "VendorBudgetSegment",
|
|
24605
|
+
"preserveMemberOrder": false,
|
|
24606
|
+
"members": [
|
|
24607
|
+
{
|
|
24608
|
+
"kind": "PropertySignature",
|
|
24609
|
+
"canonicalReference": "@genesislcap/ai-assistant!VendorBudgetSegment#id:member",
|
|
24610
|
+
"docComment": "/**\n * Identifies the source. Must be unique within a breakdown, and must not be `__remainder__`, which the meter reserves for unattributed spend; a breakdown that breaks either rule is dropped. It does not decide drawing order or tone — array order does.\n */\n",
|
|
24611
|
+
"excerptTokens": [
|
|
24612
|
+
{
|
|
24613
|
+
"kind": "Content",
|
|
24614
|
+
"text": "id: "
|
|
24615
|
+
},
|
|
24616
|
+
{
|
|
24617
|
+
"kind": "Content",
|
|
24618
|
+
"text": "string"
|
|
24619
|
+
},
|
|
24620
|
+
{
|
|
24621
|
+
"kind": "Content",
|
|
24622
|
+
"text": ";"
|
|
24623
|
+
}
|
|
24624
|
+
],
|
|
24625
|
+
"isReadonly": false,
|
|
24626
|
+
"isOptional": false,
|
|
24627
|
+
"releaseTag": "Beta",
|
|
24628
|
+
"name": "id",
|
|
24629
|
+
"propertyTypeTokenRange": {
|
|
24630
|
+
"startIndex": 1,
|
|
24631
|
+
"endIndex": 2
|
|
24632
|
+
}
|
|
24633
|
+
},
|
|
24634
|
+
{
|
|
24635
|
+
"kind": "PropertySignature",
|
|
24636
|
+
"canonicalReference": "@genesislcap/ai-assistant!VendorBudgetSegment#label:member",
|
|
24637
|
+
"docComment": "/**\n * What the host calls this slice of the spend; rendered verbatim in the legend.\n */\n",
|
|
24638
|
+
"excerptTokens": [
|
|
24639
|
+
{
|
|
24640
|
+
"kind": "Content",
|
|
24641
|
+
"text": "label: "
|
|
24642
|
+
},
|
|
24643
|
+
{
|
|
24644
|
+
"kind": "Content",
|
|
24645
|
+
"text": "string"
|
|
24646
|
+
},
|
|
24647
|
+
{
|
|
24648
|
+
"kind": "Content",
|
|
24649
|
+
"text": ";"
|
|
24650
|
+
}
|
|
24651
|
+
],
|
|
24652
|
+
"isReadonly": false,
|
|
24653
|
+
"isOptional": false,
|
|
24654
|
+
"releaseTag": "Beta",
|
|
24655
|
+
"name": "label",
|
|
24656
|
+
"propertyTypeTokenRange": {
|
|
24657
|
+
"startIndex": 1,
|
|
24658
|
+
"endIndex": 2
|
|
24659
|
+
}
|
|
24660
|
+
},
|
|
24661
|
+
{
|
|
24662
|
+
"kind": "PropertySignature",
|
|
24663
|
+
"canonicalReference": "@genesislcap/ai-assistant!VendorBudgetSegment#spentUsd:member",
|
|
24664
|
+
"docComment": "/**\n * This slice's share of the spend in USD. Finite and `>= 0`.\n */\n",
|
|
24665
|
+
"excerptTokens": [
|
|
24666
|
+
{
|
|
24667
|
+
"kind": "Content",
|
|
24668
|
+
"text": "spentUsd: "
|
|
24669
|
+
},
|
|
24670
|
+
{
|
|
24671
|
+
"kind": "Content",
|
|
24672
|
+
"text": "number"
|
|
24673
|
+
},
|
|
24674
|
+
{
|
|
24675
|
+
"kind": "Content",
|
|
24676
|
+
"text": ";"
|
|
24677
|
+
}
|
|
24678
|
+
],
|
|
24679
|
+
"isReadonly": false,
|
|
24680
|
+
"isOptional": false,
|
|
24681
|
+
"releaseTag": "Beta",
|
|
24682
|
+
"name": "spentUsd",
|
|
24683
|
+
"propertyTypeTokenRange": {
|
|
24684
|
+
"startIndex": 1,
|
|
24685
|
+
"endIndex": 2
|
|
24686
|
+
}
|
|
24687
|
+
}
|
|
24688
|
+
],
|
|
24689
|
+
"extendsTokenRanges": []
|
|
24690
|
+
},
|
|
23676
24691
|
{
|
|
23677
24692
|
"kind": "Class",
|
|
23678
24693
|
"canonicalReference": "@genesislcap/ai-assistant!WebStorageSessionProvider:class",
|