refactor(chat): route browser chat through one runtime (P3 Slice-Zero Task 5) (#1172)
ci/woodpecker/push/publish Pipeline failed
ci/woodpecker/push/publish Pipeline failed
Co-authored-by: shaggy <[email protected]>
This commit was merged in pull request #1172.
This commit is contained in:
@@ -42,10 +42,6 @@ export interface HarnessSelectionValue {
|
||||
* resolves the composite option identity to the real entry and passes both
|
||||
* ids, so a bare model id is never combined with ambient provider state. */
|
||||
selectModel: (providerId: string, modelId: string) => void;
|
||||
/** The compatibility `{provider, modelId}` projection for the legacy socket
|
||||
* send path — derived ONLY from the validated persisted tuple, never from any
|
||||
* free-text or unpersisted draft. Empty when nothing is sendable. */
|
||||
projection: { provider?: string; modelId?: string };
|
||||
}
|
||||
|
||||
/** A tuple is a currently-usable catalog option only when the catalog holds a
|
||||
@@ -193,9 +189,6 @@ export function useHarnessSelection(): HarnessSelectionValue {
|
||||
!catalogUnavailable &&
|
||||
tuplesEqual(draft, persistedSelection) &&
|
||||
isAvailableInCatalog(persistedSelection, catalog);
|
||||
const projection: { provider?: string; modelId?: string } = canSend
|
||||
? { provider: persistedSelection.providerId, modelId: persistedSelection.modelId }
|
||||
: {};
|
||||
|
||||
return {
|
||||
harnesses,
|
||||
@@ -211,6 +204,5 @@ export function useHarnessSelection(): HarnessSelectionValue {
|
||||
selectHarness,
|
||||
selectProvider,
|
||||
selectModel,
|
||||
projection,
|
||||
};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user