rdy documentation v0.53.0

Reference

File formats

since 0.10.0 This reference gives every file rdy reads or writes outside the store. These are the export tree, its block entries, the dump file and the sync batch. They also include the working-copy YAML, the four configuration files, the credential file and pack files. The store's own objects are in "Store format" in How rdy is built. Commands and their flags are in CLI.

Export format 3

rdy import <dir> --view <view> reads a folder tree into a view, and rdy check lints one. rdy 0.4.0 and earlier wrote the tree with rdy export; since rdy 0.5.0, no command writes one. The tree has one manifest, one authors file and two directories.

Text
<out>/rdy-export.yaml                  the manifest
<out>/authors.yaml                     who last wrote each block
<out>/docs/                            the folder tree
<out>/docs/wallets/_folder.yaml        the wallets folder block
<out>/docs/wallets/transactions.yaml   the doc and every block in it
<out>/docs/wallets/cards/_folder.yaml  a sub-folder
<out>/docs/overview.yaml               a top-level doc
<out>/blobs/<hash>                     one file per blob, named by content hash

The manifest holds three keys.

Table 1
KeyValue
format3
packthe name of the project's pack, for example rdy-standard
scopethe scope that was exported, for example canon or view:work

The file system is authoritative for the name and parent of folders and docs. A folder is a directory, and its name is the directory name. A doc is a file, and its name is the file stem. Neither entry carries name or parent; a name or parent on either is refused on import with E_FILE_FORMAT. A rename of a file or directory is a rename of the doc or folder.

_folder.yaml holds one block entry, the folder: id, type: folder, order and fields without name. A directory is written even when its folder is empty. A doc file holds a list of block entries. The first is the doc, without parent or name; every block inside keeps an explicit parent and order. Sibling order is the order key, and directory listing order is ignored.

An asset block names its blob by hash in fields.blob, and the file sits in blobs/. A blob field on a block of another type is an ordinary field, and export copies no file for it. Import refuses an asset whose blob is neither in blobs/ nor already in the project. Dotfiles are never part of an export, and import refuses a symbolic link anywhere in the tree with E_FILE_FORMAT. A format-3 import creates the folders and the blocks in one write, with one change per author.

since 0.2.0

authors.yaml holds one row per block: id, actor, run, role, at_ms and landed_ms. actor, run, role and at_ms come from the change that last wrote the block, and at_ms is that change's time in milliseconds. landed_ms is the time of the landing that carried the change. A row has no run or landed_ms when there is none. Rows follow the log order of the changes that wrote them, then block id within one change. rdy export refuses the inflight scope with E_BAD_INPUT.

since 0.2.0

rdy import reads authors.yaml when it is there. It writes one change per author, oldest first, with the run, role and time of that author's newest block. Changes with the same time keep the order of authors.yaml: each takes the place of its author's last row at that time. An import merges each author's blocks into one change, so a later export does not always keep the row order. Blocks without a row go in a last change, the importer's. Each author's change has the message import from <dir>: <n> block(s) by <actor>, imported by <importer>, where <dir> is the directory's name, never its path. Import does not store landed_ms; it is there for people to read. A row that fails is E_BAD_INPUT: an unknown key, a block outside the export, or an at_ms outside 0 to now plus 24 hours.

Markdown import source

since 0.49.0

rdy import --md and rdy_import with md: true read a folder of Markdown files. YAML stays the working copy's source format: Markdown is an import source only, and rdy never writes it back.

rdy opens only files whose names end in .md or .markdown, in any case. Other regular files are counted and reported as non_markdown_file rows, never opened. rdy leaves out every entry named .rdy or .git. A root .rdyignore follows the working copy's rules, with at most 65,536 bytes and 1,024 patterns, else E_CONFIG. A link, a reparse point, an entry that is not a regular file or directory, or a name that is not plain UTF-8 is E_BAD_INPUT. So are two paths that are one when case is ignored, and a source that changes while rdy reads it.

since 0.49.0

Front matter is closed. It starts with --- on the first line and ends with --- or ..., at most 65,536 bytes. rdy takes two keys only: title, a non-empty string, and doc_type, a string. Any other key, a value of the wrong kind, or YAML that does not parse leaves the whole front matter as literal text, with a front_matter row. A doc_type that the pack does not hold is E_DOC_TYPE, <path>:<line>:<col>: unknown doc_type "<value>". A file that is not UTF-8 is E_FILE_FORMAT.

since 0.49.0

Each directory becomes a folder, and each Markdown file becomes a doc in its folder. A name is the slug of the directory name or the file stem, else <kind>-<slug>, else the kind alone. A repeat under one parent, ignoring case, takes -2, -3 and so on. A doc's title is the front matter title, else the text of its first heading, else the file stem. Its doc type is the front matter doc_type, else the pack default.

A heading becomes a section, nested by heading level. A fenced or indented code block becomes a code block, and a fenced block keeps the first word of its info string as the language. A table becomes a table. A paragraph, a list, a block quote and other running text become prose.

since 0.49.0

rdy checks every bound while it reads, and a source over one is E_LIMIT, Markdown import exceeds <bound>: <limit>.

since 0.49.0

Table 2
BoundLimit
Source regular files, including reported non-Markdown files4,096
Markdown bytes per file16 MiB
Total captured Markdown and ignore bytes64 MiB
Front matter per file65,536 bytes
Generated blocks100,000
Folder depth32
Parser nesting128
Relative path bytes4,096
Unmapped rows10,000

since 0.49.0

The source digest is a BLAKE3 hash, 64 lowercase hexadecimal characters. It covers each included directory and file path and its kind, the bytes of each Markdown file, and the bytes of the root .rdyignore. A reported file adds its path only. A preview gives the digest, and expected_source refuses an import whose source no longer has it.

since 0.3.0

Dump format 1

since 0.32.0

rdy dump writes one dump file, and rdy load reads it, alone or as the first file of a dump chain. The dump is the long-lived exchange format: every later rdy reads every released dump format. Dump format 1 is released with rdy 0.3.0 and store format 10, and rdy 0.4.0 writes it with store format 11. rdy 0.5.0 writes it with store format 12. rdy 0.6.0 writes dump format 2 with store format 13, and rdy 0.7.0 writes it with store format 14, as the next section says. rdy 0.10.0 writes it with store format 15. rdy 0.13.0 writes dump format 3 for every dump, with store format 16, rdy 0.18.0 writes it with store format 17, and rdy 0.20.0 with store format 18. rdy 0.26.0 writes dump format 4, which carries a feature store. Two numbers version a dump. dump_format versions the container: the prelude, the framing, the record kinds and the fields of each record. In formats 1 to 3, the header's store_format names the encoding of the copied store frames, and a reader checks the pair. Format 4 holds the store's features in its place.

