The recs files are skills for coding agents. The agent keeps each decision about your system as a short, numbered record, and writes the code from those records. The records persist between sessions; the agent's context does not.
A borrower wants to keep a book longer. These are the records that govern the renewal, and the code and test that cite them.
2a. The book is reserved
Library refuses with MSG-4: A reserved book cannot be renewed; the use case ends
2b. The loan is overdue beyond the grace period
Library refuses with MSG-5: An overdue loan cannot be renewed; the use case ends
# F-12 §2: A borrower can renew a loan return refuse(:msg_4) if loan.book.reserved? # F-12 §1: A borrower can renew a loan loan.due_on = Date.today + loan.period
# F-12 §2: A borrower can renew a loan
assert_equal "A reserved book cannot be renewed",
renew(reserved_loan).message
Agents write code faster than anyone documents it, and the reasons behind it are the first thing lost. The recs files store those reasons as records. When a new record contradicts existing sentences, in other records, in skills or in code, the agent finds each one, proposes its replacement, and lands the record and the replacements in a single commit.
If you know event sourcing, you know this shape. Records are appended in order and never rewritten in substance; a new decision on the same question is a new record that supersedes the old one. Fold the records of one category and you get its projection: the titles of every active record. The projection is what the agent reads.
A projection costs one line per record, so the agent can read all of it at the start of a task. From the titles it picks the records that bear on the work and opens those files, and only those. Context goes to the decisions in play, at the depth each one needs.
Newspapers write in an inverted pyramid: the headline, then the essential facts, then the detail. A reader can stop at any point and still have the story.
Records follow the same structure. A record's title states its decision, so a reader who stops at the projection already knows the substance. The record file holds the detail, and the knowledge base holds the sources the idea came from.
“Reversible summarization at multiple zoom levels. Compress context without losing the ability to expand back to full detail.”
User workflows follow Alistair Cockburn's use cases. Each states one actor's goal, a main success scenario in numbered steps, and extensions keyed to the steps where things can go differently. Each also states two guarantees: what holds even when the workflow fails, and what the actor gets when it succeeds.
The vision states what the system is for, and the ubiquitous language defines the words of its domain. Each user workflow is a hub: it names the features it reaches, the messages its actor can meet, and the terms it uses. Start from a workflow, follow its references, and you have what the system does for that goal.
Run recs-kickstart in a project that has code but no records. The agent reads the project and proposes records one category at a time, titles first and then bodies. Nothing is written until you approve each batch, and your code is left untouched.