VIEW THIS AS

Auto mode follows the Route Engine until you choose a viewpoint.

YOU ARE HERE

ROUTE CHECK

CONNECTED TO

WHAT NEXT

Use the canonical route for this room, or HELP if you are unsure.

Vocabulary Coding and Engineering | The Semantic Stock–Flow Contract: Why Adding Everything That Happened Does Not Tell Us What Exists Today

Two university researchers connect source data and plotting steps to a matching validated chart and caption checklist.

A system can record that one hundred requests were received, eighty were completed and twenty were pending, while another report records a hundred and twenty pending requests across several dates. These quantities cannot be compared responsibly without knowing which are events during an interval and which are states at a point in time. Vocabulary Coding and Engineering proposes a Semantic Stock–Flow Contract: preserve the distinction between an accumulated state, the changes that affect it and the accounting relationship linking its opening and closing positions. This makes the vocabulary of growth, availability, progress and capacity more precise when intelligence is distributed across systems.

The IMF Government Finance Statistics Manual 2014, chapter 3, describes an integrated relationship between opening stock positions, flows and closing stock positions. The 2025 System of National Accounts continues the internationally agreed accounting framework in its specific statistical domain. The proposed eduKateSG contract borrows this distinction for fictional information and workflow systems. It extends the Semantic Quantity Kind Contract, not as an accounting standard or measured result, but as a bounded research direction for preserving the meaning of change.

  • Identify whether a measure is a stock at a specified time, a flow over an interval or a rate of flow.
  • Preserve the entity, scope, units, opening and closing times.
  • Account for additions, removals, transfers and other legitimate changes separately.
  • Do not add repeated snapshots to obtain a count of distinct entities.
  • Keep gross and net changes distinct.
  • Record unexplained residuals rather than manufacture balancing events.
  • Investigate whether an apparently successful balance preserves the correct underlying identities and statuses.

Chapter index

1. What exists and what happened

A library has a collection of books at a particular time. During a month, books enter, leave or change classification. The number of books in the collection and the number received during the month answer different questions. Calling both quantities books is not enough to make them interchangeable. An AI should retain whether the value describes a position or a change. The distinction remains important even if the quantities share the same unit and can participate in a legitimate balance calculation.

2. The accounting precedent

The IMF manual describes how a stock position at the end of an accounting interval is related to the opening position and the net flows affecting it. In its economic context, changes can arise from transactions and other economic events. The useful engineering idea is to specify the relationship rather than treat every change as a purchase or sale. Our proposal applies that discipline to bounded fictional systems. It does not establish compliance with national accounting standards or determine the treatment of real financial transactions.

3. A worked fictional inventory

A storeroom starts a day with 100 items. Thirty items are received and twenty leave. Five further items are removed from the count following a separately documented classification correction. Under these stipulated conditions, the closing recorded inventory is 100 plus 30 minus 20 minus 5, or 105. The net change is five items. The total received is thirty, not five or 105. The correction is not necessarily a physical movement. These are invented figures used to illustrate different meanings of the same counting unit.

4. What the balance does and does not establish

Suppose the actual closing record instead reports 107. There is an unexplained difference of two items relative to the stated opening position and changes. The difference does not establish theft, an additional delivery or a counting error. Those are possible explanations requiring evidence. Record a residual and investigate the relevant source relationships. The Reconciliation Ledger helps distinguish an observed difference from a proposed adjustment. An arithmetic identity should guide investigation rather than provide a reason to invent whatever event would make the numbers agree.

5. Net change is not activity

A fictional queue receives 500 new requests and completes 500 during an interval. Its net change attributable to those two flows is zero. That does not mean nobody worked or that no requests arrived. Conversely, a small net increase could conceal substantial activity in both directions. Preserve the gross additions and removals alongside the net result. A description of a stable stock is not a description of an inactive system. This distinction is important when an organisation interprets productivity or workload.

6. A snapshot cannot be added like a flow

Imagine an archive has 100 documents at the end of Monday and 110 at the end of Tuesday. Summing the snapshots gives 210 document-observations across the two snapshots, not necessarily 210 distinct documents. Much of the collection may be present on both days. To count unique documents across the interval, use appropriate identity and event evidence. To estimate an average stock, specify the observations, weights and method. The Semantic Join Contract provides complementary vocabulary for avoiding repeated counts of the same underlying entity.

7. Flow rate and accumulated flow differ