Integers are little endian, and a hash is the BLAKE3 hash of the bytes it covers. A dump starts with the 8 bytes RDYDUMP\n, then dump_format as a u32. Records follow, each framed as a store frame: len: u32, kind: u8, hash: [u8; 32], then the payload. A record's hash is the hash of its payload. The order is closed:

  1. one HEADER;
  2. zero or more FILE records;
  3. zero or more BATCH records, each followed by exactly its frames store frames;
  4. one TRAILER, then the end of the file.
Table 3
RecordKindPayload
HEADER0xF0store_format: u32, log_end.segment: u32, log_end.offset: u64, rdy_len: u16, rdy: [u8; rdy_len]
FILE0xF1path_len: u16, path: [u8; path_len], then the file's bytes
BATCH0xF2start.segment: u32, start.offset: u64, frames: u32, digest: [u8; 32], kinds: [u8; 32]
TRAILER0xFFbatches: u64, frames: u64, files: u32, digest: [u8; 32]
store frameits store kindthe frame's bytes, exactly as the log holds them

since 0.3.0

log_end is the end of the source log when the dump was written. rdy is the version of the rdy that wrote the dump, such as 0.4.0, in UTF-8 and at most 256 bytes. It is for people only, and no reader checks it. A FILE record's path is UTF-8 and one of a closed set: .rdy.yaml, .rdyignore, or .rdy/packs/<name>. <name> uses only A-Z a-z 0-9 . _ -, does not start with ., ends in .yaml or .yml, and is at most 255 bytes, its suffix counted. A reader refuses any other path as damage, E_DUMP, before a load writes anything. A dump holds at most 256 FILE records, each file at most 16 MiB, with paths in strictly ascending order.

A BATCH record copies one sealed batch of the source log. start and digest are the fields of the batch's marker, and frames is at least 1. That many store frames follow, byte for byte as the log holds them. kinds is the hash of each frame's kind byte and hash, in order. A frame's kind is one that the header's store format assigns, as the next paragraph lists. It is never 14, the batch marker, and never an unassigned kind.

since 0.32.0

The pair (1, 10) assigns the frame kinds 1 to 9, 13, and 15 to 19. The pair (1, 11) assigns the same kinds and 10, the ANSWER kind. rdy 0.4.0 reads both pairs. The pair (1, 12) assigns the same kinds as (1, 11), because store format 12 adds only the refs meta/repo_id and meta/origin. rdy 0.5.0 reads all three pairs. rdy 0.6.0 reads these three pairs and (2, 13). rdy 0.7.0 also reads (2, 14), rdy 0.10.0 also reads (2, 15), and rdy 0.13.0 also reads (3, 16). rdy 0.18.0 also reads (3, 17), and rdy 0.20.0 also reads (3, 18).

The trailer's batches, frames and files count the records before it. Its digest is the hash of kind: u8, len: u64 and hash of each record, in order, from HEADER to the last record before the trailer. len is the payload's length. A record's hash covers only its payload. So kinds binds each frame's kind, and the trailer's digest binds each record's kind and length, and their order.

since 0.3.0

A reader checks every record's hash, the order, each frame's kind, each batch's frame count and both its digests, and the trailer's counts and digest. Any failure refuses the whole dump with E_DUMP, and no rdy repairs a dump. rdy load also refuses a dump whose batches do not end at the header's log_end, or that holds no batch.

since 0.6.0

Dump format 2

since 0.10.0

Dump format 2 is released with rdy 0.6.0 and store format 13, as the pair (2, 13). It keeps the prelude, the framing and the HEADER, FILE, BATCH and TRAILER records of format 1. Its frame kinds are those of (1, 12), and 20 to 22, the redaction kinds. It adds one record, DROPPED, of kind 0xF3. The readers of format 1 are unchanged, and a dump of format 1 never holds a DROPPED record. rdy 0.7.0 writes store format 14 in dump format 2, as the pair (2, 14). Its frame kinds are those of (2, 13), and 11, the SIGNATURE kind. rdy 0.10.0 writes store format 15 in dump format 2, as the pair (2, 15). Its frame kinds are those of (2, 14), because store format 15 adds only refs.

since 0.6.0

A DROPPED record stands where a batch's store frame would be. It is one source frame whose payload an applied redaction removed. Its payload is exactly 102 bytes: original_kind: u8, original_hash: [u8; 32], original_len: u32, apply_hash: [u8; 32], has_residue: u8, residue_hash: [u8; 32]. original_kind is BLOCK, CHANGE or BLOB_CHUNK. A block or a change has a residue, and has_residue is 1. A chunk has none: has_residue is 0, and residue_hash is 32 zero bytes. original_len is at most 64 MiB.

A DROPPED record counts as one source frame. Its place in the source log is the batch's start plus the original sizes of the frames before it. The BATCH record's digest and kinds use the original kind and hash. The trailer's digest uses the record as it is: kind 0xF3, length 102 and the record's own hash.

since 0.13.0

The apply that authorizes a dropped frame comes later in the stream than the frame. So rdy load writes the frame's original header and then zeros of its original length. Before it writes FORMAT, it checks that the log's own sealed applies authorize each dropped frame's exact span. A stopped load checks each drop against the apply in the files that it reads after the stop. A dangling or forged drop refuses the load with E_DUMP, and no store is made. A load holds at most 1,000,000 dropped frames for this check. The frames not yet authorized claim at most 1 GiB of zeros in all.

since 0.10.0

A holder's dump holds no FILE record, because a holder has no project files. Its first batch sets meta/store_mode, so its load makes a holder again. A load refuses a holder's dump that holds a FILE record, with E_DUMP.

since 0.10.0

The gate keeps the fixture dumps v2-s13, v2-s14 and v2-s15 of the pairs (2, 13) to (2, 15), beside the three fixtures of format 1. For (2, 15), it also keeps v2-s15-holder, the dump of a holder. No later rdy rewrites any of them, and every later rdy must load each one.

since 0.13.0

Dump format 3

since 0.13.0

Dump format 3 is released with rdy 0.13.0 and store format 16, as the pair (3, 16). It holds two kinds of dump: a full dump and an increment. It keeps the prelude, the framing and the FILE, BATCH and DROPPED records of format 2. Its HEADER and TRAILER keep their kinds, 0xF0 and 0xFF, with new payloads. A frame's kind is one that the header's store format assigns: for (3, 16), the kinds of (2, 15), and 23, the REDACTION_CARRIED kind. rdy wrote format 3 for every dump until format 4, and every later rdy reads formats 1, 2 and 3.

since 0.29.0

Store format 17 keeps dump format 3, as the pair (3, 17), released with rdy 0.18.0. Its frame kinds are those of (3, 16), and 24, the PLAN kind. The gate adds the fixtures v3-s17, v3-s17-chain-full, -chain-1 and -chain-2 beside those of (3, 16). The holder's files add -holder after v3-s17, and each set has an expect file. The table after the digests of (3, 16) pins their twelve digests, and no later rdy rewrites them.

