Skip to main content
Glama

Semantic Search

semantic_search
Read-onlyIdempotent

Perform semantic search using vector embeddings with FAISS acceleration.

Args:
    query: Natural language search query (required)
    max_results: Maximum number of results to return (default: 5, max: 20)
    similarity_threshold: Minimum similarity threshold 0.0-1.0 (default: 0.3)
    index_type: FAISS index type - "hnsw", "ivf", or "flat" (optional, auto-selected)

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
queryYes
index_typeNo
max_resultsNo
similarity_thresholdNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed19 schema fields changed
    • removedInput schema / additionalProperties
      Removed value: -false
    • addedInput schema / properties / index_type / anyOf
      Added value: +[
      +  {
      +    "type": "string"
      +  },
      +  {
      +    "type": "null"
      +  }
      +]
    • addedInput schema / properties / index_type / default
      Added value: +null
    • removedInput schema / properties / index_type / description
      Removed value: -"FAISS index type (optional, auto-selected if not specified)"
    • removedInput schema / properties / index_type / enum
      Removed value: -[
      -  "hnsw",
      -  "ivf",
      -  "flat"
      -]
    • addedInput schema / properties / index_type / title
      Added value: +"Index Type"
    • removedInput schema / properties / index_type / type
      Removed value: -"string"
    • removedInput schema / properties / max_results / description
      Removed value: -"Maximum number of results"
    • removedInput schema / properties / max_results / maximum
      Removed value: -20
    • removedInput schema / properties / max_results / minimum
      Removed value: -1
    • addedInput schema / properties / max_results / title
      Added value: +"Max Results"
    • removedInput schema / properties / query / description
      Removed value: -"Natural language search query"
    • addedInput schema / properties / query / title
      Added value: +"Query"
    • removedInput schema / properties / similarity_threshold / description
      Removed value: -"Minimum similarity threshold"
    • removedInput schema / properties / similarity_threshold / maximum
      Removed value: -1
    • removedInput schema / properties / similarity_threshold / minimum
      Removed value: -0
    • addedInput schema / properties / similarity_threshold / title
      Added value: +"Similarity Threshold"
    • addedInput schema / title
      Added value: +"semantic_searchArguments"
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "properties": {
      +    "result": {
      +      "title": "Result",
      +      "type": "string"
      +    }
      +  },
      +  "required": [
      +    "result"
      +  ],
      +  "title": "semantic_searchOutput",
      +  "type": "object"
      +}
  2. First observed

TDQS

A4.3/5.0
Behavior4/5

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

Annotations (readOnlyHint=true, destructiveHint=false, idempotentHint=true) already establish safety. The description adds meaningful behavioral context by mentioning FAISS acceleration, configurable index types (hnsw, ivf, flat), auto-selection, and default threshold. This goes beyond annotations to clarify technical behavior.

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 front-loaded with the primary purpose. The Args section provides parameter details in a clean, scannable format. Every sentence serves a purpose, with no extraneous information.

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 output schema exists, return values need no explanation. The description covers purpose, parameters, defaults, and technical details. It lacks explicit usage guidance or edge-case caveats, but for a straightforward search tool, it is nearly complete. Sibling distinctions are not addressed, slightly lowering completeness.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Despite 0% schema description coverage, the description fully explains each parameter: query (natural language), max_results (default 5, max 20), similarity_threshold (range 0.0-1.0, default 0.3), and index_type (options and auto-selection). This compensates completely for missing schema descriptions.

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 'Perform semantic search using vector embeddings with FAISS acceleration.' This specifies both the verb and resource, and distinguishes it from siblings like search_specifications (which likely handles keyword search). The tool's purpose is unambiguous.

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

Usage Guidelines3/5

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

The description implies usage for semantic similarity searches but does not explicitly state when to use it versus alternatives like search_specifications. There is no 'when-not' guidance or mention of sibling tools. The context provided by the args (e.g., similarity threshold) suggests scenarios, but explicit alternatives are absent.

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.

Resources