Skip to main content
Glama
Aorls

java-class-analyzer-mcp

by Aorls

java_class_analyzer

Decompile any specified Java class from Maven dependencies by its fully qualified name, returning source code for direct analysis.

Instructions

分析和反编译指定的Java类。根据类的全限定名查找对应的JAR包并进行反编译,返回源代码。

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
classNameYes要分析的类的全限定名,例如: com.qinglusaas.connect.domain.model.BizPushRecordDTO

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

A4/5.0
Behavior4/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 disclosing behavior. It clearly explains the core operation: find the JAR by fully qualified name, decompile, and return source code. This makes the read-only nature of decompilation evident, though it does not explicitly state safety or error behavior when a class or JAR is not found.

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, compact sentence that front-loads the action ('analyze and decompile') and conveys the full workflow without any filler. Every phrase earns its place, making it highly efficient for an agent to parse quickly.

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

Completeness4/5

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

For a tool with one parameter, no output schema, and no annotations, the description adequately covers the core input, action, and output ('returns source code'). It leaves out edge cases such as class-not-found or JAR-not-resolved behavior, but the overall context is sufficient for straightforward invocation.

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?

The schema already describes the single parameter with 100% coverage as the fully qualified class name. The description essentially restates this, adding only that the class name is used to locate the JAR package, which is a minor procedural detail already implied by the schema. It does not significantly elevate semantic 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 states a specific verb and resource: 'analyzes and decompiles the specified Java class,' and details the process of locating the JAR by fully qualified name and returning source code. This clearly distinguishes the tool from siblings java_class_indexer and java_class_search, which are focused on indexing and searching rather than decompilation.

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: if you need decompiled source for a class, use this tool. However, it does not explicitly mention when to use it over alternatives or provide exclusions, such as 'use java_class_search to find a class first' or 'do not use if you just need metadata.' The guidance is implicit rather than explicit.

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