Skip to main content
Glama
landicefu

Divide and Conquer MCP Server

by landicefu

mark_task_done

Mark a checklist item as completed to track progress in task breakdown workflows. Specify the item index to update its status.

Instructions

Marks a checklist item as done.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
indexYesThe index of the checklist item to mark as done (0-based)

Implementation Reference

  • The handler function for 'mark_task_done' tool. It validates the index, reads the task data from config file, sets the checklist item's 'done' to true, updates progress metadata, writes back to file, and returns success message.
    private async markTaskDone(args: any): Promise<any> {
      if (args?.index === undefined) {
        throw new McpError(ErrorCode.InvalidParams, 'Index is required');
      }
    
      try {
        const taskData = await this.readTaskData();
        
        // Check if the index is valid
        if (args.index < 0 || args.index >= taskData.checklist.length) {
          throw new McpError(ErrorCode.InvalidParams, `Invalid index: ${args.index}`);
        }
        
        // Mark the checklist item as done
        taskData.checklist[args.index].done = true;
        
        // Write the updated task data to the file
        await this.writeTaskData(taskData);
        
        return {
          content: [
            {
              type: 'text',
              text: 'Task marked as done.',
            },
          ],
        };
      } catch (error) {
        console.error('Error marking task as done:', error);
        return {
          content: [
            {
              type: 'text',
              text: `Error marking task as done: ${error instanceof Error ? error.message : String(error)}`,
            },
          ],
          isError: true,
        };
      }
    }
  • Input schema for the 'mark_task_done' tool, requiring a 0-based index of the checklist item.
    inputSchema: {
      type: 'object',
      properties: {
        index: {
          type: 'number',
          description: 'The index of the checklist item to mark as done (0-based)'
        }
      },
      required: ['index']
    }
  • src/index.ts:264-277 (registration)
    Registration of the 'mark_task_done' tool in the ListTools response, defining name, description, and input schema.
    {
      name: 'mark_task_done',
      description: 'Marks a checklist item as done.',
      inputSchema: {
        type: 'object',
        properties: {
          index: {
            type: 'number',
            description: 'The index of the checklist item to mark as done (0-based)'
          }
        },
        required: ['index']
      }
    },
  • src/index.ts:434-435 (registration)
    Dispatch case in the CallToolRequest handler that routes 'mark_task_done' calls to the markTaskDone method.
    case 'mark_task_done':
      return await this.markTaskDone(request.params.arguments);
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries full burden for behavioral disclosure. While 'marks...done' implies a mutation operation, it doesn't specify whether this is reversible, what permissions are required, whether it triggers side effects, or what happens if the index is invalid. For a mutation tool with zero annotation coverage, this leaves significant behavioral questions unanswered.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, efficient sentence that communicates the core functionality without any wasted words. It's appropriately sized for a simple tool with one parameter and gets straight to the point with no unnecessary elaboration.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a mutation tool with no annotations and no output schema, the description is insufficiently complete. It doesn't explain what 'done' means in this context, what the expected outcome is, or how this interacts with other checklist operations. Given the tool's role in a task management system with multiple sibling tools, more contextual information would be helpful.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, with the single parameter 'index' fully documented in the schema. The description doesn't add any parameter semantics beyond what the schema already provides (e.g., it doesn't explain what 'checklist item' refers to or provide examples). Baseline 3 is appropriate when the schema does all the parameter documentation work.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the action ('marks') and target ('checklist item as done'), making the purpose immediately understandable. It doesn't explicitly differentiate from sibling 'mark_task_undone', but the verb 'marks...done' provides inherent distinction. The description avoids tautology by not just restating the tool name.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides no guidance on when to use this tool versus alternatives like 'clear_task' or 'mark_task_undone'. It doesn't mention prerequisites (e.g., whether a task must be initialized first) or contextual constraints. The agent must infer usage solely from the tool name and description without explicit direction.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

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/landicefu/divide-and-conquer-mcp-server'

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