Skip to main content
Glama

list_models

Read-onlyIdempotent

Retrieve available Gemini AI models and current bridge status to select appropriate models for high-performance, stateful AI interactions through the MCP server.

Instructions

List available Gemini models and current bridge state. Returns known models, current active model, and agent info.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Implementation Reference

  • The tool `list_models` is defined and implemented as an async function decorated with @mcp.tool. It returns a dictionary containing available models and bridge status.
    @mcp.tool(
        name="list_models",
        annotations=ToolAnnotations(
            title="List Available Models",
            readOnlyHint=True,
            destructiveHint=False,
            idempotentHint=True,
            openWorldHint=False,
        ),
        description="List available Gemini models and current bridge state. "
        "Returns known models, current active model, and agent info.",
    )
    async def list_models() -> Dict[str, Any]:
        """List available models and bridge status."""
        return {
            "models": _KNOWN_MODELS,
            "approval_modes": list(_APPROVAL_MODES.keys()),
            "current_model": _bridge._current_model or "(not started)",
            "agent_info": _bridge._agent_info or None,
            "bridge_version": VERSION,
            "process_running": _bridge._proc is not None and _bridge._proc.poll() is None,
        }
Behavior4/5

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

Annotations cover safety (readOnly, idempotent, non-destructive), but the description adds valuable behavioral context about what state is accessed ('bridge state', 'agent info') and what the function returns. It complements the annotations by explaining the semantic content of the operation.

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 efficient sentences with zero waste. First sentence establishes the operation and scope; second sentence details return contents. Information is front-loaded and appropriately sized for a parameterless introspection tool.

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?

For a zero-parameter, read-only listing tool with an output schema present, the description is complete. It explains what resource is queried and what data categories are returned, which is sufficient given the low complexity and existing output schema.

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 input schema has zero parameters, establishing a baseline of 4 per the rubric. The description appropriately doesn't mention parameters since none exist, maintaining focus on the operation's purpose and return values.

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 uses a specific verb (List) with clear resources (Gemini models, bridge state). It distinguishes itself from sibling 'list_sessions' by explicitly naming 'Gemini models' and 'bridge state' as targets, and from 'gemini' (likely a generation tool) by being read-only/listing focused.

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?

While the description implies usage by explaining what is returned (known models, active model, agent info), it lacks explicit when-to-use guidance or comparison to siblings. It doesn't state, for example, to use this before calling 'gemini' to check available models.

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/shenyunhuan/gemini_mcp'

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