@makinbakin/sdk 0.0.1-rc.27 → 0.0.1-rc.29
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/_internal/app/hooks/use-horizontal-resize.d.ts +2 -3
- package/_internal/app/hooks/use-resizable-pane.d.ts +2 -2
- package/_internal/core/adapters/runtime/concepts.d.ts +15 -1
- package/_internal/core/adapters/runtime/errors.d.ts +7 -0
- package/conversation/index.js +1 -1
- package/hooks/index.d.ts +0 -7
- package/hooks/index.js +1 -1
- package/package.json +1 -1
- package/patterns/index.d.ts +3 -3
- package/patterns/index.js +2 -2
- package/slots/index.d.ts +0 -4
- package/slots/index.js +1 -1
- package/styles.css +1 -1
- package/types/runtime.d.ts +6 -0
- package/types/services.d.ts +23 -0
- package/ui/index.js +1 -1
- package/utils/index.d.ts +1 -2
- package/utils/index.js +2 -2
- package/_internal/app/hooks/use-file-drop.d.ts +0 -25
- package/_internal/app/hooks/use-form-guard.d.ts +0 -5
- package/_internal/app/hooks/use-vertical-resize.d.ts +0 -21
|
@@ -14,9 +14,8 @@ interface Return {
|
|
|
14
14
|
/**
|
|
15
15
|
* Resize a right-anchored panel by dragging its left edge. The handle lives at
|
|
16
16
|
* the left of the element; dragging left grows the panel, dragging right
|
|
17
|
-
* shrinks it. Keyboard: ArrowLeft/ArrowRight (Shift for a larger step).
|
|
18
|
-
*
|
|
19
|
-
* thin wrappers over {@link useResizablePane}.
|
|
17
|
+
* shrinks it. Keyboard: ArrowLeft/ArrowRight (Shift for a larger step).
|
|
18
|
+
* Thin wrapper over {@link useResizablePane} for side-by-side split panes.
|
|
20
19
|
*/
|
|
21
20
|
export declare function useHorizontalResize({ defaultWidth, minWidth, maxWidth, storageKey }: Options): Return;
|
|
22
21
|
export {};
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Shared
|
|
2
|
+
* Shared split-pane resize behavior. A pane is anchored to the
|
|
3
3
|
* trailing edge (bottom for 'y', right for 'x') and resized by dragging the
|
|
4
4
|
* divider on its leading edge — dragging toward that edge (up / left) grows it.
|
|
5
|
-
* {@link
|
|
5
|
+
* {@link useHorizontalResize} provides the right-anchored panel wrapper;
|
|
6
6
|
* keep all drag / persistence / a11y logic here so it lives in exactly one place.
|
|
7
7
|
*/
|
|
8
8
|
export type ResizeAxis = 'x' | 'y';
|
|
@@ -237,7 +237,9 @@ export type ChatChunk =
|
|
|
237
237
|
data?: RuntimeMetadata;
|
|
238
238
|
usage?: MessageUsage;
|
|
239
239
|
}
|
|
240
|
-
/** Terminal failure — `data.kind` carries the RuntimeError kind when known
|
|
240
|
+
/** Terminal failure — `data.kind` carries the RuntimeError kind when known;
|
|
241
|
+
* `data.model` names the qualified model id when the failure was the
|
|
242
|
+
* provider rejecting that model (kind 'model_not_supported', #852). */
|
|
241
243
|
| {
|
|
242
244
|
type: 'error';
|
|
243
245
|
content?: string;
|
|
@@ -832,6 +834,18 @@ export interface AgentRuntimeAdapter {
|
|
|
832
834
|
listAvailable(opts?: {
|
|
833
835
|
includeUnavailable?: boolean;
|
|
834
836
|
}): Promise<RuntimeAvailableModel[]>;
|
|
837
|
+
/**
|
|
838
|
+
* OPTIONAL capability (#852): verify the ACCOUNT can actually call this
|
|
839
|
+
* model by firing a minimal (~1-token) completion. Resolves on success;
|
|
840
|
+
* rejects with a typed RuntimeError — `model_not_supported` when the
|
|
841
|
+
* provider rejected the model id itself. Adapters without a cheap probe
|
|
842
|
+
* transport OMIT the member; callers feature-detect (`models.probe?.`).
|
|
843
|
+
* Billed (~pennies) and user-triggered only — never called on a
|
|
844
|
+
* schedule or from background refresh paths.
|
|
845
|
+
*/
|
|
846
|
+
probe?(modelId: string, opts?: {
|
|
847
|
+
signal?: AbortSignal;
|
|
848
|
+
}): Promise<void>;
|
|
835
849
|
/** Static declaration of which routing-policy fields this runtime honors. */
|
|
836
850
|
routingSupport(): RuntimeRoutingSupport;
|
|
837
851
|
/** The runtime's current routing policy (unsupported fields empty). */
|
|
@@ -18,6 +18,13 @@ export type RuntimeErrorKind =
|
|
|
18
18
|
| 'provider_cooldown'
|
|
19
19
|
/** Structured runtime failure (HTTP-status class, CLI exit, protocol). */
|
|
20
20
|
| 'runtime_failed'
|
|
21
|
+
/**
|
|
22
|
+
* The provider deterministically rejected the MODEL ID for this account
|
|
23
|
+
* (retired/unentitled model — the #852 class). Not a cooldown: waiting
|
|
24
|
+
* never fixes it, so it is never retried. `providerInfo.model` carries the
|
|
25
|
+
* qualified rejected id; core records it as availability evidence.
|
|
26
|
+
*/
|
|
27
|
+
| 'model_not_supported'
|
|
21
28
|
/**
|
|
22
29
|
* The caller intentionally cancelled the turn (MessageArgs.signal) —
|
|
23
30
|
* terminal: never retried, never diagnosed, never enters the recovery
|