Skip to content

Wire Format

Hexdump examples for common MFBP operations. All multi-byte values are little-endian.

FieldSizeDescription
Length4 bytesTotal payload size (u32 LE)
OpCode1 byteCommand identifier
PayloadVariableCommand-specific data

Create lineage "fire" with energy 0.9:

Request:

OffsetBytesDescription
0x000B 00 00 00Length: 11
0x0410OpCode: LINEAGE.CREATE
0x0504 00key_len: 4
0x0766 69 72 65key: “fire”
0x0B66 66 66 3Fenergy: 0.9 (f32 LE)

Response:

OffsetBytesDescription
0x0001 00 00 00Length: 1
0x04F0OpCode: OK

Stimulate "fire" with delta 0.5:

Request:

OffsetBytesDescription
0x000B 00 00 00Length: 11
0x0412OpCode: LINEAGE.STIMULATE
0x0504 00key_len: 4
0x0766 69 72 65key: “fire”
0x0B00 00 00 3Fdelta: 0.5 (f32 LE)

Response:

OffsetBytesDescription
0x0001 00 00 00Length: 1
0x04F0OpCode: OK

Create synergy bond from "fire""heat" with strength 0.8:

Request:

OffsetBytesDescription
0x0011 00 00 00Length: 17
0x0420OpCode: BOND.CONNECT
0x0504 00src_len: 4
0x0766 69 72 65src: “fire”
0x0B04 00tgt_len: 4
0x0D68 65 61 74tgt: “heat”
0x11CD CC 4C 3Fstrength: 0.8 (f32 LE)
0x1501polarity: +1 (synergy)

Response:

OffsetBytesDescription
0x0001 00 00 00Length: 1
0x04F0OpCode: OK

Get database statistics:

Request:

OffsetBytesDescription
0x0001 00 00 00Length: 1
0x0441OpCode: SYS.STATS

Response:

OffsetBytesDescription
0x000D 00 00 00Length: 13
0x04F0OpCode: OK
0x0505 00 00 00lineage_count: 5
0x0903 00 00 00bond_count: 3
0x0D66 66 66 3Fmood: 0.9 (f32 LE)

TypeSizeEncoding
u162 bytesLE
u324 bytesLE
u648 bytesLE
f324 bytesIEEE 754 LE
i81 byteSigned