lemma_docs_mcp
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@lemma_docs_mcpHow does the deposit bonus accrue?"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
lemma_docs_mcp
Part of PracticeOS — the operating layer for therapy practice owners, by Private Practice Collective.
Read-only MCP (Model Context Protocol) server for semantic search over a locally supplied copy of Lemma's documentation (getlemma.com — healthcare-practice banking: entity accounts, deposit bonuses, fixed fee loans, cash sweeps, MSO-PC compliant banking). Same architecture as its siblings in this folder (whop_docs_mcp, stedi_docs_mcp, ghl_docs_mcp, …): stdio transport, TypeScript, two read-only tools, in-memory index built lazily on first call. It never calls live Lemma or banking APIs.
Open overview.html for the branded one-page summary.
Corpus
Default root:
PPC/Product/PracticeOS/Lemma/docs/(siblingPPC/ofMCP_Servers/on the drive). Override withLEMMA_DOCS_CORPUS_ROOT.Flat folder of
lemma-docs-*.mdfiles. As of 2026-08-26: 8 documents → 61 chunks — the full set of pages Lemma exposes via its markdown export endpoint.Not covered (exists on getlemma.com but has no
.mdexport): banking operations (accounts, cards, transactions, move money), insurance & billing (lockbox, EOB, reconciliation), invoicing, team management, API reference. The tools say so rather than guessing.Namespace routing keys off filename prefix:
quickstart→getting-started;changelog/roadmap→product-updates; everything else (theguides-*pages) →guides.
Related MCP server: RAG MCP Server
Tools
Tool | Purpose |
| Ranked excerpt search for a question/task. Auto-routes to a namespace, returns compact chunks with ids, source paths, pagination, follow-ups. |
| Full text of specific chunks by id, or a whole document by relative path. The expansion step after search. |
Both declare readOnlyHint, idempotentHint, openWorldHint:false, and attach structured content alongside markdown.
Build & verify
npm install
npm run build
npm run dry-run # index stats (8 docs → 61 chunks)
npm run query -- "how does the deposit bonus accrue"
npm run test # assertions against the real corpus
npm run test:fixture # 35-assertion behavior suite, runs anywhere
npm run smoke # end-to-end MCP wire-protocol test (17 checks)Register in Claude Desktop / Cowork
~/Library/Application Support/Claude/claude_desktop_config.json → mcpServers:
"lemma-docs": {
"command": "/Users/zackscriven/.nvm/versions/node/v25.9.0/bin/node",
"args": ["/Volumes/Extreme SSD/MCP_Servers/lemma_docs_mcp/dist/index.js"]
}No env needed — the corpus root default resolves relative to this folder. Restart Claude Desktop after editing. For Codex, add the equivalent [mcp_servers.lemma-docs] TOML table (see MCP_Servers/CLAUDE.md).
Licensing
Code is MIT; the Lemma documentation content is © Lemma, supplied locally, never redistributed. See NOTICE.md before publishing anything from this folder.
Available Tools
2 toolslemma_docs_contextSearch Lemma Docs ContextARead-onlyIdempotent
Search the local Lemma (getlemma.com) documentation corpus and return focused, ranked source excerpts for a question or task. Lemma is healthcare-practice banking: entity accounts, deposit bonuses, fixed fee loans, cash sweeps, MSO-PC compliant banking guardrails, and shared onboarding. Routes the query into one of three internal namespaces (getting-started: quickstart/onboarding/KYB; guides: deposit bonuses, fixed fee loans, MSO-PC compliance, collaboration, owning multiple entities; product-updates: changelog and roadmap) and returns compact chunks with source paths. This is a local documentation index only — it NEVER calls live Lemma or banking APIs, and it cannot move money or mutate any account state.
Coverage note: the corpus is the 8 pages Lemma exposes as markdown. Banking-operations pages (accounts, cards, transactions, move money), insurance/lockbox, invoicing, team-management, and the API reference are NOT in this index — say so instead of guessing when a query needs them.
Args:
query (string, required): The documentation question or task, 2-500 chars.
namespace ('auto' | 'getting-started' | 'guides' | 'product-updates', default 'auto'): Corpus area. Use 'auto' unless you already know the area.
intent ('answer' | 'build_context' | 'source_map', default 'answer'): How the returned context will be used; adjusts guidance.
max_chunks (int 1-12, default 6): Page size.
offset (int >= 0, default 0): Ranked matches to skip, for paging.
response_format ('markdown' | 'json', default 'markdown'): Text rendering; structured content is always attached.
Returns (structured): { query, namespace, intent, guidance, chunks: [{ id, score, namespace, source_type, path, heading, excerpt, metadata }], pagination: { total_matches, count, offset, has_more, next_offset? }, follow_ups: [string], truncated?, truncation_message?, stats: { indexed_chunks, returned_chunks } }
Chunk excerpts are capped; pass a chunk's id (or its path) to lemma_docs_get for the full text.
Examples:
"How does the deposit bonus accrue and when is it paid?" -> guides (deposit-bonuses).
"Open an account for a new PLLC" -> getting-started (quickstart, KYB, beneficial owners).
"Does Lemma support Zelle?" -> product-updates (roadmap workaround section).
"What guardrails does Lemma set up for an MSO-PC structure?" -> guides (mso-pc-compliance).
Follow-up paging: repeat the same query with offset=pagination.next_offset.
Errors:
"Lemma docs corpus root not found ..." -> set LEMMA_DOCS_CORPUS_ROOT to the absolute path of the lemma-docs-*.md folder and restart.
Empty chunks with guidance "No strong ... matches" -> retry with a more specific Lemma term (entity, deposit bonus, fixed fee loan, cash sweep, MSO-PC), or the topic may be outside the 8-page corpus.
| Name | Required | Description | Default |
|---|---|---|---|
| query | Yes | The Lemma documentation question or task, e.g. 'How does the deposit bonus accrue?'. | |
| intent | No | How the context will be used: 'answer' a question, 'build_context' for coding/implementation, or 'source_map' to list where sources live. | answer |
| offset | No | Number of ranked matches to skip, for paging through results (default 0). | |
| namespace | No | Corpus area to search: 'getting-started' (quickstart, onboarding, KYB), 'guides' (deposit bonuses, fixed fee loans, MSO-PC compliance, collaboration, multiple entities), 'product-updates' (changelog, roadmap), or 'auto' to route from the query (default). | auto |
| max_chunks | No | Maximum chunks to return per page, 1-12 (default 6). | |
| response_format | No | Text output format: 'markdown' for human-readable (default) or 'json' for the full machine-readable object. Structured content is always attached either way. | markdown |
Output Schema
| Name | Required | Description |
|---|---|---|
| query | Yes | |
| stats | Yes | |
| chunks | Yes | |
| intent | Yes | |
| guidance | Yes | |
| namespace | Yes | |
| truncated | No | |
| follow_ups | Yes | |
| pagination | Yes | |
| truncation_message | No |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Beyond the readOnly/idempotent annotations, the description discloses important non-obvious behaviors: it is a local documentation index only, never calls live Lemma or banking APIs, cannot move money or mutate state, and excludes specific page areas. It also explains truncation and error conditions, adding substantial behavioral context beyond annotations.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Although the description is long, it is well-structured with clear sections (coverage, args, returns, examples, errors) and every sentence contributes actionable information. The core purpose and key constraints are front-loaded before the parameter details.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
The description covers the full call contract: parameter semantics, routing behavior, return structure, pagination, examples, error handling, and explicit linkage to the sibling tool. Nothing needed for correct invocation or interpretation is missing.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100%, so the baseline is 3, but the description adds meaningful enrichment: per-namespace examples mapping queries to areas, intent usage examples, a follow-up paging pattern with offset, and clarification of response_format. These examples go beyond the schema's property descriptions.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description opens with a specific verb and resource: 'Search the local Lemma (getlemma.com) documentation corpus and return focused, ranked source excerpts.' It clearly differentiates from the sibling lemma_docs_get by noting that chunks are capped and that the full text is obtained via lemma_docs_get.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description explicitly says to use 'auto' unless the corpus area is already known, and it names the sibling tool for retrieving full text. The coverage note instructs the agent to say so instead of guessing when a query falls outside the 8-page index, which is concrete when-not-to-use guidance.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
lemma_docs_getGet Lemma Docs ChunksARead-onlyIdempotent
Fetch the full text of specific indexed Lemma documentation chunks by id, or every chunk of one document by its relative path. Use this after lemma_docs_context to expand excerpts you actually need — do not use it to browse (use lemma_docs_context for discovery). Reads the local corpus index only; it NEVER calls live Lemma or banking APIs.
Args:
ids (string[], 1-8, optional): Chunk ids exactly as returned by lemma_docs_context.
path (string, optional): A relative corpus path exactly as returned in a result's 'path' field; returns all chunks of that document in order.
response_format ('markdown' | 'json', default 'markdown'): Text rendering; structured content is always attached. At least one of ids or path is required.
Returns (structured): { found: [{ id, namespace, source_type, path, heading, text, metadata }], missing: [string], truncated?, truncation_message? }
Examples:
ids=["lemma-docs-docs-guides-deposit-bonuses.md#md-1-0"] -> full text of that section.
path="lemma-docs-docs-guides-mso-pc-compliance.md" -> every chunk of that document (may truncate; follow the truncation message).
Errors:
Calling with neither ids nor path returns an error explaining both options.
Unknown ids/paths are reported in 'missing' rather than failing the whole call.
| Name | Required | Description | Default |
|---|---|---|---|
| ids | No | Chunk ids exactly as returned by lemma_docs_context (e.g. "lemma-docs-docs-guides-deposit-bonuses.md#md-1-0"), up to 8 per call. | |
| path | No | A relative corpus path exactly as returned in a previous result's 'path' field. Returns every chunk of that document, in order. | |
| response_format | No | Text output format: 'markdown' for human-readable (default) or 'json' for the full machine-readable object. | markdown |
Output Schema
| Name | Required | Description |
|---|---|---|
| found | Yes | |
| missing | Yes | |
| truncated | No | |
| truncation_message | No |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already declare readOnlyHint, idempotentHint, and destructiveHint, but the description adds substantial behavioral context beyond that: it 'NEVER calls live Lemma or banking APIs,' unknown ids/paths are reported in 'missing' rather than failing the call, and truncation is possible with a message to follow. This is exactly the kind of non-obvious behavior an agent needs to know.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is front-loaded with purpose and usage, then organized into Args, Returns, Examples, and Errors sections. Every section earns its place, and the content is dense but non-redundant with the schema.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
The description covers validation behavior, missing-id behavior, truncation, live-API boundaries, return shape, and examples for both access modes. Given the output schema exists and the annotations cover safety, nothing an agent needs to invoke this correctly is missing.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The input schema already documents all three parameters with clear descriptions, so the baseline is 3. The description adds meaningful extras: the critical 'at least one of ids or path is required' constraint that is absent from the schema, the difference in what each mode returns, and concrete examples. This goes beyond the schema without having to carry the full parameter-documentation burden.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description opens with a specific verb-resource pair: 'Fetch the full text of specific indexed Lemma documentation chunks by id, or every chunk of one document by its relative path.' It clearly distinguishes the tool from its sibling lemma_docs_context by framing this tool as the expansion step, not the discovery step.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description explicitly says to use this tool after lemma_docs_context to expand excerpts and warns 'do not use it to browse (use lemma_docs_context for discovery).' This is direct, unambiguous routing guidance that names the alternative tool and the condition that selects it.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
TDQS
The two tools have clearly distinct roles: one performs ranked search/discovery over the corpus, the other retrieves full text for specific chunks or documents. There is no overlap or ambiguity between them.
Both tool names follow the same `lemma_docs_<verb>` pattern, with context indicating search/discovery and get indicating retrieval. The naming convention is consistent and predictable.
Two tools is on the thin side, but for a narrow local-documentation retrieval server the search-and-get pair is a reasonable minimal setup. It feels slightly sparse rather than fully fleshed out.
The server covers the core documentation workflow: discover relevant chunks and then expand them to full text. Notable gaps like listing all documents or browsing the corpus are acknowledged by the tool descriptions, and the search tool can surface paths, so agents can work around them.
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Connectors
The Needle MCP server enables semantic search on documents stored in files like PDFs, DOCX, and XLSX by connecting AI applications to external data sources. It provides capabilities to create and manage document collections, perform natural language searches on stored content, and retrieve relevant information without requiring exact keyword matches.
Agentic search over your Dewey document collections from any MCP-compatible client.
Team docs served to AI agents over MCP - search, Markdown reads, version pinning, read audit.
MCP server for querying Forkast documentation
Related MCP Servers
- FlicenseNot gradedqualityBmaintenanceEnables any MCP-compatible AI assistant to search, filter, and retrieve information from a local document collection using a hybrid search pipeline with vector, BM25, reranking, and LLM enrichment.4
- FlicenseNot gradedqualityDmaintenanceProvides tools for ingesting documents into a local vector database and retrieving relevant information via semantic search, enabling retrieval-augmented generation for MCP clients.6
- AlicenseNot gradedqualityBmaintenanceEnables semantic search over a local knowledge base using MCP tools, allowing AI clients to retrieve relevant document chunks via the search_knowledge tool.152MIT
- FlicenseNot gradedqualityCmaintenanceProvides read-only, citation-backed semantic search and retrieval-augmented generation over enterprise documents via standardized MCP tools, with local embeddings for privacy.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
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/zackscriven/lemma-docs-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server