-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.ts
More file actions
16 lines (14 loc) · 828 Bytes
/
Copy pathindex.ts
File metadata and controls
16 lines (14 loc) · 828 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
import { localAdvisorAdapter } from './localAdvisorAdapter';
import type { ChatAdapter } from './types';
export type { ChatAdapter, ChatChunk, ChatContext, ChatMessage, ChatRole, ChatMode, ChatSuggestion } from './types';
export { buildChatContext, isValidContext, isValidLevels } from './context';
export { answerText, localAdvisorAdapter } from './localAdvisorAdapter';
/**
* The single swap-point for the ChatService (Adapter Pattern). Today it returns the local,
* offline, rule-based advisor. To wire a network LLM later, implement a new `ChatAdapter` and
* return it here — NO UI, hook, or state code changes (they depend only on the `ChatAdapter`
* contract). That is the entire long-term-scalability guarantee, in one function.
*/
export function getChatAdapter(): ChatAdapter {
return localAdvisorAdapter;
}