since 0.13.0

Table 4
RecordKindPayload
HEADER0xF0kind: u8 (0 full, 1 increment), store_format: u32, repo_id: [u8; 16], base.segment: u32, base.offset: u64, base_batch: [u8; 48], prev: [u8; 32], end.segment: u32, end.offset: u64, end_batch: [u8; 48], rdy_len: u16, rdy: [u8; rdy_len]
TRAILER0xFFbatches: u64, frames: u64, files: u32, removals: u32, has_first_removed: u8, first_removed.segment: u32, first_removed.offset: u64, digest: [u8; 32]

since 0.13.0

A batch's marker fields are start.segment: u32, start.offset: u64, frames: u32 and digest: [u8; 32], 48 bytes in all. end is the end of the last batch that the file holds, and end_batch is that batch's marker fields. In a full dump, base is segment 0 at offset 0, and base_batch and prev are zero bytes. In an increment, base is the end of the file before it, and base_batch is that file's end_batch. prev is that file's trailer digest. rdy is the writer's version, for people only, as in format 2.

since 0.13.0

removals counts the REDACTION_APPLY frames that the file holds. first_removed is the lowest log place that any of those applies removes, and has_first_removed is 1 when there is one. A holder's apply removes the holder's own copies of its spans, and a hole that only a carried record explains is no span. A place before base says that earlier files of the chain still hold removed content. The trailer's digest covers each record's kind, length and hash from HEADER on, as in format 2. So prev chains each file to the file before it.

since 0.13.0

A reader checks every rule of format 2, and these too. The first BATCH of an increment starts at base, or at offset 0 of the next segment where the source log rolled. The batches end at end, the last batch's marker fields equal end_batch, and an increment holds at least one batch. The trailer's removals and first_removed match the applies in the file, and a chain load resolves an apply whose request an earlier file holds. A load also checks that each batch starts where the batch before it ends, or at offset 0 of the next segment. Any failure refuses the file with E_DUMP, and a place past the largest u64 reads dump position overflows.

since 0.13.0

In dump format 3, a DROPPED record's apply_hash can name a REDACTION_CARRIED record. The load accepts that drop when a carried record in the same file names its exact span with held: false. A later apply in the chain that covers the span leaves the drop as it is. The loaded store then takes that apply as the span's proof.

since 0.13.0

For each released pair (3, s), the gate keeps a full dump and a three-file dump chain of a project and of a holder. For (3, 16) they are v3-s16 and v3-s16-chain-full, -chain-1 and -chain-2. The holder's files add -holder after v3-s16, and each set has an expect file. They sit beside the fixtures of formats 1 and 2, the table below pins every digest, and no later rdy rewrites them. Every later rdy must load each one whole. It must also load each chain at two fixed stops before a redaction apply, and each full dump at one.

since 0.13.0

Table 5
FileBLAKE3
v3-s16.rdydump5de4badbd1e5692e12b8465f06fce5f6cea1f42fd619a18cde756584c792c2b5
v3-s16.expect.json0df206615c985815d676a5ca91efd865899209464f06f575ea235976425e6232
v3-s16-chain-full.rdydump7deafdc1a6b2d42a5f71165ca2961d7f32c9c8f4f2a0012a1798d230d1935a62
v3-s16-chain-1.rdydump23f64d4625407f257e5a0ceb55a133c7472188f21a2ea78e291e49fd02d9069c
v3-s16-chain-2.rdydumpd8735bd462d05edf2d371bed9cf56ce3ca04080fd06882b5e1a02d3e2e2b8111
v3-s16-chain.expect.json2b00f08d44c55b74e6e97375f52acd9e6ed9458ab15790bb31fd6d391a05b615
v3-s16-holder.rdydumpdc4ca5b0fcce7e097db9ecf64196ce00a26ad6c0233df11341a578f8d9e7f26e
v3-s16-holder.expect.jsonc188d8ff41afdb9ecd2e6a172a20e285aef89826dcf3442bab9730ce446b1372
v3-s16-holder-chain-full.rdydumpbf1a88b6d553393f34ad812131bdcb4497347c5a1ec16273a8a8e86c2565f300
v3-s16-holder-chain-1.rdydumpf4069d58ca2dc9705f8b95cf1ae1d5795edf8af5a87ba8a30cc01289debf4262
v3-s16-holder-chain-2.rdydump3aa9e3303fe228c02b79e3e219494992a7f4b6250e602bf0bcaea6f869150057
v3-s16-holder-chain.expect.json369da6d39efc8aeb46369ed36aff7b52e5f5b20f6ba22d0c73531639159bef80

The BLAKE3 digest of each file of the pair (3, 16), set when it was written.

since 0.29.0

Table 6
FileBLAKE3
v3-s17.rdydump94157e0d99fbd0170ea7eeca37315e141a4776485923bd27264bbc00e70442b5
v3-s17.expect.json397680b93467ef7a9dce3fdb0e16cb1a71d8bbcdbe734ce96907d657578fd44a
v3-s17-chain-full.rdydumpc0ee2f5236c226df0eaac875b317872d10bbc2f0f441145ea9df139317636872
v3-s17-chain-1.rdydump1189a0c637444c8f9ec13ad4f6b1ee93dc12c7b2d912b4f877d253bc6e3e313d
v3-s17-chain-2.rdydump1c72ece30389ba89621cf4b01702b0a640628280d0297f3ca04418fbff73b42b
v3-s17-chain.expect.json9dcb2982bcae43cf79476b6ecaff2e13f528bb1a86d5f2caf0ec4e98c0f775b8
v3-s17-holder.rdydump004dbd2f0eb39bcf227aa4a1dfc1fe58980094bd3bbb80b52bbcb70cc8124d91
v3-s17-holder.expect.json8c21ae51e8a2bd0689189935d56bac40506fb77890606cf70cdf0d967f39ff69
v3-s17-holder-chain-full.rdydumpec0e4a4f6f3f5c6efde8229b8b65205adfa4a18de8098f4945864021f4ebf5eb
v3-s17-holder-chain-1.rdydump1ff73bc53aeb46cb50f0de29997165298bcd14e14b4876bf3909db17eecd9be2
v3-s17-holder-chain-2.rdydumpbbff1ff5ce76e60d8ec2c6aacab90b9c471edf0ec4b359017dfa884c7e2bc35a
v3-s17-holder-chain.expect.jsonb38ac9d6944e139dd4e0966c5a58648d76a937c8858910f11b92446200b55e2f

since 0.32.0

Store format 18 keeps dump format 3, as the pair (3, 18), written by rdy 0.20.0. Its frame kinds are those of (3, 17), and a CHANGE frame may carry the reflects justification. The gate adds the fixtures v3-s18, v3-s18-chain-full, -chain-1 and -chain-2 beside those of (3, 17). The holder's files add -holder after v3-s18, and each set has an expect file. The table below pins their twelve digests, and no later rdy rewrites them.

