Skip to main content
Glama
davidgut1982

lore-mcp

by davidgut1982

kb_search

Search a persistent knowledge base using lexical or semantic search with hybrid fusion. Retrieve relevant entries by query and optional filters.

Instructions

Search knowledge base. Lexical FTS5 (or LIKE fallback) by default; set semantic=true / hybrid=true / search_mode=hybrid to use vector embeddings + RRF fusion (requires LORE_SEMANTIC_SEARCH=true).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
queryYes
topicNo
top_kNo
semanticNo
hybridNo
search_modeNo
session_idNo
parent_query_idNo
required_requeryNo
caller_agentNo
min_trust_scoreNo
min_scoreNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections. Dates show when Glama detected each change.

  1. Changed40 schema fields changedv0.8.5
    • addedInput schema / additionalProperties
      Added value: +false
    • addedInput schema / properties / caller_agent / anyOf
      Added value: +[
      +  {
      +    "type": "string"
      +  },
      +  {
      +    "type": "null"
      +  }
      +]
    • addedInput schema / properties / caller_agent / default
      Added value: +null
    • removedInput schema / properties / caller_agent / description
      Removed value: -"Optional name of the agent/user issuing the search (retrieval telemetry, issue #5)."
    • removedInput schema / properties / caller_agent / type
      Removed value: -"string"
    • removedInput schema / properties / hybrid / description
      Removed value: -"Force hybrid (FTS5 + vector + RRF). Shortcut for search_mode='hybrid'."
    • addedInput schema / properties / min_score / anyOf
      Added value: +[
      +  {
      +    "type": "number"
      +  },
      +  {
      +    "type": "null"
      +  }
      +]
    • addedInput schema / properties / min_score / default
      Added value: +null
    • removedInput schema / properties / min_score / description
      Removed value: -"Minimum relevance score threshold. Results below this score are excluded. For hybrid mode uses rrf_score; for fts/semantic uses score. Range 0.0-1.0 for semantic/hybrid; unbounded for raw fts. Note: SQLite FTS5 uses bm25() scores which are negative (e.g. -1.5 to 0.0); set min_score to a negative value on the fts path, or use hybrid/semantic modes for intuitive 0.0-1.0 scoring."
    • removedInput schema / properties / min_score / type
      Removed value: -"number"
    • addedInput schema / properties / min_trust_score / anyOf
      Added value: +[
      +  {
      +    "type": "number"
      +  },
      +  {
      +    "type": "null"
      +  }
      +]
    • addedInput schema / properties / min_trust_score / default
      Added value: +null
    • removedInput schema / properties / min_trust_score / description
      Removed value: -"Minimum trust score threshold (0.0–1.0). Excludes entries with trust_score below this value. Useful for filtering out deprecated or low-confidence facts."
    • removedInput schema / properties / min_trust_score / maximum
      Removed value: -1
    • removedInput schema / properties / min_trust_score / minimum
      Removed value: -0
    • removedInput schema / properties / min_trust_score / type
      Removed value: -"number"
    • addedInput schema / properties / parent_query_id / anyOf
      Added value: +[
      +  {
      +    "type": "string"
      +  },
      +  {
      +    "type": "null"
      +  }
      +]
    • addedInput schema / properties / parent_query_id / default
      Added value: +null
    • removedInput schema / properties / parent_query_id / description
      Removed value: -"Optional query_id of the search this one re-queries/refines (retrieval telemetry, issue #5)."
    • removedInput schema / properties / parent_query_id / type
      Removed value: -"string"
    • removedInput schema / properties / query / description
      Removed value: -"Search query"
    • removedInput schema / properties / required_requery / description
      Removed value: -"Optional hint that this search was a re-query after an unsatisfying prior result (retrieval telemetry, issue #5)."
    • addedInput schema / properties / search_mode / anyOf
      Added value: +[
      +  {
      +    "enum": [
      +      "fts",
      +      "semantic",
      +      "hybrid"
      +    ],
      +    "type": "string"
      +  },
      +  {
      +    "type": "null"
      +  }
      +]
    • addedInput schema / properties / search_mode / default
      Added value: +null
    • removedInput schema / properties / search_mode / description
      Removed value: -"Explicit search mode. Overrides semantic/hybrid flags. Falls back to FTS when semantic is unavailable."
    • removedInput schema / properties / search_mode / enum
      Removed value: -[
      -  "fts",
      -  "semantic",
      -  "hybrid"
      -]
    • removedInput schema / properties / search_mode / type
      Removed value: -"string"
    • removedInput schema / properties / semantic / description
      Removed value: -"Force semantic (vector) search only. Shortcut for search_mode='semantic'."
    • addedInput schema / properties / session_id / anyOf
      Added value: +[
      +  {
      +    "type": "string"
      +  },
      +  {
      +    "type": "null"
      +  }
      +]
    • addedInput schema / properties / session_id / default
      Added value: +null
    • removedInput schema / properties / session_id / description
      Removed value: -"Optional opaque id linking related searches in one session (retrieval telemetry, issue #5). No effect unless LORE_HARD_NEGATIVE_MINING=true on a PostgreSQL backend."
    • removedInput schema / properties / session_id / type
      Removed value: -"string"
    • removedInput schema / properties / top_k / description
      Removed value: -"Number of results to return (default 20)."
    • removedInput schema / properties / top_k / maximum
      Removed value: -200
    • removedInput schema / properties / top_k / minimum
      Removed value: -1
    • addedInput schema / properties / topic / anyOf
      Added value: +[
      +  {
      +    "type": "string"
      +  },
      +  {
      +    "type": "null"
      +  }
      +]
    • addedInput schema / properties / topic / default
      Added value: +null
    • removedInput schema / properties / topic / description
      Removed value: -"Filter by topic"
    • removedInput schema / properties / topic / type
      Removed value: -"string"
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "properties": {
      +    "result": {
      +      "type": "string"
      +    }
      +  },
      +  "required": [
      +    "result"
      +  ],
      +  "type": "object",
      +  "x-fastmcp-wrap-result": true
      +}
  2. Changed2 schema fields changedv0.8.2
    • addedInput schema / properties / min_score
      Added value: +{
      +  "description": "Minimum relevance score threshold. Results below this score are excluded. For hybrid mode uses rrf_score; for fts/semantic uses score. Range 0.0-1.0 for semantic/hybrid; unbounded for raw fts. Note: SQLite FTS5 uses bm25() scores which are negative (e.g. -1.5 to 0.0); set min_score to a negative value on the fts path, or use hybrid/semantic modes for intuitive 0.0-1.0 scoring.",
      +  "type": "number"
      +}
    • addedInput schema / properties / min_trust_score
      Added value: +{
      +  "description": "Minimum trust score threshold (0.0–1.0). Excludes entries with trust_score below this value. Useful for filtering out deprecated or low-confidence facts.",
      +  "maximum": 1,
      +  "minimum": 0,
      +  "type": "number"
      +}
  3. First observedv0.7.0

