Refactors the initialize_project MCP tool to call a dedicated direct function (initializeProjectDirect) instead of executing the CLI command. This improves reliability and aligns it with other MCP tools.
Key changes include: Modified initialize-project.js to call initializeProjectDirect, required projectRoot parameter, implemented handleApiResult for MCP response formatting, enhanced direct function to prioritize args.projectRoot over session-derived paths, added validation to prevent initialization in invalid directories, forces yes:true for non-interactive use, ensures process.chdir() targets validated directory, and added isSilentMode() checks to suppress console output during MCP operations.
This resolves issues where the tool previously failed due to incorrect fallback directory resolution when session context was incomplete.
Centralizes init command logic within the main CLI structure. The action handler in commands.js now directly calls initializeProject from the init.js module, resolving issues with argument parsing (like -y) and removing the need for the separate bin/task-master-init.js executable. Updates package.json and bin/task-master.js accordingly.
- Enhance MCP server robustness and usability:
- Implement smart project root detection with hierarchical fallbacks
- Make projectRoot parameter optional across all MCP tools
- Add comprehensive PROJECT_MARKERS for reliable project detection
- Improve error messages and logging for better debugging
- Split monolithic core into focused direct-function files
- Implement full suite of MCP commands:
- Add task management: update-task, update-subtask, generate
- Add task organization: expand-task, expand-all, clear-subtasks
- Add dependency handling: add/remove/validate/fix dependencies
- Add analysis tools: analyze-complexity, complexity-report
- Rename commands for better API consistency (list-tasks → get-tasks)
- Enhance documentation and developer experience:
- Create and bundle new taskmaster.mdc as comprehensive reference
- Document all tools with natural language patterns and examples
- Clarify project root auto-detection in documentation
- Standardize naming conventions across MCP components
- Add cross-references between related tools and commands
- Improve UI and progress tracking:
- Add color-coded progress bars with status breakdown
- Implement cancelled/deferred task status handling
- Enhance status visualization and counting
- Optimize display for various terminal sizes
This major update significantly improves the robustness and usability
of the MCP server while providing comprehensive documentation for both
users and developers. The changes make Task Master more intuitive to
use programmatically while maintaining full CLI functionality.
- Add support for comma-separated subtask IDs in remove-subtask command
- Implement MCP configuration in project initialization
- Add package update notification system with version comparison
- Improve command documentation with boolean flag conventions
- Add comprehensive error handling for unknown options
- Update help text with better examples and formatting
- Implement proper validation for command inputs
- Add global error handling patterns with helpful user messages
Fix issue with kebab-case validator incorrectly flagging single-word flags like --prompt. Refactor detectCamelCaseFlags to properly handle all single-word flags. Update tests to verify correct behavior with single-word and camelCase flags. Add support for alternative flag formats in init command (e.g., -my_name). This fixes a bug where users couldn't use the --prompt flag directly and had to use -p instead.
This commit resolves several issues with the task expansion system to
ensure higher quality subtasks and better synchronization:
1. Task File Generation
- Add automatic regeneration of task files after expanding tasks
- Ensure individual task text files stay in sync with tasks.json
- Avoids manual regeneration steps after task expansion
2. Perplexity API Integration
- Fix 'researchPrompt is not defined' error in Perplexity integration
- Add specialized research-oriented prompt template
- Improve system message for better context and instruction
- Better fallback to Claude when Perplexity unavailable
3. Subtask Parsing Improvements
- Enhance regex pattern to handle more formatting variations
- Implement multiple parsing strategies for different response formats:
* Improved section detection with flexible headings
* Added support for numbered and bulleted lists
* Implemented heuristic-based title and description extraction
- Create more meaningful dummy subtasks with relevant titles and descriptions
instead of generic placeholders
- Ensure minimal descriptions are always provided
4. Quality Verification and Retry System
- Add post-expansion verification to identify low-quality subtask sets
- Detect tasks with too many generic/placeholder subtasks
- Implement interactive retry mechanism with enhanced prompts
- Use adjusted settings for retries (research mode, subtask count)
- Clear existing subtasks before retry to prevent duplicates
- Provide detailed reporting of verification and retry process
These changes significantly improve the quality of generated subtasks
and reduce the need for manual intervention when subtask generation
produces suboptimal results.
This commit includes several important improvements:
1. Add support for updating multiple tasks at once with comma-separated IDs
- Modify setTaskStatus to handle lists like id=1,1.1,1.2
- Fix subtask handling to properly update subtask statuses
- Add in-progress as a valid status option
2. Fix initialization script issues
- Add debugging information to help diagnose npx execution problems
- Improve error handling and readline interface management
- Remove conditional check that prevented script from running in some environments
- Add troubleshooting section to README.md
3. Improve package preparation
- Make scripts executable during package preparation
- Update version to 1.0.7
These changes make the package more robust and user-friendly, particularly
for first-time users and those managing complex task hierarchies.
- Update to ES modules syntax throughout the codebase
- Add fileURLToPath and dirname imports to handle __dirname in ES modules
- Upgrade Anthropic SDK from 0.10.0 to 0.39.0
- Fix JSON parsing to handle responses wrapped in Markdown code blocks
- Improve documentation with clearer installation instructions
- Add important notes about ES modules and SDK requirements
- Update environment examples with API key format and model recommendations
- Include index.js in package files list
- Bump version to 1.0.2