Skip to content

Latest commit

 

History

History
105 lines (73 loc) · 5.79 KB

File metadata and controls

105 lines (73 loc) · 5.79 KB

Unit: The Known Value for Deliberate Emptiness

BCR-2026-001

© 2026 Blockchain Commons

Authors: Wolf McNally, Christopher Allen
Date: January 12, 2026

Abstract

This document defines Unit, the Known Value at code point 0, which serves as both a type and its sole inhabitant. Unit positively asserts deliberate emptiness—that a position carries zero informational content and must not be replaced with any other value. In Gordian Envelope, Unit enables envelopes whose meaning is conveyed entirely by their assertions, without requiring a subject identifier such as a DID or XID. This specification distinguishes Unit from null (absence) and Unknown (value exists but is not known), clarifying its role as a first-class semantic primitive for intentional vacuity.

Introduction

Programming languages and data-interchange formats have long grappled with representing "nothing." Most solutions conflate several distinct concepts: absence (no value is currently present), unknown (a value must exist but is not known), and emptiness (a value that deliberately carries no information). This conflation leads to ambiguity—does a null field mean the data was never provided, that it was intentionally cleared, or that emptiness itself is the only possible answer?

Type theory offers a cleaner distinction through the unit type: a type with exactly one inhabitant. Unlike null, which denotes absence, the unit value positively asserts that this position is occupied—by the unique value that carries zero bits of information. A function returning unit is not "returning nothing"; it is returning the only possible value of a type that encodes no choices.

Known Values reserves code point 0 for Unit, bringing this type-theoretic concept into the semantic layer. Unit enables structured data formats like Gordian Envelope to distinguish between "this slot is empty on purpose" and "this slot has and can have no meaningful value." The distinction matters: an envelope whose subject is Unit declares that its meaning lies entirely in its assertions, not in some missing identifier.

The Unit Type and Value

Code point 0 denotes Unit—a special entry that is simultaneously a class and its single inhabitant, written as the empty string in single quotes as for all known values:

''

Semantics:

Unit positively asserts that “nothing is or can be conveyed in this position.” It is not a stand-in for a missing, null, or still-to-be-determined value, nor a marker that something ought to or might be here later. By using Unit you are saying, precisely, that this position carries zero informational content, and that it would be incorrect to replace it with any other value.

Contrast this with 'Unknown' (codepoint 17), which indicates that some value exists but is not known, and with explicit null constructs (e.g., JavaScript or CBOR null), which signify absence rather than deliberate emptiness.

Language parallels:

  • Rust: both the unit type and the value are written ()
  • C / C++: the type void plays the same role in the type system, but there is no inhabitant value (functions simply return to the caller)
  • Java: the primitive return type void; boxed analogue java.lang.Void is a reference type whose only legal inhabitant is null
  • Python: the singleton value None, whose type is types.NoneType

Usage in Gordian Envelope

A primary use of Unit in Gordian Envelope is to represent the subject of the envelope when it is the assertions of the envelope that convey its entire meaning, and there is no obvious subject like a DID or XID about which to make the assertions. For example, an envelope that simply asserts isA: 'Person' and name: 'Alice' can use Unit as the subject, indicating that the envelope itself is conveying the information about a person without needing to identify a specific subject:

'' [
    'isA': 'foaf:Person'
    'foaf:firstName': "Wolf"
    'foaf:lastName': "McNally"
]

Note that the use of the subject Unit ('') here is a deliberate choice to indicate that the envelope is conveying information without a specific subject, rather than leaving the subject undefined or using a placeholder. Unit here conveys not that the subject is missing or unknown, but essentially that the envelope has and can have no meaningful subject other than the assertions themselves.

Unit in the envelope command line tool

The envelope CLI tool (verion 0.31.1 and later) supports Unit as a subject type:

ENV=$(envelope subject type unit)
echo $ENV
envelope format $ENV
envelope format --type diag $ENV

│ ur:envelope/aetdaowslg
│ ''
│ 200(0)

Using unit as a subject type is the same as using known 0:

ENV=$(envelope subject type known 0)
echo $ENV
envelope format $ENV
envelope format --type diag $ENV

│ ur:envelope/aetdaowslg
│ ''
│ 200(0)

To build the envelope shown above, you can use the following command:

ENV=$(
    envelope subject type unit |
    envelope assertion add pred-obj known 'isA' known 'foaf:Person' |
    envelope assertion add pred-obj known 'foaf:firstName' string "Wolf" |
    envelope assertion add pred-obj known 'foaf:lastName' string "McNally"
)
echo $ENV
envelope format $ENV

│ ur:envelope/lraeoyadcfastyoycfaswftpsoiogtiaglhsjzjzkkoycfasvetpsoiehgjljziywtehjzjk
│ '' [
│     'isA': 'foaf:Person'
│     'foaf:firstName': "Wolf"
│     'foaf:lastName': "McNally"
│ ]

Note: The example above assumes you are using envelope CLI version 0.31.2 or later, and that you have installed the JSON FOAF ontology in your local known values store in ~/.known-values/.