({ providerProfile, cwd, title, metadata, ephemeral = null })
| 318 | } |
| 319 | |
| 320 | async startThread({ providerProfile, cwd, title, metadata, ephemeral = null }) { |
| 321 | this.threadCounter += 1; |
| 322 | this.startThreadCalls.push({ providerProfile, cwd, title, metadata, ephemeral }); |
| 323 | const thread = { |
| 324 | threadId: `${providerProfile.id}-thread-${this.threadCounter}`, |
| 325 | cwd: cwd ?? `/tmp/${providerProfile.id}`, |
| 326 | title: title ?? `${providerProfile.displayName} thread ${this.threadCounter}`, |
| 327 | updatedAt: this.nextUpdatedAt(), |
| 328 | preview: '', |
| 329 | turns: [], |
| 330 | }; |
| 331 | this.threads.set(thread.threadId, thread); |
| 332 | return thread; |
| 333 | } |
| 334 | |
| 335 | async stop() { |
| 336 | this.stopCalls.push({ at: Date.now() }); |
nothing calls this directly
no test coverage detected