Skip to main content
Glama

find_similar

Read-onlyIdempotent

Find historical (ticker, date) setups most similar to a query ticker today. Four similarity methods are available: cosine (default, all tiers) ranks by cosine similarity of 32-D regime-aware embeddings; label_aware (PRO+) restricts the backbook to dates in the same SPY volatility regime; supervised (QUANT) projects embeddings through a PLS regression fit on forward-return labels so neighbors are ones whose factor profile most-strongly-predicted realized returns; dtw (HOBBY+) cosine-shortlists then reranks by dynamic-time-warping distance over the rolling return window. Each returned neighbor row carries the analogue's factor row and forward-return labels at that historical (ticker, date) — pre-joined for honest backtests, no extra fetches needed. Use min_lookback_days=30 to filter out same-day correlated tickers. Pass conditioner=vx_term_structure (QUANT only) to additionally filter analogues to dates with a VIX-curve regime similar to today.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
limitNo
methodNoSimilarity method. Tier-gated: FREE=cosine; HOBBY=cosine+dtw; PRO=cosine+dtw+label_aware; QUANT=all four.cosine
tickerYes
toleranceNoMax |conditioner_query − conditioner_neighbor|. Only used when conditioner is set.
conditionerNoQUANT only. Filter analogues to dates with a similar regime conditioner value. Currently only vx_term_structure is supported. Limits: analogues older than 252 trading days are passed through unverified.
min_lookback_daysNoRequire neighbor_date to be at least this many days before query_date. Default 30 strips co-traded same-day ETFs.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
methodYes
neighborsYes
toleranceNoEcho of conditioner tolerance.
query_dateNo
conditionerNoPresent only when conditioner is requested (QUANT).
query_tickerYes
conditioner_noteNoNotes about the conditioner filter — matched count, unverified count.
min_lookback_daysNo

TDQS

A4.7/5.0
Behavior5/5

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

Beyond the readOnly/idempotent annotations, the description discloses rich behavioral details: the inner workings of each method (e.g., PLS regression, dynamic-time-warping), tier restrictions, pre-joined return rows for honest backtests, and the 252-day pass-through limit for conditioner. These are substantial additions not present in 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 compact and every sentence earns its place: purpose, method distinctions, return contents, and usage tips. It is front-loaded with the core purpose and avoids any redundancy.

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 an output schema exists, the description needn't detail return structures. It comprehensively covers the tool's complexity: method selection, tier gates, output row contents, and parameter effects. The only omissions are pagination/error details, but these are minor and the description is otherwise complete.

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?

The schema covers 6 parameters with 67% description coverage. The description adds significant meaning for method (explains all four variants), min_lookback_days (purpose of stripping co-traded ETFs), and conditioner (QUANT-only, filtering behavior). Ticker and limit remain intuitive but the description compensates well for the coverage gap.

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 opens with 'Find historical (ticker, date) setups most similar to a query ticker today,' a specific verb+resource+scope that clearly differentiates it from the sibling data-retrieval tools (e.g., get_embedding, get_features). The detailed method breakdown further reinforces its unique role.

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?

Provides clear conditional guidance: 'Use min_lookback_days=30 to filter out same-day correlated tickers' and 'Pass conditioner=vx_term_structure (QUANT only) to additionally filter analogues...' It also implies a backtest use case. However, it does not explicitly state when to prefer this tool over alternatives or when not to use it.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

TDQS

A4.2/5.0
Disambiguation4/5

Most tools target distinct resources (features, embeddings, labels, market context, risk clusters), but minor overlap exists: get_market_context includes a regime reading that get_market_regime also provides, and get_report_card bundles features that get_features offers separately. Descriptions are clear enough to resolve these overlaps.

Naming Consistency4/5

The predominant pattern is get_<noun> (get_features, get_labels, get_manifest, etc.), with two exceptions: find_similar (find_) and list_futures (list_). This is a small deviation but still follows a predictable verb-noun structure for retrieval, search, and enumeration actions.

Tool Count5/5

14 tools is well within the ideal range for a quantitative data server. Each tool serves a distinct purpose, from basic data retrieval (features, labels) to advanced analytics (similarity, risk clusters) and user management (alerts, usage). No tool feels redundant or missing.

Completeness4/5

The toolset covers the core data access and analytics needs for factor-based market analysis: retrieval, search, market context, and backtesting labels. Minor gaps include no generic ticker search or list (beyond futures), and no direct way to browse available factors beyond documentation, but these can be worked around via get_top and get_manifest.

Resources