Skip to main content
Glama

Analyze Case

analyze_case

Triggers AI analysis of a single case asynchronously. Poll after 30-60 seconds for the result, or set force to re-analyze an existing case.

Instructions

Triggers AI analysis of a single case. CONSUMES AI CREDITS. ASYNCHRONOUS: normally returns immediately with status processing while the analysis runs in the background; poll get_case_analysis after roughly 30 to 60 seconds to retrieve the result. If analysis already exists and force is not set, the existing analysis is returned immediately instead with alreadyExists true. Set force true to re-analyze a case that already has analysis, which also consumes credits again. Fails with a clear message if the case has no usable text or PDF content to analyze.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
idYesCase identifier: either a 24 character MongoDB ObjectId hex string, or a case number string. Lookup order: the server first tries to parse this as an ObjectId; only if that parse fails does it fall back to looking up by case number. This means a syntactically valid but nonexistent ObjectId returns 404 without ever trying the case number path.
forceNoRe-run analysis even if it already exists, default false.
Behavior5/5

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

Even with no annotations, the description fully discloses key behaviors: it consumes AI credits, is asynchronous, returns immediately with processing status, may return existing analysis with alreadyExists=true, force re-analyzes and re-consumes credits, and fails if no usable content exists. This exceeds transparency expectations.

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 compact yet comprehensive, with each sentence serving a distinct purpose: primary action, credit consumption, async/polling behavior, existing-analysis behavior, force behavior, and failure condition. No wasted words.

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

Completeness5/5

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

Given the tool's complexity (async, credit consumption, subtle id matching, conditional re-analysis) and the absence of an output schema, the description covers all necessary operational details. It provides a complete mental model for correct invocation and follow-up.

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 already documents both parameters with 100% coverage, providing a baseline of 3. The description adds meaningful semantics beyond the schema: the id lookup order (ObjectId parse attempt followed by case number fallback), including the 404 edge case, and that force consumes credits again. This enriches parameter understanding.

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

Purpose5/5

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

The description clearly states the tool's function: 'Triggers AI analysis of a single case.' It distinguishes from siblings, notably 'analyze_consolidated_case' (consolidated cases) and 'get_case_analysis' (retrieval), by focusing on the triggering action and mentioning polling for results.

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

Usage Guidelines4/5

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

The description provides clear usage context: it explains the asynchronous flow, says to poll 'get_case_analysis' after 30-60 seconds, and describes when to set 'force' for re-analysis. It does not explicitly name alternative tools for excluding, but the implicit guidance is strong.

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/thinkscoop-technologies/courtmesh-mcp'

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