Realm

v0

gno.land/r/moul/x/daily/markovdemo/v0

Render

Markov Babbler

A demo of the p/moul/x/daily/markov library — an on-chain port of Go's classic "Generating arbitrary text: a Markov chain algorithm" codewalk. Every two-word prefix maps to the words that followed it; Generate walks that chain, picking suffixes with a PRNG seeded by the block height — deterministic, yet different each block.

Fresh sample (40 words, height 708954)

it was the worst of times it was the age of foolishness i am a free man i am not a number i am the master of my soul

Corpus

  • Words: 48
  • Distinct prefixes: 33
  • Prefix length: 2 words

Some prefixes → suffixes

prefixcan be followed by
_(start)_it
itwas
a freeman
a numberi
age ofwisdom, foolishness
am afree
am nota
am themaster, captain
best oftimes
captain ofmy
fate iam
foolishness iam

Call Feed("your text here") to teach it new words, then reload for a new sample.

Transactions

No indexed transactions for this realm yet.

Calls, deploys, and child packages in indexed history.

Call function

Source (qfile)