Skip to main content
Glama
@memoryrelay/mcp-server

@memoryrelay/mcp-server

Official
by memoryrelay

pattern_search

Search development patterns by semantic similarity. Find global and project-specific patterns using natural language queries, with filters for category and similarity threshold.

Instructions

Search for development patterns using semantic similarity. When working on a project, shows both global patterns and patterns adopted by that project.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "query": "<query>"
    },
    "name": "pattern_search"
  }
}

Input Schema

NameRequiredDescriptionDefault
limitNoMaximum results (1-50, default 10)
queryYesNatural language query describing the pattern to find (e.g., "validation", "error handling")
projectNoProject context — shows global patterns plus patterns adopted by this project
categoryNoFilter by category
thresholdNoMinimum similarity threshold (0-1, default 0.3)

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.5.0

TDQS

A3.6/5.0
Behavior3/5

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

With no annotations, the description carries the burden itself. It does add real behavioral context: results blend global patterns with those adopted by the given project, which an agent could not assume. It says nothing about token cost, ranking behavior, or return shape, which significant for a search tool with a similarity threshold.

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?

Two sentences with no waste. Purpose comes first, then the one piece of behavioral nuance worth knowing, so the text is front-loaded and short.

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?

A fully documented five-parameter search schema plus a clear purpose sentence is nearly enough for correct invocation. The only remaining gap is return shape and result ordering, which the description never touches and no output schema covers.

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 coverage is 100% and every parameter has a description covering defaults, ranges, and examples, so the schema already does this work. The description's only beyond-schema signal is the global-plus-project blending rule, which the schema's project field also states.

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?

States a specific verb and resource plus the retrieval method: 'Search for development patterns using semantic similarity.' That clearly separates it from memory_search in the sibling list, but it never mentions pattern_suggest or pattern_adopt, so an agent must infer which pattern tool fits.

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?

Usage is only implied by the second sentence about project context; there is no explicit when-to-use, when-not-to-use, or named alternative among pattern_create, pattern_suggest, or pattern_adopt. An agent can guess it is for lookup, but the routing decision is left to inference.

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