Skip to content

feat(inference): call what a brain does by its functions - #84

Merged
rami-hatoum merged 5 commits into
mainfrom
feat/brain-functions-vocabulary
Oct 4, 2026
Merged

rami-hatoum merged 5 commits into
mainfrom
feat/brain-functions-vocabulary

Conversation

@rami-hatoum

Copy link
Copy Markdown
Contributor

Follows #83.

What this changes

The words a user reads, nothing else: no tool, argument, route, package or type is renamed.

A brain can reason, interact, compute, recall and predict. It coordinates those functions through workflows. Those are the words in every sentence the server gives an assistant to pass on and in the README; the primitives keep their technical names (inference, orchestration and the rest) in the architecture, the code and the API, and each primitive's description says how the two relate, once:

A spec of the inference primitive is a reason function: it reasons with a language model, following a prompt, to turn an input into an answer. In conversation, call it a reason function; the primitive's name, inference, is what the tools take.

  • "Reason function" replaces "prompt" as the name of the thing in results and errors. "Prompt" is kept only for what configures a reason function. "Workflow" and "run" are unchanged.
    • Created the reason function "summary". What it does: Summarizes a text. It has been saved but has not been run yet.
    • Ran the reason function "summary". Its answer: "Profits rose."
    • Could not run the reason function "summary": this server is not set up to use the provider of the model named, but it can use others. Nothing was changed. This can be put right on your side: once its prompt names a model from one of those, which the details below list, it can be tried again.
  • The README describes a brain by what it can do. "How a brain works" opens with the sentence above, then a table with a row per brain function: what you define, how it runs (the primitive), built or planned; then the example of a budget-review workflow that recalls, computes, predicts, reasons and interacts. The quick start, the MCP section and the api and inference READMEs use the same words.
  • CLAUDE.md gives builders the mapping, so user-facing text uses the brain-function words and code keeps the primitive names.

Verification

  • pnpm check passes: 2,274 tests across ten packages, 100% coverage on every file, nothing excluded.
  • The leak check over every tool's first block passes with the new nouns.

🤖 Generated with Claude Code

rami-hatoum and others added 5 commits October 4, 2026 16:58
The remedy for a model the server is not set up for said "once it
names a model from one of those". With a spec of inference now called a
reason function, "it" would be the reason function, but it is the
prompt that configures it which names the model. The remedy now reads
"once its prompt names a model from one of those, which the details
below list, it can be tried again."

The phrasing and explanation tests use reason function as their sample
noun instead of prompt.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The plain words of every result called a spec of inference a prompt. A
prompt is what configures it; the thing a person defines is a reason
function. The noun of inference is now reason function, so results
read "Created the reason function “summary”.", "Ran the reason function
“summary”." and "This brain has 1 reason function: “summary”.".

The description of inference, which the spec tools carry, now opens:
a spec of the inference primitive is a reason function that reasons
with a language model, following a prompt, to turn an input into an
answer; in conversation, call it a reason function, while the tools
take the name inference. The rest of the description is unchanged.

Tests that called the thing a prompt now say reason function: the
server's plain words, the quick start and the leak check's sample. The
spec operations' tests of an unknown primitive name it reason, the word
a person might now try, instead of prompt.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The description of orchestration, which the spec tools carry, now opens
with the words a person uses: a spec of the orchestration primitive is a
workflow that coordinates the brain's other functions, running them in
order, deciding what happens next and waiting for input; in
conversation, call it a workflow, while the tools take the name
orchestration. The rest of the description is unchanged.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
How a brain works now leads with what a brain can do: reason, interact,
compute, recall and predict, coordinating those functions through
workflows. Its table has a row per brain function, with what a person
defines for it, the primitive that runs it, linked to its package, and
whether it is built, in place of the table of primitives and its column
What you make with it. A budget-review workflow shows the functions
together. The ledger paragraph and the diagram stay.

The quick start, the MCP section, the api README and the opening of the
inference README call a spec of inference a reason function, and use
prompt only for what configures it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
CLAUDE.md now says, under What this is, which word a user reads for each
primitive: a brain can reason (inference, whose specs are reason
functions, each configured by a prompt), interact, compute, recall and
predict, and coordinates them through workflows (orchestration); a
primitive is a brain function and an execution a run, while code, the
API and the architecture keep the primitive names.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@rami-hatoum
rami-hatoum added this pull request to the merge queue Oct 4, 2026
Merged via the queue into main with commit 7eaf4dc Oct 4, 2026
10 checks passed
@rami-hatoum
rami-hatoum deleted the feat/brain-functions-vocabulary branch October 4, 2026 18:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant