Skip to main content
Glama
agentience

Tribal Knowledge Service

by agentience

get_error_by_id

Retrieve a specific error record by its unique ID to analyze programming issues and learn from past mistakes within the Tribal Knowledge Service.

Instructions

Get an error record by its ID.

Args:
    error_id: UUID of the error record

Returns:
    The error record or None if not found

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
error_idYes

Implementation Reference

  • Handler function that implements the get_error_by_id MCP tool by validating the error_id as UUID and retrieving the corresponding ErrorRecord from ChromaStorage, serializing to dict or returning None if not found.
    @mcp.tool()
    async def get_error_by_id(error_id: str) -> Optional[Dict]:
        """
        Get an error record by its ID.
    
        Args:
            error_id: UUID of the error record
    
        Returns:
            The error record or None if not found
        """
        try:
            uuid_id = UUID(error_id)
            record = await storage.get_error(uuid_id)
            if record:
                return json.loads(record.model_dump_json())
            return None
        except ValueError:
            return None
  • Handler function that implements the get_error_by_id MCP tool by proxying a GET request to the backend API endpoint /api/v1/errors/{error_id}.
    @mcp.tool()
    async def get_error_by_id(error_id: str) -> Dict:
        """
        Get an error record by its ID.
    
        Args:
            error_id: UUID of the error record
    
        Returns:
            The error record
        """
        return await make_api_request("GET", f"/api/v1/errors/{error_id}")
  • Explicit registration and dispatch of the get_error_by_id tool within the @mcp.handle_execution handler.
    elif tool_name == "get_error_by_id":
        return await get_error_by_id(**params)
Behavior3/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It states the tool retrieves an error record or returns None if not found, which clarifies the read-only nature and potential outcomes. However, it lacks details on permissions, rate limits, or error handling beyond the basic return behavior, leaving gaps in transparency.

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 front-loaded with the core purpose, followed by structured sections for Args and Returns, making it highly efficient and easy to parse. Every sentence adds value without redundancy, adhering to best practices for conciseness.

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?

Given the tool's low complexity (one parameter, no output schema, no annotations), the description is adequate but has clear gaps. It covers the basic operation and parameter semantics but lacks details on behavioral aspects like authentication or error scenarios. Without annotations or output schema, more context would improve completeness.

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

Parameters4/5

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

The schema description coverage is 0%, so the description must compensate. It adds meaningful context by specifying that 'error_id' is a UUID, which clarifies the parameter's format beyond the schema's generic string type. Since there's only one parameter, this is sufficient to elevate the score above the baseline.

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 tool's purpose with a specific verb ('Get') and resource ('an error record by its ID'), making it immediately understandable. It distinguishes this from siblings like 'search_errors' or 'find_similar_errors' by focusing on direct ID-based retrieval rather than search operations. However, it doesn't explicitly contrast with 'delete_error' or 'track_error', keeping it from a perfect score.

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?

The description implies usage when you have a specific error ID, as opposed to searching or finding similar errors, but it doesn't provide explicit guidance on when to use this tool versus alternatives like 'delete_error' or 'track_error'. There's no mention of prerequisites or exclusions, leaving some ambiguity in context.

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/agentience/tribal_mcp_server'

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