Skip to main content
Glama

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault
DB_PATHNoWhere vectors are stored. Default: ./lancedb/./lancedb/
BASE_DIRNoOnly files under this path can be accessed. Default: current directory.
WEB_PORTNoPort for web interface. Default: 30003000
CACHE_DIRNoModel cache directory. Default: ./models/./models/
RAG_RRF_KNoRRF smoothing constant (only applies in rrf mode). Default: 6060
MODEL_NAMENoHuggingFace embedding model. Default: Xenova/all-MiniLM-L6-v2Xenova/all-MiniLM-L6-v2
UPLOAD_DIRNoTemporary directory for web UI file uploads. Default: ./uploads/./uploads/
RAG_API_KEYNoAPI key for authentication. Default: unset
CORS_ORIGINSNoAllowed origins (comma-separated, or *). Default: localhostlocalhost
RAG_GROUPINGNoQuality filter: unset, similar (top group only), or related (top 2 groups). Default: unset
MAX_FILE_SIZENoBiggest file you can ingest (bytes). Default: 104857600 (100 MB)104857600
JSON_BODY_LIMITNoMax request body size. Default: 5mb5mb
RAG_SEARCH_MODENoFusion mode: boost (multiplicative keyword boost) or rrf (Reciprocal Rank Fusion). Default: boostboost
REQUEST_LOGGINGNoTurn on request audit logging. Default: falsefalse
RAG_HYDE_API_KEYNoAPI key for LLM backend (required when RAG_HYDE_BACKEND=api). Default: unset
RAG_HYDE_BACKENDNorule-based for local template expansion, api for LLM-based HyDE. Default: rule-basedrule-based
RAG_HYDE_ENABLEDNoTurn on query expansion for better recall. Default: falsefalse
RAG_MAX_DISTANCENoDrops results below this relevance threshold (use with boost mode). Default: unset
RAG_HYBRID_WEIGHTNoBalance between vector and BM25. 0 = vector-only, 1.0 = BM25-only. Default: 0.60.6
ALLOWED_SCAN_ROOTSNoDirectories allowed for database scanning. Default: Home directory
RAG_HYDE_API_MODELNoModel for LLM-based expansion. Default: claude-haiku-4-5-20251001claude-haiku-4-5-20251001
RAG_RERANKER_MODELNoHuggingFace cross-encoder model. Default: Xenova/ms-marco-MiniLM-L-6-v2Xenova/ms-marco-MiniLM-L-6-v2
REQUEST_TIMEOUT_MSNoAPI request timeout. Default: 3000030000
RAG_FTS_COOLDOWN_MSNoHow long to wait before retrying FTS after hitting the failure limit. Default: 300000 (5 min)300000
RAG_HYDE_EXPANSIONSNoNumber of expanded queries to generate. Default: 22
RAG_RERANKER_DEVICENoDevice for the reranker (same options as RAG_EMBEDDING_DEVICE). Default: autoauto
RAG_EMBEDDING_DEVICENoDevice for running embeddings: auto, cpu, cuda, dml, webgpu, wasm, gpu, webnn. Default: autoauto
RAG_FTS_MAX_FAILURESNoFull-text search failures before FTS is temporarily disabled. Default: 33
RAG_RERANKER_ENABLEDNoTurn on cross-encoder reranking for better results. Default: falsefalse
RATE_LIMIT_WINDOW_MSNoRate limit time window (ms). Default: 6000060000
RAG_HYDE_API_BASE_URLNoAPI endpoint for LLM backend. Default: https://api.anthropic.comhttps://api.anthropic.com
RATE_LIMIT_MAX_REQUESTSNoMax requests per window. Default: 100100
RERANKER_INIT_TIMEOUT_MSNoTimeout for model download and initialization. Default: 600000 (10 min)600000
RAG_GROUPING_STD_MULTIPLIERNoHow many standard deviations between groups counts as a relevance gap. Default: 1.51.5
RAG_HYBRID_CANDIDATE_MULTIPLIERNoHow many extra vector candidates to grab before keyword reranking. Default: 22
RAG_RERANKER_CANDIDATE_MULTIPLIERNoFetch this many extra candidates for the reranker to score. Default: 22

Capabilities

Features and capabilities supported by this server

CapabilityDetails
tools
{
  "listChanged": true
}

Tools

Functions exposed to the LLM to take actions

NameDescription
query_documentsA

Search your documents using both meaning and exact keyword matching. You can also use advanced syntax:

  • "exact phrase" → Match phrase exactly

  • field:value → Filter by custom metadata (e.g., domain:legal, author:john)

  • term1 AND term2 → Both terms required (default)

  • term1 OR term2 → Either term matches

  • -term → Exclude results containing term Results include a score (0 = best match, higher = less relevant). Set explain=true to see why each result matched.

ingest_fileA

Add a document (PDF, DOCX, TXT, MD, JSON, JSONL) to your knowledge base so you can search it. Use the full file path. If you ingest the same file again, it replaces the old version. You can tag it with metadata like author, domain, or tags.

ingest_dataA

Add text content directly instead of from a file. Good for: fetched web pages (format: html), copied text (format: text), or markdown strings (format: markdown). The source identifier lets you update the content later by re-ingesting with the same source. You can add custom metadata too. For files on disk, use ingest_file instead.

delete_fileA

Remove a document from your knowledge base. Use filePath for files you added with ingest_file, or source for content you added with ingest_data. You need to provide one or the other.

list_filesA

Show all documents in your knowledge base, with file paths and how many chunks each one has.

statusA

Check how many documents and chunks you have, the database size, and current settings.

feedback_pinA

Mark a search result as relevant for a query. Pinned results get boosted in future searches. Use this when a result was helpful.

feedback_dismissB

Mark a search result as irrelevant for a query. Dismissed results get pushed down in future searches. Use this when a result wasn't helpful.

feedback_statsA

See your feedback stats: total events, how many results you've pinned, and how many you've dismissed.

Prompts

Interactive templates invoked by user choice

NameDescription

No prompts

Resources

Contextual data attached and managed by the client

NameDescription

No resources

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/RobThePCGuy/rag-vault'

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