Skip to main content
Glama
zwczwczwc

Chroma MCP Server

by zwczwczwc

chroma_get_documents

Fetch documents from a Chroma collection using optional ID, metadata, or content filters. Supports logical operators, pagination, and field selection.

Instructions

Get documents from a Chroma collection with optional filtering.

Args:
    collection_name: Name of the collection to get documents from
    ids: Optional list of document IDs to retrieve
    where: Optional metadata filters using Chroma's query operators
           Examples:
           - Simple equality: {"metadata_field": "value"}
           - Comparison: {"metadata_field": {"$gt": 5}}
           - Logical AND: {"$and": [{"field1": {"$eq": "value1"}}, {"field2": {"$gt": 5}}]}
           - Logical OR: {"$or": [{"field1": {"$eq": "value1"}}, {"field1": {"$eq": "value2"}}]}
    where_document: Optional document content filters
           Examples:
           - Contains: {"$contains": "value"}
           - Not contains: {"$not_contains": "value"}
           - Regex: {"$regex": "[a-z]+"}
           - Not regex: {"$not_regex": "[a-z]+"}
           - Logical AND: {"$and": [{"$contains": "value1"}, {"$not_regex": "[a-z]+"}]}
           - Logical OR: {"$or": [{"$regex": "[a-z]+"}, {"$not_contains": "value2"}]}
    include: List of what to include in response. By default, this will include documents, and metadatas.
    limit: Optional maximum number of documents to return
    offset: Optional number of documents to skip before returning results

Returns:
    Dictionary containing the matching documents, their IDs, and requested includes

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
idsNo
limitNo
whereNo
offsetNo
includeNo
where_documentNo
collection_nameYes
Behavior3/5

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

No annotations are provided, so the description carries full burden. It describes retrieval behavior with filtering, pagination, and includes, but does not discuss error conditions, authentication needs, rate limits, or whether the operation is idempotent. The read-only nature is implied but not explicitly stated.

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 well-structured with a brief summary followed by a bulleted parameter list. It is moderately long but every sentence adds value. Could be slightly more concise by removing redundant wording.

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 7 parameters and no output schema, the description covers most aspects: parameter details, examples, and a general return description. Missing information includes possible error responses and collection existence requirements, but overall sufficiently complete for effective tool usage.

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?

Schema description coverage is 0%, yet the description extensively explains each parameter with clear examples for complex objects like 'where' and 'where_document', including supported operators (comparison, logical, regex). Default values for 'include' are noted. This adds significant value beyond the schema.

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 'Get documents from a Chroma collection with optional filtering,' which is a specific verb+resource. It naturally distinguishes from sibling tools like chroma_query_documents (which uses vector similarity) and chroma_add_documents.

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 retrieving documents with metadata/content filtering, but does not explicitly guide when to use this tool over alternatives like chroma_query_documents (which uses embedding similarity). No exclusions or when-not-to-use guidance is provided.

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

Install Server

Other Tools

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/zwczwczwc/chroma-mcp-ollama'

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