# ClariLayer > ClariLayer is the context layer you never have to curate — it grows out of the work you are already doing, and every definition is reconciled against your source, not just asserted. Connect it to claude.ai, Claude Code, Cursor, or Codex over MCP. It bootstraps five artifact kinds — SQL, dbt, CLAUDE.md, dictionary/codebook, and semantic model — and reconciles one saved definition at a time through warehouse actual_sample or row-free HubSpot crm_evidence, so your agent stops re-explaining your data every session. ## Key Pages - [Home](https://clarilayer.com) - [Features](https://clarilayer.com/features) - [Use Cases](https://clarilayer.com/use-cases) - [Pricing](https://clarilayer.com/pricing) - [About](https://clarilayer.com/about) - [Blog](https://clarilayer.com/blog) - [Methodology](https://clarilayer.com/methodology) - [For teams](https://clarilayer.com/for-teams) ## Comparisons & Security - [Security](https://clarilayer.com/security) - [Comparisons](https://clarilayer.com/comparisons) - [ClariLayer vs CLAUDE.md](https://clarilayer.com/comparisons/claude-md) - [ClariLayer vs Semantic Layers](https://clarilayer.com/comparisons/semantic-layer) ## Product Facts - ClariLayer is the context layer you never have to curate — it grows out of the work you are already doing, and every definition is reconciled against your source, not just asserted. It is delivered over MCP so an individual analyst or RevOps operator can give their AI durable, checkable context. - In our internal paired eval — three batteries, 38 pre-registered data questions, same agent with and without the layer — the agent scored 36/38 with ClariLayer connected vs 26/38 without. The cheaper the model, the bigger the lift (the control went confidently wrong under session load). - It is single-player: one analyst or RevOps operator, their own data, their own agent — no team account or procurement required. The production service supports claude.ai through OAuth; Claude Code, Cursor, and Codex connect over MCP with a context key. - Connect the clarilayer MCP server at POST /api/mcp/mcp. The four headline verbs are recall (get_analysis_context), remember, bootstrap, and reconcile; context_checkpoint separately records a bounded completion receipt. - bootstrap bulk-ingests context from artifacts you already have — five source kinds: validated SQL (deterministically structured into tables/joins/grain), a data dictionary / codebook (the agent maps it into structured per-variable schema-notes), a semantic-layer artifact such as a Databricks Metric View or dbt semantic models (the agent normalizes it into structured models, one canonical metric definition each), dbt models, and CLAUDE.md / freeform notes. - propose and propose_batch suggest context for your review instead of saving it directly: proposals land in your Context Inbox to accept or reject (nothing is recalled until you accept). propose_batch is the bulk path and the vehicle for conversation harvest — ask your agent to distill the durable facts from a working session into your Inbox; explicit-request only, you approve each, and the transcript is never sent to ClariLayer (only the distilled candidate facts cross the boundary). - Each explicit reconcile checks one compatible saved definition through one shipped adapter. Warehouse definitions accept agent-supplied actual_sample evidence: columns, an optional row count, and optional preview rows. HubSpot CRM definitions accept bounded crm_evidence: property metadata and aggregate value distributions, with CRM rows recursively forbidden. - HubSpot reconcile is generally available to authenticated organizations behind the global emergency kill switch. Salesforce CRM contracts can be stored and recalled, but Salesforce reconcile is disabled. - In the personal MCP reconciliation path, ClariLayer never holds source credentials, executes SQL, or calls HubSpot; the agent is the connector. Optional preview rows are permitted only in warehouse actual_sample evidence, while CRM evidence is row-free. Separately configured team connectors belong to the gated Governed Context Edge surface and are not part of this personal path. - context_checkpoint durably and idempotently persists the agent's managed-protocol context_updated or no_update_required declaration. It validates ownership and eligibility of referenced ClariLayer objects; it does not independently prove an entry changed or external work happened. Proposal-only work and update_failed cannot complete the loop, and the receipt never certifies code, deployment, query output, provider state, or semantic correctness. - Statuses are asserted and caveat. The stronger verified status is not live and remains gated off. - The context you build compounds across sessions and is portable across claude.ai, Claude Code, Cursor, and Codex. The Governed Context Edge — shared team canon, Diff-to-team, and conflict adjudication — is built and in a hand-run private pilot; teams request access at clarilayer.com/for-teams. ## Docs - [ClariLayer Docs](https://clarilayer.com/docs) - [MCP Quickstart](https://clarilayer.com/docs/getting-started) - [bootstrap verb](https://clarilayer.com/docs/quickstart/bootstrap) - [Use ClariLayer with Databricks (semantic_model import)](https://clarilayer.com/docs/quickstart/databricks) - [harvest & propose workflow (propose_batch)](https://clarilayer.com/docs/quickstart/harvest) - [recall verb (recall_context and get_analysis_context)](https://clarilayer.com/docs/quickstart/recall) - [remember verb](https://clarilayer.com/docs/quickstart/remember) - [reconcile verb](https://clarilayer.com/docs/quickstart/reconcile) - [Verified vs Asserted](https://clarilayer.com/docs/concepts/verified-vs-asserted) - [The Context Layer](https://clarilayer.com/docs/concepts/context-layer) - [The Reasoning Trail](https://clarilayer.com/docs/concepts/reasoning-trail) - [AI Agent Context Guide](https://clarilayer.com/docs/guides/ai-agent-context) - [dbt-check CLI Guide](https://clarilayer.com/docs/guides/dbt-check) - [SaaS Metrics Definition Library](https://clarilayer.com/docs/reference/saas-metrics) - [Annual Recurring Revenue Definition](https://clarilayer.com/docs/reference/saas-metrics/arr) - [Monthly Recurring Revenue Definition](https://clarilayer.com/docs/reference/saas-metrics/mrr) - [Net Revenue Retention Definition](https://clarilayer.com/docs/reference/saas-metrics/nrr) - [Churn Definition](https://clarilayer.com/docs/reference/saas-metrics/churn) - [Pipeline Coverage Definition](https://clarilayer.com/docs/reference/saas-metrics/pipeline-coverage) - [Gross Revenue Retention Definition](https://clarilayer.com/docs/reference/saas-metrics/gross-revenue-retention) - [Expansion MRR Definition](https://clarilayer.com/docs/reference/saas-metrics/expansion-mrr) - [Contraction MRR Definition](https://clarilayer.com/docs/reference/saas-metrics/contraction-mrr) - [Customer Churn Rate Definition](https://clarilayer.com/docs/reference/saas-metrics/customer-churn-rate) - [Logo Retention Definition](https://clarilayer.com/docs/reference/saas-metrics/logo-retention) - [Average Revenue per Account Definition](https://clarilayer.com/docs/reference/saas-metrics/arpa) - [Annual Contract Value Definition](https://clarilayer.com/docs/reference/saas-metrics/acv) - [ARR Growth Rate Definition](https://clarilayer.com/docs/reference/saas-metrics/arr-growth-rate) - [Sales Cycle Length Definition](https://clarilayer.com/docs/reference/saas-metrics/sales-cycle-length) - [Win Rate Definition](https://clarilayer.com/docs/reference/saas-metrics/win-rate) - [Forecast Accuracy Definition](https://clarilayer.com/docs/reference/saas-metrics/forecast-accuracy) - [API v1 Overview](https://clarilayer.com/docs/api/v1) - [API v1 Authentication](https://clarilayer.com/docs/api/v1/authentication) - [GET /api/v1/metrics and GET /api/v1/metrics/{id}](https://clarilayer.com/docs/api/v1/metrics) - [GET /api/v1/metrics/{id}/contract](https://clarilayer.com/docs/api/v1/metrics-contract) ## Blog - [Semantic Recall: Helping Your AI Find What It Saved](https://clarilayer.com/blog/semantic-recall-find-saved-context) - [We checked every public dbt project we could find for docs-vs-warehouse drift](https://clarilayer.com/blog/dbt-docs-warehouse-drift-survey) - [How a Context Layer Differs From Notes and AI Memory](https://clarilayer.com/blog/context-layer-vs-notes-and-ai-memory) - [Anthropic and OpenAI both said context is the bottleneck for data agents. Here's what they didn't say.](https://clarilayer.com/blog/what-anthropic-and-openai-didnt-say-about-context-for-data-agents) - [Your AI Agent Used a Retired Metric Definition. Did It Tell You?](https://clarilayer.com/blog/post-trust-benchmark-v2-1) - [The ClariLayer Trust Benchmark v1: A 2,136-Call Study of AI Accuracy](https://clarilayer.com/blog/post-trust-benchmark-v1) - [The Context Gap: Why Warehouses and Semantic Layers Aren't Enough](https://clarilayer.com/blog/context-gap-warehouses-semantic-layers) - [What ClariLayer Does (And What It Does Not)](https://clarilayer.com/blog/what-clarilayer-does) - [Why AI Agents Need a Context Layer](https://clarilayer.com/blog/why-ai-agents-need-context) - [Why Your Metrics Need a Context Layer](https://clarilayer.com/blog/why-metrics-need-context) ## Full Documentation # Docs Connect Claude Code, Cursor, Codex, or claude.ai. Save one confirmed decision from your work, then ask your AI to recall it in a later project or session. ## Start here [Choose your client and start setup](/docs/getting-started#1-connect-your-client). Start free. No credit card. [Pricing](/pricing). The [Quickstart](/docs/getting-started) keeps connection, one saved decision or rule, and agent recall together. Connecting MCP is separate from optional history import or ongoing capture: you choose the source, space, provider, and what to accept. - [The Context Layer](/docs/concepts/context-layer) explains how saved context travels between tasks. - [Verified vs Asserted](/docs/concepts/verified-vs-asserted) explains the live `asserted` and `caveat` statuses; `verified` is not live. ## The four verbs ClariLayer documents four verbs. `recall` and `remember` are the everyday continuity loop. `bootstrap` and `reconcile` cover structured Analytics context and its supported evidence paths. - [recall](/docs/quickstart/recall) pulls relevant saved decisions, definitions, notes, and caveats for the current task. General work uses `recall_context`; supported Analytics or CRM work also uses `get_analysis_context` when relevant. - [remember](/docs/quickstart/remember) saves a confirmed decision, constraint, definition, or correction for later sessions. It is an explicit agent-triggered write. - [bootstrap](/docs/quickstart/bootstrap) seeds Analytics context from SQL, dbt models, `CLAUDE.md` notes, a data dictionary or codebook, and semantic-layer models. - [reconcile](/docs/quickstart/reconcile) checks a compatible Analytics SQL definition against warehouse `actual_sample` evidence or a HubSpot CRM contract against row-free `crm_evidence`; a mismatch is flagged as a caveat. Saved context keeps its source and applicability visible. Correct, replace, supersede, or forget an entry when the work changes. General work memory is not independently reconciled; the `asserted` and `caveat` model applies to the supported Analytics evidence paths described above. ## Going deeper - [AI Agent Context Guide](/docs/guides/ai-agent-context) walks through the recall-first working loop in practice. - The completion loop uses `context_checkpoint` to persist the agent's bounded managed-protocol declaration and validate its referenced ClariLayer objects. It does not independently prove that an entry changed, external code deployed, or a source result is correct. - [SaaS Metrics Definition Library](/docs/reference/saas-metrics) is a reference for the metric definitions teams argue about most: ARR, MRR, NRR, churn, and pipeline coverage. ## For teams The Governed Context Edge supports shared team canon, governed write and explicit adoption. It is available as a hand-run private pilot: - [For teams](/for-teams) covers where ClariLayer goes as teams adopt it: personal context layers joined by a governed Context Edge — propose your definition up, adopt the team's canon down, with agency. - [API v1 overview](/docs/api/v1) documents the read-only Contract API an external workflow or BI tool can use to read a governed metric's canonical context. # Quickstart ## 1. Connect your client Choose your client, copy the setup prompt, and paste it into that AI. The prompt can configure supported local clients or guide you through hosted settings. It does not contain a context key, authorize context uploads, or edit project instructions. You may need to complete browser sign-in or restart the client before its tools appear. Use the manual configuration under the selected client only when the assisted path cannot finish. ClariLayer is **the context layer you never have to curate**. Start with one decision or rule you want your AI to remember. Start free. No credit card. [See pricing](/pricing). After connecting, ask your agent to call `clarilayer__health`. A successful response confirms the authenticated workspace, not that a particular rule was used. If authentication fails, check your key or complete the claude.ai approval flow. [Connection recovery](#connection-recovery) has the details.
Optional: bring over selected history after connecting Connecting ClariLayer does not read local history, install a collector, or accept past context. If your setup is supported, you separately choose a local history source, an authorized space, and an extraction provider. Review the extracted batch before accepting it. Ongoing capture is another explicit choice and can be paused or revoked. Source support and extraction-provider support are different. Current qualified extraction uses the version-specific Claude CLI profile; OpenAI and Cursor extraction providers are unavailable, and native Cursor history qualification remains limited. Your selected source content is processed by the provider you choose. ClariLayer stores extracted context rather than a raw transcript archive.
## 2. Save one artifact or rule Pick one decision, preference, rule, lesson, or short Analytics artifact you already use. Ask your agent: > Help me save this selected decision or rule as durable ClariLayer context. Keep its source and applicability. Ask about anything ambiguous before saving, and reuse an existing equivalent instead of creating a duplicate. No file or source access? Describe one rule yourself, such as how your team handles refunds. Your agent reads a selected file locally and sends the chosen content to ClariLayer. The browser cannot inspect your files. ClariLayer holds no warehouse or CRM credentials, runs no SQL, and does not call your CRM provider in this personal MCP flow. If you already have saved context, reuse an existing personal rule; when guided setup is available, you can choose it in Connect your AI. A pending proposal still needs Inbox review; it is not saved context for this exercise. The [bootstrap reference](/docs/quickstart/bootstrap) covers all five source kinds: `sql`, `dbt`, `claude_md`, `dictionary`, and `semantic_model`. ## 3. Ask your AI to recall it Ask: “Use ClariLayer recall before answering: what should I know about [the decision or rule]?” Your agent uses `recall_context` for general work, or `get_analysis_context` for Analytics. Inspect the returned source and applicability. Analytics entries also carry `asserted` or `caveat`; general work memory is not independently verified. When you need the complete body or stored SQL, use `get_context_entry` with the `entry_id` returned by general recall, or with the type/name address returned by Analytics recall. [Read the recall reference](/docs/quickstart/recall). When the guided setup is available, its browser preview lets you try the question against a scoped read of saved context. Preview does not run your agent or record agent use. After the agent's real recall, use **Check agent reuse** in Connect. Missing or partial activity is unknown; it does not prove the rule was never used. You can report whether the result was useful, or skip.
Optional: find context by meaning You can search saved context by name without semantic indexing. When self-service consent is available, guided setup with an eligible selected starter reveals an optional organization-wide choice for an owner/admin. The older setup flow offers this choice before the connection instructions when the guide is off. Existing granted, withheld or revoked decisions are not re-prompted; an error dismissal writes nothing. Enabling permits eligible existing and future entry names/main text and recall query text to be sent to Google through the Vercel AI Gateway; ClariLayer stores entry vectors. Indexing is asynchronous, and search availability depends on the service controls. **Not now** records withheld. Check progress or change consent in Account settings. Revocation removes stored embedding rows, but in-flight requests may finish and data already sent cannot be recalled. Read the [semantic indexing privacy notice](/privacy#semantic-indexing).
Credentials and other deployments ClariLayer's MCP server is a remote, stateless Streamable HTTP endpoint at `POST /api/mcp/mcp`. Claude Code, Cursor, Codex, and other compatible clients can use the remote endpoint; claude.ai uses its hosted Connector flow. A client that supports only stdio needs a compatible HTTP bridge and is not directly supported by the generic route. Use an MCP-capable client and a ClariLayer workspace. Local clients use a personal `cl_…` context key. `context:read` permits recall; saving or importing requires `context:write`. The full key is shown once: store it securely and keep it out of prompts, tickets and recordings. Revoke a lost key and create a replacement. Prefer OAuth when the selected client offers a compatible flow. ClariLayer has not verified OAuth end to end in every client. When OAuth is unavailable, enter the context key directly in the client's secure bearer-token, API-key, or Authorization-header field; never paste it into AI chat. The production claude.ai connector uses OAuth approval, with no context key field. A self-hosted or other deployment must enable and configure OAuth before offering that path. Use the deployment's canonical app endpoint; do not replace it with a marketing URL.
Connection recovery and managed instructions For a local-client authentication failure, check that the full key was installed and has not been revoked. For claude.ai, reconnect and finish the approval flow. Return to the [client selector](#1-connect-your-client) to open setup with your selected client; sign-in and signup preserve that choice. Open **Optional: install or update project instructions** under your local client's snippet when you are ready to make recall part of your working routine. The managed prompt names exactly one target for the client you selected. Copying it does not change your repository: your local agent inspects that one file, asks for approval before an edit, and preserves bytes outside the recognized ClariLayer range. An already-current or conflict decision, or an approved write, reports exactly `installed`, `already current`, or `conflict/manual review`; if you decline approval, the agent stops without claiming an installation state. A malformed managed range, a legacy stanza whose sentinel remains but whose full bytes differ, or incompatible Cursor frontmatter fails closed to manual review. For Claude Code and Codex, otherwise-unrecognized existing text is preserved while the managed range appends on first install. If an early `CLAUDE.md` or `AGENTS.md` kept the exact old ClariLayer heading but shortened or edited the section underneath it, open **Older shortened ClariLayer section?** and explicitly copy the separate guided recovery prompt. The standard installer remains fail closed. The recovery option appears only for Claude Code and Codex, shows a full one-file replacement diff before asking for approval, and stops on ambiguous headings, fenced examples, marker fragments, or concurrent file changes. Cursor recovery stays manual because its frontmatter and target semantics differ. Neither copying option lets the browser or remote server read or write your repository.
Completion receipts for ongoing work The managed instructions establish a completion loop: **recall → confirmed live remember/reconcile → `context_checkpoint`**. Your agent recalls before relevant data work, writes a confirmed durable change to live context with `remember`, and reconciles it when appropriate. If the suggestion still needs human review, it uses `propose` and stops for acceptance; proposal-only work cannot continue to a completion receipt. After an accepted proposal is live, or after another confirmed live outcome, the completion loop can continue. A pending proposal is not live recall context, and an `update_failed` checkpoint does not allow completion. When the task made no durable context change, the agent can use `no_update_required` only after explicitly checking the relevant facets. The receipt has a deliberately narrow meaning: it persists the agent's managed-protocol declaration (`context_updated` or `no_update_required`) and validates ownership and eligibility of any referenced ClariLayer objects. It does **not** independently prove that an entry changed during this task, that code deployed, that Databricks validation passed, that a query result is correct, or that the saved rule is semantically equivalent to an external system.
## The four verbs ClariLayer documents four verbs. General work starts with `recall_context` and explicit `remember` writes. `bootstrap`, `get_analysis_context`, and `reconcile` are the structured Analytics path. - [recall](/docs/quickstart/recall) — use `recall_context` for selected general work, preserving source and applicability. Use `get_analysis_context` as the additional specialist Analytics or CRM recall path. - [remember](/docs/quickstart/remember) — save a confirmed decision, fact, preference, rule, lesson, or Analytics definition so your agent can use it in later sessions. - [bootstrap](/docs/quickstart/bootstrap) — import selected SQL, dbt, `CLAUDE.md` notes, a data dictionary or codebook, and semantic-layer models into Analytics context. - [reconcile](/docs/quickstart/reconcile) — check a saved SQL definition against warehouse `actual_sample` evidence or a HubSpot CRM contract against row-free `crm_evidence`; a mismatch is flagged as a caveat. Salesforce contracts remain store/recall-only. ### Beyond the four verbs Beyond the basic recall-and-remember loop, the agent can also: - **Record a completion receipt** — after the relevant recall and confirmed write/reconcile path, call `context_checkpoint` so the task has a durable `context_updated` or `no_update_required` receipt. - **[Harvest a whole session](/docs/quickstart/harvest)** — on your explicit request, distill the durable facts from a working conversation and stage them in your **Context Inbox** for review (via `propose` / `propose_batch`). Nothing is auto-saved; you approve each, and the transcript is never sent to ClariLayer — only the distilled candidate facts. - **Manage what's saved** — reversibly retire context with `archive` / `restore` (and `archive_reasoning` / `restore_reasoning` for the caveats and assumptions attached to an entry), or remove it for good with `forget`. ## What "checked" means General work memory keeps its source and applicability visible, but it is not independently reconciled against an external source. When specialist Analytics `reconcile` runs against a supported warehouse or HubSpot evidence path, a declared-vs-observed mismatch is flagged as a **caveat**; otherwise the entry stays **asserted**. Those are the only public Analytics outcomes. The **verified** status remains gated and is not live. Read [Verified vs Asserted](/docs/concepts/verified-vs-asserted) for exactly what each status means and why. ## Where to go next - [The Context Layer](/docs/concepts/context-layer) explains selected memory, recall, source, applicability, correction, and specialist Analytics reconciliation. - [AI Agent Context Guide](/docs/guides/ai-agent-context) shows the recall-first working loop in practice. - [SaaS Metrics Definition Library](/docs/reference/saas-metrics) is a reference for the metric definitions teams argue about most. - The [For teams](/for-teams) strand covers what happens as your personal context merges into shared, governed team context. # bootstrap Start with one artifact whose meaning you can check: a short SQL query, one dbt model, a note, a dictionary entry, or a semantic-model definition. Ask your agent to inspect only that selected source and clarify ambiguous facts before saving. If you have no file to share, [remember one rule](/docs/quickstart/remember) instead. The [Quickstart](/docs/getting-started#2-save-one-artifact-or-rule) walks through that first task. When you want to import more, `bootstrap` supports bounded batches of the five source kinds below. You choose the content the agent sends. **`bootstrap` feeds on your files, never your data.** Your agent reads each artifact locally — your SQL, your dbt models, your `CLAUDE.md`, a data dictionary, a semantic-layer artifact — and passes what it reads to the `bootstrap` tool (raw text for some kinds, structured `rows` or `models` for others). ClariLayer never connects to or reads your warehouse, holds no credentials, and runs no server-side SQL, so you stay in control of exactly what is shared. ## What it ingests `bootstrap` accepts five source kinds today. Three are **structured** (`sql`, `dictionary`, and `semantic_model`); the other two are stored mostly as raw notes: - **`sql`** — a SELECT query. This is the only source kind structured by **server-side parsing of raw text**: ClariLayer validates the SQL and deterministically extracts a structured shape (tables, joins, group-bys, time grain) so the resulting entry is genuinely queryable context, not just stored text. (`dictionary` and `semantic_model` are also structured, but via a different mechanism — see below.) - **`dbt`** — a dbt model file. The content is imported and stored as a schema note (raw content plus light metadata). It is not parsed into structure the way SQL is. - **`claude_md`** — a `CLAUDE.md` or freeform notes. Imported and stored as a note so your agent can recall it later. - **`dictionary`** — a column / variable dictionary (a codebook, data dictionary, CSV header + labels, `df.dtypes`, a Looker view, or a SAS/SPSS/Stata export). This is **another structured source kind**, but it is structured differently from `sql`: there is no server-side dictionary parser. Instead your agent maps whatever artifact it has into a structured `rows` payload, and ClariLayer fans those agent-supplied rows out to one schema note per variable. This is the cold-start path when your context lives in a codebook rather than a SQL repo. See [the dictionary section below](#dictionary-a-codebook-or-data-dictionary). - **`semantic_model`** — a semantic-layer artifact (a Databricks Metric View, dbt semantic models, a Snowflake semantic view, and so on). Like `dictionary`, there is no server-side vendor parser: your agent normalizes the artifact into structured `models` and ClariLayer fans those out to one metric **`definition`** per model, each carrying a structured metric contract. This is the path when your definitions already live in a semantic layer. See [Use ClariLayer with Databricks](/docs/quickstart/databricks) for a worked example. ### `dictionary` — a codebook or data dictionary If your data context lives in a codebook or data dictionary (common for survey, research, or spreadsheet-first work that has no SQL repo behind it), point your agent at it. Unlike the other kinds, you do **not** paste raw file text: your agent maps the artifact into structured `rows` — each row is one column / variable — and ClariLayer expands it into one schema note per row. There is no per-format parser; the agent does the mapping, so any codebook shape works (a CSV header plus labels, `df.dtypes`, a dbt `schema.yml`'s column docs, a SAS/SPSS/Stata dictionary export). Each row carries a required `variable` and optional `label`, `type`, `value_labels` (a coded-value → label map), and `notes`. An optional `dataset` on the source names the table. A small worked example — a customer-survey codebook: ```json { "kind": "dictionary", "name": "Customer survey 2026", "dataset": "survey_2026", "rows": [ { "variable": "respondent_id", "label": "Stable per-respondent identifier (hashed owner email)", "type": "string" }, { "variable": "nps_bucket", "label": "Net Promoter Score bucket from the q3 survey", "type": "categorical", "value_labels": { "0": "Detractor (0-6)", "1": "Passive (7-8)", "2": "Promoter (9-10)" } }, { "variable": "csat_score", "label": "Customer satisfaction rating, 1-5 Likert", "type": "integer", "notes": "null when the respondent skipped the item" } ] } ``` Each row becomes **one recall-addressable schema note** named `{dataset}.{variable}` — so the example above lands `survey_2026.respondent_id`, `survey_2026.nps_bucket`, and `survey_2026.csat_score`. When `dataset` is omitted, the source `name` is used as the prefix instead. After this, asking your agent "what does `survey_2026.nps_bucket` mean?" recalls the variable with its label and decoded value labels. The same per-call bounds apply (each row is size-checked, and a very large dictionary is split across multiple calls). ## How to run it Ask your agent to bootstrap from a directory or a set of files. A natural prompt: > Bootstrap my ClariLayer context from `./analytics/sql` and my dbt models in `./models`. Or, when your context lives in a codebook instead of a SQL repo: > Bootstrap my ClariLayer context from the data dictionary in `./docs/survey_2026_codebook.csv`. Your agent reads those files and calls `bootstrap` with their content (mapping a codebook into the `dictionary` source's `rows`). The tool is bounded so a single call cannot flood your store: each source is capped (around 50 KB per source), and the whole call is capped (around 200 KB and 200 sources). Oversized sources are reported back, never silently truncated. ## What you get back `bootstrap` returns a summary of what happened: how many entries were created, updated, and skipped, a breakdown by source type, and any sources it dropped (for example, an oversized file or an unparseable SQL statement). Ingestion is deduped, so re-running `bootstrap` over the same artifacts updates existing entries rather than creating duplicates. After a bootstrap, the entries it created are stored with status `asserted` and provenance that records where they came from: SQL uses `sql_import`, dbt uses `dbt`, dictionary rows use `dictionary`, semantic models use `semantic_model`, and `CLAUDE.md` / freeform notes use `you`. The separate `agent` provenance identifies facts an AI agent extracted through an agent-originated write path; it is not the provenance assigned to `claude_md` bootstrap entries. `asserted` is the honest baseline — the entry has not been contradicted, but it is not stamped as proven. To check a supported definition, run [reconcile](/docs/quickstart/reconcile) against it. ## Bootstrap, then recall Once your store has content, your agent can [recall](/docs/quickstart/recall) it in-flow. The typical first loop is: 1. `bootstrap` the relevant SQL, dbt, `CLAUDE.md` notes, dictionary rows, or semantic models so the store is not empty. 2. Ask a question; your agent recalls the relevant definitions and answers from them. 3. When your agent learns something new or you correct it, [remember](/docs/quickstart/remember) it so the next session benefits. 4. When a number looks off, [reconcile](/docs/quickstart/reconcile) a stored SQL definition with warehouse `actual_sample` or a HubSpot CRM contract with row-free `crm_evidence`. ## Privacy posture ClariLayer receives only what your agent chooses to send — the artifact text (your SQL, dbt models, `CLAUDE.md`), or the structured input your agent maps for the schema-first kinds (a `dictionary` source's `rows`, a `semantic_model` source's `models`); it never connects to your warehouse, holds source credentials, executes SQL server-side, or calls a CRM provider. The `sql` structuring is a static parse of query text, not a live data read. `reconcile` is a separate flow: warehouse `actual_sample` can include optional preview rows with real values, while HubSpot `crm_evidence` is row-free by contract. ## See also - [Quickstart](/docs/getting-started) — connect a CLI agent with a context key or production claude.ai over OAuth. - [recall](/docs/quickstart/recall) — pull bootstrapped context back in-flow. - [Verified vs Asserted](/docs/concepts/verified-vs-asserted) — what the `asserted` status on a bootstrapped entry means. # recall `recall` is how your agent pulls relevant saved context mid-task without you leaving your flow. General work uses the `recall_context` MCP tool. When your agent is about to draft, decide, or answer a question, it can recall selected decisions, facts, preferences, rules, and lessons from the authorized space, with source and applicability intact. Supported Analytics or CRM work has an additional specialist path through `get_analysis_context`. This is the structural fix for the old "destination app" problem. You do not open a tool to look a number up; the context rides along inside claude.ai, Claude Code, Cursor, or Codex, and your agent reaches for it when it needs it. ## What it returns `recall_context` takes a query and optional `project` and `purpose` relevance hints. It searches the selected authorized space; those hints do not change access or silently exclude other projects. Each result carries: - an **entry ID and bounded summary**; - its **source**, including provenance and available capture metadata; - its **applicability**, including general or bounded scope, project references, and conditions. Recall is read-only and in-flow. It never mutates your store; it only surfaces what is already there. Because it reads, it needs only `context:read` — a read-only context key can recall. For Analytics, `get_analysis_context` returns definitions, schema notes, saved queries, and notes with provenance and `asserted` or `caveat` status. There is no public query-history bootstrap source or importer. ## Fetch the full entry Recall returns bounded body previews and does not inline stored SQL. For general recall, call `get_context_entry` with the returned `entry_id` when `summary_truncated` is true or you need complete content. For Analytics recall, use the type/name address when `has_sql` or `has_crm_contract` indicates more detail. The browser's scoped preview is separate: it does not run MCP recall or record agent use. ## Who decides when to recall Recall is a tool your agent decides to call — ClariLayer exposes it; it does not force a call. In practice you get the most value by making recall the first step of your agent's loop. For Claude Code, Cursor, or Codex, the [Quickstart](/docs/getting-started#2-install-the-mcp-server) generates one managed-install prompt from the local client you explicitly select. Your local agent inspects only that client's canonical instruction target, asks before editing, and installs a managed range that carries the recall-first and completion-checkpoint workflow into future sessions. The browser and remote server do not inspect or edit your files. The claude.ai path connects to the production custom Connector over OAuth and does not install a local project instruction file. That is the difference between "can recall in-flow" (always true — the tool is there) and "always recalls first" (true only when your client config or prompt makes it so).