Skip to main content
Glama

aida_bug_fix

Mark bugs as resolved in AI development analytics. Log bug fixes with ID and solution details to improve coding patterns.

Instructions

当你修复了一个 bug 后调用。标记 bug 为已修复。

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
bugIdYesBug ID,如 BUG-01
fixNo修复方案简述

Implementation Reference

  • The implementation of the aida_bug_fix tool handler. It updates the bug status to fixed, records tokens, and saves the changes.
    function handleBugFix(args: any): any {
      const { path, data } = ensureRunJson();
      const bug = data.bugs.find(b => b.bugId === args.bugId);
      if (!bug) return { success: false, message: `Bug ${args.bugId} 未找到` };
    
      bug.status = 'fixed';
      bug.fixedAt = now();
      if (args.fix) bug.fix = args.fix;
    
      // Auto-collect tokens for bug fix
      let bugTokens = 0;
      if (bug.reportedAt && bug.fixedAt) {
        bugTokens = getTaskTokens(bug.reportedAt, bug.fixedAt);
        if (bugTokens > 0) {
          (bug as any).tokensConsumed = bugTokens;
          if (!data.cost) data.cost = {};
          if (!data.cost.tokenBreakdown) data.cost.tokenBreakdown = [];
          data.cost.tokenBreakdown.push({
            stage: `bugfix:${args.bugId}`,
            tokens: bugTokens,
          });
        }
      }
    
      addEvent(data, 'bug_fixed', { bugId: args.bugId, tokensConsumed: bugTokens });
      addTimeline(data, 'bug-fix', `${args.bugId}: ${bug.title}`);
      save(path, data);
      syncTokenUsage(path, data);
    
      const tokenMsg = bugTokens > 0 ? ` (${bugTokens} tokens)` : '';
      return { success: true, message: `${args.bugId} 已修复${tokenMsg}` };
    }
  • The switch-case registration for the aida_bug_fix tool.
    case 'aida_bug_fix':
      result = handleBugFix(args);
      break;
Behavior2/5

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

No annotations provided, so description carries full burden. States the marking action but fails to disclose mutation side effects, reversibility, state transitions, or whether this triggers notifications. For a state-change tool, behavioral details are insufficient.

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?

Two sentences with zero waste. Front-loaded with the trigger condition ('当你修复了一个 bug 后调用'), followed immediately by the effect. Appropriate length for the tool's scope.

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

Completeness3/5

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

Adequate for a simple 2-parameter state-update tool with no output schema. Covers the essential trigger and action, though omitting operational details (e.g., whether this archives the bug, updates timestamps, or interacts with aida_status).

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%, establishing baseline 3. The phrase 'after you have fixed a bug' adds context that the 'fix' parameter should describe the completed solution, but no additional semantic guidance (format constraints, example values) is provided beyond the schema.

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 (标记/mark as fixed) and resource (bug), and specifies the trigger condition ('after you have fixed a bug'). It implicitly distinguishes from sibling aida_log_bug through the post-fix timing versus logging, though it could explicitly contrast with bug creation tools.

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

Usage Guidelines3/5

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

Provides clear timing guidance ('when you have fixed a bug'), indicating the workflow state for invocation. However, lacks explicit guidance on when NOT to use (e.g., vs. aida_task_done for tasks) or alternatives for unverified fixes.

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/LWTlong/ai-dev-analytics'

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