Skip to main content
Glama

parse_task_list

Convert natural language task lists into structured todos with priority, timeframe, and energy levels for previewing before creation in Coach AI.

Instructions

Parse natural language task list into structured todos (does NOT create them).

Use this to preview what will be created before committing. Then use add_todo(todos_batch=...) to create them.

Or use brain_dump_tasks() for a one-step workflow.

Supports multiple formats:

  • Bullet points: "- Task 1"

  • Numbered lists: "1. Task 2"

  • Checkboxes: "[ ] Task 3"

  • Section headers: "Sprint work:\n- Task 4"

Smart extraction:

  • Priority: "#high", "URGENT:", "!!"

  • Timeframe: "this week", "(this month)", "someday"

  • Time: "(30min)", "~2h"

  • Energy: "[high energy]", "[low effort]"

  • Theme: "#sprint", "@admin"

Args: text: Natural language task list default_priority: Default priority for tasks default_timeframe: Default timeframe for tasks

Returns: JSON string of parsed todos

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
textYes
default_priorityNomedium
default_timeframeNo

Implementation Reference

  • The parse_task_list tool is implemented as an async function in server.py, decorated with @mcp.tool(). It uses the parse_natural_language_task_list helper function to parse the text.
    @mcp.tool()
    async def parse_task_list(
        text: str,
        default_priority: str = "medium",
        default_timeframe: Optional[str] = None,
    ) -> str:
        """Parse natural language task list into structured todos (does NOT create them).
    
        Use this to preview what will be created before committing.
        Then use add_todo(todos_batch=...) to create them.
    
        Or use brain_dump_tasks() for a one-step workflow.
    
        Supports multiple formats:
        - Bullet points: "- Task 1"
        - Numbered lists: "1. Task 2"
        - Checkboxes: "[ ] Task 3"
        - Section headers: "Sprint work:\\n- Task 4"
    
        Smart extraction:
        - Priority: "#high", "URGENT:", "!!"
        - Timeframe: "this week", "(this month)", "someday"
        - Time: "(30min)", "~2h"
        - Energy: "[high energy]", "[low effort]"
        - Theme: "#sprint", "@admin"
    
        Args:
            text: Natural language task list
            default_priority: Default priority for tasks
            default_timeframe: Default timeframe for tasks
    
        Returns:
            JSON string of parsed todos
        """
        result = parse_natural_language_task_list(text, default_priority, default_timeframe)
    
        response = f"{result['parse_summary']}\n\n"
    
        if result['parsed_todos']:
            response += "Parsed todos (ready for add_todo batch mode):\n"
            response += json.dumps(result['parsed_todos'], indent=2)
    
        if result['unparseable_lines']:
            response += "\n\nCould not parse:\n"
            for line in result['unparseable_lines']:
                response += f"  - {line}\n"
    
        response += f"\n\nTo create these todos, use: add_todo(todos_batch='{json.dumps(result['parsed_todos'])}')"
    
        return response

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/94aharris/coach-ai'

If you have feedback or need assistance with the MCP directory API, please join our Discord server