()
| 99 | // ==================== Init ==================== |
| 100 | |
| 101 | init(): AssistantInitResult { |
| 102 | const { fs, assistantsDir } = this.deps |
| 103 | fs.ensureDir(assistantsDir) |
| 104 | |
| 105 | const generalCreated = this.ensureGeneralAssistants() |
| 106 | this.loadAll() |
| 107 | |
| 108 | this.initialized = true |
| 109 | this.deps.logger?.info('AssistantManager', 'Initialized', { |
| 110 | total: this.cache.size, |
| 111 | generalCreated, |
| 112 | }) |
| 113 | |
| 114 | return { total: this.cache.size, generalCreated } |
| 115 | } |
| 116 | |
| 117 | private ensureGeneralAssistants(): boolean { |
| 118 | const { fs, assistantsDir } = this.deps |
no test coverage detected