Realm Ledger

A system, partly mechanical, partly magical, and partly run with light, that records transactions – the parties, what was bought and sold, costs, quantities, eventually delivery data – all coded. Each buying or selling entity, each good or service, each address, has a unique code. The realm runs this for everyone for free in order to get the insights the aggregated data yields, and because it makes commerce more efficient (and, hence, makes everyone more prosperous, one of Victory’s great goals). 

Daily transactions are aggregated into daily reports, which in turn are aggregated into shift-round reports, then shift-cycle reports, then half-season, season, and year. Uses a combination of punched cards, punched tapes, and physical accumulators (odometer-style) for the larger entities. Very small accounts, like the individual accounts of people who don’t transact large volumes or sums, are aggregated by neighbourhood. 

If the daily entries are missed for some reason, it throws the whole system out of whack until the clerks catch up. 

In contrast to our world, all accounts have a “rolling balance”; nothing is zeroed at the end of a period. A financial picture is always at a given date, and because the system works in near-real time and includes predicted future events, it’s possible to have a meaningful current, or even future, set of numbers (though there’s the concept of a “firm numbers date” which will always be in the past). Eventually, calculations become sophisticated enough to adjust future positions based on past performance, with reasonable accuracy. 

Asset accounting is also different; though the concept of depreciation exists, it’s not as emphasised, and instead there are formulas to calculate the contribution of an asset to earnings and compare that to its cost. This is regarded as the most interesting thing you can know about an asset, though working it out can be a black art; the basic idea is that each asset involved in creating something of value is assigned a proportion of that value, with overhead items, like buildings, being assigned a fixed proportion and assets directly involved in production, like a specific machine, being assigned a value based on the increase in value between the item that enters and the item that leaves. This is also used to calculate the machine owner/operator’s income, where that model is used. 

Absentee or uninvolved owners (shareholders) are not a concept with much traction. The model is either that capital is loaned on a participatory basis (that is, the amount of value it assists in generating is calculated, and the lender is repaid proportionately) or a flat basis (with a fixed interest rate and no participation in profits – tends to be used when profits are less predictable); or else ownership is by management and/or workers. Lenders have limited, and mostly informal, influence over the enterprise; if the management messes up the profitability, the lenders won’t lend to the enterprise again, and it may find that its flat-basis rate or base rate for borrowing has risen. 

Companies can own each other in whole or in part, but the ultimate officers must be traceable, and a company which only owns other companies is investigated more closely. 

Lending is either for capital investment, where the participatory rate is based on the contribution of the asset(s) purchased with the capital to future earnings, and the participatory payouts continue after the principal has been repaid; or for operational purposes, which is usually on a flat basis, but can be participatory if the enterprise anticipates high profits from operations relatively independent of assets (for example, a service business). 

Some businesses have “repeaters” set up in their offices to show their key numbers changing on accumulators which echo the ones at the Ledger. An important machine might have a repeater set over it as well, with its purchase cost, lifetime maintenance and refurbishment costs, and lifetime profits shown. Celebrations may be held when the machine pays for itself. 

Standard accounting practice has always been to have a page, or a spread, of a ledger per day (or less in very busy businesses), and to enter expected transactions on future pages to aid in planning. This is embraced and extended, with reports showing future predicted cash position. 

Subscribers can request reports about their own activity, and about (aggregated and anonymized) activity in their industry. Publications like the Commercial Gazette can also request aggregated data, and of course the Clerks have access to answer questions at an aggregated level. 

Eventually can be used for quoting (RFQs sent out to everyone who supplies a certain good or service), and government consultation (we’re proposing a new law about the shipping of livestock; who does that affect?) Carefully set up so that nobody can use it to gain commercially sensitive information – printouts are made face down and folded with only a destination code on the outside. But people are constantly trying to get around these protections, and sometimes they succeed. 

There’s a special group of clerks, later spun off as the Realm Audit Office, who search through the data for suspicious activity, and can get specifics if they can show that a crime is probably being committed. It’s possible to detect extortion in a poor neighbourhood, for example, by looking for unexplained money leaks from small businesses in the same area, and corresponding unexplained income by local hoods. This involves the ability to map businesses and people, which the Ledger supports through a standardized addressing convention also used in freight and post delivery and the navigation of skyships. To retain anonymity as much as possible, analysts who live in different cities from the businesses being analysed do the initial work.

Companies whose patterns of activity differ too much from the norm, or are too perfectly average, or don’t conform to Benford’s Law; facilities that don’t exist; employees that don’t exist, or have criminal records, or don’t live near their supposed workplace; profits that seem to appear from nowhere; companies which claim to be selling goods to each other but don’t appear to be shipping them in between; charities with a lot of money flowing through them – all of these can be looked at in an anonymized way before calling for a warrant. The clerks concerned wear little skull pins to show their successes in bringing down malefactors, with the materials of the pins reflecting the magnitude of the fraud (copper/silver/gold). 

The major problem they face is that the dwarven banking system is still operating, and used by two main groups: criminals, and conservative Golds and High Silvers who don’t trust the Clerks. (The two groups have a certain amount of overlap, but are not identical.) Whenever money vanishes into or appears out of the dwarven banks, it’s subjected to extra scrutiny. Anyone who’s using large amounts of cash is almost certainly a criminal; money laundering abounds, because large cash amounts entering the system are also closely scrutinized. 

There’s also the strategy of moving the money out of Koslin and back in again at a different point, since the system only extends within the realm – though there are negotiations to change that, too. Only the western realm, of the various bordering areas, has a sophisticated enough banking system to achieve this at scale, and the Realmgolds are quietly promoting reform there – including welcoming the heir, and other highly-placed young people, to be educated in Koslin. As they’re winning there, though, the east starts opening up and the problem moves. 

The machinery for the Ledger is housed in several enormous buildings, one in each province (which also stores copies of the neighbouring provinces’ data, for security). 

Creates a whole industry of clerks who can enter and interpret the data. UI nightmare, especially at first. Output is on “slates” that have physical, hard-wired letter/number elements in a 64w x 128h grid (typically); the numbers physically rotate by 45%, and each element has a set of (effectively) circuitry that interprets the signals from a single punched character into illumination of the correct parts of the letter/number. Input is by keyers as discussed elsewhere, and by readers that read punched cards or tapes (for greater data entry accuracy). 

Programming

To create a data card or data tape, you can fill in a form in a specific template and run it through (effectively) a scanner which translates the letters and numbers into their punch card equivalents. This is what happens when elite bureaucrats design an information system: input is form-based. 

A program (known as a “sequence”) consists primarily of a series of instructions to write certain values to certain accumulators. Each accumulator has an audit tape which records the balance before the transaction, the ID of the accumulator with the balancing transaction, the ID of the accumulator with the originating transaction, the ID of the program that is writing the value, the value being written, and the timestamp. These are archived every 32 days and randomly checked for integrity. 

Programs can reference accumulators via relative reference, based on the business partner involved. Since the schema is common, and there’s a hierarchy of accumulators, there’s a “failure mode” setting which is usually set to “write to parent accumulator” if the business concerned doesn’t have that specific accumulator. The machine will traverse the hierarchy upwards until it finds a valid accumulator to write to. 

In theory, for example, each item that can be bought and sold has its own accumulator for each business that buys or sells it, but in practice it is usually tracked at a higher, aggregated level in the hierarchy, unless it is a key item for that business and they want to track it individually. 

Printed reference books set out the accumulator hierarchies, the meanings of various processing codes, etc.

Reports usually work off the accumulators’ audit tapes, since locking all the accumulators in order to run reports is a drastic measure; if a business wants up-to-the-minute reporting, they use echo accumulators slaved to the primary ones. The current day’s tapes can’t be used, since they are being written to, so reporting is generally one day in arrears. 

There is a brief shutdown of data entry just before midnight, to allow semi-automated systems to change tape spools. 

As well as ledger accounts, which are the heart of the system, there’s also a concept of a document, which has a unique number, a document type, and a status, and which, depending on its document type, writes certain values to particular accounts when it reaches a new status. This definition is held in a program for each document type. 

Adding functionality to a program – for instance, updating registers which are used by transport providers to plan and control shipping – basically means adding further updates to additional accounts at given statuses. 

There is basic if-then logic, basic foreach and while looping, and basic error control. 

Documents have their own set of registers, with the reference code for each register being reassigned to a new document number when a document reaches its “closed” status. The next opened document will then pick up on the same physical register. 

Documents have sub-entries, held on cards; all current documents are held in a card repository, which automatically locates a card when the related document changes to a status where the sub-entries are required and sends it through a read head, so that the values required by the program can be retrieved. Example: a trading document which holds item-level data. The register holds the retrieval location for a primary card, and the primary card holds the location for any secondary cards (a later enhancement). 

Because both the sale and the purchase are held in a single system, it’s not necessary to have separate sales orders and purchase orders; the one implies the other, so both sets of information are kept on the same document, known as a trading document. There are also ledger transfer documents for moving accounting entries around for things like wages, rent, and other instances where no physical goods are being transferred. 

Alongside trading documents, there are also shipping documents (the next stage developed), which refer to trading documents. This enables the whereabouts of items ordered to be tracked. With the navigation system providing a unified location schema, and more and more transport using the navigation system, it’s possible to know exactly where many items are at any given time; it’s also possible to analyse the movement of specific types of goods through the realm in order to optimise transport. 

It becomes a mark of a large, wealthy company that their headquarters includes a large map showing their facilities and the goods flowing to and from them in real time. Typically, this map is in their main foyer, in a two- or three-story space viewable from the executive offices. 

Documents can hold text as well as numbers, in defined places (= fields) which can be read out from associated cards. Since typesetting was an early application of the technology, recording and outputting text are well-solved problems. This can include information such as human-readable contract data, notes and instructions, or more detailed descriptions of items being shipped. 

Pictures, being a lot more information-intensive, are not well supported. However, a standard set of pictographs developed for the illiterate is among the character sets provided, along with Dwarvish numbers and letters, punctuation marks, Elvish numbers and letters, mathematical symbols, and magical symbols. There is an effort to encode gnomish gesture language (think emoji), though it faces issues of complexity. 

Basic screens only show Dwarvish numbers and letters through a fixed set of display elements. More sophisticated screens can use dots (=pixels) to display not only those, but also the other symbol sets. This obviously requires a much larger and more expensive machine, since the dot pattern for each symbol must be stored in a way that can be accessed rapidly enough that the operator doesn’t experience excessive lag. 

The celebrated and wealthy mage Hope at Merrybourn came up with a way to produce coherent (laser) light, and the inventor Branch Heathlake used this, with the already existing glass cable, to make a standard square element with multiple cables in a matrix of various sizes (the absolute minimum being 8×8, but going much higher), with controllers that would accept a character code and switch the correct elements of the matrix on or off. He then shone the light through lenses of the appropriate size to project it either on the back of a treated piece of glass (instead of a terminal screen with an array of individual mechanical elements), shrunk down to take up 1/64th of the width, or else on a large wall screen such as a map. For maps, the projection elements behind the lenses also move in two degrees of freedom, and the lenses are ground to compensate for the different angles and reduce character distortion (or use prisms?)

The translator unit accepts a character code and a screen address. Based on the character set, the information is routed to one of several lookup tables, which returns the on/off settings for each pixel in the display matrix (an adaptation of Rosie’s design for the multiplication tables). Those settings are then sent to the designated screen address. 

Terminals

Terminals are, of course, text-based, with a matrix that displays characters in a fixed width (normally 64 characters across) and height. These consist of a number of smaller elements which can be lit up or not. A keyer and a scanner (and, naturally, a farwriter unit) are connected to the terminal, and it can be used to set up documents or reports, to retrieve them, and to modify them in accordance with the rules of their document type, based on a combination of user group membership and status. Users log on with their thumbprints – the universal means of identity verification – and matching punched cards, which for secure systems are kept locked up outside of working hours and delivered pneumatically to the workstation when the operator thumbs on. 

Once the operator has thumbed on and slotted the card, the terminal itself is treated as having the relevant user group membership; a register inside it is set to a code which it sends along with each outbound transmission. This is a vulnerability that could be exploited if someone was sophisticated enough to be able to modify the terminal to capture a login by someone with higher authority and re-use it later; after this exploit was used and discovered, terminals had to be modified to send a code that hashes the user group membership with a changing code sent by the Ledger, and is only good for a single session. Once the user’s card is removed from the slot, the session is terminated, and it times out after a set period even if the card is still in place, whereupon the user must thumb back in again.

Documents are (in the third generation of the system) entered and retrieved using a form model. A form contains multiple fields of several different types: numbers; one or more of a list of values; locations (expressed as province/county/locality/Post Office address, convertible back and forth to a coordinate system based on aerial survey); dates; texts; identity and authorization (thumbprints, Gryphon Clerk seals, Realm Agent sigils, etc.). Text fields are searchable, but it takes a long time. The other kinds of fields are indexed in various ways, and you can do a kind of query-by-example from a terminal, first finding the relevant form/document. How much of the document you can see, and whether you can see individual documents or only summaries, depends on your access level. You can narrow down your search by making selections and seeing how many documents match them (behind the scenes, the machinery is locating document numbers that are in common between all of the selections), and once you have a reasonable number, the full data can be delivered to your terminal for further analysis and processing. 

The machinery holds “piles” of data – ordered lists of all individual form instances that have a specific value for a specific field, with a count that can be referenced quickly. These are held in various storage media; the aim is to have something that is quick to read and economical to write an extra value to. Since forms are given numbers in the order in which they are entered, the sorting takes care of itself; the first number will always be the lowest, and the last number the highest, unless something has gone wrong (in which case the pile is rewritten). A long paper tape for each pile that can be run back and forth, read through, and written to after the current last entry, plus a counter for each pile and an indicator of the pile’s value and form field ID, is the basic implementation. 

When multiple piles are to be compared, if the comparison is an AND and involves inclusion (“IN”), the smallest pile is taken as the starting point, and then the other piles are run through in order of size. At each stage, a tape is written which reflects the overlap. If the comparison involves a “NOT IN” (in our-world SQL terms; known as an exclusion), the largest pile is used first. This quickly gets to the intersecting set. Depending on the query, and the user’s access, the forms themselves or a summary of certain other fields on them will then be retrieved. 

Cards and Tapes

The cards and tapes are not actually punched, after the first few generations; they have increasingly tiny holes burned through them with lasers, and other lasers read the presence or absence of these holes. 

Working memory can be represented with mechanical accumulators, but these take up more space and are less reliable than the tapes (which have to spool, yes, but that’s not as prone to failure as small, precise mechanical components). 

Reusable, rewritable, non-mechanical storage is a holy grail, diligently sought by investigators at the Institutes, since the amount of paper the Ledger collectively goes through (even with the holes used being tiny) is large and ever-growing. Lights being lit or not lit is the most promising avenue for exploration, basically the displays at miniature scale (smaller than a person can easily read). This involves creating extremely fine glass fibers. 

Thumbprint Identification

The thumbprint readers do not just read the physical thumbprint; they are partially magical, and read, in a sense, the person via the medium of the thumbprint. This means that getting hold of someone’s thumbprint (which is not especially difficult) and somehow making a model thumb with it (increasingly easy with the proliferation of hardlac) would not enable identity theft. There is a kind of cryptographic hash of the thumbprint/magical identification which is both consistent and unique for each person, and can be checked against a list or a document (such as the person’s identifying card).

Personnel

Bright Tiler: assistant building manager for the New Koslinmouth Ledger.

Building Layout

In New Koslinmouth, a well-defended entrance leads to offices and meeting rooms, then, towards the back of the building, Operational Control (an office where sequencers and machine supervisors work); the totalizer room (where the active accumulators are; kept magically cooled); the punching room (where transactions are recorded onto paper tape and cards); roll storage; and the calculation room, a three-story-high space full of towering machines, almost half of it below ground level. A gallery runs around the calculation room.