- Refactors the core `removeTask` function (`task-manager/remove-task.js`) to accept and iterate over comma-separated task/subtask IDs.
- Updates dependency cleanup and file regeneration logic to run once after processing all specified IDs.
- Adjusts the `remove-task` CLI command (`commands.js`) description and confirmation prompt to handle multiple IDs correctly.
- Fixes a bug in the CLI confirmation prompt where task/subtask titles were not being displayed correctly.
- Updates the `remove_task` MCP tool description to reflect the new multi-ID capability.
This addresses the previously known issue where only the first ID in a comma-separated list was processed.
Closes#140
This commit focuses on standardizing configuration and API key access patterns across key modules as part of subtask 61.34.
Key changes include:
- Refactored `ai-services.js` to remove global AI clients and use `resolveEnvVariable` for API key checks. Client instantiation now relies on `getAnthropicClient`/`getPerplexityClient` accepting a session object.
- Refactored `task-manager.js` (`analyzeTaskComplexity` function) to use the unified `generateTextService` from `ai-services-unified.js`, removing direct AI client calls.
- Replaced direct `process.env` access for model parameters and other configurations (`PERPLEXITY_MODEL`, `CONFIG.*`) in `task-manager.js` with calls to the appropriate getters from `config-manager.js` (e.g., `getResearchModelId(session)`, `getMainMaxTokens(session)`).
- Ensured `utils.js` (`resolveEnvVariable`) correctly handles potentially undefined session objects.
- Updated function signatures where necessary to propagate the `session` object for correct context-aware configuration/key retrieval.
This moves towards the goal of using `ai-client-factory.js` and `ai-services-unified.js` as the standard pattern for AI interactions and centralizing configuration management through `config-manager.js`.