Skip to main content
Glama
bxzymy

MCP Recommender

by bxzymy

get_functional_keywords

Retrieve functional keyword mappings to improve search accuracy and discover relevant MCP server recommendations.

Instructions

Show available functional keyword mappings for better search results.

Returns: Formatted list of functional keywords

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The handler function decorated with @mcp.tool(), implementing the logic to retrieve and format functional keywords from the recommender instance.
    @mcp.tool()
    def get_functional_keywords() -> str:
        """
        Show available functional keyword mappings for better search results.
        
        Returns:
            Formatted list of functional keywords
        """
        try:
            if not recommender.functional_keywords:
                return "### No functional keywords available\nThe keyword mapping database is not loaded."
            
            result = "### Functional Keywords Mapping:\n\n"
            result += "Use these terms in your queries for better results:\n\n"
            
            for function, keywords in recommender.functional_keywords.items():
                result += f"**{function.title()}:**\n"
                result += f"  - Keywords: {', '.join(keywords[:8])}"  # Show first 8 keywords
                if len(keywords) > 8:
                    result += f" (and {len(keywords) - 8} more)"
                result += "\n\n"
            
            return result
            
        except Exception as e:
            return f"### Error\nAn error occurred while retrieving keywords: {str(e)}"

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/bxzymy/mcp-recommend'

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