Documentation Tags
Use#(doc) tags to add human-readable descriptions to fields. Place the tag on the line before the field definition.
Value Indexing
Use#(index_values) to index distinct values from a column. This enables AI agents to find fields by searching for data values, not just field names or descriptions.
n parameter specifies how many distinct values to index. Use n=-1 to index all values, or specify a number for high-cardinality fields where you only need a sample.
Why Value Indexing Matters
Consider a product catalog where the column is namedproduct_category but contains values like “Running Shoes” and “Athletic Apparel”.
Without value indexing, when a user asks an MCP-connected AI assistant “What are our top-selling sports gear products?”, the system can only search field names and documentation—it won’t find these products.
With value indexing, the Credible Context Engine indexes the actual values. When a user submits a natural language query, the engine identifies fields with values that match the query, then uses these retrieved fields to help an agent construct a query with the correct filter value—finding “Running Shoes” and “Athletic Apparel” without exact string matching.
When to Use Value Indexing
Use#(index_values) on:
- Names and titles - Product names, customer names, program titles
- Categorical values - Status codes, types, categories
- Lookup values - Region names, department names, brand names
- Numeric fields (amounts, counts, IDs)
- Timestamps and dates
- Fields with millions of unique values (diminishing returns)
Example: Well-Documented Model
Next Steps
Credible Context Engine
Learn how metadata powers AI discovery
Publish Your Model
Make your documented model available to the platform