since 0.32.0

Table 7
FileBLAKE3
v3-s18.rdydumpb69978453eaf0bc06b5e8040cd152836c1a290a913603cd53a5a2e5ece53c615
v3-s18.expect.jsonc2bf21e87c2c4babf30750ec8d619f204367ea8d94eeae600ff394f1429603c0
v3-s18-chain-full.rdydump7c734b3043f0b5e3873621eb97799ae7c0aab1638f1f130c9a268da9ef6e0002
v3-s18-chain-1.rdydumpb1203e3fdc5bd5a8f15622d23b4cc8951bfe193ac59b23372900aecd81ceb947
v3-s18-chain-2.rdydump5837691a6d83e7537fb4e62211aaaf54f33e9948e41be0343fc23bc6f85c28e9
v3-s18-chain.expect.json1d93b0abc3570711b46075d5405b4df54af86fd9eeb45512ab8d511e930c7785
v3-s18-holder.rdydump0ba16663f3cc01684e1a01e36d2941cb7ae4f92d6940be4cc3a4b833ad3afbe7
v3-s18-holder.expect.jsonc6cad8a5b549df4c840ae698c8d5e6cd67830525370e76fc4f372ba638a7dccf
v3-s18-holder-chain-full.rdydump2ac0183140a5c494bcd6d63e41eb6cc3437d684096b904d856a453be9bcfd907
v3-s18-holder-chain-1.rdydump06a8b3bfa187101dc1179d0b9b7708e86a826068bf767bf79cf03919fd116b9e
v3-s18-holder-chain-2.rdydumpd160d815ecde5f20f4eda78cc1b0710199b56add6e5063916b61a7f25b74e974
v3-s18-holder-chain.expect.json07ae3d4064f82907bbb9e4be41a062bad173d7a6dbe86265302db67607410b88

since 0.26.0

Dump format 4

since 0.26.0

Dump format 4 carries a feature store, and rdy 0.26.0 writes it for every dump. It keeps every rule of format 3: the prelude, the framing, the FILE, BATCH and TRAILER records, and the chain facts. Its HEADER holds the store's feature manifest where format 3 holds store_format. A reader applies the store's feature rules to that manifest. An invalid manifest is E_DUMP, and an unknown incompatible feature is E_STORE_FORMAT. Every later rdy reads formats 1 to 4, and the nine released pairs keep their readers.

since 0.26.0

Table 8
RecordKindPayload
HEADER0xF0kind: u8 (0 full, 1 increment), features_len: u32, features: [u8; features_len], repo_id: [u8; 16], base.segment: u32, base.offset: u64, base_batch: [u8; 48], prev: [u8; 32], end.segment: u32, end.offset: u64, end_batch: [u8; 48], rdy_len: u16, rdy: [u8; rdy_len]
DROPPED0xF3104 bytes: logical_kind: u8, encoding: u16, original_hash: [u8; 32], original_len: u32, apply_hash: [u8; 32], has_residue: u8, residue_hash: [u8; 32]
store frameits raw kindthe frame's bytes as the log holds them; a versioned frame keeps kind | 0x80 and its encoding prefix

since 0.26.0

features is the manifest's canonical JSON, at most 65,536 bytes. A frame's encoding must be one that its kind registers. The BATCH record's digests use each frame's raw kind. A DROPPED record adds the removed frame's encoding after its kind, and that encoding is 0 until a removed versioned record has its residue adapter. A chain may add features from file to file, and it never drops or changes one.

since 0.26.0

The gate keeps two fixture sets of format 4, v4-f1-e0 and v4-f1-e1, and a test pins their bytes. v4-f1-e0 holds the format's first set, and v4-f1-e1 adds the carried kinds and the records of encoding 1. Each set holds a full dump and a three-file dump chain of a project and of a holder, each with an expect file. The stem names the test set, not a store format.

since 0.48.0

A dump of a store with foreign_copy carries its FOREIGN frames and the frames in their kinds' optional encodings, and its manifest names the feature. A dump of any other store carries neither. The gate also keeps the format-4 fixture v4-f1-e1-foreign-copy, with its expect file.

since 0.52.0

A dump of a store with snapshot_delta carries its SNAPSHOT_DELTA frames, and its manifest names the feature. Dump format 4 keeps its number. A load of a dump whose manifest lacks the feature ends with one batch of deltas, as the upgrade of a store does. A load refuses a SNAPSHOT frame whose bytes are not the canonical encoding of its map, also without the feature. That is E_DUMP damage at a byte, and <what> reads snapshot <hash>: bytes are not canonical. The gate also keeps the format-4 fixture v4-f1-e1-snapshot-delta, with its expect file.

since 0.10.0

Sync batch format 2

since 0.10.0

A sync batch carries part or all of one tag's history from one store to another, as one file. An upload is one or more batches of one tag. Each batch has its own header, trailer and prerequisites, so batches may arrive in any order and may repeat. A batch is not a dump: it holds no project file, local ref, batch marker or source place. rdy stream check checks one batch, and a holder's take checks all the batches of an upload together.

since 0.48.0

Integers are little endian. A batch starts with the 8 bytes RDYSYNC\n, then stream_format as a u32, which is 2 for a tag history and 3 for a link delivery. Records follow, each framed as a store frame, as in a dump. The order is closed. Format 2 holds one HEADER, zero or more object records, one TRAILER, then the end of the file. Format 3 adds one DELIVERY after the HEADER. An object record is a portable object's raw frame, as the store holds it, or a DROPPED record.

since 0.48.0

Table 9
RecordKindPayload
HEADER0xF0features_len: u32, features: [u8; features_len], repo_id: [u8; 16], purpose: u8 (0 tag_history, 1 link_delivery), tag: [u8; 32], prerequisites: u32, then that many keys of a logical kind: u8 and hash: [u8; 32], in strictly ascending order
DELIVERY0xF4format 3 only: the stream-only record {publication, selection, versions, shells} in postcard, as below
objectits raw store kindthe object's bytes, as the source log holds them; a versioned frame keeps its encoding prefix
DROPPED0xF3the 104 bytes of a format-4 dump's DROPPED record, with no place in a source log
TRAILER0xFFrecords: u64, bytes: u64, digest: [u8; 32]: exactly 48 bytes

since 0.48.0

tag is the hash of the upload's root TAG. Every batch of an upload repeats the same features, repo_id, purpose and tag. A take refuses a batch with a feature that this rdy may only read, with E_STORE_FORMAT. A batch has no sequence number, upload id or end mark. records counts the object records, and bytes counts every byte before the trailer's frame. In format 3, records and digest also cover the DELIVERY. digest is the hash of each record's kind, length and hash, from HEADER to the last object record, as a dump's trailer has it.

