# Find notes by meaning, not exact words: `{query, results: [{path, score, heading, snippet,

`POST /datanotes/operations/semantic_search/` (operation `semantic_search`)

Find notes by meaning, not exact words: `{query, results: [{path, score, heading, snippet,
table?}]}`, one result per note (its best passage), best first. Use it for vague questions
("the dinner where we talked about moving", "what did I decide about the car") and to find the
rows to read or update; then read_note / select_rows for the details. Filters: `tables`
(qualified or short names), `folder`, `min_score` (cosine 0–1; ~0.5+ is usually relevant).
`limit`: default 10, max 100. Fails with a clear message when semantic search is not enabled in
the engine settings.

## Request body

`application/json`, required

| Property | Type | Required | Default | Description |
| --- | --- | --- | --- | --- |
| `query` | `string` | yes |  |  |
| `limit` | `integer` | no | `10` |  |
| `tables` | `string[] \| null` | no | `null` |  |
| `folder` | `string \| null` | no | `null` |  |
| `min_score` | `number \| null` | no | `null` |  |

## Responses

| Status | Description | Body |
| --- | --- | --- |
| 200 | Done. | `object` (application/json) |
| 400 | Bad input: the body is not a JSON object, or an argument is unknown, missing or of the wrong type. | `Error` (application/json) |
| 401 | Missing or wrong bearer token. | `Error` (application/json) |
| 500 | Unexpected error. | `Error` (application/json) |

The schemas named here are in [openapi.json](https://datanotes.dev/openapi.json) (`components.schemas`).
