CBCL / DocumentationDocs v0.3.1

What is CBCL?

Common Business Communication Language (CBCL) lets participants define the rules for a conversation. Each participant can check messages against the same rules.

For example, a buyer sends two purchase requests. A supplier sends the message “I approve.” Which request did the supplier approve? In a CBCL protocol, each approval can have a mandatory reference to its request. It can also specify who can approve a request and how to count the approvals.

On this page

How participants share the rules

A dialect is a definition that extends CBCL for a specified use. A participant can send a dialect definition to a second host. The receiving host can accept or refuse installation. Each host can then check messages locally. How a host adopts a dialect explains this process.

The pieces of a conversation

ConceptIn a lunch pollWhat it tells the host
DialectThe shared definition of a lunch pollWhich verbs, field types, transitions and state rules to install
ActAlice proposes Sushi or PizzaWhat a participant actually communicated
ThreadFriday’s pollWhich instance of the protocol to evaluate
Causal referenceBob’s vote cites Alice’s proposalWhich earlier act makes the vote possible
Authenticated signerBob’s verified identityWhose ballot the vote can change
ProjectionThe tally for FridayWhat can be computed from eligible acts in this instance

A dialect is reusable. The polls for Monday and Friday can use the same definition. Each poll has its own options, participants, and tally.

Where the runtime fits

A sender gives the runtime an intent, such as a request to vote for Pizza. The runtime uses the thread history to make the complete message. The sending host signs the message and sends it.

The receiving host checks the identity of the signer. Its runtime checks the message against the dialect and the available history. If the vote passes admission, the runtime can use it to calculate the tally.

Two receivers can show different tallies while one receiver waits for a message. The receivers can calculate the same tally when they have the same accepted acts, dialect, and evaluation context. The hosts supply message delivery and storage.

Follow an act through the system

  1. Messages and dialects explains how to read the text on the wire.
  2. Threads and causality follows one vote received out of order.
  3. Identity, roles and casts explains how a thread assigns authority.
  4. Admission and derived state follows an accepted vote into the tally.
  5. Evidence of a protocol violation explains how to check two conflicting messages.

Build a receiver in JavaScript or Rust.

For installation instructions and a complete poll, see Quick start.