/p/moul/addrset/v0
provides a specialized set data structure for managing unique Gno addresses. It is built on top of an AVL tree for efficient operations and maintains addresses in sorted order.
provides a specialized set data structure for managing unique Gno addresses. It is built on top of an AVL tree for efficient operations and maintains addresses in sorted order.
provides a set of blockchain addresses, backed by a B+ tree.
provides small, deterministic commitment helpers shared by the agent demos.
wire format for messages passed between agents through a relay realm. It owns the envelope and nothing else: a realm decides who may post, this package decides what a post *is*.
primitive layer for ASCII, ANSI and pixel art in a realm.
provides flexible authorization control for privileged actions.
provides flexible authorization control for privileged actions.
provides a generic collection implementation with support for multiple indexes, including unique indexes and case-insensitive indexes.
provides a Copy-on-Write (CoW) AVL tree implementation. This is a fork of gno.land/p/nt/avl that adds CoW functionality while maintaining the original AVL tree interface and properties.
provides utilities for logging and displaying debug information within Gno realms. It supports conditional rendering of logs and metadata, toggleable via query parameters.
provides a doubly-linked deque with optional size limits, optimized for minimal storage updates and O(1) operations in Gno environments.
provides a simple template engine for handling dynamic content replacement. It is similar to strings.Replacer but with lazy execution of replacements, making it more optimization-friendly in several cases.
provides an interface that abstracts a notion of entity which can under the hood be an EOA (address), a package realm (PkgPath, address).
Entropy generates fully deterministic, cost-effective, and hard to guess numbers. It is designed both for single-usage, like seeding math/rand or for being reused which increases the entropy and its cost effectiveness.
provides utilities for combining multiple errors.
implements a fixed-size FIFO (First-In-First-Out) list data structure using a singly-linked list.
domain engine of an on-chain software forge: repos, roles, an append-only reference log, issues and change requests (pull requests), with no chain imports of its own.
domain engine of an on-chain software forge: repos, roles, an append-only reference log, issues and change requests (pull requests), with no chain imports of its own.
domain engine of an on-chain software forge: repos, roles, an append-only reference log, issues and change requests (pull requests), with no chain imports of its own.
provides functional programming utilities for Gno, enabling transformations, filtering, and other operations on slices of any. Example of chaining operations:
domain model of a source registry for gno packages: a map from a deployed package path back to the repository, commit and directory that produced it. It exists because gno deliberately broke the link Go gets for free.
grant board governed by a member set: anyone may ask the board for money, the members vote in the open, and the money leaves in tranches that each have to be earned by producing a proof the members accept.
tiny pure package used as a canary: it proves that versioned cross-package resolution (gno.land/p/moul/greet/v0) works in the workspace and in CI. Replace or remove it once real packages land.
provides utilities for creating help page links compatible with Gnoweb, Gnobro, and other clients that support the Gno contracts' flavored Markdown format.
secondary index every realm with a store was writing by hand: a lookup from a key a human typed to the [store.ID]s that carry it. A realm keeps its records in a gno.land/p/moul/kit/store and answers "entry 7".
formats numbers for a human to read: fixed-point amounts, percentages and zero padding. Thousands separators are NOT here.
auto-id ordered collection every r/moul realm was building by hand: an avl.Tree, an int counter, and a private function that zero-pads the counter into a key so the tree iterates in the order a human expects.
orders a scoreboard: highest score first, ties broken by key.
shared display vocabulary for r/moul realms: the small set of rendering decisions that every realm was making on its own, made once. It deliberately does NOT re-export markdown primitives.
provides helper functions for generating Markdown content programmatically. It includes utilities for text formatting, creating lists, blockquotes, code blocks, links, images, and more.
proof-of-concept for composable UIs patterns. It allows specifying a data source and then dynamically rendering it as a list or a grid.
provides a simple way to create Markdown tables. Example usage:
provides a simple memoization utility to cache function results. The package offers a Memoizer type that can cache function results based on keys, with optional validation of cached values.
builds links into a mygnoscan block explorer. A realm knows things a reader cannot see from its Render output: which chain it is on, what its address is, which block it was last written at.
provides helpers for package-path based access control. It is useful for upgrade patterns relying on namespaces.
provides utilities for one-time execution patterns. It extends the concept of sync.Once with error handling and panic options.
proposes an abstraction around the ownership which provides various kind of owners and some composition options.
implements a flexible pagination system that can be used with any data structure that implements the Pageable interface. It provides functionality for:
switch a realm checks before it acts: a parsed pause state, the rule for combining two of them, and the asserts that stop a call.
realm-driven account: one realm holds the funds and the identity, a key pilots it, and its powers are separate realms installed afterwards without ever redeploying it. The gno answer to a Gnosis Safe with modules.
this package is a joke... or not.
engine behind an embeddable reaction block: the one-click "👍 3 · 🔥 1" strip a realm drops into its own Render, keyed on the PAGE it is showing rather than on the realm that stores it.
lightweight Render.path parsing and link generation library with an idiomatic API, closely resembling that of net/url.
inspired by Gnosis Safe
minimalist and extensible SVG generation library for Gno.
directory model behind r/moul/toolbox(/r/moul/toolbox): a list of small gno.land utilities, each one a realm of its own, rendered as a single index.
provides utility functions for converting between different types and checking their states. It aims to provide consistent behavior across different types while remaining lightweight and dependency-free.
defines minimal interfaces for Decentralized Autonomous Organizations (DAOs). It intentionally does not expose members and votes, as these details are implementation-specific.
provides a layered proxy implementation for lists that allows transparent migration of data between different schema versions.
provides an append-only list implementation using a binary tree structure, optimized for scenarios requiring sequential inserts with auto-incrementing indices.
provides an append-only list implementation using a binary tree structure, optimized for scenarios requiring sequential inserts with auto-incrementing indices.
preview of gno.land/p/nt/ufmt/v2, published here before that path exists. This is v2 of ufmt. It is not yet published at its expected path, gno.land/p/nt/ufmt/v2.
computes a gno.land account's vesting curve, as a PURE calculator: no state, no balances, no transfers. It is not a vesting scheme of its own.
Pacakge web25 provides an opinionated way to register an external web2 frontend to provide a "better" web2.5 experience.
implements Aho-Corasick multi-pattern search as a pure, reusable package.
ports the core of Bitcoin's Base58 codec (à la mr-tron/base58 and btcutil/base58) to gno — as a reusable pure package.
implements RFC 4648 base32 and Crockford base32 as a pure, reusable package. Two alphabets, for two different jobs:
implements the Bech32 and Bech32m string formats of BIP-173 and BIP-350 as a pure, reusable package.
finds the cheapest route from one node to every other node of a weighted directed graph whose arcs may cost LESS than nothing, as a pure, reusable package.
implements bencoding, the serialization format BitTorrent uses for .torrent files and tracker responses, as a pure reusable package.
bidirectional map — unique in both directions — as a pure, reusable package. A normal map answers "what is the value for this key". A bidirectional one also answers the reverse in O(1), by keeping a second index.
dense, fixed-capacity bit vector as a pure, reusable package: a compact set of small non-negative integers with the usual set algebra (union, intersection, difference).
computes cliff-then-linear vesting schedules as a PURE calculator — no state, no balances, no transfers.
computes cliff-then-linear vesting schedules as a PURE calculator: no state, no balances, no transfers.
implements the commit-then-reveal scheme as a pure, reusable package.
estimates element frequencies in sublinear space, as a pure, reusable package. An exact frequency map costs one entry per distinct element, which on chain means unbounded storage driven by whatever users feed it.
on-chain Gno port of the classic `cowsay` program: it builds an ASCII cow with a speech bubble containing a message — as a reusable pure package.
on-chain Gno port of the classic `cowsay` program: it builds an ASCII cow with a speech bubble containing a message — as a reusable pure package.
implements the CRC-32 checksum as a pure, reusable package. CRC-32 treats a message as one enormous binary number and takes the remainder of dividing it by a fixed polynomial.
parses the classic five-field cron expression and answers the only question a schedule exists to answer: when does it next fire.
finds the cheapest route from one node to every other node of a weighted directed graph, as a pure, reusable package.
union-find (a disjoint-set forest) as a pure, reusable package: it tracks a partition of [0, n) into disjoint groups and answers "are these two in the same group?" in near-constant time.
Binary Indexed Tree (Peter Fenwick, 1994): an array of int64 that answers a prefix sum and applies a point update in O(log n), with no extra storage beyond the array itself.
sorted-vector map — the STL flat_map / Abseil btree_map trade — as a pure, reusable package. Keys and values live in two parallel sorted slices instead of a hash table or a tree of nodes.
exact rational arithmetic as a pure, reusable package: values are p/q with int64 numerator and denominator, always kept in lowest terms with a positive denominator.
encodes a latitude/longitude pair into the short base32 string known as a geohash, decodes one back into the cell it names, and walks from a cell to the eight around it.
matches shell-style patterns against strings, in two modes: plain, where `*` crosses everything, and path, where `/` is a boundary that only `**` crosses. The reason to have it on chain is the allowlist.
binary min-heap / priority queue over string items with integer priorities, as a pure, reusable package.
renders bytes in the classic xxd/hexdump -C layout, as a pure, reusable package.
compresses a string with canonical Huffman codes: the classic frequency-based prefix code, in the one form that is safe to put on a chain. Two properties matter here and neither is about compression. The codes are CANONICAL.
formats numbers for people rather than machines, as a pure, reusable package: byte sizes, thousands separators, ordinals, pluralisation and block-height "durations". Everything is integer-only.
formats numbers for people rather than machines, as a pure, reusable package: byte sizes, thousands separators, ordinals, pluralisation and block-height "durations". Everything is integer-only.
implements Knuth–Morris–Pratt substring search as a pure, reusable package. The naive scan re-compares characters it has already matched, so a hostile input like "aaaaaaab" in "aaaaaaaaaaaaaaab" costs O(n*m).
ports the classic Levenshtein edit-distance algorithm (as found in Go libraries like agext/levenshtein) to gno — as a reusable pure package.
implements the Luhn mod-10 checksum (Hans Peter Luhn, 1954) as a pure, reusable package: the check used by credit-card numbers, IMEIs and many national ID schemes to catch typos and single-digit transpositions.
deterministic Markov-chain text generator — a port of Go's canonical example "Generating arbitrary text: a Markov chain algorithm" (https://go.dev/doc/codewalk/markov/) with math/rand replaced by a caller-supplied seed.
bag / frequency counter — a set that allows duplicates and remembers how many — as a pure, reusable package.
implements MurmurHash3 x86_32, Austin Appleby's non-cryptographic hash, as a pure, reusable package. The function reads the input four bytes at a time.
computes the shortest edit script between two sequences of lines, using Myers' greedy algorithm: the same one git, diff and every review tool run to turn two documents into a list of additions and deletions.
map that remembers the order its keys were inserted, as a pure, reusable package. This matters more on chain than off it.
ports the classic "Pig Latin" translator — a staple Go beginner exercise — to gno.land as a reusable pure package. Rules implemented (the standard English game):
escrow ledger behind the pull-payment pattern, as a pure, reusable package. The pattern is the classic Solidity answer to reentrancy: never push value to an address, credit it and let the recipient withdraw.
escrow ledger behind the pull-payment pattern, as a pure, reusable package. The pattern is the classic Solidity answer to reentrancy: never push value to an address, credit it and let the recipient withdraw.
deterministic token-bucket rate limiter — a port of golang.org/x/time/rate with the wall clock replaced by a caller-supplied monotonic tick (on-chain, that tick is the block height).
deterministic token-bucket rate limiter — a port of golang.org/x/time/rate with the wall clock replaced by a caller-supplied monotonic tick (on-chain, that tick is the block height).
fixed-capacity FIFO that overwrites its oldest entry when full, as a pure, reusable package.
implements run-length encoding as a pure, reusable package: runs of a repeated byte collapse to a count and the byte. The encoding is `<count><char>` with counts in decimal, e.g. "aaabbc" → "3a2b1c".
pure port of the classic Roman-numeral converter kata: ToRoman / FromRoman, valid for 1..3999. Deterministic — no time, randomness or I/O — and free of any realm coupling, so it is reusable as a library.
ports Go's classic ROT13 example — the one used to teach strings.Map and io.Reader in the standard library docs — to gno as a reusable pure package.
rock-paper-scissors move: parsing it, naming it, and deciding a throw. It holds no state, so every realm that plays the game agrees on what "r" means and who wins.
on-chain port of the core of golang.org/x/mod/semver (and the spirit of github.com/Masterminds/semver): parse "vMAJOR.MINOR.PATCH [-prerelease][+build]" strings and compare them with correct Semantic Versioning 2.0.0…
implements SHA-1 (FIPS 180-1, RFC 3174) as a pure, reusable package: one-shot, streaming, HMAC-SHA1, and git object ids.
turns an infix arithmetic expression into reverse Polish notation and evaluates it over int64, with Dijkstra's shunting-yard algorithm (1961).
on-chain port of Go's classic concurrent prime sieve (the "prime sieve" example from the Go tour / Go source docs), implemented as a deterministic, allocation-friendly Sieve of Eratosthenes so it runs reproducibly…
implements the Soundex phonetic algorithm as a pure, reusable package: names that sound alike in English encode to the same four-character key, so "Robert" and "Rupert" both give R163.
renders a numeric series as one line of Unicode block characters — ▁▂▃▄▅▆▇█ — so a realm's Render can show a trend inline, with no image, no chart library and no client-side code. Everything is integer math, deliberately.
orders a dependency graph so that every node comes after everything it depends on — the "install these packages in a safe order" problem — as a pure, reusable package.
orders a dependency graph so that every node comes after everything it depends on — the "install these packages in a safe order" problem — as a pure, reusable package.
prefix tree (trie) for autocomplete, as a pure, reusable package: insert words, then ask for every word sharing a prefix.
implements LEB128 / protobuf-style variable-length integers over strings, with one deliberate restriction: it only accepts the canonical encoding of a value.
reads and forwards the coins a transaction attached to a call: the `-send` field of a `MsgCall`, credited to the called realm's address before a line of its code runs.
probes, at runtime, which realm frame pure-package code executes in when a realm forwards its own `cur` into it.
stock that fills at a rate while nobody is playing: the resource field of an idle game, the warehouse of a 4X, anything whose state is a function of how long it has been left alone. The shape is always the same.
deadline that actions push forward, with the two guards a naive "extend on every action" clock lacks. Any last-action-wins game has the same clock: every action buys more time, so the game ends only when nobody acts.
splits an integer amount across weighted claimants without leaking or inventing a unit. Every payout in a game is this operation: a pot, a roster, and a weight each.
builds derived GRC20 tokens on top of existing ones. Two shapes:
builds and verifies Merkle inclusion proofs on gno.land. It wraps the `crypto/merkle` stdlib, which is native (implemented in Go, gas-metered) and shipped with the chain, and which had no callers anywhere before this package.
implements a Merkle Mountain Range: an append-only log with a root that updates in O(log n) and inclusion proofs of O(log n) size.
whole behaviour of one constant-product AMM pair, as a pure package, so that a realm holding a single pair can be twenty lines of glue.
RAM file server: Plan 9's ramfs, in a realm's heap. It is the reference implementation of gno.land/p/moul/x/plan9/ninep's File and Mutable, and the tree a namespace server hands out as a user's private root.
RAM file server: Plan 9's ramfs, in a realm's heap. It is the reference implementation of gno.land/p/moul/x/plan9/ninep's File and Mutable, and the tree a namespace server hands out as a user's private root.
Plan 9 shaped file abstraction for gno. It implements the SEMANTICS of 9P2000, not its wire format: there is no socket on a chain, the VM call is the transport.
Plan 9 namespace: a private, mutable mount table over gno.land/p/moul/x/plan9/ninep file trees. This is the idea the rest of the suite exists for.
Plan 9 namespace: a private, mutable mount table over gno.land/p/moul/x/plan9/ninep file trees. This is the idea the rest of the suite exists for.
small shell over a Plan 9 namespace. It exists because a namespace you cannot inspect is a namespace you cannot trust.
small shell over a Plan 9 namespace. It exists because a namespace you cannot inspect is a namespace you cannot trust.
builds a synthetic, read-only ninep file server whose contents are computed by a function at read time. This is the package that makes the rest of the suite adoptable.
GRC20 that cannot exist until its author has answered the three questions a social app's token usually dodges: what mints it, what burns it, and who has a reason to buy it.
small-group coordination as a product rather than as a framework: three to fifteen people with a shared pot, a way to decide, and a way to leave with their share.
engine behind a curated list where being on the list costs something: anyone may list an entry by locking a deposit, anyone may challenge an entry by matching that deposit with a bond, and the loser of the challenge…
engine behind recurring support for a builder: a plan somebody subscribes to, period after period, paid in ugnot on chain.
engine behind recurring support for a builder: a plan somebody subscribes to, period after period, paid in ugnot on chain.
engine behind an embeddable discussion block: the text half of what a reaction bar does, keyed on the PAGE it is shown under rather than on the realm that stores it.
engine behind a web of trust: one address says it stands behind another, in writing, optionally with its own money locked against the claim.
engine behind a web of trust: one address says it stands behind another, in writing, optionally with its own money locked against the claim.
answers one question: is it worth paying gas to delete on-chain state? On gno.land every byte of realm state locks GNOT, and the lock is refunded to whoever signs the transaction that frees the byte.
answers one question: is it worth paying gas to delete on-chain state? On gno.land every byte of realm state locks GNOT, and the lock is refunded to whoever signs the transaction that frees the byte.
Brainfuck machine for gno.land, and the measuring stick the rest of the guest-VM work is calibrated against. It ships two things that look alike and are not:
RV32IM emulator for gno.land: 48 instructions that every real compiler already targets. A guest here is not written in a new language.
host ABI shared by every guest virtual machine that runs inside a gno realm: a stepping contract with an explicit fuel budget, a capability-scoped Host, and a snapshot format that lets a guest program outlive the…
implements the publishable, non-secret half of the Wesh protocol (weshnet, the network layer behind Berty) as a pure gno library.
Wikipedia-shaped wiki engine for gno.land: namespaced titles, an append-only revision chain, wikilinks with backlinks, categories, redirects, protection levels, line diffs, and markdown rendering.
Code generated by generator.go; DO NOT EDIT.
Code generated by generator.go; DO NOT EDIT.
content model of a curated registry of gno.land networks: what a zone is, what an endpoint on one is, which strings each field accepts, and the curation states both move through.