diff --git a/typescript/src/agents/amazonBedrockAgent.ts b/typescript/src/agents/amazonBedrockAgent.ts index 58367229..2a997bd0 100644 --- a/typescript/src/agents/amazonBedrockAgent.ts +++ b/typescript/src/agents/amazonBedrockAgent.ts @@ -52,14 +52,15 @@ export class AmazonBedrockAgent extends Agent { userId: string, sessionId: string, chatHistory: ConversationMessage[], - additionalParams?: Record + additionalParams?: Record ): Promise { // Construct the command to invoke the Amazon Bedrock agent with user input const command = new InvokeAgentCommand({ agentId: this.agentId, agentAliasId: this.agentAliasId, - sessionId, - inputText + sessionId: sessionId, + inputText: inputText, + sessionState: additionalParams ? additionalParams.sessionState? additionalParams.sessionState : undefined : undefined, }); try { diff --git a/typescript/src/orchestrator.ts b/typescript/src/orchestrator.ts index f78a27c0..f76f69be 100644 --- a/typescript/src/orchestrator.ts +++ b/typescript/src/orchestrator.ts @@ -345,7 +345,7 @@ export class MultiAgentOrchestrator { userInput: string, userId: string, sessionId: string, - additionalParams: Record = {} + additionalParams: Record = {} ): Promise { this.executionTimes = new Map(); let classifierResult: ClassifierResult;