TDQS

B3.1/5.0
Behavior3/5

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

No annotations are provided, so the description must convey behavior. It describes the default lexical search and the optional vector modes with RRF fusion, but fails to mention what happens if the required env var is missing, or any error handling. It does not discuss rate limits, authentication, or side effects, though search is read-only.

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 a single sentence that efficiently conveys the core functionality and key options. It is concise but could benefit from brevity in technical details; overall, it is well-structured and front-loaded.

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

Completeness2/5

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

Given the tool's complexity (12 parameters, multiple search modes, an output schema exists), the description is incomplete. It does not explain many parameters, output format, error conditions, or how the default fallback works. The reliance on technical terms (FTS5, RRF fusion) may also assume too much prior knowledge.

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

Parameters2/5

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

Schema description coverage is 0%, so the description must explain parameters. It only covers 4 of 12 parameters (query, semantic, hybrid, search_mode), leaving important params like top_k, session_id, min_score, etc. unexplained. This insufficiently compensates for the lack of schema descriptions.

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 states 'Search knowledge base' and details the search modes (FTS5, semantic, hybrid), clearly identifying the tool's function. The name 'kb_search' combined with the description distinguishes it from sibling tools like 'search_local' or 'search_corpora', though it could be more explicit about when to use this over other search tools.

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 explains how to enable semantic/hybrid search (setting flags and requiring an environment variable). However, it does not specify when NOT to use this tool or direct users to alternatives like 'multi_search' for broader searches, lacking comprehensive usage guidance.

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

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/davidgut1982/lore-mcp'

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