File tree Expand file tree Collapse file tree 1 file changed +7
-1
lines changed
Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Original file line number Diff line number Diff line change @@ -26,6 +26,7 @@ export interface ChatMessage {
2626export interface ChatConfig {
2727 mode : "debug" | "production" ;
2828 agentId : string ;
29+ promptOverride ?: string ;
2930}
3031
3132export interface ChatPayload {
@@ -45,6 +46,7 @@ export async function callAgent<T = Record<string, unknown>>(
4546 evmAddress : string = "" ,
4647 suiAddress : string = "" ,
4748 solanaAddress : string = "" ,
49+ systemPrompt ?: string ,
4850) : Promise < AgentResponse < T > > {
4951 const chatId = `chat_${ Date . now ( ) } _${ Math . random ( ) . toString ( 36 ) . substr ( 2 , 9 ) } ` ;
5052
@@ -61,7 +63,11 @@ export async function callAgent<T = Record<string, unknown>>(
6163 messageId : Math . random ( ) . toString ( 36 ) . substr ( 2 , 9 ) ,
6264 } ,
6365 ] ,
64- config : { mode : "debug" , agentId } ,
66+ config : {
67+ mode : "debug" ,
68+ agentId,
69+ ...( systemPrompt ? { promptOverride : systemPrompt } : { } ) ,
70+ } ,
6571 } ;
6672
6773 const response = await fetch ( BITTE_API_URL , {
You can’t perform that action at this time.
0 commit comments