A fictional service processes ten items per hour at a constant rate for three hours. Under that assumption it processes thirty items. The rate is not itself the total. If the rate varies, a suitable time-weighted calculation or event count is needed. Preserve the interval, unit and assumptions behind the operation. Do not assume a reported peak rate was sustained for the entire period. The Quantity Kind Contract distinguishes the two measured quantities; the Stock–Flow Contract identifies their roles in a changing state.

8. Time boundaries determine membership

A completed event at the boundary of two reporting periods must be assigned according to the specified convention. If both periods include the same endpoint, double counting may occur. If neither includes it, an event can disappear. Specify relevant time zones, timestamp precision and interval conventions. The Temporal Join Contract helps identify the applicable source record at a declared cutoff. Do not assume that the event’s occurrence, its recording and its later review share one timestamp or belong to the same reporting period.

9. Transfers across system boundaries

Suppose ten fictional items move from room A to room B. A’s stock falls by ten and B’s rises by ten, if the movement is complete and both positions use consistent counting rules. For the combined two-room collection the transfer alone changes no total. For either room it matters. Define the boundary and the relationship between movements before aggregating. A record of dispatch may not yet establish receipt. In-transit items and unresolved events should remain visible when the actual workflow requires their reconciliation.

10. Changes that are not physical flows

A monetary value may change because the valuation basis changes while the physical quantity remains the same. A document may be reclassified without being removed from storage. A review status can change without creating a new document. The proposed stock-flow record distinguishes physical movement, value changes and classification changes rather than compressing them into one category. The Allocation Crosswalk can document estimated redistributions across changing classifications. The relevant accounting relationship depends on the quantity kind, domain and intended state being measured.

11. A pending request can change status

A submitted request may be admitted, reviewed, completed or closed unresolved. A queue of pending admitted requests is a stock defined by its membership conditions at a particular time. Admission and legitimate closure affect that stock. The number of generated messages is a different flow. The earlier Backpressure Contract explains the capacity problem; this proposal adds a general accounting discipline. A closure must not automatically count as successful completion. Preserve each disposition and the evidence that establishes it.

12. The proposed stock-flow record

Record the state quantity and unit, entity or collection scope, membership rule, opening and closing cutoffs, observed positions, relevant event identifiers, change types, signs, quantities, valuation or classification basis and unresolved differences. Preserve the evidence source and version for each observation. State whether the relationship is an exact invariant under a declared model or an approximate comparison of measurements. These proposed fields do not themselves establish that all flows have been observed or that the recorded closing position is correct.

13. Zoom 0: the learner’s vocabulary

A learner can fill a fictional container with counters, remove some, and compare the opening and closing counts. Ask the learner to identify the starting quantity, added quantity, removed quantity and final quantity. Then introduce repeated observations and ask why adding both snapshots does not count distinct objects. These exercises develop the words stock, flow, net, gross, total and interval through concrete relationships. Use new reviewed examples to examine transfer. No claim about broad learning outcomes follows from one illustrative exercise.

14. Zoom 1: household planning

A household can distinguish its available supplies today from items bought during the week. If the opening quantity, purchases, consumption and other changes are known, it can calculate an expected remaining quantity. Actual observations may reveal a difference. An assistant should state which information is measured and which is estimated, rather than assume that an unrecorded use must have occurred. The same discipline helps distinguish a current balance, cumulative contributions and changes over a period. Calculations do not authorise purchases, transfers or changes to private records.

15. Zoom 2: organisations and operational knowledge

An organisation may need to know how many cases are outstanding, how many were opened and how many were resolved. A high number of newly opened cases does not necessarily mean a backlog has increased if a sufficient number were legitimately closed. Conversely, many reported closures may not establish successful outcomes. Preserve membership, transitions and the actual observation boundary. Use appropriate domain review for consequential reporting. A semantic stock-flow ledger can make these calculations inspectable without claiming that the organisation’s data or procedures are independently validated.

16. Zoom 3: institutions and statistics

Public statistics may describe population at a point in time, movements over an interval or rates relative to a defined population. The relevant statistical framework and coverage matter. Changes in geographic boundaries or classification can affect comparisons. The proposed record should preserve those distinctions and identify where estimates rather than direct observations are used. Actual official statistics require their own standards and methods. An AI should not create unsupported population totals by summing snapshots or treat unexplained differences as evidence of a particular event.

17. Zoom 4: the Second Intelligence Pool

Specialist agents may produce, review, revise and reuse knowledge objects. A growing archive is not the same as a growing stock of independently validated capabilities. Define the membership of each stock: generated drafts, reviewed records, currently available methods or another specific category. Track the transitions that move records between them. The Claim Release Ledger and Review Independence Record remain essential. Counting every generated interpretation as validated intelligence would change the meaning of progress without corresponding evidence.

