What is f1r3lang?
The concurrent language for verifiable concurrent computing.
You already know the door in: SELECT, FROM, WHERE — the query shape every developer has written for fifty years. f1r3lang builds the whole language around it and adds the missing word: DO. The query acts. Built on the rho‑calculus, every program is processes passing messages on channels — parallel by default, deterministic in consensus, and every transaction leaves its receipt in the program itself.
Heir to Rholang · proven on RChain · built by F1R3FLY
select-from-where-do.rhof1r3lang
-- the query you already write:
-- SELECT spec FROM prey WHERE chi(spec)
// the same query in f1r3lang — with a DO
for( @spec <- prey where Chi(spec) ) {
Break!(spec)
}
Why f1r3lang
The door you already know
SELECT‑FROM‑WHERE has been reinvented every decade for fifty years — SQL, LINQ, XQuery, comprehensions. f1r3lang builds the language around that shape and adds DO: the query is not a request for a value someone else acts on. It is how anything happens at all.
Transactions leave receipts
When a reader meets a writer on a channel, the meeting itself is recorded in the program text. Atomicity needs no engine underneath, multi-party commit is the & operator, and a failed condition consumes nothing — there is no rollback because nothing began.
Concurrent and unforgeable
The | operator runs processes in parallel by default, and names made with new are cryptographically unforgeable — capability security as grammar. Thousands of concurrent transactions, identical final state on every node.
One text, three readings
Let a condition answer with a value instead of yes or no, and the same program becomes three artefacts: code committing transactions, a stochastic simulation of a population of itself, and — measured, not promised — a learning rule. The research →
The name
The two glyphs in the middle of f1r3|@ng are not decoration. | is parallel composition — the operator that runs processes concurrently. @ is quotation — the operator that turns a process into a name. They are the two operators everything else in the language is assembled from. The name spells the calculus.
The headline act
No other chain language ships AI as a built-in. In f1r3lang, a contract can query a model mid-execution, hand the result to the next process, and leave a verifiable record of the whole exchange on chain.
AI channels are non-deterministic by nature, so the runtime caches responses at execution and replays them during consensus — agents that act on chain without breaking the chain's agreement about what happened.
And calling models is only the surface. Grade a where clause and the clause itself becomes a learning rule — gradient descent falls out of the language, no framework imported. See the research.
On-chain agents, off-chain models, one verifiable transcript.
ask-the-model.rhof1r3lang
new gpt4(`rho:ai:gpt4`) in {
new ret in {
gpt4!("Explain quantum computing
in one sentence", *ret) |
for (@response <- ret) {
stdout!(response)
}
}
}
// also built in:
// rho:ai:dalle3, rho:ai:textToAudio
// rho:ollama:chat — local models,
// no API key leaves your node
Lineage
f1r3lang is the heir to Rholang — the concurrent smart contract language that ran RChain's mainnet. It inherits the core of its control flow from rholang, and the debt is named where it is owed: in f1r3lang's own module system, rholang appears as one theory among others, written out in the same declarations a developer would use for an invoice format. The calculus underneath is not privileged. That is the point.
But the inheritance is not an equivalence. f1r3lang was carried through the research notes as "rholang 1.4" before earning its own name, and what it adds — a data definition sublanguage with a real module system, and conditions that can answer with a value instead of a verdict — changes what a program can mean. A pure-Rust engine, an active research program published as working notes with runnable code, and a language that goes where rholang does not reach.
Ten minutes to hello world
One Docker command starts a node. The REPL takes it from there.