Related notes
find_relatedRetrieve semantically similar notes by comparing a source note's chunk embeddings in pgvector, independent of the wikilink graph—useful when a note is sparsely linked or you need thematic neighbors.
Instructions
Semantically similar notes based on the source note's chunk embeddings, averaged then queried via pgvector.
Independent of the link graph — useful when the source is sparsely linked
or when looking for thematic neighbors. For link-based exploration use
get_neighborhood. For arbitrary topic queries use semantic_search.
Carries semantic_search's per-row markers and its header counts:
stale: true means that neighbour changed after it was embedded, so it was
ranked against its previous content and its preview is withheld —
read_note returns the current text. embedding_truncated: true means
only that note's head was embedded, so a match against it says nothing
about its tail.
One marker is about the source rather than a neighbour. If the note you asked about has itself changed since it was embedded, the result says so once, at the top — and it says so on the empty result too. The query vector is the average of the source's stored chunk vectors, so a stale source means every neighbour answers a question about content that note no longer has, and "no related notes" from a stale source means "nothing is near what this note used to say", not "this note has no neighbours". The next embed pass repairs it. A source with no vectors at all is a different message ("has not been embedded yet") with a different fix.
The bound on the staleness signal: it reports what the index has committed, so an edit the indexer has not yet scanned is not marked.
Section locator. A fresh row names the section it matched on its
result line: § "<heading path>" (#N) for a heading's section, or
§ (top of note) for text before the first heading.
read_note(path, section="#N") reads exactly that section. The quoted
path is note text; the (#N) after it is the server's. The locator is
omitted on stale rows and on rows not yet re-embedded since heading-aware
chunking. While any of your notes is not yet re-chunked, the line after
the header reads index_transition: N notes not yet re-chunked; …:
ranking across the two generations is approximate, so re-run once it is
gone. Previews are one line.
Args: path: Vault-relative path to the source note. limit: Maximum results (default 10, hard cap 50).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes | ||
| limit | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |