Skip to main content
Glama
dmarsters

Constellation Composition MCP Server

by dmarsters

Search Constellations by Theme or Characteristics

search_constellations
Read-onlyIdempotent

Search constellations by name, theme, shape, or brightness to find patterns matching specific compositional needs for AI image generation.

Instructions

Search for constellations by name, theme, visual characteristics, or shape.

Useful for discovering which constellations match specific compositional needs or thematic requirements. Returns constellation details including mythology, visual characteristics, and shape patterns.

Args: params (ConstellationSearchInput): Search parameters including: - query: Text search for name/theme/characteristic - shape_type: Filter by geometric shape - brightness: Filter by brightness pattern - response_format: Output format (markdown or json)

Returns: str: List of matching constellations with their characteristics

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
paramsYesInput for searching constellations.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Implementation Reference

  • The handler function `search_constellations` iterates through the `CONSTELLATIONS` dictionary, applying filters for query, shape, and brightness to return matching constellation metadata.
    @mcp.tool(
        name="search_constellations",
        annotations={
            "title": "Search Constellations by Theme or Characteristics",
            "readOnlyHint": True,
            "destructiveHint": False,
            "idempotentHint": True,
            "openWorldHint": False
        }
    )
    async def search_constellations(params: ConstellationSearchInput) -> str:
        """
        Search for constellations by name, theme, visual characteristics, or shape.
        
        Useful for discovering which constellations match specific compositional needs
        or thematic requirements. Returns constellation details including mythology,
        visual characteristics, and shape patterns.
        
        Args:
            params (ConstellationSearchInput): Search parameters including:
                - query: Text search for name/theme/characteristic
                - shape_type: Filter by geometric shape
                - brightness: Filter by brightness pattern
                - response_format: Output format (markdown or json)
        
        Returns:
            str: List of matching constellations with their characteristics
        """
        
        results = []
        
        for name, data in CONSTELLATIONS.items():
            match = True
            
            # Text query matching
            if params.query:
                query_lower = params.query.lower()
                searchable = f"{name} {data.get('story', '')} {data.get('theme', '')} {data.get('visual_character', '')}".lower()
                if query_lower not in searchable:
                    match = False
            
            # Shape filter
            if params.shape_type and match:
                shape = data.get('shape', '')
                if params.shape_type.lower() not in shape.lower():
                    match = False
            
            # Brightness filter
            if params.brightness and match:
                brightness = data.get('brightness_profile', '')
                if params.brightness.lower() not in brightness.lower():
                    match = False
            
            if match:
                result = {
                    'name': name,
                    'abbr': data.get('abbr'),
                    'story': data.get('story'),
                    'theme': data.get('theme'),
                    'visual_character': data.get('visual_character'),
                    'shape': data.get('shape'),
                    'brightness_profile': data.get('brightness_profile'),
                    'star_count': data.get('star_count_visual')
                }
                results.append(result)
        
        if not results:
            return "No constellations found matching your criteria. Try broader search terms."
        
        if params.response_format == ResponseFormat.JSON:
            return json.dumps({'constellations': results, 'count': len(results)}, indent=2)
        else:
            return format_search_results_markdown(results)
Behavior4/5

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

Annotations already declare readOnlyHint=true, destructiveHint=false, idempotentHint=true, and openWorldHint=false. The description adds valuable context about what the tool returns (constellation details including mythology, visual characteristics, and shape patterns) and mentions the response_format parameter for output control. It doesn't describe rate limits or authentication needs, but provides useful behavioral context beyond the annotations.

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 efficiently structured with a clear purpose statement, usage context, and parameter/return information in separate sections. Every sentence adds value without redundancy. The Args and Returns sections are appropriately formatted and concise.

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 has comprehensive annotations, 100% schema description coverage, and an output schema (implied by the Returns section), the description provides complete context. It explains what the tool does, when to use it, what parameters control, and what information is returned, making it fully adequate for this search tool.

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?

Schema description coverage is 100%, so the schema already fully documents all parameters. The description adds minimal value beyond the schema - it mentions the response_format parameter and implies search capabilities, but doesn't provide additional syntax, format details, or usage examples beyond what's in the schema descriptions. This meets the baseline for high schema coverage.

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 tool searches for constellations using specific criteria (name, theme, visual characteristics, shape) and returns detailed information. It distinguishes from siblings like 'list_all_constellations' (which presumably lists all without filtering) and 'get_constellation_coordinates' (which focuses on coordinates rather than thematic search).

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 for when to use this tool ('useful for discovering which constellations match specific compositional needs or thematic requirements'), but doesn't explicitly state when not to use it or name specific alternatives among the sibling tools. It implies usage for search-based discovery rather than listing or coordinate retrieval.

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/dmarsters/constellation-composition-mcp'

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