Skip to main content
Your users comment on and review work inside your app. Memory records every one of those decisions, plus the ones your AI agents make. Add your own guidelines on top, then query all of it over REST.

How it works

1

Reviews become judgments

Every review decision your users make in your app is recorded as a judgment: the decision, the reasoning, who decided, and what they decided on. This happens automatically. There is no “create judgment” endpoint.
2

You add knowledge

Ingest your guidelines, standards, and policy docs. Memory converts each file to markdown, extracts rules, and embeds it.
3

You query both

Use search for raw decision records, ask for a written answer with citations, and suggest for a recommendation on a new item.
4

Memory derives insights

Reviewer profiles, decision patterns, stats, and alerts build up from those judgments over time.
A new workspace starts empty. ask returns an empty answer with confidence: 0 until enough review history exists. Memory returns nothing rather than inventing an answer.

Quickstart

Every endpoint is a POST under https://api.velt.dev/v2/. The examples below read your API key and Auth Token from $VELT_API_KEY and $VELT_AUTH_TOKEN.
1

Add a knowledge source

Base64-encode a file and send it. Ingestion runs in the background and returns a sourceId.
Poll with that sourceId until status is completed or failed:
Files up to 5 MB go inline. For files up to 30 MB, call Get Upload URL, PUT the bytes to the returned uploadUrl, then ingest with { "source": "fileRef", "fileRef": "<gs:// URI>", "mimeType": "..." }.
2

Ask a question

You get a written answer, the records it drew on, and a confidence score.
3

Search past decisions

Use search when you want the underlying records instead of a written answer.
Each result carries the reasoning, decision, confidence, who decided (actionUser), and a similarity score.
4

Get a suggestion

Ask what Memory would recommend for a new item, based on precedent.
primary is the best-grounded recommendation. conflict is filled in when the evidence is split, so you can show that reviewers disagree.

Narrow your results

Add these fields to search and ask to control what Memory reads.

All endpoints

There are two searches, and they read different things. Search Judgments reads past decisions. Search Knowledge Base reads the content of the files you ingested. Pass includeRules: true on the second one to search extracted rules too.

Good to know

  • Judgments are read-only. They come from your users’ review activity, so a new workspace has none until people start reviewing. Comments from older SDK clients are enriched into Memory too, including a one-time backfill of historical data.
  • Ingestion is asynchronous. ingest returns processing. Poll ingest-status until it is completed or failed.
  • Supported file types: PDF, CSV, Excel (.xlsx), and plain text.
  • File limits: 5 MB inline, 30 MB by reference.
  • Duplicate uploads report the original source’s status, so a duplicate can stay processing until the original finishes. completed always means safe to download.
  • Knowledge rate limits, per API key per minute: knowledge/ingest-status 600, knowledge/search 120, knowledge/upload-url 100, knowledge/ingest 30, knowledge/delete 30. Going over returns RESOURCE_EXHAUSTED, so keep bulk imports and status polling under those ceilings.

Errors

On a validation error, every memory endpoint returns details.issues alongside message and status, listing each failing field. The most common INVALID_ARGUMENT causes:
  • filters.annotationId without organizationId.
  • documentId without organizationId on knowledge/ingest or knowledge/upload-url.
  • A dateRange whose start is after its end.
  • An unsupported file type, or an inline file over 5 MB. Use Get Upload URL for larger files.
  • An unrecognized field on knowledge/ingest, knowledge/upload-url, knowledge/ingest-status, knowledge/delete, or knowledge/search. These five reject unknown keys, so a typo like bas64 fails instead of being ignored. knowledge/search is workspace-wide and rejects organizationId and documentId.