Connection check
local install
brainllm
Persistent graph-structured memory for LLMs in TriliumNext Notes — readable and editable by humans.
Tools
75
GitHub stars
—
Installs / wk
490
Licence
—
Transport
stdio
Last checked
never
Tools & capabilities
75 toolsRead from the published package source — this server runs locally, so there is no endpoint to query. Names are taken from the code, not observed at runtime, and descriptions are often absent.
addendum
from source
add_label
from source
Add a #label to a note (empty value = boolean flag). Adds a new attribute; does not dedupe. Add a #label to a note (empty value = boolean flag). Adds a new attribute; does not dedupe.
add_relation
from source
Add a ~relation with any name (the core connect() enforces the canonical vocabulary). Add a ~relation with any name (the core connect() enforces the canonical vocabulary).
assembly
from source
What the brain HOLDS \u2014 every note by title, grouped under the surface it lives in, with each surface What the brain HOLDS \u2014 every note by title, grouped under the surface it lives in, with each surface
attach
from source
Attach a raw artifact (file, image, code blob, document) to a note \u2014 or read one back. Dual-mode by the content param: content provided \u2192 UPSERT by title: creates the a… Attach a raw artifact (file, image, code blob, document) to a note \u2014 or read one back. Dual-mode by the content param: content provided \u2192 UPSERT by title: creates the attachment, or replaces the existing same-titled attachment
backup
from source
Trigger a BrainLLM database backup. Writes a named snapshot to Trilium Trigger a BrainLLM database backup. Writes a named snapshot to Trilium
bootstrap
from source
brain
from source
claim
from source
Register a checkable assertion, and record whether it still holds. consistency() asks whether the brain agrees with ITSELF. Nothing asked whether a specific assertion is still tru… Register a checkable assertion, and record whether it still holds. consistency() asks whether the brain agrees with ITSELF. Nothing asked whether a specific assertion is still true of the codebase, config or live surface it describes \u2014 so a claim that quietly stopped being true stayed authoritative until something downstream broke, and
clone_note
from source
Place a note under an additional parent (multi-parent branch; shared content, no copy). Place a note under an additional parent (multi-parent branch; shared content, no copy).
close
from source
Commit the session log \u2014 call ONCE, last, after completing the session() pre-close protocol. Enforced, not just documented: refuses (returns an informational error, doesn Commit the session log \u2014 call ONCE, last, after completing the session() pre-close protocol. Enforced, not just documented: refuses (returns an informational error, doesn
connect
from source
Wire a typed relation between two notes when you notice a real connection. Vocabulary (closed): ${RelationTypes.join( Wire a typed relation between two notes when you notice a real connection. Vocabulary (closed): ${RelationTypes.join(
consistency
from source
Cross-note agreement check: take a pattern, find every note that asserts a value for it, and report whether they agree. The brain Cross-note agreement check: take a pattern, find every note that asserts a value for it, and report whether they agree. The brain
create_attachment
from source
Attach a file or text blob to a note (role: file | image). Attach a file or text blob to a note (role: file | image).
create_backup
from source
Trigger a named Trilium database backup. The backup file is written to Trilium Trigger a named Trilium database backup. The backup file is written to Trilium
create_note
from source
Create a note at an explicit parent. Types: text/code/book/canvas/mermaid/relationMap/render/search/file/image. Create a note at an explicit parent. Types: text/code/book/canvas/mermaid/relationMap/render/search/file/image.
create_revision
from source
Snapshot a note Snapshot a note
day
from source
The new-day sweep payload \u2014 one call replacing the manual multi-read protocol on the first session of a day. Serves: whether today is genuinely fresh (no addendum blocks in to… The new-day sweep payload \u2014 one call replacing the manual multi-read protocol on the first session of a day. Serves: whether today is genuinely fresh (no addendum blocks in today
delete_attachment
from source
Permanently delete an attachment. Irreversible. Permanently delete an attachment. Irreversible.
delete_attribute
from source
Delete any label or relation by attributeId. Delete any label or relation by attributeId.
delete_branch
from source
Remove one placement of a note (deletes the note if it was the last branch). Remove one placement of a note (deletes the note if it was the last branch).
delete_note
from source
Hard-delete a note (and its subtree if this is its last branch). Irreversible. Hard-delete a note (and its subtree if this is its last branch). Irreversible.
detach
from source
Remove an attachment from a note \u2014 by attachmentId directly, or by (noteId + title). Permanent: attachments have no archive tier; re-attach() from source to undo. Retry-safe \… Remove an attachment from a note \u2014 by attachmentId directly, or by (noteId + title). Permanent: attachments have no archive tier; re-attach() from source to undo. Retry-safe \u2014 an already-removed target returns cleanly instead of erroring.
diary
from source
Write to today Write to today
diff
from source
domain
from source
Surface the brain Surface the brain
explore
from source
Walk the relation graph around a note. mode=links what this note points to (one hop) mode=backlinks what points to this note (one hop) mode=neighborhood everythi… Walk the relation graph around a note. mode=links what this note points to (one hop) mode=backlinks what points to this note (one hop) mode=neighborhood everything within N hops, both directions (depth, optional relation filter); via is prefixed \u2190 for edges walked inbound mode=path shortest connection between noteId and toNoteId
forget
from source
Archive a note (default) or hard-delete it (hard=true). Archiving keeps it in place, hidden from default recall \u2014 the safe choice and the only one for anything with history. H… Archive a note (default) or hard-delete it (hard=true). Archiving keeps it in place, hidden from default recall \u2014 the safe choice and the only one for anything with history. Hard delete is refused while other notes still link here (backlinks are returned so you can re-wire with connect() first). To undo an archive, use recover().
get_app_info
from source
Trilium server version, DB version, runtime metadata. Trilium server version, DB version, runtime metadata.
get_attachment_content
from source
Read the content of a text/code attachment. Read the content of a text/code attachment.
get_attachments
from source
List attachments on a note (id + title + mime + size). List attachments on a note (id + title + mime + size).
get_attribute
from source
Fetch a single attribute by id. Fetch a single attribute by id.
get_branch
from source
Fetch a branch (a note Fetch a branch (a note
get_day_note
from source
Get (or auto-create) the journal day note. Format: YYYY-MM-DD (default: today). Get (or auto-create) the journal day note. Format: YYYY-MM-DD (default: today).
get_inbox_note
from source
Get the Trilium inbox note for a date (fixed #inbox note, or the day note). Format: YYYY-MM-DD. Get the Trilium inbox note for a date (fixed #inbox note, or the day note). Format: YYYY-MM-DD.
get_month_note
from source
Get (or auto-create) the journal month note. Format: YYYY-MM. Get (or auto-create) the journal month note. Format: YYYY-MM.
get_note
from source
Full note metadata: title, type, mime, attributes (labels + relations), parent/child ids, dates. Full note metadata: title, type, mime, attributes (labels + relations), parent/child ids, dates.
get_note_content
from source
Raw note content (HTML / text / code). Raw note content (HTML / text / code).
get_revision_content
from source
Content of a historical revision snapshot. Content of a historical revision snapshot.
get_revisions
from source
List a note List a note
get_week_note
from source
Get (or auto-create) the journal week note. Format: YYYY-Www. Get (or auto-create) the journal week note. Format: YYYY-Www.
get_year_note
from source
Get (or auto-create) the journal year note. Format: YYYY. Get (or auto-create) the journal year note. Format: YYYY.
graph
from source
The graph view \u2014 render the brain The graph view \u2014 render the brain
insights
from source
Read the BrainLLM Read the BrainLLM
insights_recall
from source
Skim recent change logs (days + previews). Skim recent change logs (days + previews).
inspect
from source
Read everything BrainLLM Read everything BrainLLM
knowledge
from source
Read a Knowledge note by id \u2014 a user-knowledge note, a domain information note, or a Sources note. Pass section= Read a Knowledge note by id \u2014 a user-knowledge note, a domain information note, or a Sources note. Pass section=
knowledge_recall
from source
Skim Knowledge. With a domain: that domain Skim Knowledge. With a domain: that domain
label
from source
Set or remove a single label on a note \u2014 the guarded, BrainLLM-native path for direct label surgery (fixing a stray value, correcting drift) so a real edge case doesn Set or remove a single label on a note \u2014 the guarded, BrainLLM-native path for direct label surgery (fixing a stray value, correcting drift) so a real edge case doesn
llm
from source
Read an LLM note: responsibilities, protocols or selfcorrection (singletons), or a diary entry by id. selfcorrection holds the assistant Read an LLM note: responsibilities, protocols or selfcorrection (singletons), or a diary entry by id. selfcorrection holds the assistant
llm_recall
from source
Skim the LLM surface: responsibilities, protocols & self-correction opening lines (with relation snippets), plus recent diary entries. Skim the LLM surface: responsibilities, protocols & self-correction opening lines (with relation snippets), plus recent diary entries.
maintain
from source
master
from source
Read a Master singleton: biography, goals, or preferences. Returns its id, content, and relation snippet. section= Read a Master singleton: biography, goals, or preferences. Returns its id, content, and relation snippet. section=
master_recall
from source
Skim all three Master singletons \u2014 the opening lines of biography, goals, and preferences (with ids and relation snippets). Skim all three Master singletons \u2014 the opening lines of biography, goals, and preferences (with ids and relation snippets).
memory
from source
memory_recall
from source
Skim Memory: active threads and recent sessions (ids + previews). An optional query filters threads by title. Skim Memory: active threads and recent sessions (ids + previews). An optional query filters threads by title.
move_note
from source
Move a note to a new parent (clone to the new parent, then remove the old branch). Move a note to a new parent (clone to the new parent, then remove the old branch).
note_history
from source
Recent changes feed (creations / modifications / deletions), newest first. Recent changes feed (creations / modifications / deletions), newest first.
outline
from source
The heading tree of a note \u2014 every h2/h4 section with its level, its occurrence index among same-text siblings, and a structural check \u2014 without reading the body. Read t… The heading tree of a note \u2014 every h2/h4 section with its level, its occurrence index among same-text siblings, and a structural check \u2014 without reading the body. Read this BEFORE a section= revise on a note you haven
patch_note
from source
Mutate note metadata: title, type, or mime. Mutate note metadata: title, type, or mime.
recall
from source
Search memory before answering questions about the user, their threads, knowledge, or anything previously discussed. Runs label, title and full-text strategies server-side and retu… Search memory before answering questions about the user, their threads, knowledge, or anything previously discussed. Runs label, title and full-text strategies server-side and returns merged, ranked results with kind/status. Archived notes are excluded unless includeArchived=true. orderBy / orderDirection override the score-based sort when you need temporal ordering (
recover
from source
Restore an archived or resolved note: removes #archived, clears #closed, resets status to active. Use to undo forget() or reconsider a resolved thread / note. Does not restore note… Restore an archived or resolved note: removes #archived, clears #closed, resets status to active. Use to undo forget() or reconsider a resolved thread / note. Does not restore note content \u2014 use revise() to fix content, or get_revisions (full mode) to roll back to a prior snapshot. For notes deleted from Trilium entirely (not just archived), use undelete_note (full mode) instead.
remarks
from source
Diary cues \u2014 call before diary() as part of the session() pre-close protocol (close() enforces the order session \u2192 remarks \u2192 diary). Returns two cue banks that promp… Diary cues \u2014 call before diary() as part of the session() pre-close protocol (close() enforces the order session \u2192 remarks \u2192 diary). Returns two cue banks that prompt the day
remember
from source
resolve
from source
Complete a thread (or any resolvable note): write a substantive outcome, set the terminal status, and archive it in place (it stays where it is, excluded from default recall). Complete a thread (or any resolvable note): write a substantive outcome, set the terminal status, and archive it in place (it stays where it is, excluded from default recall).
revise
from source
Update an existing note by id. Append a dated addendum (default), replace the body (mode=replace), edit a heading section in place (section=), insert around a heading (section= wit… Update an existing note by id. Append a dated addendum (default), replace the body (mode=replace), edit a heading section in place (section=), insert around a heading (section= with mode=
search_notes
from source
Raw Trilium query search. Native query language: #label=value, note.title =* Raw Trilium query search. Native query language: #label=value, note.title =*
session
from source
Mandatory pre-close step \u2014 call BEFORE close() to end a session. Fetches the master and LLM singletons as {id, lastModified, relations} stubs (LIGHT \u2014 the default), today Mandatory pre-close step \u2014 call BEFORE close() to end a session. Fetches the master and LLM singletons as {id, lastModified, relations} stubs (LIGHT \u2014 the default), today
start
from source
template
from source
undelete_note
from source
Recover a recently Trilium-deleted note from Trilium Recover a recently Trilium-deleted note from Trilium
update_attachment
from source
Update an attachment Update an attachment
update_attribute
from source
Update an attribute Update an attribute
update_note_content
from source
Replace a note Replace a note
withdraw
from source