@@ -114,10 +114,9 @@ export class ManageTodoListTool extends Disposable implements IToolImpl {
114114
115115 async invoke ( invocation : IToolInvocation , _countTokens : any , _progress : any , _token : CancellationToken ) : Promise < IToolResult > {
116116 const args = invocation . parameters as IManageTodoListToolInputParams ;
117- const chatSessionId = invocation . context ?. sessionId ?? args . chatSessionId ;
118- if ( chatSessionId === undefined ) {
119- throw new Error ( 'A chat session ID is required for this tool' ) ;
120- }
117+ // For: #263001 Use default sessionId
118+ const DEFAULT_TODO_SESSION_ID = 'default' ;
119+ const chatSessionId = invocation . context ?. sessionId ?? args . chatSessionId ?? DEFAULT_TODO_SESSION_ID ;
121120
122121 this . logService . debug ( `ManageTodoListTool: Invoking with options ${ JSON . stringify ( args ) } ` ) ;
123122
@@ -160,10 +159,9 @@ export class ManageTodoListTool extends Disposable implements IToolImpl {
160159
161160 async prepareToolInvocation ( context : IToolInvocationPreparationContext , _token : CancellationToken ) : Promise < IPreparedToolInvocation | undefined > {
162161 const args = context . parameters as IManageTodoListToolInputParams ;
163- const chatSessionId = context . chatSessionId ?? args . chatSessionId ;
164- if ( ! chatSessionId ) {
165- throw new Error ( 'chatSessionId undefined' ) ;
166- }
162+ // For: #263001 Use default sessionId
163+ const DEFAULT_TODO_SESSION_ID = 'default' ;
164+ const chatSessionId = context . chatSessionId ?? args . chatSessionId ?? DEFAULT_TODO_SESSION_ID ;
167165
168166 const items = args . todoList ?? this . chatTodoListService . getTodos ( chatSessionId ) ;
169167 const todoList = items . map ( todo => ( {
0 commit comments