Skip to main content
Glama
watamoo

Crossword MCP Server

by watamoo

get_candidates

Retrieve registered candidate words for a crossword clue ID to support puzzle solving by accessing previously stored answer possibilities.

Instructions

登録済みの候補語リストを取得する。

Args: clue_id (str): 取得対象のカギ ID。事前に register_candidates で候補を登録して いる必要がある。

Returns: list[str]: 登録済み候補語のリスト。登録時に渡した文字列を順序どおりに返す。

Raises: ValueError: clue_id が空の場合。 KeyError: 指定した clue_id の候補が未登録の場合。

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
clue_idYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Implementation Reference

  • The @mcp.tool() decorator registers the async handler function get_candidates, which retrieves and returns the list of candidates registered for the specified clue_id from the global PuzzleState.
    @mcp.tool()
    async def get_candidates(clue_id: str) -> list[str]:
        """登録済みの候補語リストを取得する。
    
        Args:
            clue_id (str): 取得対象のカギ ID。事前に `register_candidates` で候補を登録して
                いる必要がある。
    
        Returns:
            list[str]: 登録済み候補語のリスト。登録時に渡した文字列を順序どおりに返す。
    
        Raises:
            ValueError: `clue_id` が空の場合。
            KeyError: 指定した `clue_id` の候補が未登録の場合。
        """
    
        if not clue_id:
            raise ValueError("clue_id は必須です。")
    
        clue_id = clue_id.strip()
        if clue_id not in state.candidates:
            raise KeyError("指定された clue_id の候補が登録されていません。")
    
        return state.candidates[clue_id]
Behavior4/5

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

With no annotations provided, the description carries full burden and does well. It discloses that the tool returns a list in the original registration order, specifies two error conditions (ValueError for empty clue_id, KeyError for unregistered clue_id), and indicates this is a retrieval operation rather than a mutation. It doesn't mention performance characteristics like rate limits or authentication needs, but covers the essential behavioral aspects.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is well-structured with clear sections (Args, Returns, Raises) and front-loads the core purpose. Each sentence earns its place by providing essential information. It could be slightly more concise in the Japanese portion, but overall it's efficiently organized with no wasted text.

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 moderate complexity (single parameter retrieval), no annotations, but with an output schema present, the description is complete. It covers purpose, parameter meaning, return behavior, error conditions, and prerequisites. The output schema handles return value documentation, so the description appropriately focuses on operational context rather than repeating schema information.

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

Parameters5/5

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

The schema has 0% description coverage, so the description must fully compensate. It provides comprehensive parameter semantics: explains that clue_id identifies which set of candidates to retrieve, specifies it must be non-empty, and clarifies the prerequisite relationship with register_candidates. This adds significant value beyond the bare schema type information.

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 specific action ('取得する' - retrieve/get) and resource ('登録済みの候補語リスト' - registered candidate word list). It distinguishes from sibling tools by specifying it retrieves pre-registered candidates rather than registering them (register_candidates) or searching (search_consistent_sets). The purpose is precise and unambiguous.

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 context about when to use this tool: when you need to retrieve previously registered candidates for a specific clue_id. It mentions the prerequisite that candidates must have been registered via 'register_candidates' first. However, it doesn't explicitly state when NOT to use this tool or name specific alternatives among the siblings, which prevents a perfect score.

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/watamoo/mcp-crossword-tools'

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