Skip to main content
Glama
yalcin

ta-lib-mcp

by yalcin

talib_list_indicators

Read-onlyIdempotent

List TA-Lib indicators filtered by group, category, or keyword. Returns indicator names with group and category metadata.

Instructions

List TA-Lib indicators with optional group, category, and search filters.

Returns indicator names with group and category metadata. Use the optional filters to narrow results by TA-Lib group, category, or keyword search.

Args: group: Optional TA-Lib group filter (e.g., "Overlap Studies"). category: Optional category filter (e.g., "Trend", "Momentum"). search: Optional keyword search for indicator names. limit: Maximum number of indicators to return (1-1000).

Returns: List of indicator summaries with name, group, and category.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
groupNo
categoryNo
searchNo
limitNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Implementation Reference

  • The talib_list_indicators MCP tool handler function. Decorated with @mcp.tool, it takes optional group, category, search, and limit parameters, constructs a ListIndicatorsInput model, delegates to list_indicators() from indicators module, and returns IndicatorSummary dicts.
    @mcp.tool(annotations=_TOOL_ANNOTATIONS)
    def talib_list_indicators(
        group: str | None = None,
        category: str | None = None,
        search: str | None = None,
        limit: int = 200,
    ) -> list[dict[str, Any]]:
        """List TA-Lib indicators with optional group, category, and search filters.
    
        Returns indicator names with group and category metadata. Use the optional
        filters to narrow results by TA-Lib group, category, or keyword search.
    
        Args:
            group: Optional TA-Lib group filter (e.g., "Overlap Studies").
            category: Optional category filter (e.g., "Trend", "Momentum").
            search: Optional keyword search for indicator names.
            limit: Maximum number of indicators to return (1-1000).
    
        Returns:
            List of indicator summaries with name, group, and category.
        """
        input_model = ListIndicatorsInput(
            group=group,
            category=category,
            search=search,
            limit=limit,
        )
        raw = list_indicators(
            group=input_model.group,
            category=input_model.category,
            search=input_model.search,
            limit=input_model.limit,
        )
        return [IndicatorSummary(**row).model_dump() for row in raw]
  • ListIndicatorsInput Pydantic model defining the input schema for the talib_list_indicators tool, with fields: group, category, search (all optional str), and limit (int, default 200, max 1000).
    class ListIndicatorsInput(BaseModel):
        """Input for talib_list_indicators tool."""
    
        group: str | None = Field(
            default=None,
            description=(
                "Optional TA-Lib group filter. "
                "Examples: 'Overlap Studies', 'Momentum Indicators', 'Volume Indicators'."
            ),
            max_length=MAX_INPUT_LENGTH,
        )
        category: str | None = Field(
            default=None,
            description=(
                "Optional category filter. Examples: 'Trend', 'Momentum', 'Volume', 'Volatility'."
            ),
            max_length=MAX_INPUT_LENGTH,
        )
        search: str | None = Field(
            default=None,
            description="Optional keyword search filter for indicator names.",
            max_length=MAX_INPUT_LENGTH,
        )
        limit: int = Field(
            default=DEFAULT_LIMIT,
            description=f"Maximum number of indicators to return (1-{MAX_LIMIT}).",
            ge=1,
            le=MAX_LIMIT,
        )
  • IndicatorSummary Pydantic model defining the output schema for talib_list_indicators, with fields: name, group, and category (all str).
    class IndicatorSummary(BaseModel):
        """Summary of a single indicator."""
    
        name: str = Field(description="Indicator name (uppercase).")
        group: str = Field(description="TA-Lib function group.")
        category: str = Field(description="Indicator category.")
  • The core list_indicators() function that queries TA-Lib via get_function_groups() and get_functions(), filters by group, category, and search (case-insensitive), maps groups to categories via categorize_group(), and returns up to 'limit' results.
    def list_indicators(
        group: str | None = None,
        category: str | None = None,
        search: str | None = None,
        limit: int = DEFAULT_LIMIT,
    ) -> list[dict[str, str]]:
        """List available TA-Lib indicators with group and category metadata.
    
        Args:
            group: Optional TA-Lib group filter.
            category: Optional category filter.
            search: Optional keyword search for indicator names.
            limit: Maximum number of results.
    
        Returns:
            List of indicator dicts with name, group, and category.
    
        Raises:
            TALibUnavailableError: If TA-Lib is not installed.
            ValidationError: If filter parameters are invalid.
        """
        limit = validate_limit(limit)
        talib, _ = _require_talib()
    
        group_filter = normalize_text_filter(group, "group")
        category_filter = normalize_text_filter(category, "category")
        search_filter = normalize_text_filter(search, "search")
    
        group_map, names = _get_metadata(talib)
        rows: list[dict[str, str]] = []
        for name in names:
            grp = group_map.get(name, "Unknown")
            cat = categorize_group(grp)
            if group_filter and group_filter not in grp.casefold():
                continue
            if category_filter and category_filter not in cat.casefold():
                continue
            if search_filter and search_filter not in name.casefold():
                continue
            rows.append({"name": name, "group": grp, "category": cat})
            if len(rows) >= limit:
                break
    
        return rows
  • Import of list_indicators from ta_lib_mcp.indicators and ListIndicatorsInput/IndicatorSummary from ta_lib_mcp.models, connecting the tool handler to its dependencies.
    from ta_lib_mcp.constants import ENV_LOG_LEVEL, SERVER_DESCRIPTION, SERVER_NAME
    from ta_lib_mcp.indicators import (
        compute_indicator,
        get_indicator_info,
        list_indicators,
        talib_versions,
    )
    from ta_lib_mcp.models import (
        CategorySummary,
        ComputationResult,
        ComputeIndicatorInput,
        GetIndicatorInfoInput,
        IndicatorInfo,
        IndicatorSummary,
        ListIndicatorsInput,
        VersionInfo,
    )
Behavior4/5

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

Annotations already indicate the tool is read-only, non-destructive, and idempotent. The description adds valuable contextual details, such as the return format (list with name, group, category), the optional filters, and the limit range. No contradictions with annotations.

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, starting with a one-line summary followed by a detailed Args/Returns block. It is efficient, though the Args section adds moderate length. Overall, it is front-loaded and clear.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's low complexity, the existence of an output schema, and the annotations covering safety, the description is complete. It covers the purpose, parameters, and return structure. Minor missing aspects like sort order or edge cases are not critical for this simple list tool.

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?

With 0% schema coverage, the description fully explains all four parameters: group, category, search (with examples), and limit (with range). This compensates for the missing schema descriptions and provides clear semantics.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool lists TA-Lib indicators with optional filters, specifying the verb 'list' and the resource 'indicators'. However, it does not explicitly differentiate from sibling tools like 'talib_list_categories' or 'talib_get_indicator_info', which could cause ambiguity in selection.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides basic usage instructions ('Use the optional filters...') but lacks explicit guidance on when to use this tool versus alternatives. For instance, it does not mention that for a specific indicator's details one should use 'talib_get_indicator_info', or that for categories alone 'talib_list_categories' is more appropriate.

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/yalcin/ta-lib-mcp'

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