Skip to main content
Glama

get_grounding_information

Extract central topics and selected subtopics from a mind map to gain structured grounding information. Configure detail levels or enable text-only mode for specific insights.

Instructions

Extracts grounding information (central topic, selected subtopics) from the mindmap. Args: mode (str): Detail level ('full', 'content', 'text'). Defaults to 'full'. turbo_mode (bool): Enable turbo mode (text only). Defaults to False. Returns: Union[List[str], Dict[str, str]]: A list containing [top_most_topic, subtopics_string] or error dictionary.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
modeNofull
turbo_modeNo

Implementation Reference

  • The primary handler function for the 'get_grounding_information' tool. Decorated with @mcp.tool() for registration in FastMCP. Handles input parameters, invokes helper, manages errors, and returns serialized results. The docstring provides schema details.
    @mcp.tool() async def get_grounding_information( mode: str = 'full', turbo_mode: bool = False ) -> Union[List[str], Dict[str, str]]: """ Extracts grounding information (central topic, selected subtopics) from the mindmap. Args: mode (str): Detail level ('full', 'content', 'text'). Defaults to 'full'. turbo_mode (bool): Enable turbo mode (text only). Defaults to False. Returns: Union[List[str], Dict[str, str]]: A list containing [top_most_topic, subtopics_string] or error dictionary. """ try: print("Calling get_grounding_information()", file=sys.stderr) top_most, subtopics_str = _get_grounding_information(mode=mode, turbo_mode=turbo_mode) print(f"get_grounding_information() returned: top='{top_most}', subtopics='{subtopics_str}'", file=sys.stderr) return [top_most, subtopics_str] # Return as list for JSON except Exception as e: # This function doesn't directly call MindManager, so errors are less likely external print(f"ERROR in get_grounding_information: {e}", file=sys.stderr) return {"error": "Internal Error", "message": f"Failed to get grounding information: {e}"}
  • Helper function that instantiates MindmapDocument and fetches the grounding information (top topic and subtopics) from the current mindmap selection.
    def _get_grounding_information(mode='text', turbo_mode=True): document = _get_document_instance(turbo_mode=turbo_mode) if document.get_mindmap(mode=mode): document.get_selection() return document.get_grounding_information() return None

Other Tools

Related 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/robertZaufall/mindm-mcp'

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