refactor/channel & ipc (#349)
Co-authored-by: paisley <8197966+su8su@users.noreply.github.com> Co-authored-by: zuolingxuan <zuolingxuan@bytedance.com>
This commit is contained in:
committed by
GitHub
Unverified
parent
8b45960662
commit
e28eba01e1
18
src/stores/chat/store-api.ts
Normal file
18
src/stores/chat/store-api.ts
Normal file
@@ -0,0 +1,18 @@
|
||||
import type { ChatState } from './types';
|
||||
|
||||
export type ChatSet = (
|
||||
partial: Partial<ChatState> | ((state: ChatState) => Partial<ChatState>),
|
||||
replace?: false,
|
||||
) => void;
|
||||
|
||||
export type ChatGet = () => ChatState;
|
||||
|
||||
export type SessionHistoryActions = Pick<
|
||||
ChatState,
|
||||
'loadSessions' | 'switchSession' | 'newSession' | 'deleteSession' | 'cleanupEmptySession' | 'loadHistory'
|
||||
>;
|
||||
|
||||
export type RuntimeActions = Pick<
|
||||
ChatState,
|
||||
'sendMessage' | 'abortRun' | 'handleChatEvent' | 'toggleThinking' | 'refresh' | 'clearError'
|
||||
>;
|
||||
Reference in New Issue
Block a user