since 0.52.0

Sync batch format 2 replaces format 1. Its header holds the store's feature manifest, as canonical JSON of at most 65,536 bytes, in place of store_format. A reader applies the store's feature rules to it, so an invalid manifest or an unknown incompatible feature is E_STORE_FORMAT. A reader refuses format 1 with E_STORE_FORMAT: sync batch format 1 is not supported, with the fix write the stream with the pinned rdy build. The gate keeps the bytes of the fixture v1-s15 and pins that refusal. It keeps v2-f1-e0, v2-f1-e1 and v2-f1-e1-snapshot-delta for format 2.

since 0.52.0

An object record's logical kind is 1 to 7, 9 to 11, 13, 15 to 18, 20 to 22, 24 to 28 or 30. A ref update, a batch marker, a TRANSITION record and a REDACTION_CARRIED record never travel. Each record decodes within its bounds, and no object repeats in one batch. A record's dependency is an earlier record of the batch or a prerequisite. The prerequisites are exactly the keys that the records need and the batch lacks, and the root TAG when the batch lacks it. So a batch may hold no object record, and its root is then a prerequisite.

since 0.10.0

A dropped record's key is the removed object's kind and hash. Its apply may come before or after it in the batch, because a removal proof follows what it removes. An apply that the batch lacks is a prerequisite, like any other reference. A batch check only says that one batch is valid. It never says that an upload is complete or that a removal is approved: a take checks those over all the upload's files.

since 0.10.0

One batch, and one upload, hold at most 2,147,483,648 bytes, 1,000,000 object records and 1,000,000 dependency edges. A dependency chain holds at most 100,000 records. A header holds at most 100,000 prerequisites, so at most 3,300,057 bytes. An upload has at most 1,024 batch files. At most 1,000,000 dropped records may wait for their proof, with at most 1 GiB of original bytes in all. A batch over a bound is E_LIMIT.

since 0.52.0

since 0.10.0

One typed record holds at most 16 MiB, a text at most 1 MiB, and a list or map at most 100,000 elements. It nests at most 64 levels and decodes at most 1,000,000 values. Containers and leaves count as values, and fixed-width scalars do not. Each struct, option, enum, list, map, string and byte string is one value, and a hash is two. A blob chunk holds at most 1 MiB and has no typed decode.

since 0.48.0

Sync stream format 3 carries the purpose link_delivery: a profile's filtered view at a tag, which the cited side's Snapshot::link_export writes. A tag history stays at format 2, and a reader reads formats 2 and 3. Only the adapter writes and takes a link delivery, and a batch of the wrong purpose is E_STREAM_PURPOSE. Its order is one HEADER, one DELIVERY, zero or more object records and one TRAILER, and it has no prerequisites. Each object record is the BLOCK of one selected version, or a DROPPED record for a redacted one.

since 0.48.0

DELIVERY, kind 0xF4, is a stream-only record {publication, selection, versions, shells}. It holds the publication {tag, profile, profile_version?}, the selection digest, each selected block's ForeignVersion and each shell's {id, version}. These are facts that the citing side cannot compute. HEADER.tag is the hash of the cited tag's TAG object, for provenance only. The stream never carries that TAG, and the citing store never holds a foreign one. So the root-TAG rule of a tag history does not apply, and the check and the take never ask for that TAG.

since 0.48.0

Two deliveries are the same when each selected block's version or residue, its derived facts, the shells, and the set kind and team match. The take then writes nothing, and a new tag alone writes nothing. A change to the shells alone writes a delivery with no added, changed or removed block.

Block entries

Every entry in a doc file or _folder.yaml is one mapping with these keys. The same shape is what rdy show <id> prints and rdy edit <block> opens.

since 0.2.0

Table 10
KeyTypeRequiredMeaning
idstringyes on export; absent for a new block in a staged filethe block's id, such as c-7KQ2M
typestringyesthe block type from the pack
parentstringblocks inside a docthe parent block's id; absent on a doc or folder entry
orderstringyesthe sibling order key: base-62, compared byte-wise, at most 24 characters
fieldsmapwhen the type has fieldsthe typed fields the pack declares, such as title, lifecycle, doc_type, alt
bodystringwhen the type requires a bodythe inline text, with {{id}} refs and the inline Markdown subset
linksmapoptionallink kind to a list of {target, part}; part is optional
pinsmapoptional, export onlyblock id to the content hash a ref or link was pinned at
YAML
- id: d-1DENT
  type: doc
  order: a1
  fields:
    title: Transactions
    doc_type: components
    lifecycle: stable
- id: s-Q4RRZ
  type: section
  parent: d-1DENT
  order: a1
  fields:
    title: Transfers
- id: c-7KQ2M
  type: claim
  parent: s-Q4RRZ
  order: a1
  body: "A leaver opens a new wallet and transfers their balance on the {{t-MEDGR}}."
  links:
    describes:
      - target: m-W2HXR

fields holds YAML values of the kinds the pack declares: str, int, bool, list, map or enum. A body on a type whose body rule is forbidden, or a missing body where it is required, is a schema error. A link kind the pack does not list in link_types is refused.

fields.reflects is an engine field, and a pack that defines it does not load, with E_CONFIG. It holds the code paths a block follows: a list of at most 32 path globs, relative to a code repo's top folder. A glob is segments joined by single / characters, with no / at either end. A whole ** segment matches any number of segments, * matches any run of characters inside one segment, and ? matches one character. Other characters are limited to A-Z a-z 0-9 . _ -, and a glob is at most 256 bytes.

A block of any doc asset type may carry the field. The validator refuses it with these codes:

  • E_FIELD_UNKNOWN on a supporting type, such as a decision;
  • E_FIELD_KIND for a value that is not a list of strings;
  • E_LIMIT for more than 32 globs;
  • E_BAD_GLOB for a glob that does not compile.

since 0.2.0

fields.key_auto is an engine field. rdy sets it to true next to a key it derived from a path, and only on a doc or a folder. The validator refuses it on any other type with E_FIELD_UNKNOWN. It refuses it with E_FIELD_KIND when the value is not true or no key stands beside it. The field is store-only: the working copy never writes it, and rdy refuses a staged file that sets it. An export writes it, and an import keeps it.

fields.reaffirmed and fields.reflects_at are engine fields, and only rdy writes them. reaffirmed sits on an accepted decision, and reflects_at on a block that declares reflects. A pack that defines either does not load, with E_CONFIG. The validator refuses either in a create or an update with E_FIELD_UNKNOWN. Both are store-only: the working copy never writes them, and rdy refuses a staged file that names them with E_WC_INVALID. An export omits them, and an import never sets them. A staged file or a write that leaves them out does not clear them. Only the rules for each field change them.

since 0.48.0