18. Zoom 5: civilisation over time

A civilisation inherits buildings, methods, institutions and records while also losing, revising and creating them. A description of its accumulated resources should not be confused with a measure of current activity. Portable civilisation requires knowledge of the state, the flows affecting it and the scope of each recorded measure. Later researchers may reconstruct portions of those relationships using preserved evidence. They must retain uncertainty about unavailable events and changing definitions. No universal law of intellectual growth follows from a simple accounting equation.

19. A second fictional example of capacity

A review service begins with 25 pending admitted items. During a specified interval it admits 15 new items and completes 18. Two additional items are legitimately cancelled. With no other changes, the pending stock ends at 20. The successful-completion flow is 18, the total closure flow is 20 and the net change is minus five. If the service reports only the 20 closures as successes, it misrepresents the cancellations. All numbers are fictional. The example connects the accounting identity to the vocabulary of legitimate dispositions.

20. Cumulative counters require reset rules

A machine or software service may expose a cumulative counter that normally increases but can reset when restarted or replaced. Subtracting successive readings can estimate an interval flow only under suitable assumptions about resets, identity and recording. A lower later reading does not automatically establish a negative physical flow. Preserve evidence of the relevant reset or changed instrument. The Recovery Witness and Session Continuity Contract can identify circumstances in which earlier and later readings may not be directly comparable.

21. Proposed fixtures for change accounting

Prepare six fictional cases: a normal opening-to-closing balance, an unexplained residual, offsetting gross flows, repeated stock snapshots, a transfer across two boundaries and a classification change with no physical movement. Include a cumulative counter reset. Specify the expected quantities and dispositions before evaluation. Independent review should examine whether the source definitions make the calculation appropriate. These fixtures have not been executed here. They are designed to test preservation of accounting meaning rather than merely the ability to perform addition and subtraction.

22. Preserve the balance and the evidence

A useful report states the opening quantity, observed additions and removals, other established changes, expected closing quantity and actual observed closing position. Where evidence is incomplete, label the calculated position accordingly. Do not declare the collection reconciled solely because a residual is zero. Equal totals may conceal offsetting record discrepancies. Use the Reconciliation Ledger to investigate underlying identities and the Production Attestation to document how the calculation was made. The two properties are related but not interchangeable.

23. Appropriate authority and uncertainty

A mathematical balancing relationship does not justify accessing private records, modifying the source or deciding that a particular person caused a discrepancy. Use authorized information and proportionate safeguards. When measurements have uncertainty, the comparison may require a suitable statistical or technical method. Preserve that uncertainty and the applicable units. Synthetic cases provide a legitimate way to investigate the distinctions before real use. Any consequential accounting, engineering or institutional application needs appropriate professional and operational review.

24. A proposed four-week programme

Week 1: define a harmless fictional stock, its membership rules and permitted changes. Week 2: write reviewed interval, transfer, reset and residual fixtures. Week 3: if an implementation is available, compare its observed calculations and dispositions with independent checks. Week 4: report the actual evidence and limitations, and revise the specification. These steps describe a possible research programme, not work completed here or a guarantee of system performance.

25. Questions every reader should ask

Does the quantity describe what exists at a time or what happened during an interval? What is included in the state? Which events add or remove members? Are changes gross or net? Did a transfer cross the chosen boundary? Was the quantity revalued or reclassified? Does the opening position plus the recorded changes agree with the closing observation? These questions transform a report of growth or progress into an inspectable quantitative claim. They help identify when the intended comparison requires more evidence.

26. The next engineering step

Connect the Stock–Flow Contract to Quantity Kind, Temporal Join, Allocation Crosswalk, Backpressure and Reconciliation. Build a small reviewed set of state-change traces that distinguishes observed positions, estimated changes and unresolved residuals. The present article proposes the vocabulary and synthetic cases; it does not claim a new system or independent findings. The next companion question concerns the order of quantitative transformations: when can two operations be reordered without changing their meaning, and when does the sequence itself become part of the knowledge that must travel?

Technical references

Research status: stocks, flows and integrated accounts are established concepts in specified statistical and accounting frameworks. The Semantic Stock–Flow Contract is a proposed vocabulary-engineering extension. All worked data and cases are fictional. No new implementation, financial finding or independent empirical validation is claimed.

Continue the current series: Semantic Transformation Order Contract · Semantic Reconstruction Contract