fields.adopted_as is an engine field on an accepted decision, with the same rules as reaffirmed. Its value is the map {content, encoding, id, repo}. A write that names it is refused with the fix remove adopted_as; use rdy_supersede with adopted_as. A pack type that defines a field adopted_as or deviates_from does not load: type <name>: field <f> is reserved for the engine.

The working-copy YAML

The working copy is the docs/ tree of an export, laid at the project root and bound to a view. Folders are directories with _folder.yaml, docs are <name>.yaml, and blobs live in _blobs/<hash>.<ext>. The block entries are the ones above, with the metadata split applied. See "Working copy" in How rdy is built.

since 0.2.0

Requirement

A doc file holds only content and presentation fields, inline refs, reader links, structure and the folder path; version pins, provenance and justification links stay in the store.

A new block in a staged file has no id; the client assigns one before the commit, and the write-back fills it in. A figure block may name an image by relative path; the commit stores it as a blob and rewrites the reference to the hash form. Write-back rewrites every committed file in canonical form and drops YAML comments.

Three kinds of file sit beside the docs and are never docs. <doc>.theirs.yaml and _folder.theirs.yaml hold the store's side of a conflict after rdy update. Dot-entries, non-YAML files outside _blobs/, directories without _folder.yaml, and anything .rdyignore matches are ignored, never errors. A *.yaml file that does not parse as a doc is listed as untracked.

Local state lives in .rdy/wc/ and is never a store object: bound.yaml (the bound view and its head), base/ (the checked-out version of every block and file), stage/ (staged copies), conflicts.yaml, pending.yaml (the write-back journal) and lock. An extra worktree holds a .rdy-worktree file that points at the project and keeps its state in .rdy/worktrees/<name>/.

.rdy.yaml

since 0.4.0

.rdy.yaml at the project root is the shared project config. It travels with the project, and every clone reads the same values.

since 0.49.0

Table 11
KeyMeaning
packthe pack the project uses
namethe project's name, as the site shows it; absent, rdy uses the project directory's name
descriptionthe project's description, as the site shows it
serve.start_timeoutseconds a client waits for the daemon to start; default 30
serve.idle_timeoutseconds a detached daemon stays up with no connection; default 600; a live page in view counts as a connection
serve.site_portthe live site's port, from 1024 to 65535; absent, rdy derives one from the project path; also valid in the local and user config
serve.site_lantrue also serves the live site on this machine's private network address; default false; also valid in the local and user config
serve.uitrue serves the approver UI on the loopback listeners; default true; set it in the local or user config only: in .rdy.yaml it warns, and rdy ignores it
serve.mcp_httptrue turns on MCP over HTTP at /~mcp on the live site's loopback listener; default false; set it in the local or user config only: in .rdy.yaml it warns, and rdy ignores it
views.idle_daysdays without a write before rdy view ls flags a view idle; default 14
reviews.lease_ttlminutes a claimed review request stays leased, a whole number; default 10, and 0 disables leases
reviews.require_up_to_datetrue refuses every approval whose base moved, instead of the clean-rebase rule
coverage.targetthe coverage at which onboarding is done, a whole number from 0 to 100; default 80
coverage.gateoff (default) or no_lower; no_lower makes a version that lowers coverage not ready; another word warns, and rdy uses off; .rdy.yaml only
decisions.homethe doc or folder where new decisions go, as its path, key or id; optional, and without it they go to the project root; .rdy.yaml only
propose.cadencewhen agents propose: break (default), task, changes or asked; also valid in the local and user config; another word warns, and rdy uses break
propose.changesthe count of changes that makes a proposal due under changes; 1 to 1000, default 10; also valid in the local and user config
ADR sourceseach source's repo and folder; a pin to a revision is a foreign pin in canon, never a config entry
code_reposthe linked code repos: at most 16 names; .rdy.yaml only
site.logo, site.faviconthe project's own logo and favicon, self-hosted
site.creditfalse removes the "Built with rdy" line
site.themetheme token overrides per mode, or theme_dir naming .rdy-theme/
site.theme.stricttrue makes a contrast failure an error instead of W_THEME_CONTRAST
site.base_paththe path a static site is served under, starting and ending with /; default /; only the not-found page reads it, and the live site ignores it; .rdy.yaml only
remoteseach remote by name: url, an HTTPS URL, and mode, share or publish; one share remote at most; also valid in local and user config

since 0.4.0

Constraint

.rdy.yaml never holds actor, tokens or key pins, and the working copy never treats it as a doc.

Constraint

Only the project config affects rendering; user and local config never change the site's output.

.rdyignore

since 0.4.0

.rdyignore at the project root uses gitignore syntax. A file it matches is skipped by import and by every working-copy command, and it is never an error. The working copy never treats the file as a doc.

.rdy/local.yaml

since 0.4.0

.rdy/local.yaml is this user's configuration for this project: the local config. It is never carried by clone or dump.

since 0.49.0

Table 12
KeyMeaning
actorthis user's actor for this project, overriding the user config; in rdy's actor form, else E_BAD_INPUT with a fix that names this file
serve.site_lan_addressthe private IPv4 address the live site uses while serve.site_lan is true; also valid in the user config, never in .rdy.yaml
serve.uitrue or false: whether the live site serves the approver UI for this checkout; default true; also valid in the user config, never in .rdy.yaml
serve.mcp_httptrue or false: whether MCP over HTTP serves for this checkout; default false; also valid in the user config, never in .rdy.yaml
overridesany project-level preference, overriding .rdy.yaml for this user
code_pathseach linked code repo's checkout path, by name; a relative path starts at the project root; also valid in the user config, where a path must be absolute; never in .rdy.yaml
signing settingsthe signing settings of the user config, for this project only; never in .rdy.yaml
remotesremotes for this checkout; an entry replaces the user config's or .rdy.yaml's entry of that name
hub.installs.<origin>.pinned_originsup to 16 other HTTPS origins for that install, replacing the user config's list; trusted for the uploads of rdy publish, and later for the sync client; never in .rdy.yaml
remote tokensa static token for a remote; hub sign-in tokens live in credentials.yaml, beside the user config

User config

since 0.4.0

~/.config/rdy/config.yaml is one person's configuration across projects: the user config. When XDG_CONFIG_HOME is set, the path is $XDG_CONFIG_HOME/rdy/config.yaml.

since 0.49.0

Table 13
KeyMeaning
actorthe human actor, such as human:<handle>, in rdy's actor form, else E_BAD_INPUT with a fix that names this file. Absent, rdy shapes human:$USER into the form. It writes lower case, writes each other character as -, and folds each run of - into one. It keeps at most 64 characters, with no -, _ or . at either end. An empty result gives human:unknown
serve.site_lan_addressthe private IPv4 address the live site uses while serve.site_lan is true, in every project whose local config sets none
serve.uiwhether the live site serves the approver UI, in every project whose local config sets none; default true
serve.mcp_httpwhether MCP over HTTP serves, in every project whose local config sets none; default false
personal defaultspreferences that apply in every project unless a project or local file overrides them
signing settingssigning.key, signing.agent_key, signing.sign and signing.allowed_signers; "Configuration" in How rdy is built gives their values
remotesremotes for every project of this user; a project or local entry of that name replaces one
hub.installs.<origin>.ca_filean absolute path to a PEM bundle that the TLS check of that install also trusts; user config only
hub.installs.<origin>.pinned_originsup to 16 other HTTPS origins for that install; read and checked, first used by the publish and sync clients
instructions.personthe absolute path of the person's meta project, which holds their own agent instructions; user config only; default .rdy/meta in the home directory

credentials.yaml

credentials.yaml sits beside the user config and holds this user's hub sign-ins, one record per install. Its only key, installs, maps each install's origin to a record whose state is pending, ready or reauth_required. A pending record holds machine_name, device_code, user_code, verification_uri, expires_at_ms, next_poll_at_ms and interval_seconds. A ready record holds access_token, refresh_token, expires_at_ms, account and handle. A reauth_required record holds its state alone, and an install with no record is signed out. Only rdy writes the file; a record that does not parse is E_CONFIG, and its fix is remove the invalid credential file, then sign in again.

Precedence

since 0.4.0

Settings are read from four levels, and the most specific wins: local config, then project config, then user config, then the defaults.

since 0.4.0

Requirement

A key valid only at some levels is ignored elsewhere, and its W_CONFIG_UNKNOWN warning names the file it belongs in.

since 0.4.0

actor is valid in the user config and in the local config, never in .rdy.yaml, where it would make everyone the same actor. rdy config --show-origin prints each effective value and the file it came from. An agent that uses the CLI as a tool sets $RDY_ACTOR and $RDY_RUN instead of any file.

instructions.person is valid only in the user config. So a project never moves a person's meta project.

Pack files

A pack is one YAML file. The built-in pack is rdy-standard; a project's own packs live in .rdy/packs/*.yaml. A key that repeats in one mapping makes the file invalid, and the pack does not load (E_CONFIG). rdy pack check resolves the project's pack and reports problems.

since 0.48.0

Table 14
KeyTypeMeaning
namestringthe pack's name
versionstringthe pack's version; a project pins one
extendsstringthe pack this one extends; its types are inherited and may be overridden
link_typeslistthe link kinds a block may carry, such as describes, implements, decided_by, affects
default_doc_typestringthe doc type rdy new doc uses when none is given
block_typesmapeach block type by name; see below
doc_typesmapeach doc type by name, with its skeleton
areasmapeach area by name, with a description and paths
tensionsmapseverity overrides per tension kind, blocking or advisory
tensions_acrossmapseverity overrides for tensions across projects, blocking or advisory, for the five cross-project kinds; see below
coveragemapthe coverage dimension weights, dismissed_weight, drift_threshold and max_docs_per_level; see below
ruleslistat most 64 rule checks; see below

A block type has these keys.

Table 15
KeyTypeMeaning
prefixstringthe id prefix, such as c for a claim
traitslistengine traits: normative, informative, defines, describes, asset, structural, presentational
fieldsmapeach field by name: kind (str, int, bool, list, map, enum), required and, for an enum, values
childrenlistthe block types allowed below this one
bodyenumoptional (the default), required or forbidden
classenumdoc_asset (the default) or supporting; a type a child pack overrides keeps the parent's class unless it sets one; decision, question, publication_profile, finding and source are always supporting
trackinglistFields left out of the content hash. They stay writable on an accepted or rejected decision. Each must be a field of the type, and none may be key, reflects, reaffirmed, reflects_at, status, decided_at, lifecycle, or a decision's statement or options. A child pack adds to its parent's list.

since 0.33.0

Every type with the defines trait also holds the optional bool field everyday. A pack may declare the field only in that form. Any other declaration does not load: type <name>: field everyday must be an optional bool. A max_docs_per_level out of range reads coverage.max_docs_per_level is <n>; it must be 1 to 100000.

since 0.41.0

Every pack also holds three as-built fields. decision holds the optional string built, which is always a tracking field. Each content type, a doc_asset type other than doc and folder, holds the optional bool field planned and the optional string since. doc holds planned only. A pack may declare these fields only in those forms. Any other declaration does not load: type <name>: field <field> must be an optional bool, or must be an optional string.

since 0.41.0

built is planned, none or a release version, and since is a release version. A release version has one optional leading v, then <major>.<minor>.<patch> with an optional pre-release part, and no +build part. A bad value refuses the write with E_VALIDATION, and its issue is E_BAD_INPUT. For built, it reads Field "built" must be planned, none or a release version., with the fix Write built as planned, none, or a version such as 1.2.0. For since, it reads Field "since" must be a release version., with the fix Write since as a version such as 1.2.0 or v1.2.0-rc.1.

since 0.41.0

A value over 256 bytes gives the issue E_LIMIT, Field "<field>" exceeds its limit., with the fix Use at most 256 bytes in "<field>". A value of the wrong kind is E_FIELD_KIND. A working-copy file takes planned and since like other fields, and a commit checks them. built stays in the store with its decision. rdy reads built and since as metadata, never as text. No store format or dump format changed for these fields.

since 0.41.0

Every pack also holds the engine type publication_profile, and a pack that declares it does not load. Its id prefix is pf, and it is a supporting type with no body. It sits directly under a doc and needs a key. Its fields are title, audience (org or public) and select (1 to 1024 distinct doc or folder ids). The optional fields are description, trail (a bool), planned and since. planned is hide or mark. With none, a public profile hides planned blocks, and an org profile marks them. since is show or off. With none, the pill shows in docs of type reference only. Another value gives the issue E_FIELD_ENUM. title holds at most 256 bytes, and description at most 4096. The store format does not change for it.

since 0.49.0

Every pack also holds the engine type authority_policy. A pack that declares it does not load. Its id prefix is ap, its key is authority-policy, and it is a supporting type. It has no body, and it sits directly under a doc, as a publication profile does. Its fields are:

  • agent_may_accept: at most 64 rules. A version lands under the policy when one rule covers all of it. Each rule has these fields, and areas, two_way_areas and basis may be absent:
    • name, an rdy name of 1 to 64 bytes, unique in the policy;
    • actors, 1 to 64 actor patterns in rdy's actor form, where a pattern may end in one *, as in agent:ana/*;
    • areas, at most 64 pack areas, where an empty list means every area;
    • lifecycle, draft or any;
    • justifications, 1 to 3 of implements, editorial and reflects;
    • decisions, none or two_way, with 1 to 64 two_way_areas for two_way and none for none;
    • basis, up to 4 of delegated, precedent, elimination and none, never direct_ruling, recorded_ruling or reconstructed; an empty list accepts no decision;
    • max_blocks, 1 to 100,000, and max_items, 0 to 100,000: the most blocks the version may change and the most plan items it may hold.
  • roles: at most 64 policy roles, each a name mapped to 1 to 256 human:<name> actors and team:<name> labels.
  • require: at most 64 entries {when, role}, where when is one_way, decision, area:<name>, deferral, reaffirm, owner or any. when: owner takes no role. When several entries match an item, the first in the list names its policy role. An adopt item matches only one_way, area:<name>, owner and any. Its blocks are those whose pins it moves or rebinds, and the repo link.
  • owners: at most 10,000 entries {path, owners}. path is a folder, a doc path or a block id, of 1 to 240 bytes. owners holds 1 to 256 human:<name> actors and team:<name> labels.
  • rules_from_chat: optional, land or card. With no field or no policy, it reads land. land lets rdy_rule land on the person's words. card makes it return the card, and rdy_rule {scope, answer} takes the answer. rdy reads this field from canon, never from a draft. Any other value is E_FIELD_ENUM, and a value that is not text is E_FIELD_KIND. A live policy that does not validate stops rdy_rule with E_VALIDATION, and it does not read as no policy. A required policy role still applies to the person, with E_PERMISSION.

A project holds one live policy block. A second one fails at write with E_KEY_CLASH, and at propose or landing with E_VALIDATION. An agent: or ci: entry in roles or owners, and two owners entries with one path, fail validation with E_VALIDATION.

Every pack also holds the engine type instruction, with the prefix ai. It is a doc_asset type with the trait normative, and it has no key. It sits under a doc, or under a section when the pack has that type. Its body is required and holds the whole rule. Its fields are applies_to, 1 to 1024 selectors of at most 256 bytes each, and locked, a bool that is false by default. A decided_by link to a decision gives its reason, and every instruction needs one.

A selector is all, area:<name>, type:<name> or act:<act>. A name has 1 to 64 characters of a to z, 0 to 9, _ and -, and starts with a letter or digit. An act is write, decide, propose, relay, review, publish or redact. An area: selector for an area that the pack lacks warns on the write with W_INSTRUCTION_SELECTOR, and it names nothing until the pack defines the area. An instruction with all is required. rdy shows the other selectors as hints in the rdy_instructions menu and never filters by them.

since 0.41.0

locked counts only in a set's own project, so a local lock has no force over another layer. Every doc also holds the optional bool field required, and required: true makes the doc's instructions a required ruleset. A pack may add optional fields to instruction, and any other declaration of it does not load. A pack type that takes the prefix ai does not load either. An instruction block turns on no store feature. Like every content type, instruction also takes planned and since. rdy_instructions still delivers every landed instruction, whatever its as-built status, because the status changes only what a publication shows.

since 0.48.0

Every pack also holds the engine type repo_link, with the prefix rl, and a pack that declares it does not load. It is a supporting type with no body, no traits and no key, and it sits directly under a doc. Its fields are:

  • alias, [a-z][a-z0-9-]{0,23}, unique among the project's live repo_link blocks;
  • repo, the cited project's repo id in 32 lowercase hex digits, never the project's own;
  • profile, the block id of the link's publication profile in the cited project, a pf- id;
  • title, optional.

A bad value is E_VALIDATION, repo link <alias>: invalid alias, invalid repo id or invalid profile id, with the fix correct the repo_link block: rdy_write / rdy edit. A repo_link block owns the foreign entries whose repo and publication.profile equal its fields. It turns on the store feature foreign_copy.

since 0.28.0

Every pack also holds the engine types finding (prefix F) and source (prefix S), both always supporting and informative. A finding holds statement and evidence, and a source holds title, kind (release, commit or spec), locator and an optional version. The engine adds both to the children of every type that lists decision. It also sets the children of folder to folder, doc, decision, question, finding and source, whatever a pack lists. A pack may omit or repeat their core fields, and it may add optional fields. Any other change does not load: pack <p> cannot redefine <type> (<what>); it may only add optional fields, where <what> is prefix, children, body, traits or field <name>. A pack type that takes the prefix F or S does not load, and the store format does not change for them.

since 0.32.0

A doc type's skeleton is a list of {title, required} sections. An area's paths are globs over folder and doc paths. The tension kinds are edit_collision, fork, premise_shift, area_overlap, duplicate_definition, unjustified_change, deprecated_reference, value_disagreement and restatement_drift. edit_collision, fork, premise_shift and unjustified_change default to blocking. duplicate_definition and value_disagreement default to blocking in stable content and advisory in draft. The rest default to advisory. In stable content unjustified_change stays blocking whatever the pack sets: an entry that lowers it gets W_PACK_SEVERITY when the pack loads.

since 0.33.0

The coverage section has four keys, and each is optional:

  • weights maps each dimension, grounded, consistent, current, connected, complete or governed, to a whole-number weight. A dimension that is not listed weighs 1, and 0 omits it from the overall score.
  • dismissed_weight is the percent of one check that a dismissed tension costs, from 0 to 100; default 50.
  • drift_threshold is the match percent at which restatement drift counts, from 1 to 100; default 60.
  • max_docs_per_level is the most docs one level holds directly before each gets crowded_level, from 1 to 100000; default 8.

A number out of range, every weight at 0, or an unknown key makes the pack invalid. A pack that extends another overrides each weight and number it sets.

YAML
name: acme-docs
version: "0.1.0"
extends: rdy-standard
areas:
  payments:
    description: money in and out
    paths: [wallets, payments/**]
tensions:
  deprecated_reference: blocking

since 0.32.0

The pack key rules holds at most 64 rule checks. Each rule has name, select, require, severity, message and fix. name has 1 to 64 characters with no space at either end, and it is unique. select and require are filters in the grammar of rdy_query. severity is advisory, the default, or blocking. message and fix each hold 1 to 2000 characters. A block that matches select and fails require raises the rule.

since 0.32.0

A pack that extends another takes the parent's rules, then its own, and a name used twice stops the pack from loading. So does a bad expression, an unknown key in a rule, or a rule that reads fields.decided_at in a test or in has. The landing sets that field, so no rule can judge it before the landing. rdy q still reads it. The errors are in Errors and warnings.

since 0.48.0

The pack key tensions_across maps a tension kind to blocking or advisory for tensions across projects. Across projects every kind is advisory unless this key raises it. Its keys are the five kinds that apply across projects: duplicate_definition, value_disagreement, restatement_drift, deprecated_reference and premise_shift. Any other key, semantic included, warns with W_CONFIG_UNKNOWN: pack <name>: tensions_across has no kind "<k>"; rdy ignores it. That kind stays advisory. The tensions map refuses an unknown kind, so the two keys differ.

A snapshot of rdy documentation at v0.53.0.