Language reference

Look up keywords, functions, operators and types using the search above. This reference uses the same local information as doc("name"). For explanations in context, read the Manual or Textbook.

Authored cards, Manual excerpts and extracted library notes are labeled separately. Extracted diagnostics describe individual call branches; they are not a complete specification. A reserved or registered name is not a promise of stability: experimental, retired and unimplemented surfaces retain their stated limits.

!

Operator / syntax

Postfix factorial, as in 5!. Logical negation is not or ¬. A bang may also be part of a function name such as reverse!.

!=

Operator / syntax

Value inequality, the counterpart of ==. Unicode spelling: ≠.

!==

Operator / syntax

Type-strict inequality: the negation of equal? / ===.

!~

Operator / syntax

Regular-expression non-match: subject !~ pattern returns a Boolean. See manual "regex".

#

Operator

# comment | #comment
Line comment — runs to end of line wherever `#` appears outside a string, glued or spaced, exactly like `//`. Prefix length `#xs` and the Issue literal `#123` are retired (2026-09-03): write `len(xs)`. Only the `#!` shebang on line 1 and the `#language` header pragma are read before the comment rule applies.

Examples

x: 5  # trailing comment

#----- section banner -----

len(xs)            # length (was #xs)

$

Operator

xs[$] | xs[$-k] | xs[i:$]
Last-index of the collection being indexed (1-based, equal to len(xs)). Only valid inside `[]`. `$5` is a money literal and `$name` is the identifier guard — those are not last-index. `for i in 1..$` is a SyntaxError; loop with an index as `for e at i in xs`.

Examples

"Julius Caesar"[$]       # "r"

"Julius Caesar"[8:$]     # "Caesar"

"Julius Caesar"[$-3:$]   # "esar"

xs[$-1]                  # second-to-last

%

Operator

number % number
Modulo (remainder) operator. Returns the remainder of dividing the left operand by the right. FLOOR-mod: the remainder takes the sign of the DIVISOR (integers and floats). Keyword aliases: `mod`, `modulo`. Prefix builtin: `remainder(a, b)`. Paired with floor division (`div` / `÷`) by the identity (a div b) * b + (a % b) == a.

Examples

100 % 7            # Returns 2

-7 % 3             # Returns -1   (sign of dividend, integers)

2 + 10 % 3         # Returns 3    (% binds tighter than +)

100 mod 7          # Returns 2    (keyword alias)

remainder(100, 7)  # Returns 2    (prefix builtin)

&

Operator / syntax

Take a reference to an assignable place, as in &x. See manual "Pointers" for references and dereferencing.

and

Operator

expression1 and expression2
Logical AND; aliases && and ∧. Skips the right operand for Boolean false on the left. Otherwise preserves multivalued logic dispatch; not an operand-returning or truthiness operator.

Examples

true and false

x > 0 and x < 10

'

Operator / syntax

Quote a word, as in 'name; also participates in character literals and quoted loop labels. These forms depend on context. See manual "Word" and manual "labels".

's

Operator

object's property
Possessive notation for property access

Examples

john's name

stock's price

car's speed = 60

(

Operator / syntax

Open grouped expression, function call, tuple or parameter list, depending on context; closed by ).

)

Operator / syntax

Close a parenthesized expression, call, tuple or parameter list opened by (.

*

Operator

number * number | string * number | number * string
Multiplication operator. For numbers: performs arithmetic multiplication. For strings: repeats the string the specified number of times.

Examples

5 * 3              # Returns 15

2.5 * 4            # Returns 10.0

"-" * 32          # Returns "--------------------------------"

"hello" * 3       # Returns "hellohellohello"

5 * "hi"          # Returns "hihihihihi"

"=" * 10          # Returns "=========="

**

Operator / syntax

Alternative spelling of exponentiation (^). See doc pow.

*=

Operator / syntax

Compound multiplication assignment to an assignable place. See manual "Compound assignment".

+

Operator

number + number | string + string
Addition operator. For numbers: performs arithmetic addition. For strings: concatenates the strings together.

Examples

5 + 3              # Returns 8

2.5 + 1.5          # Returns 4.0

"hello" + "world" # Returns "helloworld"

"Hello, " + "Alice!" # Returns "Hello, Alice!"

"" + "test"      # Returns "test"

"prefix" + ""    # Returns "prefix"

++

Operator / syntax

Recognized only to diagnose unsupported increment syntax. Write x += 1; ++x and x++ are not supported.

+:

Operator

element +: sequence | (+:)(element, sequence)
Prepends one element to a List or Array without modifying it. Retains the sequence kind; a collection element stays nested. List prepend is O(1) with tail sharing; Array prepend copies outer storage in O(n), sharing nested values and preserving explicit element constraints. Right-associative at the multiplicative cons band, above addition. Parenthesize arithmetic heads and mixed +: / :+ chains. Adjacent +: is reserved: write 2 + :x for get-word addition. cons remains List-only.

Examples

1 +: 2 +: `[]

(1 + 2) +: [4]

(1 +: [2]) :+ 3

+=

Operator / syntax

Compound addition assignment to an assignable place. See manual "Compound assignment" for supported targets and mutation rules.

,

Operator / syntax

Separator in argument lists, collection literals, patterns and other list-like grammar. It is not a standalone function.

-

Operator / syntax

Numeric subtraction, or unary negation. Use difference or \ for set difference. See manual "Operators".

--

Operator / syntax

Recognized only to diagnose unsupported decrement syntax. Write x -= 1; --x and x-- are not supported.

-=

Operator / syntax

Compound subtraction assignment to an assignable place. See manual "Compound assignment".

->

Operator / syntax

Thin arrow: a lambda in parameter position; otherwise a Pair, like =>. Bare x -> 2 is a lambda even if x was already bound; pair(x, 2) explicitly constructs a Pair. Also used in function types and dialect translation syntax. Unicode → is logical implication. See manual "Pair".

.

Operator

object.property
Dot notation for property access

Examples

person.age

stock.volume

vehicle.model = "Tesla"

.%

Operator

left .% right
Elementwise broadcast of %. Standalone Array operands have matching lengths, or one operand is a scalar. Dotted function calls use broadcast dimension rules. Connected dotted expressions fuse; an ordinary call is a boundary. See doc broadcast and manual "Broadcast".

.*

Operator

left .* right
Elementwise broadcast of *. Standalone Array operands have matching lengths, or one operand is a scalar. Dotted function calls use broadcast dimension rules. Connected dotted expressions fuse; an ordinary call is a boundary. See doc broadcast and manual "Broadcast".

.+

Operator

left .+ right
Elementwise broadcast of +. Standalone Array operands have matching lengths, or one operand is a scalar. Dotted function calls use broadcast dimension rules. Connected dotted expressions fuse; an ordinary call is a boundary. See doc broadcast and manual "Broadcast".

.-

Operator

left .- right
Elementwise broadcast of -. Standalone Array operands have matching lengths, or one operand is a scalar. Dotted function calls use broadcast dimension rules. Connected dotted expressions fuse; an ordinary call is a boundary. See doc broadcast and manual "Broadcast".

..

Operator

a..b | a..<b | a..b by s | a..b..±s | n..
The range literal — a first-class ORDERED Range value (type "Range"): it keeps direction (5..1 descends), takes an exclusive end (`..<`), a positive step magnitude (`by` — direction still comes from the operands; a..b..s spells the signed step), and an open-ended lazy form (`n..` — infinite, integer start). Membership is O(1); iteration (loops, comprehensions, map/filter/reduce, zip, enumerate, nth/sample/sort/min/max/sum/product) walks source order; set operations decay it to the Set of its points. Open ranges work with bounded consumers (first(n.., k), zip truncation, foreach + break, lazy comprehensions) and raise a catchable error from every materializer (sum/len/array/...). The end must sit on the SAME line as the `..`; in index position a[2..] slices to the end. Character ranges: "a".."e".

Examples

1..5              # 1, 2, 3, 4, 5   (type(1..5) → "Range")

5..1              # descending: 5, 4, 3, 2, 1

1..<5             # exclusive: 1, 2, 3, 4

1..10 by 3        # stepped: 1, 4, 7, 10  (10..1 by 3 → 10, 7, 4, 1)

first(2.., 4)     # open-ended, lazy → [2, 3, 4, 5]

3 in 1..10 by 2   # true — O(1), the step grid counts

array(5..1)       # [5, 4, 3, 2, 1] — materialize in source order

...

Operator / syntax

Ellipsis for finite or open set progressions, plus rest/variadic forms in their own grammar. It is not a universal call-spread operator; use apply where documented. See manual "ellipsis" and doc apply.

..<

Operator / syntax

Range with an excluded upper endpoint, as in 1..<4. Compare inclusive ..; see manual "ranges".

./

Operator

left ./ right
Elementwise broadcast of /. Standalone Array operands have matching lengths, or one operand is a scalar. Dotted function calls use broadcast dimension rules. Connected dotted expressions fuse; an ordinary call is a boundary. See doc broadcast and manual "Broadcast".

.^

Operator

left .^ right
Elementwise broadcast of ^. Standalone Array operands have matching lengths, or one operand is a scalar. Dotted function calls use broadcast dimension rules. Connected dotted expressions fuse; an ordinary call is a boundary. See doc broadcast and manual "Broadcast".

Operator

left .÷ right
Elementwise broadcast of ÷. Standalone Array operands have matching lengths, or one operand is a scalar. Dotted function calls use broadcast dimension rules. Connected dotted expressions fuse; an ordinary call is a boundary. See doc broadcast and manual "Broadcast".

/

Operator

numerator / denominator
Exact division of Integers/Rationals; whole results simplify to Integer. Float operands use floating-point division. Word form: rdiv. Use fdiv for explicitly floating division and div/idiv for floor division. A slash attached to a callable can instead introduce a refinement.

//

Comment

// comment through end of line
Line-comment spelling, like #. It is not floor division; use div or ÷.

/=

Operator / syntax

Compound division assignment to an assignable place. See manual "Compound assignment".

:

Operator

identifier: expression
REBOL-style assignment operator

Examples

x: 42

name: "Bob"

apple: a Stock { price: 150 }

:+

Operator

sequence :+ element | (:+)(sequence, element)
Appends one element to a List or Array without modifying it. Retains the sequence kind; a collection element stays nested. List append copies the spine in O(n); Array append copies outer storage in O(n), sharing nested values and preserving explicit element constraints. Left-associative at the multiplicative cons band, above addition. Mixed +: / :+ chains require parentheses. Adjacent :+ is reserved: write n: +3 for a unary-plus binding. Positive slice bounds xs[1:+2] keep their meaning.

Examples

[] :+ 1 :+ 2

`[1, 2] :+ 3

[1, 2] :+ [3, 4]

::

Operator / syntax

Type annotation, as in x :: Integer; also appears in parameter and result contracts. See manual "Type System".

:>

Operator / syntax

Relation-argument subcollection bound: an argument must name a Concept below the given bound. relation/strict enables enforcement. See manual "argGenl".

:man

REPL command

:man topic | :manual topic
Short REPL command for the embedded Manual. In source code use manual("topic"); bare man is not a source-level function alias. Searches locally without a model or network.

:manual

REPL command

:man topic | :manual topic
Short REPL command for the embedded Manual. In source code use manual("topic"); bare man is not a source-level function alias. Searches locally without a model or network.

;

Operator / syntax

Statement separator. A semicolon inside square brackets sequences statements; it does not join matrix rows. Construct matrices with matrix(rows).

<

Operator / syntax

Less-than comparison. In literal positions angle brackets also delimit natural-language text. See manual "Operators" and manual "Natural Language".

<-

Operator / syntax

Generator binding in comprehensions and supported iteration forms: x <- source. See manual "Comprehensions".

<=

Operator / syntax

Less-than-or-equal comparison (≤). Strict backward rules use <==, not <=.

<==

Operator / syntax

Strict backward rule: conclusion <== premises. See manual "Rules" for rule context, grounding and derivation.

<~~

Operator / syntax

Defeasible backward rule: conclusion <~~ premises. See manual "Rules" for defaults and the limits of the selected reasoning path.

=

Operator

variable = value | object.property = value
Assignment operator for variables and properties

Examples

x = 10

person.name = "Alice"

stock's price = 200

==

Operator / syntax

Value equality; numeric equality can compare different numeric types (1 == 1.0). Use === for type-strict equality.

===

Operator / syntax

Type-strict equality, the infix form of equal?: 1 === 1.0 is false.

==>

Operator / syntax

Strict forward rule: premises ==> conclusion. See manual "Rules" for derivation and grounding.

=>

Operator / syntax

Arrow for a lambda or match arm in that grammar; otherwise constructs a Pair. Bare x => body is a lambda; pair(x, value) explicitly makes a Pair from a variable. See manual "Pair".

=~

Operator / syntax

Regular-expression match: subject =~ pattern returns captures or none. See doc regex_match.

>

Operator / syntax

Greater-than comparison; also closes angle-bracket natural-language text. Context determines the grammatical role.

>=

Operator / syntax

Greater-than-or-equal comparison (≥). Ordering comparisons can form chains such as 0 <= x < 10.

?

Operator

cond ? a : b | ?X | empty?
Three positions, one glyph, no silent dual. Infix `cond ? a : b` is the ternary — the same IfExpression as `if cond then a else b`, right-associative, one branch evaluated. Prefix `?X` is a HiLog/POP-11 pattern variable; bare `?` is the anonymous wildcard. Glued to an identifier, `empty?` is the predicate suffix (a different token). `??` / `???` / `?.` win the longer token. Compact `n?1:0` is the identifier `n?`, not a ternary; compact `1<2?3:4` lexes `3:4` as Time. `axioma/beginner` refuses the ternary.

Examples

n > 1 ? n : 0

fib(n) = n < 2 ? n : fib(n - 1) + fib(n - 2)

empty?([])

?.

Operator / syntax

Safe navigation: none or om propagates through property access instead of causing an ordinary missing-receiver error. See manual "safe navigation".

??

Operator / syntax

None-coalescing: use the right operand when the left is none. Unlike ???, this does not also replace om.

???

Operator / syntax

Bottom-coalescing: use the right operand when the left is none or om (Ω). See manual "coalescing".

?ᵇ

Symbol

=== ?ᵇ (Glyph) === name: belnap_neither latex: belneither, gap category: mvl codepoint: U+003F meaning: ?ᵇ — Belnap B4 neither (the gap; ≡ belnap("neither"))

?ᵏ

Symbol

=== ?ᵏ (Glyph) === name: kleene_unknown latex: klunknown category: mvl codepoint: U+003F meaning: ?ᵏ — Kleene K3 unknown (≡ kleene("unknown"); om is the untyped K3 unknown)

?ⁱ

Symbol

=== ?ⁱ (Glyph) === name: g3_unknown latex: gunknown category: mvl codepoint: U+003F meaning: ?ⁱ — Gödel G3 unknown (≡ intuit3("unknown"); ¬?ⁱ = ⊥ⁱ — the intuitionistic collapse)

@

Operator / syntax

Universal sigil with context-specific introspection, splice and collection forms. For example @value inspects its type. See manual "sigil".

Array

Type

Messages: a push x / a append x / a add x / a pop / a clear — statement-position imperatives, in place, alias-visible (a place is commanded; a List is not) Bounds: unbounded; ordered, mutable, heterogeneous; 1-INDEXED — xs[1] is the first element Literals: [1, "two", 3.0]; a one-element array in branch position is [x,] (bare [x] there is a block); xs[2..3] slices (inclusive); negative indices count from the end Operations: + concatenates ([1,2] + [3] → [1,2,3]); xs[i]: v assigns, xs[i] += 1 compounds; in/∈ tests membership; == is structural Conversions: set(xs) dedups; array(s) back; zip flatten unique sorted reverse Related: len count first last push map filter reduce sum min max range(a, b) (inclusive) index_of contains enumerate group_by Accessors: .length .size .first .last .second … .tenth .empty (dot or possessive spelling) Test/annotate: xs is Array · xs :: Array

Boolean

Type

Values: true and false — the only two (singletons) Truthiness: false, none, and om are falsy — 0, "", {}, [] are all TRUTHY (test emptiness with .empty or len(x) == 0, never by truthiness) Operations: and or not xor implies iff (short-circuit and/or; glyphs ∧ ∨ ¬ → ↔ lex too); mixing with Kleene/Belnap/Łukasiewicz/G3 values dispatches into that logic's tables Related: designated(v) reads an MVL value's designation as a Boolean; expect(label, actual, expected) pins Booleans in tests Test/annotate: x is Boolean · x :: Boolean

Box

Symbol

=== □ (Glyph) === name: box words: necessarily latex: Box, square variants: ◻ category: modal codepoint: U+25A1 meaning: □p — necessarily p (alethic necessity; true in all accessible worlds)

Byte

Type

Bounds: bounded — 0..255, the one bounded integer type: Byte.bounded → true, Byte.min → 0, Byte.max → 255; byte(300) errors Construct: byte(n) / byte(0xFF) — no dedicated literal (b"..." is Bytes, a byte ARRAY) Operations: arithmetic widens to Integer (byte(200) + byte(100) → 300, byte(0xFF) + 1 → 256); bitwise band bor bxor bshl bshr between two Bytes STAY Byte (mod-256 world) Conversions: int(b) → Integer; hex(n) / bin(n) render digit strings; Byte.parse("255") / parse_as(Byte, "0xFF") read a String (0..255) Test: b is Byte

Bytes

Type

Construct: b"hi", b"\xFF\x00" (hex escapes); bytes("text") from a String Operations: + concatenates (b"ab" + b"cd" → b"abcd"); len(b) counts bytes; b[i] (1-based) yields the numeric byte value; == compares contents Conversions: bytes(s) from String; str(x) renders the display form Related: indexing Bytes composes with the Byte bitwise family Test: b is Bytes

Complex

Type

Construct: complex(re, im), or the unit im (= complex(0, 1)); prints as 3.0 + 4.0 * im. No juxtaposed literal: 2im is diagnosed, write 2 * im Operations: + - * / ^ == and unary minus; NO ordering (complex(1,1) < complex(2,2) errors). ^ is exact at integer exponents: complex(0,1)^2 → -1 Tower: top of the numeric tower — Integer, Float, Rational and Byte all embed, so complex(3,4) + 1/2 → 3.5 + 4.0 * im. Embedding is via float64, so exactness stops here: exact?(complex(1,0)) → false Related: abs is the modulus (abs(complex(3, 4)) → 5), real, imag, conjugate; sqrt/exp/log/sin/cos all accept a Complex Notes: the REAL spellings keep real domains — sqrt(-1) and (-1)^0.5 error and point at the opt-in: sqrt(complex(-1, 0)) → im Test: z is Complex

Diamond

Symbol

=== ◇ (Glyph) === name: diamond words: possibly latex: Diamond, diamond, lozenge variants: ◊ ⋄ category: modal codepoint: U+25C7 meaning: ◇p — possibly p (alethic possibility; true in some accessible world)

Dictionary

Type

Literals: {key: "value", n: 42} — string keys, bare or quoted; the EMPTY hash is dict() / dictionary() ({} is the empty set) Access: d.key and d["key"] read — a MISSING key yields none, not an error (default with d["zz"] ?? 0); d["k"]: v / d.key: v assign; d["k"] += 1 compounds Operations: len(d); == is structural; {k: v | x <- xs} dict comprehensions Related: keys(d) values(d) items(d) — sorted, deterministic; group_by(fn, xs) buckets Test: d is Dictionary

E!

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §3.1.1 Pattern binding (ML-style tuple patterns); read with manual "3.1.1" Excerpt: > Quantify with `forall` / `exists`, the glyphs `∀` / `∃`, the backtick > digraphs `` `forall `` / `` `exists ``, or `∃!` (unique existential). `E!` > (the free-logic existence predicate) is a separate token. > **There is no `:=`, and `let` is not an assignment.** Bind with `:`

Float

Type

Bounds: IEEE 754 binary64; a whole float stays a Float (type(2.0) → "Float") Members: Float.bounded → true, Float.max, Float.min_positive, Float.epsilon, Float.digits → 15; Float.parse("3.2") / parse_as(Float, "3.2") read a String Literals: 2.5, 6.02e23, 0x1p-1 (hex float: mantissa × 2^exponent), inf, nan Display: shortest unique decimal; whole values keep .0 (1.0 not 1); Inf not +Inf Operations: + - * / div % ^ and comparisons; == is exact IEEE equality — 0.1 + 0.2 == 0.3 is false (compare with abs(a - b) < eps); mixed Integer/Float arithmetic yields Float Conversions: floor ceil trunc round int — exact Integers at any magnitude (floor(1.0e30) is exact); round(2.5) → 3 (half away from zero), round(x, digits); float(n) / float("2.5") construct Related: sqrt exp ln log (natural) sin cos tan atan atan2 deg rad nan? infinite? finite? stringf("%.2f", x) for formatting Test/annotate: x is Float · x :: Float

Integer

Type

Bounds: unbounded — arbitrary precision; no maximum or minimum exists (memory is the only bound) Members: Integer.bounded → false; Integer.max / Integer.min → error (there is none, by design); Integer.parse("32") / parse_as(Integer, "32") read a String (whole-string consume; optional base) Literals: 42, -7, 1_000_000, 0x2A (hex), 0b1010 (binary), 0o52 (octal) — any number of digits (2^100 is exact) Operations: + - * div % ^ exact at any size; / is exact division (7/2 → the Rational 7/2, 4/2 → 2); band bor bxor bshl bshr; comparisons < <= == != >= > (2 == 2.0 is true) Conversions: float(n) (may round past 2^53), str(n), byte(n) (0..255 only), rational(n, d); int(x) truncates a Float exactly at any magnitude; Integer.parse("42") / parse_as(Integer, "42") are the strict string readers (int("3.2") still truncates a prefix — the readers refuse it) Related: abs sign succ pred divmod quotient remainder gcd lcm factorial even? odd? prime? min max sum hex bin random(n) Test/annotate: x is Integer · x :: Integer

List

Type

Spread: `[...xs] makes a List; [...xs] makes an Array (Array/List sources). Construct: `[] (empty) / `[1, 2, 3] (literal and display); list() remains supported; cons(x, l) / x cons l / x +: l prepend; l :+ x appends one value Semantics: persistent singly-linked cons list — immutable, structure-sharing. Array is a place, List is a value: it answers NO message verbs (l push 3 errors, teaching cons) — imperatives command places; a value's verbs are its expressions. The empty list is TRUTHY (a value, not a bottom) Operations: first(l) O(1) head; rest(l) O(1) SHARED tail; l1 + l2 concatenates (left copied, right SHARED; type-strict — List + Array errors); l[i] reads O(n) (a courtesy — l[i]: v errors); == is structural and TYPE-STRICT (list([1,2]) ≠ [1, 2]); [h | t] destructures in match/func/relation heads, tail SHARED Conversions: list(xs) / array(l) / set(l) / tuple(l) / stack(l) — round-trip at value level Related: map/filter/reverse/sort preserve List; len/empty? inspect; reduce folds Test: l is List · list?(l) / is_list(l)

NA

Value

Built-in NA value: na Manual §4.2 Missing data cells: `na` and `Na`; read with manual "4.2" Excerpt: ### Missing data cells: `na` and `Na` `na` is the missing-cell value; `Na` is its programming type. `NA` remains a compatibility alias of the same value. Values and DataFrames display it as `na`;

Null

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §4.3 Dual null types; read with manual "4.3" Excerpt: ### Dual null types Axioma has **two distinct null-like values** with different semantics — they are **not interchangeable**.

Omega

Symbol

=== Ω (Glyph) === name: omega words: om latex: Omega category: constant codepoint: U+03A9 meaning: Ω — the SETL undefined value

PHI

Symbol

=== φ (Glyph) === name: phi words: PHI latex: phi, varphi category: constant codepoint: U+03C6 meaning: φ — the golden ratio (1.61803…)

PI

Symbol

=== π (Glyph) === name: pi words: PI latex: pi category: constant codepoint: U+03C0 meaning: π — 3.14159… (ratio of circumference to diameter)

Rational

Type

Bounds: unbounded — exact Integer numerator and denominator Construct: division makes them: 7/2, 1/3 (no dedicated literal); rational(n, d) constructs; auto-normalizes (2/4 → 1/2) and demotes to Integer when whole (4/2 → 2) Operations: + - * / ^ stay exact (1/3 + 1/6 → 1/2, (1/3)^2 → 1/9); comparisons work; mixing with a Float leaves exactness (1/3 + 0.5 → a Float) Conversions: float(q) → 3.5; numerator(q) → 7, denominator(q) → 2 (for 7/2) Related: stringf("%.2f", q) formats through the numeric tower Test: q is Rational

Set

Type

Literals: {1, 2, 3}; {} is the EMPTY SET ∅ (the empty hash is dict()); {x | x <- xs, p} comprehensions; {2, 4, ..., 100} / {2, 4, 6, ...} ellipsis progressions Semantics: unordered, deduplicated; displays and iterates in sorted order (first({3,1,2}) → 1) Operations: union/∪ intersect/∩ \ (difference) symdiff subset/⊆ superset subsetneq supsetneq; in/∈ notin/∉ membership; == is structural Conversions: array(s), set(xs); bag(xs) for multisets with multiplicities Related: len first powerset emptyset; named infinite sets (naturals, evens, primes, …) Test/annotate: s is Set · s :: Set

Sigma

Symbol

=== Σ (Glyph) === name: sum words: sum latex: Sigma category: constant codepoint: U+03A3 meaning: Σ — summation

String

Type

Bounds: unbounded; UTF-8 — a sequence of CHARACTERS: len/length/size/count all count characters (len("héllo") → 5), as do s[i], .first/.last, and chars(s); the BYTE length is len(bytes(s)) → 6 Literals: "text" (escapes \n \t \" \\ \u{2203}), r"raw — no escapes", """multi-line""", "interpolation: ${expr}" Operations: + concatenates, * repeats ("ab" * 3 → "ababab"), comparisons are lexicographic; s[i] indexes 1-based ("hello"[2] → "e", negative counts from the end, s[2..3] slices); s =~ r"pattern" regex-matches (captures hash or none), s !~ r"pattern" negates Conversions: str(x) from any value; int("42") float("2.5"); Integer.parse / parse_as(Integer, s); chars(s) → character array; bytes(s) → Bytes; split(s, sep) → Array; str_join(arr, sep) joins back Related: upper lower trim contains substring replace reverse count index_of stringf chr ord Test/annotate: x is String · x :: String

TAU

Symbol

=== τ (Glyph) === name: tau words: TAU latex: tau category: constant codepoint: U+03C4 meaning: τ — 2π (6.28318…)

Time

Type

Meaning: signed relative time, measured in nanoseconds; not a time of day Literals: 1:30 (hours:minutes), 1:30:00, -1:30, 1:02.5 (minutes:seconds.fraction) Construct: time(seconds), time("00:120:00"), time(hours, minutes, seconds) overflowing minutes and seconds normalize; hours can exceed 23 Operations: Time +/- Time; numeric offsets are seconds; scale by a real number; Time / Time is an exact ratio (0:01 / 0:03 → 1/3) Conversions: float(t) gives seconds; int(t) truncates seconds toward zero Limits: signed int64 nanoseconds; overflow and division by zero are errors Execution: evaluator only; --vm explicitly refuses Time values and construction Related: DateTime is an absolute instant; Duration belongs to the datetime API

Tuple

Type

Literals: (1, "two", 3.0) — fixed-arity, immutable, 1-indexed: t[1] → first element Operations: len(t); == compares elementwise; destructures in bindings and comprehensions: a, b: (1, 2) · [x + y | (x, y) <- pairs] Conversions: array(t), set(t) Related: zip pairs elements into tuples; divmod returns a (q, r) Tuple Test: t is Tuple

[

Operator / syntax

Open an Array literal, index/slice expression or block, depending on context. A block sequences statements; it is not necessarily an Array. See manual "Blocks".

\

Keyword

\param => expression  OR  \(params) -> expression
Prefix lambda notation (Haskell-style). Creates a first-class anonymous function. Arrow can be `=>`, `->`, `→`, or `.`, and multiple parameters must be parenthesized.

Examples

\x => x * 2                   # Simple double function

\(x, y) -> x + y              # Multiple arguments

map(\(n) [n * n], [1, 2, 3])  # Block-bodied prefix lambda

]

Operator / syntax

Close the bracket-delimited literal, indexing expression or block opened by [.

^

Operator / syntax

Exponentiation: base ^ exponent. Integer powers can remain exact; operand types determine the numeric result. See doc pow.

`[]

syntax

`[expression, ...] | `[]
Constructs a persistent List directly. The backtick touches the opening bracket; no closing backtick is used. Empty, singleton, trailing-comma and nested forms are supported. Elements evaluate once, left to right, and each written expression contributes one value, including a Range or nested collection. Unlike quotation, names and calls are evaluated. The constructor cannot be shadowed. Lists print in this literal form and retain shallow immutability. Explicit ...xs elements spread an Array or List; ordinary elements remain nested. Plain [] is Array; [h | t] patterns are unchanged. This opener does not introduce List comprehensions, statement blocks, or new patterns. Evaluator and VM supported; HM inference remains outside its supported fragment.

Examples

`[]

`[1, 2, 3]

1 +: 2 +: `[]

`[1, 2] :+ 3

`name`

Operator

left `function` right   (matched pair of backticks)
Infix application: puts any two-argument function between its operands. Nothing to declare — `a `f` b` is a parse-time desugar to the ordinary call f(a, b), so f resolves however function position resolves it and arity, partial application, multi-clause dispatch, contracts and overloads all behave as they do for the prefix spelling. Precedence of *, left-associative. Note the CLOSING backtick: an UNPAIRED backtick is the unrelated glyph digraph (`in → ∈, `cup → ∪), and the two are told apart by shape alone, never by a name lookup — so a name can be a glyph and a function at once with no interference.

Examples

mysum(x, y) = x + y

3 `mysum` 4                  # → 7   ≡ mysum(3, 4)

5 `max` 3                    # → 5   builtins too

"hello" `contains` "ell"     # → true

3 `mysum` 4 * 2              # → 14  binds like *, left-assoc

3 mysum 4                    # → 3   WITHOUT backticks: three statements

a

Keyword

InstanceName: a ConceptName { properties... }  OR  InstanceName: an ConceptName { properties... }  OR  InstanceName: a ConceptName with slot: value, ...
Creates a concept instance with inline property initializers using natural language syntax. The brace block is canonical; `a ConceptName with slot: value, ...` is a provisional spelling of the same block (the list may continue after a comma).

Examples

myCar: a Car { brand: "Toyota", year: 2023 }

laptop: an ElectronicProduct { price: 999 }

bike: a Vehicle with wheels: 2, brand: "Brompton"

abductive

Keyword

Select abductive mode for a reasoning chain: seeking candidate explanations. A candidate explanation is not a deductive proof.

abs

Function

abs(x)
Absolute value (Integer/Float/Complex modulus); big-aware. Manual §13.1 Type names, `DataType`, and how `is` dispatches; read with manual "13.1" Excerpt: **Calls.** Prefer functions: `abs(5)`, `push(s, v)`. Unary method sugar already exists: `5.abs`, `[1,2,3].len` mean `abs(5)` / `len([1,2,3])`. True `Concept action` methods are for **entities**, not every primitive.

absent?

Function

absent?(value)
Test whether a constructor value has the Absent tag. This is a tag test; it does not unwrap or execute the contained value. See manual "Option" for Option, Result and Either.

accident

Ontological Logic

subject accident predicate
Accidental property operator. Expresses that a property is accidental, not essential.

Examples

Human accident Height

Book accident Color

accidental: Object accident Property

acos

Function

acos(x)
Arccosine, in radians. Manual §22.3 Mathematical functions; read with manual "22.3" Excerpt: | `sin(x)` / `cos(x)` / `tan(x)` | Trigonometry — arguments in **radians** (like Lua/C); convert with `rad`/`deg` | | `asin(x)` / `acos(x)` / `atan(x)` | Inverse trig, radians (`asin`/`acos` domain-checked). `atan(y, x)` 2-arg is the full-quadrant form (Lua 5.3+ `math.atan`) | | `atan2(y, x)` | Full-quadrant arctangent — the C/Python spelling of `atan(y, x)` (`atan2(1, 0)` → `pi/2`) | | `sinh(x)` / `cosh(x)` / `tanh(x)` | Hyperbolic functions | | `deg(x)` | Radians → degrees (`deg(pi)` → `180`; Lua `math.deg`) |

action

Keyword

Concept action name(params) [ body ]
Attaches a method to a concept. Inside the body, `it` refers to the receiving instance. Instances invoke it with dot-call syntax.

Examples

Airplane action describe() [ it.brand + " (" + str(it.engines) + " engines)" ]

plane.describe()

activate

Function

Call diagnostics (different branches may describe different overloads): • activate requires an axiom • activate requires exactly 1 argument Extracted library reference: evaluator/builtins.go:6320. These notes are not a complete signature or a stability guarantee. Manual §19.3.3 Declared binary symbolic operators; read with manual "19.3.3" Excerpt: Without a matching declaration, `2+-3` keeps its original `-1` result. Strings and comments do not activate declarations. Declarations precede uses and apply only to that source file. Imported functions require an explicit local declaration, for example

adapt_case

Function

adapt_case(base_case, new_problem [, adaptation_method])
Adapts a base case's solution for a new problem context. Implements CBR's REUSE phase with strategies: 'substitution', 'transformational', 'compositional'.

Examples

adapt_case(base_case, new_problem)

adapt_case(base_case, new_problem, "substitution")

adapt_case(base_case, new_problem, "transformational")

add

Function

add(x, y) OR add(x, y, z)
Dual-mode function: 2 args returns x+y, 3 args checks if x+y=z. Supports both function symbols and predicates in FOL.

Examples

add(2, 3)      # Returns 5 (function mode)

add(2, 3, 5)   # Returns true (predicate mode)

add(2, 3, 6)   # Returns false (predicate mode)

forall x,y in Numbers: equal(add(x, y), add(y, x))

add1

Function

numericIncrBuiltin: add1 (1+) / sub1 (1-), preserving numeric type via the shared computeAdd. Call diagnostics (different branches may describe different overloads): • add1 requires exactly 1 argument Extracted library reference: evaluator/scheme_extras.go:371. These notes are not a complete signature or a stability guarantee. Manual §22.3 Mathematical functions; read with manual "22.3" Excerpt: | `square(x)` | `x * x`, preserving numeric type | | `add1(x)` / `sub1(x)` | `x + 1` / `x - 1` (Lisp `1+` / `1-`) | | `succ(x)` / `pred(x)` | Successor / predecessor over the ordinal types (Pascal/Ada `'Succ`/`'Pred`): Integers (`succ(5)` → 6) and enum members (`succ(Mon)` → Tue, erroring at the ends). On Integers ≡ `add1`/`sub1`; the ordinal-typed, enum-symmetric spelling | | `isqrt(n)` | Integer floor square root of a non-negative integer (exact, big-int aware) | | `numerator(r)` / `denominator(r)` | Rational accessors; an integer `n` is `n/1` (so `denominator(5)` → `1`) |

add_case

Function

add_case(library, problem, solution, outcome [, context])
Adds a new case to a case library. Core component of CBR's RETAIN phase. Each case contains problem description, solution, outcome, and optional context.

Examples

add_case(lib, problem_obj, solution_obj, outcome_obj)

add_case(medical_lib, symptoms, diagnosis, results, patient_context)

add_concept

Function

Call diagnostics (different branches may describe different overloads): • add_concept requires 2 arguments: graph, concept • first argument must be a conceptual graph • second argument must be a concept Extracted library reference: evaluator/builtins.go:10150. These notes are not a complete signature or a stability guarantee.

add_default_fact

Function

add_default_fact(theory, fact) - Add a known fact Example: add_default_fact(dt, "bird(tweety)") Call diagnostics (different branches may describe different overloads): • add_default_fact requires 2 arguments: theory, fact • first argument must be a default theory • second argument must be a string (fact) Extracted library reference: evaluator/builtins.go:19527. These notes are not a complete signature or a stability guarantee.

add_default_rule

Function

add_default_rule(theory, name, prerequisite, justification, conclusion [, priority]) - Add default rule Example: add_default_rule(dt, "birds_fly", "bird(X)", "flies(X)", "flies(X)") Prioritized: add_default_rule(dt, "penguins_dont", "penguin(X)", "not_flies(X)", "not_flies(X)", 2) The optional 6th argument is an integer priority (default 0); a higher priority defeats a lower-priority CONFLICTING default (Tweety/specificity). Call diagnostics (different branches may describe different overloads): • add_default_rule requires 5 or 6 arguments: theory, name, prerequisite, justification, conclusion [, priority] • fifth argument must be a string (conclusion) • first argument must be a default theory • fourth argument must be a string (justification) • second argument must be a string (rule name) • sixth argument (priority) must be an integer • third argument must be a string (prerequisite) Extracted library reference: evaluator/builtins.go:19555. These notes are not a complete signature or a stability guarantee.

add_deontic_agent

Function

add_deontic_agent(deontic_model, agent_name) - Add agent to deontic model Example: add_deontic_agent(dm, "Alice") Call diagnostics (different branches may describe different overloads): • add_deontic_agent requires 2 arguments: model, agent_name • agent_name must be a string • first argument must be a deontic model Extracted library reference: evaluator/builtins.go:17930. These notes are not a complete signature or a stability guarantee.

add_dimension

Function

add_dimension(space, name, min, max, options...) - Add dimension Extracted library reference: evaluator/builtin_conceptual.go:48. These notes are not a complete signature or a stability guarantee.

add_dl_concept

Function

add_dl_concept(kb, name) - Add a concept to the knowledge base Example: add_dl_concept(kb, "Person") Call diagnostics (different branches may describe different overloads): • add_dl_concept requires 2 arguments: kb, concept_name • first argument must be a DL knowledge base • second argument must be a string (concept name) Extracted library reference: evaluator/builtins.go:18346. These notes are not a complete signature or a stability guarantee.

add_dl_individual

Function

add_dl_individual(kb, name) - Add an individual to the knowledge base Example: add_dl_individual(kb, "john") Call diagnostics (different branches may describe different overloads): • add_dl_individual requires 2 arguments: kb, individual_name • first argument must be a DL knowledge base • second argument must be a string (individual name) Extracted library reference: evaluator/builtins.go:18428. These notes are not a complete signature or a stability guarantee.

add_dl_role

Function

add_dl_role(kb, name) - Add a role to the knowledge base Example: add_dl_role(kb, "hasParent") Call diagnostics (different branches may describe different overloads): • add_dl_role requires 2 arguments: kb, role_name • first argument must be a DL knowledge base • second argument must be a string (role name) Extracted library reference: evaluator/builtins.go:18372. These notes are not a complete signature or a stability guarantee.

add_domain

Function

add_domain(space, name, dimensions [, options...])
Adds a quality domain that groups integral dimensions in a conceptual space. Domain-aware distance computes a metric inside each domain, then combines domains by weighted sum.

Examples

fruit: conceptual_space("Fruit")

add_dimension(fruit, "sweetness", 0, 10)

add_dimension(fruit, "size", 0, 10)

add_domain(fruit, "taste_size", ["sweetness", "size"])

add_domain(fruit, "taste_size", ["sweetness", "size"], "metric", "manhattan", "weight", 2.0)

add_edge

AI Function

add_edge(graph, from_node, to_node[, weight])
Adds an edge between two nodes in a graph. Optional weight parameter for weighted graphs.

Examples

add_edge(g, "A", "B")           # Unweighted edge

add_edge(g, "A", "B", 5)        # Weighted edge

add_edge(graph, "start", "end", 2.5)

add_epistemic_agent

Function

add_epistemic_agent(epistemic_model, agent_name) - Add agent to epistemic model Example: add_epistemic_agent(em, "Alice") Call diagnostics (different branches may describe different overloads): • add_epistemic_agent requires 2 arguments: model, agent_name • agent_name must be a string • first argument must be an epistemic model Extracted library reference: evaluator/builtins.go:17905. These notes are not a complete signature or a stability guarantee.

add_free_term

Function

add_free_term(model, term_name, denotes, referent) - Add a term Example: add_free_term(flm, "the_king", false, "") Call diagnostics (different branches may describe different overloads): • add_free_term requires 4 arguments: model, term_name, denotes, referent • first argument must be a free logic model • fourth argument must be a string (referent) • second argument must be a string (term name) • third argument must be a boolean (denotes) Extracted library reference: evaluator/builtins.go:19333. These notes are not a complete signature or a stability guarantee.

add_knowledge_state

Function

add_knowledge_state(model, id, forced_props) - Add a knowledge state to intuitionistic model forced_props is a dict/hash of propositions forced true at this state Example: add_knowledge_state(im, "s1", {p: true, q: false}) Call diagnostics (different branches may describe different overloads): • add_knowledge_state requires 3 arguments: model, id, forced_props • first argument must be an intuitionistic model • second argument must be a string (state ID) Extracted library reference: evaluator/builtins.go:18077. These notes are not a complete signature or a stability guarantee.

add_node

Function

Add node to graph Call diagnostics (different branches may describe different overloads): • add_node requires at least 2 arguments: graph, node_id [, value] • first argument must be a graph • second argument must be a string (node ID) Extracted library reference: evaluator/builtins.go:8998. These notes are not a complete signature or a stability guarantee.

add_prob_conditional

Function

add_prob_conditional(kb, formula, condition, probability) - Add P(formula|condition) Example: add_prob_conditional(kb, "wet_grass", "raining", 0.9) Call diagnostics (different branches may describe different overloads): • add_prob_conditional requires 4 arguments: kb, formula, condition, probability • first argument must be a probabilistic logic KB • fourth argument must be a number (probability) • second argument must be a string (formula) • third argument must be a string (condition) Extracted library reference: evaluator/builtins.go:19046. These notes are not a complete signature or a stability guarantee.

add_prob_formula

Function

add_prob_formula(kb, formula, probability) - Add probabilistic formula Example: add_prob_formula(kb, "flies(X)", 0.95) → P(flies(X)) = 0.95 Call diagnostics (different branches may describe different overloads): • add_prob_formula requires 3+ arguments: kb, formula, probability, [variables...] • first argument must be a probabilistic logic KB • second argument must be a string (formula) • third argument must be a number (probability) Extracted library reference: evaluator/builtins.go:18972. These notes are not a complete signature or a stability guarantee.

add_prototype

Function

add_prototype(space, name, coordinates, options...) - Add prototype Extracted library reference: evaluator/builtin_conceptual.go:245. These notes are not a complete signature or a stability guarantee.

add_region

Function

add_region(space, name, type, definition) - Add convex region Extracted library reference: evaluator/builtin_conceptual.go:323. These notes are not a complete signature or a stability guarantee.

add_relation

Function

Call diagnostics (different branches may describe different overloads): • add_relation requires 2 arguments: graph, relation • first argument must be a conceptual graph • second argument must be a relation Extracted library reference: evaluator/builtins.go:10172. These notes are not a complete signature or a stability guarantee.

add_semantic_link

Function

add_semantic_link(network, from, to, linktype [, strength])
Creates a typed semantic relationship between two nodes with optional strength (0.0-1.0)

Examples

add_semantic_link(net, "canary", "bird", "ISA", 1.0)

add_semantic_link(net, "tweety", "canary", "INSTANCE_OF")

add_semantic_link(net, "bird", "can_fly", "HAS_PROPERTY", 0.8)

add_semantic_node

Function

add_semantic_node(network, id, label, type)
Adds a semantic node to a semantic network with specified ID, label, and type

Examples

add_semantic_node(net, "bird", "Bird", "Category")

add_semantic_node(net, "tweety", "Tweety", "Individual")

add_state

Function

add_state(temporal_model, state_id, props) - Add state to temporal model Example: add_state(tm, "s0", {traffic_light: "red"}) Call diagnostics (different branches may describe different overloads): • add_state requires at least 2 arguments: model, state_id[, props] • first argument must be a temporal model • state_id must be a string Extracted library reference: evaluator/builtins.go:17841. These notes are not a complete signature or a stability guarantee.

add_taxonomy_node

Function

add_taxonomy_node(taxonomy, name, parent_name) - Adds a node to taxonomy Example: add_taxonomy_node(custom, "root", none) add_taxonomy_node(custom, "child", "root") Call diagnostics (different branches may describe different overloads): • add_taxonomy_node requires 3 arguments: taxonomy, name, parent_name • first argument must be a Leibniz taxonomy • second argument must be a string (node name) • third argument must be a string (parent name) or none/om Extracted library reference: evaluator/builtins.go:19772. These notes are not a complete signature or a stability guarantee.

add_term

Function

Call diagnostics (different branches may describe different overloads): • add_term requires 3 arguments: linguistic_var, term_name, fuzzy_set • first argument must be a linguistic variable • term name must be a string • third argument must be a fuzzy set Extracted library reference: evaluator/builtins.go:12951. These notes are not a complete signature or a stability guarantee.

add_to_domain

Function

add_to_domain(model, entity) - Add entity to domain of discourse Example: add_to_domain(flm, "socrates") Call diagnostics (different branches may describe different overloads): • add_to_domain requires 2 arguments: model, entity • first argument must be a free logic model • second argument must be a string (entity) Extracted library reference: evaluator/builtins.go:19308. These notes are not a complete signature or a stability guarantee.

add_transition

Function

add_transition(temporal_model, from_state, to_state) - Add temporal transition Example: add_transition(tm, "s0", "s1") Call diagnostics (different branches may describe different overloads): • add_transition requires 3 arguments: model, from_state, to_state • first argument must be a temporal model • from_state must be a string • to_state must be a string Extracted library reference: evaluator/builtins.go:17876. These notes are not a complete signature or a stability guarantee.

add_world

Function

add_world(model, world_id, props) - Add a possible world to a Kripke model Example: add_world(km, "w1", {p: true, q: false}) Call diagnostics (different branches may describe different overloads): • add_world requires at least 2 arguments: model, world_id[, props] • first argument must be a Kripke model • world_id must be a string Extracted library reference: evaluator/builtins.go:17771. These notes are not a complete signature or a stability guarantee.

ai

Function

(retired) ai "…"  →  ask/any "…"
Retired 2026-09-02 on the same day it shipped: `ai` and `ask` were one speech act at two distances, and the name hid that. The general door is now ask/any (a refinement of ask, the language door). Writing ai "…" errors with the migration hint; a user binding named ai is untouched. The REPL meta-command :ai is unchanged.

Examples

ask/any "what is a fixpoint?"      # what ai "…" used to mean

alias

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §19.11 Aliasing the vocabulary — `alias` / `unalias`; read with manual "19.11" Excerpt: ### Aliasing the vocabulary — `alias` / `unalias` `alias new = target` gives an existing spelling a second name; `unalias new` withdraws it. One statement covers four kinds of target:

aliases

Function

Alias management functions Call diagnostics (different branches may describe different overloads): • aliases() takes no arguments Extracted library reference: evaluator/builtins.go:16629. These notes are not a complete signature or a stability guarantee. Manual §4.5.6 Case mapping — `upper` / `lower` / `title` (and Julia aliases); read with manual "4.5.6" Excerpt: #### Case mapping — `upper` / `lower` / `title` (and Julia aliases) ```axioma upper("Hello") # → "HELLO"

all?

Function

all?(predicate, collection)
True iff the predicate holds for every element (vacuously true on empty). Manual §12.18 List-library verbs (Haskell / OCaml); read with manual "12.18" Excerpt: `separate` is `partition` under a different name (`partition` is reserved for concept partitions). `all?`/`any?`/`none?` short-circuit and read correctly in `if`. The nine verbs above `unfold` work under `--vm` (byte-identical). **`unfold` is

allow

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §34 Modules; read with manual "34" Excerpt: - **No `export` / `allow` in the file** — functions, `data` types, and ALL_CAPS constants are public; plain values are not; `_` is never public. - **At least one `export` / `allow`** — that list **is** the surface. Unlisted functions are hidden. `_` stays private. A plain value still has to be named

alnum?

Function

charPredicate wraps a rune classifier as a builtin accepting a Character or a one-character String. Call diagnostics (different branches may describe different overloads): • alnum? requires exactly 1 argument Extracted library reference: evaluator/character.go:81. These notes are not a complete signature or a stability guarantee.

alpha?

Function

charPredicate wraps a rune classifier as a builtin accepting a Character or a one-character String. Call diagnostics (different branches may describe different overloads): • alpha? requires exactly 1 argument Extracted library reference: evaluator/character.go:81. These notes are not a complete signature or a stability guarantee.

alphabet_of

Function

alphabet_of(taxonomy)
The taxonomy's 'alphabet of human thoughts': every primitive differentia with its prime, in prime order — the registry of first terms Leibniz's 1666 class tables call for, arithmetized 1679-style.

Examples

alphabet_of(porphyry)   # [("substance", "2"), ("material", "3"), ...]

always

Temporal Logic

always proposition
Temporal necessity operator (□P). Expresses that a proposition is always true.

Examples

always true

always (mathematical laws)

eternal: always (logical principles)

an

Keyword

InstanceName: an ConceptName { properties... }  OR  InstanceName: an ConceptName with slot: value, ...
Alias for `a`. Used for grammatically correct concept instantiation in natural language; accepts the same provisional `with slot: value, ...` list as `a`.

Examples

laptop: an ElectronicProduct { price: 999 }

analogous

Analogical Logic

domain1 analogous domain2
Structural analogy operator. Expresses deep structural similarities between domains.

Examples

Mathematics analogous Music

SolarSystem analogous Atom

analogy: Domain1 analogous Domain2

analogy

Reserved vocabulary

Reserved vocabulary with no dedicated parser implementation in this build. It is not a usable standalone form. Use doc "discover" for the implemented discovery interface, and manual for supported language forms. Recognition of a name is not a claim that its intended feature is implemented.

and

Operator

expression1 and expression2
Logical AND; aliases && and ∧. Skips the right operand for Boolean false on the left. Otherwise preserves multivalued logic dispatch; not an operand-returning or truthiness operator.

Examples

true and false

x > 0 and x < 10

and_then

Function

and_then(f, wrapper) — monadic bind: on success, return f(payload) as-is (f should return Option/Result/Either); on failure, unchanged. Call diagnostics (different branches may describe different overloads): • and_then requires exactly 2 arguments: a function and an Option/Result/Either Extracted library reference: evaluator/builtin_option_helpers.go:129. These notes are not a complete signature or a stability guarantee. Manual §33.14.2 Railway helpers — `map_ok` / `and_then` / `or_else` / `is_*`; read with manual "33.14.2" Excerpt: #### Railway helpers — `map_ok` / `and_then` / `or_else` / `is_*` Function **first**, wrapper **second** (same order as `map` / `filter`):

andalso

Operator

expression1 andalso expression2
Short-circuiting logical AND. Always two-valued: it reads the left operand's truthiness and stops there, so the right operand is skipped whenever the left is false, none or om. Yields a Boolean. Use `and` when the operands may be multi-valued truth values (Belnap, Kleene, Łukasiewicz, Gödel G3), since a lattice meet needs both sides.

Examples

1 < 2 andalso 3 > 4

i <= len(xs) andalso xs[i] > 0

annotation

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §26.2 Literate annotation: `--annotate`; read with manual "26.2" Excerpt: ### Literate annotation: `--annotate` `axioma --annotate path.ax` parses the script, groups consecutive statements of the same kind into blocks, and emits a step-by-step

annotations

Function

annotations(fn)
The declared `::` type of a function as a FunctionType (`Integer -> Integer`), or none when no arm was written. Not the DataType tag (`:: f` is Function/Builtin) and not the callable shape (`signature(f)` is func(x)). `.params` / `.result` walk the arms; a missing arm is none and prints `_`. Works under --vm.

Examples

twice :: Integer -> Integer

twice(x :: Integer) = x * 2

annotations(twice)          # → Integer -> Integer

annotations(twice).result   # → Integer

annotations(sqrt)           # → none

any?

Function

any?(predicate, collection)
True iff the predicate holds for some element (false on empty). Manual §12.18 List-library verbs (Haskell / OCaml); read with manual "12.18" Excerpt: `separate` is `partition` under a different name (`partition` is reserved for concept partitions). `all?`/`any?`/`none?` short-circuit and read correctly in `if`. The nine verbs above `unfold` work under `--vm` (byte-identical). **`unfold` is

append

Function

append(array, value)  |  append(path, text)
Grows an array in place and returns it (same as push), or appends text to a file. First argument decides: an Array is growth; a path is I/O.

Examples

a: [1, 2]

append(a, 3)  # a is now [1, 2, 3]

append(%log.txt, "line\n")

append_map

Function

appendMapBuiltin builds append_map / flatmap / mapcat: map fn over the collection, where fn returns a collection per element, and concatenate the results into one Array. Call diagnostics (different branches may describe different overloads): • append_map requires 2 arguments: function and collection • append_map: second argument must be an array, tuple, or set Extracted library reference: evaluator/scheme_extras.go:109. These notes are not a complete signature or a stability guarantee. Manual §22.7 Higher-order functions; read with manual "22.7" Excerpt: foldr(fn, init, coll) # right fold, fn(elem, acc) (also fold_right) append_map(fn, coll) # map then concatenate the per-element collections (flatmap / mapcat) for_each(fn, coll) # apply fn for side effects; returns none constantly(x) # → a function that ignores its args and returns x negate(pred) # → a predicate that logically negates pred (≠ set `complement`)

apply

Function

apply(fn, args) — call fn with the array/tuple `args` spread as its positional arguments: apply(f, [1, 2, 3]) ≡ f(1, 2, 3). The Lisp/ Scheme `apply`. Works with user functions, builtins, and relations (anything applyCallable dispatches). Pairs with variadic params: apply(func(...xs) [sum(xs)], [1, 2, 3]) → 6. Call diagnostics (different branches may describe different overloads): • apply requires exactly 2 arguments: a function and an argument array Extracted library reference: evaluator/builtins.go:4195. These notes are not a complete signature or a stability guarantee. Manual §19.3.3 Declared binary symbolic operators; read with manual "19.3.3" Excerpt: target does. Unsupported target features retain their explicit VM errors (including guarded clauses, contracts, and `apply` on a VM closure). Custom unary, postfix and partial operator sections are not added. Existing built-in operator sections remain unchanged. See [Chapter 10](../textbook/htdp-in-axioma/10_higher_order.md) for the optional lesson, exercise and solution; `doc("operator")` gives offline help.

apply_mapping

Function

apply_mapping(mapping, point) - Apply space mapping Extracted library reference: evaluator/builtin_conceptual_mapping.go:63. These notes are not a complete signature or a stability guarantee.

apropos

Function

apropos("term")
Discovery search (the Common Lisp / SWI-Prolog tool): case-insensitive substring match over names AND documentation text across the doc registry, builtin table, reserved keywords, and visible concepts. Prints `name — category — summary` lines (sorted) and returns none. Evaluator-only. Shadowable.

Examples

apropos("substr")        # find the substring family

apropos("regex")

arg

Function

arg(z) - Get argument/phase of complex number in radians Example: arg(1 + i) → π/4 ≈ 0.785398 Call diagnostics (different branches may describe different overloads): • arg requires a complex number • arg requires exactly 1 argument: complex number Extracted library reference: evaluator/builtins.go:17219. These notes are not a complete signature or a stability guarantee. Manual §12.11 Contracts — `requires` / `ensures` / `check f`; read with manual "12.11" Excerpt: parameter can carry its own contract in a nested block. Its clauses speak positionally — `arg` (or `arg1`…`argN`, and `args`) and `result` — because the contract's author does not choose the lambda the caller passes: ```axioma

argues

Argument Logic

premise argues conclusion
Informal argument operator. Expresses that a premise supports a conclusion.

Examples

Evidence argues Theory

Premise argues Conclusion

argument: Data argues Hypothesis

arity

Function

arity(fn)
Parameter count of a function. User functions report their declared parameter count; spec-registered builtins with one fixed arity report it; optional/variadic shapes (and builtins without a spec) report -1 — use signature(fn) for the full shape.

Examples

arity(func(a, b) [a + b])   # → 2

arity(map)                  # → 2

arity(round)                # → -1 (1 or 2 args — see signature)

array

Function

array([collection])
With no argument, the empty array (≡ the literal []). With one argument, materializes a set, tuple, or finite range as an Array. A Set is walked in its CANONICAL order — the same order first/nth/s[i] and display show — so the result is reproducible across runs; a Range keeps source order (array(5..1) → [5, 4, 3, 2, 1]); an Array is returned unchanged. Renamed July 2026 from toArray, joining the bare type-name coercions (bytes/str/int/float); the old spelling raises an error naming this one.

Examples

array()              # [] — the empty array

array({3, 1, 2})     # [1, 2, 3] — canonical order

array((1, 2, 3))     # [1, 2, 3] — from a Tuple

array(1..4)          # [1, 2, 3, 4]

array(5..1)          # [5, 4, 3, 2, 1] — source order

array?

Function

Call diagnostics (different branches may describe different overloads): • array? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee. Manual §5.8 Lists (persistent cons lists); read with manual "5.8" Excerpt: `is List`, `is_list(l)` and `list?(l)` test the type (`list?` no longer aliases `array?`; an Array argument errors with a migration hint). The accumulate idiom is `acc: cons(x, acc)` in a loop, then `reverse(acc)` — every step O(1).

array_to_stack

Function

Call diagnostics (different branches may describe different overloads): • argument to array_to_stack must be an array • array_to_stack requires 1 argument: array Extracted library reference: evaluator/builtins.go:12165. These notes are not a complete signature or a stability guarantee. Manual §18.4 Array conversion; read with manual "18.4" Excerpt: | `stack_to_array(s)` | Snapshot the stack as an array, top first | | `array_to_stack(arr)` | Build a new stack from an array | ### Example

as

Keyword

import NAME as ALIAS from "path" | import "path" as M | PAT as NAME | implement I for T as { ... }
Several positions, one word: import rename, module alias, as-pattern (`| 1..9 as n`), and the `implement … as { … }` block. `Dog as Animal` still declares class inclusion; the canonical form is `Dog extends Animal`.

Examples

import sqrt as root from "lib/math.ax"

match n with | 1..9 as k => k

implement Iterable for Box as { iterate: func(x) [ [x.v] ] }

as_unit

Function

as_unit(quantity, unit)
Same quantity, different display unit. Equality is unchanged: as_unit(1*kg, gram) == 1*kg. `in` is not overloaded (that word is membership).

Examples

as_unit(5 * kg, gram)   # displays as 5000 gram, still == 5*kg

asc

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §7.13 ORDER BY clause; read with manual "7.13" Excerpt: List comprehensions accept an `orderby` clause that sorts the result. Sets and dicts ignore `orderby` (they're unordered by nature). Direction defaults to `asc`; add `desc` to reverse: ```axioma [x | x <- xs, orderby x] # asc by default

ascii?

Function

charPredicate wraps a rune classifier as a builtin accepting a Character or a one-character String. Call diagnostics (different branches may describe different overloads): • ascii? requires exactly 1 argument Extracted library reference: evaluator/character.go:81. These notes are not a complete signature or a stability guarantee.

asin

Function

asin(x)
Arcsine, in radians. Manual §22.3 Mathematical functions; read with manual "22.3" Excerpt: | `sin(x)` / `cos(x)` / `tan(x)` | Trigonometry — arguments in **radians** (like Lua/C); convert with `rad`/`deg` | | `asin(x)` / `acos(x)` / `atan(x)` | Inverse trig, radians (`asin`/`acos` domain-checked). `atan(y, x)` 2-arg is the full-quadrant form (Lua 5.3+ `math.atan`) | | `atan2(y, x)` | Full-quadrant arctangent — the C/Python spelling of `atan(y, x)` (`atan2(1, 0)` → `pi/2`) | | `sinh(x)` / `cosh(x)` / `tanh(x)` | Hyperbolic functions | | `deg(x)` | Radians → degrees (`deg(pi)` → `180`; Lua `math.deg`) |

ask

Function

ask "question" [{provider: "…", model: "…"}] | ask/axioma "…" | ask/any "…" | ask("…"[, {…}]) | ask/any("…"[, {…}])
The AI door. Bare ask (= ask/axioma) is the LANGUAGE door: the question goes to the configured model with a generated card — the roles a word can take, your own definitions, the dictionary entries for the words in the question — and the model's suggestion must PARSE: it is run through the interpreter's own parser and repaired with the parser's errors, at most three rounds, then printed after `ask suggests:` and returned as a String (in the REPL a bare 1 runs it). The card also carries, for each word of the question you have defined, what it is and what can be asked of it — a thing brings its kind, where slots are declared — and skips English function words (quote a word to ask about the word itself). ask/any is the GENERAL door: any topic, no card, no check, the reply as text (the REPL's :ai in scripts). Both print a provenance line (provider, model, endpoint, local or billed) and the token usage of the call; in the REPL a remote provider asks for confirmation first. The scope is a refinement, so the call form is ask/any("…") — no scope parameter, no second function. Shadowable: a binding named ask wins. Never fires on its own — the unknown-word hint only points at it. Under --vm it refuses (env-aware).

Examples

ask "how do I make msft a Stock?"           # language door — the reply parses

reply: ask("how do I state a fact?")        # call form, bound

ask/any "one sentence on Leibniz"          # any topic

ask/any("…", {provider: "ollama"})         # one call on a local model

assert

Keyword

assert fact(args...)
Asserts a plain fact into the knowledge store at DATUM grounding — an observed particular with no claim of foundational status. Use axiom/postulate for stronger epistemic commitments; rules derive theorems (strict <==) and conjectures (defeasible <~~) from them.

Examples

relation edge(x, y)

assert edge("a", "b")

grounding("edge", "a", "b")  # "datum"

assert_dl_concept

Function

assert_dl_concept(kb, individual, concept) - Assert C(a) Example: assert_dl_concept(kb, "john", "Person") → john is a Person Call diagnostics (different branches may describe different overloads): • assert_dl_concept requires 3 arguments: kb, individual, concept • first argument must be a DL knowledge base • second argument must be a string (individual name) • third argument must be a string (concept name) Extracted library reference: evaluator/builtins.go:18454. These notes are not a complete signature or a stability guarantee.

assert_dl_role

Function

assert_dl_role(kb, role, individual1, individual2) - Assert R(a,b) Example: assert_dl_role(kb, "hasParent", "john", "mary") Call diagnostics (different branches may describe different overloads): • assert_dl_role requires 4 arguments: kb, role, individual1, individual2 • first argument must be a DL knowledge base • fourth argument must be a string (individual2 name) • second argument must be a string (role name) • third argument must be a string (individual1 name) Extracted library reference: evaluator/builtins.go:18484. These notes are not a complete signature or a stability guarantee.

assign_stmt

Function

Call diagnostics (different branches may describe different overloads): • assign_stmt name must be a string • assign_stmt requires exactly 2 arguments (name, value) Extracted library reference: evaluator/builtins.go:16456. These notes are not a complete signature or a stability guarantee.

assignment_stmt?

Function

Call diagnostics (different branches may describe different overloads): • assignment_stmt? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1645. These notes are not a complete signature or a stability guarantee.

assumes

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §33.13 Confluence — does the clause ORDER matter?; read with manual "33.13" Excerpt: bodies** at the witness, so a body with effects performs them; guards are assumed pure for the same reason dispatch already assumes it. **Relationship to `--typecheck`.** The static pass above reports *tag-level* redundancy at compile time and deliberately stops at multi-slot constructor

ast

Function

ast("source") | ast(fn) | ast(astValue)
AST value from source at RUNTIME, without executing it — eval parses AND runs; ast splits that ('(…) quote is the LEXICAL spelling for quoting the expression you are writing). A String parses as a whole program with NO truncation: a single expression unwraps to its expression node (quote-compatible, so head/ast_string/replace_all compose), a single statement stays a statement, and multi-statement input wraps the whole Program — eval(ast(src)) ≡ eval(src) always (parse()'s default mode keeps only the FIRST statement; ast() is the front-end that never drops code). A user function yields its reconstructed definition (the AST twin of source(f)); an AST passes through unchanged; builtins error catchably (Go — see signature/doc).

Examples

a: ast("x + 1")           # parse, don't run — ast_string(a) → "(x + 1)"

eval(ast("a: 5\na * 2"))   # → 10 — whole program (parse() default → 5!)

ast_type(ast("zz: 9"))     # → "LetStatement"

eval(ast(func(x) [x * 2]))(5)   # → 10 — the function-definition twin of source

ast?

Function

Call diagnostics (different branches may describe different overloads): • ast? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

ast_call_args

Function

ast_call_args(ast)
Inspect a call node's arguments as data. Supply an AST value (for example from quote or parse), not executable source text. See manual "Code as Data" for the AST inspection family.

ast_call_name

Function

ast_call_name(ast)
Inspect a call node's function name as data. Supply an AST value (for example from quote or parse), not executable source text. See manual "Code as Data" for the AST inspection family.

ast_children

Function

ast_children(ast)
Inspect the node's structural children as data. Supply an AST value (for example from quote or parse), not executable source text. See manual "Code as Data" for the AST inspection family.

ast_eval

Function

Call diagnostics (different branches may describe different overloads): • argument to ast_eval must be an AST object Extracted library reference: evaluator/builtins.go:15808. These notes are not a complete signature or a stability guarantee. Manual §19.10.8 Limits; read with manual "19.10.8" Excerpt: | `fullform(inline_call(...))` captures the call literally (hold semantics) | Bind to local first: `r: call(...); fullform(r)`. Or use `ast_string(call(...))` which doesn't hold. | | `ast_eval` doesn't see local bindings | Use `quasiquote` to splice values *into* the AST before evaluating: `ast_eval(quasiquote(unquote(x) + 1))` | | Computed ASTs lose direct caller provenance | Splice argument ASTs directly with `unquote`; use `gensym` for intentionally constructed names | | `quasiquote` not yet compiled in `--vm` | Run quasiquote-heavy / macro-heavy scripts under the tree-walker | | No reader macros — can't extend the parser itself | Out of scope for v1 |

ast_field

Function

Call diagnostics (different branches may describe different overloads): • ast_field field name must be a string • ast_field requires exactly 2 arguments (AST, field_name) Extracted library reference: evaluator/builtins.go:15897. These notes are not a complete signature or a stability guarantee.

ast_fields

Function

ast_fields(ast)
Inspect the names of the node's fields as data. Supply an AST value (for example from quote or parse), not executable source text. See manual "Code as Data" for the AST inspection family.

ast_has?

Function

Call diagnostics (different branches may describe different overloads): • ast_has? field name must be a string • ast_has? requires exactly 2 arguments (AST, field_name) Extracted library reference: evaluator/builtins.go:15874. These notes are not a complete signature or a stability guarantee.

ast_kind

Function

Extracted library reference: evaluator/builtins.go:15846. These notes are not a complete signature or a stability guarantee. Manual §19.10 19.10 Homoiconicity — building code as data; read with manual "19.10" Excerpt: **The dispatch loop.** Recursive AST walks dispatch on `ast_kind`: ```axioma walk: func(expr) [

ast_string

Function

Call diagnostics (different branches may describe different overloads): • argument to ast_string must be an AST object Extracted library reference: evaluator/builtins.go:15825. These notes are not a complete signature or a stability guarantee. Manual §19.10.8 Limits; read with manual "19.10.8" Excerpt: |---|---| | `fullform(inline_call(...))` captures the call literally (hold semantics) | Bind to local first: `r: call(...); fullform(r)`. Or use `ast_string(call(...))` which doesn't hold. | | `ast_eval` doesn't see local bindings | Use `quasiquote` to splice values *into* the AST before evaluating: `ast_eval(quasiquote(unquote(x) + 1))` | | Computed ASTs lose direct caller provenance | Splice argument ASTs directly with `unquote`; use `gensym` for intentionally constructed names | | `quasiquote` not yet compiled in `--vm` | Run quasiquote-heavy / macro-heavy scripts under the tree-walker |

ast_type

Function

Call diagnostics (different branches may describe different overloads): • argument to ast_type must be an AST object Extracted library reference: evaluator/builtins.go:15785. These notes are not a complete signature or a stability guarantee. Manual §25.5 Runtime reflection — the self-describing surface; read with manual "25.5" Excerpt: head(a) # the same shape '(x + 1) gives, so the AST eval(ast("2 + 3")) # algebra (head, ast_type, replace_all) composes eval(ast("a: 5\na * 2")) # → 10 — a String parses as the WHOLE program eval(parse("a: 5\na * 2")) # → 5! parse()'s default mode keeps only the # FIRST statement — ast() never drops code

ast_with_context

Function

Context transfer is explicit and copies syntax. An identifier AST is the context witness, so callers cannot accidentally combine unrelated contexts from an arbitrary expression containing several independently scoped names. Call diagnostics (different branches may describe different overloads): • ast_with_context requires AST syntax and an identifier AST context • ast_with_context requires syntax and an identifier AST context Extracted library reference: evaluator/macro_context_builtins.go:12. These notes are not a complete signature or a stability guarantee. Manual §19.10.2 Macros and template hygiene; read with manual "19.10.2" Excerpt: `ast_with_context(syntax, identifier_context)` copies syntax and transfers that context to its identifiers. `make_identifier` validates the name spelling. `make_lambda` accepts String names or identifier ASTs, preserving context and rejecting duplicate parameters. Ordinary automatic hygiene covers the programming

astar

AI Function

astar(graph, start_node, goal_node)
Performs A* Search using heuristic guidance for optimal pathfinding. Combines best of DFS and BFS.

Examples

astar(g, "A", "Z")

astar(map, "home", "destination")

at

Keyword

for ELEM at I in ITERABLE [ body ]
Loop clause attaching a 1-based iteration counter to a `for`/`foreach` loop, element-first. Composes with destructure (`for x, y at i in pairs`) and any iterable (arrays, strings by rune, sets in canonical sorted order, ranges — including open `n..` with a break). `at` is a SOFT keyword, recognized only between the loop variables and `in` — variables named `at` keep working. Equivalent spellings: `for e in xs with index i` and `for i, e in xs.indexed`.

Examples

for f at i in ["fig", "plum"] [ println("${i}. ${f}") ]

for n at i in 2..100 by 2 [ if i == 3 then [break] ]

for v, tag at i in pairs [ ... ]   # destructure + counter

at0

Function

Call diagnostics (different branches may describe different overloads): • at0 requires exactly 2 arguments Extracted library reference: evaluator/builtins.go:6836. These notes are not a complete signature or a stability guarantee.

at1

Function

Call diagnostics (different branches may describe different overloads): • at1 requires exactly 2 arguments Extracted library reference: evaluator/builtins.go:6846. These notes are not a complete signature or a stability guarantee.

atan

Function

atan(x_or_y, [x])
Arctangent of x; atan(y, x) is the full-quadrant form (≡ atan2). Manual §22.3 Mathematical functions; read with manual "22.3" Excerpt: | `sin(x)` / `cos(x)` / `tan(x)` | Trigonometry — arguments in **radians** (like Lua/C); convert with `rad`/`deg` | | `asin(x)` / `acos(x)` / `atan(x)` | Inverse trig, radians (`asin`/`acos` domain-checked). `atan(y, x)` 2-arg is the full-quadrant form (Lua 5.3+ `math.atan`) | | `atan2(y, x)` | Full-quadrant arctangent — the C/Python spelling of `atan(y, x)` (`atan2(1, 0)` → `pi/2`) | | `sinh(x)` / `cosh(x)` / `tanh(x)` | Hyperbolic functions | | `deg(x)` | Radians → degrees (`deg(pi)` → `180`; Lua `math.deg`) |

atan2

Function

atan2(y, x)
Full-quadrant arctangent of y/x in radians, using both signs to pick the quadrant (range (−π, π]). atan(y, x) is the equivalent Lua 5.3+ spelling; atan(x) 1-arg remains the plain arctangent.

Examples

atan2(1, 1)   # Returns pi/4 (first quadrant)

atan2(1, -1)  # Returns 3*pi/4 (second quadrant)

atan2(1, 0)   # Returns pi/2 (straight up — no division by zero)

atend

Function

Call diagnostics (different branches may describe different overloads): • atend requires exactly 2 arguments Extracted library reference: evaluator/builtins.go:6856. These notes are not a complete signature or a stability guarantee.

attach_coordinates

Function

attach_coordinates(kb, concept_name, space, coordinates) - Attach geometric grounding to DL concept Extracted library reference: evaluator/builtin_conceptual_bridges.go:81. These notes are not a complete signature or a stability guarantee.

attempt

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §29.7 `attempt` — swallow to `none`; read with manual "29.7" Excerpt: ### `attempt` — swallow to `none` ```axioma n: attempt parse_int(user_input) # an Integer, or `none` if it didn't parse

attribute

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §13.22 Detached signatures — `f :: A -> B` on the line above; read with manual "13.22" Excerpt: (`relation teach(x :: String -> "teacher")`), a translation block, and an attribute set. Inside a `\`-lambda the body reading always wins — `\x :: Integer -> Circle` returns `Circle`, it does not declare a return type — because a nullary constructor is simultaneously a legal type atom and a legal value, and the body is what a lambda is for.

average

Function

average(data, [axis])
Arithmetic mean — exact alias of mean. Manual §22.7 Higher-order functions; read with manual "22.7" Excerpt: sum(coll) # Numeric sum over array/set/tuple (Σ is Unicode alias) mean(coll) # Arithmetic mean of an array, tuple, or matrix (`average` is the alias) median(coll) # Middle value of a sorted array, tuple, or matrix (even count averages the two middle) # Scheme/Lisp folds & combinators

axiom

Keyword

axiom fact(args...) | axiom/<kind> fact(args...) | axiom Name [scope]: expression ["documentation"]
Asserts a fact as an AXIOM — a foundational truth, the top rung of the grounding ladder (axiom > postulate > theorem > conjecture > hypothesis > datum). Strict rules over axioms derive theorems; defeasible rules derive conjectures. A /kind refinement tags the Schopenhauerian truth-kind in the same breath (axiom/empirical, axiom/transcendental, axiom/logical, axiom/metalogical, axiom/motive). Axioms stay challengeable via challenge(). The named form (axiom Name: expression) declares a validated logical constraint.

Examples

axiom parent("john", "mary")

axiom/empirical weighs("apple", 95)

grounding("parent", "john", "mary")  # "axiom"

axiom NonNegative: balance >= 0

axiomadoc CLI Tool

Tools

axiomadoc <command> [options]
Professional documentation generator for Axioma source code. Supports HTML, Markdown, and PDF output with live serving and validation.

Examples

go build -o axiomadoc ./cmd/axiomadoc

./axiomadoc generate -input . -output docs -format html

./axiomadoc serve -port 8080 -watch

./axiomadoc validate -input . -check-links -run-examples

./axiomadoc generate -format html -template academic

./axiomadoc help  # Show detailed usage information

axioms

Function

Axiom manipulation functions Call diagnostics (different branches may describe different overloads): • axioms requires a concept or axiom name • axioms requires at least 1 argument Extracted library reference: evaluator/builtins.go:6295. These notes are not a complete signature or a stability guarantee. Manual §15 Knowledge Base, Axioms & Postulates; read with manual "15" Excerpt: ## 15. Knowledge Base, Axioms & Postulates ### Declaring knowledge — the six grounding grades

b4_join

Function

b4_join(a, b, ...) — Belnap B4 KNOWLEDGE-order join ⊕ (Fitting's "gullibility": accept everything every source says). This is the evidence-combination operator: b4_join(belnap("true"), belnap("false")) → ⊤⊥ᵇ (a glut). Distinct from truth-order `or`. Also accepts one Array/Set argument to fold over a collection (empty → ?ᵇ, the ⊕ identity). Operands: Belnap/Boolean/om (strings need belnap(...)). Extracted library reference: evaluator/builtins.go:12811. These notes are not a complete signature or a stability guarantee. Manual §9.4 Belnap B4 (paraconsistent four-valued); read with manual "9.4" Excerpt: **knowledge order** (how much information? — `neither` < `true`,`false` < `both`), surfaced as `b4_join` (⊕ — accept everything every source says) and `b4_meet` (⊗ — keep only what all sources agree on): ```axioma

b4_meet

Function

b4_meet(a, b, ...) — Belnap B4 KNOWLEDGE-order meet ⊗ (Fitting's "consensus": keep only what all sources agree on). b4_meet(belnap("true"), belnap("false")) → ?ᵇ (no consensus). Distinct from truth-order `and`. Also accepts one Array/Set argument to fold over a collection (empty → ⊤⊥ᵇ, the ⊗ identity). Extracted library reference: evaluator/builtins.go:12824. These notes are not a complete signature or a stability guarantee. Manual §9.4 Belnap B4 (paraconsistent four-valued); read with manual "9.4" Excerpt: **knowledge order** (how much information? — `neither` < `true`,`false` < `both`), surfaced as `b4_join` (⊕ — accept everything every source says) and `b4_meet` (⊗ — keep only what all sources agree on): ```axioma

backarrow

Symbol

=== ← (Glyph) === name: backarrow latex: leftarrow category: logic codepoint: U+2190 meaning: ← — conceptual-graph backward arrow

backward

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §1.1 Key features; read with manual "1.1" Excerpt: - **Five first-class logics**: Boolean, Kleene K3, Łukasiewicz L3, Belnap B4, Gödel G3 (intuitionistic), automatically dispatched by operand type. - **Strict and defeasible rules** in both backward and forward directions. - **Bilattice truth values** with paraconsistent contamination (Belnap B4). - **SQLite-backed knowledge base** shared with [Cascade](https://github.com/vevenhar/axiomacascade). - **Stack programming** with both a user-accessible `Stack` type and a global interpreter stack.

bag

Function

bag(x?) — an empty bag, or a bag of an array / set / bag's elements. ─── Bag (multiset) constructors ───────────────────────────────────────────── These were `evalCallExpression` intercepts taking AST expressions plus an environment, which is why `bag(...)` was "undefined variable bag" under --vm: the VM resolves names against the shared builtin TABLE, and an intercept is not in it. Each used its environment for exactly one thing — evaluating its own arguments — so each is an ordinary value-based builtin, and moving them into the table gives both runtimes ONE body rather than an intercept and a re-implementation that can drift. Extracted library reference: evaluator/builtin_strings.go:524. These notes are not a complete signature or a stability guarantee. Manual §28.5.8 Refinement modes — `/bag`, `/k3`, `/strict`, `/distinct`, `/explain`; read with manual "28.5.8" Excerpt: #### Refinement modes — `/bag`, `/k3`, `/strict`, `/distinct`, `/explain` The block accepts SQL-shaping refinements that pre-configure how the compiled comprehension treats duplicates, NULLs, and shape strictness:

bag_add

Function

bag_add(b, x) — a new bag with x's multiplicity incremented by 1. Extracted library reference: evaluator/builtin_strings.go:562. These notes are not a complete signature or a stability guarantee.

bag_of_set

Function

bag_of_set(s) — each element once. Extracted library reference: evaluator/builtin_strings.go:590. These notes are not a complete signature or a stability guarantee.

bag_of_string

Function

bag_of_string(s) — one entry per CHARACTER, multiplicities counting repeats. Extracted library reference: evaluator/builtin_strings.go:606. These notes are not a complete signature or a stability guarantee.

bag_remove

Function

bag_remove(b, x) — a new bag with x's multiplicity decremented by 1. Extracted library reference: evaluator/builtin_strings.go:576. These notes are not a complete signature or a stability guarantee.

band

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §4.1.1 Integers don't overflow; read with manual "4.1.1" Excerpt: `0xFFFFFFFFFFFFFFFF` is 2⁶⁴−1 (a positive number), not Lua's `-1`. - **Bit operators** (`band`/`bor`/`bxor`/`bshl`/`bshr`) use Python's infinite-two's-complement reading: `bshl` is exact at any count (`1 bshl 63` = 2⁶³, `1 bshl 100` = 2¹⁰⁰), and `bshr` is an arithmetic shift that drains to `0` (or `-1` for negatives) past the width.

barvee

Symbol

=== ⊽ (Glyph) === name: nor latex: barvee, nor category: logic codepoint: U+22BD meaning: p ⊽ q — NOR, the Peirce arrow ¬(p ∨ q); functionally complete alone (Wittgenstein's N is its n-ary form). Prefix form: nor(p, q)

barwedge

Symbol

=== ⊼ (Glyph) === name: nand latex: barwedge, nand category: logic codepoint: U+22BC meaning: p ⊼ q — NAND, the Sheffer stroke ¬(p ∧ q); functionally complete alone (Post). Prefix form: nand(p, q)

base64_decode

Function

Call diagnostics (different branches may describe different overloads): • base64_decode requires exactly 1 argument (String) Extracted library reference: evaluator/builtin_bytes.go:301. These notes are not a complete signature or a stability guarantee. Manual §4.6.2 Conversions (explicit + fallible); read with manual "4.6.2" Excerpt: | `string_to_bytes(s, "utf-8")` | `Bytes` | encoding unknown | | `base64_encode(bs)` / `base64_decode(s)` | round-trip | decoder errors on bad input | | `read_bytes(path)` / `write_bytes(path, bs)` | file I/O | path missing / permission | #### Bitwise ops — word-form infix (v3) + functional form

base64_encode

Function

Call diagnostics (different branches may describe different overloads): • base64_encode requires exactly 1 argument (Bytes) Extracted library reference: evaluator/builtin_bytes.go:287. These notes are not a complete signature or a stability guarantee. Manual §4.6.2 Conversions (explicit + fallible); read with manual "4.6.2" Excerpt: | `string_to_bytes(s, "utf-8")` | `Bytes` | encoding unknown | | `base64_encode(bs)` / `base64_decode(s)` | round-trip | decoder errors on bad input | | `read_bytes(path)` / `write_bytes(path, bs)` | file I/O | path missing / permission | #### Bitwise ops — word-form infix (v3) + functional form

bayesian_network

Function

Call diagnostics (different branches may describe different overloads): • bayesian_network requires no arguments Extracted library reference: evaluator/builtins.go:11778. These notes are not a complete signature or a stability guarantee.

bayesian_update

Function

bayesian_update(kb, hypothesis, evidence, prob_evidence_given_h) - Bayesian update Example: bayesian_update(kb, "disease", "positive_test", 0.95) Call diagnostics (different branches may describe different overloads): • bayesian_update requires 4 arguments: kb, hypothesis, evidence, P(E|H) • first argument must be a probabilistic logic KB • fourth argument must be a number (P(E|H)) • second argument must be a string (hypothesis) • third argument must be a string (evidence) Extracted library reference: evaluator/builtins.go:19226. These notes are not a complete signature or a stability guarantee.

because

Causal Logic

effect because cause
Explanatory operator. Expresses that something happens because of something else.

Examples

Smoke because Fire

Success because Effort

explanation: Result because Cause

bel

Function

bel …
Alternative spelling of belnap. See doc("belnap") for its meaning and call forms.

belboth

Symbol

=== ⊤⊥ᵇ (Glyph) === name: belnap_both latex: belboth, glut category: mvl codepoint: U+22A4 meaning: ⊤⊥ᵇ — Belnap B4 both (the glut; ≡ belnap("both"))

belfalse

Symbol

=== ⊥ᵇ (Glyph) === name: belnap_false latex: belfalse category: mvl codepoint: U+22A5 meaning: ⊥ᵇ — Belnap B4 false (≡ belnap("false"))

belief

Function

Call diagnostics (different branches may describe different overloads): • belief requires 2 arguments: hypothesis, probability • hypothesis must be a string • probability must be a number Extracted library reference: evaluator/builtins.go:11812. These notes are not a complete signature or a stability guarantee. Manual §10.3 Epistemic logic; read with manual "10.3" Excerpt: alice: agent("alice") b: believes(alice, "answer", 42) # record a belief; do not assert its content println(beliefs_of(alice)) # ["answer(42)"] assert answer(42) k: knows(alice, "answer", 42) # requires an existing supporting fact

believes

Epistemic Logic

agent believes proposition
Doxastic belief operator. Expresses that an agent believes a proposition with some confidence.

Examples

John believes false

Student believes hypothesis

opinion: Philosopher believes theory

belnap

Function

belnap("true" | "false" | "both" | "neither") — or the literals ⊤ᵇ ⊥ᵇ ⊤⊥ᵇ ?ᵇ
Belnap B4 truth-value constructor (paraconsistent four-valued logic: true / false / both / neither). The four values are also first-class LITERALS — ⊤ᵇ ⊥ᵇ ⊤⊥ᵇ ?ᵇ (digraphs `beltrue `belfalse `belboth `belneither, plus Priest's `glut / `gap; members Belnap.true / .false / .both / .neither / .glut / .gap; Belnap.values is the domain array) — so the constructor is the dynamic/coercion form (accepts Boolean, om, t/f/⊤/⊥ spellings). Operators dispatch automatically (and/or/not/implies/iff/xor); == is Boolean metalanguage equality coercing "both"-style strings; truthiness is DESIGNATION ({⊤ᵇ, ⊤⊥ᵇ} — a glut branches then, the gap branches else). Evidence combination lives on the knowledge order: b4_join (⊕) / b4_meet (⊗). Junk operands error (wrap strings with belnap(...)).

Examples

w: ⊤⊥ᵇ                          # ≡ belnap("both") — the glut literal

⊤ᵇ and ⊤⊥ᵇ                      # → ⊤⊥ᵇ (contamination propagates)

not ⊤⊥ᵇ                         # → ⊤⊥ᵇ (negating a glut keeps the glut)

belnap("true") == "true"        # → true (metalanguage equality coerces)

designated(⊤⊥ᵇ)                 # → true — and `if ⊤⊥ᵇ` takes the then-branch

match w with | ⊤⊥ᵇ => "glut" | ?ᵇ => "gap" | _ => "classical"   # literals are patterns

forall p in Belnap.values | designated(p or not p)   # → false (LEM's gap escape)

belnap_both

Symbol

=== ⊤⊥ᵇ (Glyph) === name: belnap_both latex: belboth, glut category: mvl codepoint: U+22A4 meaning: ⊤⊥ᵇ — Belnap B4 both (the glut; ≡ belnap("both"))

belnap_false

Symbol

=== ⊥ᵇ (Glyph) === name: belnap_false latex: belfalse category: mvl codepoint: U+22A5 meaning: ⊥ᵇ — Belnap B4 false (≡ belnap("false"))

belnap_neither

Symbol

=== ?ᵇ (Glyph) === name: belnap_neither latex: belneither, gap category: mvl codepoint: U+003F meaning: ?ᵇ — Belnap B4 neither (the gap; ≡ belnap("neither"))

belnap_true

Symbol

=== ⊤ᵇ (Glyph) === name: belnap_true latex: beltrue category: mvl codepoint: U+22A4 meaning: ⊤ᵇ — Belnap B4 true (≡ belnap("true"))

belneither

Symbol

=== ?ᵇ (Glyph) === name: belnap_neither latex: belneither, gap category: mvl codepoint: U+003F meaning: ?ᵇ — Belnap B4 neither (the gap; ≡ belnap("neither"))

beltrue

Symbol

=== ⊤ᵇ (Glyph) === name: belnap_true latex: beltrue category: mvl codepoint: U+22A4 meaning: ⊤ᵇ — Belnap B4 true (≡ belnap("true"))

bench

Keyword

bench "label" expr   |   bench "label" [ … ]   |   bench(label, fn)
Times an operand and returns a Dictionary `{label, elapsed_ms, result}`. The keyword form runs in the current environment: `bench "qsort" qsort(xs)`. The call `bench(label, fn)` times a thunk. Use `elapsed expr` when you only need how long.

Examples

r: bench "qsort" qsort(xs)

r: bench("qsort", func() [qsort(xs)])

println(r.label, r.elapsed_ms, r.result)

beta

Function

Call diagnostics (different branches may describe different overloads): • alpha must be a number • beta must be a number • beta requires 2 arguments: alpha, beta Extracted library reference: evaluator/builtins.go:11528. These notes are not a complete signature or a stability guarantee. Manual §22.4 Randomness — `random` / `random_seed` / `shuffle` / `sample`; read with manual "22.4" Excerpt: home, it lands in `prob`'s seedable source (the `normal`/`uniform`/ `binomial`/`beta` path) precisely so it does. ### Formatted output — `printf` / `stringf` / `format`

between

Function

between(space, point, point1, point2, [tolerance]) - Check betweenness Extracted library reference: evaluator/builtin_conceptual.go:666. These notes are not a complete signature or a stability guarantee. Manual §28.5.5 Expressions — `CAST`, `CASE`, `LIKE`, `BETWEEN`, `IN`, `EXISTS`; read with manual "28.5.5" Excerpt: #### Expressions — `CAST`, `CASE`, `LIKE`, `BETWEEN`, `IN`, `EXISTS` ```axioma # CAST — type conversion (CAST(expr AS type) and Postgres :: shorthand)

bf

Function

Registered alias of butfirst. Call diagnostics (different branches may describe different overloads): • butfirst expects one collection Extracted library reference: evaluator/builtin_logo.go:101. These notes are not a complete signature or a stability guarantee.

bfs

AI Function

bfs(graph, start_node, goal_node)
Performs Breadth-First Search to find optimal path from start to goal. Guarantees shortest path in unweighted graphs.

Examples

bfs(g, "A", "Z")

bfs(network, "source", "destination")

bidirectional

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §13.31 Auto-classification via `defines`; read with manual "13.31" Excerpt: (`is(x, C) → prop(x, val)` — every member has this property). `Concept defines { body }` is *bidirectional* (`is(x, C) ↔ body(x)` — membership iff predicate). See KM §17 for the canonical Mexican/Square contrast. **The three logical roles, separately surfaced:**

big_and

Function

big_and(domain, predicate)
Apply a predicate to a finite Set, Array, Tuple or Range. Return false at the first falsy result; return true if all pass, including an empty domain. This is a short-circuit Boolean quantifier fold; an open-ended Range is refused.

big_or

Function

Peirce's quantifiers-as-folds: ∃ = Σ (logical sum / n-ary OR), ∀ = Π (logical product / n-ary AND), the predicate a first-class value. Extracted library reference: evaluator/builtins.go:4941. These notes are not a complete signature or a stability guarantee.

bigcap

Function

bigCapBuiltin computes the generalized intersection ⋂ᵢ Aᵢ of a family of sets. Schaum §1.7 flags the empty-family case: the intersection of no sets would be the universal set, which has no representation here, so it errors. Call diagnostics (different branches may describe different overloads): • bigcap requires exactly 1 argument: bigcap(family) Extracted library reference: evaluator/builtins.go:1018. These notes are not a complete signature or a stability guarantee.

bigcup

Function

bigUnionBuiltin computes the generalized union ⋃ᵢ Aᵢ of a family of sets. The union over an empty family is the empty set. Call diagnostics (different branches may describe different overloads): • bigunion requires exactly 1 argument: bigunion(family) Extracted library reference: evaluator/builtins.go:998. These notes are not a complete signature or a stability guarantee.

bigintersect

Function

bigCapBuiltin computes the generalized intersection ⋂ᵢ Aᵢ of a family of sets. Schaum §1.7 flags the empty-family case: the intersection of no sets would be the universal set, which has no representation here, so it errors. Call diagnostics (different branches may describe different overloads): • bigcap requires exactly 1 argument: bigcap(family) Extracted library reference: evaluator/builtins.go:1018. These notes are not a complete signature or a stability guarantee.

bigunion

Function

bigUnionBuiltin computes the generalized union ⋃ᵢ Aᵢ of a family of sets. The union over an empty family is the empty set. Call diagnostics (different branches may describe different overloads): • bigunion requires exactly 1 argument: bigunion(family) Extracted library reference: evaluator/builtins.go:998. These notes are not a complete signature or a stability guarantee.

bin

Function

bin(n)
Binary digit string of an Integer (bin(5) → "101"). Manual §25.5 Runtime reflection — the self-describing surface; read with manual "25.5" Excerpt: ```axioma functions(Integer) # → ["abs", "add1", "bin", …, "zero?"] (sorted) functions("String") # same catalog by name (this spelling works under --vm) "divmod" in set(functions(Integer)) # → true functions() # → the cataloged type names (the doc-card set)

bind_stmt

Function

Call diagnostics (different branches may describe different overloads): • bind_stmt name must be a string • bind_stmt requires exactly 2 arguments (name, value) Extracted library reference: evaluator/builtins.go:1661. These notes are not a complete signature or a stability guarantee.

bind_stmt?

Function

Call diagnostics (different branches may describe different overloads): • bind_stmt? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1645. These notes are not a complete signature or a stability guarantee.

bindings

Function

bindings()
Sorted names the USER has bound this session — the seeded namespace (concepts, math constants, enum members, preludes) is subtracted, so a fresh session reports []. Evaluator-only. Shadowable.

Examples

x: 42

bindings()               # → ["x"]

binomial

Function

Call diagnostics (different branches may describe different overloads): • binomial requires 2 arguments: n, p • n must be an integer • p must be a number Extracted library reference: evaluator/builtins.go:11503. These notes are not a complete signature or a stability guarantee. Manual §22.4 Randomness — `random` / `random_seed` / `shuffle` / `sample`; read with manual "22.4" Excerpt: home, it lands in `prob`'s seedable source (the `normal`/`uniform`/ `binomial`/`beta` path) precisely so it does. ### Formatted output — `printf` / `stringf` / `format`

bit_and

Function

===== Bitwise operations ===== Functional form because Axioma's parser has no infix `&` / `|` / `^` / `<<` / `>>` operators today — adding them would touch the lexer, parser, and VM. The functional form unblocks bit-level work for byte manipulation now; an infix form can come later as a syntactic sugar over these builtins. All ops accept Byte or Integer arguments and return the same type as the inputs (Byte if both are Byte, Integer otherwise). Call diagnostics (different branches may describe different overloads): • bit_and requires exactly 2 arguments Extracted library reference: evaluator/builtin_bytes.go:330. These notes are not a complete signature or a stability guarantee. Manual §4.6.3 Bitwise ops — word-form infix (v3) + functional form; read with manual "4.6.3" Excerpt: # Functional form (still available — useful when you need a callable) bit_and(byte(0xF0), byte(0x0F)) # Byte(0x00) bit_or(byte(0xF0), byte(0x0F)) # Byte(0xFF) bit_xor(byte(0xFF), byte(0x0F)) # Byte(0xF0) bit_not(byte(0x0F)) # Byte(0xF0)

bit_not

Function

Call diagnostics (different branches may describe different overloads): • bit_not requires exactly 1 argument Extracted library reference: evaluator/builtin_bytes.go:357. These notes are not a complete signature or a stability guarantee. Manual §6.4.2 Logical negation — `not` / `¬` / `!` (and what `~` is not); read with manual "6.4.2" Excerpt: Perl-borrowed regex pair (`=~` match / `!~` non-match). Bitwise NOT is `bit_not(x)` — `bit_not(5)` → `-6`, `bit_not(0)` → `-1` — alongside `band`, `bor`, `bxor`, `bshl`, `bshr`. #### `nand` / `nor` — the Sheffer stroke `⊼` and Peirce arrow `⊽`

bit_or

Function

Call diagnostics (different branches may describe different overloads): • bit_or requires exactly 2 arguments Extracted library reference: evaluator/builtin_bytes.go:339. These notes are not a complete signature or a stability guarantee. Manual §4.6.3 Bitwise ops — word-form infix (v3) + functional form; read with manual "4.6.3" Excerpt: bit_and(byte(0xF0), byte(0x0F)) # Byte(0x00) bit_or(byte(0xF0), byte(0x0F)) # Byte(0xFF) bit_xor(byte(0xFF), byte(0x0F)) # Byte(0xF0) bit_not(byte(0x0F)) # Byte(0xF0) bit_shl(byte(1), 4) # Byte(0x10)

bit_shl

Function

Call diagnostics (different branches may describe different overloads): • bit_shl requires exactly 2 arguments (value, count) Extracted library reference: evaluator/builtin_bytes.go:373. These notes are not a complete signature or a stability guarantee. Manual §4.6.3 Bitwise ops — word-form infix (v3) + functional form; read with manual "4.6.3" Excerpt: bit_not(byte(0x0F)) # Byte(0xF0) bit_shl(byte(1), 4) # Byte(0x10) bit_shr(byte(0x80), 4) # Byte(0x08) reduce(bit_or, byte(0), bytes_to_array(bs)) # fold OR over bytes → Byte ```

bit_shr

Function

Call diagnostics (different branches may describe different overloads): • bit_shr requires exactly 2 arguments (value, count) Extracted library reference: evaluator/builtin_bytes.go:382. These notes are not a complete signature or a stability guarantee. Manual §4.6.3 Bitwise ops — word-form infix (v3) + functional form; read with manual "4.6.3" Excerpt: bit_shl(byte(1), 4) # Byte(0x10) bit_shr(byte(0x80), 4) # Byte(0x08) reduce(bit_or, byte(0), bytes_to_array(bs)) # fold OR over bytes → Byte ```

bit_xor

Function

Call diagnostics (different branches may describe different overloads): • bit_xor requires exactly 2 arguments Extracted library reference: evaluator/builtin_bytes.go:348. These notes are not a complete signature or a stability guarantee. Manual §4.6.3 Bitwise ops — word-form infix (v3) + functional form; read with manual "4.6.3" Excerpt: bit_or(byte(0xF0), byte(0x0F)) # Byte(0xFF) bit_xor(byte(0xFF), byte(0x0F)) # Byte(0xF0) bit_not(byte(0x0F)) # Byte(0xF0) bit_shl(byte(1), 4) # Byte(0x10) bit_shr(byte(0x80), 4) # Byte(0x08)

bl

Function

Registered alias of butlast. Call diagnostics (different branches may describe different overloads): • butlast expects one collection Extracted library reference: evaluator/builtin_logo.go:111. These notes are not a complete signature or a stability guarantee.

block

Function

Call diagnostics (different branches may describe different overloads): • block argument must be an array • block requires exactly 1 argument (array of statements/expressions) Extracted library reference: evaluator/builtins.go:16510. These notes are not a complete signature or a stability guarantee. Manual §28.1 28.1 The `[<dialect> | … ]` block; read with manual "28.1" Excerpt: ### 28.1 The `[<dialect> | … ]` block ```axioma mean: [python |

block?

Function

Call diagnostics (different branches may describe different overloads): • block? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1645. These notes are not a complete signature or a stability guarantee.

block_append

Function

Call diagnostics (different branches may describe different overloads): • block_append requires exactly 2 arguments (block, statement-or-expression) Extracted library reference: evaluator/builtins.go:16092. These notes are not a complete signature or a stability guarantee.

block_at

Function

Call diagnostics (different branches may describe different overloads): • block_at index must be an integer • block_at requires exactly 2 arguments (block, zero-based index) Extracted library reference: evaluator/builtins.go:16020. These notes are not a complete signature or a stability guarantee.

block_concat

Function

Call diagnostics (different branches may describe different overloads): • block_concat requires exactly 2 arguments (left_block, right_block) Extracted library reference: evaluator/builtins.go:16325. These notes are not a complete signature or a stability guarantee.

block_filter

Function

Call diagnostics (different branches may describe different overloads): • block_filter requires exactly 2 arguments (block, predicate) Extracted library reference: evaluator/builtins.go:16220. These notes are not a complete signature or a stability guarantee.

block_find

Function

Call diagnostics (different branches may describe different overloads): • block_find requires exactly 2 arguments (block, statement-or-expression) Extracted library reference: evaluator/builtins.go:16252. These notes are not a complete signature or a stability guarantee.

block_first

Function

Call diagnostics (different branches may describe different overloads): • block_first requires exactly 1 argument Extracted library reference: evaluator/builtins.go:16057. These notes are not a complete signature or a stability guarantee.

block_insert

Function

Call diagnostics (different branches may describe different overloads): • block_insert index must be an integer • block_insert requires exactly 3 arguments (block, zero-based index, statement-or-expression) Extracted library reference: evaluator/builtins.go:16112. These notes are not a complete signature or a stability guarantee.

block_len

Function

Call diagnostics (different branches may describe different overloads): • block_len requires exactly 1 argument Extracted library reference: evaluator/builtins.go:16006. These notes are not a complete signature or a stability guarantee.

block_map

Function

Call diagnostics (different branches may describe different overloads): • block_map requires exactly 2 arguments (block, function) Extracted library reference: evaluator/builtins.go:16186. These notes are not a complete signature or a stability guarantee.

block_remove

Function

Call diagnostics (different branches may describe different overloads): • block_remove index must be an integer • block_remove requires exactly 2 arguments (block, zero-based index) Extracted library reference: evaluator/builtins.go:16140. These notes are not a complete signature or a stability guarantee.

block_replace

Function

Call diagnostics (different branches may describe different overloads): • block_replace requires exactly 3 arguments (block, old, new) Extracted library reference: evaluator/builtins.go:16276. These notes are not a complete signature or a stability guarantee.

block_rest

Function

Call diagnostics (different branches may describe different overloads): • block_rest requires exactly 1 argument Extracted library reference: evaluator/builtins.go:16074. These notes are not a complete signature or a stability guarantee.

block_slice

Function

Call diagnostics (different branches may describe different overloads): • block_slice requires exactly 3 arguments (block, zero-based start, exclusive end) • block_slice start and end must be integers Extracted library reference: evaluator/builtins.go:16163. These notes are not a complete signature or a stability guarantee.

block_to_array

Function

Call diagnostics (different branches may describe different overloads): • block_to_array requires exactly 1 argument Extracted library reference: evaluator/builtins.go:16307. These notes are not a complete signature or a stability guarantee.

block_words

Function

Call diagnostics (different branches may describe different overloads): • block_words requires exactly 1 argument Extracted library reference: evaluator/builtins.go:16041. These notes are not a complete signature or a stability guarantee.

boolean

Function

boolean(value)
The truth value of anything, by Axioma's OWN truthiness — boolean(x) and `if x` consult the same predicate and so can never disagree. Only false, none and om are falsy; 0, "", [] and {} are all TRUTHY, and an Error is truthy by design (you try it, you do not if it). Total: there is no input it refuses. Added July 2026 — Boolean was the last primitive type with no coercion function. There is no nullary form: Boolean has two identity elements (true for and, false for or), so the identity-element rule refuses to pick one.

Examples

boolean(0)        # true  — zero is NOT falsy in Axioma

boolean("")       # true  — nor is the empty string

boolean([])       # true  — nor is an empty collection

boolean(none)     # false

boolean(om)       # false

boolean?

Function

Call diagnostics (different branches may describe different overloads): • boolean? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee. Manual §8.7 Formula type + predicate; read with manual "8.7" Excerpt: formula?(f) # true boolean?(f) # false ``` See [tests/axioma/logic/test_textbook_parity_tier1.ax](../../tests/axioma/logic/test_textbook_parity_tier1.ax)

bor

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §4.1.1 Integers don't overflow; read with manual "4.1.1" Excerpt: `0xFFFFFFFFFFFFFFFF` is 2⁶⁴−1 (a positive number), not Lua's `-1`. - **Bit operators** (`band`/`bor`/`bxor`/`bshl`/`bshr`) use Python's infinite-two's-complement reading: `bshl` is exact at any count (`1 bshl 63` = 2⁶³, `1 bshl 100` = 2¹⁰⁰), and `bshr` is an arithmetic shift that drains to `0` (or `-1` for negatives) past the width.

bot

Symbol

=== ⊥ (Glyph) === name: falsum latex: bot, perp category: logic codepoint: U+22A5 meaning: ⊥ — falsum (false)

boundary

Keyword

concept C { boundary: predicate }   |   { boundary~: predicate }
Inline membership rule on a concept block — compiles to the same auto-classifier as `C defines { predicate }`, co-located with the concept's purpose/examples/formed_by metadata. The defeasible boundary~ form caps derived memberships at conjecture grade even on an axiom-grade (stipulated) concept.

Examples

concept Adult { formed_by: "stipulation", boundary: age >= 18 and is Person }

concept Sage { formed_by: "stipulation", boundary~: age >= 65 and is Person }

box

Symbol

=== □ (Glyph) === name: box words: necessarily latex: Box, square variants: ◻ category: modal codepoint: U+25A1 meaning: □p — necessarily p (alethic necessity; true in all accessible worlds)

break

Keyword

break  |  break <expr>  |  break 'label  |  break 'label <expr>  |  if c then break
Exit a loop. Bare `break` leaves the innermost enclosing loop and yields none; `break v` (same-line, the same rule `return` uses) is the value that loop yields, so `n: loop [ break 123 ]` binds 123. A Word after break is a loop label (`break 'outer`, `break 'outer v`) — the loop is named `'outer: loop [ … ]` / `'outer: for …`, not `outer:` (that colon binds the result). Parenthesize to yield a Word: `break ('ok)`. Branch position (`if c then break v`) is sugar for `then [break v]`; both arms take it. There is NO postfix guard — `break if c` is not `return if`; write `if c then break`. Outside any loop it raises "break statement outside of loop" and halts the run. `--vm` refuses `break` (and the infinite `loop [ … ]` form) by name.

Examples

n: loop [ break 123 ]                  # n is 123

while true [ if done then break ]      # guarded exit

foreach i in a [ foreach j in b [ if p then break ] ]   # exits the INNER loop only

'outer: for n in xs [ for m in ys [ if p then break 'outer ] ]

found: 'search: loop [ break 'search cell ]

if x == 6 then "note" else break      # the else arm too

breakpoint

Function

breakpoint([line, ...])   |   breakpoint()
Debugging - pauses execution at the given line numbers so you can inspect state. At a hit, press Enter to continue or type 'inspect' for the debug inspector (list / show <var> / continue / quit). Called with no arguments it clears every breakpoint. ONLY PROMPTS WHEN STDIN IS A TERMINAL: under a pipe, redirect or CI it announces the hit and continues, so a forgotten breakpoint cannot wedge a headless run (and cannot swallow input meant for the program's own input()/prompt() calls). Shadowable - a user binding of the name wins.

Examples

breakpoint([15, 30])         # pause at lines 15 and 30

breakpoint()                 # clear all breakpoints

clearbreakpoints()           # the explicit spelling (see: clearbreakpoints)

broadcast

Function

broadcast(fn, [...args])
Eagerly apply fn elementwise to finite shaped arguments, expanding singleton axes aligned from the right. Strings and dictionaries are scalars. Ordinary broadcast calls materialize; nested dotted calls use fusion. Interpreter-only. Manual §6.10 Function broadcasting; read with manual "6.10" Excerpt: Ordinary function calls, including `broadcast(...)`, break fusion. Bind an intermediate result when separate evaluation is intended. Ordinary pipe stages are also boundaries; nested dotted expressions within a stage can fuse without changing pipe argument insertion.

bshl

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §4.1.1 Integers don't overflow; read with manual "4.1.1" Excerpt: `0xFFFFFFFFFFFFFFFF` is 2⁶⁴−1 (a positive number), not Lua's `-1`. - **Bit operators** (`band`/`bor`/`bxor`/`bshl`/`bshr`) use Python's infinite-two's-complement reading: `bshl` is exact at any count (`1 bshl 63` = 2⁶³, `1 bshl 100` = 2¹⁰⁰), and `bshr` is an arithmetic shift that drains to `0` (or `-1` for negatives) past the width.

bshr

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §4.1.1 Integers don't overflow; read with manual "4.1.1" Excerpt: `0xFFFFFFFFFFFFFFFF` is 2⁶⁴−1 (a positive number), not Lua's `-1`. - **Bit operators** (`band`/`bor`/`bxor`/`bshl`/`bshr`) use Python's infinite-two's-complement reading: `bshl` is exact at any count (`1 bshl 63` = 2⁶³, `1 bshl 100` = 2¹⁰⁰), and `bshr` is an arithmetic shift that drains to `0` (or `-1` for negatives) past the width.

builtin?

Function

Call diagnostics (different branches may describe different overloads): • builtin? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

builtins

Function

builtins() | builtins("name")
Sorted catalog of every registered builtin function name (the keywords() sibling). The 1-arg form is a membership check. Precise by design: lists the standard (VM-shared) table; env-aware builtins (tableform, grounding, …) are documented individually and found via apropos(). Works under --vm.

Examples

len(builtins())          # how many builtin functions exist

builtins("map")          # → true

[b | b <- builtins(), contains(b, "regex")]

butfirst

Function

Call diagnostics (different branches may describe different overloads): • butfirst expects one collection Extracted library reference: evaluator/builtin_logo.go:101. These notes are not a complete signature or a stability guarantee. Manual §13.37 Hidden slots, scanners, turtles, and concatenative extras; read with manual "13.37" Excerpt: `#language axioma/rpn` is additive (infix still runs). Textbook: HtDKP-in-Axioma Chapter 41. Logo selectors: `butfirst`, `butlast`, `logo_item`, `sentence`. ---

butlast

Function

Call diagnostics (different branches may describe different overloads): • butlast expects one collection Extracted library reference: evaluator/builtin_logo.go:111. These notes are not a complete signature or a stability guarantee. Manual §13.37 Hidden slots, scanners, turtles, and concatenative extras; read with manual "13.37" Excerpt: HtDKP-in-Axioma Chapter 41. Logo selectors: `butfirst`, `butlast`, `logo_item`, `sentence`. ---

bxor

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §4.1.1 Integers don't overflow; read with manual "4.1.1" Excerpt: `0xFFFFFFFFFFFFFFFF` is 2⁶⁴−1 (a positive number), not Lua's `-1`. - **Bit operators** (`band`/`bor`/`bxor`/`bshl`/`bshr`) use Python's infinite-two's-complement reading: `bshl` is exact at any count (`1 bshl 63` = 2⁶³, `1 bshl 100` = 2¹⁰⁰), and `bshr` is an arithmetic shift that drains to `0` (or `-1` for negatives) past the width.

by

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §4.8 Ranges — ordered `a..b`, exclusive `..<`, `by` step, open `n..`; read with manual "4.8" Excerpt: ### Ranges — ordered `a..b`, exclusive `..<`, `by` step, open `n..` `a..b` is a first-class **ordered** `Range` value — it knows its direction, its step, and (optionally) that it has no end. It displays compactly, tests

by_default

Keyword

Mark a default-logic expression: a defeasible conclusion may depend on the active default theory. This belongs to the experimental reasoning surface.

byte

Function

byte(n)
A single Byte (0..255) — out-of-range errors. Manual §4.6 Binary data — `Byte` and `Bytes`; read with manual "4.6" Excerpt: ### Binary data — `Byte` and `Bytes` Distinct from `Integer` and `String` so the type system can dispatch byte-specific operations and so `bs[0] == 0xff` reads as a `Byte`/`Byte` comparison rather than implicit coercion. The cost is verbosity, the win is no silent UTF-8 corruption.

bytes

Function

bytes(values...)
Bytes from a String (UTF-8), an array, or variadic byte values; bytes() is empty. Manual §4.6 Binary data — `Byte` and `Bytes`; read with manual "4.6" Excerpt: ### Binary data — `Byte` and `Bytes` Distinct from `Integer` and `String` so the type system can dispatch byte-specific operations and so `bs[0] == 0xff` reads as a `Byte`/`Byte` comparison rather than implicit coercion. The cost is verbosity, the win is no silent UTF-8 corruption.

bytes_to_array

Function

Call diagnostics (different branches may describe different overloads): • bytes_to_array requires exactly 1 argument (Bytes) Extracted library reference: evaluator/builtin_bytes.go:150. These notes are not a complete signature or a stability guarantee. Manual §4.6.2 Conversions (explicit + fallible); read with manual "4.6.2" Excerpt: |---|---|---| | `bytes_to_array(bs)` | `Array` of `Byte` (≡ `bs[i]` elements; `bytes(arr)` round-trips) | never | | `bytes_to_hex(bs)` | `"ff00ab"` | never | | `hex_to_bytes(s)` | `Bytes` | input has odd length or non-hex chars | | `bytes_to_string(bs, "utf-8")` | `String` | bytes aren't valid UTF-8 |

bytes_to_hex

Function

Call diagnostics (different branches may describe different overloads): • bytes_to_hex requires exactly 1 argument (Bytes) Extracted library reference: evaluator/builtin_bytes.go:168. These notes are not a complete signature or a stability guarantee. Manual §4.6.2 Conversions (explicit + fallible); read with manual "4.6.2" Excerpt: | `bytes_to_array(bs)` | `Array` of `Byte` (≡ `bs[i]` elements; `bytes(arr)` round-trips) | never | | `bytes_to_hex(bs)` | `"ff00ab"` | never | | `hex_to_bytes(s)` | `Bytes` | input has odd length or non-hex chars | | `bytes_to_string(bs, "utf-8")` | `String` | bytes aren't valid UTF-8 | | `string_to_bytes(s, "utf-8")` | `Bytes` | encoding unknown |

bytes_to_string

Function

Call diagnostics (different branches may describe different overloads): • bytes_to_string requires 1-2 arguments (Bytes, [encoding]) Extracted library reference: evaluator/builtin_bytes.go:200. These notes are not a complete signature or a stability guarantee. Manual §4.6.2 Conversions (explicit + fallible); read with manual "4.6.2" Excerpt: | `hex_to_bytes(s)` | `Bytes` | input has odd length or non-hex chars | | `bytes_to_string(bs, "utf-8")` | `String` | bytes aren't valid UTF-8 | | `string_to_bytes(s, "utf-8")` | `Bytes` | encoding unknown | | `base64_encode(bs)` / `base64_decode(s)` | round-trip | decoder errors on bad input | | `read_bytes(path)` / `write_bytes(path, bs)` | file I/O | path missing / permission |

call

Function

Call diagnostics (different branches may describe different overloads): • call args must be an array • call requires exactly 2 arguments (function, args) Extracted library reference: evaluator/builtins.go:16370. These notes are not a complete signature or a stability guarantee. Manual §25.4 `doc` — statement and call form; read with manual "25.4" Excerpt: ### `doc` — statement and call form `doc` is a language statement, not just a REPL command — it works in scripts too, and it has a **call twin** that prints the identical text through the

call_expr?

Function

Call diagnostics (different branches may describe different overloads): • call_expr? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1645. These notes are not a complete signature or a stability guarantee.

called

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §6.10 Function broadcasting; read with manual "6.10" Excerpt: Dictionary, are scalar arguments. Nested Arrays remain elements: they do not create additional axes. With only scalars the function is called once; with an empty output it is not called. Unbounded/lazy iterators must be bounded and collected before broadcasting.

cancel

Function

cancel(relation, args...)
Marks a derived fact as defeated — the defeasible-logic escape hatch ("birds fly, EXCEPT penguins"). Provenance is preserved; comprehensions filter the fact out. Grounding-aware: refuses to defeat a strict THEOREM (revise a premise instead, or use force_cancel). Conjectures, hypotheses, and base posits stay directly cancelable.

Examples

flies(X) <~~ bird(X)

assert bird("pingu")

cancel("flies", "pingu")

canceled

Function

canceled(relation, args...)
Returns true if the fact has been suppressed with cancel(). Siblings: uncancel() removes the marker; force_cancel() overrides the theorem guard.

Examples

canceled("flies", "pingu")  # true after cancel

cap

Symbol

=== ∩ (Glyph) === name: intersect words: intersect, intersection latex: cap category: set codepoint: U+2229 meaning: A ∩ B — intersection (members in both sets)

capitalize

Function

capitalize(s)
First character up, every other character down ("hELLO WORLD" → "Hello world"). Manual §4.5.6 Case mapping — `upper` / `lower` / `title` (and Julia aliases); read with manual "4.5.6" Excerpt: `title`. A Character in is a Character out (`uppercase('a')` is `'A'`). `uppercasefirst` is not `capitalize` (Julia leaves the rest of the string alone) and is not shipped. #### Operators

cardinality

Function

cardinality(Concept, "slot", min [, max])
Registers a min/max cardinality bound on a concept property (description-logic style). Violations on write are recorded as non-fatal violation markers.

Examples

cardinality(Person, "age", 1, 1)

case

Keyword

case expr | pattern [when guard] => body | …
The same matcher as `match expr with`, without a preposition: keyword, value, then `|` arms. Reserved (not a name — use `$case`). `case/strict` is `match/strict`. First `|` is required (the value is an expression). `of`/`with`/`do` after the value are SyntaxErrors. Arm arrows: `=>` or `->`. `switch` is the ReasonML spelling of the same form. Evaluator-only: `--vm` refuses.

Examples

case pair | (1, x, 3) => x | _ => 0

case pair
| (1, x, 3) => x
| _ => 0

case/strict 1 | 1 => "one" | _ => "no"

switch pair | (1, x, 3) => x | _ => 0

case_library

Function

case_library(name, description)
Creates a new case library for storing and managing cases in Case-Based Reasoning. Roger Schank's CBR implementation.

Examples

case_library("Medical Cases", "Diagnostic case library")

case_library("Engineering Designs", "Design pattern library")

case_library_stats

Function

case_library_stats(library)
Returns comprehensive statistics about a case library including case count, feature distribution, and indexing information.

Examples

case_library_stats(medical_lib)

stats: case_library_stats(library); print(stats)

case_similarity

Function

case_similarity(case1, case2 [, method])
Calculates similarity between two cases using various algorithms: 'weighted' (default), 'euclidean', 'cosine'. Core similarity computation for CBR.

Examples

case_similarity(case1, case2)

case_similarity(case1, case2, "euclidean")

case_similarity(case1, case2, "cosine")

catch

Keyword

catch  |  catch e  |  catch e is Kind
Clause of end-form try. First matching arm runs. Typed `catch e is Kind` before the untyped catch-all. RESERVED: `$catch` is the name; `[catch e]` stays a word list.

Examples

try
    1 / 0
catch e is DivByZero
    0
catch e
    42
end

causally

Causal Logic

cause causally effect
Causal relationship operator. Expresses that one thing causally produces another.

Examples

Fire causally Smoke

Training causally Improvement

causation: Cause causally Effect

cbr_engine

Function

cbr_engine(case_library)
Creates a complete Case-Based Reasoning engine with the specified case library. Provides integrated CBR capabilities with configurable parameters.

Examples

cbr_engine(medical_library)

cbr_engine(design_library)

cd_primitive?

Function

Registered alias of is_cd_primitive. Call diagnostics (different branches may describe different overloads): • is_cd_primitive requires 1 argument: primitive Extracted library reference: evaluator/builtin_words.go:107. These notes are not a complete signature or a stability guarantee.

cd_primitives

Function

Call diagnostics (different branches may describe different overloads): • cd_primitives requires 0 arguments Extracted library reference: evaluator/builtin_words.go:80. These notes are not a complete signature or a stability guarantee.

cd_roles

Function

Call diagnostics (different branches may describe different overloads): • cd_roles requires 1 argument: primitive Extracted library reference: evaluator/builtin_words.go:92. These notes are not a complete signature or a stability guarantee.

ceil

Function

ceil(x)
Smallest integer ≥ x — exact at any magnitude. Manual §22.3 Mathematical functions; read with manual "22.3" Excerpt: | `floor(x)` | Floor | | `ceil(x)` | Ceiling | | `pow(b, e)` | Exponentiation | | `sin(x)` / `cos(x)` / `tan(x)` | Trigonometry — arguments in **radians** (like Lua/C); convert with `rad`/`deg` | | `asin(x)` / `acos(x)` / `atan(x)` | Inverse trig, radians (`asin`/`acos` domain-checked). `atan(y, x)` 2-arg is the full-quadrant form (Lua 5.3+ `math.atan`) |

ceiling

Function

ceiling(x)
Smallest integer ≥ x — exact alias of `ceil`. Manual §12.9 Arity overloads — one name, several parameter counts; read with manual "12.9" Excerpt: The **ceiling** is the widest arity declared for the name; more arguments than that is an error at every arity (`no clause of 'e' accepts 3 argument(s)`), and `--typecheck` reports it ahead of the run. A `...rest` slot on any one of the overloads lifts the ceiling for the name entirely.

cg_format

Function

Call diagnostics (different branches may describe different overloads): • argument must be a conceptual graph • cg_format requires 1 argument: graph Extracted library reference: evaluator/builtins.go:10216. These notes are not a complete signature or a stability guarantee.

cg_join

Function

Call diagnostics (different branches may describe different overloads): • cg_join requires 2 arguments: graph1, graph2 • first argument must be a conceptual graph • second argument must be a conceptual graph Extracted library reference: evaluator/builtins.go:10194. These notes are not a complete signature or a stability guarantee.

cg_visualize

Function

Call diagnostics (different branches may describe different overloads): • cg_visualize requires 1-2 arguments: graph [, layout] • first argument must be a conceptual graph • layout must be a string Extracted library reference: evaluator/builtins.go:10233. These notes are not a complete signature or a stability guarantee.

chain

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §14.5 Variable chain unification; read with manual "14.5" Excerpt: ### Variable chain unification ```axioma # Equivalent to Prolog: grandparent(X,Z) :- parent(X,Y), parent(Y,Z)

challenge

Function

challenge(relation, args...)
Marks an axiom as suspect. Axioms are foundational but not sacred — any fact on the ladder must remain challengeable. Pair with challenged() to query the flag, and forget/forget_cascade to actually retract.

Examples

axiom parent("john", "mary")

challenge("parent", "john", "mary")

challenged("parent", "john", "mary")  # true

challenged

Function

challenged(relation, args...)
Returns true if the fact has been marked suspect with challenge().

Examples

challenged("parent", "john", "mary")

char

Function

charBuiltin is `char(...)`: the constructor. There is no nullary form. The constructor invariant admits one exactly when the type has a genuine identity element — a container's empty, a number's zero — and there is no zero character. NUL is not one: it is precisely the invented value (`""`, `0x0`, an epoch) the invariant names, and it would then flow through comparison and alphabet membership as genuine data. A loud arity error beats a quiet U+0000. Extracted library reference: evaluator/character.go:52. These notes are not a complete signature or a stability guarantee. Manual §22.8 List & string helpers; read with manual "22.8" Excerpt: unique!([1, 2, 2, 3, 1]) # → [1, 2, 3] in-place; unique(xs) is the copy chars("abc") # → ["a", "b", "c"] (string → char array) explode("abc") # → ["a", "b", "c"] (SML spelling; exact alias of chars) implode(["a", "b", "c"]) # → "abc" (inverse of explode/chars) implode(explode("日本語")) # → "日本語" (round-trip over runes)

char_alphabetic?

Function

charClassPredicate: char_alphabetic? / char_numeric? / char_whitespace? over a single-character string. Call diagnostics (different branches may describe different overloads): • char_alphabetic? requires a single-character string • char_alphabetic? requires exactly 1 argument Extracted library reference: evaluator/scheme_extras.go:738. These notes are not a complete signature or a stability guarantee. Manual §22.8 List & string helpers; read with manual "22.8" Excerpt: # member(collection, target) — Axioma order, not SML List.member(element, list) char_alphabetic?("a") # → true (also char_numeric? / char_whitespace?) ``` ### Knowledge-base builtins

char_numeric?

Function

charClassPredicate: char_alphabetic? / char_numeric? / char_whitespace? over a single-character string. Call diagnostics (different branches may describe different overloads): • char_numeric? requires a single-character string • char_numeric? requires exactly 1 argument Extracted library reference: evaluator/scheme_extras.go:738. These notes are not a complete signature or a stability guarantee. Manual §22.8 List & string helpers; read with manual "22.8" Excerpt: # member(collection, target) — Axioma order, not SML List.member(element, list) char_alphabetic?("a") # → true (also char_numeric? / char_whitespace?) ``` ### Knowledge-base builtins

char_whitespace?

Function

charClassPredicate: char_alphabetic? / char_numeric? / char_whitespace? over a single-character string. Call diagnostics (different branches may describe different overloads): • char_whitespace? requires a single-character string • char_whitespace? requires exactly 1 argument Extracted library reference: evaluator/scheme_extras.go:738. These notes are not a complete signature or a stability guarantee. Manual §22.8 List & string helpers; read with manual "22.8" Excerpt: # member(collection, target) — Axioma order, not SML List.member(element, list) char_alphabetic?("a") # → true (also char_numeric? / char_whitespace?) ``` ### Knowledge-base builtins

characteristic_numbers

Function

characteristic_numbers(RootConcept)
Arithmetizes a LIVE concept hierarchy — Leibniz's actual program. Walks the extends-tree under the root, assigns a prime per branch, returns the taxonomy and makes it active. Categorical sentences over those concept names are then decided by divisibility, and is_subtype_of provably agrees with the `is` copula — two engines, one ontology.

Examples

Dog extends Creature

characteristic_numbers(Creature)

every Dog is Creature    # true, by arithmetic

chars

Function

chars(s)
Characters (runes) of a String, as an Array. Manual §22.8 List & string helpers; read with manual "22.8" Excerpt: unique!([1, 2, 2, 3, 1]) # → [1, 2, 3] in-place; unique(xs) is the copy chars("abc") # → ["a", "b", "c"] (string → char array) explode("abc") # → ["a", "b", "c"] (SML spelling; exact alias of chars) implode(["a", "b", "c"]) # → "abc" (inverse of explode/chars) implode(explode("日本語")) # → "日本語" (round-trip over runes)

check

Automated Reasoning

check Concept | check function | check proposition [using strategy]
On a Concept, verifies the formation contract and returns a Belnap B4 verdict: ⊤ᵇ if every listed example classifies in and no counterexample does, ⊥ᵇ if the boundary misclassifies one, ⊤⊥ᵇ if an entity appears in both lists, ?ᵇ if the contract is vacuous (no examples/counterexamples). On a user FUNCTION, verifies its declared contract (see `doc contract`) over the contract's examples: plus trials: draws from generate: — or, when generate: is absent and every parameter carries a supported :: annotation, from auto-generated draws (the summary says 'auto trials'). ⊤ᵇ all ensures: hold (a classify: labeler adds a distribution census line), ⊥ᵇ a counterexample or call error was found — the witness is SHRUNK to a minimal failing input first (deterministic; the report shows `shrunk from: (…) in N steps`), ?ᵇ no contract, no input source, or every input skipped by requires:. Runs under the ambient seeded RNG (fixed startup seed), so an unseeded check is reproducible; generated inputs are SIZED — they start small and grow across the run (a generate: function may take one `size` parameter to receive the ramp; a zero-arg one is unchanged). A Concept carrying a `contract Concept { operations: [...] }` declaration instead gets STATEFUL checking: random sequences of those operations run against fresh instances, with the concept's invariant: as the oracle; a failure prints the operation SEQUENCE, shrunk to the fewest operations that still break it, and every trial's instance is released so the extent is left untouched. On propositions, performs consistency checking.

Examples

concept Adult { boundary: age >= 18 and is Person, examples: [alice], counterexamples: [kid] }

check Adult   # ⊤ᵇ when the boundary honors the contract

contract maximum { ensures: result[1] in a, generate: func() [ [random(-99, 99), random(-99, 99)] ] }

check maximum   # ⊤ᵇ, or ⊥ᵇ with a counterexample report

contract Account { operations: [deposit, withdraw], steps: 12, trials: 40 }

check Account   # stateful: ⊥ᵇ plus the operation sequence that broke the invariant

check "system consistency"

check_derivation

Function

check_derivation(text [, system]) — check a Lemmon-style derivation in the book's four-column format: `deps (n) formula justification`, columns separated by 2+ spaces. Rules: P Conj Simp DN RAA Add DS MP MT C BE BI | EG ES US UG QN | IE II | D ND ◇I □I □E □□ ◇ B. The system argument (T, B, S4, S5 — default S5) gates the modal rules. Returns {valid, sequent, system, errors, lines}. Call diagnostics (different branches may describe different overloads): • check_derivation requires 1-2 arguments: text [, system] • check_derivation: first argument must be a string • check_derivation: system must be a string (T, B, S4 or S5) Extracted library reference: evaluator/builtins.go:17405. These notes are not a complete signature or a stability guarantee.

check_double_negation

Function

check_double_negation(expr) - Check if ¬¬P → P holds Returns false in intuitionistic logic (DNE not valid) Example: check_double_negation(func(p) [ (not (not p)) implies p ]) Call diagnostics (different branches may describe different overloads): • check_double_negation requires 1 argument: proposition Extracted library reference: evaluator/builtins.go:18175. These notes are not a complete signature or a stability guarantee.

check_effect

Function

Call diagnostics (different branches may describe different overloads): • check_effect: before and after must be Integers Extracted library reference: evaluator/builtin_word_effect.go:74. These notes are not a complete signature or a stability guarantee. Manual §13.37 Hidden slots, scanners, turtles, and concatenative extras; read with manual "13.37" Excerpt: Forth extras: `stack_dip` / `stack_keep` / `stack_cleave`; word `effect: "( n -- n^2 )"` with `word_effect` / `check_effect`; return stack `rpush` / `rpop` / `rpeek` / `rdepth` / `rclear`. `#language axioma/rpn` is additive (infix still runs). Textbook: HtDKP-in-Axioma Chapter 41. Logo selectors: `butfirst`,

check_explosion

Function

check_explosion(model, p, q) - Check if explosion (P ∧ ¬P) → Q holds Should return false in paraconsistent logic Example: check_explosion(pm, "p", "q") Call diagnostics (different branches may describe different overloads): • check_explosion requires 3 arguments: model, p, q • first argument must be a paraconsistent model • second argument must be a string (proposition p) • third argument must be a string (proposition q) Extracted library reference: evaluator/builtins.go:18268. These notes are not a complete signature or a stability guarantee.

check_lem

Function

check_lem(expr) - Check if Law of Excluded Middle (P ∨ ¬P) holds Returns false in intuitionistic logic for non-decidable propositions Example: check_lem(func(p) [ p or (not p) ]) Call diagnostics (different branches may describe different overloads): • check_lem requires 1 argument: proposition Extracted library reference: evaluator/builtins.go:18160. These notes are not a complete signature or a stability guarantee.

check_tfl_derivation

Function

check_tfl_derivation(text) — check a TFL proof in the book's format `(n) formula justification`, with the appendix rules P Com Assoc DN It Simp Conj EN IN PD UD DON WQ Taut (pp. 180–182). Call diagnostics (different branches may describe different overloads): • check_tfl_derivation requires 1 argument: derivation text • check_tfl_derivation: argument must be a string Extracted library reference: evaluator/builtins.go:17667. These notes are not a complete signature or a stability guarantee.

chicken_game

Function

chicken_game()
Return the built-in two-player Chicken game (Swerve or Straight). Payoff pairs are (0,0), (-1,1), (1,-1), (-10,-10), in row-major strategy order. These are fixed example models, not empirical predictions.

choice

Function

Call diagnostics (different branches may describe different overloads): • choice options must be an array or set Extracted library reference: evaluator/builtins.go:15141. These notes are not a complete signature or a stability guarantee. Manual §25.8 Reading a value — `read_integer()` / `read_float()` / `read_string()`; read with manual "25.8" Excerpt: `input_number`, `prompt`, `choice`, `confirm`, and `menu` share the same persistent stdin reader, so sequential calls consume successive lines under a pipe. The token readers share it too.

choose

Function

choose(n, k)
Computes the binomial coefficient (n choose k), representing the number of ways to choose k items from n. Alias: `nCr`, `combinations`.

Examples

choose(5, 2)   # Returns 10

chr

Function

chr(codepoint)
Unicode codepoint → 1-character String (chr(8707) → "∃"). Manual §4.5.5 Codepoint builtins — `chr` and `ord`; read with manual "4.5.5" Excerpt: #### Codepoint builtins — `chr` and `ord` For programmatic codepoint construction (when the literal form can't help because the value comes from runtime):

chunk

Function

chunkBuiltinFn groups consecutive equal elements into runs (compared by Inspect()) — e.g. chunk([1,1,2,3,3]) → [[1,1],[2],[3,3]]. Call diagnostics (different branches may describe different overloads): • chunk requires exactly 1 argument: a collection Extracted library reference: evaluator/builtins.go:23076. These notes are not a complete signature or a stability guarantee. Manual §12.17 Enumerable verbs; read with manual "12.17" Excerpt: each_cons(2, [1, 2, 3, 4]) # → [[1,2], [2,3], [3,4]] sliding windows chunk([1, 1, 2, 3, 3]) # → [[1,1], [2], [3,3]] group consecutive-equal runs detect(func(x) [x > 3], [1, 2, 3, 4]) # → 4 first element matching (none if no match) compact([1, none, 2, none, 3]) # → [1, 2, 3] drop none (keeps om and everything else) [3, 1, 2] |> sort |> tap(func(a) [println(a)]) # peek mid-pipeline, return the value unchanged

ci

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §3.15 Formatting a file — `--fmt`; read with manual "3.15" Excerpt: `--fmt-check` writes nothing and exits 1 when any file would change, which is the form to use in CI or a pre-commit hook. **`--fmt-diff`** is the same gate with the detail — it prints the unified diff instead of just the filename: ```bash

circ

Symbol

=== ∘ (Glyph) === name: ring latex: circ category: function codepoint: U+2218 meaning: f ∘ g — function composition, right-to-left: (f ∘ g)(x) = f(g(x)); mirror of compose(g, f)

circular_permutations

Function

circular_permutations(n)
Arrangements of n things around a circle, where rotations coincide: (n−1)!. Leibniz's 'variation of neighborhood' (De Arte Combinatoria 1666, Problem V — the seating order of guests at a round table).

Examples

circular_permutations(4)   # 6

cl_count

Function

Call diagnostics (different branches may describe different overloads): • cl_count requires environment (this should not be called) Extracted library reference: evaluator/builtins.go:5595. These notes are not a complete signature or a stability guarantee.

cl_derive

Function

Call diagnostics (different branches may describe different overloads): • cl_derive requires environment (this should not be called) Extracted library reference: evaluator/builtins.go:5609. These notes are not a complete signature or a stability guarantee.

cl_exists

Function

Call diagnostics (different branches may describe different overloads): • cl_exists requires environment (this should not be called) Extracted library reference: evaluator/builtins.go:5588. These notes are not a complete signature or a stability guarantee.

cl_explain

Function

Call diagnostics (different branches may describe different overloads): • cl_explain requires environment (this should not be called) Extracted library reference: evaluator/builtins.go:5623. These notes are not a complete signature or a stability guarantee.

cl_infer

Function

Call diagnostics (different branches may describe different overloads): • cl_infer requires environment (this should not be called) Extracted library reference: evaluator/builtins.go:5602. These notes are not a complete signature or a stability guarantee.

cl_prove

Function

Call diagnostics (different branches may describe different overloads): • cl_prove requires environment (this should not be called) Extracted library reference: evaluator/builtins.go:5616. These notes are not a complete signature or a stability guarantee.

cl_query

Function

Call diagnostics (different branches may describe different overloads): • cl_query requires environment (this should not be called) Extracted library reference: evaluator/builtins.go:5573. These notes are not a complete signature or a stability guarantee.

cl_translate

Function

Builtin functions for constrained language system translate() - Translate constrained language between English and Lojban Usage: translate(stmt, to: "lojban") or translate(stmt, to: "english") Call diagnostics (different branches may describe different overloads): • translate requires 2 arguments: translate(statement, to: language) Extracted library reference: evaluator/builtin_constrained_language.go:17. These notes are not a complete signature or a stability guarantee.

classify

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §12.11 Contracts — `requires` / `ensures` / `check f`; read with manual "12.11" Excerpt: | `examples:` | Array/Set of argument tuples `check` always runs first (deterministic anchors). | | `classify:` | A function over the same arguments returning a String label; `check` prints the label **distribution** under `CHECK PASS` (see below). | | `trials:` | How many generated draws `check` makes (default 100). | Enforcement is **always on** for a contracted function — the cost is

classify_dl

Function

classify_dl(kb) - Classify the knowledge base (build subsumption hierarchy) Example: classify_dl(kb) → hierarchy map Call diagnostics (different branches may describe different overloads): • argument must be a DL knowledge base • classify_dl requires 1 argument: kb Extracted library reference: evaluator/builtins.go:18578. These notes are not a complete signature or a stability guarantee.

clear

Function

Call diagnostics (different branches may describe different overloads): • argument to clear must be a stack • clear requires 1 argument: stack Extracted library reference: evaluator/builtins.go:12132. These notes are not a complete signature or a stability guarantee. Manual §18.1 Core operations; read with manual "18.1" Excerpt: | `depth(s)` / `stacklength(s)` | `→ n` | Current number of items | | `clear(s)` / `erase(s)` | `… →` | Empty the stack | ### Stack-shuffle operations

clear_screen

Function

Call diagnostics (different branches may describe different overloads): • clear_screen takes no arguments Extracted library reference: evaluator/builtins.go:15311. These notes are not a complete signature or a stability guarantee.

clear_trace_log

Function

clear_trace_log()
Reflection - drops the accumulated trace transcript, leaving the active domains untouched (clearing mid-trace keeps tracing on and simply restarts the log). Deliberately NOT folded into `untrace`: you read the log after stopping the trace, so clearing there would destroy what you came for. The test shape is clear → run → assert. Shadowable - a user binding of the name wins.

Examples

clear_trace_log()            # start from an empty transcript

len(trace_log())             # → 0

clear_universe

Function

clear_universe() - Clear the universal set from environment Use this when done with complement operations Example: clear_universe() Call diagnostics (different branches may describe different overloads): • clear_universe() takes no arguments Extracted library reference: evaluator/builtins.go:8210. These notes are not a complete signature or a stability guarantee.

clearbreakpoints

Function

clearbreakpoints()
Debugging - clears every breakpoint set by `breakpoint`. Equivalent to a no-argument `breakpoint()`. Shadowable - a user binding of the name wins.

Examples

clearbreakpoints()           # remove all breakpoints

close_solutions

Function

close_solutions(stream)
Release retained search state. An open stream becomes cancelled, never complete. Closing again is harmless. Pulling a cancelled stream raises an error.

closure

Function

Call diagnostics (different branches may describe different overloads): • closure requires exactly 1 argument Extracted library reference: evaluator/builtins.go:7917. These notes are not a complete signature or a stability guarantee. Manual §19.7.1 The domains; read with manual "19.7.1" Excerpt: | `epistem` | `assert` / `axiom` / `postulate` / derivation, with the grounding tier | the whole ladder — `axiom`, `postulate`, `theorem`, `conjecture`, `hypothesis`, `datum` — plus `assert`, `retract`, `derive` | | `func` | function application and closure creation | `lambda`, `closure` | | `quantifiers` | `forall` / `exists` | `quantifier`, `forall`, `exists` | | `reasoning` | rule firing and inference, including the recursive walk | `rule`, `inference` | | `relations` | relation queries and unification, with answer counts | `relation`, `unification`, `query`, `queries` |

cnf?

Function

Registered alias of is_cnf.is_cnf(expr) - Check if expression is in Conjunctive Normal Form Returns true if the expression is already in CNF form Call diagnostics (different branches may describe different overloads): • is_cnf requires exactly 1 argument: a boolean expression Extracted library reference: evaluator/builtins.go:16916. These notes are not a complete signature or a stability guarantee.

Cognitive Science Features

Concept

Features aligned with cognitive science research
Axioma implements modern cognitive science concepts: graded categorization, prototype effects, hierarchical organization, and similarity-based reasoning.

Examples

# Graded categorization (not just boolean)

similarity(Robin, Bird)     # 0.8 (very typical)

similarity(Penguin, Bird)   # 0.6 (less typical)



# Prototype effects

typicality(Robin)           # High (good prototype)

typicality(Ostrich)         # Lower (atypical bird)



# Hierarchical reasoning

Robin partOf Bird

Bird partOf Animal

Robin relatedTo Animal      # Transitive relationship

cognitive_word?

Function

Call diagnostics (different branches may describe different overloads): • cognitive_word? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

collect

Function

collect(iterable)
Collect iteration values into an Array; consumes finite generators, rejects known infinite inputs. Interpreter-only. Manual §5.14 Matrices, tensors & dataframes; read with manual "5.14" Excerpt: `elements(m)` and `each(m)` return a fresh single-use Generator; `collect(m)` and finite collection verbs such as `map`, `filter`, and `reduce` gather the same ordered cells. `collect` retains its allocation limit. Materializing is explicit and does not make `len(m)` / `size(m)` valid: dimensions still come from `shape(m)`.

combinations

Function

combinations(n, k)
Alias for `choose` (and `nCr`). Computes the binomial coefficient (n choose k).

Examples

combinations(5, 2)   # Returns 10

common_ancestor

Function

common_ancestor(taxonomy, a, b)
The most specific common genus of two encodings, computed as their GCD and decoded back to a path.

Examples

common_ancestor(porphyry, 10374, 66)   # → substance → material (body, 6)

compact

Function

compactBuiltinFn drops absent (none/null) elements, keeping om and everything else (Ruby's compact, where nil ≈ Axioma's none). Preserves the source kind for Array/Set; a Tuple compacts to an Array. Call diagnostics (different branches may describe different overloads): • compact requires exactly 1 argument: a collection Extracted library reference: evaluator/builtins.go:23154. These notes are not a complete signature or a stability guarantee. Manual §12.17 Enumerable verbs; read with manual "12.17" Excerpt: detect(func(x) [x > 3], [1, 2, 3, 4]) # → 4 first element matching (none if no match) compact([1, none, 2, none, 3]) # → [1, 2, 3] drop none (keeps om and everything else) [3, 1, 2] |> sort |> tap(func(a) [println(a)]) # peek mid-pipeline, return the value unchanged # the payoff — a readable left-to-right pipeline:

compile

Function

compile("program") | compile('(expr))
Compile a SELF-CONTAINED program (a source String or a quoted AST) to bytecode for the VM, once; returns a callable that runs it on a fresh VM per call and yields the program's last value (results normalize onto the evaluator's values, so truthiness and == behave). The program is a sub-program, not a closure over the session: a free identifier is a loud compile-time error, and state does not persist between calls. Constructs outside the VM-compilable subset (relations, rules, set comprehensions, …) return a catchable Error — try(compile(src)) is the first in-language probe of the evaluator-only/VM boundary. eval runs the full language; compile runs the compiled subset.

Examples

c: compile("fib: func(n) [if n < 2 then n else fib(n-1) + fib(n-2)]\nfib(25)")

c()                        # runs the bytecode (call it as often as you like)

compile('(6 * 7))()        # a quoted AST compiles too → 42

try(compile("relation r(x)"))   # catchable: outside the VM subset

complement

Function

complement(set, [universe]) - Compute set complement relative to universe Mathematical: A^c = U \ A (where U is the universal set) Requires universe to be defined first via universe() function, OR provide explicit universe Example 1: universe({1..10}); complement({2,4,6,8,10}) → {1,3,5,7,9} Example 2: complement({2,4,6}, {1,2,3,4,5,6}) → {1,3,5} Call diagnostics (different branches may describe different overloads): • complement() requires 1-2 arguments: complement(set) or complement(set, universe) Extracted library reference: evaluator/builtins.go:8161. These notes are not a complete signature or a stability guarantee. Manual §22.7 Higher-order functions; read with manual "22.7" Excerpt: constantly(x) # → a function that ignores its args and returns x negate(pred) # → a predicate that logically negates pred (≠ set `complement`) neg(n) # → -n (exact alias of negate; also neg(pred)) ```

completeness

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §16.3 Complete and incomplete relation queries; read with manual "16.3" Excerpt: cannot use an incomplete positive extent to establish absence. This contract describes the evaluator's relation-query engine; it does not claim completeness for every separate reasoning or solver API. Relation declarations remain outside the VM's supported subset.

complex

Function

complex(re, im)
Complex number re + im·i. Manual §14.6 Complex term matching; read with manual "14.6" Excerpt: ### Complex term matching ```axioma relation person(x, attr1, attr2)

complex?

Function

Call diagnostics (different branches may describe different overloads): • complex? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

complexes

Value

Built-in INFINITE_SET value: InfiniteSet(complexes) Manual §5.10.1 Ellipsis sets — textbook `{2, 4, ..., 100}` / `{2, 4, 6, ...}`; read with manual "5.10.1" Excerpt: **The standard number sets.** The chain **ℕ ⊂ ℤ ⊂ ℚ ⊂ ℝ ⊂ ℂ** is built in. The identifiers `rationals` / `reals` / `complexes` and the glyphs `ℚ` / `ℝ` / `ℂ` are membership sets: ```axioma

compose

Function

compose(f, g, ...)
Composes relations or functions LEFT-TO-RIGHT: compose(f, g)(x) is g(f(x)) — f runs first, the same as the `>>` operator. The direction is fixed by relation composition, which compose has always performed: a function is its graph, so composing two function graphs and composing the two functions give the same answer. Note this is the mathematician's `g ∘ f` (spelled `<<` in ASCII); it reads as a pipeline, agreeing with pipe() and `|>`. All arguments must be sets (relation composition) or all functions (function composition) — mixing the two is an error. The first stage receives every argument; each later stage receives the single value its predecessor produced. compose() with no arguments is the identity element and compose(f) is f, so a stage list of any length folds.

Examples

compose(double, incr)(5)              # Returns 11 — double first, then incr

(double >> incr)(5)                   # Returns 11 — the operator form

compose(double, incr)(5) == pipe(5, double, incr)   # true — same order

compose({(1,2)}, {(2,3)})             # Returns {(1, 3)} — relation composition

compose()(5)                          # Returns 5 — the identity element

compose_mappings

Function

compose_mappings(mapping1, mapping2) - Compose two mappings Extracted library reference: evaluator/builtin_conceptual_mapping.go:98. These notes are not a complete signature or a stability guarantee.

computational_philosophy

System

Various philosophical operators and commands
Axioma implements a complete computational philosophy system based on Leibniz's Universal Characteristica, supporting modal logic, epistemic reasoning, automated inference, and philosophical computation.

Examples

# Modal Logic: necessarily, possibly, contingently

# Epistemic Logic: knows, believes with certainty measures

# Deontic Logic: ought, permitted, forbidden

# Automated Reasoning: derive, check with confidence metrics

# See individual operators for detailed usage

compute_extensions

Function

compute_extensions(theory) - Compute all extensions Example: compute_extensions(dt) Call diagnostics (different branches may describe different overloads): • argument must be a default theory • compute_extensions requires 1 argument: theory Extracted library reference: evaluator/builtins.go:19657. These notes are not a complete signature or a stability guarantee.

concept

Keyword

concept Name ["doc"] | concept/persist Name | concept Name { slot: default, ... } | concept Name { slot :: Type: default, ... } | concept Name with … end | concept Name extends Parent [implements I1, ...] {}
Declares a concept (a category/class). The block form sets default slots; a slot may carry a type — `price :: Integer: 0`, or `age :: Integer` to start as none — that every later write must satisfy (creation, assignment, record update, later default), with an Integer converting for a Float slot, and `show properties` prints it; a postfix string attaches documentation; the /persist, /transient and /system refinements control knowledge-base persistence. Inheritance via extends (single) and implements (multiple interfaces). Add slots after declaration with `Name has slot: default`. Formation-layer slots (purpose, formed_by, boundary, examples, counterexamples) carry concept-design metadata — see formed_by. Lifecycle: `Name suspend`, `Name unsuspend`, `Name destroy`.

Examples

concept Person { name: "", age: 0 }

concept Measure { ratio :: Float: 1.0, label: "free" }

concept Stock "a tradable equity"

concept Airplane extends Vehicle implements Flyable {}

Airplane has wingspan: 35

concept?

Function

Call diagnostics (different branches may describe different overloads): • concept? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee. Manual §13.2 Defining concepts; read with manual "13.2" Excerpt: classifies an instance, `X is Concept` (in expression position) asks "is this a registered concept?", and a statement-level `Stock is Concept` is a parser error pointing at `concept Stock`. **Define-family form** (`define concept`) — fills the typed-define

concept_and

Function

concept_and(kb, name1, name2) - Create intersection concept (C ⊓ D) Example: concept_and(kb, "Student", "Employee") → WorkingStudent Call diagnostics (different branches may describe different overloads): • concept names must be strings • concept_and requires 3 arguments: kb, concept1, concept2 • first argument must be a DL knowledge base Extracted library reference: evaluator/builtins.go:18629. These notes are not a complete signature or a stability guarantee.

concept_not

Function

concept_not(kb, name) - Create negation concept (¬C) Example: concept_not(kb, "Student") → NonStudent Call diagnostics (different branches may describe different overloads): • concept name must be a string • concept_not requires 2 arguments: kb, concept • first argument must be a DL knowledge base Extracted library reference: evaluator/builtins.go:18695. These notes are not a complete signature or a stability guarantee.

concept_or

Function

concept_or(kb, name1, name2) - Create union concept (C ⊔ D) Example: concept_or(kb, "Student", "Professor") → AnyPerson Call diagnostics (different branches may describe different overloads): • concept names must be strings • concept_or requires 3 arguments: kb, concept1, concept2 • first argument must be a DL knowledge base Extracted library reference: evaluator/builtins.go:18662. These notes are not a complete signature or a stability guarantee.

conceptnet_capableof

Function

conceptnet_capableof(concept) - Get "CapableOf" ability relations Call diagnostics (different branches may describe different overloads): • conceptnet_capableof argument must be a string • conceptnet_capableof requires exactly 1 argument (concept) Extracted library reference: evaluator/builtins.go:21076. These notes are not a complete signature or a stability guarantee.

conceptnet_isa

Function

conceptnet_isa(concept) - Get "IsA" taxonomic relations Call diagnostics (different branches may describe different overloads): • conceptnet_isa argument must be a string • conceptnet_isa requires exactly 1 argument (concept) Extracted library reference: evaluator/builtins.go:21013. These notes are not a complete signature or a stability guarantee.

conceptnet_partof

Function

conceptnet_partof(concept) - Get "PartOf" meronymic relations Call diagnostics (different branches may describe different overloads): • conceptnet_partof argument must be a string • conceptnet_partof requires exactly 1 argument (concept) Extracted library reference: evaluator/builtins.go:21034. These notes are not a complete signature or a stability guarantee.

conceptnet_query

Function

==================================================================================== CONCEPTNET INTEGRATION - Common-Sense Knowledge Graph ==================================================================================== conceptnet_query(concept, [relation], [limit]) - Query ConceptNet for related concepts Call diagnostics (different branches may describe different overloads): • conceptnet_query first argument must be a string • conceptnet_query requires 1-3 arguments (concept, [relation], [limit]) Extracted library reference: evaluator/builtins.go:20867. These notes are not a complete signature or a stability guarantee.

conceptnet_related

Function

conceptnet_related(concept, [relation]) - Get related concepts Call diagnostics (different branches may describe different overloads): • conceptnet_related first argument must be a string • conceptnet_related requires 1-2 arguments (concept, [relation]) Extracted library reference: evaluator/builtins.go:20934. These notes are not a complete signature or a stability guarantee.

conceptnet_relations

Function

conceptnet_relations(concept) - Get all relations grouped by type Call diagnostics (different branches may describe different overloads): • conceptnet_relations argument must be a string • conceptnet_relations requires exactly 1 argument (concept) Extracted library reference: evaluator/builtins.go:20980. These notes are not a complete signature or a stability guarantee.

conceptnet_usedfor

Function

conceptnet_usedfor(concept) - Get "UsedFor" purpose relations Call diagnostics (different branches may describe different overloads): • conceptnet_usedfor argument must be a string • conceptnet_usedfor requires exactly 1 argument (concept) Extracted library reference: evaluator/builtins.go:21055. These notes are not a complete signature or a stability guarantee.

concepts

Function

concepts()
Sorted names of every Concept visible from the call site — seeded primitive-type concepts (Integer, Float, …) and user-declared ones alike. Filter with comprehensions. Evaluator-only (walks the live environment). Shadowable: a user binding named `concepts` wins.

Examples

concepts()               # the full concept landscape

"Integer" in set(concepts())   # → true

concepts_formed_by

Function

concepts_formed_by(mode)
Returns every concept whose formed_by: slot equals the given formation mode ("abstraction", "combination", "distinction", "stipulation", "metaphor"). Useful for KB audits — "show me everything stipulated by fiat".

Examples

concepts_formed_by("stipulation")

conceptual_graph

Function

============================ John Sowa's Conceptual Graphs Functions ============================ Call diagnostics (different branches may describe different overloads): • conceptual_graph requires at least 1 argument: context • context must be a string Extracted library reference: evaluator/builtins.go:10073. These notes are not a complete signature or a stability guarantee.

conceptual_space

Function

Conceptual Space Builtin Functions Total: 21 core functions for comprehensive conceptual space support All functions are registered in evaluator/builtins.go GetBuiltins() conceptual_space(name, [description]) - Create conceptual space Extracted library reference: evaluator/builtin_conceptual.go:14. These notes are not a complete signature or a stability guarantee.

conceptual_to_semantic

Function

============================================================================ SEMANTIC NETWORK BRIDGES ============================================================================ conceptual_to_semantic(space, threshold) - Convert conceptual space to semantic network Creates edges between prototypes based on similarity threshold Extracted library reference: evaluator/builtin_conceptual_bridges.go:22. These notes are not a complete signature or a stability guarantee.

conceptually

Reserved vocabulary

Reserved vocabulary with no dedicated parser implementation in this build. It is not a usable standalone form. Use doc "discover" for the implemented discovery interface, and manual for supported language forms. Recognition of a name is not a claim that its intended feature is implemented.

cond

Keyword

cond | predicate => body | else => body
Predicate dispatch. Reserved keyword (not a name — use `$cond` to bind that spelling). Desugars to chained `if`/`else if` (full `--vm` parity). Arms may wrap; the first `|` is optional. Catch-all arms: `else`, `otherwise`, `_`. No catch-all → `none`. Arm arrows: `=>` or `->`.

Examples

cond | n > 0 => "pos" | n < 0 => "neg" | else => "zero"

cond | false => 1 | otherwise => 2

cond | false => 1 | _ => 3

confirm

Function

Extracted library reference: evaluator/builtins.go:15226. These notes are not a complete signature or a stability guarantee. Manual §25.8 Reading a value — `read_integer()` / `read_float()` / `read_string()`; read with manual "25.8" Excerpt: `input_number`, `prompt`, `choice`, `confirm`, and `menu` share the same persistent stdin reader, so sequential calls consume successive lines under a pipe. The token readers share it too.

confluence

Function

confluenceBuiltins are registered from GetBuiltins. Extracted library reference: evaluator/confluence.go:1100. These notes are not a complete signature or a stability guarantee. Manual §33.13 Confluence — does the clause ORDER matter?; read with manual "33.13" Excerpt: ### Confluence — does the clause ORDER matter? A multi-clause function is a **term rewrite system**: patterns are left-hand sides, bodies are right-hand sides, and one dispatch is one rewrite step. Axioma

conj

Function

conj(z)
Complex conjugate.

conjugate

Function

conjugate(z)
Complex conjugate: conjugate(a + bi) = a - bi. Manual §4.1 Primitives; read with manual "4.1" Excerpt: | `Rational` | `1/3`, `rational(2, 6)` → `1/3` | Exact `p/q` on big integers, GCD-reduced — `/` on integers stays exact (`1/3 + 1/6` → `1/2`, never `0.4999…`); accessors `numerator(r)` / `denominator(r)` | | `Complex` | `complex(3, 4)` → `3.0 + 4.0i`; `im` → `i` | The **top of the numeric tower** — every other numeric type embeds, so `complex(3, 4) + 1/2` → `3.5 + 4i`. The unit is the shadowable builtin `im` (`complex(0, 1)`); write `1 + im`, `(1 + im)^2` → `2i`, `2 * im`. No juxtaposed literal: `2im` is diagnosed (same as `2x`). Full arithmetic incl. `^` (exact at integer exponents: `im^2` → `-1`) and unary minus; `sqrt`/`exp`/`log`/`sin`/`cos`/`abs`/`conjugate` all accept one. No ordering. Embedding is via `float64`, so exactness stops here. Coefficients use the same Float printer | | `String` | `"hello"`, `"unicode: ∀∃"`, `"\u{2203}"`, `r"raw \n"` | UTF-8; escape sequences + `r"..."` raw prefix — see [Strings](#strings--escape-sequences-raw-form-codepoint-builtins) | | `Boolean` | `true`, `false` | Classical two-valued | | `Byte` | `byte(0xFF)` | Single byte 0..255; distinct from `Integer`. See [Binary data](#binary-data--byte-and-bytes) |

connect

Keyword

Introduce the connection clause of a conceptual-graph statement. See doc "conceptual_graph" and doc "join"; this is graph construction vocabulary, not a network connection command.

cons

Function

cons(element, list) | element cons list
Prepends an element onto a List in O(1), sharing the tail — the original list is untouched (persistent). The second argument must be a List (proper lists only, no dotted pairs). Infix `h cons t` is the same call, right-associative: `4 cons 2 cons 3 cons list()` is `cons(4, cons(2, cons(3, list())))`. `:` is binding and `::` is ascription; they are not cons.

Examples

m: cons(0, list([1, 2]))  # `[0, 1, 2]

m: 0 cons list([1, 2])    # the same, written infix

4 cons 2 cons 3 cons list()  # `[4, 2, 3]

acc: cons(x, acc)         # the accumulate idiom; reverse(acc) closes it

consistency

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §13.4 Concept formation layer (Phase 1); read with manual "13.4" Excerpt: `AutomatedReasoningObject` wrapper (`check 42` still returns the generic consistency-check string). **Phase 2b-2** adds the `boundary:` slot and the active application of `default_grounding`. A `boundary:` value is a *predicate*, not an open

const

Keyword

const NAME = value
Declares a program-level named constant: one name, one value — cannot be reassigned or shadowed, in either direction. TOP-LEVEL ONLY (August 2026): inside a function the immutable local is `let`. Takes `=` only. The binding is constant, not the value (a const array can still be pushed). The retired `given` was its alias.

Examples

const MY_PI = 3.14159

const MAX_SIZE = 1000

const/persist CONFIG = {...}

const/transient TEMP_FLAG = true

constant

Function

Call diagnostics (different branches may describe different overloads): • constant requires at least 1 argument Extracted library reference: evaluator/builtins.go:5071. These notes are not a complete signature or a stability guarantee. Manual §3.1.1 Pattern binding (ML-style tuple patterns); read with manual "3.1.1" Excerpt: A failed match (wrong arity, non-tuple value, or a constant that does not equal the corresponding component) raises a catchable error — SML's `Bind` exception. No name is left partially bound. A paren pattern matches only a **Tuple** (not an Array). An array/cons pattern `[h | t]` matches an Array

constantly

Function

constantly(value)
constantly(x) returns a function that ignores every argument and always returns x. See kestrel for the curried two-slot variant. Manual §22.7 Higher-order functions; read with manual "22.7" Excerpt: for_each(fn, coll) # apply fn for side effects; returns none constantly(x) # → a function that ignores its args and returns x negate(pred) # → a predicate that logically negates pred (≠ set `complement`) neg(n) # → -n (exact alias of negate; also neg(pred)) ```

constrain

Function

constrain(Concept, "slot", predicate)
Registers a write-time validation predicate on a concept slot. Invalid writes are rejected with a warning and the previous value is preserved.

Examples

constrain(Airplane, "year", lambda y => y >= 1903)

plane.year: 1800   # rejected, slot unchanged

contains

Operator

container contains element
Tests if a container (concept, set, array) contains an element. Works with concepts for semantic containment.

Examples

{1, 2, 3} contains 2

["a", "b", "c"] contains "b"

Mammal contains Dog         # Concept hierarchy

animals contains Dog        # Set membership

context_assert

Function

Call diagnostics (different branches may describe different overloads): • context_assert requires 5-6 arguments: graph, context_id, element_id, fact, truth [, confidence] • fifth argument must be a string (truth: true, false, both, neither) • first argument must be a context graph • fourth argument must be a string (fact) • second argument must be a string (context_id) • sixth argument must be a number (confidence) • third argument must be a string (element_id) Extracted library reference: evaluator/builtins.go:10636. These notes are not a complete signature or a stability guarantee.

context_create

Function

Call diagnostics (different branches may describe different overloads): • context_create requires 4-5 arguments: graph, id, label, type [, logic] • first argument must be a context graph • fourth argument must be a string (type: temporal, epistemic, source, hypothetical, domain) • second argument must be a string (id) • third argument must be a string (label) Extracted library reference: evaluator/builtins.go:10594. These notes are not a complete signature or a stability guarantee.

context_diff

Function

Call diagnostics (different branches may describe different overloads): • context_diff requires 3 arguments: graph, ctx1_id, ctx2_id • first argument must be a context graph • second argument must be a string (ctx1_id) • third argument must be a string (ctx2_id) Extracted library reference: evaluator/builtins.go:10755. These notes are not a complete signature or a stability guarantee.

context_graph

Function

===================================================================== CONTEXT GRAPHS — Multi-Context Systems (McCarthy ist(c,p)) Situational layers: temporal, epistemic, source, hypothetical, domain ===================================================================== Call diagnostics (different branches may describe different overloads): • context_graph requires 1-2 arguments: id [, label] • first argument must be a string (id) Extracted library reference: evaluator/builtins.go:10573. These notes are not a complete signature or a stability guarantee.

context_lift

Function

Call diagnostics (different branches may describe different overloads): • all arguments must be strings • context_lift requires 5 arguments: graph, from_ctx, to_ctx, element_id, fact • first argument must be a context graph Extracted library reference: evaluator/builtins.go:10788. These notes are not a complete signature or a stability guarantee.

context_lower

Function

Call diagnostics (different branches may describe different overloads): • arguments must be strings • context_lower requires 3 arguments: graph, from_ctx, to_ctx • first argument must be a context graph Extracted library reference: evaluator/builtins.go:10816. These notes are not a complete signature or a stability guarantee.

context_merge

Function

Call diagnostics (different branches may describe different overloads): • context_merge requires 4-5 arguments: graph, ctx1_id, ctx2_id, new_id [, strategy] • first argument must be a context graph • fourth argument must be a string (new_id) • second argument must be a string (ctx1_id) • third argument must be a string (ctx2_id) Extracted library reference: evaluator/builtins.go:10711. These notes are not a complete signature or a stability guarantee.

context_project

Function

Call diagnostics (different branches may describe different overloads): • context_project requires 2 arguments: graph, context_id • first argument must be a context graph • second argument must be a string (context_id) Extracted library reference: evaluator/builtins.go:10685. These notes are not a complete signature or a stability guarantee.

context_query

Function

Call diagnostics (different branches may describe different overloads): • context_query requires 1-4 arguments: graph [, element_pattern, fact_pattern, context_types] • first argument must be a context graph Extracted library reference: evaluator/builtins.go:10868. These notes are not a complete signature or a stability guarantee.

context_resolve

Function

Call diagnostics (different branches may describe different overloads): • arguments must be strings • context_resolve requires 3 arguments: graph, element_id, fact • first argument must be a context graph Extracted library reference: evaluator/builtins.go:10842. These notes are not a complete signature or a stability guarantee.

context_set_parent

Function

Call diagnostics (different branches may describe different overloads): • arguments must be strings • context_set_parent requires 3 arguments: graph, child_id, parent_id • first argument must be a context graph Extracted library reference: evaluator/builtins.go:10935. These notes are not a complete signature or a stability guarantee.

context_stats

Function

Call diagnostics (different branches may describe different overloads): • context_stats requires 1 argument: graph • first argument must be a context graph Extracted library reference: evaluator/builtins.go:10905. These notes are not a complete signature or a stability guarantee.

contingently

Modal Logic

contingently expression
Modal contingency operator. Expresses that a proposition is contingently true (could be true or false).

Examples

contingently true

contingently (the weather tomorrow)

continue

Keyword

continue  |  continue 'label  |  if c then continue
Skip the rest of the current iteration and advance a loop. Bare `continue` is the innermost enclosing loop; `continue 'outer` advances the loop named `'outer: …`. Branch position (`if c then continue`) is sugar for `then [continue]`; both arms take it, and there is no postfix guard. In the condition-bearing `repeat` forms (block-condition and `until`) `continue` falls through to the EXIT TEST rather than skipping it, so a continue-heavy loop still terminates (verified: the example below exits at n = 6). Outside any loop it raises "continue statement outside of loop" and halts the run.

Examples

foreach x in xs [ if x % 2 == 1 then continue
  evens: push(evens, x) ]

'rows: for n in 1..3 [ for m in 1..3 [ if m == 2 then continue 'rows ] ]

repeat [n < 6] [ n: n + 1
  if n % 2 == 0 then continue ]   # still exits at n = 6

contract

Functions

contract name { purpose: "…", requires: expr, ensures: expr, decreases: expr, generate: func([size]) [...], examples: [...], classify: func(...) [...], param: { requires: …, ensures: … }, trials: n }  |  contract Concept { operations: [...], steps: n, trials: n }
Attaches a declared contract to a user function (soft keyword — `contract: value` bindings keep working). Slots, all optional: purpose: (prose, shown by describe), requires: (precondition over the parameter names; repeatable, conjunction, checked before the body — a false clause is a catchable `contract violated:` Error), ensures: (postcondition over parameters + `result`; repeatable, checked after the body — inside ensures, old(e) denotes the value e had ON ENTRY to the call, captured by value with composites deep-copied; a binding named `old` in scope wins and the operator stands down), decreases: (termination measure over the parameters — an Integer ≥ 0 that must STRICTLY decrease on every recursive activation, self-tail-call iterations included; violations are catchable `measure did not decrease (a → b)` Errors, and the measure stays live under `check` so a non-terminating recursion fails a trial instead of hanging), generate: (zero-arg function returning one argument tuple per call — a Tuple splats to multiple arguments — or a ready-made collection), examples: (Array/Set of argument tuples `check` always runs), classify: (function over the same arguments returning a String label — `check` prints the label distribution under CHECK PASS), trials: (generated draws under `check`, default 100). When generate: is absent and EVERY parameter carries a supported :: annotation (Integer/Float/String/Boolean), `check` auto-generates draws from the annotations. Enforcement is always on for a contracted function; re-declaring replaces. Guards vs requires: a `when` guard SELECTS among clauses (no match → om), requires: REJECTS loudly. Concepts have the instance-level twin: `concept X { invariant: predicate }` is checked after instantiation and after every direct property write (violating writes REVERT; a violating creation is stillborn). A function-valued PARAMETER may carry a nested sub-contract — `f: { requires: arg >= 0, ensures: result >= arg }`, whose clauses speak positionally (`arg`, `arg1`…`argN`, `args`, `result`): the incoming function is wrapped so the guard travels with it, and violations carry a `blame:` line naming the party at fault (a sub-contract's requires blames the CALLEE for calling it outside its domain; its ensures blames the CALLER for supplying a function that breaks its own promise). A CONCEPT target declares stateful checking instead — `contract Account { operations: [...], steps: n, trials: n }` — driven by `check Account`. `prove f` is the STATIC twin of `check f`: it discharges the contract for ALL inputs through the SMT solver rather than sampling (⊤ᵇ discharged, ⊥ᵇ with a real counterexample, ?ᵇ not discharged). Evaluator-only — under --vm the statement rejects and calls run unenforced.

Examples

maximum: func(a) [ ... ]

contract maximum { requires: len(a) > 0, ensures: result[1] in a }

maximum([])      # ERROR: contract violated: maximum requires clause 1 (len(a) > 0)

check maximum    # generated-input verification → Belnap verdict

contract push_end { ensures: len(result) == old(len(xs)) + 1 }   # pre-state via old()

contract fact { requires: n >= 0, decreases: n }   # dynamic termination measure

concept Account { balance: 0, invariant: balance >= 0 }   # the concept twin

contract twice { f: { requires: arg >= 0 }, ensures: result >= x }   # higher-order sub-contract

contract Account { operations: [deposit, withdraw], steps: 12 }   # stateful checking

prove maximum   # STATIC discharge for all inputs (the check twin)

contradiction

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §4.4 Multi-valued logic types; read with manual "4.4" Excerpt: (`contradiction` itself is a reserved word — hence `glut`, which is also Priest's term for the value.) ### Strings — escape sequences, raw form, codepoint builtins

contradicts

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §13.25 Inferred polymorphic types — `axioma --infer`; read with manual "13.25" Excerpt: `x + 1` and `x + "s"`) included. The single exception is a *declared* return the body contradicts: that type was inferred, and it disagrees with something you wrote, so it exits 1. - **Arithmetic is structural.** `+ - * %` type as "operands and result are one type", so `add :: (a, a) -> a` means any *one* type consistently — the

control?

Function

charPredicate wraps a rune classifier as a builtin accepting a Character or a one-character String. Call diagnostics (different branches may describe different overloads): • control? requires exactly 1 argument Extracted library reference: evaluator/character.go:81. These notes are not a complete signature or a stability guarantee.

converge

Function

converge(combiner, [f, g, ...])
The FORK: applies several functions to the SAME input and combines their results. converge(combiner, [f, g])(x) is combiner(f(x), g(x)). Composition builds a chain; converge builds a branch that reconverges — the shape a mean has (sum and length of one input, divided). Every branch receives the full argument list, so a fork can start from a multi-argument function. The branch list is an Array so the combiner stays in first position, matching map/filter/reduce.

Examples

converge(div, [total, count_of])([2,4,6,8])   # Returns 5 — the mean

converge(pair_up, [incr, double])(3)          # Returns [4, 6]

converge(pair_up, [add, mul])(3, 4)           # Returns [7, 12] — both args reach both branches

converse

Function

converse(categorical_proposition)
The classical conversion of a proposition, with validity COMPUTED over all region models rather than table-looked-up: E and I convert simply (swap the terms), A converts per accidens (every S is P → some P is S — valid only with existential import), O does not convert. Returns {converse, kind, valid, valid_boolean}.

Examples

converse(no human is stone)      # simple, valid

converse(every human is animal)  # per_accidens — valid only w/ import

copy

Function

Extracted library reference: evaluator/builtins.go:9909. These notes are not a complete signature or a stability guarantee. Manual §21.2 Deep copy; read with manual "21.2" Excerpt: ### Deep copy `copy(value)` returns an independent deep copy:

corrcoef

Function

Call diagnostics (different branches may describe different overloads): • argument to corrcoef must be a matrix • corrcoef requires exactly 1 argument: matrix Extracted library reference: evaluator/builtins.go:14183. These notes are not a complete signature or a stability guarantee.

cos

Function

cos(x)
Cosine (radians). Manual §22.3 Mathematical functions; read with manual "22.3" Excerpt: | `pow(b, e)` | Exponentiation | | `sin(x)` / `cos(x)` / `tan(x)` | Trigonometry — arguments in **radians** (like Lua/C); convert with `rad`/`deg` | | `asin(x)` / `acos(x)` / `atan(x)` | Inverse trig, radians (`asin`/`acos` domain-checked). `atan(y, x)` 2-arg is the full-quadrant form (Lua 5.3+ `math.atan`) | | `atan2(y, x)` | Full-quadrant arctangent — the C/Python spelling of `atan(y, x)` (`atan2(1, 0)` → `pi/2`) | | `sinh(x)` / `cosh(x)` / `tanh(x)` | Hyperbolic functions |

cosh

Function

cosh(x)
Hyperbolic cosine. Manual §22.3 Mathematical functions; read with manual "22.3" Excerpt: | `atan2(y, x)` | Full-quadrant arctangent — the C/Python spelling of `atan(y, x)` (`atan2(1, 0)` → `pi/2`) | | `sinh(x)` / `cosh(x)` / `tanh(x)` | Hyperbolic functions | | `deg(x)` | Radians → degrees (`deg(pi)` → `180`; Lua `math.deg`) | | `rad(x)` | Degrees → radians (`rad(180)` → `pi`; `sin(rad(90))` → `1`; Lua `math.rad`) | | `quotient(a, b)` / `a quotient b` | Floor division, rounding toward −∞ (same as `a ÷ b` / `a div b`) |

cosine

Function

Vector / embedding helpers for neuro-symbolic retrieve (Aug 2026). Thin bridge only — not a training framework. cosine(a, b) → Float in [-1, 1] (0 if a zero-norm vector) top_k(query, items, k) → Array of {id, score, item} sorted by score desc Vectors are Arrays of numbers. Optional Observation entities: if an item is an Observation ConcreteEntity, its .embedding slot is used when present. Call diagnostics (different branches may describe different overloads): • cosine requires exactly 2 arguments: vector_a, vector_b Extracted library reference: evaluator/builtin_embeddings.go:20. These notes are not a complete signature or a stability guarantee. Manual §33.16 Embeddings — `cosine` / `top_k` (thin neuro retrieve); read with manual "33.16" Excerpt: ### Embeddings — `cosine` / `top_k` (thin neuro retrieve) Vector similarity for RAG-style **candidate retrieval**. Not a training stack: retrieve → **filter symbolically** → treat hits as `observation(...)`, never as

count

Function

count(collection, [target])
Characters of a String / cardinality; with target, occurrence count. Manual §28.5.4 Aggregates — `GROUP BY`, `HAVING`, `COUNT/SUM/AVG/MIN/MAX`; read with manual "28.5.4" Excerpt: #### Aggregates — `GROUP BY`, `HAVING`, `COUNT/SUM/AVG/MIN/MAX` ```axioma # Single-column GROUP BY with COUNT

cov

Function

Call diagnostics (different branches may describe different overloads): • argument to cov must be a matrix • cov requires exactly 1 argument: matrix Extracted library reference: evaluator/builtins.go:14164. These notes are not a complete signature or a stability guarantee.

createFormalSystem

Function

=== GÖDEL'S INCOMPLETENESS THEOREM FUNCTIONS === Call diagnostics (different branches may describe different overloads): • createFormalSystem requires exactly 1 argument (system name) • createFormalSystem requires string argument Extracted library reference: evaluator/builtins.go:6577. These notes are not a complete signature or a stability guarantee.

createGodelSentence

Function

Call diagnostics (different branches may describe different overloads): • createGodelSentence takes 0 or 1 arguments Extracted library reference: evaluator/builtins.go:6639. These notes are not a complete signature or a stability guarantee.

create_canvas

Function

Create custom visualization canvas Call diagnostics (different branches may describe different overloads): • create_canvas requires 1-3 arguments: title [, width, height] • first argument must be a string (title) Extracted library reference: evaluator/builtins.go:9176. These notes are not a complete signature or a stability guarantee.

create_fuzzy_set

Function

create_fuzzy_set(space, prototype_name, alpha_cut) - Create fuzzy set with α-cut Extracted library reference: evaluator/builtin_conceptual_bridges.go:202. These notes are not a complete signature or a stability guarantee.

create_mapping

Function

Cross-Space Mapping Builtin Functions Enables metaphor, analogy, and cross-domain reasoning All functions are registered in evaluator/builtins.go GetBuiltins() create_mapping(from_space, to_space, mapping_function) - Create space mapping Extracted library reference: evaluator/builtin_conceptual_mapping.go:15. These notes are not a complete signature or a stability guarantee.

create_porphyry

Function

create_porphyry()
Builds the classical Tree of Porphyry with Leibniz's prime assignments (substance=2, material=3, ... rational=19) and the classical species aliases (body, living, animal, human, stone, plant, beast, spirit). Becomes the ACTIVE taxonomy: categorical sentences (`every human is animal`) are then decided by characteristic-number arithmetic.

Examples

porphyry: create_porphyry()

println(show_taxonomy(porphyry))

every human is animal   # true

create_taxonomy

Function

create_taxonomy(name)
Creates an empty Leibniz taxonomy (primes are assigned automatically as nodes are added with add_taxonomy_node / define_species) and makes it the active model for categorical judgments.

Examples

tax: create_taxonomy("Zoo")

critical_pairs

Function

Extracted library reference: evaluator/confluence.go:1111. These notes are not a complete signature or a stability guarantee. Manual §33.13 Confluence — does the clause ORDER matter?; read with manual "33.13" Excerpt: Each entry of `critical_pairs` is a hash with `clauses` (a `(i, j)` tuple of 1-based clause numbers), `arity`, `witness` (the argument list both clauses accept), `left`, `right`, `joins` (`true` / `false` / `none`), `status`, and a `note`.

cset_digits

Function

Call diagnostics (different branches may describe different overloads): • cset_digits takes no arguments Extracted library reference: evaluator/builtin_scanner.go:259. These notes are not a complete signature or a stability guarantee.

cset_letters

Function

Call diagnostics (different branches may describe different overloads): • cset_letters takes no arguments Extracted library reference: evaluator/builtin_scanner.go:246. These notes are not a complete signature or a stability guarantee.

cup

Symbol

=== ∪ (Glyph) === name: union words: union latex: cup category: set codepoint: U+222A meaning: A ∪ B — union (members in either set)

curry

Function

curry(f)
Identity on user functions — an under-saturated call already partially applies, so every function is its own curried form. Manual §12.15.4 The surrounding combinators; read with manual "12.15.4" Excerpt: | `partial(f, a)` | fix leading arguments | `partial(sub, 10)(3)` → `7` | | `curry(f)` | one argument at a time | `curry(sub)(10)(3)` → `7` | | `flip(f)` | swap the first two arguments | `flip(sub)(2, 10)` → `8` | | `iterate(f, x, n)` | repeated self-composition | `iterate(f, 0, 4)` → `[0,1,2,3]` | | `converge(c, [f, g])` | **fork**: one input, several functions | see below |

cut

Keyword

p(X) :- q(X), cut, r(X)
Prolog goal only. Succeeds and discards alternatives made since entering the current predicate, including remaining clauses and alternatives of goals to the left. Does not discard caller choices or choices created to its right. prune and standalone ! are exact aliases. !goal remains negation, n! remains factorial. Refused in Datalog and tabled search.

dataframe

Function

dataframe([columns], [options])
Construct a DataFrame. Optional {schema: RowType} validates scalar cells and retains the row contract. Manual §5.14 Matrices, tensors & dataframes; read with manual "5.14" Excerpt: `dataframe(columns, {schema: WineRow})` checks in-memory columns against the same contract. The first version supports scalar `String`, `Integer`, `Float`, `Boolean`, `None`, `Na`, transparent aliases and unions of those types. Nested mutable cells are refused explicitly. Input column arrays are copied

date

Function

date(year_or_string, [month], [day])
date("2026-07-26") or date(2026, 7, 26); the 3-arg form range-checks the calendar. Manual §3.3.1 Uninitialized slots and identity defaults; read with manual "3.3.1" Excerpt: assign” look like a successful program that happens to use zero — the same §911 class that refuses nullary `date()` inventing an epoch. Axioma’s rule matches nullary constructors: **containers may start empty; scalars do not get silent zeros.** `0`, `""`, and `false` remain fully legal as *explicit* initializers.

date?

Function

Call diagnostics (different branches may describe different overloads): • date? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

datetime?

Function

Call diagnostics (different branches may describe different overloads): • datetime? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

deactivate

Function

Call diagnostics (different branches may describe different overloads): • deactivate requires an axiom • deactivate requires exactly 1 argument Extracted library reference: evaluator/builtins.go:6337. These notes are not a complete signature or a stability guarantee.

decidability

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §32 Executable Logic Engines (the `logic` namespace); read with manual "32" Excerpt: `[logic/<mode> | …]`. Each engine runs a different fragment of logic, and — this is the part most tools skip — **every answer reports the decidability regime it came from**, so you always know whether a result is a genuine *decision*, a *bounded* search, a sound-but-incomplete *heuristic*, or a principled *refusal*. There is no single "decide any logic" engine, because for full predicate logic there provably

declare

Keyword

declare <name> [:: Type] = <expression>
Introduces a fresh immutable recursive binding with a deferred computation. Earlier closures retain their cells; const names cannot be shadowed. A declaration group sees all its names. An annotation checks and converts the eventual value on demand. Singleton arrays stay arrays. Failed attempts may retry; cyclic demand errors. The expression is not evaluated until the name is first READ, and the result is cached thereafter. The laziness is transparent — the binding behaves like an ordinary value that happens to compute on demand. Use `lazy e` instead when you need the deferred computation as a VALUE (to pass, store, or return); a `declare` binding has already forced itself by the time it reaches an argument. Evaluator-only: rejected at compile time under --vm.

Examples

declare x = 1 + 2      # nothing computed yet

x                      # 3 — computed on this first read, then cached

declare a, b = 10, 20  # multiple lazy bindings

decode

Function

Call diagnostics (different branches may describe different overloads): • decode requires a Gödel number • decode requires exactly 1 argument Extracted library reference: evaluator/builtins.go:6443. These notes are not a complete signature or a stability guarantee. Manual §4.5 Strings — escape sequences, raw form, codepoint builtins; read with manual "4.5" Excerpt: For cases where the character can't be typed directly, escape sequences decode at parse time: | Escape | Result | |---|---|

deduce

Keyword

deduce
Triggers forward-chaining inference using all defined rules. Applies rules until no new conclusions can be derived.

Examples

deduce                      # Apply all rules

# After defining rules:

rule R1: A implies B

rule R2: B implies C

deduce                      # Derives A -> B -> C

deductive

Keyword

Select deductive mode for a reasoning chain. The chain's premises and rules remain explicit; its label alone does not certify every inference.

dedupe

Function

dedupeBuiltin: order-preserving removal of duplicates from an array (keyed by the canonical types.ObjectKey, so it matches set value-equality). Backs dedupe / remove_duplicates / unique. A Set already has unique members, so use a Set when order doesn't matter; this is for lists where order does. Call diagnostics (different branches may describe different overloads): • dedupe requires exactly 1 argument Extracted library reference: evaluator/scheme_extras.go:273. These notes are not a complete signature or a stability guarantee. Manual §22.8 List & string helpers; read with manual "22.8" Excerpt: butlast([1, 2, 3, 4]) # → [1, 2, 3] (all but the last) dedupe([1, 2, 2, 3, 1]) # → [1, 2, 3] order-preserving (remove_duplicates / unique) unique!([1, 2, 2, 3, 1]) # → [1, 2, 3] in-place; unique(xs) is the copy chars("abc") # → ["a", "b", "c"] (string → char array) explode("abc") # → ["a", "b", "c"] (SML spelling; exact alias of chars)

default_believes

Function

default_believes(theory, formula) - Check if formula is believed Example: default_believes(dt, "flies(tweety)") → true/false Call diagnostics (different branches may describe different overloads): • default_believes requires 2 arguments: theory, formula • first argument must be a default theory • second argument must be a string (formula) Extracted library reference: evaluator/builtins.go:19677. These notes are not a complete signature or a stability guarantee.

default_override

Function

default_override(theory, higher, lower) - Declare higher ≻ lower A pairwise superiority relation (Nute-style): rule `higher` defeats rule `lower` when their conclusions conflict, equivalent to giving `higher` a greater numeric priority but expressing a partial order directly. Example: default_override(dt, "penguins_dont", "birds_fly") Call diagnostics (different branches may describe different overloads): • default_override requires 3 arguments: theory, higher_rule_name, lower_rule_name • first argument must be a default theory • second argument must be a string (higher rule name) • third argument must be a string (lower rule name) Extracted library reference: evaluator/builtins.go:19608. These notes are not a complete signature or a stability guarantee.

default_theory

Function

default_theory(strategy) - Create a default logic theory Strategies: "brave" (default), "cautious" Example: default_theory("brave") Extracted library reference: evaluator/builtins.go:19511. These notes are not a complete signature or a stability guarantee.

define

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §3.2 Binding model at a glance; read with manual "3.2" Excerpt: **Not part of this table (see below):** lazy `declare` / definitional `define`, persistence refinements, multi-assign, type annotations on bindings. Cross-frame mistakes that used to be silent outer writes are reported by `axioma --lint` (see [`rebind`](#rebind--writing-a-name-in-an-enclosing-frame)).

define_species

Function

define_species(taxonomy, species, differentia, genus)
Porphyry's definition per genus et differentiam: declares species = differentia + genus, creating the differentia node under the genus (next free prime) and registering the species alias. The genus may be a species alias or a differentia name. The new term immediately participates in categorical judgments.

Examples

define_species(porphyry, "dog", "domesticated", "beast")

every dog is animal       # true

definition_of(porphyry, "dog")   # "domesticated beast"

defines

Keyword

Concept defines { predicate }   |   Concept defines~ { predicate }
Attaches an auto-classification rule: any entity satisfying the predicate is classified into the concept's extent automatically (KM-style intensional membership). The strict form derives theorem-grade memberships; the defeasible defines~ form derives conjectures. The same rule can live inline on the concept as a boundary: slot.

Examples

concept Minor

Minor defines { age < 18 and is Person }

kid is Minor   # true, derived

definition_of

Function

definition_of(taxonomy, term)
Reads back a term's classical definition — differentia + genus — from the taxonomy. The root (summum genus) has no definition, per Porphyry.

Examples

definition_of(porphyry, "human")   # "rational animal"

definitions

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §3.4 Eager bindings, deferred bindings, and definitions; read with manual "3.4" Excerpt: ### Eager bindings, deferred bindings, and definitions `let`/`val`, `var`/`local`, and bare `:`/`=` bindings evaluate their RHS now. `declare` creates a **fresh immutable lazy binding**: reading its name runs the

defuzzify

Function

Call diagnostics (different branches may describe different overloads): • defuzzify requires at least 3 arguments: fuzzy_set, start, end [, method] • end must be a number • first argument must be a fuzzy set • start must be a number Extracted library reference: evaluator/builtins.go:13163. These notes are not a complete signature or a stability guarantee.

deg

Function

deg(x)
Converts an angle from radians to degrees (x * 180/π — Lua's math.deg). All Axioma trig functions (sin/cos/tan/asin/acos/atan) take and return RADIANS; deg/rad are the unit converters.

Examples

deg(pi)          # Returns 180

deg(atan2(1, 1)) # Returns 45 (the polar-heading idiom)

del_key

Function

`del_key(hash, key)` — remove the entry in place and return the hash (chainable). Deleting an absent key is a no-op, like Python's dict.pop(k, None) rather than `del`. (Named del_key because `delete` is a reserved lexer keyword — the deprecated entity-destroy form.) Call diagnostics (different branches may describe different overloads): • del_key requires 2 arguments: hash, key Extracted library reference: evaluator/builtins.go:7030. These notes are not a complete signature or a stability guarantee. Manual §5.12.1 Schema field writes; read with manual "5.12.1" Excerpt: present value unless the declared field type includes them. `delete` and `del_key` reject removal of required fields. Earlier field-type and requiredness constraints remain attached if another alias is annotated with a wider schema. Open dictionaries retain their ordinary insert/update/delete behavior.

delete

Keyword

delete a[i]  |  delete a[i:j]  |  delete h[k]   (prefix)    ConceptName delete   (postfix, deprecated)
Prefix: retract a place — the mutating inverse of a[i]: v / h[k]: v. Yields the removed value (none on an open-map miss). Slice form yields the removed array. Postfix `Foo delete` is the deprecated concept destroy (use `Foo destroy`). Not a file delete (`remove(path)`), and not variable unbind (`word x delete` in the REPL).

Examples

xs: [10, 20, 30]

delete xs[2]       # 20 — xs is [10, 30]

old: delete xs[1]  # binds 10

h: {a: 1, b: 2}

delete h["a"]    # 1 — h is {b: 2}

Person delete      # Deprecated — use Person destroy

demonstrateIncompleteness

Function

Call diagnostics (different branches may describe different overloads): • demonstrateIncompleteness takes no arguments Extracted library reference: evaluator/builtins.go:6726. These notes are not a complete signature or a stability guarantee.

denom

Function

denom(r) - Get denominator of rational number Example: denom(2/3) → 3 Call diagnostics (different branches may describe different overloads): • denom requires a rational number • denom requires exactly 1 argument: rational number Extracted library reference: evaluator/builtins.go:17339. These notes are not a complete signature or a stability guarantee.

denominator

Function

denominator(q)
Denominator of a Rational (denominator(7/2) → 2). Manual §4.1 Primitives; read with manual "4.1" Excerpt: | `Float` | `3.14159`, `-2.5`, `0.75`, `1.5e6`, `3.14e-2`, `1E+9`, `0x1p-1`, `0xA.Bp2` | IEEE 754 double — **the type is `Float`**, not `Float64` and not `FLOAT`. `:: Float64` names no type (did-you-mean `:: Float`). Scientific notation `e`/`E` ± optional sign; **hexadecimal floats** (Go/C99 syntax — binary exponent `p`/`P` **required**: `0x1p-1` = 2⁻¹ = `0.5`, `0xa.bp2` = `42.75`, `0x2.p3` = `16.0`). The exponent is what distinguishes a hex float from a hex integer (`0x10` stays `Integer` 16), keeps `0xFE`/`0x1E` reading `e`/`E` as digits, and keeps `0x15e-2` a subtraction. Lua's exponentless fraction `0x0.2` is deliberately rejected with a hint (write `0x0.2p0`, or evaluate the Lua form via `[lua/eval \| 0x0.2 ]`). **Display** is the shortest decimal that round-trips the bits: a whole value keeps `.0` (`1.0` not `1`), IEEE remainders are not rounded away (`sin(3.1415926/2)` is `0.9999999999999997`, `0.1+0.2` is `0.30000000000000004`), infinities print `Inf`/`-Inf`, and `eval(string(x))` recovers a Float | | `Rational` | `1/3`, `rational(2, 6)` → `1/3` | Exact `p/q` on big integers, GCD-reduced — `/` on integers stays exact (`1/3 + 1/6` → `1/2`, never `0.4999…`); accessors `numerator(r)` / `denominator(r)` | | `Complex` | `complex(3, 4)` → `3.0 + 4.0i`; `im` → `i` | The **top of the numeric tower** — every other numeric type embeds, so `complex(3, 4) + 1/2` → `3.5 + 4i`. The unit is the shadowable builtin `im` (`complex(0, 1)`); write `1 + im`, `(1 + im)^2` → `2i`, `2 * im`. No juxtaposed literal: `2im` is diagnosed (same as `2x`). Full arithmetic incl. `^` (exact at integer exponents: `im^2` → `-1`) and unary minus; `sqrt`/`exp`/`log`/`sin`/`cos`/`abs`/`conjugate` all accept one. No ordering. Embedding is via `float64`, so exactness stops here. Coefficients use the same Float printer | | `String` | `"hello"`, `"unicode: ∀∃"`, `"\u{2203}"`, `r"raw \n"` | UTF-8; escape sequences + `r"..."` raw prefix — see [Strings](#strings--escape-sequences-raw-form-codepoint-builtins) | | `Boolean` | `true`, `false` | Classical two-valued |

denotes

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §6.9 Operator precedence (high → low); read with manual "6.9" Excerpt: precedence applies. `ought/permitted/forbidden` have no ordinary infix handler; `satisfies`, `with_probability`, infix `probably/typically`, `denotes`, `normally`, `by_default` have no active ordinary infix priority. Their presence in parser metadata does not make them supported expression operators.

denoting

Function

Natural language helpers for Free Logic concept creation Call diagnostics (different branches may describe different overloads): • denoting() requires exactly 2 arguments: concept and referent Extracted library reference: evaluator/builtins.go:5751. These notes are not a complete signature or a stability guarantee. Manual §3.11 Guarded identifiers and atoms; read with manual "3.11" Excerpt: **Symbolic set elements (atoms)** use the self-denoting word literal `'name`, and **cardinality** is `len(...)`: ```axioma

deontic_model

Function

deontic_model(system) - Create a new deontic model for obligations Example: deontic_model("D") → New deontic model Extracted library reference: evaluator/builtins.go:17753. These notes are not a complete signature or a stability guarantee.

depth

Function

depth(stack)
Returns the number of elements currently in the stack. Alias: stacklength.

Examples

s: stack()

push(s, 10)

depth(s)  # 1

derive

Automated Reasoning

derive proposition [from context] [using strategy]
Automated derivation command. Attempts to derive conclusions from premises using logical inference.

Examples

derive "mathematical truth"

derive conclusion from premises using forward

result: derive theorem

desc

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §7.13 ORDER BY clause; read with manual "7.13" Excerpt: List comprehensions accept an `orderby` clause that sorts the result. Sets and dicts ignore `orderby` (they're unordered by nature). Direction defaults to `asc`; add `desc` to reverse: ```axioma [x | x <- xs, orderby x] # asc by default

describe

Function

describe(x)
Print an inspection card for a VALUE (the Elixir i/1 / Common Lisp describe model): its display form, type, and type-specific facts — digits/parity for Integers, bytes-vs-runes for Strings, element types for collections, the R3 signature for functions, fact counts for relations, designation for MVL values — then pointers to `doc <Type>` and functions(). doc documents NAMES; describe inspects VALUES. Returns none. Evaluator-only. Shadowable.

Examples

describe(42)               # parity, sign, digit count, card pointer

describe("héllo")          # bytes vs runes

describe(round)            # signature + summary from the R3 spec

describe(none)             # the none-vs-om teaching card

describe_link_type

Function

describe_link_type(link_type)
Returns a detailed description of a specific semantic link type and its meaning

Examples

describe_link_type("ISA")

describe_link_type("HAS_PROPERTY")

described

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §5.5 Unary dot fallback — `xs.sum ≡ sum(xs) ≡ xs's sum`; read with manual "5.5" Excerpt: The fallback for **reads** is strictly unary: `xs.push` surfaces the builtin's arity error. Registered collection **calls**, described next, add explicit receiver placement. On collection receivers, a lexical user-function call `xs.f(a)` passes `xs` first, as described next. To call a function returned by unary application, write `f(xs)(a)`. Scalar receivers retain the earlier

designated

Function

designated(truth_value)
Logic-aware validity primitive: is this truth value "true-enough" under its own logic's standard designated set? Boolean → its value; om (K3 gap) → false; Kleene K3 → only ⊤ᵏ; Belnap/LP (FDE) → ⊤ᵇ or the glut ⊤⊥ᵇ; Łukasiewicz → only 1.0; Gödel G3 → only ⊤ⁱ. Since July 2026 `if`/`while` on a typed MVL value branch by exactly this test (truthiness = designation), so designated(x) and `if x` always agree — the builtin remains the explicit spelling for validity checks over a domain: forall p in Belnap.values | designated(f(p)).

Examples

designated(⊤⊥ᵇ)                 # → true — a glut is true-enough to act on

designated(?ᵇ)                  # → false (the gap)

designated(om)                  # → false (K3 gap) — and `if om` now agrees (falsy, 2.5)

designated(lukasiewicz(0.9))    # → false (only 1.0 is designated)

forall p in Kleene.values | designated(p or not p)   # → false (LEM fails in K3)

destroy

Keyword

ConceptName destroy
Permanently removes a concept from the environment (replaces 'delete')

Examples

Person destroy

Stock destroy

Vehicle destroy

det

Function

============================================================================ Linear Algebra Functions ============================================================================ Call diagnostics (different branches may describe different overloads): • argument to det must be a matrix • det requires exactly 1 argument: matrix Extracted library reference: evaluator/builtins.go:13920. These notes are not a complete signature or a stability guarantee. Manual §5.14 Matrices, tensors & dataframes; read with manual "5.14" Excerpt: transpose(m) # rows ↔ columns det(m) # → -2 ; trace(m) → 5 reshape(matrix([[1, 2, 3], [4, 5, 6]]), 3, 2) # 2×3 → 3×2 zeros(2, 2) # 2×2 of 0s ; ones(2, 3) → 2×3 of 1s solve(matrix([[2, 1], [1, 3]]), [5, 10]) # Ax = b → column vector (1, 3)

detect

Function

detectBuiltinFn returns the first element satisfying the predicate (Ruby's detect, the synonym of find — `find` is a reserved solver keyword in Axioma, so `detect` is the collection verb), or none if no element matches. Collection-last: detect(pred, coll). Miss stays `none` (falsy) so `if detect(...)` and `??` keep working. For an Option-shaped miss use detect_option (OPTION_STDLIB_AUDIT.md) — do not change this return type. Call diagnostics (different branches may describe different overloads): • detect requires exactly 2 arguments: a predicate and a collection Extracted library reference: evaluator/builtins.go:23108. These notes are not a complete signature or a stability guarantee. Manual §33.17 Tool registry and Act guardrails; read with manual "33.17" Excerpt: |---|---| | `detect(pred, coll)` | `detect_option(pred, coll)` | | `get(hash, key [, default])` | `get_option(hash, key)` — no default arg | | `index_of(coll, target [, init])` | `index_of_option(...)` | | `span_of(s, sub [, init])` | `span_of_option(...)` |

detect_option

Function

detectOptionBuiltinFn is the Option dual of detect: Some(elem) on the first hit, None if nothing matches. Same argument order as detect (pred, coll). detect itself is unchanged (OPTION_STDLIB_AUDIT.md P1). Call diagnostics (different branches may describe different overloads): • detect_option requires exactly 2 arguments: a predicate and a collection Extracted library reference: evaluator/builtins.go:23131. These notes are not a complete signature or a stability guarantee. Manual §33.17 Tool registry and Act guardrails; read with manual "33.17" Excerpt: |---|---| | `detect(pred, coll)` | `detect_option(pred, coll)` | | `get(hash, key [, default])` | `get_option(hash, key)` — no default arg | | `index_of(coll, target [, init])` | `index_of_option(...)` | | `span_of(s, sub [, init])` | `span_of_option(...)` |

df_describe

Function

Call diagnostics (different branches may describe different overloads): • argument must be a dataframe • df_describe requires exactly 1 argument: dataframe Extracted library reference: evaluator/builtins.go:14872. These notes are not a complete signature or a stability guarantee. Manual §5.14 Matrices, tensors & dataframes; read with manual "5.14" Excerpt: df_info(df) # schema: dtypes, non-null counts, memory df_describe(df) # count / mean / std / min / quartiles / max ``` `read_csv(path)` loads a file into a `DataFrame`, and `write_csv(df, path

df_filter

Function

Call diagnostics (different branches may describe different overloads): • df_filter requires 2 arguments: dataframe, condition_function • first argument must be a dataframe • second argument must be a function Extracted library reference: evaluator/builtins.go:14687. These notes are not a complete signature or a stability guarantee. Manual §4.6.3 Bitwise ops — word-form infix (v3) + functional form; read with manual "4.6.3" Excerpt: The functional forms are ordinary builtins, and builtins are valid higher-order callables — `map` / `filter` / `reduce` / `df_filter` accept them directly (`map(bit_not, xs)`, `reduce(bit_or, 0, xs)`), the same way the Enumerable verbs (`sort_by`, `detect`, …) always have. The one exception is `partial`, which needs declared parameters to curry and so

df_groupby

Function

df_groupby(dataframe, columns)
Group dataframe rows by a column name String or an Array of column-name Strings. Returns the grouped result. See manual "dataframes" for construction and tabular operations.

df_head

Function

Call diagnostics (different branches may describe different overloads): • df_head requires 1 or 2 arguments: dataframe [, n] • first argument must be a dataframe • n must be an integer Extracted library reference: evaluator/builtins.go:14808. These notes are not a complete signature or a stability guarantee. Manual §5.14 Matrices, tensors & dataframes; read with manual "5.14" Excerpt: df_sort(df, ["age"]) # ascending (optional 3rd arg: ascending?) df_head(df, 2) # first rows ; df_tail(df, 1) → last rows df_info(df) # schema: dtypes, non-null counts, memory df_describe(df) # count / mean / std / min / quartiles / max ```

df_info

Function

Call diagnostics (different branches may describe different overloads): • argument must be a dataframe • df_info requires exactly 1 argument: dataframe Extracted library reference: evaluator/builtins.go:14856. These notes are not a complete signature or a stability guarantee. Manual §5.14 Matrices, tensors & dataframes; read with manual "5.14" Excerpt: df_head(df, 2) # first rows ; df_tail(df, 1) → last rows df_info(df) # schema: dtypes, non-null counts, memory df_describe(df) # count / mean / std / min / quartiles / max ```

df_mutate

Function

df_mutate(df, column, values)
Return a DataFrame with a column replaced or added. Validates its row schema before returning; leaves the input unchanged. Manual §5.14 Matrices, tensors & dataframes; read with manual "5.14" Excerpt: `df_mutate(df, name, values)` returns a new table with that column added or replaced, validates the complete candidate, and leaves `df` unchanged on failure or success. The row schema survives filtering, sorting, head/tail and column replacement; selection projects it onto the selected columns. `df_filter`

df_select

Function

Call diagnostics (different branches may describe different overloads): • column names must be strings • df_select requires 2 arguments: dataframe, columns • first argument must be a dataframe • second argument must be an array of column names Extracted library reference: evaluator/builtins.go:14653. These notes are not a complete signature or a stability guarantee. Manual §5.14 Matrices, tensors & dataframes; read with manual "5.14" Excerpt: type(df) # → "DataFrame" df_select(df, ["name"]) # column projection df_filter(df, func(row) [row["age"] > 26]) # row predicate — row is a Dictionary df_sort(df, ["age"]) # ascending (optional 3rd arg: ascending?) df_head(df, 2) # first rows ; df_tail(df, 1) → last rows

df_sort

Function

Call diagnostics (different branches may describe different overloads): • ascending values must be booleans • column names must be strings • columns must be string or array of strings • df_sort requires 2 or 3 arguments: dataframe, columns [, ascending] • first argument must be a dataframe Extracted library reference: evaluator/builtins.go:14709. These notes are not a complete signature or a stability guarantee. Manual §5.14 Matrices, tensors & dataframes; read with manual "5.14" Excerpt: df_filter(df, func(row) [row["age"] > 26]) # row predicate — row is a Dictionary df_sort(df, ["age"]) # ascending (optional 3rd arg: ascending?) df_head(df, 2) # first rows ; df_tail(df, 1) → last rows df_info(df) # schema: dtypes, non-null counts, memory df_describe(df) # count / mean / std / min / quartiles / max

df_tail

Function

Call diagnostics (different branches may describe different overloads): • df_tail requires 1 or 2 arguments: dataframe [, n] • first argument must be a dataframe • n must be an integer Extracted library reference: evaluator/builtins.go:14832. These notes are not a complete signature or a stability guarantee. Manual §5.14 Matrices, tensors & dataframes; read with manual "5.14" Excerpt: df_sort(df, ["age"]) # ascending (optional 3rd arg: ascending?) df_head(df, 2) # first rows ; df_tail(df, 1) → last rows df_info(df) # schema: dtypes, non-null counts, memory df_describe(df) # count / mean / std / min / quartiles / max ```

dfs

AI Function

dfs(graph, start_node, goal_node)
Performs Depth-First Search to find a path from start to goal. Returns search result with path, cost, and exploration stats.

Examples

dfs(g, "A", "Z")

dfs(maze, "start", "exit")

diag

Function

Call diagnostics (different branches may describe different overloads): • argument to diag must be an array or matrix • diag requires exactly 1 argument: vector or matrix Extracted library reference: evaluator/builtins.go:13855. These notes are not a complete signature or a stability guarantee.

diagnose

Function

diagnose(arg)
Carnap/Schlick pseudo-statement diagnostic — returns a Diagnosis entity whose .verdict classifies the target. Dispatches on argument type: • Concept → vacuously_formed / untestable / empirically_anchored / heuristic (formed_by:"metaphor") • func(sd) proposition → L_true / L_false / meaningful (analytic vs contingent); carries .confirmation = range_size/total_sds • string assertion → meaningful (has_meaning verifier registered) or pseudo (Scheinsatz — meaningless, not false) Every Diagnosis carries .verdict, .target, .reasons; string diagnoses also expose .verifier_bound. Siblings: pseudo_concept(C) (Boolean shortcut), pseudo_statements() (set walk).

Examples

declare_atomic("p")

taut: func(sd) [atom_truth(sd, "p") or not atom_truth(sd, "p")]

diagnose(taut).verdict          # "L_true"

diagnose(taut).confirmation       # 1.0

dm: diagnose("the Absolute is lazy")

dm.verdict                        # "pseudo"

dm.verifier_bound                 # false

diagonalize

Function

diagonalize(expression_string)
Gödel's diagonal construction: encodes the expression, then encodes the expression APPLIED TO its own Gödel number (the numeral embedded as a string — Gödel numbers exceed int64). The engine of self-reference behind the incompleteness theorem.

Examples

d: diagonalize("provable")

is_godel(d)   # true

dialect?

Function

Call diagnostics (different branches may describe different overloads): • dialect? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

diamond

Symbol

=== ◇ (Glyph) === name: diamond words: possibly latex: Diamond, diamond, lozenge variants: ◊ ⋄ category: modal codepoint: U+25C7 meaning: ◇p — possibly p (alethic possibility; true in some accessible world)

dict

Function

dict(args...)
Dictionary constructor: empty (`dict()`), capacity `dict(n)`, key/value pairs (any key, compared by ==), Pairs (`k => v` / `k -> v`), or one Array / List / Set of Pairs or 2-tuples. `dictionary` is the spelled-out twin. Manual §7.7 Dict comprehensions; read with manual "7.7" Excerpt: ### Dict comprehensions Produce a hash by emitting a key/value pair per iteration. Pipe form and pipe-less form are both supported:

dictionary

Function

dictionary(args...)
Spelled-out twin of `dict()` — same empty Dictionary, capacity, key/value, Pair, and collection forms. Manual §13.18 Structural dictionary types — `type Poet = { … }`; read with manual "13.18" Excerpt: ### Structural dictionary types — `type Poet = { … }` A **schema over Dictionary values** (TS object-type shapes), still a **DataType** — not a domain Concept and not an entity class:

diff

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §28.7.2 `:compare` (REPL) — typed-value diff with timing; read with manual "28.7.2" Excerpt: #### `:compare` (REPL) — typed-value diff with timing ```text :compare 2 + 3 // 2 + 3

difference

Operator

set1 difference set2
Set difference operator

Examples

{1, 2, 3} difference {2, 3}

all difference completed

different

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §3.1.1 Pattern binding (ML-style tuple patterns); read with manual "3.1.1" Excerpt: > (canonical) or `=`; `x := value` is a syntax error with an inline hint > pointing at `x: value`. `let x = value` is a different construct entirely — > a **fresh, immutable declaration** that shadows rather than updates > (below), exactly the `let` of mathematical prose: "let x = 5" fixes x for > the rest of the argument. Its mutable twin is `var x = value` (`let mut x =

digit?

Function

charPredicate wraps a rune classifier as a builtin accepting a Character or a one-character String. Call diagnostics (different branches may describe different overloads): • digit? requires exactly 1 argument Extracted library reference: evaluator/character.go:81. These notes are not a complete signature or a stability guarantee. Manual §33.8 Range patterns and `in` patterns; read with manual "33.8" Excerpt: match 20 with | n in [10, 20] => n # → 20 func digit?(n in 0..9) [true] func digit?(n) [false] ```

digraph

AI Function

digraph(node1, node2, node3, ...)
Creates a directed graph with specified nodes. Use add_edge() to connect nodes.

Examples

digraph("Start", "Middle", "End")

digraph("State1", "State2", "State3")

dim

Function

dim(quantity)
The dimension of a Quantity as a string (`"kg"`, `"m/s^2"`, `"1"`).

Examples

dim(5 * kg)                 # "kg"

dim(metre / sec^2)          # "m/s^2"

dimensions_of

Function

dimensions_of(space) - Get dimensions Extracted library reference: evaluator/builtin_conceptual.go:117. These notes are not a complete signature or a stability guarantee.

direct

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §3.3.1 Uninitialized slots and identity defaults; read with manual "3.3.1" Excerpt: ascending closed integer ranges. Every reachable break/continue path must still supply the fill. It follows direct reference aliases by cell identity: `p = &x; *p = 1` fills `x`, even if a later fresh declaration hides that cell. Caught errors preserve writes completed before failure; `try`, `attempt`, `otherwise`, catch handlers and finally blocks join their actual exit paths.

discover

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §3.14 Typing the glyphs; read with manual "3.14" Excerpt: Names are LaTeX first (`` `cup ``, `\subseteq`), then Axioma's canonical names (`` `union ``), then word aliases — ~100 spellings. Discover them from inside the language: `symbols()` lists the whole catalog with LaTeX names and meanings; `glyph("cup")` looks one up.

dispatch

Function

Extracted library reference: evaluator/behavior_interface.go:1110. These notes are not a complete signature or a stability guarantee. Manual §28.4.1 Engine dispatch — deterministic emitter then LLM fallback; read with manual "28.4.1" Excerpt: #### Engine dispatch — deterministic emitter then LLM fallback The translation engine prefers a deterministic AST emitter when it can:

distance

Function

distance(space, point1, point2, [options]) - Compute distance Extracted library reference: evaluator/builtin_conceptual.go:377. These notes are not a complete signature or a stability guarantee. Manual §5.12.2 Unified type declarations; read with manual "5.12.2" Excerpt: ```axioma type Distance = Float type NumericCoordinate = Integer | Float type Coordinates = (Float, Float) type PersonId = opaque Integer

distinct

Function

distinct(x) — the Set of x's distinct elements. A Set is already distinct. ─── Multiset / collection conversions ─────────────────────────────────────── Converted from evalCallExpression intercepts alongside the bag constructors, and for the same reason: each used its environment only to evaluate its one argument, so as intercepts they were invisible to the VM's name resolution ("undefined variable distinct" under --vm). One shared body each. Extracted library reference: evaluator/builtin_strings.go:629. These notes are not a complete signature or a stability guarantee. Manual §28.5.8 Refinement modes — `/bag`, `/k3`, `/strict`, `/distinct`, `/explain`; read with manual "28.5.8" Excerpt: #### Refinement modes — `/bag`, `/k3`, `/strict`, `/distinct`, `/explain` The block accepts SQL-shaping refinements that pre-configure how the compiled comprehension treats duplicates, NULLs, and shape strictness:

div

Operator

number div number
Integer (floor) division infix keyword — a same-line soft keyword for floor division. Produces a byte-identical AST to the glyph `÷` (operator string `div`), so the result and precedence (PRODUCT) match. Word aliases: `idiv` and longhand `quotient`. Prefix builtins: `div(a, b)`, `idiv(a, b)`, and `quotient(a, b)` — each hands its operands to the same floor operator, so call and infix cannot answer differently. Division FLOORS (rounds toward −∞) on integers and floats alike, so `-7 div 3` is -3 and not -2. As a soft keyword, `div` is only an operator between two expressions on the same line; `div: 5` is still an ordinary binding and `div` remains a legal variable / hash-key name — a local binding shadows the builtin. Line comments use `#` or `//` (not floor division).

Examples

100 div 7          # Returns 14

100 idiv 7         # Returns 14   (word alias)

100 quotient 7     # Returns 14   (infix longhand)

10.0 div 3.0       # Returns 3

100 ÷ 7            # Returns 14   (glyph equivalent)

6 * 5 div 7        # Returns 4    (left-assoc with *)

div(100, 7)        # Returns 14   (prefix builtin, keyword spelling)

idiv(100, 7)       # Returns 14   (prefix builtin, idiv spelling)

quotient(100, 7)   # Returns 14   (prefix builtin, long spelling)

-7 div 3           # Returns -3   (floor, toward -inf)

div(-7, 3)         # Returns -3   (the call agrees, by construction)

division

Function

division(R, S) - Relational division (Codd's operator) Mathematical: R ÷ S = {x | ∀y ∈ S: (x,y) ∈ R} Returns tuples from R that are paired with ALL elements of S Example: employees ÷ all_skills → employees who have all skills Call diagnostics (different branches may describe different overloads): • division requires exactly 2 arguments: division(R, S) Extracted library reference: evaluator/builtins.go:8287. These notes are not a complete signature or a stability guarantee. Manual §3.9 `global` — Julia's module write; read with manual "3.9" Excerpt: That division of labor is the whole design: **`let` protects a cell, `const` protects a name.** Use `let` for everyday working bindings, `const` for the `SCREAMING_CASE` handful whose point is that the name is globally unambiguous.

divmod

Function

divmod(a, b)
Returns both quotient and remainder of dividing a by b as a 1-indexed Tuple (quotient, remainder) — Python's divmod, computing both halves in one call. Element [1] is the quotient (as `quotient(a, b)`), element [2] is the remainder (as `remainder(a, b)`). Divisor 0 raises an error. Useful for base conversion and time math where both halves are needed without recomputing a / b.

Examples

divmod(100, 7)     # Returns (14, 2)   — (quotient, remainder)

divmod(100, 7)[1]  # Returns 14        (quotient, 1-indexed)

divmod(100, 7)[2]  # Returns 2         (remainder)

divmod(-7, 3)      # Returns (-3, 2)   (floor quotient, remainder signed like the divisor)

divmod(100, 0)     # ERROR: divmod by zero

dl_consistent?

Function

Registered alias of is_dl_consistent.is_dl_consistent(kb) - Check knowledge base consistency Example: is_dl_consistent(kb) → true/false Call diagnostics (different branches may describe different overloads): • argument must be a DL knowledge base • is_dl_consistent requires 1 argument: kb Extracted library reference: evaluator/builtins.go:18607. These notes are not a complete signature or a stability guarantee.

dl_instance?

Function

Registered alias of is_dl_instance.is_dl_instance(kb, individual, concept) - Check if individual is instance of concept Example: is_dl_instance(kb, "john", "Person") → true/false Call diagnostics (different branches may describe different overloads): • first argument must be a DL knowledge base • is_dl_instance requires 3 arguments: kb, individual, concept • second argument must be a string (individual name) • third argument must be a string (concept name) Extracted library reference: evaluator/builtins.go:18519. These notes are not a complete signature or a stability guarantee.

dl_kb

Function

dl_kb(system) - Create a new Description Logic knowledge base Systems: "ALC" (default), "ALCI", "SHOIN", "SROIQ" Example: dl_kb("ALC") → new DL knowledge base Extracted library reference: evaluator/builtins.go:18324. These notes are not a complete signature or a stability guarantee. Manual §13.15.2 Defined concepts, ⊤/⊥, and more spellings; read with manual "13.15.2" Excerpt: The older `dl_kb(...)` family of builtins remains for explicit string-keyed knowledge bases. DL operators evaluate in the tree-walking interpreter (not under `--vm`, which does not compile concept declarations).

dl_stats

Function

dl_stats(kb) - Get statistics about the knowledge base Example: dl_stats(kb) → {concepts: 10, roles: 5, individuals: 20, ...} Call diagnostics (different branches may describe different overloads): • argument must be a DL knowledge base • dl_stats requires 1 argument: kb Extracted library reference: evaluator/builtins.go:18905. These notes are not a complete signature or a stability guarantee.

dnf?

Function

Registered alias of is_dnf.is_dnf(expr) - Check if expression is in Disjunctive Normal Form Returns true if the expression is already in DNF form Call diagnostics (different branches may describe different overloads): • is_dnf requires exactly 1 argument: a boolean expression Extracted library reference: evaluator/builtins.go:16930. These notes are not a complete signature or a stability guarantee.

do

Function

Extracted library reference: evaluator/builtins.go:15742. These notes are not a complete signature or a stability guarantee. Manual §6.6 Conditional; read with manual "6.6" Excerpt: `case/strict` / `switch/strict` is `match/strict`. `case e of` / `with` / `do` are SyntaxErrors. On `match`, the first `|` after `with` is optional: `match e with p => … | _ => …`. On `case` / `switch`, the first arm starts with `|` (the value is an expression). Postfix `e match | p => …` is the value-first spelling. Arm arrows are `=>` or `->`, the same pair as lambdas.

doc

Function

doc | doc <word> | doc(word) | doc("word")
Documentation lookup, in two equivalent spellings: the statement `doc word` and the call `doc(word)`. Both print the identical word inspection (definition, source, type, value, registry documentation) through one shared renderer; with no word, both print the full topic catalog (sorted). The call form takes a bare identifier with hold semantics — doc(Integer) documents the NAME Integer, not the evaluated concept — or a String for words that cannot appear as call arguments (keywords and operators: doc("if"), doc("+")). Prints and returns none, like println. Evaluator-only (needs the live environment); under --vm it rejects with a clear message.

Examples

doc Integer            # statement form

doc(Integer)           # call form — identical output

doc("if")              # keywords/operators need the string form

doc random             # builtin docs (seeding, ranges)

doc                    # the full sorted topic catalog (also doc())

Documentation Strings

Concept

Various documentation syntaxes for concepts and functions
Axioma supports multiple ways to add documentation to concepts and functions

Examples

concept Person "A Person represents a human being"

concept Vehicle """\nMulti-line documentation\nwith detailed descriptions\n"""

greet: lambda name => "Hello, " + name documented as "Simple greeting"

add: func(x, y) "Adds two numbers" [ x + y ]

Person document "Add documentation later"

document

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §3.15 Formatting a file — `--fmt`; read with manual "3.15" Excerpt: **In the editor.** `axioma-lsp` serves the same engine as `textDocument/formatting`, so *Format Document* (and format-on-save) in VS Code, Cursor, Neovim or Helix produces bytes identical to `axioma --fmt`. It also serves `textDocument/rangeFormatting`, so *Format Selection* (and the extension's *Format Axioma Selection*) changes only the selected lines — at

documented

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §5.12.2 Unified type declarations; read with manual "5.12.2" Excerpt: **Spellings:** `struct` is the primary documented spelling; `record` is an alias in the `type Name =` kind slot. Both are immutable by default. Either `mut` or `mutable` after either word selects the same mutable struct: `struct mutable`, `struct mut`, `record mutable` and `record mut` are identical

domain

Function

Call diagnostics (different branches may describe different overloads): • domain requires exactly 1 argument Extracted library reference: evaluator/builtins.go:7579. These notes are not a complete signature or a stability guarantee. Manual §19.7.2 Scoped trace blocks — `trace <domain> [ ... ]`; read with manual "19.7.2" Excerpt: #### Scoped trace blocks — `trace <domain> [ ... ]` `trace` has two forms, and the domain list is optional in both:

domains_of

Function

domains_of(space)
Returns the quality domains declared for a conceptual space.

Examples

fruit: conceptual_space("Fruit")

add_dimension(fruit, "sweetness", 0, 10)

add_dimension(fruit, "size", 0, 10)

add_domain(fruit, "taste_size", ["sweetness", "size"])

domains_of(fruit)

doubts

Keyword

In an active epistemic model, test whether the agent's belief confidence is below 0.5. Without a model, construct an epistemic object with the doubts attitude and default certainty 0.3. This experimental interface does not test the truth of the proposition.

drop

Function

Call diagnostics (different branches may describe different overloads): • argument to drop must be a stack • drop requires 1 argument: stack Extracted library reference: evaluator/builtins.go:12078. These notes are not a complete signature or a stability guarantee. Manual §28.5.1 DDL — `CREATE TABLE`, `DROP TABLE`, `TRUNCATE`; read with manual "28.5.1" Excerpt: #### DDL — `CREATE TABLE`, `DROP TABLE`, `TRUNCATE` ```axioma # CREATE TABLE — declares a new relation

drop_while

Function

Call diagnostics (different branches may describe different overloads): • drop_while requires exactly 2 arguments: a predicate and a collection Extracted library reference: evaluator/builtins.go:22995. These notes are not a complete signature or a stability guarantee. Manual §12.17 Enumerable verbs; read with manual "12.17" Excerpt: take_while(func(x) [x < 5], [1, 2, 9, 1]) # → [1, 2] leading run while the predicate holds drop_while(func(x) [x < 5], [1, 2, 9, 1]) # → [9, 1] the complement each_slice(3, [1, 2, 3, 4, 5, 6, 7]) # → [[1,2,3], [4,5,6], [7]] consecutive fixed chunks each_cons(2, [1, 2, 3, 4]) # → [[1,2], [2,3], [3,4]] sliding windows chunk([1, 1, 2, 3, 3]) # → [[1,1], [2], [3,3]] group consecutive-equal runs

dsl_case

Function

Call diagnostics (different branches may describe different overloads): • dsl_case requires 2 arguments: pattern string, word Extracted library reference: evaluator/builtin_dsl.go:231. These notes are not a complete signature or a stability guarantee.

dsl_cases

Function

Call diagnostics (different branches may describe different overloads): • dsl_cases requires environment (this should not be called) Extracted library reference: evaluator/builtins.go:5524. These notes are not a complete signature or a stability guarantee.

dsl_compile

Function

Call diagnostics (different branches may describe different overloads): • dsl_compile requires environment (this should not be called) Extracted library reference: evaluator/builtins.go:5500. These notes are not a complete signature or a stability guarantee.

dsl_define

Function

Call diagnostics (different branches may describe different overloads): • dsl_define requires environment (this should not be called) Extracted library reference: evaluator/builtins.go:5518. These notes are not a complete signature or a stability guarantee.

dsl_explain

Function

Call diagnostics (different branches may describe different overloads): • dsl_explain requires environment (this should not be called) Extracted library reference: evaluator/builtins.go:5506. These notes are not a complete signature or a stability guarantee.

dsl_export

Function

Call diagnostics (different branches may describe different overloads): • dsl_export requires environment (this should not be called) Extracted library reference: evaluator/builtins.go:5482. These notes are not a complete signature or a stability guarantee.

dsl_import

Function

Call diagnostics (different branches may describe different overloads): • dsl_import requires environment (this should not be called) Extracted library reference: evaluator/builtins.go:5488. These notes are not a complete signature or a stability guarantee.

dsl_lint

Function

Call diagnostics (different branches may describe different overloads): • dsl_lint requires environment (this should not be called) Extracted library reference: evaluator/builtins.go:5470. These notes are not a complete signature or a stability guarantee.

dsl_list

Function

Call diagnostics (different branches may describe different overloads): • dsl_list requires environment (this should not be called) Extracted library reference: evaluator/builtins.go:5452. These notes are not a complete signature or a stability guarantee.

dsl_match

Function

Call diagnostics (different branches may describe different overloads): • dsl_match requires 2 or 3 arguments: pattern string, phrase [, vocabulary] Extracted library reference: evaluator/builtin_dsl.go:672. These notes are not a complete signature or a stability guarantee.

dsl_parse

Function

Call diagnostics (different branches may describe different overloads): • dsl_parse requires environment (this should not be called) Extracted library reference: evaluator/builtins.go:5494. These notes are not a complete signature or a stability guarantee.

dsl_reference

Function

Call diagnostics (different branches may describe different overloads): • dsl_reference requires environment (this should not be called) Extracted library reference: evaluator/builtins.go:5464. These notes are not a complete signature or a stability guarantee.

dsl_show

Function

Call diagnostics (different branches may describe different overloads): • dsl_show requires environment (this should not be called) Extracted library reference: evaluator/builtins.go:5458. These notes are not a complete signature or a stability guarantee.

dsl_test

Function

Call diagnostics (different branches may describe different overloads): • dsl_test requires environment (this should not be called) Extracted library reference: evaluator/builtins.go:5476. These notes are not a complete signature or a stability guarantee.

dsl_tokens

Function

Call diagnostics (different branches may describe different overloads): • dsl_tokens requires 1 argument: constrained language, natural language, or string Extracted library reference: evaluator/builtin_dsl.go:16. These notes are not a complete signature or a stability guarantee.

dsl_trace

Function

Call diagnostics (different branches may describe different overloads): • dsl_trace requires environment (this should not be called) Extracted library reference: evaluator/builtins.go:5512. These notes are not a complete signature or a stability guarantee.

dsl_validators

Function

Call diagnostics (different branches may describe different overloads): • dsl_validators requires constraint/word pairs Extracted library reference: evaluator/builtin_dsl.go:279. These notes are not a complete signature or a stability guarantee.

dsl_vocab

Function

Call diagnostics (different branches may describe different overloads): • dsl_vocab requires synonym/canonical string pairs Extracted library reference: evaluator/builtin_dsl.go:250. These notes are not a complete signature or a stability guarantee.

dup

Function

dup(stack)
Duplicates the top value of the stack.

Examples

s: stack()

push(s, 10)

dup(s)  # stack is now [10, 10]

dupnum

Function

Call diagnostics (different branches may describe different overloads): • count must be non-negative • dupnum requires 2 arguments: stack, count • first argument to dupnum must be a stack • second argument to dupnum must be an integer Extracted library reference: evaluator/builtins.go:12257. These notes are not a complete signature or a stability guarantee. Manual §18.3 Bulk & depth operations; read with manual "18.3" Excerpt: |---|---| | `dupnum(s, n)` | Duplicate top `n` times | | `erasenum(s, n)` | Drop top `n` items | ### Array conversion

duration?

Function

Call diagnostics (different branches may describe different overloads): • duration? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee. Manual §4.7.4 DateTime & Duration — the `datetime` package; read with manual "4.7.4" Excerpt: type(Dt.now()) # → "DateTime" (Dt.utc() for UTC) is_datetime(bday) # → true ; duration?(gap) → true ``` The package also carries `Dt.datetime(y, mo, d, h, mi, s)`, `Dt.from_unix` /

e

Value

Built-in FLOAT value: 2.718281828459045 Manual §19.2.1 Parentheses: `(OP)` is the value; `(OP e)` and `(e OP)` are sections; read with manual "19.2.1" Excerpt: #### Parentheses: `(OP)` is the value; `(OP e)` and `(e OP)` are sections Three corners, all shipped. Wrapping an operator in parentheses is the spelling that reads inside an argument list, where a bare operator would sit next to a

each

Function

Extracted library reference: evaluator/builtin_each.go:46. These notes are not a complete signature or a stability guarantee. Manual §5.14 Matrices, tensors & dataframes; read with manual "5.14" Excerpt: `elements(m)` and `each(m)` return a fresh single-use Generator; `collect(m)` and finite collection verbs such as `map`, `filter`, and `reduce` gather the same ordered cells. `collect` retains its allocation limit. Materializing is explicit and does not make `len(m)` / `size(m)` valid: dimensions still come from `shape(m)`.

each_cons

Function

eachConsBuiltinFn yields each consecutive sliding window of size n (Ruby's each_cons) — e.g. each_cons(2, [1,2,3]) → [[1,2],[2,3]]. Fewer than n elements yields the empty array. Collection-last: each_cons(n, coll). Call diagnostics (different branches may describe different overloads): • each_cons requires exactly 2 arguments: a window size and a collection • each_cons window size must be a positive integer Extracted library reference: evaluator/builtins.go:23052. These notes are not a complete signature or a stability guarantee. Manual §12.17 Enumerable verbs; read with manual "12.17" Excerpt: each_slice(3, [1, 2, 3, 4, 5, 6, 7]) # → [[1,2,3], [4,5,6], [7]] consecutive fixed chunks each_cons(2, [1, 2, 3, 4]) # → [[1,2], [2,3], [3,4]] sliding windows chunk([1, 1, 2, 3, 3]) # → [[1,1], [2], [3,3]] group consecutive-equal runs detect(func(x) [x > 3], [1, 2, 3, 4]) # → 4 first element matching (none if no match) compact([1, none, 2, none, 3]) # → [1, 2, 3] drop none (keeps om and everything else)

each_slice

Function

eachSliceBuiltinFn cuts the collection into consecutive fixed-size chunks (the final chunk may be short). Collection-last: each_slice(n, coll). Call diagnostics (different branches may describe different overloads): • each_slice requires exactly 2 arguments: a size and a collection • each_slice size must be a positive integer Extracted library reference: evaluator/builtins.go:23023. These notes are not a complete signature or a stability guarantee. Manual §12.17 Enumerable verbs; read with manual "12.17" Excerpt: verb is **collection-last**, so it threads through the forward pipe `|>` with no `_` hole (`people |> max_by(...)`, `xs |> each_slice(3)`). ```axioma tally(["a", "b", "a"]) # → {a: 2, b: 1} count occurrences (alias: frequencies)

eachline

Function

eachline()  |  eachline(path)
Exact alias of readlines. The for-loop spelling: for line in eachline(path). Returns an Array (files slurp).

Examples

for line in eachline("notes.txt") [ println(line) ]

efficiently

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §29.3 End-form `try` / `catch` / `finally` / `end`; read with manual "29.3" Excerpt: `finally` is this cleanup clause. Aristotle's final cause is the four-cause infix `P teleologically Q` (with `materially` / `formally` / `efficiently`). `Acorn finally OakTree` is a SyntaxError with that hint. ### Constructing & re-raising

eg_add_cut

Function

eg_add_cut(graph, cut)
Adds a cut (negation area) to an Existential Graph. The cut's depth is automatically calculated based on containing cuts for proper quantification scope.

Examples

cut: eg_cut(80, 80, 150, 50)

eg_add_cut(alpha, cut)

print(eg_format(alpha))  # Shows cut in graph structure

eg_add_predicate

Function

eg_add_predicate(graph, predicate)
Adds a predicate to an Existential Graph. The predicate's depth is calculated from its position relative to cuts for quantification scope.

Examples

pred: eg_predicate("Human", 1, 150, 150)

eg_add_predicate(beta, pred)

print(eg_format(beta))  # Shows predicate in graph

eg_alpha

Function

eg_alpha(description)
Creates an Alpha Graph for propositional logic using Charles S. Peirce's Existential Graphs. Alpha graphs support cuts (negation) and juxtaposition (conjunction).

Examples

alpha: eg_alpha("Propositional logic example")

eg_add_predicate(alpha, eg_predicate("P", 0, 100, 100))

print(eg_format(alpha))

eg_beta

Function

eg_beta(description)
Creates a Beta Graph for first-order logic with quantification using lines of identity. Beta graphs extend Alpha graphs with existential and universal quantification.

Examples

beta: eg_beta("First-order logic with quantification")

eg_add_predicate(beta, eg_predicate("Human", 1, 150, 150))

print(eg_format(beta))

eg_cut

Function

eg_cut(x, y, width, height [, style])
Creates a cut (negation area) for Existential Graphs. Cuts represent logical negation and follow Peirce's spatial logic rules. Style can be 'solid' or 'dashed' (for modal logic).

Examples

cut: eg_cut(50, 50, 200, 100)           # Solid cut

modal: eg_cut(100, 200, 150, 80, "dashed")  # Dashed cut for modal logic

eg_add_cut(graph, cut)

eg_erase_cut

Function

eg_erase_cut(graph, cut_id)
Implements Peirce's First Permission: erase a cut from a positive (unshaded) area. Returns an operation result with the transformed graph.

Examples

result: eg_erase_cut(graph, "cut_id_123")

if result.Success [

    print("Cut erased successfully")

]

eg_format

Function

eg_format(graph)
Creates a human-readable text representation of an Existential Graph showing all predicates, cuts, and their spatial relationships with depth information.

Examples

print(eg_format(alpha))  # Display Alpha graph structure

print(eg_format(beta))   # Display Beta graph with quantification

print(eg_format(gamma))  # Display Gamma graph with modal cuts

eg_gamma

Function

eg_gamma(description)
Creates a Gamma Graph for modal logic with necessity and possibility operators using dashed cuts. Gamma graphs support modal reasoning about necessity, possibility, and knowledge.

Examples

gamma: eg_gamma("Modal logic reasoning")

modal_cut: eg_cut(100, 100, 200, 100, "dashed")

eg_add_cut(gamma, modal_cut)

eg_insert_cut

Function

eg_insert_cut(graph, cut)
Implements Peirce's First Permission: insert a cut in a negative (shaded) area. This is a fundamental transformation rule of Existential Graphs.

Examples

cut: eg_cut(100, 100, 120, 60)

result: eg_insert_cut(graph, cut)

print(result.Success)  # Check if operation succeeded

eg_iterate

Function

eg_iterate(graph, element_id, target_x, target_y)
Implements Peirce's Second Permission: copy (iterate) any graph instance anywhere. This allows duplication of logical elements according to EG transformation rules.

Examples

result: eg_iterate(graph, predicate.ID, 400, 200)

print(result.Rules)  # Shows 'second_permission_iterate'

print(eg_format(result.Output))  # Displays copied element

eg_predicate

Function

eg_predicate(name, arity, x, y)
Creates a predicate for use in Existential Graphs. Predicates represent logical propositions or relations with specified arity (number of arguments).

Examples

p: eg_predicate("P", 0, 100, 100)        # Proposition P

human: eg_predicate("Human", 1, 200, 150)  # Unary predicate

loves: eg_predicate("Loves", 2, 300, 200) # Binary relation

eig

Function

Call diagnostics (different branches may describe different overloads): • argument to eig must be a matrix • eig requires exactly 1 argument: matrix Extracted library reference: evaluator/builtins.go:14201. These notes are not a complete signature or a stability guarantee.

eighth

Function

ordinalBuiltin builds a 1-argument ordinal accessor (second..tenth) backed by nthElement, so the whole Racket-style family shares one implementation and works on finite collections and infinite sets alike. Call diagnostics (different branches may describe different overloads): • eighth requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1528. These notes are not a complete signature or a stability guarantee.

elapsed

Keyword

elapsed expr   |   elapsed [ … ]   |   elapsed(fn)
Times an operand and returns Duration. `elapsed(square(2))` wraps that call — start, run square(2), end — it does not pass 4 to elapsed. Bare `elapsed square(2)` is the same wrap. `[ … ]` is only for a statement sequence. Successful values are discarded; use `bench` to keep the result.

Examples

d: elapsed(square(2))

d: elapsed qsort(xs)

d: elapsed [ setup(); qsort(xs) ]

elements

Function

elements(collection)
Dispatches to Iterable.iterate on the given collection or object, returning a generator, stream, or collection of elements. Convenience for dispatch(Iterable, "iterate", collection). Distinct from iterate(fn, start[, count]).

Examples

elements([1, 2, 3])

elements(my_custom_tree)

else

Keyword

if condition then consequent else alternative
Introduce the alternative branch when preceding if or elseif conditions do not hold. Used in both compact and end-terminated conditionals. See doc if and doc elseif.

Examples

println(if false then 1 else 2)

elseif

Keyword

if condition
  body
elseif other_condition
  other_body
else
  fallback
end
Add another condition to the same end-terminated if expression. The chain uses one closing end. else if is two nested constructs and needs a closer for each. See manual "End-form blocks".

Examples

grade: if 7 > 9
  "high"
elseif 7 > 5
  "middle"
else
  "low"
end
println(grade)

email

Function

email(string)
A string to an Email; rejects anything without [email protected] shape. Manual §1.2 Influences; read with manual "1.2" Excerpt: - **REBOL** — the `:` value binding, the family of scalar value literals (URL, email, file, money, pair, issue, …), the get-word (`:w`), refinements (`name/ref`), and the value-returning (non-throwing) error model. - **Forth / Pop-11** — the stack model: the global interpreter stack, the postfix sequence notation, and the stack-shuffle verbs.

email?

Function

Call diagnostics (different branches may describe different overloads): • email? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

emergence

Reserved vocabulary

Reserved vocabulary with no dedicated parser implementation in this build. It is not a usable standalone form. Use doc "discover" for the implemented discovery interface, and manual for supported language forms. Recognition of a name is not a claim that its intended feature is implemented.

empty?

Function

emptyPredicate: empty? — true for an empty collection (array / tuple / string / set / dict). An infinite set is never empty. Non-collections error. Call diagnostics (different branches may describe different overloads): • empty? requires exactly 1 argument Extracted library reference: evaluator/scheme_extras.go:591. These notes are not a complete signature or a stability guarantee. Manual §5.4 Lists and recursion — `[h | t]`; read with manual "5.4" Excerpt: partial where `tl` is total: `hd([])` raises, `tl([])` is `[]`, so write the base case as `empty?(xs)` rather than leaning on the tail to fail. - **In a `match` arm, `[h]` is a block, not a one-element array** — it evaluates to `h`. Everywhere else (binding right-hand side, call argument, operand, function-body last expression) `[h]` is the array `[h]`. Write `[h,]` when you

empty_set

Value

Built-in SET value: {}

emptyset

Value

Built-in SET value: {} Manual §5.10 Sets; read with manual "5.10" Excerpt: and `{1, 2, 3} == {3, 2, 1}`. The empty set is `{}` (equivalently `set()`, `emptyset`, or `∅`); `len(s)` is the cardinality. ```axioma {3, 1, 2, 2, 1} # → {1, 2, 3} (deduped, unordered)

encode

Function

Gödel encoding functions Call diagnostics (different branches may describe different overloads): • encode requires exactly 1 argument Extracted library reference: evaluator/builtins.go:6397. These notes are not a complete signature or a stability guarantee. Manual §28.2 28.2 Secondary runners: Julia / R / Node.js / TypeScript / Lua / Common Lisp / Free Pascal / C / Haskell; read with manual "28.2" Excerpt: - **One `/eval` contract, shared JS encoder for Node and tsx.** Node and TypeScript encode with an explicit JS encoder (stricter than `JSON.stringify`: non-finite numbers and cyclic values are *errors*, not silent `null`s); Julia and R have no stdlib JSON, so a self-contained encoder is spliced around the body (the Lisp/Lua precedent). All decode

end

Keyword

if / while / for / loop / repeat / function / module … end
Close a keyword-terminated statement body. Usually the header is followed by a newline, then the body and its matching end. Nested bodies each require their own closer. Brackets remain an alternative. end is reserved; it is not the last-index marker in a collection: use xs[$], xs[-1], or last(xs). See manual "End-form blocks".

Examples

for n in 1..2
  println(n)
end

ends_with

Function

ends_with(s, suffix) — true if s ends with suffix. Call diagnostics (different branches may describe different overloads): • ends_with requires 2 arguments: string, suffix Extracted library reference: evaluator/builtin_strings.go:97. These notes are not a complete signature or a stability guarantee.

Enhanced Concept System

Concept

Multi-phase concept system with cognitive science features
Axioma's enhanced concept system implements cognitive science principles with 4 integrated phases: multiple categorization, inference engine, semantic relationships, and prototype theory.

Examples

# Phase 1: Multiple categorization

concept Duck implements Flyable, Swimmable { }

Duck is Flyable             # Interface check



# Phase 2: Inference rules (relation store)

rule flies(X) :- bird(X)    # Head derives whenever body holds

deduce                      # Apply forward-chaining



# Phase 3: Semantic relationships

Dog relatedTo Mammal        # Bidirectional relation

Engine partOf Car           # Hierarchical relation



# Phase 4: Prototype theory

similarity(Dog, Cat)        # Cognitive similarity

typicality(Robin)           # Prototypicality measure

prototype({animals})        # Find best example

entails

Argument Logic

premise entails conclusion
Logical entailment operator. Expresses that a premise logically entails a conclusion.

Examples

Axiom entails Theorem

Premise entails Conclusion

entailment: Logic entails Result

entity

Keyword

name: entity Concept { slot: value, ... }  OR  name: entity Concept with slot: value, ...
Creates a concrete instance of a concept — the keyword sibling of the indefinite-article forms `a` / `an`. All three produce the same instantiation, with the brace block or the provisional `with slot: value, ...` list.

Examples

drone: entity Airplane { brand: "DJI" }

plane: a Airplane { brand: "Boeing" }

enum

Keyword

enum Name = Item1, Item2, ...
Keyword-first ordinal enum (soft keyword). Same semantics as `Name enumerates Item1, Item2, ...`. Not an ADT — payloads use `data`. `enum: 1` still binds the name.

Examples

enum Day = Mon, Tue, Wed

Day enumerates Mon, Tue, Wed   # same

Mon.ord     # 0

succ(Mon)   # Tue

enumerate

Function

enumerate(xs)
Returns the Array of (index, element) pairs, 1-based and index-first, over Array/Tuple/String(runes)/Set(canonical sorted order)/finite Range. The accessor spelling is xs.indexed (synonym: .enumerated). Open ranges error (infinite).

Examples

enumerate(["a", "b"])    # [(1, "a"), (2, "b")]

for i, e in enumerate(xs) [ ... ]

{(i, e) | (i, e) <- enumerate(xs), i > 1}

enumerates

Keyword

Name enumerates Item1, Item2, ...
Defines an enumerated DataType with ordinals and iteration. Formal dual: `enum Name = Item1, Item2, ...`.

Examples

Day enumerates Mon, Tue, Wed

enum Season = Spring, Summer

Mon is Day   # true

Wed.ord     # 2

epistem

Type

epistem(relation, args...)  →  Epistem
An Epistem is the primary unit of knowledge in Axioma — every asserted or derived fact mints one as a first-class value. The unit carries independent, orthogonal epistemic axes: 1. Grounding — how well it is known, the strength ladder: axiom > postulate > theorem > conjecture > hypothesis > datum. Query: grounding(rel, args...). 2. Truth-kind — WHY it holds, Schopenhauer's fourfold root: logical, empirical, transcendental, metalogical, motive. Query: truth_kind(...); set via set_truth_kind(...) or the axiom/<kind> refinement. 3. Truth value — Belnap B4 bilattice: true (⊤ᵇ), false (⊥ᵇ), both (⊤⊥ᵇ, paraconsistent), neither (?ᵇ). Query: truth(...); set via set_truth(...). 4. Degree — numeric confidence in [0, 1], carried on the unit as .truth. Related per-fact layers: the value stance (value_good / value_bad / value_indifferent, query value_kind_of), aspectual framings (qua / framings_of), challenge marks (challenge / challenged), and defeasance (cancel / uncancel). The epistem(rel, args...) builtin returns the unit itself as a value — inspect it with .type (grounding), .truth (degree), .surface_form, .justification; test with is_epistem(x). Provenance: `why fact(...)` and proof(...) trace a derived unit to its base posits.

Examples

relation parent(x, y)

axiom/empirical parent("john", "mary")

u: epistem("parent", "john", "mary")

type(u)   # "Epistem"

u.type    # "axiom"  (the grounding axis)

epistem?

Function

Call diagnostics (different branches may describe different overloads): • epistem? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

epistemic_model

Function

epistemic_model(system) - Create a new epistemic model for knowledge/belief Example: epistemic_model("S5") → New epistemic model Extracted library reference: evaluator/builtins.go:17735. These notes are not a complete signature or a stability guarantee.

eq?

Function

eqIdentityBuiltin builds eq? / eql?. Call diagnostics (different branches may describe different overloads): • eq? requires exactly 2 arguments Extracted library reference: evaluator/scheme_predicates.go:167. These notes are not a complete signature or a stability guarantee. Manual §22.6.1 Scheme/Lisp-style predicates (`?` suffix); read with manual "22.6.1" Excerpt: # equal? is deep, type-strict (`===` is the infix spelling) eq?(1, 1) # true eq?([1,2], [1,2]) # false (distinct objects) equal?([1,2], [1,2]) # true equal?(1, 1.0) # false (type-strict) 1 === 1.0 # false 1 == 1.0 # true (exact tower) equal?('a', "a") # false 'a' == "a" # true (Character ≠ String as a TYPE, like Byte ≠ Integer)

eql?

Function

eqIdentityBuiltin builds eq? / eql?. Call diagnostics (different branches may describe different overloads): • eql? requires exactly 2 arguments Extracted library reference: evaluator/scheme_predicates.go:167. These notes are not a complete signature or a stability guarantee.

equal

Function

equal(x, y)
Multi-argument predicate that checks equality between terms using first-order unification.

Examples

equal(4, 4)  # Returns true

equal(add(2, 3), 5)  # Returns true

forall x in Numbers: equal(add(x, 0), x)

equal?

Function

deepEqualBuiltin builds equal? — deep, type-strict structural equality. Same structural engine as `==` but strict at every depth (evalValueEqualityStrict), so equal?([1,2],[1,2]) is true while equal?(1, 1.0) — and equal?([1],[1.0]) — is false, per Scheme's exact vs inexact distinction; likewise equal?('a', "a") is false where 'a' == "a" is true (the Byte–Integer precedent, extended to Character 2026-09-07). Call diagnostics (different branches may describe different overloads): • equal? requires exactly 2 arguments Extracted library reference: evaluator/scheme_predicates.go:185. These notes are not a complete signature or a stability guarantee. Manual §6.2 Comparison; read with manual "6.2" Excerpt: collections key by `==`. `===` / `!==` are Elixir-style strict equality — same as `equal?` / `not equal?` — so an Integer never strictly equals a Float, at any depth (`[1] === [1.0]` is false). The same line separates the *equal as values, distinct as types* pairs: `byte(65) == 65` and `'a' == "a"` hold, `byte(65) === 65` and `'a' === "a"` do not, at any depth

equijoin

Function

Call diagnostics (different branches may describe different overloads): • equijoin requires exactly 4 arguments: equijoin(R, S, r_index, s_index) Extracted library reference: evaluator/builtins.go:7674. These notes are not a complete signature or a stability guarantee. Manual §28.5.10 Tuple relational calculus — `[trc | …]`; read with manual "28.5.10" Excerpt: **Cartesian product vs equijoin in TRC** (same lesson as SQL): ```axioma relation emp(id, name)

equiv

Symbol

=== ≡ (Glyph) === name: equivalent words: equivalent latex: equiv category: logic codepoint: U+2261 meaning: p ≡ q — equivalence

equivalence_classes

Function

equivalence_classes(expressions) - Partition formulas into equivalence classes All formulas within a class are logically equivalent to each other Example: equivalence_classes([f1, f2, f3]) → [[f1, f2], [f3]] Call diagnostics (different branches may describe different overloads): • equivalence_classes argument must be an array of boolean expressions • equivalence_classes requires exactly 1 argument: an array of boolean expressions Extracted library reference: evaluator/builtins.go:17008. These notes are not a complete signature or a stability guarantee.

equivalent

Symbol

=== ≡ (Glyph) === name: equivalent words: equivalent latex: equiv category: logic codepoint: U+2261 meaning: p ≡ q — equivalence

equivalent_terms

Function

equivalent_terms(taxonomy, a, b)
DAC's 'equal predication': true when two terms carry the same characteristic content (mutual containment — the same node; a species alias and its differentia are equivalent).

Examples

equivalent_terms(porphyry, human, "rational")   # true

eqv?

Function

eqIdentityBuiltin builds eq? / eql?. Call diagnostics (different branches may describe different overloads): • eqv? requires exactly 2 arguments Extracted library reference: evaluator/scheme_predicates.go:167. These notes are not a complete signature or a stability guarantee. Manual §20.1 Identity is Leibniz identity, not address comparison; read with manual "20.1" Excerpt: `-0.0 == 0.0` is true — `str` renders them `"-0"` and `"0"`, so they are discernible. (Scheme's `eqv?` gives both the same answers.) The executable statement of these laws is [`lib/laws/equality.ax`](../../lib/laws/equality.ax); run it with

erase

Function

Call diagnostics (different branches may describe different overloads): • argument to erase must be a stack • erase requires 1 argument: stack Extracted library reference: evaluator/builtins.go:12239. These notes are not a complete signature or a stability guarantee. Manual §18.1 Core operations; read with manual "18.1" Excerpt: | `depth(s)` / `stacklength(s)` | `→ n` | Current number of items | | `clear(s)` / `erase(s)` | `… →` | Empty the stack | ### Stack-shuffle operations

erasenum

Function

Call diagnostics (different branches may describe different overloads): • count must be non-negative • erasenum requires 2 arguments: stack, count • first argument to erasenum must be a stack • second argument to erasenum must be an integer Extracted library reference: evaluator/builtins.go:12288. These notes are not a complete signature or a stability guarantee. Manual §18.3 Bulk & depth operations; read with manual "18.3" Excerpt: | `dupnum(s, n)` | Duplicate top `n` times | | `erasenum(s, n)` | Drop top `n` items | ### Array conversion

err?

Function

err?(value)
Test whether a constructor value has the Err tag. This is a tag test; it does not unwrap or execute the contained value. See manual "Option" for Option, Result and Either.

error

Function

error(msg [, hint [, kind]])
Build an inert, truthy Error value. A well-typed call does not stop the program. To stop, raise the string or the value.

Examples

e: error("bad input", "expected a number")

e.message

raise(e)

error?

Function

Call diagnostics (different branches may describe different overloads): • error? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee. Manual §29.11 Error kinds as sub-Concepts; read with manual "29.11" Excerpt: > **VM parity:** `try` / `otherwise` / `attempt` are evaluator-only — under `--vm` they report a clean `compilation not implemented`. The value-level builtins `error()` / `raise` / `error?` *do* work under `--vm`, as does classification of explicitly tagged values with `e is IncompleteReasoningError` and `e is Error`. Error field access, including `.kind`, remains evaluator-only. Porting the whole errors-as-values floor to the VM is a single later phase. ---

essence

Ontological Logic

subject essence predicate
Essential property operator. Expresses that a property is essential to something's nature.

Examples

Human essence Rationality

Triangle essence ThreeSided

essential: Concept essence Property

eval

Function

eval(ast)
Evaluates an AST node at runtime and returns the resulting value. Sibling: quote, parse.

Examples

expression: quote(x * 10)

x: 3

eval(expression)  # 30

eval_free_predicate

Function

eval_free_predicate(model, predicate, term) - Evaluate P(t) Example: eval_free_predicate(flm, "bald", "the_king") → "true"/"false"/"undefined" Call diagnostics (different branches may describe different overloads): • eval_free_predicate requires 3 arguments: model, predicate, term • first argument must be a free logic model • second argument must be a string (predicate) • third argument must be a string (term) Extracted library reference: evaluator/builtins.go:19429. These notes are not a complete signature or a stability guarantee.

even

Function

Call diagnostics (different branches may describe different overloads): • even requires exactly 1 argument Extracted library reference: evaluator/builtins.go:4541. These notes are not a complete signature or a stability guarantee. Manual §22.6.1 Scheme/Lisp-style predicates (`?` suffix); read with manual "22.6.1" Excerpt: `?` is part of the identifier (`zero?` is one word), so these read naturally. The sign predicates treat a non-number as `false` (matching `even`/`positive`). ```axioma # sign / parity (over Integer, Float, Rational)

even?

Function

even?(n)
True iff the Integer is even (big-aware). Manual §22.6.1 Scheme/Lisp-style predicates (`?` suffix); read with manual "22.6.1" Excerpt: positive?(5) # true minus?(-1/3) # true (strictly negative) negative?(-5) # true even?(4) # true odd?(3) # true # type predicates (join number?/integer?/string?/boolean?/null?/pair?/array?…) list?([1, 2, 3]) # true procedure?(func(x) [x]) # true

eventually

Temporal Logic

eventually proposition
Temporal possibility operator (◇P). Expresses that a proposition will eventually be true.

Examples

eventually true

eventually (technology advances)

future: eventually discovery

every

Keyword

every S is P   |   every Concept has slot: default
Two senses. (1) Categorical universal affirmative (the A form of Leibniz's 1679 judgment calculus): `every S is P` is a proposition, decided by characteristic-number pair arithmetic against the active taxonomy, or by subsumption/extents when both terms are Concepts. Siblings: `no S is P` (E), `some S is P` (I), `some S is not P` (O). (2) KM-style universal slot declaration: `every Concept has slot: default`, equivalent to `Concept has slot: default`.

Examples

create_porphyry()

every human is animal   # true — 10374 divisible by 546

every Car has wheels: 4

everyone

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §10.3 Epistemic logic; read with manual "10.3" Excerpt: any finite sequence of the selected agents' accessibility links, including the actual world. Everyone knowing a proposition at the actual world is a weaker condition. Neither stored reports nor nested proposition strings supply a general calculus of common knowledge. See [epistemic model boundaries](https://github.com/vevenhar/axiomalang/blob/main/docs/epistemic-model-boundaries.md).

exact?

Function

exact?(x)
True iff x is an exact number (Integer or Rational). Floats are inexact; non-numbers are neither. Manual §6.9 Operator precedence (high → low); read with manual "6.9" Excerpt: The embedding runs through `float64`, so **exactness stops at the complex boundary** — `exact?(complex(1, 0))` is `false`, and `complex(0, 1) + 1/3` is inexact. Keeping exactness inside the plane would need exact Gaussian rationals, which Axioma does not have.

exactly

Keyword

{fields} exactly | Ctor { fields } exactly
Closed hash or record pattern. `{name, age} exactly` matches only when those keys are present and no others remain (`{name, age}` stays open). `P { x, y } exactly` requires every constructor field to be listed. Soft keyword: `exactly: 5` still binds the name. `{a, ..} exactly` is a SyntaxError. `{a, ..rest}` already accounts for every leftover key.

Examples

match h with | {name, age} exactly => name | _ => none

match dict() with | {} exactly => "empty"

match pt with | P { x, y, z } exactly => x

execute

Function

Call diagnostics (different branches may describe different overloads): • execute requires environment (this should not be called) Extracted library reference: evaluator/builtins.go:5565. These notes are not a complete signature or a stability guarantee. Manual §25.3 Execute a file with `:source` and replay it with `:refresh`; read with manual "25.3" Excerpt: ### Execute a file with `:source` and replay it with `:refresh` In the **native CLI REPL**, both at the interactive terminal and with piped input, `:source file.ax` reads the file and executes it as one complete input

exists

Keyword

exists [op val] variable in set: predicate  OR  exists [lower <=] variable [<= upper]: predicate
Existential quantifier - checks if predicate is true for at least one element (or N elements for counting quantifiers). Supports set domains, ranges, and counting comparisons (==, >=, <=, >, <) directly after exists.

Examples

exists x in {1, 2, 3}: x > 2

exists >= 3 x in domain: x > 2  # counting quantifier: at least 3

exists == 2 x in domain: even   # counting quantifier: exactly 2

exists 1 < x < 5: x == 3        # range quantifier

exists x <= 0: x == 0           # single-sided range

exists?

Function

Free Logic existence predicate (natural language form) Call diagnostics (different branches may describe different overloads): • exists? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:5632. These notes are not a complete signature or a stability guarantee.

exists_concept

Function

exists_concept(kb, role_name, concept_name) - Create existential restriction (∃R.C) Example: exists_concept(kb, "hasAdvisor", "Professor") → has at least one Professor advisor Call diagnostics (different branches may describe different overloads): • exists_concept requires 3 arguments: kb, role, concept • first argument must be a DL knowledge base • role and concept names must be strings Extracted library reference: evaluator/builtins.go:18725. These notes are not a complete signature or a stability guarantee.

exp

Function

exp(x)
e raised to x. Manual §4.1 Primitives; read with manual "4.1" Excerpt: | `Rational` | `1/3`, `rational(2, 6)` → `1/3` | Exact `p/q` on big integers, GCD-reduced — `/` on integers stays exact (`1/3 + 1/6` → `1/2`, never `0.4999…`); accessors `numerator(r)` / `denominator(r)` | | `Complex` | `complex(3, 4)` → `3.0 + 4.0i`; `im` → `i` | The **top of the numeric tower** — every other numeric type embeds, so `complex(3, 4) + 1/2` → `3.5 + 4i`. The unit is the shadowable builtin `im` (`complex(0, 1)`); write `1 + im`, `(1 + im)^2` → `2i`, `2 * im`. No juxtaposed literal: `2im` is diagnosed (same as `2x`). Full arithmetic incl. `^` (exact at integer exponents: `im^2` → `-1`) and unary minus; `sqrt`/`exp`/`log`/`sin`/`cos`/`abs`/`conjugate` all accept one. No ordering. Embedding is via `float64`, so exactness stops here. Coefficients use the same Float printer | | `String` | `"hello"`, `"unicode: ∀∃"`, `"\u{2203}"`, `r"raw \n"` | UTF-8; escape sequences + `r"..."` raw prefix — see [Strings](#strings--escape-sequences-raw-form-codepoint-builtins) | | `Boolean` | `true`, `false` | Classical two-valued | | `Byte` | `byte(0xFF)` | Single byte 0..255; distinct from `Integer`. See [Binary data](#binary-data--byte-and-bytes) |

expand_dims

Function

Call diagnostics (different branches may describe different overloads): • axis must be an integer • expand_dims requires 2 arguments: tensor, axis • first argument must be tensor or matrix • tensor conversion requires a Float matrix; use float(m) explicitly Extracted library reference: evaluator/builtins.go:14430. These notes are not a complete signature or a stability guarantee. Manual §5.14 Matrices, tensors & dataframes; read with manual "5.14" Excerpt: squeeze(tensor([[1, 2, 3]])) # drop size-1 axes → vector [3] expand_dims(tensor([1, 2, 3]), 0) # add an axis → 1×3 ``` **DataFrames** — column-oriented tables (pandas-style):

expect

Function

expect(label, actual, expected)
Test assertion: pass iff actual == expected; failures make the run exit non-zero. Manual §26.9 Testing — the `expect` builtin; read with manual "26.9" Excerpt: ### Testing — the `expect` builtin `expect(label, actual, expected)` is a real assertion: it passes iff `actual == expected` (regular value equality — cross-type numerics, deep array/set/map, MVL coercion). It prints `go test`-style markers — `--- PASS: <label> (<duration>)` on a match, `--- FAIL: <label> (<duration>)` plus the actual/expected values on a mismatch; the parenthesized duration is the time spent evaluating `actual`/`expected` (adaptive `µs`/`ms`/`s`), so a slow assertion stands out and can flag an optimization regression the way `go test` shows per-test durations. A mismatch increments a run-level counter and **continues** (accumulate-and-continue); at end-of-run the CLI prints a Go-style summary to stderr — `PASS <script> (N assertions)` or `FAIL <script> (N of M failed)` — and exits **non-zero** if any expectation failed. (The summary prints only for scripts that ran ≥1 `expect()`, so ordinary scripts stay silent.) This is what lets the parallel test runner (which keys on exit code) actually detect wrong answers — unlike the older `if cond then println("✅") else println("❌")` idiom, which exits 0 even when every check is wrong.

expected_payoff

Function

Call diagnostics (different branches may describe different overloads): • all strategies must be mixed strategies • expected_payoff requires 2 arguments: game, strategies • first argument must be a game • strategies must be an array Extracted library reference: evaluator/builtins.go:13620. These notes are not a complete signature or a stability guarantee.

explain

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §28.5.8 Refinement modes — `/bag`, `/k3`, `/strict`, `/distinct`, `/explain`; read with manual "28.5.8" Excerpt: #### Refinement modes — `/bag`, `/k3`, `/strict`, `/distinct`, `/explain` The block accepts SQL-shaping refinements that pre-configure how the compiled comprehension treats duplicates, NULLs, and shape strictness:

explode

Function

explode(s)
SML spelling of chars — string → Array of single-character strings (runes). Exact alias. Manual §22.8 List & string helpers; read with manual "22.8" Excerpt: chars("abc") # → ["a", "b", "c"] (string → char array) explode("abc") # → ["a", "b", "c"] (SML spelling; exact alias of chars) implode(["a", "b", "c"]) # → "abc" (inverse of explode/chars) implode(explode("日本語")) # → "日本語" (round-trip over runes) rev([1, 2, 3]) # → [3, 2, 1] (SML List.rev; exact alias of reverse)

explore

Reserved vocabulary

Reserved vocabulary with no dedicated parser implementation in this build. It is not a usable standalone form. Use doc "discover" for the implemented discovery interface, and manual for supported language forms. Recognition of a name is not a claim that its intended feature is implemented.

export

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §19.10.2 Macros and template hygiene; read with manual "19.10.2" Excerpt: **Modules, limits, and tooling.** Macros use existing module `export` and import forms; exported macros retain access to private helpers. Preparation reads module syntax without running application code, detects import cycles, and reuses the prepared artifact. Source changes between preparation and execution require a

export_visualization

Function

Export visualization to specific format Call diagnostics (different branches may describe different overloads): • export_visualization requires exactly 3 arguments: canvas, filename, format • first argument must be a canvas • second argument must be a string (filename) • third argument must be a string (format) Extracted library reference: evaluator/builtins.go:9262. These notes are not a complete signature or a stability guarantee.

expr_stmt

Function

Call diagnostics (different branches may describe different overloads): • expr_stmt requires exactly 1 argument Extracted library reference: evaluator/builtins.go:16439. These notes are not a complete signature or a stability guarantee.

expr_stmt?

Function

Call diagnostics (different branches may describe different overloads): • expr_stmt? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1645. These notes are not a complete signature or a stability guarantee.

extend

Function

extend(array, collection)  |  array extend collection
Grows an array in place by concatenating the elements of a collection. Distinct from append, which nests a second array as one element. Returns the same array. copy() first for a snapshot.

Examples

a: [1, 2]

extend(a, [3, 4])  # a is [1, 2, 3, 4]

a extend (5, 6)    # message form; tuples work too

extends

Keyword

concept Child extends Parent
Defines concept inheritance. The child concept inherits the parent's slots, methods and axioms and can override defaults or add its own. Slot inheritance is live: a slot added to the parent after the `extends` reaches the child and its later instances, a removed one leaves, and the child's own slot shadows; with several parents the first-declared wins. `Child had slot` refuses for a slot the child only inherits.

Examples

concept Mammal extends Animal

concept Manager extends Employee

eye

Function

Call diagnostics (different branches may describe different overloads): • eye requires 1 or 2 arguments: n [, m] • m must be an integer • matrix dimensions must be positive • n must be an integer Extracted library reference: evaluator/builtins.go:13784. These notes are not a complete signature or a stability guarantee.

factorial

Function

factorial(n)
n! — exact at any size (arbitrary precision). Manual §4.1.1 Integers don't overflow; read with manual "4.1.1" Excerpt: builtins (`succ`/`pred`, `sum`, `abs`, `divmod`/`quotient`/`remainder`, `floor`/`ceil`/`round`/`trunc`/`int`, `gcd`/`lcm`, `factorial`, …). Consequences of the design:

facts

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §14.1 Facts; read with manual "14.1" Excerpt: ### Facts Declare a relation with `relation` (or the short hard alias `rel`), then assert facts with `assert` (or the graded `axiom` / `postulate` — see [§15](#15-knowledge-base-axioms--postulates)):

facts_by_kind

Function

facts_by_kind(kind)
Returns all facts whose Schopenhauerian truth-kind matches the given kind: "logical", "empirical", "transcendental", "metalogical", or "motive". The kind-axis sibling of predicates_of (which discovers along the grounding axis).

Examples

axiom/empirical weighs("apple", 95)

facts_by_kind("empirical")

fail

Keyword

p(X) :- q(X), cut, fail
An explicit logical goal that yields no solution. cut followed by fail also discards alternatives of the enclosing predicate. It does not establish classical negation or enumerate a complement.

false

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §3.3.1 Uninitialized slots and identity defaults; read with manual "3.3.1" Excerpt: matches nullary constructors: **containers may start empty; scalars do not get silent zeros.** `0`, `""`, and `false` remain fully legal as *explicit* initializers. **Bottoms vs holes vs empties.**

falsum

Symbol

=== ⊥ (Glyph) === name: falsum latex: bot, perp category: logic codepoint: U+22A5 meaning: ⊥ — falsum (false)

fdiv

Operator

a fdiv b | fdiv(a, b)
Floating division of Integer, Rational, Byte or Float operands; always returns Float. Finite operands are divided exactly before one binary64 rounding (nearest, ties to even), avoiding premature overflow of huge operands. Overflow yields signed infinity, underflow may yield signed zero, and NaN/infinity follow Float division. Every zero divisor errors. Same-line soft infix keyword, multiplication precedence, left associative; ordinary bindings may shadow the callable builtin. Both operands are evaluated once. Interpreter only: VM refuses fdiv. Existing / and its word form rdiv stay exact on exact operands, div / idiv / ÷ stay floor division, and // and # stay comments.

Examples

fdiv(1, 8)  # 0.125

8 fdiv 2  # 4.0

fdiv(10^400, 8*10^400)  # 0.125

fe

Keyword

Lojban-inspired x3 argument-position tag (destination). Used inside tagged relational forms, not as a standalone function.

fi

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §4.5.8 Unicode normalization — `normalize(s, [form])`; read with manual "4.5.8" Excerpt: normalize("\u{E9}", "NFD") # decomposes → "e\u{301}" normalize("\u{FB01}", "NFKC") # "fi" — compatibility fold (fi) normalize("\u{2460}", "NFKC") # "1" — ① folds too try(normalize("x", "NFX")) # catchable Error naming the forms ```

fi'o

Keyword

Generic semantic-role tag in a tagged relational form.

fifth

Function

ordinalBuiltin builds a 1-argument ordinal accessor (second..tenth) backed by nthElement, so the whole Racket-style family shares one implementation and works on finite collections and infinite sets alike. Call diagnostics (different branches may describe different overloads): • fifth requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1528. These notes are not a complete signature or a stability guarantee.

file

Function

file(string)
A string to a File path (the leading % is added when absent). Manual §3.15 Formatting a file — `--fmt`; read with manual "3.15" Excerpt: ### Formatting a file — `--fmt` `--glyphify` canonicalizes how an operator is **spelled**; `--fmt` canonicalizes where it **sits**. The two compose, and together they are the

file?

Function

Call diagnostics (different branches may describe different overloads): • file? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

file_exists

Function

File-existence check. Named `file_exists` (not `exists`) because the bare word `exists` lexes as the existential quantifier (∃) keyword, so `exists("/path")` is a parse error and the builtin was unreachable. `file_exists` is a non-reserved identifier and matches the io package's `IO.file_exists`. (For deletion use `remove(path)`.) Extracted library reference: evaluator/builtins.go:15432. These notes are not a complete signature or a stability guarantee. Manual §4.7.6 `read` and file I/O; read with manual "4.7.6" Excerpt: > **Naming gotchas (reserved-word collisions).** > - **Existence is `file_exists(path)`, not `exists(...)`** — the bare word > `exists` lexes as the existential quantifier (`∃`), so `exists("/p")` is a > parse error. `file_exists` matches the io package's `IO.file_exists`. > - **File deletion is `remove(path)`, not `delete(...)`** — prefix `delete a[i]`

fill

Function

fill(count_or_array, value)
Build n slots of value (`fill(n, v)`, `[](n, v)`), or paint every live slot of an array (`fill(a, v)`, `a fill v`). Manual §5.1 Arrays; read with manual "5.1" Excerpt: two ways forward: grow with `append(a, v)` or `insert_at(a, v)`, or pre-size and then fill (`fill(n, none)` or `[none,] * n`, after which `a[j]: v` is an ordinary in-bounds store). The comprehension `[none | i <- 1..n]` is the same pre-size, written as a generator.

filter

Function

filter(predicate, collection)
Filters elements of a collection (array, set, or tuple) based on a boolean predicate function, returning a new collection of the same type containing only the elements that satisfy the predicate.

Examples

filter(lambda x => x % 2 == 0, [1, 2, 3, 4])  # Returns [2, 4]

filter(is_prime, {2, 3, 4, 5})                # Returns {2, 3, 5}

finally

Keyword

try ⏎ body ⏎ finally ⏎ cleanup ⏎ end
Always-run cleanup clause of end-form try. Not Aristotle's final cause — that infix is `P teleologically Q`. RESERVED. `[finally x]` stays a word list.

Examples

try
    1 / 0
finally
    closed: true
end

find_all

Function

Call diagnostics (different branches may describe different overloads): • find_all requires environment (this should not be called) Extracted library reference: evaluator/builtins.go:5581. These notes are not a complete signature or a stability guarantee.

find_contradictions

Function

find_contradictions(model) - Find all propositions with truth value "both" Example: find_contradictions(pm) Call diagnostics (different branches may describe different overloads): • argument must be a paraconsistent model • find_contradictions requires 1 argument: model Extracted library reference: evaluator/builtins.go:18297. These notes are not a complete signature or a stability guarantee.

finite?

Function

Call diagnostics (different branches may describe different overloads): • finite? requires exactly 1 argument Extracted library reference: evaluator/scheme_extras.go:475. These notes are not a complete signature or a stability guarantee. Manual §22.6.1 Scheme/Lisp-style predicates (`?` suffix); read with manual "22.6.1" Excerpt: infinite?(inf) # true is_infinite(inf) # true finite?(3.14) # true is_finite(3.14) # true integral?(5.0) # true — the VALUE is whole (5.01/NaN/±Inf → false; the TYPE test is integer?) # equality: eq? / eql? / eqv? are shallow identity (collections by reference);

first

Function

first(s, [n])
First element (rune-based on Strings); first(s, n) takes the first n — lazy/infinite sources too. Manual §2.4 First steps; read with manual "2.4" Excerpt: ### First steps ```axioma axioma> a: {1, 2, 3}

fix

Function

fix(f, args...)
Fixpoint: fix(f) is the g satisfying g == f(g), so a lambda can recurse without being named. fix(f, x) applies immediately. Manual §3.3 Fresh declarations with `let` and `var`; read with manual "3.3" Excerpt: - **Reserved word** (since August 2026). `let`, `var`, and `val` are keywords, so a bare `let: 42` is a SyntaxError that names the fix. To use one of them as an ordinary name, guard it: `$let: 42`, `func($val)`, `h.$val`, `$val() = 1` — the same `$` guard every reserved word takes. POP-11 word lists are the exception that needs no guard: `[let x var y]` is still the

flat_map

Function

flatMapBuiltinFn maps then flattens ONE level: an Array/Tuple/Set result is spliced in; any other (scalar) result is appended as-is. Always returns an Array. Call diagnostics (different branches may describe different overloads): • flat_map requires exactly 2 arguments: a function and a collection Extracted library reference: evaluator/builtins.go:22887. These notes are not a complete signature or a stability guarantee. Manual §5.10 Sets; read with manual "5.10" Excerpt: `foldr`), and the Enumerable verbs (`take_while`, `sort_by`, `min_by`, `group_by`, `flat_map`, …). ```axioma s: {30, 4, 100, 2, 77}

flatmap

Function

appendMapBuiltin builds append_map / flatmap / mapcat: map fn over the collection, where fn returns a collection per element, and concatenate the results into one Array. Call diagnostics (different branches may describe different overloads): • flatmap requires 2 arguments: function and collection • flatmap: second argument must be an array, tuple, or set Extracted library reference: evaluator/scheme_extras.go:109. These notes are not a complete signature or a stability guarantee. Manual §22.7 Higher-order functions; read with manual "22.7" Excerpt: foldr(fn, init, coll) # right fold, fn(elem, acc) (also fold_right) append_map(fn, coll) # map then concatenate the per-element collections (flatmap / mapcat) for_each(fn, coll) # apply fn for side effects; returns none constantly(x) # → a function that ignores its args and returns x negate(pred) # → a predicate that logically negates pred (≠ set `complement`)

flatten

Function

flatten(nested)
Recursively flatten nested Arrays into one Array, preserving non-Array elements. Manual §12.17 Enumerable verbs; read with manual "12.17" Excerpt: flat_map(func(r) [r], [[1, 2], [3]]) # → [1, 2, 3] map then flatten one level flatten([[[1]], [[2]]]) # → [1, 2] recursively descend Arrays flat_map(identity, [[[1]], [[2]]]) # → [[1], [2]] concatenate just one level take_while(func(x) [x < 5], [1, 2, 9, 1]) # → [1, 2] leading run while the predicate holds drop_while(func(x) [x < 5], [1, 2, 9, 1]) # → [9, 1] the complement

flip

Function

flip(f) or flip(f, a, b, ...)
Swaps the first two arguments of a function. flip(f) RETURNS the swapped function, so it can be composed, mapped or stored; flip(f, a, b) applies the swap immediately. The returning form is what makes flip a combinator rather than a call shorthand — identity, partial and curry all return functions, and flip was the outlier that could not participate in a composition.

Examples

flip(sub, 2, 10)          # Returns 8 — applies sub(10, 2)

flip(sub)(2, 10)          # Returns 8 — the swapped function itself

(flip(sub) >> incr)(2, 10)   # Returns 9 — opens a pipeline

float

Function

float(x)
To Float: from a number or a numeric String; Time returns seconds. On a Matrix, returns a Float matrix copy; exact cells may round, overflow refuses. Manual §13.24 Type ascription — `(expr :: T)`; read with manual "13.24" Excerpt: and the ascribed type propagates outward, so `(n :: Ordinal) + 1` trips the arithmetic rule (§26). For a real conversion use `float(x)` / `int(x)` / `string(x)` — or their postfix spellings `x.float` and `x's float`.

float?

Function

Call diagnostics (different branches may describe different overloads): • float? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

floor

Function

floor(x)
Largest integer ≤ x — exact at any magnitude. Manual §22.3 Mathematical functions; read with manual "22.3" Excerpt: | `sqrt(x)` | Square root | | `floor(x)` | Floor | | `ceil(x)` | Ceiling | | `pow(b, e)` | Exponentiation | | `sin(x)` / `cos(x)` / `tan(x)` | Trigonometry — arguments in **radians** (like Lua/C); convert with `rad`/`deg` |

fn

Keyword

fn [name](params) [body]  OR  name: fn(params) [body]
Compatibility alias for the `func` keyword. Declares a named function or creates an anonymous function block.

Examples

fn double(x) [ x * 2 ]         # Named declaration

double: fn(x) [ x * 2 ]        # Anonymous assignment form

fold_left

Function

foldLeftBuiltin builds foldl / fold_left: fn is called (acc, elem) from the LEFT (the same shape as reduce), but accepts any callable, not just a *types.Function. Call diagnostics (different branches may describe different overloads): • fold_left requires 3 arguments: function, initial value, collection • fold_left: third argument must be an array, tuple, or set Extracted library reference: evaluator/scheme_extras.go:79. These notes are not a complete signature or a stability guarantee. Manual §22.7 Higher-order functions; read with manual "22.7" Excerpt: # Scheme/Lisp folds & combinators foldl(fn, init, coll) # left fold, fn(acc, elem) — like reduce (also fold_left) foldr(fn, init, coll) # right fold, fn(elem, acc) (also fold_right) append_map(fn, coll) # map then concatenate the per-element collections (flatmap / mapcat) for_each(fn, coll) # apply fn for side effects; returns none

fold_right

Function

foldRightBuiltin builds foldr / fold_right: fn is called (elem, acc) from the RIGHT, so foldr(fn, z, [a,b,c]) = fn(a, fn(b, fn(c, z))). This is the genuine gap — `reduce` is a left fold only. Call diagnostics (different branches may describe different overloads): • fold_right requires 3 arguments: function, initial value, collection • fold_right: third argument must be an array, tuple, or set Extracted library reference: evaluator/scheme_extras.go:49. These notes are not a complete signature or a stability guarantee. Manual §25.11 The word oracle — discovering the language by bumping into it; read with manual "25.11" Excerpt: flag: `isEmpty`, `isempty`, `IsEmpty`, `emptyp` and `empty` are all `empty?` written the way another tradition writes it, `foldRight` is `fold_right`, and a word written with a capital is a kind's name by rule, so `INTEGER` answers the type `Integer` (a capitalised `Shape` is never pushed toward the function `shape`). Without the flag the answer is one sentence under the error —

foldl

Function

foldLeftBuiltin builds foldl / fold_left: fn is called (acc, elem) from the LEFT (the same shape as reduce), but accepts any callable, not just a *types.Function. Call diagnostics (different branches may describe different overloads): • foldl requires 3 arguments: function, initial value, collection • foldl: third argument must be an array, tuple, or set Extracted library reference: evaluator/scheme_extras.go:79. These notes are not a complete signature or a stability guarantee. Manual §5.10 Sets; read with manual "5.10" Excerpt: display all show. Every consumer agrees with them — every loop form (`foreach`, `repeat`, `loop`), `map`, `filter`, `array(s)`, the folds (`reduce`, `foldl`, `foldr`), and the Enumerable verbs (`take_while`, `sort_by`, `min_by`, `group_by`, `flat_map`, …).

foldr

Function

foldRightBuiltin builds foldr / fold_right: fn is called (elem, acc) from the RIGHT, so foldr(fn, z, [a,b,c]) = fn(a, fn(b, fn(c, z))). This is the genuine gap — `reduce` is a left fold only. Call diagnostics (different branches may describe different overloads): • foldr requires 3 arguments: function, initial value, collection • foldr: third argument must be an array, tuple, or set Extracted library reference: evaluator/scheme_extras.go:49. These notes are not a complete signature or a stability guarantee. Manual §4.8 Ranges — ordered `a..b`, exclusive `..<`, `by` step, open `n..`; read with manual "4.8" Excerpt: 4, 1]`), and the collection builtins — `map`/`filter` over a range return an ordered **Array**, `reduce`/`foldr` fold in source order, and `nth`/`second`…`tenth`/`sample`/`sort`/`min`/`max`/`sum`/`product`/`zip`/ `enumerate` all take ranges directly. (Before July 2026 a range materialized as an unordered *Set*, which is how `zip(1..len(a), a)` could silently

for

Keyword

for item in source [ body ] | for item in source
  body
end
Visit each value in an iterable source. Arrays and matrix cells follow their indexing order; a Matrix visits cells in row-major order. A combined generator header walks a Cartesian product with the rightmost generator varying fastest. break leaves the loop; continue advances it. Available in the beginner subset as well as the full language. See manual "Loops" and manual "End-form blocks".

Examples

for n in 1..3
  println(n)
end

for_each

Function

forEachBuiltin builds for_each: apply fn to each element for its side effects, discarding results. Returns null (the absent value). Call diagnostics (different branches may describe different overloads): • for_each requires 2 arguments: function and collection • for_each: second argument must be an array, tuple, or set Extracted library reference: evaluator/scheme_extras.go:143. These notes are not a complete signature or a stability guarantee. Manual §22.7 Higher-order functions; read with manual "22.7" Excerpt: append_map(fn, coll) # map then concatenate the per-element collections (flatmap / mapcat) for_each(fn, coll) # apply fn for side effects; returns none constantly(x) # → a function that ignores its args and returns x negate(pred) # → a predicate that logically negates pred (≠ set `complement`) neg(n) # → -n (exact alias of negate; also neg(pred))

forall

Keyword

forall variable[,variable2,...] in set: predicate  OR  forall [lower <=] variable [<= upper]: predicate
Universal quantifier - checks if predicate is true for all elements. Supports set domains, double-sided ranges (lower <= x <= upper), and single-sided ranges (x < upper, starting at 0).

Examples

forall x in {1, 2, 3}: x > 0

forall 1 <= x <= 10: x > 0       # double-sided range

forall x < 5: x >= 0            # single-sided range (starts at 0)

forall x,y in {1, 2, 3}: (x + y) == (y + x)

forall_concept

Function

forall_concept(kb, role_name, concept_name) - Create universal restriction (∀R.C) Example: forall_concept(kb, "teaches", "Course") → only teaches Courses Call diagnostics (different branches may describe different overloads): • first argument must be a DL knowledge base • forall_concept requires 3 arguments: kb, role, concept • role and concept names must be strings Extracted library reference: evaluator/builtins.go:18758. These notes are not a complete signature or a stability guarantee.

forbidden

Deontic Logic

forbidden proposition
Deontic prohibition operator (FP). Expresses what is morally or logically forbidden.

Examples

forbidden false

forbidden (break promises)

prohibited: forbidden action

force

Function

force(x)
Resolves deferred evaluation. A `lazy` thunk caches a successful result; errors may retry and recursive forcing reports cyclic demand; a Generator from a lazy comprehension is drained into an Array; any other value is returned unchanged, following R7RS Scheme's force, so force() is idempotent and safe to map over mixed data. For an infinite generator, bound consumption with gen_take(n, g) or first(g, n) instead.

Examples

force(lazy (6 * 7))               # 42

force((x * 2 | x <- [1, 2, 3]))   # [2, 4, 6] — drains a generator

force(42)                          # 42 — not a promise, returned as-is

map(force, [lazy (1 + 1), lazy (2 + 2)])   # [2, 4]

force_cancel

Function

force_cancel(relation, args...)
Cancels a fact even when it is a strict theorem — the explicit override for cancel()'s grounding guard. Prefer revising a premise (challenge / forget_cascade); a theorem follows necessarily from its premises, so defeating it while keeping them is epistemically odd.

Examples

force_cancel("tranquil", "sage")

foreach

Keyword

foreach item in source [ body ] | foreach item in source
  body
end
Alternative spelling of for. Visit source values with the same binding, indexing and exit rules. See doc for.

Examples

foreach n in [1, 2, 3]
  println(n)
end

forget

Function

forget(relation, args...)
Retracts a fact from all grounding buckets and cleans its metadata. NOTE: conclusions already derived FROM the fact are left in place — use forget_cascade to also withdraw everything whose justification depends on it.

Examples

forget("likes", "alice", "bob")

grounding("likes", "alice", "bob")  # "unknown"

forget_cascade

Function

forget_cascade(relation, args...)
Justification-based retraction (a truth-maintenance system): withdraws the premise AND every derived fact whose derivation chain transitively names it. Conclusions with an independent surviving justification re-derive automatically on the next query.

Examples

disturbed(P) <~~ judges_bad(P)

assert judges_bad("novice")

forget_cascade("judges_bad", "novice")   # the disturbance lifts too

formally

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §29.3 End-form `try` / `catch` / `finally` / `end`; read with manual "29.3" Excerpt: `finally` is this cleanup clause. Aristotle's final cause is the four-cause infix `P teleologically Q` (with `materially` / `formally` / `efficiently`). `Acorn finally OakTree` is a SyntaxError with that hint. ### Constructing & re-raising

format

Function

format(format, args...)
Exact alias of stringf: formats into a String and RETURNS it — it never prints. The alias points at stringf, not printf, because that is what the word means everywhere newcomers carry it from: Lua's string.format, Ruby's format (≡ sprintf), Java/C#'s String.Format, and Rust's format! all return the value — and Ruby, which has BOTH format and printf, makes format the returning one. Same verbs, same numeric-tower adaptation, same loud catchable errors (prefixed 'format:'). To print, use printf — or compose: println(format(...)).

Examples

format("%.2f", 1/3)        # "0.33"  (≡ stringf)

println(format("%x", 255)) # the Lua print(string.format(...)) idiom

formed_by

Keyword

concept C { formed_by: "mode", purpose: "...", examples: [...], counterexamples: [...] }
Concept-formation metadata slot: records HOW the concept was formed — "abstraction", "combination", "distinction", "stipulation", or "metaphor" (also available as FormationMode enum members). Each mode sets a default grounding for classified instances (stipulation → axiom, abstraction → conjecture, metaphor → hypothesis, ...). Sibling slots: purpose (why it exists), examples (must classify IN), counterexamples (must classify OUT) — verified by `check Concept`.

Examples

concept Adult { formed_by: "stipulation", boundary: age >= 18 and is Person }

concepts_formed_by("stipulation")

grounding("isa", alice, Adult)  # "axiom"

formula?

Function

Call diagnostics (different branches may describe different overloads): • formula? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee. Manual §8.7 Formula type + predicate; read with manual "8.7" Excerpt: @f # "formula" formula?(f) # true boolean?(f) # false ```

forward

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §6.11 Forward pipe `|>`; read with manual "6.11" Excerpt: ### Forward pipe `|>` The forward pipe threads a value into a function call, so a chain of transformations reads **left-to-right** in the order it runs — instead of the

fourth

Function

ordinalBuiltin builds a 1-argument ordinal accessor (second..tenth) backed by nthElement, so the whole Racket-style family shares one implementation and works on finite collections and infinite sets alike. Call diagnostics (different branches may describe different overloads): • fourth requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1528. These notes are not a complete signature or a stability guarantee. Manual §6.4.1 `andalso` / `orelse` — the strictly two-valued pair; read with manual "6.4.1" Excerpt: the operand's type — a guard, a filter predicate, an `if` test fed by data of unknown provenance. Reach for `and` / `or` when the third (or fourth) truth value is information you want to keep. Neither evaluates its right operand when the left already decides the result:

framed_qua

Function

framed_qua(relation, args..., handle)
Returns true if the specified fact has been asserted under the given aspectual handle (using `qua`).

Examples

departed("estate") qua "lost"

framed_qua("departed", "estate", "lost")        # true

framed_qua("departed", "estate", "given_back")  # false

framings_of

Function

framings_of(relation_name, arg1, arg2, ...)
Returns a set of all string handles under which the specified fact has been framed using `qua`.

Examples

framings_of("departed", "estate")

free_denotes

Function

free_denotes(model, term) - Check if a term denotes Example: free_denotes(flm, "socrates") → true/false Call diagnostics (different branches may describe different overloads): • first argument must be a free logic model • free_denotes requires 2 arguments: model, term • second argument must be a string (term name) Extracted library reference: evaluator/builtins.go:19369. These notes are not a complete signature or a stability guarantee.

free_exists

Function

free_exists(model, term) - Evaluate E!(t) - "t exists" Example: free_exists(flm, "socrates") → true/false Call diagnostics (different branches may describe different overloads): • first argument must be a free logic model • free_exists requires 2 arguments: model, term • second argument must be a string (term name) Extracted library reference: evaluator/builtins.go:19459. These notes are not a complete signature or a stability guarantee.

free_logic_model

Function

free_logic_model(mode) - Create a free logic model Modes: "negative" (default), "positive", "supervaluational" Example: free_logic_model("negative") Extracted library reference: evaluator/builtins.go:19292. These notes are not a complete signature or a stability guarantee.

frege_classic_example

Function

frege_classic_example(example_type)
Creates historical examples from Frege's original 1879 Begriffsschrift work including modus ponens, universal instantiation, and identity formulas. Perfect for studying the foundations of mathematical logic.

Examples

modus_ponens: frege_classic_example("modus_ponens")

universal_inst: frege_classic_example("universal_instantiation")

identity: frege_classic_example("identity")  # a = a

frege_conditional

Function

frege_conditional(antecedent, consequent)
Creates Frege's conditional stroke representing material implication. In Begriffsschrift notation, the antecedent appears on a vertical branch below the main horizontal line containing the consequent.

Examples

p_implies_q: frege_conditional(p, q)  # P → Q

print(frege_format(p_implies_q))  # Shows spatial layout

modus_ponens: frege_conditional(and_pq, q)  # ((P ∧ Q) → Q)

frege_content

Function

frege_content(formula, negated)
Creates Frege's content stroke (—) representing judgeable content - propositions that can be asserted as true or false. The negated parameter indicates whether the content is denied.

Examples

p: frege_content("P", false)  # Positive content

not_p: frege_content("P", true)  # Negated content

complex: frege_content("Human(x)", false)  # Predicate content

frege_format

Function

frege_format(frege_object)
Creates an authentic textual representation of Begriffsschrift formulas preserving Frege's spatial relationships including judgment strokes, content strokes, conditional branches, and quantification concavities.

Examples

print(frege_format(judgment))  # Display: ⊢—— "P"

print(frege_format(conditional))  # Spatial conditional layout

print(frege_format(universal))  # Quantification with concavity

frege_formula

Function

frege_formula(root, description)
Creates a complete Begriffsschrift formula with proper spatial layout calculation. This represents a full logical expression in Frege's notation system with computed complexity and positioning.

Examples

formula: frege_formula(conditional, "Modus Ponens Structure")

complex: frege_formula(universal_conditional, "Universal Implication")

print(frege_format(formula))  # Display complete spatial layout

frege_function_app

Function

frege_function_app(function, argument, function_type, argument_type)
Creates Frege's function-argument application - his revolutionary replacement of traditional subject-predicate analysis. This allows flexible parsing of the same proposition into different function-argument structures.

Examples

human_socrates: frege_function_app(human, socrates, "predicate", "object")

equals_5_plus_3: frege_function_app(equals_5, plus_3, "concept", "function")

print(frege_format(human_socrates))  # Function application display

frege_judgment

Function

frege_judgment(content, context)
Creates Frege's judgment stroke (⊢) - the assertion that a given content is true. This represents Frege's revolutionary distinction between expressing a proposition and asserting its truth.

Examples

judgment: frege_judgment(p, "Assertion of P")  # ⊢P

print(frege_format(judgment))  # Display: ⊢—— "P"

complex_judgment: frege_judgment(forall_x, "Universal statement")

frege_negation

Function

frege_negation(content)
Creates Frege's negation stroke - a vertical line under the content stroke representing denial. This is Frege's spatial representation of logical negation.

Examples

not_p: frege_negation(p)  # ¬P

print(frege_format(not_p))  # Display: —|— "P"

double_neg: frege_negation(frege_negation(p))  # ¬¬P

frege_quantification

Function

frege_quantification(variable, quantifier, scope, content)
Creates Frege's quantification using concavity notation (⌒) - the first formal treatment of universal and existential quantification in logic history. The concavity appears in the content stroke with the variable placed within.

Examples

forall_x: frege_quantification("x", "universal", "object", px)  # ∀x P(x)

exists_y: frege_quantification("y", "existential", "object", qy)  # ∃y Q(y)

print(frege_format(forall_x))  # Display: —⌒— "P(x)" with x below

frege_to_modern

Function

frege_to_modern(frege_object)
Converts Begriffsschrift notation to modern symbolic logic, providing educational mappings showing how each Frege element corresponds to contemporary notation. Returns conversion result with success status and explanatory mappings.

Examples

modern: frege_to_modern(conditional)  # Convert P→Q to modern notation

if modern.Success then print(modern.Converted)  # Show modern form

print(modern.Mappings)  # Educational correspondence explanations

frequencies

Function

tallyBuiltinFn counts occurrences of each element, returning a Dictionary of element → count (Ruby's tally / Clojure's frequencies). Keys stringify like group_by: a String element keys by its raw .Value, anything else by Inspect(). Call diagnostics (different branches may describe different overloads): • tally requires exactly 1 argument: a collection Extracted library reference: evaluator/builtins.go:22715. These notes are not a complete signature or a stability guarantee. Manual §12.17 Enumerable verbs; read with manual "12.17" Excerpt: `sort_by` shares `sort`'s numeric-aware ordering, so integer keys sort by value. `tally`/`frequencies` return a dictionary (a string is counted character by character). Ruby's first-match is `find`/`detect`; `find` is a reserved solver keyword here, so the collection verb is `detect`. `tap` runs its function for a side effect and returns the value unchanged — handy for peeking inside a `|>`

from

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §13.29 Enum subrange — `Sub extends Enum in From..To` (Pascal/Ada); read with manual "13.29" Excerpt: ### Enum subrange — `Sub extends Enum in From..To` (Pascal/Ada) `Workday extends Day in Mon..Fri` declares a subtype of an existing enum restricted to a contiguous slice. Every Workday IS a Day (widening is

from_base

Function

Call diagnostics (different branches may describe different overloads): • from_base requires exactly 2 arguments: a string and a base (2..36) Extracted library reference: evaluator/builtins.go:4354. These notes are not a complete signature or a stability guarantee.

from_data

Function

from_data(value) → an AST literal for the value (the value→code direction of the bridge; the same lifting `to_ast` performs, named for the pair). `to_data(from_data(v)) == v` for data values. Call diagnostics (different branches may describe different overloads): • from_data requires exactly 1 argument (a value) Extracted library reference: evaluator/builtin_ast_algebra.go:55. These notes are not a complete signature or a stability guarantee. Manual §19.10.6 The code ↔ data bridge — `to_data` / `from_data`; read with manual "19.10.6" Excerpt: #### The code ↔ data bridge — `to_data` / `from_data` Two converters cross the line between a quoted AST and an ordinary value:

from_json

Function

Extracted library reference: evaluator/builtins.go:14636. These notes are not a complete signature or a stability guarantee. Manual §5.14 Matrices, tensors & dataframes; read with manual "5.14" Excerpt: **JSON** is the value↔string pair `to_json(v [, pretty])` / `from_json(s)` (2026-08-27) — pure functions, so they work in the browser build, and the file genre composes from shipped parts: `from_json(read(%data.json))` and `write(path, to_json(v, true))`.

from_option

Function

fromOptionBuiltin: Some(v) → v; Absent → none; else error. Call diagnostics (different branches may describe different overloads): • from_option requires exactly 1 argument (an Option) Extracted library reference: evaluator/builtins.go:2443. These notes are not a complete signature or a stability guarantee. Manual §33.14.1 Bridges — `to_option` / `from_option` / `to_result` / `from_result` / `unwrap_or`; read with manual "33.14.1" Excerpt: #### Bridges — `to_option` / `from_option` / `to_result` / `from_result` / `unwrap_or` Never auto-promote bottoms into ADTs:

from_result

Function

fromResultBuiltin: Ok(v) → v; Err(e) → e; else error. Both arms unwrap; callers that want a default on Err should use unwrap_or. Call diagnostics (different branches may describe different overloads): • from_result requires exactly 1 argument (a Result) Extracted library reference: evaluator/builtins.go:2477. These notes are not a complete signature or a stability guarantee. Manual §33.14.1 Bridges — `to_option` / `from_option` / `to_result` / `from_result` / `unwrap_or`; read with manual "33.14.1" Excerpt: #### Bridges — `to_option` / `from_option` / `to_result` / `from_result` / `unwrap_or` Never auto-promote bottoms into ADTs:

fu

Keyword

Lojban-inspired x5 argument-position tag (method or means). Used inside tagged relational forms.

fullform

Function

fullform(expression)
Returns the AST of an expression as a Mathematica-style string. Hold semantics — the argument is inspected unevaluated. Sibling: treeform, tableform, graphform.

Examples

fullform(2 + 3)            # → "+(2, 3)"

fullform([1, 2, 3])        # array literal AST

fullform(if x then y else z)

h: hold(2 + 3); fullform(h)  # unwraps held AST → "+(2, 3)"

fun

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §12.1 Function definitions; read with manual "12.1" Excerpt: multiply: func(a, b, c) [a * b * c] # canonical REBOL bind fn half(x) [x / 2] # `fn`, `fun`, and `function` alias `func` fun thrice(x) [x * 3] function scale(x) [x * 10] func double(x) [x * 2] # named declaration (optional keyword form)

func

Keyword

func [name](params) [body]  OR  name: func(params) [body]  OR  name(params) = expr
Declares a named function or creates an anonymous function block. Generic contracts use func[T](x :: T) :: T [x], named f[T](...), or a detached f[T] :: T -> T signature. Bounds use T of Number; repeated direct variables share one runtime type per call. See doc("generics"). Evaluator-only for generics. Functions support local block scope, parameters with types, default values, pattern-matching destructuring, and closures. The keyword-free EQUATION form `name(params) = expr` is sugar for the same declaration (patterned/guarded equations accumulate as clauses, like clausal func); its right-hand side is an ordinary value expression.

Examples

func double(x) [ x * 2 ]       # Named declaration

double: func(x) [ x * 2 ]      # Anonymous assignment form

double(x) = 2 * x              # Equation form (textbook/Julia style)

fact(0) = 1                    # Patterned equations accumulate as clauses

fact(n) = n * fact(n - 1)

function

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §6.8 End-form blocks — `if`, `while`, `for`, `loop`, `repeat`, `function`, `module` … `end`; read with manual "6.8" Excerpt: ### End-form blocks — `if`, `while`, `for`, `loop`, `repeat`, `function`, `module` … `end` A second, keyword-terminated spelling of control-flow, function, and in-file module bodies (2026-08-27; `module` 2026-08-29; `loop`/`repeat` 2026-08-30). The

function?

Function

Call diagnostics (different branches may describe different overloads): • function? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

functions

Function

functions() | functions(Integer) | functions("Integer")
The builtin functions that operate on (or construct) a type — Julia's methodswith view, curated and verified per entry. Covers exactly the card-bearing types (the doc-card set); the no-arg form lists them. Functions only — operators (+, band, union, …) stay documented on the type card. The String-argument spelling works under --vm.

Examples

functions(Integer)         # every Integer-relevant builtin, sorted

functions("String")        # same catalog by name

"divmod" in set(functions(Integer))   # → true

functions()                # the cataloged type names

fuzzy_and

Function

Call diagnostics (different branches may describe different overloads): • arguments must be numbers • fuzzy_and requires 2 arguments Extracted library reference: evaluator/builtins.go:13074. These notes are not a complete signature or a stability guarantee.

fuzzy_category_membership

Function

Return as Łukasiewicz fuzzy value (could integrate with Axioma's MVL system) fuzzy_category_membership(space, point) - Get fuzzy membership for all prototypes Extracted library reference: evaluator/builtin_conceptual_bridges.go:168. These notes are not a complete signature or a stability guarantee.

fuzzy_from_prototype

Function

============================================================================ FUZZY LOGIC BRIDGES ============================================================================ fuzzy_from_prototype(space, point, prototype_name) - Create fuzzy membership function Returns a fuzzy membership value [0, 1] based on distance to prototype Extracted library reference: evaluator/builtin_conceptual_bridges.go:137. These notes are not a complete signature or a stability guarantee.

fuzzy_not

Function

Call diagnostics (different branches may describe different overloads): • argument must be a number • fuzzy_not requires 1 argument Extracted library reference: evaluator/builtins.go:13142. These notes are not a complete signature or a stability guarantee.

fuzzy_or

Function

Call diagnostics (different branches may describe different overloads): • arguments must be numbers • fuzzy_or requires 2 arguments Extracted library reference: evaluator/builtins.go:13108. These notes are not a complete signature or a stability guarantee.

fuzzy_set

Function

============================================================================ Fuzzy Logic Functions ============================================================================ Call diagnostics (different branches may describe different overloads): • fuzzy_set name must be a string • fuzzy_set requires at least 1 argument: name Extracted library reference: evaluator/builtins.go:12858. These notes are not a complete signature or a stability guarantee. Manual §11.1 Fuzzy logic; read with manual "11.1" Excerpt: ```axioma tall: fuzzy_set("tall", lambda h => sigmoid(h - 180)) membership(tall, 175) # 0.38 membership(tall, 190) # 0.88 ```

g3_and

Function

g3BinaryBuiltin wraps a two-argument G3 connective (∧, ∨, →) as a builtin. Call diagnostics (different branches may describe different overloads): • g3_and requires exactly 2 arguments Extracted library reference: evaluator/mvl_godel_g3.go:306. These notes are not a complete signature or a stability guarantee. Manual §9.5 Gödel G3 (intuitionistic three-valued); read with manual "9.5" Excerpt: The `g3_*` helpers (`g3_and` / `g3_or` / `g3_not` / `g3_implies` / `g3_lem` / `g3_dne`) return **typed Intuit3 values**, so their results flow straight back into `and` / `not` / `designated`. (`==` on G3 values used to return the biconditional itself — a truthy `?ⁱ` for `unknown == true`; it is now

g3_dne

Function

=== Builtin backends (standard table — evaluator/builtins.go) === All stateless, so they live in the standard builtin table and work under --vm for free. Since July 2026 they return TYPED *types.Intuit3 values (they returned bare Strings before — a fossil from before the Intuit3 type existed, which made their results dead ends: a String can't flow into `and`/`not`/`designated`). Inputs stay permissive (parseG3Value: Intuit3, Boolean, Om, Kleene, String spellings, Belnap-with-collapse) because these double as coercion surfaces, like the other MVL constructors. g3UnaryBuiltin wraps a one-argument G3 schema (¬, LEM, DNE) as a builtin. Call diagnostics (different branches may describe different overloads): • g3_dne requires exactly 1 argument (a G3-convertible value) Extracted library reference: evaluator/mvl_godel_g3.go:292. These notes are not a complete signature or a stability guarantee. Manual §9.5 Gödel G3 (intuitionistic three-valued); read with manual "9.5" Excerpt: The `g3_*` helpers (`g3_and` / `g3_or` / `g3_not` / `g3_implies` / `g3_lem` / `g3_dne`) return **typed Intuit3 values**, so their results flow straight back into `and` / `not` / `designated`. (`==` on G3 values used to return the biconditional itself — a truthy `?ⁱ` for `unknown == true`; it is now Boolean equality, and the biconditional lives at `iff`.)

g3_false

Symbol

=== ⊥ⁱ (Glyph) === name: g3_false latex: gfalse category: mvl codepoint: U+22A5 meaning: ⊥ⁱ — Gödel G3 false (≡ intuit3("false"))

g3_implies

Function

g3BinaryBuiltin wraps a two-argument G3 connective (∧, ∨, →) as a builtin. Call diagnostics (different branches may describe different overloads): • g3_implies requires exactly 2 arguments Extracted library reference: evaluator/mvl_godel_g3.go:306. These notes are not a complete signature or a stability guarantee. Manual §9.5 Gödel G3 (intuitionistic three-valued); read with manual "9.5" Excerpt: The `g3_*` helpers (`g3_and` / `g3_or` / `g3_not` / `g3_implies` / `g3_lem` / `g3_dne`) return **typed Intuit3 values**, so their results flow straight back into `and` / `not` / `designated`. (`==` on G3 values used to return the biconditional itself — a truthy `?ⁱ` for `unknown == true`; it is now

g3_lem

Function

=== Builtin backends (standard table — evaluator/builtins.go) === All stateless, so they live in the standard builtin table and work under --vm for free. Since July 2026 they return TYPED *types.Intuit3 values (they returned bare Strings before — a fossil from before the Intuit3 type existed, which made their results dead ends: a String can't flow into `and`/`not`/`designated`). Inputs stay permissive (parseG3Value: Intuit3, Boolean, Om, Kleene, String spellings, Belnap-with-collapse) because these double as coercion surfaces, like the other MVL constructors. g3UnaryBuiltin wraps a one-argument G3 schema (¬, LEM, DNE) as a builtin. Call diagnostics (different branches may describe different overloads): • g3_lem requires exactly 1 argument (a G3-convertible value) Extracted library reference: evaluator/mvl_godel_g3.go:292. These notes are not a complete signature or a stability guarantee. Manual §9.5 Gödel G3 (intuitionistic three-valued); read with manual "9.5" Excerpt: The `g3_*` helpers (`g3_and` / `g3_or` / `g3_not` / `g3_implies` / `g3_lem` / `g3_dne`) return **typed Intuit3 values**, so their results flow straight back into `and` / `not` / `designated`. (`==` on G3 values used to return the biconditional itself — a truthy `?ⁱ` for `unknown == true`; it is now

g3_not

Function

=== Builtin backends (standard table — evaluator/builtins.go) === All stateless, so they live in the standard builtin table and work under --vm for free. Since July 2026 they return TYPED *types.Intuit3 values (they returned bare Strings before — a fossil from before the Intuit3 type existed, which made their results dead ends: a String can't flow into `and`/`not`/`designated`). Inputs stay permissive (parseG3Value: Intuit3, Boolean, Om, Kleene, String spellings, Belnap-with-collapse) because these double as coercion surfaces, like the other MVL constructors. g3UnaryBuiltin wraps a one-argument G3 schema (¬, LEM, DNE) as a builtin. Call diagnostics (different branches may describe different overloads): • g3_not requires exactly 1 argument (a G3-convertible value) Extracted library reference: evaluator/mvl_godel_g3.go:292. These notes are not a complete signature or a stability guarantee. Manual §9.5 Gödel G3 (intuitionistic three-valued); read with manual "9.5" Excerpt: The `g3_*` helpers (`g3_and` / `g3_or` / `g3_not` / `g3_implies` / `g3_lem` / `g3_dne`) return **typed Intuit3 values**, so their results flow straight back into `and` / `not` / `designated`. (`==` on G3 values used to return the biconditional itself — a truthy `?ⁱ` for `unknown == true`; it is now

g3_or

Function

g3BinaryBuiltin wraps a two-argument G3 connective (∧, ∨, →) as a builtin. Call diagnostics (different branches may describe different overloads): • g3_or requires exactly 2 arguments Extracted library reference: evaluator/mvl_godel_g3.go:306. These notes are not a complete signature or a stability guarantee. Manual §9.5 Gödel G3 (intuitionistic three-valued); read with manual "9.5" Excerpt: The `g3_*` helpers (`g3_and` / `g3_or` / `g3_not` / `g3_implies` / `g3_lem` / `g3_dne`) return **typed Intuit3 values**, so their results flow straight back into `and` / `not` / `designated`. (`==` on G3 values used to return the biconditional itself — a truthy `?ⁱ` for `unknown == true`; it is now

g3_true

Symbol

=== ⊤ⁱ (Glyph) === name: g3_true latex: gtrue category: mvl codepoint: U+22A4 meaning: ⊤ⁱ — Gödel G3 true (≡ intuit3("true"))

g3_unknown

Symbol

=== ?ⁱ (Glyph) === name: g3_unknown latex: gunknown category: mvl codepoint: U+003F meaning: ?ⁱ — Gödel G3 unknown (≡ intuit3("unknown"); ¬?ⁱ = ⊥ⁱ — the intuitionistic collapse)

game

Function

Call diagnostics (different branches may describe different overloads): • game name must be a string • game requires at least 3 arguments: name, players, payoff_matrix • players must be an array • third argument must be a payoff matrix Extracted library reference: evaluator/builtins.go:13325. These notes are not a complete signature or a stability guarantee. Manual §22.4 Randomness — `random` / `random_seed` / `shuffle` / `sample`; read with manual "22.4" Excerpt: *Programming in Lua* (≤5.3) model; modern Lua 5.4+ auto-seeds at startup instead — a deliberate divergence. When you *want* fresh randomness (a game, a real simulation), call `random_seed()` once at the top: it seeds from OS entropy and returns the seed it chose, so even a "fresh" run can be logged and replayed exactly. One seedable source backs the scalar family **and**

gap

Symbol

=== ?ᵇ (Glyph) === name: belnap_neither latex: belneither, gap category: mvl codepoint: U+003F meaning: ?ᵇ — Belnap B4 neither (the gap; ≡ belnap("neither"))

gcd

Function

gcd(a, b)
Greatest common divisor (big-aware). Manual §4.1.1 Integers don't overflow; read with manual "4.1.1" Excerpt: builtins (`succ`/`pred`, `sum`, `abs`, `divmod`/`quotient`/`remainder`, `floor`/`ceil`/`round`/`trunc`/`int`, `gcd`/`lcm`, `factorial`, …). Consequences of the design:

ge

Symbol

=== ≥ (Glyph) === name: greater_equal latex: geq, ge, geqslant variants: ⩾ category: logic codepoint: U+2265 meaning: a ≥ b — greater than or equal (canonicalizes to >=)

gen_drop

Function

`gen_drop(n, gen)` advances the generator past n elements and returns it (the same generator, mutated). Named `gen_drop` to avoid collision with the stack-operation `drop` builtin. Call diagnostics (different branches may describe different overloads): • gen_drop requires 2 arguments: n, generator Extracted library reference: evaluator/builtins.go:7220. These notes are not a complete signature or a stability guarantee. Manual §7.12 Lazy generator expressions; read with manual "7.12" Excerpt: | `gen_take(n, gen)` | Pull first `n` elements — the explicit, lower-level alias of `first(gen, n)`. | | `gen_drop(n, gen)` | Advance past `n` elements (mutates gen in place, returns it). | | `gen_next(gen)` | Pull one element. Returns `Ω` when exhausted. | Prefer **`first(gen, n)`** — it's the same "first n" verb you already use for

gen_next

Function

`gen_next(gen)` pulls one element. Returns the element on success, or Ω (om) when the generator is exhausted. Useful for explicit step-by-step consumption in scripts. Call diagnostics (different branches may describe different overloads): • gen_next requires 1 argument: generator Extracted library reference: evaluator/builtins.go:7246. These notes are not a complete signature or a stability guarantee. Manual §7.12 Lazy generator expressions; read with manual "7.12" Excerpt: | `gen_drop(n, gen)` | Advance past `n` elements (mutates gen in place, returns it). | | `gen_next(gen)` | Pull one element. Returns `Ω` when exhausted. | Prefer **`first(gen, n)`** — it's the same "first n" verb you already use for arrays and infinite sets. The `gen_*` prefix exists only because `take` is a

gen_take

Function

gen_take(n, stream)
Pulls up to n elements from a lazy stream generator.

Examples

squares: (x * x | x <- [1..10])

gen_take(3, squares)  # [1, 4, 9]

generalize

Keyword

Generalize a conceptual-graph concept to another concept using the graph operation's to clause. See doc "conceptual_graph".

generate

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §13.37 Hidden slots, scanners, turtles, and concatenative extras; read with manual "13.37" Excerpt: `each(xs)` wraps any iterable. `yield` is legal in `generate` or `produce`. A `yield` from a function called by `produce` is an error; `generate` still allows it. `force` on a `Generator` stops at 1_000_000 elements (same cap as `Stream`).

generics

Language

func[T](x :: T) :: T [x]; name[T] :: T -> T
Relational function contracts: each call chooses a runtime type for each declared parameter. Repeated direct T inputs and the return :: T share that choice, with no numeric promotion. Bounds use T of Number. Partial applications retain choices. Named declarations, equations and func/fn/fun/function aliases support binders; detached generic signatures cover lambdas, guards and pipe groups. Generic clauses require one fixed arity. Direct T = Array checks its outer kind; explicit Array of T and tuple products check element/component relationships and can nest. Empty Arrays supply no element evidence. Bounds apply to leaves. Generic callbacks remain deferred. Unbounded generic bodies receive rigid HM checking in the supported pure fragment; bounded/default/refined bodies remain runtime checked. Evaluator-only; VM refuses. Generic calls use ordinary recursion to preserve return checks.

Examples

keep: func[T](x :: T, y :: T) :: T [x]
keep(1, 2)

echo[T] :: T -> T
echo: x => x
echo(7)

gensym

Function

gensym() or gensym(prefix)
Generates a unique hygienic symbol string. Prevents variable name collisions in macros.

Examples

gensym()        # "G__0"

gensym("var")  # "var__1"

geq

Symbol

=== ≥ (Glyph) === name: greater_equal latex: geq, ge, geqslant variants: ⩾ category: logic codepoint: U+2265 meaning: a ≥ b — greater than or equal (canonicalizes to >=)

geqslant

Symbol

=== ≥ (Glyph) === name: greater_equal latex: geq, ge, geqslant variants: ⩾ category: logic codepoint: U+2265 meaning: a ≥ b — greater than or equal (canonicalizes to >=)

get

Function

`get(hash, key [, default])` — the value at key, or default (null when omitted) if the key is absent. Python's dict.get. Miss stays none (falsy). For Option shape use get_option (no default arg — absence is None; a stored none is Some(none)). Call diagnostics (different branches may describe different overloads): • get requires 2 or 3 arguments: hash, key [, default] Extracted library reference: evaluator/builtins.go:6998. These notes are not a complete signature or a stability guarantee. Manual §33.17 Tool registry and Act guardrails; read with manual "33.17" Excerpt: | `detect(pred, coll)` | `detect_option(pred, coll)` | | `get(hash, key [, default])` | `get_option(hash, key)` — no default arg | | `index_of(coll, target [, init])` | `index_of_option(...)` | | `span_of(s, sub [, init])` | `span_of_option(...)` |

get_beliefs

Function

get_beliefs(theory) - Get all beliefs in extensions Example: get_beliefs(dt) → array of beliefs Call diagnostics (different branches may describe different overloads): • argument must be a default theory • get_beliefs requires 1 argument: theory Extracted library reference: evaluator/builtins.go:19702. These notes are not a complete signature or a stability guarantee.

get_concepts

Function

get_concepts(kb, individual) - Get all concepts an individual belongs to Example: get_concepts(kb, "john") → ["Undergrad", "Student", "Person"] Call diagnostics (different branches may describe different overloads): • first argument must be a DL knowledge base • get_concepts requires 2 arguments: kb, individual • individual name must be a string Extracted library reference: evaluator/builtins.go:18849. These notes are not a complete signature or a stability guarantee.

get_dl_instances

Function

get_dl_instances(kb, concept) - Get all instances of a concept Example: get_dl_instances(kb, "Person") → ["john", "mary"] Call diagnostics (different branches may describe different overloads): • first argument must be a DL knowledge base • get_dl_instances requires 2 arguments: kb, concept • second argument must be a string (concept name) Extracted library reference: evaluator/builtins.go:18549. These notes are not a complete signature or a stability guarantee.

get_non_denoting

Function

get_non_denoting(model) - Get all non-denoting terms Example: get_non_denoting(flm) → ["the_king", "golden_mountain"] Call diagnostics (different branches may describe different overloads): • argument must be a free logic model • get_non_denoting requires 1 argument: model Extracted library reference: evaluator/builtins.go:19484. These notes are not a complete signature or a stability guarantee.

get_option

Function

getOptionBuiltin(hash, key) — Some(value) if key is present (even when the stored value is none), Absent if the key is absent. Unlike get, there is no default argument: absence is Absent. Call diagnostics (different branches may describe different overloads): • get_option requires exactly 2 arguments: hash, key Extracted library reference: evaluator/builtin_option_helpers.go:199. These notes are not a complete signature or a stability guarantee. Manual §33.17 Tool registry and Act guardrails; read with manual "33.17" Excerpt: | `detect(pred, coll)` | `detect_option(pred, coll)` | | `get(hash, key [, default])` | `get_option(hash, key)` — no default arg | | `index_of(coll, target [, init])` | `index_of_option(...)` | | `span_of(s, sub [, init])` | `span_of_option(...)` |

get_role_fillers

Function

get_role_fillers(kb, role_name, individual) - Get all b such that R(a,b) Example: get_role_fillers(kb, "hasAdvisor", "john") → ["bob", "alice"] Call diagnostics (different branches may describe different overloads): • first argument must be a DL knowledge base • get_role_fillers requires 3 arguments: kb, role, individual • role and individual names must be strings Extracted library reference: evaluator/builtins.go:18791. These notes are not a complete signature or a stability guarantee.

get_superclasses

Function

Call diagnostics (different branches may describe different overloads): • argument to get_superclasses must be a concept • get_superclasses requires exactly 1 argument: concept Extracted library reference: evaluator/builtins.go:5879. These notes are not a complete signature or a stability guarantee.

get_word?

Function

Call diagnostics (different branches may describe different overloads): • get_word? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

getalias

Function

Call diagnostics (different branches may describe different overloads): • getalias() argument must be a string • getalias() takes exactly 1 argument Extracted library reference: evaluator/builtins.go:16658. These notes are not a complete signature or a stability guarantee.

gfalse

Symbol

=== ⊥ⁱ (Glyph) === name: g3_false latex: gfalse category: mvl codepoint: U+22A5 meaning: ⊥ⁱ — Gödel G3 false (≡ intuit3("false"))

given

Keyword

given NAME = value   (RETIRED August 2026)
RETIRED — `given` duplicated `const` exactly and errors with a migration hint: write `let NAME = value` for an immutable binding, or `const NAME = value` for a top-level named constant. The word's one living meaning is the premise line inside a [solver| ...] block (`find d ... given a = 3 ... condition ...`), which is unchanged.

Examples

given G = 5      # ERROR: `given` was retired

let G = 5        # immutable binding (the migration)

const G = 5      # top-level named constant (the migration)

global

Keyword

global NAME = value   |   global NAME   then NAME = value
Julia's module-scope write. Writes THIS FILE or this nested `module` body, skipping enclosing function locals, and may declare. `global x` then `x = …` in the same function writes that cell. Honors the module cell's `::` (and `global x :: T = v`). Not an alias of `rebind`. RESERVED: guard as `$global`. Word lists take it bare (`[global x]`).

Examples

total = 0
function addall(t)
  for x in t
    global total = total + x
  end
  total
end

global ratio :: Float = 3   # converts; the cell is Float

glut

Symbol

=== ⊤⊥ᵇ (Glyph) === name: belnap_both latex: belboth, glut category: mvl codepoint: U+22A4 meaning: ⊤⊥ᵇ — Belnap B4 both (the glut; ≡ belnap("both"))

glyph

Function

glyph(name)
Fetch a single glyph by name from the symbols() catalog. Accepts an Axioma operator name ("union"), a LaTeX name ("cup", "oplus"), a Greek letter ("alpha", "capital sigma"), a starter emoji name ("brain"), or a codepoint ("U+222A"). Returns a Glyph value that prints as the character and compares == to a matching String. An unknown name errors with a hint pointing at symbols(). `char` is an alias.

Examples

glyph("union")       # Returns ∪

glyph("cup")         # Returns ∪ (LaTeX alias)

glyph("therefore")   # Returns ∴

glyph("U+222A")      # Returns ∪ (by codepoint)

glyph("alpha")       # Returns α (Greek letters included)

godel?

Function

Registered alias of is_godel. Call diagnostics (different branches may describe different overloads): • is_godel requires exactly 1 argument Extracted library reference: evaluator/builtins.go:6534. These notes are not a complete signature or a stability guarantee.

godel_decode

Function

Call diagnostics (different branches may describe different overloads): • godel_decode requires a Gödel number (from godel_encode) • godel_decode requires exactly 1 argument (Gödel number) Extracted library reference: evaluator/builtins.go:6518. These notes are not a complete signature or a stability guarantee.

godel_encode

Function

godel_encode(source_string)
Gödel numbering: encodes an Axioma expression's SYNTAX as a single (big) integer — statements→numbers, the 1931 return of Leibniz's arithmetization program (concepts→numbers, see leibniz_encode). Round-trip with godel_decode; test with is_godel; digits via godel_value. Composite sub-expressions use bounded exponents (the package trades strict injectivity for computability).

Examples

g: godel_encode("2 + 3")

godel_decode(g)   # "2 + 3"

is_godel(g)       # true

godel_value

Function

Call diagnostics (different branches may describe different overloads): • godel_value requires a Gödel number • godel_value requires exactly 1 argument (Gödel number) Extracted library reference: evaluator/builtins.go:6544. These notes are not a complete signature or a stability guarantee.

graph

AI Function

graph(node1, node2, node3, ...)
Creates an undirected graph with specified nodes. Use add_edge() to connect nodes.

Examples

graph("A", "B", "C", "D")

graph(1, 2, 3, 4, 5)

graphform

Function

graphform(relation[, format])
Renders a relation as a graph (binary relations → directed edges). Five output formats: "ascii" (default) — adjacency list with → arrows; "dot" — Graphviz DOT (paste into `dot -Tsvg` or online viewer); "cg" — Sowa Conceptual Graph linear notation `[a]→(rel)→[b]`; "png" — bridges to the visualization renderer and writes a PNG file; "svg" — same as PNG but emits scalable vector graphics (better for VS Code/web/archival). PNG and SVG files go to `<cwd>/visualizations/graph_<timestamp>.{png,svg}` with nanosecond timestamps to avoid collisions. Sibling: fullform, treeform, tableform.

Examples

relation edge(x, y)

assert edge("a", "b")

graphform(edge)              # ASCII adjacency

graphform(edge, "dot")       # Graphviz DOT

graphform(edge, "cg")        # Sowa CG: [a]→(edge)→[b]

graphform(edge, "png")       # writes PNG, returns path

graphform(edge, "svg")       # writes SVG (scalable)

greater

Function

greater(x, y)
Multi-argument predicate that checks if x > y. Part of the enhanced first-order logic system.

Examples

greater(5, 3)  # Returns true

greater(2, 7)  # Returns false

forall x,y in Numbers: greater(x, y) or greater(y, x) or equal(x, y)

greater_equal

Symbol

=== ≥ (Glyph) === name: greater_equal latex: geq, ge, geqslant variants: ⩾ category: logic codepoint: U+2265 meaning: a ≥ b — greater than or equal (canonicalizes to >=)

grounding

Function

grounding(relation, args...)
Returns a fact's epistemic grounding — HOW WELL it is known, on the ordered ladder axiom > postulate > theorem > conjecture > hypothesis > datum (plus "canceled" and "unknown"). You choose the base rung when asserting (axiom / postulate / assert→datum); derivation assigns the rest: strict rules (<==) over axioms yield theorems, defeasible rules (<~~) yield conjectures, and grounding propagates as the MINIMUM of the rule body's groundings. The ladder is load-bearing: cancel() refuses to defeat a theorem, and `why` / proof() trace any derived fact back to its base posits. One of the unit's orthogonal axes — see epistem.

Examples

axiom parent("john", "mary")

grounding("parent", "john", "mary")     # "axiom"

grandparent(X, Z) <== parent(X, Y) and parent(Y, Z)

grounding("grandparent", "john", "ann")  # "theorem"

group_by

Function

group_by(fn, collection)
Bucket elements into a hash keyed by fn(element). Manual §7.14 Aggregation: `group_by`, `items`, `keys`, `values`; read with manual "7.14" Excerpt: ### Aggregation: `group_by`, `items`, `keys`, `values` Four builtins fill the SQL-style aggregation gap. `group_by(fn, coll)` partitions a collection into a hash; `items(hash)` exposes it as `(key, value)` pairs; `keys`/`values` return the parts individually. All three enumerators walk the hash in **sorted key order** — the same canonical order `println(h)` shows — so repeated calls (and `keys`/`values`/`items` against each other) always agree.

groupby

Function

groupby(relation, key_indices, agg_func) - Group by with aggregation Groups tuples by specified key columns and applies aggregation function Example: groupby(sales, [0], "sum", 1) → sum of sales by product Call diagnostics (different branches may describe different overloads): • groupby requires 2-4 arguments: groupby(relation, key_indices, [agg_func], [value_index]) • groupby: avg requires value_index argument • groupby: max requires value_index argument • groupby: min requires value_index argument • groupby: sum requires value_index argument Extracted library reference: evaluator/builtins.go:8379. These notes are not a complete signature or a stability guarantee.

gtrue

Symbol

=== ⊤ⁱ (Glyph) === name: g3_true latex: gtrue category: mvl codepoint: U+22A4 meaning: ⊤ⁱ — Gödel G3 true (≡ intuit3("true"))

gunknown

Symbol

=== ?ⁱ (Glyph) === name: g3_unknown latex: gunknown category: mvl codepoint: U+003F meaning: ?ⁱ — Gödel G3 unknown (≡ intuit3("unknown"); ¬?ⁱ = ⊥ⁱ — the intuitionistic collapse)

gödelValue

Function

Call diagnostics (different branches may describe different overloads): • gödelValue requires a Gödel number • gödelValue requires exactly 1 argument Extracted library reference: evaluator/builtins.go:6478. These notes are not a complete signature or a stability guarantee.

had

Keyword

ConceptName had propertyName
Removes a property from a concept

Examples

Person had tempProperty

Stock had oldField

has

Keyword

ConceptName has property[:: Type][: value][, property[:: Type][: value], …]
Adds one or more properties to a concept. Several properties may be declared in one statement, separated by commas; the list may continue on the next line after a comma, and each value is an ordinary expression. A property may carry a type — `has revenue :: Float` starts as none, `has expenses :: Float: 2` stores 2.0 — that every later write must satisfy: the instance block at creation, dot assignment, a record update and a later default; an Integer converts for a Float property. `had` removes one.

Examples

Person has name

Stock has price

Stock has price: 150, ticker: "AAPL"

Economy has revenue :: Float, expenses :: Float: 2

Vehicle has speed

has_key

Function

`has_key(hash, key)` — true when the hash contains the string key. Companion to keys/values; covers Python's `k in d` membership test (axioma's `in` is reserved for sets/bags). Call diagnostics (different branches may describe different overloads): • has_key requires 2 arguments: hash, key Extracted library reference: evaluator/builtins.go:6973. These notes are not a complete signature or a stability guarantee.

has_meaning

Function

has_meaning(assertion, verifier)
Schlick/Carnap verification binding — registers a Verifier entity as the meaning (verification method) for an assertion string. After binding, diagnose("…") returns verdict "meaningful" with verifier_bound true. Last binding wins for the same assertion. Siblings: meaning(assertion) query, verify(assertion) invoke the verifier body.

Examples

v: verifier("glass_check", func() [intuit3("true")])

has_meaning("glass-1 contains water", v)

diagnose("glass-1 contains water").verdict  # "meaningful"

has_role

Function

has_role(kb, role_name, ind1, ind2) - Check if R(a,b) holds Example: has_role(kb, "hasAdvisor", "john", "bob") → true/false Call diagnostics (different branches may describe different overloads): • all names must be strings • first argument must be a DL knowledge base • has_role requires 4 arguments: kb, role, individual1, individual2 Extracted library reference: evaluator/builtins.go:18823. These notes are not a complete signature or a stability guarantee.

hasalias

Function

Call diagnostics (different branches may describe different overloads): • hasalias() argument must be a string • hasalias() takes exactly 1 argument Extracted library reference: evaluator/builtins.go:16641. These notes are not a complete signature or a stability guarantee.

hash_word?

Function

Call diagnostics (different branches may describe different overloads): • hash_word? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

having

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §28.5.4 Aggregates — `GROUP BY`, `HAVING`, `COUNT/SUM/AVG/MIN/MAX`; read with manual "28.5.4" Excerpt: #### Aggregates — `GROUP BY`, `HAVING`, `COUNT/SUM/AVG/MIN/MAX` ```axioma # Single-column GROUP BY with COUNT

hd

Function

hd(s, [n])
Short spelling of first — an exact alias. Manual §5.4 Lists and recursion — `[h | t]`; read with manual "5.4" Excerpt: *list*: `tl([1,2,3])` is `[2,3]` where `last([1,2,3])` is `3`. And `hd` is partial where `tl` is total: `hd([])` raises, `tl([])` is `[]`, so write the base case as `empty?(xs)` rather than leaning on the tail to fail. - **In a `match` arm, `[h]` is a block, not a one-element array** — it evaluates to `h`. Everywhere else (binding right-hand side, call argument, operand,

head

Function

headBuiltin returns the head of an AST node as a String, uniformly: infix/prefix/postfix -> the operator (1 + 2 -> "+", 5! -> "!") call -> the functor name (add(1,2) -> "add") atoms -> the value's kind (5 -> "Integer", x -> "Symbol") other compound -> the node kind string Total: never errors on a real AST value. Call diagnostics (different branches may describe different overloads): • head requires exactly 1 argument (AST or expression) Extracted library reference: evaluator/builtin_ast_algebra.go:88. These notes are not a complete signature or a stability guarantee. Manual §19.10.3 The `head` / `operands` / `make_expr` normal-form algebra; read with manual "19.10.3" Excerpt: #### The `head` / `operands` / `make_expr` normal-form algebra Mathematica unifies every expression under one shape — `head[args]`. Axioma renders its three surface notations (infix, prefix, postfix) and call syntax to that same normal form, and a small algebra reads and rebuilds any quoted expression **uniformly**, regardless of which syntax produced it.

hex

Function

hex(n)
Hex digit string of an Integer (hex(255) → "ff"). Manual §4.6.6 Design notes; read with manual "4.6.6" Excerpt: - **`Byte` displays as decimal.** `byte(0xFF)` prints as `255` — the Python / Go / Rust convention for byte values. For a hex rendering use `bytes_to_hex(bytes(b))`. (`Bytes` keeps the `b"..."` literal form with `\xff` escapes.) - **Encoding-aware separation**. `Bytes` doesn't carry encoding metadata; conversion to `String` is explicit and fails on invalid input. - **Immutable.** Operations return new `Bytes` rather than mutating in place — composes cleanly with comprehensions, rule derivation, and the VM's bytecode constant pool. - **1-based indexing** matches `Array` / `String` / `Tuple`.

hex_to_bytes

Function

Call diagnostics (different branches may describe different overloads): • hex_to_bytes requires exactly 1 argument (String) Extracted library reference: evaluator/builtin_bytes.go:182. These notes are not a complete signature or a stability guarantee. Manual §4.6.2 Conversions (explicit + fallible); read with manual "4.6.2" Excerpt: | `bytes_to_hex(bs)` | `"ff00ab"` | never | | `hex_to_bytes(s)` | `Bytes` | input has odd length or non-hex chars | | `bytes_to_string(bs, "utf-8")` | `String` | bytes aren't valid UTF-8 | | `string_to_bytes(s, "utf-8")` | `Bytes` | encoding unknown | | `base64_encode(bs)` / `base64_decode(s)` | round-trip | decoder errors on bad input |

hiding

Keyword

import * hiding NAME, ... from "path.ax"
Soft keyword after `import *` or `take *` on the same line. Skips those export names. `hiding: 5` still binds the name.

Examples

import * hiding sqrt, abs from "lib/math.ax"

how

Keyword

how conclusion_expression
Explanation system - explains HOW a conclusion was derived by showing the step-by-step derivation process.

Examples

how grandparent("a", "c")   # Show derivation steps

how risk_level("stock")      # Explain calculation

how treatment("patient")     # Show treatment logic

hybrid_reasoning

Function

============================================================================ MULTI-SYSTEM INTEGRATION ============================================================================ hybrid_reasoning(space, kb, query_point) - Combine geometric + symbolic reasoning Extracted library reference: evaluator/builtin_conceptual_bridges.go:355. These notes are not a complete signature or a stability guarantee.

hypothesis

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §15.1 Declaring knowledge — the six grounding grades; read with manual "15.1" Excerpt: | `conjecture` | *derived* by a **defeasible** rule ([§16](#16-rules-derivation--epistemic-grounding)), or `insert(rel, …, "conjecture")` | plausibly inferred; may be defeated | | `hypothesis` | `hypothesis fact`, or `insert(rel, …, "hypothesis")` | a working assumption | | `datum` | plain `assert fact`, or `insert(rel, …)` with no grade | a bare fact — the floor of the ladder | ```axioma

ident

Function

Call diagnostics (different branches may describe different overloads): • ident name must be a string • ident requires exactly 1 argument Extracted library reference: evaluator/builtins.go:16356. These notes are not a complete signature or a stability guarantee. Manual §6.4.2 Logical negation — `not` / `¬` / `!` (and what `~` is not); read with manual "6.4.2" Excerpt: s !~ pat # digraph regex non-match sort!(xs) # ident immediately followed by `!(` is ONE identifier — # the in-place twin of sort, not factorial of the sort builtin splice!(xs, i) # same glue; unbanged splice is quasiquote, so the array # mutator has to be a different identifier

identical

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §3.14 Typing the glyphs; read with manual "3.14" Excerpt: and comments was previously a syntax error, so the form is collision-free. A digraph is byte-identical to its glyph at the token level, so it works in every construct, in the VM, and in the playground. A digraph is **unpaired** — a *matched* pair of backticks is the unrelated infix-application form of [§19.3](#193-infix-functions-are-operators) (`` 3 `mysum` 4 `` ≡ `mysum(3, 4)`).

identified

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §13.34 Defined instances — `Concept identified by ...`; read with manual "13.34" Excerpt: ### Defined instances — `Concept identified by ...` KM §17.3 — automatic coreference by identity key. Where `defines` auto-*classifies* instances by their slot state, defined instances

identifier?

Function

Call diagnostics (different branches may describe different overloads): • identifier? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1645. These notes are not a complete signature or a stability guarantee.

identity

Function

identity(x)
Returns its argument unchanged — the identity element of composition. Manual §3.3.1 Uninitialized slots and identity defaults; read with manual "3.3.1" Excerpt: #### Uninitialized slots and identity defaults Three different intents people often collapse into one:

idiv

Operator

a idiv b | idiv(a, b)
Floor division — the word alias of `div` / `÷` / `quotient`. Same-line soft infix keyword (PRODUCT, left-associative) synthesizing the identical AST operator `div`, and a prefix builtin `idiv(a, b)` that hands its operands to the same floor operator. Rounds toward −∞ on integers and floats. `idiv: 5` is still an ordinary binding. Not `rdiv` (exact `/`) and not `fdiv` (always Float).

Examples

7 idiv 2           # Returns 3

idiv(7, 2)         # Returns 3

-7 idiv 3          # Returns -3   (floor, toward -inf)

10.0 idiv 3.0      # Returns 3.0

if

Keyword

if condition then consequence [else alternative] | cond ? a : b | expr if condition (postfix modifier) | head(Args) if body (rule clause) | name(args) = expr, if cond
Conditional expression. `cond ? a : b` is the same AST as `if cond then a else b` (ternary; `--vm` included). Also a postfix statement modifier (Perl-style: `cancel(d) if challenged(d)`), and — when the head call's arguments include an uppercase logic variable and the head is a relation or not yet defined — a natural-language spelling of a strict backward rule, equivalent to `head :- body` (callable heads like `push(s, V) if V > 3` keep the conditional meaning). After an unbracketed equation body, `, if cond` is Miranda's guard (≡ `when cond` before `=`; equality is `==`). For rules, `whenever` is the primary spelling — it has no conditional reading, so it needs no gate and ground heads work bare (see `doc whenever`). `if pat = e then` is a one-arm match (see `doc match`). Predicate dispatch without a scrutinee is `cond` (see `doc cond`).

Examples

if x > 5 then "big" else "small"

x > 5 ? "big" : "small"           # ternary, same AST

if age >= 18 then "adult"

cancel(d) if challenged(d)          # postfix conditional

path(X, Y) if edge(X, Y)            # rule clause ≡ path(X, Y) whenever edge(X, Y)

path(X, Y) if edge(X, Z) and path(Z, Y)

whichsign(n) = "Positive", if n > 0  # Miranda equation guard ≡ when

if_expr

Function

Call diagnostics (different branches may describe different overloads): • if_expr requires 2 or 3 arguments (condition, consequence, [alternative]) Extracted library reference: evaluator/builtins.go:16480. These notes are not a complete signature or a stability guarantee.

if_expr?

Function

Call diagnostics (different branches may describe different overloads): • if_expr? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1645. These notes are not a complete signature or a stability guarantee.

iff

Operator

expression1 iff expression2
Logical biconditional equivalence (if and only if) operator. Returns true if both expressions have matching truth values, false otherwise.

Examples

true iff true

x > 5 iff y > 5

im

Value

Built-in COMPLEX value: im Manual §3.9 `global` — Julia's module write; read with manual "3.9" Excerpt: **Builtins vs constants.** The lowercase math names (`pi`, `e`, `tau`, `im`, …) are *shadowable* fallback builtins — `pi: 3` wins locally and leaves the system untouched. The canonical UPPERCASE constants (`PI`, `TAU`, `EULER`, …) are seeded immutable: `PI: 3` reports `Cannot reassign constant 'PI'`

imag

Function

imag(z)
Imaginary part of a Complex number.

image

Function

image(R, A) - Relational image Mathematical: R[A] = {y | ∃x: x ∈ A ∧ (x,y) ∈ R} Returns the set of all second elements paired with elements from A Example: image({(1,"a"), (2,"b"), (1,"c")}, {1}) → {"a", "c"} Call diagnostics (different branches may describe different overloads): • image requires exactly 2 arguments: image(relation, set) Extracted library reference: evaluator/builtins.go:8226. These notes are not a complete signature or a stability guarantee. Manual §3.12 Persistence refinements; read with manual "3.12" Excerpt: Explicit `lazy` closures are also unsupported. A save warning means that named value was not included in the image; `/persist` alone is not a durability proof. This keeps the canonical `:` form refinement-free and concentrates the persistence vocabulary in one place. The same `/persist` / `/transient`

impl

Keyword

impl …
Alternative spelling of implies. See doc("implies") for its meaning and call forms.

implements

Keyword

concept Name implements Interface1, Interface2 [{ ... }]
Declares that a concept implements one or more interfaces (multiple categorization). Combines with extends (`concept C extends Parent implements I`); interface membership is queried with the `is` copula. The block is optional.

Examples

concept Duck implements Flyable, Swimmable { }

concept GameObject implements Drawable, Moveable

concept Bird extends Animal implements Flyable { }

Duck is Flyable              # Interface membership query

implies

Operator

expression1 implies expression2
Logical implication operator

Examples

raining implies wet

x > 5 implies x > 0

implode

Function

implode(chars)
Inverse of explode/chars — Array (or Tuple) of strings concatenated into one String. Empty → "". Manual §22.8 List & string helpers; read with manual "22.8" Excerpt: explode("abc") # → ["a", "b", "c"] (SML spelling; exact alias of chars) implode(["a", "b", "c"]) # → "abc" (inverse of explode/chars) implode(explode("日本語")) # → "日本語" (round-trip over runes) rev([1, 2, 3]) # → [3, 2, 1] (SML List.rev; exact alias of reverse) member([1, 2, 3], 2) # → true (SML-shaped name; exact alias of contains)

import

Keyword

import "path.ax" | import NAME [as ALIAS], ... from "path.ax" | import * [hiding NAME, ...] from "path.ax"
Loads another Axioma file. Selective form binds named exports; `as` renames one; `import * hiding a, b` binds every export except those names. Two items that would bind the same local name error. Path is a string or FILE literal. `./` and `../` resolve against the importing file; bare `foo/bar.ax` searches the working directory. An `export`/`allow` list in the imported file is exclusive. `take` is the same statement. Evaluator-only: `--vm` refuses `import`.

Examples

import "lib/math.ax"

import "lib/math.ax" as Math

import "./sib.ax" as Sib

import sqrt as root, pi from "lib/math.ax"

import * hiding sqrt, abs from "lib/math.ax"

impossibly

Keyword

Modal operator for impossibility in the selected model. Its interpretation depends on that model and accessibility relation; see doc "necessarily" and doc "possibly".

in

Operator

element in collection  |  | name in collection => body
Membership. Infix: `3 in {1, 2, 3}`, `n in 1..9`. Match pattern: `| n in xs => …` binds n and requires the same membership. `| 1..9` is range membership without a bind. A membership error is not a failed match — it propagates.

Examples

3 in {1, 2, 3}

"apple" in fruits

match n with | n in 1..9 => n | _ => none

in_prototype

Function

in_prototype(space, point, prototype_name) - Check membership Extracted library reference: evaluator/builtin_conceptual.go:435. These notes are not a complete signature or a stability guarantee.

include

Keyword

include "path.ax" | include NAME, ... from "path.ax" | include * [hiding NAME, ...] from "path.ax"
Load another file and re-export its surface as this file's. `import` is use-only: names are for this file, not for whoever imports you. `include` flattens AND marks the names exported. Does not take `as` (write `import "p" as M`). File modules only. Evaluator-only: `--vm` refuses.

Examples

include "./Core.ax"

include shown from "./base.ax"

index_of

Function

index_of(collection, target, [init])
1-based position of target at or after init (default 1; negative init counts from the end), or `none` when absent (falsy — composes with `if`/`??`; never the integer 0). Manual §4.5.9 Substring search — `index_of` and `span_of`; read with manual "4.5.9" Excerpt: #### Substring search — `index_of` and `span_of` Two builtins locate a substring, both in **1-based character (rune) coordinates** — the same coordinates `substring`, `s[a..b]` slicing, and

index_of_option

Function

indexOfOptionBuiltin is the Option dual of index_of: Some(pos) on hit, None on miss. Same arguments as index_of; index_of itself still returns none. Extracted library reference: evaluator/builtin_strings.go:147. These notes are not a complete signature or a stability guarantee. Manual §33.17 Tool registry and Act guardrails; read with manual "33.17" Excerpt: | `get(hash, key [, default])` | `get_option(hash, key)` — no default arg | | `index_of(coll, target [, init])` | `index_of_option(...)` | | `span_of(s, sub [, init])` | `span_of_option(...)` | ```axioma

indexed

Accessor

xs.indexed | xs's indexed | xs.enumerated
Read-only sequence accessor returning the Array of (index, element) pairs, 1-based and index-first — the indexed VIEW of Array/Tuple/String(runes)/Set(canonical sorted order)/finite Range (keeps direction). `enumerated` is an exact synonym; the builtin twin is enumerate(xs). Feeds the destructuring loop `for i, e in xs.indexed [...]` and comprehensions `{e | i, e <- xs.indexed, ...}`. An open range (n..) errors — loop it with `for e at i in n..` + break instead.

Examples

[10, 20].indexed          # [(1, 10), (2, 20)]

(3..1).indexed            # [(1, 3), (2, 2), (3, 1)]

for i, f in fruits.indexed [ println(i, f) ]

induction

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §30 The Cognitive Kernel; read with manual "30" Excerpt: After procedural, object-oriented, functional, and logical, Axioma adds a **cognitive** layer whose defining primitive is `understand`. *Computing as the mind does* — the mind, in one word, **models**; the knowledge base *is* that world-model, and to `understand(X)` is to model X into the model of everything. The kernel adds **abduction** — Peirce's third inference mode — so deduction (strict Horn `<==`), induction (defeasible `<~~`), and abduction (`abduce`) all finally have a home. | Builtin | Role | Returns | |---|---|---|

inductive

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §13.4 Concept formation layer (Phase 1); read with manual "13.4" Excerpt: |---|---|---| | `"abstraction"` | pattern extracted from multiple observed cases | conjecture (inductive) | | `"combination"` | concept synthesized from existing concepts | theorem (derivable) | | `"distinction"` | concept split out of a broader one | theorem (derivable from parent) | | `"stipulation"` | concept defined by fiat for a purpose | axiom (definitional) |

inexact?

Function

inexact?(x)
True iff x is an inexact number (Float). Integers and Rationals are exact; non-numbers are neither.

infer

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §13.25 Inferred polymorphic types — `axioma --infer`; read with manual "13.25" Excerpt: ### Inferred polymorphic types — `axioma --infer` Annotations are optional everywhere, so most functions carry no written type. `axioma --infer` reports one anyway, where one honestly exists: every

infer_subsumption

Function

infer_subsumption(space, concept1, concept2, threshold) - Infer subsumption from typicality Extracted library reference: evaluator/builtin_conceptual_bridges.go:287. These notes are not a complete signature or a stability guarantee.

Inference Engine

Concept

Forward-chaining rule-based reasoning system
Axioma includes a sophisticated inference engine that applies logical rules automatically using forward-chaining algorithms.

Examples

# Define relation-store rules

relation edge(x, y)

assert edge("a", "b")

assert edge("b", "c")

rule path(X, Y) :- edge(X, Y)

rule path(X, Y) :- edge(X, Z) and path(Z, Y)



# Trigger inference

deduce                      # Fires all rules to a fixpoint (3 facts here)

{(X, Y) | (X, Y) <- path(X, Y)}   # Materialized transitive closure



# Named rule (operator form)

rule Mortality: mortal(X) <== human(X)

inferred

Function

inferred(fn)
The inferred `::` type of a user function as a FunctionType, or none when the body is outside the HM fragment. Sibling of annotations(fn). Evaluator-only (`--vm` refuses).

Examples

raw(x) = x * 2

inferred(raw)            # → Integer -> Integer

annotations(raw)         # → none

infinite?

Function

Call diagnostics (different branches may describe different overloads): • infinite? requires exactly 1 argument Extracted library reference: evaluator/scheme_extras.go:459. These notes are not a complete signature or a stability guarantee. Manual §22.6.1 Scheme/Lisp-style predicates (`?` suffix); read with manual "22.6.1" Excerpt: nan?(nan) # true is_nan(nan) # true infinite?(inf) # true is_infinite(inf) # true finite?(3.14) # true is_finite(3.14) # true integral?(5.0) # true — the VALUE is whole (5.01/NaN/±Inf → false; the TYPE test is integer?)

infinite_set

Function

infinite_set(name_or_predicate) - Create an infinite set Examples: infinite_set("naturals") → ℕ = {1, 2, 3, ...} infinite_set("integers") → ℤ = {..., -2, -1, 0, 1, 2, ...} infinite_set("primes") → {2, 3, 5, 7, 11, ...} infinite_set("evens") → {0, 2, 4, 6, ...} infinite_set("odds") → {1, 3, 5, 7, ...} infinite_set("fibonacci") → {0, 1, 1, 2, 3, 5, 8, ...} infinite_set(func(n) [ n % 2 == 0 ]) → custom infinite set Call diagnostics (different branches may describe different overloads): • infinite_set requires a string name or function • infinite_set requires exactly 1 argument Extracted library reference: evaluator/builtins.go:17039. These notes are not a complete signature or a stability guarantee. Manual §5.10.1 Ellipsis sets — textbook `{2, 4, ..., 100}` / `{2, 4, 6, ...}`; read with manual "5.10.1" Excerpt: 1,000,000 elements. For an *ordered* infinite sequence use this form or `infinite_set("naturals")` — a bare `naturals` / `ℕ` generator enumerates unordered. **Pulling elements.** `first(s)` is the first term; the ordinals

infinity

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §5.2.1 Classic pitfall — seeding an accumulator with `0`; read with manual "5.2.1" Excerpt: identity of `+` (and `1` of `*`) — the identity of `max` is **negative infinity**, which is why the `0` seed smuggles in an assumption. Three correct forms, most idiomatic first: ```axioma

infinity?

Function

Call diagnostics (different branches may describe different overloads): • infinity? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

infix

Function

Call diagnostics (different branches may describe different overloads): • infix operator must be a string • infix requires exactly 3 arguments (left, operator, right) Extracted library reference: evaluator/builtins.go:16409. These notes are not a complete signature or a stability guarantee. Manual §4.6.3 Bitwise ops — word-form infix (v3) + functional form; read with manual "4.6.3" Excerpt: #### Bitwise ops — word-form infix (v3) + functional form Symbolic bitwise operators (`&` `|` `^` `<<` `>>`) all conflict with existing Axioma syntax (`&` is address-of, `|` is comprehension separator, `^` is `POWER`). Word-form operators sidestep the conflict and match Axioma's pattern of `and` / `or` / `not` / `union` / `intersect`.

infix_expr?

Function

Call diagnostics (different branches may describe different overloads): • infix_expr? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1645. These notes are not a complete signature or a stability guarantee.

inherits

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §4.7.1 Arithmetic on `Money` / `Percent`; read with manual "4.7.1" Excerpt: and left-assoc chaining compounds sequentially (`$200 + 10% + 5%` → `$231`). Compound assignment inherits: `price += 10%`. Multiplication is still the only *other* operator that crosses Percent with numbers or Money — `50% * 25%`, `10% / 2`, and mixed equality (`10% == 0.1`) remain errors.

input

Function

input(prompt_string)
Reads a single line of string input from standard input (stdin) with an optional prompt. EOF answers none (falsy); a blank line answers "" (truthy).

Examples

name: input("Your name? ")

input_number

Function

Extracted library reference: evaluator/builtins.go:14967. These notes are not a complete signature or a stability guarantee. Manual §25.8 Reading a value — `read_integer()` / `read_float()` / `read_string()`; read with manual "25.8" Excerpt: EOF is `none`. A token that is not the requested type is an `Error`. `input_number()` still retries until the *line* is a number. `input_number`, `prompt`, `choice`, `confirm`, and `menu` share the same persistent stdin reader, so sequential calls consume successive lines under

input_password

Function

input_password([prompt])
Read a password from the terminal with input echo disabled. This is an interactive input operation; inspect its help without calling it when no terminal is available.

insert

Function

insert(relation, args..., [grounding])
Asserts a new fact at runtime from computed values (the functional counterpart of the assert keyword). Optional last argument names the grounding tier; defaults to "datum".

Examples

insert("likes", "alice", "bob")

insert("likes", "bob", "carol", "postulate")

insert_at

Function

insert_at(array, value)  |  insert_at(array, position, value)
Inserts into an array in place. Two arguments append (Lua table.insert). Three arguments splice at a 1-based position; position len+1 also appends.

Examples

a: [10, 20, 30]

insert_at(a, 40)     # [10, 20, 30, 40]

insert_at(a, 2, 15)  # [10, 15, 20, 30, 40]

inspect

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §13.35 `inspect` / `see` — identity-passing evaluate-and-display; read with manual "13.35" Excerpt: ### `inspect` / `see` — identity-passing evaluate-and-display A prefix directive that evaluates an expression, prints `<source> = <value>` to stdout, and returns the value unchanged.

instanceof

Function

Call diagnostics (different branches may describe different overloads): • instanceof requires exactly 2 arguments • second argument to instanceof must be a concept Extracted library reference: evaluator/builtins.go:5815. These notes are not a complete signature or a stability guarantee. Manual §13.32 Value constraints — `constrain()`; read with manual "13.32" Excerpt: `lambda v => v >= 0 and v <= 150` when the type check is sugar for an `instanceof` call. Test: [tests/axioma/concepts/test_value_constraints.ax](../../tests/axioma/concepts/test_value_constraints.ax).

int

Function

int(x)
To Integer: truncates a Float exactly at any magnitude; parses a String; Time returns whole seconds toward zero. Manual §4.6 Binary data — `Byte` and `Bytes`; read with manual "4.6" Excerpt: | `b"..."` | Literal — escape-decoded at parse time | | `int(b)` | Widen `Byte → Integer` | #### Operations

integer

Function

integer(x)
To Integer — canonical spelling of `int`. Manual §4.6.4 Integer literal prefixes; read with manual "4.6.4" Excerpt: #### Integer literal prefixes Adding bytes also brought standard hex / binary / octal literals to the language:

integer?

Function

Call diagnostics (different branches may describe different overloads): • integer? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee. Manual §22.6.1 Scheme/Lisp-style predicates (`?` suffix); read with manual "22.6.1" Excerpt: finite?(3.14) # true is_finite(3.14) # true integral?(5.0) # true — the VALUE is whole (5.01/NaN/±Inf → false; the TYPE test is integer?) # equality: eq? / eql? / eqv? are shallow identity (collections by reference); # equal? is deep, type-strict (`===` is the infix spelling)

integers

Value

Built-in SET value: {-100, -99, -98, -97, -96, -95, -94, -93, -92, -91, -90, -89, -88, -87, -86, -85, -84, -83, -82, -81, -80, -79, -78, -77, -76, -75, -74, -73, -72, -71, -70, -69, -68, -67, -66, -65, -64, -63, -62, -61, -60, -59, -58, -57, -56, -55, -54, -53, -52, -51, -50, -49, -48, -47, -46, -45, -44, -43, -42, -41, -40, -39, -38, -37, -36, -35, -34, -33, -32, -31, -30, -29, -28, -27, -26, -25, -24, -23, -22, -21, -20, -19, -18, -17, -16, -15, -14, -13, -12, -11, -10, -9, -8, -7, -6, -5, -4, -3, -2, -1, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, 100} Manual §4.1.1 Integers don't overflow; read with manual "4.1.1" Excerpt: #### Integers don't overflow `Integer` is **arbitrary-precision** (the Python/Mathematica model, not C/Lua's fixed 64-bit wrap-around): when a result outgrows the machine word it promotes

integral?

Function

integral?(x)
True iff the VALUE is a whole number — 5.0 → true, 5.01/NaN/±Inf → false, non-numbers → false (the TYPE test is integer?). Manual §22.6.1 Scheme/Lisp-style predicates (`?` suffix); read with manual "22.6.1" Excerpt: finite?(3.14) # true is_finite(3.14) # true integral?(5.0) # true — the VALUE is whole (5.01/NaN/±Inf → false; the TYPE test is integer?) # equality: eq? / eql? / eqv? are shallow identity (collections by reference); # equal? is deep, type-strict (`===` is the infix spelling)

interactive?

Function

Registered alias of is_interactive.is_interactive() / isatty() — report whether the process's standard input is attached to an interactive terminal (TTY) rather than a pipe or redirect. This exposes to scripts the same primitive the REPL already uses internally for mode routing (cmd/axioma/repl_bootstrap.go: term.IsTerminal). It is a NON-CONSUMING check: unlike the `confirm()`-on-EOF idiom it replaces, it reads no stdin and so never swallows a line of input. Stateless (no environment) → available identically under --vm (shared GetBuiltins table) and in the WASM playground (golang.org/x/term compiles for js/wasm, where it returns false — the correct answer for a browser). Takes no arguments; returns a Boolean. `isatty` is a familiar alias. Call diagnostics (different branches may describe different overloads): • is_interactive takes no arguments Extracted library reference: evaluator/builtin_tty.go:22. These notes are not a complete signature or a stability guarantee.

interpolate

Function

interpolate(space, point1, point2, t) - Linear interpolation Extracted library reference: evaluator/builtin_conceptual.go:541. These notes are not a complete signature or a stability guarantee.

interpolate_path

Function

interpolate_path(space, points, steps) - Multi-point interpolation Extracted library reference: evaluator/builtin_conceptual.go:575. These notes are not a complete signature or a stability guarantee.

interpret_tanru

Function

interpret_tanru(tanru_obj, [context]) - Get best interpretation with optional context Call diagnostics (different branches may describe different overloads): • first argument must be a tanru object • interpret_tanru requires 1-2 arguments (tanru_obj, [context]) • phrase field must be a string Extracted library reference: evaluator/builtins.go:20527. These notes are not a complete signature or a stability guarantee.

intersect

Operator

set1 intersect set2
Set intersection operator

Examples

{1, 2, 3} intersect {2, 3, 4}

primes intersect evens

intersection

Symbol

=== ∩ (Glyph) === name: intersect words: intersect, intersection latex: cap category: set codepoint: U+2229 meaning: A ∩ B — intersection (members in both sets)

intuit3

Function

intuit3("true" | "false" | "unknown") — or the literals ⊤ⁱ ⊥ⁱ ?ⁱ
Gödel G3 truth-value constructor (intuitionistic-leaning three-valued logic). Differs from K3 in two load-bearing ways: implication is REFLEXIVE (?ⁱ implies ?ⁱ → ⊤ⁱ) and negation COLLAPSES unknown to false (not ?ⁱ → ⊥ⁱ), which makes double-negation elimination fail at unknown (the constructive property — see g3_dne / g3_lem, which return typed Intuit3 values). Literals ⊤ⁱ ⊥ⁱ ?ⁱ (digraphs `gtrue `gfalse `gunknown; member Intuit3.unknown; Intuit3.values). == / != are Boolean metalanguage equality; the object-language biconditional is `iff`. Accepts Boolean, om, Kleene, strings, and Belnap (lossy both/neither → unknown collapse — constructor-only; infix operators reject Belnap operands).

Examples

p: ?ⁱ                           # ≡ intuit3("unknown")

p implies p                     # → ⊤ⁱ (reflexive — the intuitionistic signature)

not p                           # → ⊥ⁱ (G3 collapses unknown; K3 keeps it)

p == ⊤ⁱ                         # → false (Boolean equality — NOT the biconditional)

p iff p                         # → ⊤ⁱ (the biconditional's proper home)

g3_dne(?ⁱ)                      # → ?ⁱ — ¬¬P → P is NOT a G3 tautology

designated(g3_lem(?ⁱ))          # → false — LEM fails as an inference

intuitionistic_model

Function

intuitionistic_model() - Create an intuitionistic logic model Uses forcing semantics with partially ordered knowledge states Example: im: intuitionistic_model() Call diagnostics (different branches may describe different overloads): • intuitionistic_model takes no arguments Extracted library reference: evaluator/builtins.go:18064. These notes are not a complete signature or a stability guarantee.

inv

Function

Call diagnostics (different branches may describe different overloads): • argument to inv must be a matrix • inv requires exactly 1 argument: matrix Extracted library reference: evaluator/builtins.go:13934. These notes are not a complete signature or a stability guarantee.

inverse

Function

Call diagnostics (different branches may describe different overloads): • inverse requires exactly 1 argument Extracted library reference: evaluator/builtins.go:7867. These notes are not a complete signature or a stability guarantee. Manual §13.30 Slot-metadata helpers — inverse, transitive, find-or-create; read with manual "13.30" Excerpt: ### Slot-metadata helpers — inverse, transitive, find-or-create Three small builtins covering common KR patterns. All ship as configuration calls; no new keywords.

invert_mapping

Function

invert_mapping(mapping) - Create inverse mapping (if bijective) Extracted library reference: evaluator/builtin_conceptual_mapping.go:169. These notes are not a complete signature or a stability guarantee.

is

Keyword

subject is predicate | x is same as y | x is identical to y | there is x
Multi-purpose keyword for propositions, identity, and existence (Russell's three meanings)

Examples

sky is blue          # Predication

x is same as y       # Identity (sameness)

x is identical to y  # Identity (strict)

there is king        # Existence

isActive

Function

Call diagnostics (different branches may describe different overloads): • isActive requires an axiom • isActive requires exactly 1 argument Extracted library reference: evaluator/builtins.go:6354. These notes are not a complete signature or a stability guarantee.

isGödel

Function

Call diagnostics (different branches may describe different overloads): • isGödel requires exactly 1 argument Extracted library reference: evaluator/builtins.go:6466. These notes are not a complete signature or a stability guarantee.

isValidProof

Function

Call diagnostics (different branches may describe different overloads): • isValidProof requires exactly 2 arguments Extracted library reference: evaluator/builtins.go:6626. These notes are not a complete signature or a stability guarantee.

is_absent

Function

Extracted library reference: evaluator/builtin_option_helpers.go:169. These notes are not a complete signature or a stability guarantee. Manual §33.14.2 Railway helpers — `map_ok` / `and_then` / `or_else` / `is_*`; read with manual "33.14.2" Excerpt: is_some(Some(1)) # true is_absent(Absent) # true is_none(none) # true — the none value, not Option is_ok(Ok(1)) # true is_err(Err("x")) # true

is_all

Function

all?(predicate, collection)
True iff the predicate holds for every element (vacuously true on empty). Registered alias of all?.

is_alnum

Function

Registered alias of alnum?.charPredicate wraps a rune classifier as a builtin accepting a Character or a one-character String. Call diagnostics (different branches may describe different overloads): • is_alnum requires exactly 1 argument Extracted library reference: evaluator/character.go:81. These notes are not a complete signature or a stability guarantee.

is_alpha

Function

Registered alias of alpha?.charPredicate wraps a rune classifier as a builtin accepting a Character or a one-character String. Call diagnostics (different branches may describe different overloads): • is_alpha requires exactly 1 argument Extracted library reference: evaluator/character.go:81. These notes are not a complete signature or a stability guarantee.

is_any

Function

any?(predicate, collection)
True iff the predicate holds for some element (false on empty). Registered alias of any?.

is_array

Function

Call diagnostics (different branches may describe different overloads): • is_array requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

is_ascii

Function

Registered alias of ascii?.charPredicate wraps a rune classifier as a builtin accepting a Character or a one-character String. Call diagnostics (different branches may describe different overloads): • is_ascii requires exactly 1 argument Extracted library reference: evaluator/character.go:81. These notes are not a complete signature or a stability guarantee.

is_assignment_stmt

Function

Registered alias of assignment_stmt?. Call diagnostics (different branches may describe different overloads): • is_assignment_stmt requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1645. These notes are not a complete signature or a stability guarantee.

is_ast

Function

Call diagnostics (different branches may describe different overloads): • is_ast requires exactly 1 argument Extracted library reference: evaluator/builtin_ast_construct.go:345. These notes are not a complete signature or a stability guarantee. Manual §19.10 19.10 Homoiconicity — building code as data; read with manual "19.10" Excerpt: **`is_ast(x)`** predicates the type — useful in pattern-matching code: ```axioma is_ast(hold(2 + 3)) # true

is_ast_has

Function

Registered alias of ast_has?. Call diagnostics (different branches may describe different overloads): • ast_has? field name must be a string • ast_has? requires exactly 2 arguments (AST, field_name) Extracted library reference: evaluator/builtins.go:15874. These notes are not a complete signature or a stability guarantee.

is_bind_stmt

Function

Registered alias of bind_stmt?. Call diagnostics (different branches may describe different overloads): • is_bind_stmt requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1645. These notes are not a complete signature or a stability guarantee.

is_block

Function

Call diagnostics (different branches may describe different overloads): • is_block requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1645. These notes are not a complete signature or a stability guarantee.

is_boolean

Function

Call diagnostics (different branches may describe different overloads): • is_boolean requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

is_builtin

Function

Call diagnostics (different branches may describe different overloads): • is_builtin requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

is_call_expr

Function

Registered alias of call_expr?. Call diagnostics (different branches may describe different overloads): • is_call_expr requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1645. These notes are not a complete signature or a stability guarantee.

is_cd_primitive

Function

Call diagnostics (different branches may describe different overloads): • is_cd_primitive requires 1 argument: primitive Extracted library reference: evaluator/builtin_words.go:107. These notes are not a complete signature or a stability guarantee.

is_char_alphabetic

Function

Registered alias of char_alphabetic?.charClassPredicate: char_alphabetic? / char_numeric? / char_whitespace? over a single-character string. Call diagnostics (different branches may describe different overloads): • is_char_alphabetic requires a single-character string • is_char_alphabetic requires exactly 1 argument Extracted library reference: evaluator/scheme_extras.go:738. These notes are not a complete signature or a stability guarantee.

is_char_numeric

Function

Registered alias of char_numeric?.charClassPredicate: char_alphabetic? / char_numeric? / char_whitespace? over a single-character string. Call diagnostics (different branches may describe different overloads): • is_char_numeric requires a single-character string • is_char_numeric requires exactly 1 argument Extracted library reference: evaluator/scheme_extras.go:738. These notes are not a complete signature or a stability guarantee.

is_char_whitespace

Function

Registered alias of char_whitespace?.charClassPredicate: char_alphabetic? / char_numeric? / char_whitespace? over a single-character string. Call diagnostics (different branches may describe different overloads): • is_char_whitespace requires a single-character string • is_char_whitespace requires exactly 1 argument Extracted library reference: evaluator/scheme_extras.go:738. These notes are not a complete signature or a stability guarantee.

is_cnf

Function

is_cnf(expr) - Check if expression is in Conjunctive Normal Form Returns true if the expression is already in CNF form Call diagnostics (different branches may describe different overloads): • is_cnf requires exactly 1 argument: a boolean expression Extracted library reference: evaluator/builtins.go:16916. These notes are not a complete signature or a stability guarantee.

is_cognitive_word

Function

Call diagnostics (different branches may describe different overloads): • is_cognitive_word requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

is_complex

Function

Call diagnostics (different branches may describe different overloads): • is_complex requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

is_concept

Function

Call diagnostics (different branches may describe different overloads): • is_concept requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

is_control

Function

Registered alias of control?.charPredicate wraps a rune classifier as a builtin accepting a Character or a one-character String. Call diagnostics (different branches may describe different overloads): • is_control requires exactly 1 argument Extracted library reference: evaluator/character.go:81. These notes are not a complete signature or a stability guarantee.

is_date

Function

Call diagnostics (different branches may describe different overloads): • is_date requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

is_datetime

Function

Call diagnostics (different branches may describe different overloads): • is_datetime requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee. Manual §4.7.4 DateTime & Duration — the `datetime` package; read with manual "4.7.4" Excerpt: type(Dt.now()) # → "DateTime" (Dt.utc() for UTC) is_datetime(bday) # → true ; duration?(gap) → true ``` The package also carries `Dt.datetime(y, mo, d, h, mi, s)`, `Dt.from_unix` /

is_dialect

Function

Call diagnostics (different branches may describe different overloads): • is_dialect requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

is_digit

Function

Registered alias of digit?.charPredicate wraps a rune classifier as a builtin accepting a Character or a one-character String. Call diagnostics (different branches may describe different overloads): • is_digit requires exactly 1 argument Extracted library reference: evaluator/character.go:81. These notes are not a complete signature or a stability guarantee.

is_dl_consistent

Function

is_dl_consistent(kb) - Check knowledge base consistency Example: is_dl_consistent(kb) → true/false Call diagnostics (different branches may describe different overloads): • argument must be a DL knowledge base • is_dl_consistent requires 1 argument: kb Extracted library reference: evaluator/builtins.go:18607. These notes are not a complete signature or a stability guarantee.

is_dl_instance

Function

is_dl_instance(kb, individual, concept) - Check if individual is instance of concept Example: is_dl_instance(kb, "john", "Person") → true/false Call diagnostics (different branches may describe different overloads): • first argument must be a DL knowledge base • is_dl_instance requires 3 arguments: kb, individual, concept • second argument must be a string (individual name) • third argument must be a string (concept name) Extracted library reference: evaluator/builtins.go:18519. These notes are not a complete signature or a stability guarantee.

is_dnf

Function

is_dnf(expr) - Check if expression is in Disjunctive Normal Form Returns true if the expression is already in DNF form Call diagnostics (different branches may describe different overloads): • is_dnf requires exactly 1 argument: a boolean expression Extracted library reference: evaluator/builtins.go:16930. These notes are not a complete signature or a stability guarantee.

is_duration

Function

Call diagnostics (different branches may describe different overloads): • is_duration requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

is_email

Function

Call diagnostics (different branches may describe different overloads): • is_email requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

is_empty

Function

Registered alias of empty?.emptyPredicate: empty? — true for an empty collection (array / tuple / string / set / dict). An infinite set is never empty. Non-collections error. Call diagnostics (different branches may describe different overloads): • is_empty requires exactly 1 argument Extracted library reference: evaluator/scheme_extras.go:591. These notes are not a complete signature or a stability guarantee. Manual §22.6.1 Scheme/Lisp-style predicates (`?` suffix); read with manual "22.6.1" Excerpt: `isempty(xs)`, `emptyp(xs)` and `empty(xs)` all fail with `Did you mean \`empty?\` (also spelled \`is_empty\`)?` — see §25 *The word oracle*. ### Higher-order functions

is_epistem

Function

is_epistem(value)
Checks if the value is an Epistem object (a first-class logical fact). Alias: `epistem?`.

Examples

relation parent(x, y)

f: axiom parent("john", "mary")

is_epistem(f)  # true

epistem?(42)   # false

is_eq

Function

Registered alias of eq?.eqIdentityBuiltin builds eq? / eql?. Call diagnostics (different branches may describe different overloads): • is_eq requires exactly 2 arguments Extracted library reference: evaluator/scheme_predicates.go:167. These notes are not a complete signature or a stability guarantee.

is_eql

Function

Registered alias of eql?.eqIdentityBuiltin builds eq? / eql?. Call diagnostics (different branches may describe different overloads): • is_eql requires exactly 2 arguments Extracted library reference: evaluator/scheme_predicates.go:167. These notes are not a complete signature or a stability guarantee.

is_equal

Function

Registered alias of equal?.deepEqualBuiltin builds equal? — deep, type-strict structural equality. Same structural engine as `==` but strict at every depth (evalValueEqualityStrict), so equal?([1,2],[1,2]) is true while equal?(1, 1.0) — and equal?([1],[1.0]) — is false, per Scheme's exact vs inexact distinction; likewise equal?('a', "a") is false where 'a' == "a" is true (the Byte–Integer precedent, extended to Character 2026-09-07). Call diagnostics (different branches may describe different overloads): • is_equal requires exactly 2 arguments Extracted library reference: evaluator/scheme_predicates.go:185. These notes are not a complete signature or a stability guarantee.

is_eqv

Function

Registered alias of eqv?.eqIdentityBuiltin builds eq? / eql?. Call diagnostics (different branches may describe different overloads): • is_eqv requires exactly 2 arguments Extracted library reference: evaluator/scheme_predicates.go:167. These notes are not a complete signature or a stability guarantee.

is_err

Function

Extracted library reference: evaluator/builtin_option_helpers.go:175. These notes are not a complete signature or a stability guarantee. Manual §33.14.2 Railway helpers — `map_ok` / `and_then` / `or_else` / `is_*`; read with manual "33.14.2" Excerpt: is_ok(Ok(1)) # true is_err(Err("x")) # true is_left(Left(1)) # true is_right(Right(1)) # true ```

is_error

Function

Call diagnostics (different branches may describe different overloads): • is_error requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee. Manual §6.6.1 What counts as true; read with manual "6.6.1" Excerpt: not `if`. (`none` and `om` are both falsy, and a total read's absence is `none`, so you rarely need to `if`-test an error at all — but `is_error(e)` is the explicit test when you do.) The coalescing operators `??` / `???` are **not** a third option here: they fire on the *bottoms*, and an `Error` is a present value that passes straight through them — see §29.

is_even

Function

even?(n)
True iff the Integer is even (big-aware). Registered alias of even?.

is_exact

Function

exact?(x)
True iff x is an exact number (Integer or Rational). Floats are inexact; non-numbers are neither. Registered alias of exact?.

is_exists

Function

Registered alias of exists?.Free Logic existence predicate (natural language form) Call diagnostics (different branches may describe different overloads): • exists? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:5632. These notes are not a complete signature or a stability guarantee.

is_expr_stmt

Function

Registered alias of expr_stmt?. Call diagnostics (different branches may describe different overloads): • is_expr_stmt requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1645. These notes are not a complete signature or a stability guarantee.

is_file

Function

Call diagnostics (different branches may describe different overloads): • is_file requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee. Manual §12.11 Contracts — `requires` / `ensures` / `check f`; read with manual "12.11" Excerpt: Two exclusions are deliberate. Path helpers and metadata predicates — `file_exists`, `is_file`, `file_size`, `join_path`, `base_name` — open nothing and are not `io`, so a function may inspect a path under `effects: []`. And `append` splits on its first argument: `append(array, elem)` is the pure functional push and stays permitted, while

is_finite

Function

Registered alias of finite?. Call diagnostics (different branches may describe different overloads): • finite? requires exactly 1 argument Extracted library reference: evaluator/scheme_extras.go:475. These notes are not a complete signature or a stability guarantee. Manual §22.6.1 Scheme/Lisp-style predicates (`?` suffix); read with manual "22.6.1" Excerpt: infinite?(inf) # true is_infinite(inf) # true finite?(3.14) # true is_finite(3.14) # true integral?(5.0) # true — the VALUE is whole (5.01/NaN/±Inf → false; the TYPE test is integer?) # equality: eq? / eql? / eqv? are shallow identity (collections by reference);

is_float

Function

Call diagnostics (different branches may describe different overloads): • is_float requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

is_formula

Function

Call diagnostics (different branches may describe different overloads): • is_formula requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

is_function

Function

Call diagnostics (different branches may describe different overloads): • is_function requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

is_get_word

Function

Call diagnostics (different branches may describe different overloads): • is_get_word requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

is_godel

Function

Call diagnostics (different branches may describe different overloads): • is_godel requires exactly 1 argument Extracted library reference: evaluator/builtins.go:6534. These notes are not a complete signature or a stability guarantee.

is_hash_word

Function

Call diagnostics (different branches may describe different overloads): • is_hash_word requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

is_identifier

Function

Registered alias of identifier?. Call diagnostics (different branches may describe different overloads): • is_identifier requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1645. These notes are not a complete signature or a stability guarantee.

is_if_expr

Function

Registered alias of if_expr?. Call diagnostics (different branches may describe different overloads): • is_if_expr requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1645. These notes are not a complete signature or a stability guarantee.

is_inexact

Function

inexact?(x)
True iff x is an inexact number (Float). Integers and Rationals are exact; non-numbers are neither. Registered alias of inexact?.

is_infinite

Function

Registered alias of infinite?. Call diagnostics (different branches may describe different overloads): • infinite? requires exactly 1 argument Extracted library reference: evaluator/scheme_extras.go:459. These notes are not a complete signature or a stability guarantee. Manual §22.6.1 Scheme/Lisp-style predicates (`?` suffix); read with manual "22.6.1" Excerpt: nan?(nan) # true is_nan(nan) # true infinite?(inf) # true is_infinite(inf) # true finite?(3.14) # true is_finite(3.14) # true integral?(5.0) # true — the VALUE is whole (5.01/NaN/±Inf → false; the TYPE test is integer?)

is_infinity

Function

Call diagnostics (different branches may describe different overloads): • is_infinity requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

is_infix_expr

Function

Registered alias of infix_expr?. Call diagnostics (different branches may describe different overloads): • is_infix_expr requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1645. These notes are not a complete signature or a stability guarantee.

is_integer

Function

is_integer(x)
Checks if the value is an integer. Alias: `integer?`. Other type predicates include: `is_float` (`float?`), `is_boolean` (`boolean?`), `is_string` (`string?`), `is_null` (`null?`), `is_number` (`number?`), `is_rational` (`rational?`), `is_complex` (`complex?`), `is_concept` (`concept?`), `is_relation` (`relation?`), `is_axiom` (`axiom?`), `is_proposition` (`proposition?`), `is_array` (`array?`), `is_set` (`set?`), `is_tuple` (`tuple?`), `is_map` (`map?`), `is_graph` (`graph?`), `is_entity` (`entity?`), `is_epistem` (`epistem?`).

Examples

is_integer(42)   # Returns true

integer?(3.14)   # Returns false

is_integral

Function

integral?(x)
True iff the VALUE is a whole number — 5.0 → true, 5.01/NaN/±Inf → false, non-numbers → false (the TYPE test is integer?). Registered alias of integral?.

is_interactive

Function

is_interactive() / isatty() — report whether the process's standard input is attached to an interactive terminal (TTY) rather than a pipe or redirect. This exposes to scripts the same primitive the REPL already uses internally for mode routing (cmd/axioma/repl_bootstrap.go: term.IsTerminal). It is a NON-CONSUMING check: unlike the `confirm()`-on-EOF idiom it replaces, it reads no stdin and so never swallows a line of input. Stateless (no environment) → available identically under --vm (shared GetBuiltins table) and in the WASM playground (golang.org/x/term compiles for js/wasm, where it returns false — the correct answer for a browser). Takes no arguments; returns a Boolean. `isatty` is a familiar alias. Call diagnostics (different branches may describe different overloads): • is_interactive takes no arguments Extracted library reference: evaluator/builtin_tty.go:22. These notes are not a complete signature or a stability guarantee. Manual §25.9 Detecting interactivity — `is_interactive()` / `isatty()`; read with manual "25.9" Excerpt: ### Detecting interactivity — `is_interactive()` / `isatty()` A script can ask whether it is attached to a terminal, so the same source can prompt a human interactively yet stay silent (or take defaults) when

is_left

Function

Extracted library reference: evaluator/builtin_option_helpers.go:178. These notes are not a complete signature or a stability guarantee. Manual §33.14.2 Railway helpers — `map_ok` / `and_then` / `or_else` / `is_*`; read with manual "33.14.2" Excerpt: is_err(Err("x")) # true is_left(Left(1)) # true is_right(Right(1)) # true ```

is_let_stmt

Function

Registered alias of let_stmt?. Call diagnostics (different branches may describe different overloads): • is_let_stmt requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1645. These notes are not a complete signature or a stability guarantee.

is_letter

Function

Registered alias of letter?.charPredicate wraps a rune classifier as a builtin accepting a Character or a one-character String. Call diagnostics (different branches may describe different overloads): • is_letter requires exactly 1 argument Extracted library reference: evaluator/character.go:81. These notes are not a complete signature or a stability guarantee.

is_list

Function

Call diagnostics (different branches may describe different overloads): • is_list requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee. Manual §5.8 Lists (persistent cons lists); read with manual "5.8" Excerpt: be ambiguous. `is List`, `is_list(l)` and `list?(l)` test the type (`list?` no longer aliases `array?`; an Array argument errors with a migration hint). The accumulate idiom is `acc: cons(x, acc)` in a loop, then `reverse(acc)` — every step O(1).

is_lower

Function

Registered alias of lower?.charPredicate wraps a rune classifier as a builtin accepting a Character or a one-character String. Call diagnostics (different branches may describe different overloads): • is_lower requires exactly 1 argument Extracted library reference: evaluator/character.go:81. These notes are not a complete signature or a stability guarantee.

is_minus

Function

Registered alias of minus?.numericSignPredicate builds a 1-arg predicate over a number's sign. A non-number argument yields false (matching the existing positive/negative/ even family, which return false rather than erroring on a wrong type). Call diagnostics (different branches may describe different overloads): • is_minus requires exactly 1 argument Extracted library reference: evaluator/scheme_predicates.go:56. These notes are not a complete signature or a stability guarantee.

is_module

Function

Call diagnostics (different branches may describe different overloads): • is_module requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

is_money

Function

Call diagnostics (different branches may describe different overloads): • is_money requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee. Manual §4.7 Scalar value types & literals; read with manual "4.7" Excerpt: | `Time` | `12:34:56` | `"Time"` | — | `HH:MM:SS` | | `Money` | `$123.45` | `"Money"` | `is_money` | `$` + digit | | `Pair` | `'X' => 10`, `pair(k, v)` | `"Pair"` | `is_pair` | key–value cell; not a Tuple, not a Dictionary. `100x200` is retired | | `Percent` | `42%` | `"Percent"` | `is_percent` | number + `%` | | `Word` | `'hello` | `"Word"` | `is_word` | self-evaluating symbol (the label) |

is_nan

Function

Registered alias of nan?.--- float-domain predicates ---------------------------------------------- Call diagnostics (different branches may describe different overloads): • nan? requires exactly 1 argument Extracted library reference: evaluator/scheme_extras.go:443. These notes are not a complete signature or a stability guarantee. Manual §22.6.1 Scheme/Lisp-style predicates (`?` suffix); read with manual "22.6.1" Excerpt: # float domain (`inf` / `nan` are builtins producing ±∞ / NaN floats) # `is_X` ≡ `X?` — both spellings, same function (`is_nan` ≡ `nan?`) nan?(nan) # true is_nan(nan) # true infinite?(inf) # true is_infinite(inf) # true finite?(3.14) # true is_finite(3.14) # true

is_negative

Function

Registered alias of negative?.numericSignPredicate builds a 1-arg predicate over a number's sign. A non-number argument yields false (matching the existing positive/negative/ even family, which return false rather than erroring on a wrong type). Call diagnostics (different branches may describe different overloads): • is_negative requires exactly 1 argument Extracted library reference: evaluator/scheme_predicates.go:56. These notes are not a complete signature or a stability guarantee.

is_none

Function

Call diagnostics (different branches may describe different overloads): • is_none requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee. Manual §25.11 The word oracle — discovering the language by bumping into it; read with manual "25.11" Excerpt: "(also spelled …)" is said only when the two names are one function; a shape that belongs to several names (`isNone` → `none?`, `is_none`) gets a row each, with no claim about how they differ. The oracle also speaks on one shape that runs without error: a pipe ending in

is_nsm_prime

Function

is_nsm_prime(word) - Checks if a word is an NSM prime Usage: is_nsm_prime("THINK") returns true, is_nsm_prime("happy") returns false Call diagnostics (different branches may describe different overloads): • is_nsm_prime requires 1 argument: word Extracted library reference: evaluator/builtin_nsm.go:52. These notes are not a complete signature or a stability guarantee.

is_null

Function

Call diagnostics (different branches may describe different overloads): • is_null requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

is_number

Function

Call diagnostics (different branches may describe different overloads): • is_number requires exactly 1 argument Extracted library reference: evaluator/builtins.go:5268. These notes are not a complete signature or a stability guarantee.

is_object

Function

Call diagnostics (different branches may describe different overloads): • is_object requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

is_odd

Function

odd?(n)
True iff the Integer is odd (big-aware). Registered alias of odd?.

is_ok

Function

Extracted library reference: evaluator/builtin_option_helpers.go:172. These notes are not a complete signature or a stability guarantee. Manual §33.14.2 Railway helpers — `map_ok` / `and_then` / `or_else` / `is_*`; read with manual "33.14.2" Excerpt: is_none(none) # true — the none value, not Option is_ok(Ok(1)) # true is_err(Err("x")) # true is_left(Left(1)) # true is_right(Right(1)) # true

is_om

Function

Call diagnostics (different branches may describe different overloads): • is_om requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

is_pair

Function

Call diagnostics (different branches may describe different overloads): • is_pair requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee. Manual §4.7 Scalar value types & literals; read with manual "4.7" Excerpt: | `Money` | `$123.45` | `"Money"` | `is_money` | `$` + digit | | `Pair` | `'X' => 10`, `pair(k, v)` | `"Pair"` | `is_pair` | key–value cell; not a Tuple, not a Dictionary. `100x200` is retired | | `Percent` | `42%` | `"Percent"` | `is_percent` | number + `%` | | `Word` | `'hello` | `"Word"` | `is_word` | self-evaluating symbol (the label) | | `GetWord` | `:name` | `"GetWord"` | — | reads a value without evaluating |

is_partitioned

Function

is_partitioned(Concept)
True iff the concept declares at least one partition and every declared tuple is disjoint (no extent member in >1 part) AND exhaustive (none in 0 parts) over the instances seen so far. Open-world: a verdict on the current extent, not a closed-taxonomy claim.

Examples

Thing partition UpToUs, NotUpToUs

is_partitioned(Thing)

is_percent

Function

Call diagnostics (different branches may describe different overloads): • is_percent requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee. Manual §4.7 Scalar value types & literals; read with manual "4.7" Excerpt: | `Pair` | `'X' => 10`, `pair(k, v)` | `"Pair"` | `is_pair` | key–value cell; not a Tuple, not a Dictionary. `100x200` is retired | | `Percent` | `42%` | `"Percent"` | `is_percent` | number + `%` | | `Word` | `'hello` | `"Word"` | `is_word` | self-evaluating symbol (the label) | | `GetWord` | `:name` | `"GetWord"` | — | reads a value without evaluating |

is_phrase

Function

Call diagnostics (different branches may describe different overloads): • is_phrase requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

is_plus

Function

Registered alias of plus?.numericSignPredicate builds a 1-arg predicate over a number's sign. A non-number argument yields false (matching the existing positive/negative/ even family, which return false rather than erroring on a wrong type). Call diagnostics (different branches may describe different overloads): • is_plus requires exactly 1 argument Extracted library reference: evaluator/scheme_predicates.go:56. These notes are not a complete signature or a stability guarantee.

is_positive

Function

Registered alias of positive?.numericSignPredicate builds a 1-arg predicate over a number's sign. A non-number argument yields false (matching the existing positive/negative/ even family, which return false rather than erroring on a wrong type). Call diagnostics (different branches may describe different overloads): • is_positive requires exactly 1 argument Extracted library reference: evaluator/scheme_predicates.go:56. These notes are not a complete signature or a stability guarantee.

is_prime

Function

is_prime(n)
Checks if the integer n is a prime number. Returns true if n is prime, false otherwise. Alias: `prime?`.

Examples

is_prime(7)   # Returns true

is_prime(4)   # Returns false

prime?(17)    # Returns true

is_procedure

Function

Registered alias of procedure?.callablePredicate: procedure? — true for any callable. Call diagnostics (different branches may describe different overloads): • is_procedure requires exactly 1 argument Extracted library reference: evaluator/scheme_extras.go:568. These notes are not a complete signature or a stability guarantee.

is_program

Function

Registered alias of program?. Call diagnostics (different branches may describe different overloads): • is_program requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1645. These notes are not a complete signature or a stability guarantee.

is_proposition

Function

Call diagnostics (different branches may describe different overloads): • is_proposition requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

is_punct

Function

Registered alias of punct?.charPredicate wraps a rune classifier as a builtin accepting a Character or a one-character String. Call diagnostics (different branches may describe different overloads): • is_punct requires exactly 1 argument Extracted library reference: evaluator/character.go:81. These notes are not a complete signature or a stability guarantee.

is_rational

Function

Call diagnostics (different branches may describe different overloads): • is_rational requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

is_reference

Function

Call diagnostics (different branches may describe different overloads): • is_reference requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

is_right

Function

Extracted library reference: evaluator/builtin_option_helpers.go:181. These notes are not a complete signature or a stability guarantee. Manual §33.14.2 Railway helpers — `map_ok` / `and_then` / `or_else` / `is_*`; read with manual "33.14.2" Excerpt: is_left(Left(1)) # true is_right(Right(1)) # true ``` | Helper | Success tags | Failure tags |

is_satisfiable

Function

is_satisfiable(expr)
Decides propositional satisfiability via the DPLL SAT engine — true iff there exists a truth assignment making the boolean expression true. Accepts a func(p, q, …) […] proposition. Used in logicism/Russell staging: is_satisfiable(func(p) [p iff (not p)]) → false. Distinct from DL satisfiable(C) (concept tableau) and [logic/sat | …].

Examples

is_satisfiable(func(p, q) [p and q])           # true

is_satisfiable(func(p) [p and (not p)])        # false

is_satisfiable(func(p) [p iff (not p)])        # false — Russell core

is_set

Function

Call diagnostics (different branches may describe different overloads): • is_set requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

is_some

Function

Extracted library reference: evaluator/builtin_option_helpers.go:166. These notes are not a complete signature or a stability guarantee. Manual §33.14.2 Railway helpers — `map_ok` / `and_then` / `or_else` / `is_*`; read with manual "33.14.2" Excerpt: is_some(Some(1)) # true is_absent(Absent) # true is_none(none) # true — the none value, not Option is_ok(Ok(1)) # true

is_space

Function

Registered alias of space?.charPredicate wraps a rune classifier as a builtin accepting a Character or a one-character String. Call diagnostics (different branches may describe different overloads): • is_space requires exactly 1 argument Extracted library reference: evaluator/character.go:81. These notes are not a complete signature or a stability guarantee.

is_stack

Function

Call diagnostics (different branches may describe different overloads): • is_stack requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

is_string

Function

Call diagnostics (different branches may describe different overloads): • is_string requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

is_subclass_of

Function

Concept introspection functions for natural DL syntax Call diagnostics (different branches may describe different overloads): • both arguments to is_subclass_of must be concepts • is_subclass_of requires exactly 2 arguments: subconcept, superconcept Extracted library reference: evaluator/builtins.go:5853. These notes are not a complete signature or a stability guarantee.

is_subsumed_by

Function

is_subsumed_by(kb, sub_concept, super_concept) - Check subsumption with transitive closure Example: is_subsumed_by(kb, "Undergrad", "Person") → true Call diagnostics (different branches may describe different overloads): • concept names must be strings • first argument must be a DL knowledge base • is_subsumed_by requires 3 arguments: kb, sub_concept, super_concept Extracted library reference: evaluator/builtins.go:18880. These notes are not a complete signature or a stability guarantee.

is_subtype_of

Function

is_subtype_of(a, b)
Leibniz's containment test: A is a subtype of B iff B's characteristic number divides A's. Accepts integers or LeibnizEncodings.

Examples

is_subtype_of(10374, 546)   # true — every human is animal

is_subtype_of(66, 546)      # false — no stone is animal

is_symbol

Function

Registered alias of symbol?. Call diagnostics (different branches may describe different overloads): • is_symbol requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1633. These notes are not a complete signature or a stability guarantee.

is_tag

Function

Call diagnostics (different branches may describe different overloads): • is_tag requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

is_tautology

Function

is_tautology(expr) - Check if expression is a tautology (always true) Uses DPLL SAT solver: φ is tautology iff ¬φ is unsatisfiable Example: is_tautology(func(p) [ p or not p ]) → true Call diagnostics (different branches may describe different overloads): • is_tautology requires exactly 1 argument: a boolean expression Extracted library reference: evaluator/builtins.go:16945. These notes are not a complete signature or a stability guarantee.

is_time

Function

Call diagnostics (different branches may describe different overloads): • is_time requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

is_tuple

Function

Call diagnostics (different branches may describe different overloads): • is_tuple requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

is_upper

Function

Registered alias of upper?.charPredicate wraps a rune classifier as a builtin accepting a Character or a one-character String. Call diagnostics (different branches may describe different overloads): • is_upper requires exactly 1 argument Extracted library reference: evaluator/character.go:81. These notes are not a complete signature or a stability guarantee.

is_url

Function

Call diagnostics (different branches may describe different overloads): • is_url requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee. Manual §4.7 Scalar value types & literals; read with manual "4.7" Excerpt: |---|---|---|---|---| | `URL` | `https://example.com/path` | `"URL"` | `is_url` | `http://` / `https://`; `read()` fetches it | | `Email` | `[email protected]` | `"Email"` | — | `local@domain` shape | | `File` | `%data/file.txt` | `"File"` | — | `%` + path; **relative** (see the gotcha below) | | `Date` | `2026-05-02`, `1-Jan-2024`, `7/2/26` | `"Date"` | — | several spellings |

is_word

Function

Call diagnostics (different branches may describe different overloads): • is_word requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1633. These notes are not a complete signature or a stability guarantee. Manual §4.7 Scalar value types & literals; read with manual "4.7" Excerpt: | `Percent` | `42%` | `"Percent"` | `is_percent` | number + `%` | | `Word` | `'hello` | `"Word"` | `is_word` | self-evaluating symbol (the label) | | `GetWord` | `:name` | `"GetWord"` | — | reads a value without evaluating | ```axioma

is_zero

Function

Registered alias of zero?.numericSignPredicate builds a 1-arg predicate over a number's sign. A non-number argument yields false (matching the existing positive/negative/ even family, which return false rather than erroring on a wrong type). Call diagnostics (different branches may describe different overloads): • is_zero requires exactly 1 argument Extracted library reference: evaluator/scheme_predicates.go:56. These notes are not a complete signature or a stability guarantee.

is_zero_sum

Function

Call diagnostics (different branches may describe different overloads): • argument must be a game • is_zero_sum requires 1 argument: game Extracted library reference: evaluator/builtins.go:13692. These notes are not a complete signature or a stability guarantee.

isa

Operator

(retired May 2026) — write: instance is Concept
Retired spelling — the one copula `is` carries classification now (Russell's senses unified): predication/membership (`myDog is Dog`), class inclusion declared with `extends` and queried with `is` (`Dog is Animal`), identity via `is/same`, existence via `there is x in S | ...`. A leftover `x isa Y` errors with a migration hint.

Examples

myDog is Dog          # Direct instance check

myDog is Animal       # Inheritance check (Dog extends Animal)

Duck is Flyable       # Concept implements interface

d is/same d           # Identity sense

isatty

Function

is_interactive() / isatty() — report whether the process's standard input is attached to an interactive terminal (TTY) rather than a pipe or redirect. This exposes to scripts the same primitive the REPL already uses internally for mode routing (cmd/axioma/repl_bootstrap.go: term.IsTerminal). It is a NON-CONSUMING check: unlike the `confirm()`-on-EOF idiom it replaces, it reads no stdin and so never swallows a line of input. Stateless (no environment) → available identically under --vm (shared GetBuiltins table) and in the WASM playground (golang.org/x/term compiles for js/wasm, where it returns false — the correct answer for a browser). Takes no arguments; returns a Boolean. `isatty` is a familiar alias. Call diagnostics (different branches may describe different overloads): • is_interactive takes no arguments Extracted library reference: evaluator/builtin_tty.go:22. These notes are not a complete signature or a stability guarantee. Manual §25.9 Detecting interactivity — `is_interactive()` / `isatty()`; read with manual "25.9" Excerpt: ### Detecting interactivity — `is_interactive()` / `isatty()` A script can ask whether it is attached to a terminal, so the same source can prompt a human interactively yet stay silent (or take defaults) when

isqrt

Function

isqrtBuiltin: floor of the square root of a non-negative integer (exact, big-int aware) — Common Lisp isqrt. Call diagnostics (different branches may describe different overloads): • isqrt requires a non-negative integer • isqrt requires exactly 1 argument Extracted library reference: evaluator/scheme_extras.go:349. These notes are not a complete signature or a stability guarantee. Manual §22.3 Mathematical functions; read with manual "22.3" Excerpt: | `succ(x)` / `pred(x)` | Successor / predecessor over the ordinal types (Pascal/Ada `'Succ`/`'Pred`): Integers (`succ(5)` → 6) and enum members (`succ(Mon)` → Tue, erroring at the ends). On Integers ≡ `add1`/`sub1`; the ordinal-typed, enum-symmetric spelling | | `isqrt(n)` | Integer floor square root of a non-negative integer (exact, big-int aware) | | `numerator(r)` / `denominator(r)` | Rational accessors; an integer `n` is `n/1` (so `denominator(5)` → `1`) | | `to_number(s)` | Parse a string to a number — Integer if integral, else Float; a number passes through |

it

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §19.3.1 The closing backtick is what makes it safe; read with manual "19.3.1" Excerpt: #### The closing backtick is what makes it safe An **unpaired** backtick is the ASCII glyph digraph of [§3](#3-language-fundamentals) — `` `in `` → ∈, `` `cup `` → ∪ — and remains exactly that. Only a *matched pair* is infix application.

items

Function

items(hash)
(key, value) tuples of a Dictionary, sorted by key. Manual §7.14 Aggregation: `group_by`, `items`, `keys`, `values`; read with manual "7.14" Excerpt: ### Aggregation: `group_by`, `items`, `keys`, `values` Four builtins fill the SQL-style aggregation gap. `group_by(fn, coll)` partitions a collection into a hash; `items(hash)` exposes it as `(key, value)` pairs; `keys`/`values` return the parts individually. All three enumerators walk the hash in **sorted key order** — the same canonical order `println(h)` shows — so repeated calls (and `keys`/`values`/`items` against each other) always agree.

iterate

Function

iterate(fn, start [, count])
Haskell iterate: the sequence [start, fn(start), fn(fn(start)), …]. With count, the first count terms as an Array. Without count, an unbounded lazy Generator for `for i in iterate(fn, start)`. Not the Iterable walker — that is elements(x).

Examples

iterate(func(v) [v * 2], 1, 5)   # [1, 2, 4, 8, 16]

iterate(func(v) [v * 2], 1)      # <generator>

jaro_winkler

Function

Call diagnostics (different branches may describe different overloads): • jaro_winkler requires exactly 2 arguments • jaro_winkler requires two strings Extracted library reference: evaluator/builtins.go:6214. These notes are not a complete signature or a stability guarantee.

join

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §28.5.3 Queries — `SELECT` with the full join family; read with manual "28.5.3" Excerpt: #### Queries — `SELECT` with the full join family ```axioma # Single-table SELECT with WHERE

kestrel

Function

kestrel(value, ignored)
The Kestrel (K), curried: kestrel(a)(b) is a. Unlike constantly, an over-applied kestrel(a)(b)(c) reduces to a(c).

keys

Function

keys(hash)
Keys of a Dictionary, sorted. Manual §7.14 Aggregation: `group_by`, `items`, `keys`, `values`; read with manual "7.14" Excerpt: ### Aggregation: `group_by`, `items`, `keys`, `values` Four builtins fill the SQL-style aggregation gap. `group_by(fn, coll)` partitions a collection into a hash; `items(hash)` exposes it as `(key, value)` pairs; `keys`/`values` return the parts individually. All three enumerators walk the hash in **sorted key order** — the same canonical order `println(h)` shows — so repeated calls (and `keys`/`values`/`items` against each other) always agree.

keywords

Function

keywords() | keywords(word)
The reserved-word catalog — the word twin of the glyph catalog symbols(). With no arguments, returns a sorted Array of every reserved word in the language (words that cannot be used as names without the $name guard: $everyone, $"interest rate"). With one String argument, returns a Boolean: is this word reserved? Lets an author check a candidate name BEFORE a collision produces a parse-error cascade; the parser also hints at the $ guard when a reserved word is used as a binding target.

Examples

len(keywords())          # 200+ — the full sorted catalog

"everyone" in keywords() # Returns true  (reserved: KM NL surface)

keywords("everyone")     # Returns true  (1-arg reservation check)

keywords("banana")       # Returns false (free to use as a name)

$everyone: {"a", "b"}    # the guard frees a reserved spelling

kleene

Function

kleene("true" | "false" | "unknown") — or the literals ⊤ᵏ ⊥ᵏ ?ᵏ
Kleene K3 truth-value constructor (strong three-valued logic: unknown propagates unless the result is already decided). The typed literals ⊤ᵏ ⊥ᵏ ?ᵏ (digraphs `kltrue `klfalse `klunknown; member Kleene.unknown; Kleene.values) run the same K3 tables as the historical untyped unknown `om` and re-wrap results as Kleene. ?ᵏ == om is true, and since step 2.5 they branch the SAME: both `if ?ᵏ` and `if om` are falsy (designation — only ⊤ᵏ is designated; om folds onto the designation path). Accepts Boolean, om, an existing Kleene, and t/f/u/?/⊤/⊥ spellings.

Examples

ku: ?ᵏ                          # ≡ kleene("unknown") (also kleene(om))

?ᵏ and ⊤ᵏ                       # → ?ᵏ (typed results stay Kleene)

om and true                     # → Ω (the untyped K3 path, unchanged)

?ᵏ == om                        # → true (canonical equality)

if ?ᵏ then "t" else "f"         # → "f" — unknown is not designated

?ᵏ implies ?ᵏ                   # → ?ᵏ (K3 — contrast G3's reflexive ⊤ⁱ)

kleene_false

Symbol

=== ⊥ᵏ (Glyph) === name: kleene_false latex: klfalse category: mvl codepoint: U+22A5 meaning: ⊥ᵏ — Kleene K3 false (≡ kleene("false"))

kleene_true

Symbol

=== ⊤ᵏ (Glyph) === name: kleene_true latex: kltrue category: mvl codepoint: U+22A4 meaning: ⊤ᵏ — Kleene K3 true (≡ kleene("true"))

kleene_unknown

Symbol

=== ?ᵏ (Glyph) === name: kleene_unknown latex: klunknown category: mvl codepoint: U+003F meaning: ?ᵏ — Kleene K3 unknown (≡ kleene("unknown"); om is the untyped K3 unknown)

klfalse

Symbol

=== ⊥ᵏ (Glyph) === name: kleene_false latex: klfalse category: mvl codepoint: U+22A5 meaning: ⊥ᵏ — Kleene K3 false (≡ kleene("false"))

kltrue

Symbol

=== ⊤ᵏ (Glyph) === name: kleene_true latex: kltrue category: mvl codepoint: U+22A4 meaning: ⊤ᵏ — Kleene K3 true (≡ kleene("true"))

klunknown

Symbol

=== ?ᵏ (Glyph) === name: kleene_unknown latex: klunknown category: mvl codepoint: U+003F meaning: ?ᵏ — Kleene K3 unknown (≡ kleene("unknown"); om is the untyped K3 unknown)

knows

Epistemic Logic

agent knows proposition
Epistemic knowledge operator. Expresses that an agent knows a proposition with certainty.

Examples

Socrates knows true

Alice knows (2 + 2 == 4)

knowledge: Expert knows theorem

kripke_model

Function

kripke_model(system) - Create a new Kripke model for alethic modal logic Example: kripke_model("S5") → New S5 Kripke model Systems: "K", "T", "S4", "S5", "KD45" Extracted library reference: evaluator/builtins.go:17699. These notes are not a complete signature or a stability guarantee.

lambda

Keyword

lambda (param1, param2, ...rest) => expression  |  lambda binder1 binder2 => expression (curried)
Creates an anonymous function. A parenthesized header takes comma-separated parameters and may end with a variadic ...rest slot; an un-parenthesized run of names is the curried binder list (one argument at a time). λ and \ are the same keyword.

Examples

lambda x => x * 2

lambda (x, y) => x + y

lambda x y => x + y          # curried: call as f(1)(2)

lambda (a, ...rest) => [a, rest]

double: lambda x => x * 2

land

Symbol

=== ∧ (Glyph) === name: and words: and latex: wedge, land category: logic codepoint: U+2227 meaning: p ∧ q — logical conjunction (canonicalizes to the `and` operator; MVL-dispatched)

last

Function

last(s)
Last element (whole rune on Strings; error on infinite sets). Manual §12.10 Return values — the last expression, and `return`; read with manual "12.10" Excerpt: ### Return values — the last expression, and `return` A function body returns its **last evaluated expression** — that is the native idiom, and most Axioma functions never write `return` at all. For

laws_of_thought

Function

laws_of_thought()
Returns Schopenhauer's four laws of thought as seeded entities: identity, non_contradiction, excluded_middle, and sufficient_reason — each annotated with which of Axioma's five logic kinds endorse it (Belnap B4 rejects non-contradiction; only Boolean keeps excluded middle). Sufficient reason is the master principle behind the whole grounding system.

Examples

laws_of_thought()

len(laws_of_thought())  # 4

layout_algorithms

Function

Get available layout algorithms Call diagnostics (different branches may describe different overloads): • layout_algorithms requires no arguments Extracted library reference: evaluator/builtins.go:9223. These notes are not a complete signature or a stability guarantee.

layout_description

Function

Get layout algorithm description Call diagnostics (different branches may describe different overloads): • argument must be a string (layout name) • layout_description requires exactly 1 argument: layout_name Extracted library reference: evaluator/builtins.go:9242. These notes are not a complete signature or a stability guarantee.

lazy

Keyword

lazy <expression>  |  name/lazy
Two related forms. Expression: `lazy e` yields a first-class memoized thunk that caches a successful result when force() is applied; failed attempts may retry and cyclic demand is an error. Parameter refinement: `func(body/lazy)` wraps the argument as a transparent thunk (auto-force, memoize-once). `body/lazy :: Type` checks and converts the eventual value when demanded; `--vm` refuses `/lazy` functions. `declare x = e` is the BINDING form of deferred evaluation. Soft keyword: `lazy` remains usable as an ordinary name (`lazy: 5`, `f(lazy)`). Binds at prefix precedence, so `lazy 1 + 2` is `(lazy 1) + 2` — parenthesize to defer the whole expression. Evaluator-only as an expression: rejected at compile time under --vm.

Examples

t: lazy (6 * 7)        # nothing computed yet

force(t)               # 42 — computed now, and memoized

unless(test, body/lazy) = if not test then body

pick(false, lazy slow())   # slow() never runs if the branch is not taken

lcm

Function

lcm(a, b)
Least common multiple (big-aware). Manual §4.1.1 Integers don't overflow; read with manual "4.1.1" Excerpt: builtins (`succ`/`pred`, `sum`, `abs`, `divmod`/`quotient`/`remainder`, `floor`/`ceil`/`round`/`trunc`/`int`, `gcd`/`lcm`, `factorial`, …). Consequences of the design:

le

Symbol

=== ≤ (Glyph) === name: less_equal latex: leq, le, leqslant variants: ⩽ category: logic codepoint: U+2264 meaning: a ≤ b — less than or equal (canonicalizes to <=; ordering comparisons chain: 0 ≤ x < n)

least_common_subsumer

Function

Call diagnostics (different branches may describe different overloads): • least_common_subsumer requires exactly 2 arguments • least_common_subsumer requires two concepts Extracted library reference: evaluator/builtins.go:6229. These notes are not a complete signature or a stability guarantee.

left?

Function

left?(value)
Test whether a constructor value has the Left tag. This is a tag test; it does not unwrap or execute the contained value. See manual "Option" for Option, Result and Either.

leftarrow

Symbol

=== ← (Glyph) === name: backarrow latex: leftarrow category: logic codepoint: U+2190 meaning: ← — conceptual-graph backward arrow

leftrightarrow

Symbol

=== ↔ (Glyph) === name: iff words: iff latex: leftrightarrow, iff variants: ⟺ category: logic codepoint: U+2194 meaning: p ↔ q — if and only if (biconditional)

leibniz_decode

Function

leibniz_decode(taxonomy, number)
Decodes a characteristic number back to its taxonomic path by prime factorization.

Examples

leibniz_decode(porphyry, 42)   # substance → material → animate

leibniz_encode

Function

leibniz_encode(taxonomy, path)
Encodes a taxonomic path as its characteristic number — the product of the primes along the path (Leibniz, De Arte Combinatoria 1666; arithmetized 1679). Returns a LeibnizEncoding with .value, .path and prime factors.

Examples

h: leibniz_encode(porphyry, ["substance", "material", "animate", "sensitive", "rational"])

h.value   # 10374 = 2·3·7·13·19

len

Function

len(collection)
Returns the length of a collection (array, tuple, set, range, string, bytes, bag, concept, or hash map). `len`, `length`, and `size` are three spellings of one operation, and each also works as a read accessor — so len(xs), length(xs), size(xs), xs.len, xs.length, xs.size, and xs's len all agree. String length is characters. A Matrix has no single length — size(m) errors and names shape(m) / tuple(shape(m)) / ndim(m).

Examples

len([1, 2, 3])          # Returns 3

len("hello")            # Returns 5

len({1, 2, 3})          # Returns 3

len({"a": 1, "b": 2})   # Returns 2

[1, 2, 3].len        # Returns 3   (dot accessor — same name)

[1, 2, 3]'s len     # Returns 3   (possessive — same name)

length

Function

length(collection)
Returns the length of a collection (array, tuple, set, range, string, bytes, bag, concept, or hash map). `len`, `length`, and `size` are three spellings of one operation, and each also works as a read accessor — so len(xs), length(xs), size(xs), xs.len, xs.length, xs.size, and xs's len all agree. String length is characters. A Matrix has no single length — size(m) errors and names shape(m) / tuple(shape(m)) / ndim(m).

Examples

length([1, 2, 3])          # Returns 3

length("hello")            # Returns 5

length({1, 2, 3})          # Returns 3

length({"a": 1, "b": 2})   # Returns 2

[1, 2, 3].length        # Returns 3   (dot accessor — same name)

[1, 2, 3]'s length     # Returns 3   (possessive — same name)

leq

Symbol

=== ≤ (Glyph) === name: less_equal latex: leq, le, leqslant variants: ⩽ category: logic codepoint: U+2264 meaning: a ≤ b — less than or equal (canonicalizes to <=; ordering comparisons chain: 0 ≤ x < n)

leqslant

Symbol

=== ≤ (Glyph) === name: less_equal latex: leq, le, leqslant variants: ⩽ category: logic codepoint: U+2264 meaning: a ≤ b — less than or equal (canonicalizes to <=; ordering comparisons chain: 0 ≤ x < n)

less

Function

less(x, y)
Multi-argument predicate that checks if x < y. Part of the enhanced first-order logic system.

Examples

less(3, 5)  # Returns true

less(7, 2)  # Returns false

exists x,y in Numbers: less(x, y) and greater(add(x, 1), y)

less_equal

Symbol

=== ≤ (Glyph) === name: less_equal latex: leq, le, leqslant variants: ⩽ category: logic codepoint: U+2264 meaning: a ≤ b — less than or equal (canonicalizes to <=; ordering comparisons chain: 0 ≤ x < n)

let

Keyword

let NAME [:: Type] [= value]
Declares a FRESH, IMMUTABLE binding in the current scope, shadowing any outer name of the same spelling — never updating an existing binding (the dual of rebind), and refusing every later write to its cell (the mathematical reading: `let x = 5` fixes x). Its mutable twin is `var` (`let mut` / `let mutable` are the same declaration). Closures made before the let keep the old binding. RESERVED word since August 2026 (guard the name as `$let` to use it as an identifier; `[let x]` word lists take it bare). Initializers use `=`. Second spelling: `val`. A bare declaration (`let x` or `let x :: T`) is an alias for its explicit `= _` form and permits one successful fill; Function, arrow types and user concepts need no default value. The fill enforces the stored annotation even when the static checker cannot model it precisely.

Examples

let x = 5

let d :: Date = today()

let a, b = 1, 2

let x = 5
x: 6   # ERROR: `let` bindings are immutable — use `var`

let_stmt

Function

Call diagnostics (different branches may describe different overloads): • let_stmt name must be a string • let_stmt requires exactly 2 arguments (name, value) Extracted library reference: evaluator/builtins.go:1661. These notes are not a complete signature or a stability guarantee.

let_stmt?

Function

Call diagnostics (different branches may describe different overloads): • let_stmt? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1645. These notes are not a complete signature or a stability guarantee.

letter?

Function

charPredicate wraps a rune classifier as a builtin accepting a Character or a one-character String. Call diagnostics (different branches may describe different overloads): • letter? requires exactly 1 argument Extracted library reference: evaluator/character.go:81. These notes are not a complete signature or a stability guarantee.

levenshtein

Function

Call diagnostics (different branches may describe different overloads): • levenshtein requires exactly 2 arguments • levenshtein requires two strings Extracted library reference: evaluator/builtins.go:6199. These notes are not a complete signature or a stability guarantee.

lfalse

Symbol

=== ⊥ł (Glyph) === name: lukasiewicz_false latex: lfalse category: mvl codepoint: U+22A5 meaning: ⊥ł — Łukasiewicz Ł3 false (≡ lukasiewicz(0.0))

lhalf

Symbol

=== ½ł (Glyph) === name: lukasiewicz_half latex: lhalf category: mvl codepoint: U+00BD meaning: ½ł — Łukasiewicz Ł3 half-true (≡ lukasiewicz(0.5))

linguistic_var

Function

Call diagnostics (different branches may describe different overloads): • linguistic variable name must be a string • linguistic_var requires 3 arguments: name, min, max • max must be a number • min must be a number Extracted library reference: evaluator/builtins.go:12912. These notes are not a complete signature or a stability guarantee.

list

Function

list() | list(collection)
Constructs a persistent cons List (immutable, structure-sharing). Conversion-only 0/1 arity like array()/set()/tuple(): list() is the empty list (truthy), list(coll) converts an ordered collection. Variadic calls error. Build directly with `[1, 2, 3] or empty `[]; wrap one value with `[x]. Each literal element evaluates once and stays nested. list([1, 2, 3]) and cons(x, list()) remain available.

Examples

l: `[1, 2, 3]

list([1, 2, 3])  # convert an existing Array

first(l)  # 1 — O(1)

rest(l)   # `[2, 3] — O(1) shared tail

list?

Function

list? — phase 1 of the two-phase quarantine (2026-07-31 ruling): it is now THE List predicate. Until the List type shipped it was a courtesy alias of array?, so an Array argument ERRORS with a migration hint rather than silently flipping every legacy call's answer from true to false at exit 0 (the §911 class). One release later the Array arm relaxes to plain false. Call diagnostics (different branches may describe different overloads): • list? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:5305. These notes are not a complete signature or a stability guarantee. Manual §5.8 Lists (persistent cons lists); read with manual "5.8" Excerpt: be ambiguous. `is List`, `is_list(l)` and `list?(l)` test the type (`list?` no longer aliases `array?`; an Array argument errors with a migration hint). The accumulate idiom is `acc: cons(x, acc)` in a loop, then `reverse(acc)` — every step O(1).

ln

Function

ln(x)
Natural logarithm (log is the same function). Manual §22.1 Mathematical constants; read with manual "22.1" Excerpt: | `sqrt3` | 1.7320508075688772 | √3 | | `ln2` | 0.6931471805599453 | ln 2 | | `ln10` | 2.302585092994046 | ln 10 | | `im` | `i` (`complex(0, 1)`) | Imaginary unit. Shadowable like `pi`. Write `1 + im`, `(1 + im)^2` → `2i`, `2 * im`. Not a juxtaposed literal (`2im` is diagnosed) and not the loop index `i` |

ln10

Value

Built-in FLOAT value: 2.302585092994046 Manual §22.1 Mathematical constants; read with manual "22.1" Excerpt: | `ln2` | 0.6931471805599453 | ln 2 | | `ln10` | 2.302585092994046 | ln 10 | | `im` | `i` (`complex(0, 1)`) | Imaginary unit. Shadowable like `pi`. Write `1 + im`, `(1 + im)^2` → `2i`, `2 * im`. Not a juxtaposed literal (`2im` is diagnosed) and not the loop index `i` | ### Set constants

ln2

Value

Built-in FLOAT value: 0.6931471805599453 Manual §22.1 Mathematical constants; read with manual "22.1" Excerpt: | `sqrt3` | 1.7320508075688772 | √3 | | `ln2` | 0.6931471805599453 | ln 2 | | `ln10` | 2.302585092994046 | ln 10 | | `im` | `i` (`complex(0, 1)`) | Imaginary unit. Shadowable like `pi`. Write `1 + im`, `(1 + im)^2` → `2i`, `2 * im`. Not a juxtaposed literal (`2im` is diagnosed) and not the loop index `i` |

lnot

Symbol

=== ¬ (Glyph) === name: not words: not latex: neg, lnot category: logic codepoint: U+00AC meaning: ¬p — logical negation

local

Keyword

local NAME [:: Type] [= value] | local (a, b) = pair
Fresh mutable binding in the current lexical scope, sharing var semantics. Shadows outer names; earlier closures retain the previous cell. Supports annotations, multiple names and patterns. Initializers use =. Bare local x and local x :: T alias their explicit = _ forms, creating unreadable-until-filled cells with no default value. Each name in a batch may have its own annotation; an unannotated mutable cell may change value type after its first fill. Bare patterns require an initializer. Untyped holes explicitly refuse under --vm. Scope is sequential, without hoisting. Conflicts with global in the same function frame. At file/module level it binds in that unit, without changing exports. Reserved: guard the identifier as $local; [local x] remains a word list. Uses Axioma scope rules, not Julia whole-scope analysis. VM inherits var support and explicitly refuses unsupported nested blocks.

Examples

local count = 0
count += 1
println(count)

local ratio :: Float = 3
println(ratio)

log

Function

log(x)
Natural logarithm (alias of ln). Manual §4.1 Primitives; read with manual "4.1" Excerpt: | `Rational` | `1/3`, `rational(2, 6)` → `1/3` | Exact `p/q` on big integers, GCD-reduced — `/` on integers stays exact (`1/3 + 1/6` → `1/2`, never `0.4999…`); accessors `numerator(r)` / `denominator(r)` | | `Complex` | `complex(3, 4)` → `3.0 + 4.0i`; `im` → `i` | The **top of the numeric tower** — every other numeric type embeds, so `complex(3, 4) + 1/2` → `3.5 + 4i`. The unit is the shadowable builtin `im` (`complex(0, 1)`); write `1 + im`, `(1 + im)^2` → `2i`, `2 * im`. No juxtaposed literal: `2im` is diagnosed (same as `2x`). Full arithmetic incl. `^` (exact at integer exponents: `im^2` → `-1`) and unary minus; `sqrt`/`exp`/`log`/`sin`/`cos`/`abs`/`conjugate` all accept one. No ordering. Embedding is via `float64`, so exactness stops here. Coefficients use the same Float printer | | `String` | `"hello"`, `"unicode: ∀∃"`, `"\u{2203}"`, `r"raw \n"` | UTF-8; escape sequences + `r"..."` raw prefix — see [Strings](#strings--escape-sequences-raw-form-codepoint-builtins) | | `Boolean` | `true`, `false` | Classical two-valued | | `Byte` | `byte(0xFF)` | Single byte 0..255; distinct from `Integer`. See [Binary data](#binary-data--byte-and-bytes) |

log10

Function

Call diagnostics (different branches may describe different overloads): • log10 domain error: value must be positive • log10 requires a number • log10 requires exactly 1 argument Extracted library reference: evaluator/builtins.go:3720. These notes are not a complete signature or a stability guarantee.

log2

Function

Call diagnostics (different branches may describe different overloads): • log2 domain error: value must be positive • log2 requires a number • log2 requires exactly 1 argument Extracted library reference: evaluator/builtins.go:3739. These notes are not a complete signature or a stability guarantee.

log_component

Function

log_component() | log_component(name)
Read the script logging component name, or set a nonempty name for subsequent diagnostics. The setter returns none.

log_debug

Function

log_debug(message, [fields...])
Write a diagnostic at the debug level, subject to the current logging threshold. Extra fields may be a dictionary or key/value pairs. Returns none; does not change the program's result.

log_debugf

Function

log_debugf(format, values...)
Write a formatted diagnostic at the debug level. Formatting uses the same checked format verbs as stringf. Returns none.

log_enabled

Function

log_enabled(level)
Return whether the process logger enables this level: debug, info, warn, error or off.

log_error

Function

log_error(message, [fields...])
Write a diagnostic at the error level, subject to the current logging threshold. Extra fields may be a dictionary or key/value pairs. Returns none; does not change the program's result.

log_errorf

Function

log_errorf(format, values...)
Write a formatted diagnostic at the error level. Formatting uses the same checked format verbs as stringf. Returns none.

log_info

Function

log_info(message, [fields...])
Write a diagnostic at the info level, subject to the current logging threshold. Extra fields may be a dictionary or key/value pairs. Returns none; does not change the program's result.

log_infof

Function

log_infof(format, values...)
Write a formatted diagnostic at the info level. Formatting uses the same checked format verbs as stringf. Returns none.

log_level

Function

log_level()
Return the current diagnostic threshold as a lowercase String.

log_set_level

Function

log_set_level(level)
Set the process-wide diagnostic threshold; level is debug, info, warn, error or off. Returns none.

log_warn

Function

log_warn(message, [fields...])
Write a diagnostic at the warn level, subject to the current logging threshold. Extra fields may be a dictionary or key/value pairs. Returns none; does not change the program's result.

log_warnf

Function

log_warnf(format, values...)
Write a formatted diagnostic at the warn level. Formatting uses the same checked format verbs as stringf. Returns none.

logger

Value

Built-in DICTIONARY value: {DEBUG: "debug", ERROR: "error", INFO: "info", OFF: "off", WARN: "warn", component: builtin function: component, debug: builtin function: debug, debugf: builtin function: debugf, enabled: builtin function: enabled, error: builtin function: error, errorf: builtin function: errorf, info: builtin function: info, infof: builtin function: infof, level: builtin function: level, log: builtin function: log, set_level: builtin function: set_level, warn: builtin function: warn, warnf: builtin function: warnf} Manual §28.10 27.2 Ambient packages and the `python.*` namespace; read with manual "28.10" Excerpt: **Ambient native packages.** The builtin packages `math`, `datetime`, `io`, `logger`, and `os` are seeded into every session as modules — Lua-stdlib ergonomics: ```axioma

logically_equivalent

Function

logically_equivalent(expr1, expr2) - Check if two expressions are logically equivalent Uses biconditional tautology: φ ≡ ψ iff (φ ↔ ψ) is a tautology Example: logically_equivalent(func(p,q) [p => q], func(p,q) [(not p) or q]) → true Call diagnostics (different branches may describe different overloads): • logically_equivalent requires exactly 2 arguments: two boolean expressions Extracted library reference: evaluator/builtins.go:16990. These notes are not a complete signature or a stability guarantee.

logo_item

Function

Call diagnostics (different branches may describe different overloads): • logo_item: first argument must be an Integer index Extracted library reference: evaluator/builtin_logo.go:118. These notes are not a complete signature or a stability guarantee. Manual §13.37 Hidden slots, scanners, turtles, and concatenative extras; read with manual "13.37" Excerpt: HtDKP-in-Axioma Chapter 41. Logo selectors: `butfirst`, `butlast`, `logo_item`, `sentence`. ---

loop

Keyword

loop count [ body ] | loop item <- source [ body ] | loop count
  body
end | loop
  body
until condition
end
Repeat a body over a count, source, or condition. A count repeats that many times; a bound source supplies each value. repeat is another spelling. Both bracketed and end-terminated bodies are available in the beginner subset and the full language. Post-test: loop … until condition end. See manual "Loops".

Examples

loop 2
  println("again")
end

lor

Symbol

=== ∨ (Glyph) === name: or words: or latex: vee, lor category: logic codepoint: U+2228 meaning: p ∨ q — logical disjunction (canonicalizes to the `or` operator; MVL-dispatched)

lower

Function

lower(s)
Lowercase copy. A Character in, a Character out. Manual §4.5.6 Case mapping — `upper` / `lower` / `title` (and Julia aliases); read with manual "4.5.6" Excerpt: #### Case mapping — `upper` / `lower` / `title` (and Julia aliases) ```axioma upper("Hello") # → "HELLO"

lower?

Function

charPredicate wraps a rune classifier as a builtin accepting a Character or a one-character String. Call diagnostics (different branches may describe different overloads): • lower? requires exactly 1 argument Extracted library reference: evaluator/character.go:81. These notes are not a complete signature or a stability guarantee.

lowercase

Function

lowercase(s)
Julia spelling of lower. Same function, same answers. Manual §4.5.6 Case mapping — `upper` / `lower` / `title` (and Julia aliases); read with manual "4.5.6" Excerpt: `uppercase` / `lowercase` / `titlecase` are aliases of `upper` / `lower` / `title`. A Character in is a Character out (`uppercase('a')` is `'A'`). `uppercasefirst` is not `capitalize` (Julia leaves the rest of the string alone) and is not shipped.

lozenge

Symbol

=== ◇ (Glyph) === name: diamond words: possibly latex: Diamond, diamond, lozenge variants: ◊ ⋄ category: modal codepoint: U+25C7 meaning: ◇p — possibly p (alethic possibility; true in some accessible world)

lp

Function

lp(v) — Priest's Logic of Paradox constructor, the paraconsistent dual of K3. LP shares the strong-Kleene tables with Belnap/FDE but has NO gap, so an LP value IS a Belnap restricted to {true, both, false}; LP's paraconsistency comes from designating {true, both} (see `designated`). "neither" is rejected — LP has no truth-value gap (use belnap() for FDE). Call diagnostics (different branches may describe different overloads): • lp argument must be a string ("true", "both", "false"), boolean, or belnap • lp requires exactly 1 argument: "true", "both", or "false" Extracted library reference: evaluator/builtins.go:12715. These notes are not a complete signature or a stability guarantee. Manual §23.1.1 Truth tables — `tableform(func, [domain])`; read with manual "23.1.1" Excerpt: **multi-valued logic tables print**. Name a logic (`"boolean"`, `"kleene"`, `"belnap"`, `"lp"`, `"lukasiewicz"`, `"g3"`) to enumerate its canonical value set, or pass an explicit Array/Set for a general function table: ```axioma

ltrue

Symbol

=== ⊤ł (Glyph) === name: lukasiewicz_true latex: ltrue category: mvl codepoint: U+22A4 meaning: ⊤ł — Łukasiewicz Ł3 true (≡ lukasiewicz(1.0))

lukasiewicz

Function

lukasiewicz(x) for x in [0, 1] — canonical points have literals ⊤ł ½ł ⊥ł
Łukasiewicz Ł3 truth-value constructor — continuous truth in [0, 1] (and: min, or: max, not: 1−a, implies: min(1, 1−a+b)). The three canonical points are literals ⊤ł (1.0) / ½ł (0.5) / ⊥ł (0.0) (digraphs `ltrue `lhalf `lfalse; member Lukasiewicz.half; Lukasiewicz.values); other values need the constructor. Raw numbers in [0, 1] embed directly in operators (the fuzzy idiom: ½ł and 0.8). == compares raw values without clamping (lukasiewicz(1.0) == 2 is false). Only 1.0 is designated, so `if ½ł` takes the else-branch. Short alias: luke(x). NOT probability — a truth degree with a min/max algebra.

Examples

half: ½ł                        # ≡ lukasiewicz(0.5)

half and lukasiewicz(0.25)      # → 0.25ł (min)

half implies lukasiewicz(0.25)  # → 0.75ł (min(1, 1-0.5+0.25))

½ł and 0.8                      # → ½ł (raw numbers embed, clamped)

½ł == 0.5                       # → true (raw-value equality, no clamping)

lukasiewicz(0.73)               # constructor for non-canonical values

lukasiewicz_false

Symbol

=== ⊥ł (Glyph) === name: lukasiewicz_false latex: lfalse category: mvl codepoint: U+22A5 meaning: ⊥ł — Łukasiewicz Ł3 false (≡ lukasiewicz(0.0))

lukasiewicz_half

Symbol

=== ½ł (Glyph) === name: lukasiewicz_half latex: lhalf category: mvl codepoint: U+00BD meaning: ½ł — Łukasiewicz Ł3 half-true (≡ lukasiewicz(0.5))

lukasiewicz_true

Symbol

=== ⊤ł (Glyph) === name: lukasiewicz_true latex: ltrue category: mvl codepoint: U+22A4 meaning: ⊤ł — Łukasiewicz Ł3 true (≡ lukasiewicz(1.0))

luke

Function

luke …
Alternative spelling of lukasiewicz. See doc("lukasiewicz") for its meaning and call forms.

macro

Keyword

macro name(args) expression
Defines a compile-time macro that transforms code before evaluation (metaprogramming).

Examples

macro double(x) quasiquote(unquote(x) * 2)

double(21)

macroexpand

Function

macroexpand(macro_call)
Returns the expanded AST of a macro call for debugging, without evaluating it.

Examples

macro double(x) quasiquote(unquote(x) * 2)

macroexpand(double(10))  # <AST: (10 * 2)>

mag

Function

mag(quantity)
The display magnitude of a Quantity in its current Show unit (a number).

Examples

mag(5 * kg)                  # 5

mag(as_unit(5 * kg, gram))   # 5000

make_accessible

Function

make_accessible(model, from_world, to_world) - Add accessibility relation Example: make_accessible(km, "w1", "w2") Call diagnostics (different branches may describe different overloads): • first argument must be a Kripke model • from_world must be a string • make_accessible requires 3 arguments: model, from_world, to_world • to_world must be a string Extracted library reference: evaluator/builtins.go:17808. These notes are not a complete signature or a stability guarantee.

make_array

Function

Extracted library reference: evaluator/builtin_ast_construct.go:291. These notes are not a complete signature or a stability guarantee. Manual §19.10 19.10 Homoiconicity — building code as data; read with manual "19.10" Excerpt: | `make_lambda([params], body)` | `LambdaExpression` | | `make_array(...)` | `ArrayLiteral` (variadic or single `Array`) | | `make_tuple(...)` | `TupleLiteral` | | `make_set(...)` | `SetLiteral` | | `make_sequence(...)` | `SequenceExpression` (postfix sequence) |

make_boolean

Function

Call diagnostics (different branches may describe different overloads): • make_boolean requires 1 argument (Boolean) Extracted library reference: evaluator/builtin_ast_construct.go:103. These notes are not a complete signature or a stability guarantee. Manual §19.10 19.10 Homoiconicity — building code as data; read with manual "19.10" Excerpt: | `make_string(s)` | `StringLiteral` | | `make_boolean(b)` | `Boolean` | | `make_identifier(s)` | `Identifier` | | `make_infix(op, l, r)` | `InfixExpression` | | `make_prefix(op, x)` | `PrefixExpression` |

make_call

Function

Call diagnostics (different branches may describe different overloads): • make_call requires at least 1 argument (function, [args]) Extracted library reference: evaluator/builtin_ast_construct.go:185. These notes are not a complete signature or a stability guarantee. Manual §19.10 19.10 Homoiconicity — building code as data; read with manual "19.10" Excerpt: | `make_prefix(op, x)` | `PrefixExpression` | | `make_call(f, args)` | `CallExpression` | | `make_if(c, t, e?)` | `IfExpression` | | `make_lambda([params], body)` | `LambdaExpression` | | `make_array(...)` | `ArrayLiteral` (variadic or single `Array`) |

make_expr

Function

makeExprBuiltin rebuilds head(args) as an evaluatable AST node, choosing the node kind so that make_expr(head(e), operands(e)) == e for infix / prefix / postfix / call. Operands are auto-lifted (an Integer becomes an IntegerLiteral, etc.) via liftToASTExpr. make_expr("+", [1, 2]) -> '(1 + 2) (InfixExpression — recognized binary op) make_expr("!", [5]) -> '(5!) (PostfixExpression) make_expr("not", [p]) -> '(not p) (PrefixExpression) make_expr("add", [1, 2]) -> '(add(1, 2)) (CallExpression — head is not an operator) A head that isn't a recognized operator (for the given arity) builds a CallExpression, so any functor round-trips. Recognized operators are Axioma's standard set; an unrecognized operator-looking head builds a call (it will render the same under fullform but is reported here for honesty). Call diagnostics (different branches may describe different overloads): • make_expr "if" requires 2 or 3 operands (condition, consequence, [alternative]) • make_expr requires 2 arguments (head String, operands Array) Extracted library reference: evaluator/builtin_ast_algebra.go:224. These notes are not a complete signature or a stability guarantee. Manual §19.10.3 The `head` / `operands` / `make_expr` normal-form algebra; read with manual "19.10.3" Excerpt: #### The `head` / `operands` / `make_expr` normal-form algebra Mathematica unifies every expression under one shape — `head[args]`. Axioma renders its three surface notations (infix, prefix, postfix) and call syntax to that same normal form, and a small algebra reads and rebuilds any quoted expression **uniformly**, regardless of which syntax produced it.

make_float

Function

Call diagnostics (different branches may describe different overloads): • make_float requires 1 argument (Float or Integer) Extracted library reference: evaluator/builtin_ast_construct.go:70. These notes are not a complete signature or a stability guarantee. Manual §19.10 19.10 Homoiconicity — building code as data; read with manual "19.10" Excerpt: | `make_integer(n)` | `IntegerLiteral` | | `make_float(x)` | `FloatLiteral` | | `make_string(s)` | `StringLiteral` | | `make_boolean(b)` | `Boolean` | | `make_identifier(s)` | `Identifier` |

make_identifier

Function

Call diagnostics (different branches may describe different overloads): • make_identifier requires a String name and optional identifier AST context Extracted library reference: evaluator/builtin_ast_construct.go:117. These notes are not a complete signature or a stability guarantee. Manual §19.10 19.10 Homoiconicity — building code as data; read with manual "19.10" Excerpt: | `make_boolean(b)` | `Boolean` | | `make_identifier(s)` | `Identifier` | | `make_infix(op, l, r)` | `InfixExpression` | | `make_prefix(op, x)` | `PrefixExpression` | | `make_call(f, args)` | `CallExpression` |

make_if

Function

Call diagnostics (different branches may describe different overloads): • make_if requires 2-3 arguments (condition, consequence, [alternative]) Extracted library reference: evaluator/builtin_ast_construct.go:225. These notes are not a complete signature or a stability guarantee. Manual §19.10 19.10 Homoiconicity — building code as data; read with manual "19.10" Excerpt: | `make_call(f, args)` | `CallExpression` | | `make_if(c, t, e?)` | `IfExpression` | | `make_lambda([params], body)` | `LambdaExpression` | | `make_array(...)` | `ArrayLiteral` (variadic or single `Array`) | | `make_tuple(...)` | `TupleLiteral` |

make_infix

Function

===== Composite constructors ===== Call diagnostics (different branches may describe different overloads): • make_infix requires 3 arguments (operator, lhs, rhs) Extracted library reference: evaluator/builtin_ast_construct.go:142. These notes are not a complete signature or a stability guarantee. Manual §19.10 19.10 Homoiconicity — building code as data; read with manual "19.10" Excerpt: | `make_identifier(s)` | `Identifier` | | `make_infix(op, l, r)` | `InfixExpression` | | `make_prefix(op, x)` | `PrefixExpression` | | `make_call(f, args)` | `CallExpression` | | `make_if(c, t, e?)` | `IfExpression` |

make_integer

Function

===== Atomic constructors ===== Call diagnostics (different branches may describe different overloads): • make_integer requires 1 argument (Integer) Extracted library reference: evaluator/builtin_ast_construct.go:56. These notes are not a complete signature or a stability guarantee. Manual §19.10 19.10 Homoiconicity — building code as data; read with manual "19.10" Excerpt: |---|---| | `make_integer(n)` | `IntegerLiteral` | | `make_float(x)` | `FloatLiteral` | | `make_string(s)` | `StringLiteral` | | `make_boolean(b)` | `Boolean` |

make_lambda

Function

Call diagnostics (different branches may describe different overloads): • make_lambda requires 2 arguments (Array of param names, body) Extracted library reference: evaluator/builtin_ast_construct.go:249. These notes are not a complete signature or a stability guarantee. Manual §19.10 19.10 Homoiconicity — building code as data; read with manual "19.10" Excerpt: | `make_if(c, t, e?)` | `IfExpression` | | `make_lambda([params], body)` | `LambdaExpression` | | `make_array(...)` | `ArrayLiteral` (variadic or single `Array`) | | `make_tuple(...)` | `TupleLiteral` | | `make_set(...)` | `SetLiteral` |

make_prefix

Function

Call diagnostics (different branches may describe different overloads): • make_prefix requires 2 arguments (operator, operand) Extracted library reference: evaluator/builtin_ast_construct.go:166. These notes are not a complete signature or a stability guarantee. Manual §19.10 19.10 Homoiconicity — building code as data; read with manual "19.10" Excerpt: | `make_infix(op, l, r)` | `InfixExpression` | | `make_prefix(op, x)` | `PrefixExpression` | | `make_call(f, args)` | `CallExpression` | | `make_if(c, t, e?)` | `IfExpression` | | `make_lambda([params], body)` | `LambdaExpression` |

make_rebind

Function

make_rebind is the structural counterpart of Axioma's explicit cross-frame rebind statement. It accepts only an identifier target and returns an expression block so it composes with macros and the existing AST helpers. Call diagnostics (different branches may describe different overloads): • make_rebind requires an identifier AST and value syntax • make_rebind target must be an identifier AST Extracted library reference: evaluator/macro_context_builtins.go:40. These notes are not a complete signature or a stability guarantee. Manual §19.10.2 Macros and template hygiene; read with manual "19.10.2" Excerpt: identifier with a caller argument's context, pass that identifier AST as a witness. `make_rebind` constructs Axioma's explicit cross-frame write: ```axioma macro assign(name, value) make_rebind(name, value)

make_sequence

Function

Extracted library reference: evaluator/builtin_ast_construct.go:315. These notes are not a complete signature or a stability guarantee. Manual §19.10 19.10 Homoiconicity — building code as data; read with manual "19.10" Excerpt: | `make_set(...)` | `SetLiteral` | | `make_sequence(...)` | `SequenceExpression` (postfix sequence) | **Round-trip identity.** Constructed and quoted ASTs compare equal structurally:

make_set

Function

Extracted library reference: evaluator/builtin_ast_construct.go:307. These notes are not a complete signature or a stability guarantee. Manual §19.10 19.10 Homoiconicity — building code as data; read with manual "19.10" Excerpt: | `make_tuple(...)` | `TupleLiteral` | | `make_set(...)` | `SetLiteral` | | `make_sequence(...)` | `SequenceExpression` (postfix sequence) | **Round-trip identity.** Constructed and quoted ASTs compare equal structurally:

make_string

Function

Call diagnostics (different branches may describe different overloads): • make_string requires 1 argument (String) Extracted library reference: evaluator/builtin_ast_construct.go:89. These notes are not a complete signature or a stability guarantee. Manual §19.10 19.10 Homoiconicity — building code as data; read with manual "19.10" Excerpt: | `make_float(x)` | `FloatLiteral` | | `make_string(s)` | `StringLiteral` | | `make_boolean(b)` | `Boolean` | | `make_identifier(s)` | `Identifier` | | `make_infix(op, l, r)` | `InfixExpression` |

make_tuple

Function

Extracted library reference: evaluator/builtin_ast_construct.go:299. These notes are not a complete signature or a stability guarantee. Manual §19.10 19.10 Homoiconicity — building code as data; read with manual "19.10" Excerpt: | `make_array(...)` | `ArrayLiteral` (variadic or single `Array`) | | `make_tuple(...)` | `TupleLiteral` | | `make_set(...)` | `SetLiteral` | | `make_sequence(...)` | `SequenceExpression` (postfix sequence) |

man

REPL command

:man topic | :manual topic
Short REPL command for the embedded Manual. In source code use manual("topic"); bare man is not a source-level function alias. Searches locally without a model or network.

manual

Function

manual | manual <n> | manual "7.2" | manual word | manual "words to find" | manual(...) | manual/raw …
The Axioma manual, built into this binary — no checkout, no network, no model. Alone it prints the chapter list; a number opens a chapter (its own text and its sections) or a section ("7.2"); words search: headings first (one hit prints it, several are listed), then the text, each hit with its section, line number, and a snippet. The REPL commands :manual and :man are the same implementation. Headings inside code fences are ignored, so a literate-programming example is not a chapter. The markdown is rendered for the terminal — bold, italics, code spans, indented code blocks, headings, quotes — when stdout is a terminal, and printed with the markers stripped otherwise (AXIOMA_MANUAL_STYLE=rich|plain|raw overrides; NO_COLOR forces plain); manual/raw prints the source unchanged. Shadowable: a binding named manual wins. The oracle's unknown-word hint points here first (Offline:) before the AI door.

Examples

manual                         # the chapters

manual 7                       # §7 Set Theory & Comprehensions, with its sections

manual "7.2"                   # one section in full

manual comprehension           # search: headings, then text with line references

manual("refinement")           # call form, identical

manual/raw "7.1"               # the markdown source, unrendered — for copying

map

Function

map(function, collection)
Applies a function to each element of a collection (array, set, or tuple) and returns a new collection of the same type containing the results.

Examples

map(lambda x => x * 2, [1, 2, 3])   # Returns [2, 4, 6]

map(square, {1, 2, 3})              # Returns {1, 4, 9}

map_err

Function

map_err(f, wrapper) — on Err/Left, rewrap f(payload) with the same tag; on success, unchanged. None is left unchanged (no error payload — use or_else). Call diagnostics (different branches may describe different overloads): • map_err requires exactly 2 arguments: a function and a Result/Either (or Option) Extracted library reference: evaluator/builtin_option_helpers.go:94. These notes are not a complete signature or a stability guarantee. Manual §33.14.2 Railway helpers — `map_ok` / `and_then` / `or_else` / `is_*`; read with manual "33.14.2" Excerpt: | `map_ok(f, w)` | rewrap `f(payload)` as same tag | return `w` | | `map_err(f, w)` | return `w` | rewrap `f(payload)` on `Err`/`Left`; `Absent` unchanged | | `and_then(f, w)` | return `f(payload)` as-is | return `w` | | `or_else(f, w)` | return `w` | return `f(payload_or_none)` |

map_ok

Function

map_ok(f, wrapper) — on success, Some/Ok/Right(f(payload)); on failure, unchanged. Call diagnostics (different branches may describe different overloads): • map_ok requires exactly 2 arguments: a function and an Option/Result/Either Extracted library reference: evaluator/builtin_option_helpers.go:70. These notes are not a complete signature or a stability guarantee. Manual §33.14.2 Railway helpers — `map_ok` / `and_then` / `or_else` / `is_*`; read with manual "33.14.2" Excerpt: #### Railway helpers — `map_ok` / `and_then` / `or_else` / `is_*` Function **first**, wrapper **second** (same order as `map` / `filter`):

map_prototype

Function

map_prototype(mapping, prototype_name) - Map prototype through mapping Extracted library reference: evaluator/builtin_conceptual_mapping.go:138. These notes are not a complete signature or a stability guarantee.

mapcat

Function

appendMapBuiltin builds append_map / flatmap / mapcat: map fn over the collection, where fn returns a collection per element, and concatenate the results into one Array. Call diagnostics (different branches may describe different overloads): • mapcat requires 2 arguments: function and collection • mapcat: second argument must be an array, tuple, or set Extracted library reference: evaluator/scheme_extras.go:109. These notes are not a complete signature or a stability guarantee. Manual §22.7 Higher-order functions; read with manual "22.7" Excerpt: foldr(fn, init, coll) # right fold, fn(elem, acc) (also fold_right) append_map(fn, coll) # map then concatenate the per-element collections (flatmap / mapcat) for_each(fn, coll) # apply fn for side effects; returns none constantly(x) # → a function that ignores its args and returns x negate(pred) # → a predicate that logically negates pred (≠ set `complement`)

Markdown Documentation

Documentation

/**md ... */ comment blocks
Rich markdown documentation system with LaTeX math, cross-references, and code examples for literate programming

Examples

/**md\n# Function: calculate\n## Purpose\nCalculates something important\n## Parameters\n- x: number\n## Returns\nResult value\n*/

/**md\n# Mathematical Formula\n$f(x) = x^2 + 1$\n## Cross-References\n- {@link otherFunction}\n- {@concept RelatedConcept}\n*/

/**md\n## Example Usage\n```axioma\nresult: calculate(5)\nprintln(result)\n```\n*/

markov_chain

Function

Call diagnostics (different branches may describe different overloads): • all states must be strings • markov_chain requires 2 arguments: states, transition_matrix • states must be an array • transition probabilities must be numbers • transition_matrix must be an array of arrays • transition_matrix must be array of arrays Extracted library reference: evaluator/builtins.go:11725. These notes are not a complete signature or a stability guarantee.

match

Keyword

match expr with | pattern [when guard] => body ...
Pattern matching. Tries each pattern top-to-bottom. `case e | p => …` is the same matcher without a preposition (see `doc case`). Postfix `e match | p => …` is the same matcher with the value first. The first `|` after `with` (or after postfix `match`) is optional. Arm arrows: `=>` or `->` (same as lambdas). Supports literals, variables, arrays `[x, y | rest]` / `[h, ..t]`, tuples, constructors (`P { x, ..rest }`), hash-shape `{name, ..rest}` and `{name, age} exactly` (no extra keys — see `doc exactly`), or-/as-patterns, range membership (`| 1..9`), `in` membership (`| n in xs`), and user-function extractors (`| Mailbox(u, d)` when Mailbox returns Some/Absent). If no pattern matches and there is no wildcard `_`, returns `none` (a total read that found nothing — not `om`). `match/strict` makes a miss an Error. Evaluator-only: `--vm` refuses.

Examples

match x with | 0 => "zero" | n when n > 0 => "positive" | _ => "negative"

match pair with (1, x, 3) => x | _ => 0

match [1, 2, 3] with | [1 | rest] => rest

match n with | 1..9 => "digit" | _ => "other"

match n with | n in xs => n | _ => none

match h with | {name, age} exactly => name | {name, ..rest} => rest

match pt with | P { x, ..rest } => rest

match_pattern

Function

matchPatternBuiltin(pattern, subject) → Dictionary{name→AST} on match, else none. Call diagnostics (different branches may describe different overloads): • match_pattern requires 2 arguments (pattern, subject) • match_pattern: both arguments must be AST values Extracted library reference: evaluator/builtin_ast_pattern.go:65. These notes are not a complete signature or a stability guarantee. Manual §19.10.4 Pattern rewriting — `match_pattern` / `subst` / `replace_all` / `rules`; read with manual "19.10.4" Excerpt: #### Pattern rewriting — `match_pattern` / `subst` / `replace_all` / `rules` The algebra above is the substrate for **term rewriting** — Mathematica's `expr /. rule` and the heart of a computer-algebra system. Patterns reuse Axioma's existing `?x` variable syntax; no new lexer.

matching_pennies

Function

matching_pennies()
Return the built-in two-player zero-sum Matching Pennies game (Heads or Tails). Matching outcomes pay (1,-1); different outcomes pay (-1,1). These are fixed example models, not empirical predictions.

materially

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §29.3 End-form `try` / `catch` / `finally` / `end`; read with manual "29.3" Excerpt: `finally` is this cleanup clause. Aristotle's final cause is the four-cause infix `P teleologically Q` (with `materially` / `formally` / `efficiently`). `Acorn finally OakTree` is a SyntaxError with that hint. ### Constructing & re-raising

mathbb{C}

Symbol

=== ℂ (Glyph) === name: complexes words: complexes latex: mathbb{C} category: constant codepoint: U+2102 meaning: ℂ — the complex numbers

mathbb{N}

Symbol

=== ℕ (Glyph) === name: naturals words: naturals latex: mathbb{N} category: constant codepoint: U+2115 meaning: ℕ — the natural numbers

mathbb{Q}

Symbol

=== ℚ (Glyph) === name: rationals words: rationals latex: mathbb{Q} category: constant codepoint: U+211A meaning: ℚ — the rational numbers

mathbb{R}

Symbol

=== ℝ (Glyph) === name: reals words: reals latex: mathbb{R} category: constant codepoint: U+211D meaning: ℝ — the real numbers

mathbb{Z}

Symbol

=== ℤ (Glyph) === name: integers words: integers latex: mathbb{Z} category: constant codepoint: U+2124 meaning: ℤ — the integers

matrix

Function

matrix(rows) | matrix(flat_data, rows, columns)
Construct a numeric Matrix from nested rows, or from flat data and explicit dimensions. Integer and Rational cells remain exact; mixed Float arithmetic is floating point. Linear indexing and iteration visit cells in row-major order. Use shape(m) for dimensions; len(m) is refused. The * operator is matrix multiplication; dotted operators and dotted function calls act elementwise. See manual "Matrices".

max

Function

max(values...)
Largest of the arguments, or of a single array/set/tuple. Manual §28.5.4 Aggregates — `GROUP BY`, `HAVING`, `COUNT/SUM/AVG/MIN/MAX`; read with manual "28.5.4" Excerpt: #### Aggregates — `GROUP BY`, `HAVING`, `COUNT/SUM/AVG/MIN/MAX` ```axioma # Single-column GROUP BY with COUNT

max_by

Function

Extracted library reference: evaluator/builtins.go:22800. These notes are not a complete signature or a stability guarantee. Manual §5.8 Lists (persistent cons lists); read with manual "5.8" Excerpt: with Arrays), so sets of lists walk deterministically and `sort_by`/`min_by`/`max_by` order them the way a reader expects. **Why a List answers no message verbs.** `a push 4` is an imperative sentence: it commands a *place* — something with identity over time — to

may

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §3.1 Bindings — one canonical form; read with manual "3.1" Excerpt: the single-name rule), and evaluates to the **tuple** of all assigned values, so the REPL echoes `(1, 2, 3)`. A multi-assignment may also **open a bracket block** — `if val > best then [ best, at: val, idx ]` — the leading `name, name` run is recognized as a statement, not array elements, so branch bodies can start with a parallel update (both the

mean

Function

mean(data, [axis])
Arithmetic mean of an array, tuple, or matrix (optional axis for a matrix). Manual §5.6 Collection method calls; read with manual "5.6" Excerpt: `reduce(f, init, xs)`. Other registered methods put the receiver first: `push`, `append`, `reverse`, `rev`, `sort`, `sorted`, `sum`, `prod`, `mean`, `min`, `max`, `length`, `len`, `size`, `count`, `first`, `last`, `rest`, `nth`, `contains`, `collect`, `elements`, `each`, `transpose`, and `shape`. Builtin domain and mutation rules are unchanged: `m.length()` still refuses a

median

Function

median(data)
Middle value of a sorted array, tuple, or matrix (even count averages the two middle). Manual §12.16 Map / Filter / Reduce; read with manual "12.16" Excerpt: mean((2, 4, 6, 8)) # 5 (array, tuple, or matrix; average is an alias) median((3, 1, 2)) # 2 (even count averages the two middle values) ``` ### Enumerable verbs

member

Function

member(collection, target)
SML List.member-shaped name — exact alias of contains (membership / substring). Manual §22.8 List & string helpers; read with manual "22.8" Excerpt: rev([1, 2, 3]) # → [3, 2, 1] (SML List.rev; exact alias of reverse) member([1, 2, 3], 2) # → true (SML-shaped name; exact alias of contains) # member(collection, target) — Axioma order, not SML List.member(element, list) char_alphabetic?("a") # → true (also char_numeric? / char_whitespace?) ```

membership

Function

Call diagnostics (different branches may describe different overloads): • first argument must be a fuzzy set • membership requires 2 arguments: fuzzy_set, value • value must be a number or string Extracted library reference: evaluator/builtins.go:13035. These notes are not a complete signature or a stability guarantee. Manual §7.3 ISO membership generators — `{x : x ∈ U, P(x)}`; read with manual "7.3" Excerpt: ### ISO membership generators — `{x : x ∈ U, P(x)}` Real ISO/British texts put membership in the binder slot. `in` / `∈` is accepted as a generator alias for `<-` under one rule: **the clause

memoize

Function

memoize(f)
Wraps a function so repeated calls with equal arguments return a cached result instead of recomputing. Arguments are keyed by VALUE (the same keying sets and dictionaries use), so two calls hit the cache exactly when their arguments are ==. Errors are never cached. The companion to `lazy`: `lazy` defers one expression, memoize defers-and-caches every call of a function.

Examples

fast: memoize(slow)

fast(9)     # computes

fast(9)     # cached — slow() is not called again

fast(4)     # a different argument computes once, then caches

menu

Function

Call diagnostics (different branches may describe different overloads): • menu items must be a dictionary Extracted library reference: evaluator/builtins.go:15252. These notes are not a complete signature or a stability guarantee. Manual §25.8 Reading a value — `read_integer()` / `read_float()` / `read_string()`; read with manual "25.8" Excerpt: `input_number`, `prompt`, `choice`, `confirm`, and `menu` share the same persistent stdin reader, so sequential calls consume successive lines under a pipe. The token readers share it too.

metalogical

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §16.7 Grounding & Kind as first-class values; read with manual "16.7" Excerpt: `grounding(...)` and `truth_kind(...)` return typed values, not bare strings. A `Grounding` is **ordered** (the ladder above); a `Kind` is a **flat** five-member set (`logical` / `empirical` / `transcendental` / `motive` / `metalogical`). Both coerce against a plain String, so existing `== "axiom"` comparisons keep working. ```axioma relation edge(x, y)

methods

Function

methods(Integer) | methods("Integer") | methods()
The Ruby/Smalltalk-vocabulary spelling of functions() — an exact alias (same implementation, byte-identical results): the curated builtin catalog for a card-bearing type. `functions` is the canonical name. For a value, go through its type: methods(type(x)) — type(x) is the DataType Concept.

Examples

methods(Integer)           # ≡ functions(Integer)

methods(type(5))           # the catalog for a value's type

middle_terms

Function

middle_terms(taxonomy, S, P)
Leibniz's inventive-logic use from the 1666 Dissertatio: given two terms of a true universal affirmative (every S is P), returns the intervening middle terms — every M with S ⊆ M ⊆ P, i.e. each M that completes a Barbara syllogism between them. Most-specific middle first; empty when the universal does not hold.

Examples

middle_terms(porphyry, human, body)   # ["animal", "living"]

min

Function

min(values...)
Smallest of the arguments, or of a single array/set/tuple. Manual §28.5.4 Aggregates — `GROUP BY`, `HAVING`, `COUNT/SUM/AVG/MIN/MAX`; read with manual "28.5.4" Excerpt: #### Aggregates — `GROUP BY`, `HAVING`, `COUNT/SUM/AVG/MIN/MAX` ```axioma # Single-column GROUP BY with COUNT

min_by

Function

Extracted library reference: evaluator/builtins.go:22797. These notes are not a complete signature or a stability guarantee. Manual §5.8 Lists (persistent cons lists); read with manual "5.8" Excerpt: with Arrays), so sets of lists walk deterministically and `sort_by`/`min_by`/`max_by` order them the way a reader expects. **Why a List answers no message verbs.** `a push 4` is an imperative sentence: it commands a *place* — something with identity over time — to

minus?

Function

numericSignPredicate builds a 1-arg predicate over a number's sign. A non-number argument yields false (matching the existing positive/negative/ even family, which return false rather than erroring on a wrong type). Call diagnostics (different branches may describe different overloads): • minus? requires exactly 1 argument Extracted library reference: evaluator/scheme_predicates.go:56. These notes are not a complete signature or a stability guarantee. Manual §22.6.1 Scheme/Lisp-style predicates (`?` suffix); read with manual "22.6.1" Excerpt: zero?(0) # true plus?(5) # true (strictly positive) positive?(5) # true minus?(-1/3) # true (strictly negative) negative?(-5) # true even?(4) # true odd?(3) # true # type predicates (join number?/integer?/string?/boolean?/null?/pair?/array?…)

mixed_strategy

Function

Call diagnostics (different branches may describe different overloads): • mixed_strategy requires 2 arguments: player_index, probabilities • player index must be an integer • probabilities must be an array • probabilities must be numbers Extracted library reference: evaluator/builtins.go:13570. These notes are not a complete signature or a stability guarantee.

mod

Operator

number mod number
Modulo (remainder) infix keyword — a same-line soft keyword aliasing the `%` operator. Produces a byte-identical AST to `%`, so the result and precedence (PRODUCT — binds with `*`, tighter than `+`) are identical. Longhand aliases: `modulo`, `remainder`. Prefix builtins: `mod(a, b)` (the same spelling as a call) and `remainder(a, b)` — `mod(a, b)` hands its operands to the `%` operator unchanged, so call and operator cannot answer differently. FLOOR-mod: the remainder takes the sign of the DIVISOR, on integers and floats alike, so `-23 mod 7` is 5 and not -2. As a soft keyword, `mod` is only an operator between two expressions on the same line; `mod: 5` is still an ordinary binding and `mod` remains a legal variable / hash-key name — a local binding shadows the builtin.

Examples

100 mod 7          # Returns 2

100 modulo 7       # Returns 2    (longhand)

100 % 7            # Returns 2    (symbolic equivalent)

6 * 5 mod 7        # Returns 2    (left-assoc with *)

mod(100, 7)        # Returns 2    (prefix builtin, keyword spelling)

remainder(100, 7)  # Returns 2    (prefix builtin, long spelling)

-23 mod 7          # Returns 5    (floor-mod: sign of the divisor)

mod(-23, 7)        # Returns 5    (the call agrees, by construction)

mod_inverse

Function

mod_inverse(a, m)
Computes the modular multiplicative inverse of a modulo m, such that (a * x) % m == 1. Returns the inverse integer if it exists, or none if a and m are not coprime.

Examples

mod_inverse(3, 11)   # Returns 4

mod_inverse(4, 8)    # Returns none

modal_grade

Function

modal_grade(relation, args...)
Bridges Kant's modality-of-judgment triad to the grounding ladder: axiom/theorem → "apodictic" (necessary), postulate/datum → "assertoric" (actual), conjecture/hypothesis → "problematic" (possible). Other groundings pass through.

Examples

axiom claim("bedrock")

modal_grade("claim", "bedrock")   # "apodictic"

modal_syllogism

Function

modal_syllogism(major, minor, conclusion [, "aristotelian"|"boolean"])
Aristotle's MODAL syllogistic (Prior Analytics I.8–22), decided by a constant-domain DE RE Kripke semantics (rigid individuals; necessity scopes the predicate over all worlds with the subject at the actual world; possibility ampliates the subject). Each proposition is plain (assertoric) or wrapped in necessarily(...) / possibly(...). The procedure is sound, complete, and decidable, collapses onto valid_syllogism when every modality is assertoric, and reproduces the first-figure apodeictic asymmetry — Barbara LXL valid, XLL invalid (the 'two Barbaras', I.9) — and possibility Barbara (QQQ) via ampliation. Honest boundary: the de re reading declines second-figure apodeictic moods that rely on □E-conversion (e.g. Cesare LXL), marking where Aristotle's text outruns any uniform de re semantics. Returns {valid, form_valid, mood, name, figure, modal_pattern, conclusion_modality, warranted_modality, reading, note, counterexample}.

Examples

modal_syllogism(necessarily(every M is P), every S is M, necessarily(every S is P))   # LXL — valid (Aristotle)

modal_syllogism(every M is P, necessarily(every S is M), necessarily(every S is P))   # XLL — invalid (the asymmetry)

modal_syllogism(possibly(every M is P), possibly(every S is M), possibly(every S is P))   # possibility Barbara — valid

model

Keyword

[ model | expression1, expression2, ... ]
Visualizes the evaluation of a block of expressions on the knowledge lifecycle or dependency graph.

Examples

[ model |
  relation mortal(x)
  axiom mortal("socrates")
  human(X) <== mortal(X)
]

model_set

Function

model_set(sentences) — check Hintikka's downward-saturation conditions (the book's model sets, SL p. 44 / QL p. 66). Takes an array of formula strings or one multiline string; returns {ok, violations}. Example: model_set(["p ∨ q", "q", "¬p", "∃xFx", "Fa"]) Call diagnostics (different branches may describe different overloads): • model_set requires 1 argument: array of sentences (or multiline string) • model_set: argument must be an array of strings or a string • model_set: sentences must be strings Extracted library reference: evaluator/builtins.go:17523. These notes are not a complete signature or a stability guarantee.

model_system

Function

model_system(sets, alternatives [, system]) — Hintikka model SYSTEMS (ch. 4 pp. 81–87, ch. 5): a family of model sets + alternativeness. Checks frame properties (T reflexive · B +symmetric · S4 +transitive · S5 equivalence · D serial for deontic O/P), per-set saturation, and the transfer conditions C.□ C.◇ C.¬□ C.¬◇ / C.O C.P C.¬O C.¬P, plus the ch. 5 domain-inclusion check when quantifiers appear. Example: model_system({w1: ["◇p", "¬p"], w2: ["p"]}, [["w1","w1"], ["w1","w2"], ["w2","w2"]], "T") Call diagnostics (different branches may describe different overloads): • model_system requires 2-3 arguments: sets hash, alternatives array [, system] • model_system: system must be a string (T, B, S4, S5, or D) Extracted library reference: evaluator/builtins.go:17573. These notes are not a complete signature or a stability guarantee.

modern_to_frege

Function

modern_to_frege(modern_formula)
Converts modern symbolic logic to Begriffsschrift notation, enabling study of how contemporary formulas would appear in Frege's original 1879 system. Includes parsing of common logical operators.

Examples

frege_form: modern_to_frege("A → B")  # Convert to Begriffsschrift

quantified: modern_to_frege("∀x P(x)")  # Convert quantification

print(frege_format(frege_form.Converted))  # Display Frege notation

module

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §6.8 End-form blocks — `if`, `while`, `for`, `loop`, `repeat`, `function`, `module` … `end`; read with manual "6.8" Excerpt: ### End-form blocks — `if`, `while`, `for`, `loop`, `repeat`, `function`, `module` … `end` A second, keyword-terminated spelling of control-flow, function, and in-file module bodies (2026-08-27; `module` 2026-08-29; `loop`/`repeat` 2026-08-30). The

module?

Function

Call diagnostics (different branches may describe different overloads): • module? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

modules

Function

modules([filter])
Namespace names, sorted: modules() for every one, or a filter — "ambient" (bare-reachable), "import" (import-only), "ffi" (language-prefixed). Manual §34 Modules; read with manual "34" Excerpt: ## 34. Modules A file **is** a module. Optional `module Name` (or `module Math.Linear.Algebra`) at the top names it; the file path is what `import` loads.

modulo

Operator

number modulo number
Longhand alias of the `mod` modulo keyword — aliases the `%` operator with identical AST, result, and precedence. Prefix builtins: `mod(a, b)` / `remainder(a, b)`. There is no `modulo(a, b)` call form; the prefix spelling of this keyword is `mod(a, b)`.

Examples

100 modulo 7       # Returns 2

100 mod 7          # Returns 2    (short form)

100 % 7            # Returns 2    (symbolic)

mod(100, 7)        # Returns 2    (prefix builtin)

modus_ponens

Keyword

Named inference-rule form: from P and P implies Q, infer Q. This names the inference expression; proof certification remains a separate check.

modus_tollens

Keyword

Named inference-rule form: from P implies Q and not Q, infer not P. The chosen logic must support this rule; it is not unrestricted in every multivalued logic.

money

Function

money(amount, [currency])
A number (or money string) to an exact Money; currency defaults to "$". Manual §4.7.1 Arithmetic on `Money` / `Percent`; read with manual "4.7.1" Excerpt: #### Arithmetic on `Money` / `Percent` ```axioma $100 + $25 # → $125

money?

Function

Call diagnostics (different branches may describe different overloads): • money? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

most_probable

Function

most_probable(kb) - Get the most probable formula Example: most_probable(kb) → formula with highest probability Call diagnostics (different branches may describe different overloads): • argument must be a probabilistic logic KB • most_probable requires 1 argument: kb Extracted library reference: evaluator/builtins.go:19266. These notes are not a complete signature or a stability guarantee.

mu

Symbol

=== μ (Glyph) === name: mu category: greek codepoint: U+03BC meaning: Greek letter mu (lowercase)

multinomial

Function

multinomial([count1, count2, ...])
Distinct orderings of a multiset given its repeat counts: (Σaᵢ)! / ∏ aᵢ!. Leibniz's 'variations of order with repeated things' (De Arte Combinatoria 1666, Problem VI — his hexameter counts).

Examples

multinomial([1, 4, 4, 2])   # 34650 — MISSISSIPPI

multinomial([2, 1])         # 3 — AAB, ABA, BAA

multiply

Function

multiply(x, y) OR multiply(x, y, z)
Dual-mode function: 2 args returns x*y, 3 args checks if x*y=z. Supports both function symbols and predicates in FOL.

Examples

multiply(4, 5)     # Returns 20 (function mode)

multiply(4, 5, 20) # Returns true (predicate mode)

multiply(3, 4, 10) # Returns false (predicate mode)

exists x,y in Numbers: multiply(x, y) == 12

must

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §3.2 Binding model at a glance; read with manual "3.2" Excerpt: **Why this shape (and not `:=`).** Axioma is a teaching and multiparadigm language: `:` is the short Rebol-style binder; `=` must read as textbook mathematics (`B = A union C`, `area(r) = pi * r * r`) without a second “assignment only” operator. Unifying introduction and update under find-or-update is what makes accumulators work (`total: total + n` inside a

must_not

Keyword

Deontic relation expressing prohibition for an agent in the selected deontic model. See doc "forbidden" and doc "deontic_model".

mut

Keyword

let mut NAME = value | type P = struct mut {x:: Float} | type P = record mut {x:: Float}
Marks a `let mut NAME = value` binding — a second spelling of `var` (the Rust word). After struct or its record alias in a type declaration, mut aliases mutable: closed checked fields with reference identity, using the same struct AST. Braces, end bodies and generic parameters all work; without a modifier either spelling is immutable. This is not a Dictionary schema. Struct declarations remain evaluator-only; the VM refuses them. See doc struct and doc record. RESERVED: a bare `mut: 99` is a SyntaxError; guard as `$mut`. Not a borrow qualifier (`&mut` is refused) and not a parameter marker.

Examples

let mut x = 5
x: 6

let mut (a, b) = pair

$mut: 99   # the name, guarded

mutable

Keyword

let mutable NAME = value | type P = struct mutable {x:: Float} | type P = record mutable {x:: Float}
Marks a `let mutable NAME = value` binding — a second spelling of `var` (the F# word). After struct or its record alias in a type declaration, mutable and mut select the same closed checked fields with reference identity, using the existing struct AST. Braces, end bodies and generic parameters all work; without a modifier either spelling is immutable. This is not a Dictionary schema. Struct declarations remain evaluator-only; the VM refuses them. See doc struct and doc record. RESERVED: guard as `$mutable` to use it as a name. The let form is the same node as `let mut` and `var`.

Examples

let mutable x = 5
x: 6

nCr

Function

Call diagnostics (different branches may describe different overloads): • choose arguments must be integers • choose arguments too large • choose requires exactly 2 arguments (n, k) Extracted library reference: evaluator/builtins.go:22176. These notes are not a complete signature or a stability guarantee.

nPr

Function

Call diagnostics (different branches may describe different overloads): • permutations arguments must be integers • permutations arguments too large • permutations requires exactly 2 arguments (n, k) Extracted library reference: evaluator/builtins.go:22265. These notes are not a complete signature or a stability guarantee.

na

Value

Built-in NA value: na Manual §4.2 Missing data cells: `na` and `Na`; read with manual "4.2" Excerpt: ### Missing data cells: `na` and `Na` `na` is the missing-cell value; `Na` is its programming type. `NA` remains a compatibility alias of the same value. Values and DataFrames display it as `na`;

Naming Conventions

Concept

ConceptName (uppercase) | objectName (lowercase)
Axioma enforces naming conventions: concepts start with uppercase, objects with lowercase

Examples

concept Person          # Concept (uppercase)

john: a Person { name: "John" }  # Object (lowercase)

concept Stock           # Valid concept name

apple: a Stock { price: 150 }         # Valid object name

nan?

Function

--- float-domain predicates ---------------------------------------------- Call diagnostics (different branches may describe different overloads): • nan? requires exactly 1 argument Extracted library reference: evaluator/scheme_extras.go:443. These notes are not a complete signature or a stability guarantee. Manual §22.6.1 Scheme/Lisp-style predicates (`?` suffix); read with manual "22.6.1" Excerpt: # float domain (`inf` / `nan` are builtins producing ±∞ / NaN floats) # `is_X` ≡ `X?` — both spellings, same function (`is_nan` ≡ `nan?`) nan?(nan) # true is_nan(nan) # true infinite?(inf) # true is_infinite(inf) # true finite?(3.14) # true is_finite(3.14) # true

nand

Function

nand(p, q, ...) | nand(collection)   (glyph infix: p ⊼ q; digraphs `nand / `barwedge)
NAND — the Sheffer stroke ¬(p ∧ q), one of the two singly functionally-complete connectives (Post): ¬, ∧, ∨ are all definable from nand alone. N-ary like Mathematica's Nand: nand(a, b, c) = ¬(a ∧ b ∧ c); a single Array/Set/Tuple folds the collection (nand([]) → false, the negated ∧ identity). MVL-dispatched per operand pair (Belnap > G3 > Ł3 > K3 > Boolean). Not a keyword — a local `nand: func(...)` binding shadows the builtin.

Examples

nand(true, true)     # → false

true ⊼ false         # → true (glyph infix)

(p ⊼ p) == (not p)   # ¬ from nand alone

nand(true, true, false)  # → true (n-ary)

nash_equilibrium

Function

Call diagnostics (different branches may describe different overloads): • argument must be a game • nash_equilibrium requires 1 argument: game Extracted library reference: evaluator/builtins.go:13379. These notes are not a complete signature or a stability guarantee.

natural_join

Function

Call diagnostics (different branches may describe different overloads): • natural_join requires exactly 2 arguments Extracted library reference: evaluator/builtins.go:7758. These notes are not a complete signature or a stability guarantee.

naturals

Value

Built-in SET value: {1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, 100} Manual §5.10.1 Ellipsis sets — textbook `{2, 4, ..., 100}` / `{2, 4, 6, ...}`; read with manual "5.10.1" Excerpt: 1,000,000 elements. For an *ordered* infinite sequence use this form or `infinite_set("naturals")` — a bare `naturals` / `ℕ` generator enumerates unordered. **Pulling elements.** `first(s)` is the first term; the ordinals

ndim

Function

Call diagnostics (different branches may describe different overloads): • argument must be tensor, matrix, or array • ndim requires exactly 1 argument Extracted library reference: evaluator/builtins.go:14479. These notes are not a complete signature or a stability guarantee. Manual §5.14 Matrices, tensors & dataframes; read with manual "5.14" Excerpt: t: tensor([[[1, 2], [3, 4]], [[5, 6], [7, 8]]]) # rank-3 from nesting shape(t) # → [2, 2, 2] ; ndim(t) → 3 tensor([2, 3], 7) # shape + fill → 2×3 of 7s tensor_reshape(tensor([1, 2, 3, 4, 5, 6]), [2, 3]) # → 2×3 squeeze(tensor([[1, 2, 3]])) # drop size-1 axes → vector [3]

ne

Symbol

=== ≠ (Glyph) === name: not_equal latex: neq, ne category: logic codepoint: U+2260 meaning: a ≠ b — not equal (canonicalizes to !=)

nearest_prototype

Function

nearest_prototype(space, point) - Find nearest prototype Extracted library reference: evaluator/builtin_conceptual.go:493. These notes are not a complete signature or a stability guarantee.

necessarily

Modal Logic

necessarily expression
Modal necessity operator (□P). Expresses that a proposition is necessarily true in all possible worlds.

Examples

necessarily true

necessarily (2 + 2 == 4)

logical_truth: necessarily (A implies A)

neg

Function

neg(callable) | neg(number)
Exact alias of `negate` — Miranda's short spelling, and the natural abbreviation. Same two arms, split by argument type: a CALLABLE yields a predicate that answers the opposite; a NUMBER is arithmetic negation, byte-identical to `-x`. The two spellings share one implementation, so they cannot drift. Distinct from the backtick digraph `` `neg ``, which is logical ¬.

Examples

neg(33)               # → -33

abs(neg(33))          # → 33      (Miranda §1.3.2)

neg(odd?)(4)          # → true    (the combinator)

neg(negate(42))       # → 42

negate

Function

negate(callable) | negate(number)
Two meanings, split by argument TYPE — they cannot be confused because a callable is never a number. Given a CALLABLE, returns a predicate that answers the opposite: negate(pred)(x) is true exactly when pred(x) is falsy. It reads the TRUTH of the result, so it always returns a Boolean. This is distinct from the set operation `complement`, which takes a set rather than a predicate. Given a NUMBER, returns its arithmetic negation — byte-identical to the prefix `-x`, and covering the whole tower: Integer (big-aware), Float, Rational, Byte (widening to Integer), Complex, and symbolic expressions. Type is preserved, and negate is an involution: negate(negate(x)) is x. The numeric arm was added July 2026; before it every number was an error, so the overload changes no existing program.

Examples

isEven: negate(odd?)   isEven(4)   # → true   (the combinator)

negate(3)              # → -3      (the arithmetic negation)

negate(-3/4)           # → 3/4     — exact, stays Rational

negate(2.5)            # → -2.5

negate(negate(42))     # → 42      — an involution

signum(negate(n)) == negate(signum(n))   # → true for every n

neg(33)                # → -33     (short / Miranda spelling)

negative

Function

Call diagnostics (different branches may describe different overloads): • negative requires exactly 1 argument Extracted library reference: evaluator/builtins.go:4580. These notes are not a complete signature or a stability guarantee. Manual §22.6 Predicates; read with manual "22.6" Excerpt: positive(5) # true negative(-3) # true ``` #### Scheme/Lisp-style predicates (`?` suffix)

negative?

Function

numericSignPredicate builds a 1-arg predicate over a number's sign. A non-number argument yields false (matching the existing positive/negative/ even family, which return false rather than erroring on a wrong type). Call diagnostics (different branches may describe different overloads): • negative? requires exactly 1 argument Extracted library reference: evaluator/scheme_predicates.go:56. These notes are not a complete signature or a stability guarantee. Manual §22.6.1 Scheme/Lisp-style predicates (`?` suffix); read with manual "22.6.1" Excerpt: positive?(5) # true minus?(-1/3) # true (strictly negative) negative?(-5) # true even?(4) # true odd?(3) # true # type predicates (join number?/integer?/string?/boolean?/null?/pair?/array?…) list?([1, 2, 3]) # true procedure?(func(x) [x]) # true

negative_middle_terms

Function

negative_middle_terms(taxonomy, S, P)
The negative half of the middle-term finder (DAC 1666: 'these become middle terms for proving the negative'): every M with `every S is M` and `no M is P` — each M completes a Celarent proving `no S is P`.

Examples

negative_middle_terms(porphyry, human, stone)

neighbors

AI Function

neighbors(graph, node_id)
Returns an array of neighboring nodes connected to the specified node.

Examples

neighbors(g, "A")

neighbors(graph, "node1")

neq

Symbol

=== ≠ (Glyph) === name: not_equal latex: neq, ne category: logic codepoint: U+2260 meaning: a ≠ b — not equal (canonicalizes to !=)

new

Keyword

InstanceName: ConceptName new
Instantiates an object from a concept template. Creates an instance with default property values defined in the concept, which can then be dynamically modified.

Examples

myCar: Car new

myCar.brand = "Tesla"

next

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §5.4 Lists and recursion — `[h | t]`; read with manual "5.4" Excerpt: for a full doubly linked list with O(1) unlink from a bare node handle. Note that `next` is a reserved word, so either spell the field `lnk`/`nxt` or keep the conventional name with the guarded form `$next`, which stores the key bare: ```axioma

next_solution

Function

next_solution(stream)
Pull one SolutionStream answer as {done: false, value: answer}; finite exhaustion returns {done: true, value: none}. Errors propagate and remain observable on subsequent pulls. Query fields status and complete distinguish exhaustion from a prefix or cancellation.

ninth

Function

ordinalBuiltin builds a 1-argument ordinal accessor (second..tenth) backed by nthElement, so the whole Racket-style family shares one implementation and works on finite collections and infinite sets alike. Call diagnostics (different branches may describe different overloads): • ninth requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1528. These notes are not a complete signature or a stability guarantee.

nip

Function

Call diagnostics (different branches may describe different overloads): • argument to nip must be a stack • nip requires 1 argument: stack • nip requires at least 2 items on stack Extracted library reference: evaluator/builtins.go:12183. These notes are not a complete signature or a stability guarantee. Manual §18.2 Stack-shuffle operations; read with manual "18.2" Excerpt: | `drop(s)` | `a →` | Discard top | | `nip(s)` | `a b → b` | Drop second | | `tuck(s)` | `a b → b a b` | Copy top below second | | `pick(s, i)` | `→ … x` | Copy the element at index `i` (0 = top) to the top | | `roll(s, i)` | `→ … x` | Move the element at index `i` to the top |

no

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §28.9.3 Object handles — large values, no deep copy; read with manual "28.9.3" Excerpt: #### Object handles — large values, no deep copy For values too big to want to marshal whole, the `axioma.*` namespace exposes lazy access:

noi

Reserved vocabulary

Reserved vocabulary with no dedicated parser implementation in this build. It is not a usable standalone form. Use doc "discover" for the implemented discovery interface, and manual for supported language forms. Recognition of a name is not a claim that its intended feature is implemented.

nominally

Keyword

Nominal-definition qualifier, concerning the meaning of a name; contrasted with the really qualifier for real definitions. This is philosophical definition vocabulary, not an empirical truth test.

nondenoting

Function

Call diagnostics (different branches may describe different overloads): • nondenoting() requires exactly 1 argument: concept Extracted library reference: evaluator/builtins.go:5774. These notes are not a complete signature or a stability guarantee.

none

Keyword

none
Absence (type None). The only spelling of the absent value. Distinct from `om` (undetermined). Falsy. Displays as `none`. `null` and `nothing` are retired — write `none`. Option's empty tag is `Absent` (truthy). `None == none` is false (type vs value, like `Integer == 5`).

Examples

x: none

none == om          # false

none is None        # true

None == none        # false

if none then 1 else 0   # 0

str(none)           # "none"

none?

Function

none?(predicate, collection)
True iff the predicate holds for no element (vacuously true on empty). Manual §12.18 List-library verbs (Haskell / OCaml); read with manual "12.18" Excerpt: `separate` is `partition` under a different name (`partition` is reserved for concept partitions). `all?`/`any?`/`none?` short-circuit and read correctly in `if`. The nine verbs above `unfold` work under `--vm` (byte-identical). **`unfold` is

nor

Function

nor(p, q, ...) | nor(collection)   (glyph infix: p ⊽ q; digraphs `nor / `barvee)
NOR — the Peirce arrow (Quine's dagger) ¬(p ∨ q), the other singly functionally-complete connective. The collection form IS Wittgenstein's N-operator (TLP 5.502): nor(props) is true iff every proposition in the collection is false — joint denial (nor([p]) = ¬p; nor([]) → true). MVL-dispatched per operand pair. Not a keyword — a local `nor: func(...)` binding shadows the builtin.

Examples

nor(false, false)    # → true

true ⊽ false         # → false (glyph infix)

nor([false, false, false])  # → true (Wittgenstein's N)

(p ⊽ p) == (not p)   # ¬ from nor alone

norm

Function

Call diagnostics (different branches may describe different overloads): • first argument to norm must be a matrix • norm requires 1 or 2 arguments: matrix [, type] • norm type must be a string Extracted library reference: evaluator/builtins.go:14007. These notes are not a complete signature or a stability guarantee. Manual §12.7 Equations — `name(args) = expr`; read with manual "12.7" Excerpt: arrayed(x) = [[2 * x]] # the 1-element ARRAY ⇒ [2 * x] norm(x) = [ # several statements ⇒ the last is the value m: x * 2 m + 1 ]

normal

Function

============================================================================ PROBABILISTIC PROGRAMMING AND BAYESIAN REASONING ============================================================================ Distribution creation functions Call diagnostics (different branches may describe different overloads): • mu must be a number • normal requires 2 arguments: mu, sigma • sigma must be a number Extracted library reference: evaluator/builtins.go:11474. These notes are not a complete signature or a stability guarantee. Manual §19.10.3 The `head` / `operands` / `make_expr` normal-form algebra; read with manual "19.10.3" Excerpt: #### The `head` / `operands` / `make_expr` normal-form algebra Mathematica unifies every expression under one shape — `head[args]`. Axioma renders its three surface notations (infix, prefix, postfix) and call syntax to that same normal form, and a small algebra reads and rebuilds any quoted expression **uniformly**, regardless of which syntax produced it.

normalize

Function

normalize(s, [form])
Unicode normalization. The same text can arrive composed or decomposed — "é" as the single codepoint U+00E9 or as "e" + combining acute U+0301 — and the two spellings are invisible to == and count() (they render identically but compare unequal, 1 rune vs 2). normalize(s) rewrites to a canonical form so equality and counting behave: NFC (default — the W3C/web recommendation, also JavaScript's String.normalize default) composes; NFD decomposes; NFKC/NFKD additionally fold compatibility characters (the fi ligature → "fi", ① → "1"). Form name is case-insensitive; unknown forms are a loud catchable error. Normalize BOTH sides before comparing text from mixed sources (file systems, user input, copy-paste).

Examples

normalize("e\u{301}") == "\u{E9}"     # true  (NFC composes; bare == was false)

count(normalize("e\u{301}"))          # 1     (was 2 codepoints)

normalize("\u{FB01}", "NFKC")         # "fi"  (compatibility fold)

normally

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §6.9 Operator precedence (high → low); read with manual "6.9" Excerpt: precedence applies. `ought/permitted/forbidden` have no ordinary infix handler; `satisfies`, `with_probability`, infix `probably/typically`, `denotes`, `normally`, `by_default` have no active ordinary infix priority. Their presence in parser metadata does not make them supported expression operators.

not

Operator

not expression
Logical NOT operator

Examples

not true

not (x > 5)

not in

Symbol

=== ∉ (Glyph) === name: notin words: notin, not_in, not in latex: notin category: set codepoint: U+2209 meaning: x ∉ S — not a member

not_equal

Symbol

=== ≠ (Glyph) === name: not_equal latex: neq, ne category: logic codepoint: U+2260 meaning: a ≠ b — not equal (canonicalizes to !=)

not_in

Symbol

=== ∉ (Glyph) === name: notin words: notin, not_in, not in latex: notin category: set codepoint: U+2209 meaning: x ∉ S — not a member

nothing

Keyword

(retired August 2026) — write: none
Retired third spelling of `none`. Every use is a SyntaxError with a migration hint; it is never a silent alias. There is no Nothing value type. Description Logic's empty concept remains `Nothing`.

Examples

x: none             # write this

none is None        # the type of none

notin

Symbol

=== ∉ (Glyph) === name: notin words: notin, not_in, not in latex: notin category: set codepoint: U+2209 meaning: x ∉ S — not a member

nsm_all_languages

Function

nsm_all_languages() - Returns all supported languages for NSM translations Usage: nsm_all_languages() returns array of language names Call diagnostics (different branches may describe different overloads): • nsm_all_languages requires 0 arguments Extracted library reference: evaluator/builtin_nsm.go:121. These notes are not a complete signature or a stability guarantee.

nsm_applicable_rules

Function

nsm_applicable_rules(prime) - Gets grammar rules applicable to a prime Usage: nsm_applicable_rules("THINK") → array of applicable rules Call diagnostics (different branches may describe different overloads): • nsm_applicable_rules requires 1 argument: prime name Extracted library reference: evaluator/builtin_nsm.go:332. These notes are not a complete signature or a stability guarantee.

nsm_categories

Function

nsm_categories() - Returns all NSM categories Usage: nsm_categories() returns array of category names Call diagnostics (different branches may describe different overloads): • nsm_categories requires 0 arguments Extracted library reference: evaluator/builtin_nsm.go:138. These notes are not a complete signature or a stability guarantee.

nsm_check_structure

Function

nsm_check_structure(text) - Checks structural validity of explication Usage: nsm_check_structure("I think [something good]") → {valid: true, issues: []} Call diagnostics (different branches may describe different overloads): • nsm_check_structure requires 1 argument: text Extracted library reference: evaluator/builtin_nsm.go:402. These notes are not a complete signature or a stability guarantee.

nsm_expand

Function

============================================== NSM PHASE 3: EXPLICATION & EXPANSION FUNCTIONS ============================================== nsm_expand(text) - Expands NSM text to executable operations Usage: nsm_expand("I think something good") → expanded form Call diagnostics (different branches may describe different overloads): • nsm_expand requires 1 argument: NSM text Extracted library reference: evaluator/builtin_nsm.go:502. These notes are not a complete signature or a stability guarantee.

nsm_find_similar

Function

nsm_find_similar(word) - Finds NSM primes similar to the given word (for suggestions) Usage: nsm_find_similar("belief") might suggest ["THINK", "KNOW"] Call diagnostics (different branches may describe different overloads): • nsm_find_similar requires 1 argument: word Extracted library reference: evaluator/builtin_nsm.go:196. These notes are not a complete signature or a stability guarantee.

nsm_grammar_rule

Function

nsm_grammar_rule(name) - Gets a specific grammar rule by name Usage: nsm_grammar_rule("complementation") → rule dictionary Call diagnostics (different branches may describe different overloads): • nsm_grammar_rule requires 1 argument: rule name Extracted library reference: evaluator/builtin_nsm.go:312. These notes are not a complete signature or a stability guarantee.

nsm_grammar_rules

Function

============================================== NSM PHASE 2: GRAMMAR VALIDATION FUNCTIONS ============================================== nsm_grammar_rules() - Returns all NSM universal grammar rules Usage: nsm_grammar_rules() → array of grammar rule dictionaries Call diagnostics (different branches may describe different overloads): • nsm_grammar_rules requires 0 arguments Extracted library reference: evaluator/builtin_nsm.go:295. These notes are not a complete signature or a stability guarantee.

nsm_mapped_primes

Function

nsm_mapped_primes() - Returns all primes that have primitive mappings Usage: nsm_mapped_primes() → array of mapped primes Call diagnostics (different branches may describe different overloads): • nsm_mapped_primes requires 0 arguments Extracted library reference: evaluator/builtin_nsm.go:591. These notes are not a complete signature or a stability guarantee.

nsm_prime

Function

nsm_prime(name) - Gets a specific NSM prime by name Usage: nsm_prime("THINK") returns prime dictionary Call diagnostics (different branches may describe different overloads): • nsm_prime requires 1 argument: prime name Extracted library reference: evaluator/builtin_nsm.go:31. These notes are not a complete signature or a stability guarantee.

nsm_prime?

Function

Registered alias of is_nsm_prime.is_nsm_prime(word) - Checks if a word is an NSM prime Usage: is_nsm_prime("THINK") returns true, is_nsm_prime("happy") returns false Call diagnostics (different branches may describe different overloads): • is_nsm_prime requires 1 argument: word Extracted library reference: evaluator/builtin_nsm.go:52. These notes are not a complete signature or a stability guarantee.

nsm_prime_for_primitive

Function

nsm_prime_for_primitive(operation) - Gets the prime for a primitive operation Usage: nsm_prime_for_primitive("think") → "THINK" Call diagnostics (different branches may describe different overloads): • nsm_prime_for_primitive requires 1 argument: operation name Extracted library reference: evaluator/builtin_nsm.go:571. These notes are not a complete signature or a stability guarantee.

nsm_primes

Function

Builtin functions for NSM (Natural Semantic Metalanguage) system nsm_primes() - Returns all 66 NSM semantic primes Usage: nsm_primes() returns array of prime dictionaries Call diagnostics (different branches may describe different overloads): • nsm_primes requires 0 arguments Extracted library reference: evaluator/builtin_nsm.go:14. These notes are not a complete signature or a stability guarantee.

nsm_primes_by_category

Function

nsm_primes_by_category(category) - Returns all primes in a category Usage: nsm_primes_by_category("mental_predicates") Call diagnostics (different branches may describe different overloads): • nsm_primes_by_category requires 1 argument: category name Extracted library reference: evaluator/builtin_nsm.go:71. These notes are not a complete signature or a stability guarantee.

nsm_primitive_for

Function

nsm_primitive_for(prime) - Gets the primitive operation for a prime Usage: nsm_primitive_for("THINK") → "think" Call diagnostics (different branches may describe different overloads): • nsm_primitive_for requires 1 argument: prime name Extracted library reference: evaluator/builtin_nsm.go:551. These notes are not a complete signature or a stability guarantee.

nsm_primitives

Function

nsm_primitives() - Returns all primitive operations Usage: nsm_primitives() → array of primitive operation names Call diagnostics (different branches may describe different overloads): • nsm_primitives requires 0 arguments Extracted library reference: evaluator/builtin_nsm.go:534. These notes are not a complete signature or a stability guarantee.

nsm_translate

Function

nsm_translate(prime, language) - Translates an NSM prime to target language Usage: nsm_translate("THINK", "spanish") returns "pensar" Call diagnostics (different branches may describe different overloads): • nsm_translate requires 2 arguments: prime name, target language Extracted library reference: evaluator/builtin_nsm.go:94. These notes are not a complete signature or a stability guarantee.

nsm_validate_explication

Function

nsm_validate_explication(text) - Comprehensive explication validation Usage: nsm_validate_explication("X thinks Y") → detailed validation result Call diagnostics (different branches may describe different overloads): • nsm_validate_explication requires 1 argument: explication text Extracted library reference: evaluator/builtin_nsm.go:382. These notes are not a complete signature or a stability guarantee.

nsm_validate_grammar

Function

nsm_validate_grammar(text) - Validates text against NSM grammar rules Usage: nsm_validate_grammar("I think something good") → {valid: true, errors: []} Call diagnostics (different branches may describe different overloads): • nsm_validate_grammar requires 1 argument: text Extracted library reference: evaluator/builtin_nsm.go:354. These notes are not a complete signature or a stability guarantee.

nsm_validate_text

Function

nsm_validate_text(text) - Validates if text uses only NSM primes Usage: nsm_validate_text("I think something good") returns true Call diagnostics (different branches may describe different overloads): • nsm_validate_text requires 1 argument: text to validate Extracted library reference: evaluator/builtin_nsm.go:155. These notes are not a complete signature or a stability guarantee.

nth

Function

nth(collection, position)
The k-th element, 1-indexed; works on infinite sets. Manual §4.6.6 Design notes; read with manual "4.6.6" Excerpt: - **1-based indexing** matches `Array` / `String` / `Tuple`. - **A `String` indexes by CHARACTER (rune), a `Bytes` by byte.** `"ääb"[2]` → `"ä"` (the 2nd character; negative indices count characters from the end, `"résumé"[-1]` → `"é"`), consistent with `nth` / `substring` / the slice forms / the ordinal accessors — so `s[i] == nth(s, i)` always, under both runtimes. Byte-level access on a String is explicit: `string_to_bytes(s)[i]` → the i-th byte. (Before July 2026, `s[i]` selected the i-th *byte* and could return mojibake on multi-byte characters; the VM rejected string indexing entirely.) - **Colon-slice `x[lo:hi]` is 1-based and INCLUSIVE** across `Bytes` / `Array` / `String` / `Tuple` — identical to `x[lo..hi]`, so `"hello"[2:4]` → `"ell"` (3 elements). This is **not** Python's 0-based half-open slice (`"hello"[1:3]` → `"el"`, 2 elements); pasting a Python slice yields a different, silently-valid result. Use `..` (inclusive) or `..<` (half-open) when you want to be unambiguous about the bound style. - **Slice edge policy (all spellings — `lo:hi`, `lo..hi`, `lo..<hi`)**: a **negative bound counts from the end**, exactly as a negative single index does (`xs[-1]` is the last element): `xs[-3..-2]` → the 3rd- and 2nd-from-last elements, `xs[-3..]` → the last three, `"cynic"[2..-2]` → `"yni"`, `xs[: -2]` → all but the last (the end is inclusive, so `xs[: -1]` is the whole sequence; `xs[1..<-1]` stops before the last). In the colon spelling put a space before a negative end — `xs[2: -2]` — because `:-` lexes as the rule neck. Out-of-range bounds **clamp** (`"hello"[5:10]` → `"o"`, `xs[2..9999]` → the tail, `xs[-10..2]` → `xs[1..2]`) and a reversed window yields the **empty** value (`"hello"[4:2]` → `""`, `a[2..1]` → `[]`, `xs[-2..-3]` → `[]` — so the recursion idiom `arr[2..len(arr)]` is safe on a 1-element array with no guard). A slice never raises an out-of-bounds error. The two-bound `..`/`..<` forms lower to the same slice node as `:` at parse time, so all three run identically under `--vm`; an end-less `xs[2..]` slices **to the end** (≡ `xs[2:]` — arrays, strings, tuples). **Descending selection spells its step explicitly** — `xs[5..1..-1]` → reversed (the stepped `x[lo..hi..step]` form keeps the directional range path, evaluator-only); a step-less `x[4..2]` is an empty window, not a reversal. - **`$` in `[]` is last-index** of the collection being indexed (1-based, so `$` equals `len(xs)`): `xs[$]` is the last element, `xs[$-1]` the second-to-last, `"Julius Caesar"[8:$]` → `"Caesar"`, `"Julius Caesar"[$-3:$]` → `"esar"`. Nested `a[b[$]]` binds `$` to `b`. On a Matrix, `$` is last-index of the **axis it sits on** (`A[:, 2:$]` is columns 2 through last; `A[$, 1]` is the last row). `$5` is money and `$name` is the identifier guard — those are not last-index. `end` is the block closer (`xs[end]` is a SyntaxError). `$` is not a length prefix on a named collection (`$xs` is the identifier `xs`); `for i in 1..$` is a SyntaxError. Loop with an index as `for e at i in xs`.

null

Keyword

(retired August 2026) — write: none
Retired spelling of `none`. Every use is a SyntaxError with a migration hint. The type is None (`none is None`). JSON `null` remains the wire spelling for `json_parse` / foreign blocks; it is not Axioma source.

Examples

x: none             # write this

none is None        # the type of none

null?

Function

Call diagnostics (different branches may describe different overloads): • null? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

number?

Function

number? is special — accepts any numeric type rather than a single tag, matching the Lisp tradition where `number?` covers integers, floats, rationals, and complexes uniformly. Call diagnostics (different branches may describe different overloads): • number? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:5395. These notes are not a complete signature or a stability guarantee.

numer

Function

numer(r) - Get numerator of rational number Example: numer(2/3) → 2 Call diagnostics (different branches may describe different overloads): • numer requires a rational number • numer requires exactly 1 argument: rational number Extracted library reference: evaluator/builtins.go:17323. These notes are not a complete signature or a stability guarantee.

numerator

Function

numerator(q)
Numerator of a Rational (numerator(7/2) → 7). Manual §4.1 Primitives; read with manual "4.1" Excerpt: | `Float` | `3.14159`, `-2.5`, `0.75`, `1.5e6`, `3.14e-2`, `1E+9`, `0x1p-1`, `0xA.Bp2` | IEEE 754 double — **the type is `Float`**, not `Float64` and not `FLOAT`. `:: Float64` names no type (did-you-mean `:: Float`). Scientific notation `e`/`E` ± optional sign; **hexadecimal floats** (Go/C99 syntax — binary exponent `p`/`P` **required**: `0x1p-1` = 2⁻¹ = `0.5`, `0xa.bp2` = `42.75`, `0x2.p3` = `16.0`). The exponent is what distinguishes a hex float from a hex integer (`0x10` stays `Integer` 16), keeps `0xFE`/`0x1E` reading `e`/`E` as digits, and keeps `0x15e-2` a subtraction. Lua's exponentless fraction `0x0.2` is deliberately rejected with a hint (write `0x0.2p0`, or evaluate the Lua form via `[lua/eval \| 0x0.2 ]`). **Display** is the shortest decimal that round-trips the bits: a whole value keeps `.0` (`1.0` not `1`), IEEE remainders are not rounded away (`sin(3.1415926/2)` is `0.9999999999999997`, `0.1+0.2` is `0.30000000000000004`), infinities print `Inf`/`-Inf`, and `eval(string(x))` recovers a Float | | `Rational` | `1/3`, `rational(2, 6)` → `1/3` | Exact `p/q` on big integers, GCD-reduced — `/` on integers stays exact (`1/3 + 1/6` → `1/2`, never `0.4999…`); accessors `numerator(r)` / `denominator(r)` | | `Complex` | `complex(3, 4)` → `3.0 + 4.0i`; `im` → `i` | The **top of the numeric tower** — every other numeric type embeds, so `complex(3, 4) + 1/2` → `3.5 + 4i`. The unit is the shadowable builtin `im` (`complex(0, 1)`); write `1 + im`, `(1 + im)^2` → `2i`, `2 * im`. No juxtaposed literal: `2im` is diagnosed (same as `2x`). Full arithmetic incl. `^` (exact at integer exponents: `im^2` → `-1`) and unary minus; `sqrt`/`exp`/`log`/`sin`/`cos`/`abs`/`conjugate` all accept one. No ordering. Embedding is via `float64`, so exactness stops here. Coefficients use the same Float printer | | `String` | `"hello"`, `"unicode: ∀∃"`, `"\u{2203}"`, `r"raw \n"` | UTF-8; escape sequences + `r"..."` raw prefix — see [Strings](#strings--escape-sequences-raw-form-codepoint-builtins) | | `Boolean` | `true`, `false` | Classical two-valued |

object?

Function

Call diagnostics (different branches may describe different overloads): • object? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

observed_by

Keyword

Attach an observer to an epistemic assertion using its observer clause. Records provenance; it does not establish the observer's reliability.

obverse

Function

obverse(categorical_proposition)
Obversion via infinite (negated) terms: flip the quality, negate the predicate — every S is P ⟺ no S is non-P. The equivalence is verified in both directions over all region models. Returns {obverse, equiv}.

Examples

obverse(every human is animal)   # "no human is non-animal", equiv: true

oct

Function

Call diagnostics (different branches may describe different overloads): • oct requires exactly 1 argument Extracted library reference: evaluator/builtins.go:4392. These notes are not a complete signature or a stability guarantee.

odd

Function

Call diagnostics (different branches may describe different overloads): • odd requires exactly 1 argument Extracted library reference: evaluator/builtins.go:4554. These notes are not a complete signature or a stability guarantee. Manual §8.4 Combined; read with manual "8.4" Excerpt: forall x in a: even(x) and (x in b) exists x in b: odd(x) and (x > 3) ``` ### Symbolic-mode quantifiers — textbook syntax

odd?

Function

odd?(n)
True iff the Integer is odd (big-aware). Manual §22.6.1 Scheme/Lisp-style predicates (`?` suffix); read with manual "22.6.1" Excerpt: positive?(5) # true minus?(-1/3) # true (strictly negative) negative?(-5) # true even?(4) # true odd?(3) # true # type predicates (join number?/integer?/string?/boolean?/null?/pair?/array?…) list?([1, 2, 3]) # true procedure?(func(x) [x]) # true

of

Keyword

xs :: Array of T: values
Container element annotation. In the evaluator, explicit Array of T constraints persist on the shared Array: incompatible insertion or replacement fails through every alias and reference, and batches validate before mutation. Nested constraints persist too; broader annotations cannot erase earlier constraints. Unannotated heterogeneous Arrays remain allowed at runtime. Full VM parity is deferred: applicable Array element annotations refuse under --vm; bare Array remains supported. Inside a data parameter list, of also introduces an upper bound. See manual "Word-form container types".

Examples

xs :: Array of Integer: [1, 2]
other: xs
push(other, 3)
println(xs)

ok?

Function

ok?(value)
Test whether a constructor value has the Ok tag. This is a tag test; it does not unwrap or execute the contained value. See manual "Option" for Option, Result and Either.

om

Symbol

=== Ω (Glyph) === name: omega words: om latex: Omega category: constant codepoint: U+03A9 meaning: Ω — the SETL undefined value

om?

Function

Call diagnostics (different branches may describe different overloads): • om? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee. Manual §29.8.1 The fallback family at a glance; read with manual "29.8.1" Excerpt: none?.field # → none absence propagates instead of erroring om?.field # → Ω the SETL Ω-propagation law: unknown.x = unknown cfg?.timeout ?? 30 # → 30 safe navigation hands the `none` to `??` none |?> double # → none the pipe propagates; `??` would replace ```

omega

Symbol

=== Ω (Glyph) === name: omega words: om latex: Omega category: constant codepoint: U+03A9 meaning: Ω — the SETL undefined value

ominus

Symbol

=== △ (Glyph) === name: symmetric_difference words: symmetric_difference, symdiff, symmetric difference latex: triangle, ominus variants: ∆ ⊖ category: set codepoint: U+25B3 meaning: A △ B — symmetric difference (members in exactly one set)

on

Function

on(binaryFn, keyFn)
Applies a preprocessor to BOTH arguments of a binary function: on(cmp, key)(a, b) is cmp(key(a), key(b)). This is the shape every sort-by, group-by and dedupe-by has in common, and the one composition cannot express — `cmp ∘ key` would feed key's single result to a two-argument function. sort_by(key, coll) covers the common case for one verb; on() generalises the key extraction to any binary function.

Examples

longer: on(func(a, b) [a > b], func(s) [len(s)])

longer("abcd", "ab")                 # Returns true — compares by length

on(sub, func(s) [len(s)])("abcd", "ab")   # Returns 2

once

Keyword

once(goal)
Explicit depth-first Prolog goal: retain only the first solution of the enclosed goal. Cuts inside once are local to that goal; the caller's alternatives remain. Failure and IncompleteReasoningError propagate. Not an ordinary host function.

ones

Function

Call diagnostics (different branches may describe different overloads): • cols must be an integer • matrix dimensions must be positive • ones requires exactly 2 arguments: rows, cols • rows must be an integer Extracted library reference: evaluator/builtins.go:13746. These notes are not a complete signature or a stability guarantee. Manual §5.14 Matrices, tensors & dataframes; read with manual "5.14" Excerpt: reshape(matrix([[1, 2, 3], [4, 5, 6]]), 3, 2) # 2×3 → 3×2 zeros(2, 2) # 2×2 of 0s ; ones(2, 3) → 2×3 of 1s solve(matrix([[2, 1], [1, 3]]), [5, 10]) # Ax = b → column vector (1, 3) z: zeros(2, 3)

operands

Function

operandsBuiltin returns the operands of an AST node as an Array of AST values, with the head/operator/functor EXCLUDED in every case (the uniform companion to head). Atoms have no operands ([]); other compound nodes fall back to their structural children so the function stays total. Call diagnostics (different branches may describe different overloads): • operands requires exactly 1 argument (AST or expression) Extracted library reference: evaluator/builtin_ast_algebra.go:148. These notes are not a complete signature or a stability guarantee. Manual §19.10.3 The `head` / `operands` / `make_expr` normal-form algebra; read with manual "19.10.3" Excerpt: #### The `head` / `operands` / `make_expr` normal-form algebra Mathematica unifies every expression under one shape — `head[args]`. Axioma renders its three surface notations (infix, prefix, postfix) and call syntax to that same normal form, and a small algebra reads and rebuilds any quoted expression **uniformly**, regardless of which syntax produced it.

operator

Keyword

operator (&&&) = minInt [with precedence: product associativity: left end]
Declare a binary symbolic spelling for an ordinary named function at file or REPL top level, before use. Use 8 &&& 3, (&&&)(8, 3), or pass (&&&) as a function value. Default precedence product, associativity left. Static with ... end metadata accepts precedence pipe, fallback, implies, or, and, equality, comparison, range, sum, product, power (loose to tight) and associativity left, right, none. A non-associative chain needs parentheses. Targets may be module-qualified. Imports never export operator syntax. Compatible declarations may repeat during :source/:refresh; conflicts fail. Operator spelling uses ASCII !%&*+-/<=>?^|~ runs or unreserved mathematical glyphs such as ⊛; existing complete operators, reserved glyphs, comments and delimiters are protected. Ordinary function checks, contracts, dispatch and VM limits apply; declaring syntax adds no short-circuiting. Custom unary, postfix and partial operator sections are not introduced.

Examples

minInt(x, y) = if x > y then y else x
operator (&&&) = minInt
println(8 &&& 3) # 3

minus(x, y) = x - y
operator (⊛) = minus with
  precedence: sum
  associativity: right
end
println(20 ⊛ 5 ⊛ 2) # 17

oplus

Symbol

=== ⊕ (Glyph) === name: b4_join latex: oplus category: logic codepoint: U+2295 meaning: a ⊕ b — B4 knowledge-order join (gullibility: accept all testimony; conflict → glut)

or

Operator

expression1 or expression2
Logical OR; aliases || and ∨. Skips the right operand for Boolean true on the left. Otherwise preserves multivalued logic dispatch; not an operand-returning or truthiness operator.

Examples

true or false

x < 0 or x > 100

or_else

Function

or_else(f, wrapper) — on failure, call f(payload_or_none) and return its result; on success, unchanged. None passes none; Err/Left pass their field. Call diagnostics (different branches may describe different overloads): • or_else requires exactly 2 arguments: a function and an Option/Result/Either Extracted library reference: evaluator/builtin_option_helpers.go:149. These notes are not a complete signature or a stability guarantee. Manual §33.14.2 Railway helpers — `map_ok` / `and_then` / `or_else` / `is_*`; read with manual "33.14.2" Excerpt: #### Railway helpers — `map_ok` / `and_then` / `or_else` / `is_*` Function **first**, wrapper **second** (same order as `map` / `filter`):

oracle

Function

oracle word | oracle "word" | oracle("word") | oracle/on | oracle/off | oracle/status (also oracle/on() …)
The word oracle, as a word: the LOCAL parent, never a model. For an unknown word it prints the five roles the word could take (a value, a thing, a kind of thing, a relation, a way to compute) as canonical sentences, near-miss spellings from your own words and the dictionary, and the offline and AI routes; for a known word it says what it is and lists what can be asked of it. It is the same text the -o / --oracle hint gives at an unknown word, but explicit, so it answers whether or not the flag is on. Shadowable: a binding named oracle wins. Bare `oracle` in statement position holds the NAME (oracle ogabund).

Examples

oracle ogabund                 # statement form — the roles a new word could take

oracle("ogabund")             # call form, identical

oracle msft                    # a known word: what it is and what you can ask

oracle/on                      # turn the hints on for the rest of this run (the -o flag's twin; oracle/off, oracle/status)

ord

Function

ord(char)
1-character String → Unicode codepoint (ord("∃") → 8707). Manual §4.5.5 Codepoint builtins — `chr` and `ord`; read with manual "4.5.5" Excerpt: #### Codepoint builtins — `chr` and `ord` For programmatic codepoint construction (when the literal form can't help because the value comes from runtime):

order_states

Function

order_states(model, earlier, later) - Define ordering relation earlier ≤ later Represents: knowledge at later extends knowledge at earlier Example: order_states(im, "s0", "s1") Call diagnostics (different branches may describe different overloads): • first argument must be an intuitionistic model • order_states requires 3 arguments: model, earlier, later • second argument must be a string (earlier state ID) • third argument must be a string (later state ID) Extracted library reference: evaluator/builtins.go:18113. These notes are not a complete signature or a stability guarantee.

orderby

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §7.13 ORDER BY clause; read with manual "7.13" Excerpt: List comprehensions accept an `orderby` clause that sorts the result. Sets and dicts ignore `orderby` (they're unordered by nature). Direction defaults to `asc`; add `desc` to reverse: ```axioma [x | x <- xs, orderby x] # asc by default

orelse

Operator

expression1 orelse expression2
Short-circuiting logical OR. Always two-valued: the right operand is skipped whenever the left is truthy. Yields a Boolean — for a fallback that returns the VALUE, use `??` (absence) or `otherwise` (error).

Examples

1 < 2 orelse 3 > 4

i > len(xs) orelse xs[i] > 0

otherwise

Operator

expression otherwise fallback  |  name(pats) otherwise = body  |  func name(pats) otherwise [body]  |  name(pats) = body, otherwise
Two positions, one word. Infix LEFT otherwise RIGHT (also spelled or else) returns RIGHT if LEFT is an Error, otherwise LEFT; the right side is evaluated only on failure. After a function head, same-line otherwise not followed by : is sugar for a when true catch-all clause (func f(x) otherwise [0] ≡ func f(x) when true [0]; f(x) otherwise = 0 ≡ f(x) when true = 0). After an equation body, `, otherwise` is the same last-guard in Miranda's order. Soft keyword: otherwise: 5 still binds. f(x) otherwise 0 is the infix; the equation reading commits only on otherwise = or on `, otherwise` at the end of the clause.

Examples

parse_int("xx") otherwise 0

func sign(n) when n > 0 [1]

func sign(n) otherwise [0]

sign(n) otherwise = 0

sign(n) = 0, otherwise

otimes

Symbol

=== ⊗ (Glyph) === name: b4_meet latex: otimes category: logic codepoint: U+2297 meaning: a ⊗ b — B4 knowledge-order meet (consensus: keep only agreement)

ought

Deontic Logic

ought proposition
Deontic obligation operator (OP). Expresses moral or logical obligation.

Examples

ought true

ought (help others)

duty: ought (tell the truth)

over

Function

Call diagnostics (different branches may describe different overloads): • argument to over must be a stack • over requires 1 argument: stack • over requires at least 2 items on stack Extracted library reference: evaluator/builtins.go:12096. These notes are not a complete signature or a stability guarantee. Manual §18.2 Stack-shuffle operations; read with manual "18.2" Excerpt: | `rot(s)` | `a b c → b c a` | Rotate top three | | `over(s)` | `a b → a b a` | Copy second to top | | `drop(s)` | `a →` | Discard top | | `nip(s)` | `a b → b` | Drop second | | `tuck(s)` | `a b → b a b` | Copy top below second |

pa

Keyword

Lojban-inspired exact-count quantifier: exactly one member of the explicit domain.

pack

Function

packBuiltin implements pack(spec, args...) — serializes the args into a Bytes value following the format spec. The arg count must match the total "value count" the format requires (each scalar code consumes one arg per count unit; `s` consumes one Bytes/String arg per element; `x` consumes zero). Call diagnostics (different branches may describe different overloads): • pack requires at least 1 argument (format spec) • pack: format requires more values than provided Extracted library reference: evaluator/builtin_pack.go:104. These notes are not a complete signature or a stability guarantee. Manual §4.6.7 Binary serialization — `pack` / `unpack`; read with manual "4.6.7" Excerpt: #### Binary serialization — `pack` / `unpack` Python-`struct`-style format strings. `pack` serializes values into `Bytes`; `unpack` reads `Bytes` back into a `Tuple` of typed values. The format spec is small enough to memorize:

pair

Function

pair(key, value)
Association cell — same value as `key => value`. No nullary form. Manual §6.4.1 `andalso` / `orelse` — the strictly two-valued pair; read with manual "6.4.1" Excerpt: #### `andalso` / `orelse` — the strictly two-valued pair Both `and` and `andalso` short-circuit, so that is not what separates them. The difference is what happens when an operand is **not** a Boolean: `and`

pair?

Function

Call diagnostics (different branches may describe different overloads): • pair? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

paraconsistent_model

Function

paraconsistent_model(system) - Create a paraconsistent logic model Systems: "LP" (Logic of Paradox), "K3" (Strong Kleene), "FDE" (First Degree Entailment) Example: pm: paraconsistent_model("LP") Call diagnostics (different branches may describe different overloads): • argument must be a string: 'LP', 'K3', or 'FDE' • paraconsistent_model requires 1 argument: system Extracted library reference: evaluator/builtins.go:18192. These notes are not a complete signature or a stability guarantee.

parameters

Function

parameters(fn)
Parameter names of a function as an Array. Spec-registered builtins include their markers ("[x]" optional, "xs..." variadic); builtins without a spec return [].

Examples

parameters(func(a, b) [a + b])   # → ["a", "b"]

parameters(round)                # → ["x", "[digits]"]

parse

Function

parse(code, [mode])
Low-level parse of a source String to AST; mode "expression" (default — FIRST statement only), "statement", or "program" (ast() is the no-truncation front-end). Not a typed value reader — that is parse_as(Integer, s) / Integer.parse(s). Manual §25.5 Runtime reflection — the self-describing surface; read with manual "25.5" Excerpt: `parse("32")` still yields an **AST** (`eval(parse("32"))` → 32). A Julia-shaped `parse(Integer, "32")` is a catchable error that names `parse_as` / `Integer.parse`. The readers consume the **whole** string (trim and `_` allowed): `Integer.parse("3.2")` errors, while the coercion `int("3.2")` still

parse_as

Function

parse_as(type, s, [base])
Read a String as a typed value: parse_as(Integer, "32") ≡ Integer.parse("32"). Whole-string consume. Optional digit base 2..36 for Integer/Byte. Distinct from parse() (source → AST). Manual §25.5 Runtime reflection — the self-describing surface; read with manual "25.5" Excerpt: `parse("32")` still yields an **AST** (`eval(parse("32"))` → 32). A Julia-shaped `parse(Integer, "32")` is a catchable error that names `parse_as` / `Integer.parse`. The readers consume the **whole** string (trim and `_` allowed): `Integer.parse("3.2")` errors, while the coercion `int("3.2")` still truncates a prefix. Base is Integer/Byte only.

parse_grammar

Function

parse_grammar() - Parse constrained language and return grammar structure Usage: parse_grammar(stmt) returns dict with grammar details Call diagnostics (different branches may describe different overloads): • parse_grammar requires 1 argument Extracted library reference: evaluator/builtin_constrained_language.go:150. These notes are not a complete signature or a stability guarantee.

partOf

Keyword

Infix part-whole relation vocabulary. See doc "relation" for declaring explicit relations and their facts.

partial

Function

partial(f, args...)
Fix the leading arguments: partial(f, a) returns the function awaiting f's remaining parameters. Works on user functions and builtin-backed callables (a flipped function included). Manual §12.14 Currying & partial application; read with manual "12.14" Excerpt: ### Currying & partial application ```axioma multiply: lambda x => lambda y => x * y

particularly

Keyword

Philosophical particular quantifier form, paired with universally. Its domain and condition must be explicit; see doc "exists" for ordinary existential quantification.

partition

Keyword

Concept partition Part1, Part2, ...
Declares that the named subconcepts partition the parent — every instance should fall in EXACTLY one part (disjoint + exhaustive). The laws are queryable over the live extent: is_partitioned(C) gives the verdict, partition_overlap(C) / partition_gap(C) return witness instances that break disjointness/exhaustiveness, and partition_member(x, C) returns the part x falls into.

Examples

Thing partition UpToUs, NotUpToUs

is_partitioned(Thing)        # true while disjoint + exhaustive

partition_member(opinion, Thing)

partition_gap

Function

partition_gap(Concept)
Returns the Set of extent instances that fall in NO declared part — the witnesses that break exhaustiveness. Empty set ⇔ total.

Examples

mystery: a Thing {}

partition_gap(Thing)  # {mystery}

partition_member

Function

partition_member(instance, Concept)
Returns the part (member concept) of the concept's first declared partition that the instance falls into, or none. On a non-disjoint partition returns the first match — partition_overlap surfaces the conflict.

Examples

partition_member(opinion, Thing) == UpToUs  # true

partition_overlap

Function

partition_overlap(Concept)
Returns the Set of instances that fall in MORE than one declared part — the witnesses that break disjointness. Empty set ⇔ disjoint.

Examples

partition_overlap(Thing)  # {} when disjoint

partitions_of

Function

partitions_of(Concept)
Returns the partition tuples declared on the concept.

Examples

partitions_of(Thing)

partOf

Keyword

Infix part-whole relation vocabulary. See doc "relation" for declaring explicit relations and their facts.

parts

Function

partsBuiltin returns the structural children of an AST as an Array of *types.AST values — closes the recursive-traversal gap that argsof (which returns Array of String) couldn't. Lets users walk a tree without re-parsing at each level. Call diagnostics (different branches may describe different overloads): • parts requires exactly 1 argument (AST or expression) Extracted library reference: evaluator/builtin_ast_construct.go:329. These notes are not a complete signature or a stability guarantee. Manual §19.10 19.10 Homoiconicity — building code as data; read with manual "19.10" Excerpt: **Recursive traversal** via `parts(ast)`. Unlike `argsof` (which returns strings), `parts` returns `Array` of AST values — so you can walk a tree without re-parsing at each level: ```axioma h: hold((a + b) * c)

pattern

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §3.1.1 Pattern binding (ML-style tuple patterns); read with manual "3.1.1" Excerpt: #### Pattern binding (ML-style tuple patterns) When the left-hand side is a **tuple pattern** in parentheses, the right-hand side is matched as a whole and the identifiers in the pattern are bound —

pause

Function

pause() | pause(seconds)
With no argument, wait for Enter on standard input. With one nonnegative Integer or Float, sleep for that number of seconds. Returns none. The interactive form requires input; do not use it in an unattended script.

payoff_matrix

Function

============================================================================ Game Theory Functions ============================================================================ Call diagnostics (different branches may describe different overloads): • dimensions must be integers • first argument must be an array of dimensions • payoff_matrix requires 2 arguments: dimensions, payoffs • payoffs must be numbers • payoffs must be numbers or arrays • second argument must be an array of payoffs Extracted library reference: evaluator/builtins.go:13254. These notes are not a complete signature or a stability guarantee.

peek

Function

peek(stack)
Returns the top value of the stack without removing it.

Examples

s: stack()

push(s, 10)

peek(s)  # 10 (stack remains [10])

percent

Function

percent(number)
A number to a Percent (percent(50) → 50%). Manual §4.7.1 Arithmetic on `Money` / `Percent`; read with manual "4.7.1" Excerpt: #### Arithmetic on `Money` / `Percent` ```axioma $100 + $25 # → $125

percent?

Function

Call diagnostics (different branches may describe different overloads): • percent? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

permitted

Deontic Logic

permitted proposition
Deontic permission operator (PP). Expresses what is morally or logically permissible.

Examples

permitted true

permitted (take a break)

allowable: permitted action

permutations

Function

permutations(n, k)
Computes the number of ways to choose and arrange k items from n. Alias: `nPr`.

Examples

permutations(5, 2)   # Returns 20

perp

Symbol

=== ⊥ (Glyph) === name: falsum latex: bot, perp category: logic codepoint: U+22A5 meaning: ⊥ — falsum (false)

phi

Value

Built-in FLOAT value: 1.618033988749895 Manual §22.1 Mathematical constants; read with manual "22.1" Excerpt: | `e` | 2.718281828459045 | Euler's number | | `phi` | 1.618033988749895 | Golden ratio | | `sqrt2` | 1.4142135623730951 | √2 | | `sqrt3` | 1.7320508075688772 | √3 | | `ln2` | 0.6931471805599453 | ln 2 |

phrase?

Function

Call diagnostics (different branches may describe different overloads): • phrase? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

pi

Value

Built-in FLOAT value: 3.141592653589793 Manual §3.9 `global` — Julia's module write; read with manual "3.9" Excerpt: **Builtins vs constants.** The lowercase math names (`pi`, `e`, `tau`, `im`, …) are *shadowable* fallback builtins — `pi: 3` wins locally and leaves the system untouched. The canonical UPPERCASE constants (`PI`, `TAU`, `EULER`, …) are seeded immutable: `PI: 3` reports `Cannot reassign constant 'PI'`

pick

Function

Advanced Forth-style operations using existing At() method Call diagnostics (different branches may describe different overloads): • first argument to pick must be a stack • pick requires 2 arguments: stack, index • second argument to pick must be an integer Extracted library reference: evaluator/builtins.go:12320. These notes are not a complete signature or a stability guarantee. Manual §18.2 Stack-shuffle operations; read with manual "18.2" Excerpt: | `tuck(s)` | `a b → b a b` | Copy top below second | | `pick(s, i)` | `→ … x` | Copy the element at index `i` (0 = top) to the top | | `roll(s, i)` | `→ … x` | Move the element at index `i` to the top | ### Bulk & depth operations

pipe

Function

pipe(value, f, g, ...)
Threads a VALUE through a series of functions, left to right: pipe(x, f, g) is g(f(x)). The call form of the `|>` operator. Where compose() builds a new function out of stages, pipe() runs the stages on a value immediately — same order, different product.

Examples

pipe(5, double, incr)     # Returns 11

5 |> double |> incr       # Returns 11 — the operator form

pipe(5, double, incr) == compose(double, incr)(5)   # true

pipe_try

Function

pipe_try backs the error-propagating forward pipe `|?>`: x |?> f(a) ≡ pipe_try(x, lambda __pv => f(a, __pv)) It short-circuits on a failed/absent/undetermined value (Error / none / om / a ConstructorValue tagged Absent or Err), returning it untouched; otherwise it applies the deferred RHS (args[1]) to the value — UNWRAPPED first if the value is a single-field Some/Ok ConstructorValue (the Option/Result railway convention; see isPipeSuccessUnwrap). Higher-order: the VM intercepts it in callHigherOrderBuiltin so a compiled *Closure RHS is invoked correctly (with the matching unwrap mirrored there). Call diagnostics (different branches may describe different overloads): • pipe_try requires exactly 2 arguments: a value and a function Extracted library reference: evaluator/builtins.go:4923. These notes are not a complete signature or a stability guarantee. Manual §33.17.2 VM policy (tagged ADTs); read with manual "33.17.2" Excerpt: matching `|?>`'s pre-existing non-ADT behavior over `Error`/`none`/`om`. `pipe_try` never re-wraps the RHS's return value; staying "in the railway" past a stage is the RHS's own job. ### Comprehension constructor-pattern destructure

plus?

Function

numericSignPredicate builds a 1-arg predicate over a number's sign. A non-number argument yields false (matching the existing positive/negative/ even family, which return false rather than erroring on a wrong type). Call diagnostics (different branches may describe different overloads): • plus? requires exactly 1 argument Extracted library reference: evaluator/scheme_predicates.go:56. These notes are not a complete signature or a stability guarantee. Manual §22.6.1 Scheme/Lisp-style predicates (`?` suffix); read with manual "22.6.1" Excerpt: # sign / parity (over Integer, Float, Rational) zero?(0) # true plus?(5) # true (strictly positive) positive?(5) # true minus?(-1/3) # true (strictly negative) negative?(-5) # true even?(4) # true odd?(3) # true

poi

Reserved vocabulary

Reserved vocabulary with no dedicated parser implementation in this build. It is not a usable standalone form. Use doc "discover" for the implemented discovery interface, and manual for supported language forms. Recognition of a name is not a claim that its intended feature is implemented.

polar

Function

polar(r, theta) - Create complex number from polar coordinates Example: polar(1, pi) → -1 + 0i (Euler's identity) Call diagnostics (different branches may describe different overloads): • polar requires exactly 2 arguments: r, theta • polar requires numeric r • polar requires numeric theta Extracted library reference: evaluator/builtins.go:17171. These notes are not a complete signature or a stability guarantee. Manual §34 Modules; read with manual "34" Excerpt: module Geometry # the file's header module Polar [ … ] # a module inside the file — as many as you like module Cartesian [ … ] ```

pop

Function

pop(stack | array)
Removes and returns the top of a stack — or, since the July 2026 dynamic-array flip, the LAST element of an array (shortening it in place). Popping an empty stack or array errors.

Examples

s: stack()

push(s, 10)

pop(s)  # 10

a: [1, 2, 3]

pop(a)  # 3 — a is now [1, 2]

porphyry_categories

Function

porphyry_categories() - Returns the five classical Porphyrian categories Example: categories: porphyry_categories() Call diagnostics (different branches may describe different overloads): • porphyry_categories requires 0 arguments Extracted library reference: evaluator/builtins.go:20021. These notes are not a complete signature or a stability guarantee.

porphyry_examples

Function

porphyry_examples() - Prints educational examples using Porphyry tree Example: porphyry_examples() Call diagnostics (different branches may describe different overloads): • porphyry_examples requires 0 arguments Extracted library reference: evaluator/builtins.go:20055. These notes are not a complete signature or a stability guarantee.

positive

Function

Call diagnostics (different branches may describe different overloads): • positive requires exactly 1 argument Extracted library reference: evaluator/builtins.go:4567. These notes are not a complete signature or a stability guarantee. Manual §22.6.1 Scheme/Lisp-style predicates (`?` suffix); read with manual "22.6.1" Excerpt: `?` is part of the identifier (`zero?` is one word), so these read naturally. The sign predicates treat a non-number as `false` (matching `even`/`positive`). ```axioma # sign / parity (over Integer, Float, Rational)

positive?

Function

numericSignPredicate builds a 1-arg predicate over a number's sign. A non-number argument yields false (matching the existing positive/negative/ even family, which return false rather than erroring on a wrong type). Call diagnostics (different branches may describe different overloads): • positive? requires exactly 1 argument Extracted library reference: evaluator/scheme_predicates.go:56. These notes are not a complete signature or a stability guarantee. Manual §22.6.1 Scheme/Lisp-style predicates (`?` suffix); read with manual "22.6.1" Excerpt: zero?(0) # true plus?(5) # true (strictly positive) positive?(5) # true minus?(-1/3) # true (strictly negative) negative?(-5) # true even?(4) # true odd?(3) # true # type predicates (join number?/integer?/string?/boolean?/null?/pair?/array?…)

possibly

Modal Logic

possibly expression
Modal possibility operator (◇P). Expresses that a proposition is possibly true in some possible world.

Examples

possibly false

possibly (tomorrow will rain)

contingent: possibly P and possibly not P

posterior

Function

Call diagnostics (different branches may describe different overloads): • likelihood must be a distribution • posterior requires 3 arguments: prior, likelihood, evidence • prior must be a distribution Extracted library reference: evaluator/builtins.go:11790. These notes are not a complete signature or a stability guarantee.

postulate

Keyword

postulate fact(args...)
Asserts a fact as a POSTULATE — a tentative knowledge claim that may later be verified or refuted. Sits one rung below axiom on the grounding ladder: axiom > postulate > theorem > conjecture > hypothesis > datum. Supports the same kind refinements as axiom (postulate/motive, postulate/empirical, ...).

Examples

relation parent(x, y)

postulate parent("mary", "ann")

grounding("parent", "mary", "ann")  # "postulate"

postulates

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §15 Knowledge Base, Axioms & Postulates; read with manual "15" Excerpt: ## 15. Knowledge Base, Axioms & Postulates ### Declaring knowledge — the six grounding grades

pow

Function

Call diagnostics (different branches may describe different overloads): • pow base requires a number • pow exponent requires a number • pow requires exactly 2 arguments Extracted library reference: evaluator/builtins.go:3777. These notes are not a complete signature or a stability guarantee. Manual §6.9 Operator precedence (high → low); read with manual "6.9" Excerpt: exact — so `2 ^ -3` → `1/8`, `2 ^ -1` → `1/2`, `1 ^ -5` → `1`. (`0 ^ -3` is a division-by-zero error.) Use a Float base/exponent or `pow(...)` if you want a Float result instead. **A fractional exponent is a root, and exactness follows the operands.** A

pow_mod

Function

pow_mod(base, exp, mod)
Alias for `powmod`. Computes modular exponentiation.

Examples

pow_mod(2, 10, 1000)   # Returns 24

powerset

Function

powerset(set)
Set of all subsets. Manual §4.8 Ranges — ordered `a..b`, exclusive `..<`, `by` step, open `n..`; read with manual "4.8" Excerpt: the set of its points: `(1..5) union {9}`, `(1..9) intersect (4..12)`, `set(1..3)`, `powerset(1..3)`, and the `{1..5, 99}` set-literal splice all produce ordinary Sets. **Open-ended ranges are lazy.** `2..` never materializes; bounded consumers

powmod

Function

powmod(base, exp, mod)
Computes modular exponentiation: (base ^ exp) % mod. Runs efficiently using binary exponentiation. Alias: `pow_mod`.

Examples

powmod(2, 10, 1000)   # Returns 24

pred

Function

pred(x)
Predecessor: the previous Integer (or enum member). Manual §13.13 Intensional class descriptions — `the Concept where <pred>`; read with manual "13.13" Excerpt: ### Intensional class descriptions — `the Concept where <pred>` A Russell-style definite description with restrictor (KM §18.2). `the Stock where price > 1000` denotes the anonymous class of Stocks whose

predicate

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §8.7 Formula type + predicate; read with manual "8.7" Excerpt: ### Formula type + predicate ```axioma f: ∀x P(x)

predicates_of_term

Function

predicates_of_term(taxonomy, S)
DAC's inventive enumeration: every term truly predicated of S (every S is T) — S's ancestors, most-specific first. Dual: subjects_of_term(tax, P) lists every T with `every T is P` (the descendants).

Examples

predicates_of_term(porphyry, human)   # [animal, living, body, substance]

subjects_of_term(porphyry, "animal")  # [rational, human, irrational, beast, ...]

presupposes

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §7.22 The same question, many ways; read with manual "7.22" Excerpt: Plus the related-but-distinct **membership** test, which presupposes you already have the witness: ```axioma mike in persons # "is mike one of them?"

prime?

Function

prime?(n)
Lisp-style alias for `is_prime`. Checks if the integer n is prime.

Examples

prime?(17)    # Returns true

print

Function

print(expression)
Prints a value to the console

Examples

print("Hello, World!")

print(42)

print(person's name)

printf

Function

printf(format, args...)
C-style formatted output to stdout (escape sequences interpreted). Verbs: %d %b %o %x %X %c %U (integer class), %f %e %g (float class), %s %q %v, %t, %% — with Go-fmt flags/width/precision. Arguments adapt by the numeric tower's own rules: an INTEGRAL Float/Rational converts under %d, an Integer/Rational converts under %f, %s takes anything via its display form. Any verb/type mismatch, missing/extra argument, or unknown verb is a loud catchable error — a Go '%!' badge can never reach output. stringf is the string-returning twin.

Examples

printf("%05d|%6.2f\n", 42, 3.14159)   # 00042|  3.14

printf("%d\n", 35.0)                   # 35 (integral Float converts)

println

Function

println(values...)
Print the arguments then a newline. Manual §7.14 Aggregation: `group_by`, `items`, `keys`, `values`; read with manual "7.14" Excerpt: Four builtins fill the SQL-style aggregation gap. `group_by(fn, coll)` partitions a collection into a hash; `items(hash)` exposes it as `(key, value)` pairs; `keys`/`values` return the parts individually. All three enumerators walk the hash in **sorted key order** — the same canonical order `println(h)` shows — so repeated calls (and `keys`/`values`/`items` against each other) always agree. ```axioma orders: [

prisoners_dilemma

Function

prisoners_dilemma()
Return the built-in two-player, two-strategy Prisoner's Dilemma example (Cooperate or Defect). Payoff pairs are (3,3), (0,5), (5,0), (1,1), in row-major strategy order. These are fixed example models, not empirical predictions.

prob_and

Function

prob_and(kb, formulaA, formulaB) - Compute P(A ∧ B) Example: prob_and(kb, "bird(X)", "flies(X)") → conjunction probability Call diagnostics (different branches may describe different overloads): • first argument must be a probabilistic logic KB • prob_and requires 3 arguments: kb, formulaA, formulaB • second argument must be a string (formulaA) • third argument must be a string (formulaB) Extracted library reference: evaluator/builtins.go:19141. These notes are not a complete signature or a stability guarantee.

prob_logic_kb

Function

prob_logic_kb(mode) - Create a probabilistic logic knowledge base Modes: "independent" (default), "markov_logic", "bayesian" Example: prob_logic_kb("bayesian") Extracted library reference: evaluator/builtins.go:18956. These notes are not a complete signature or a stability guarantee.

prob_not

Function

prob_not(kb, formula) - Compute P(¬A) Example: prob_not(kb, "raining") → P(not raining) Call diagnostics (different branches may describe different overloads): • first argument must be a probabilistic logic KB • prob_not requires 2 arguments: kb, formula • second argument must be a string (formula) Extracted library reference: evaluator/builtins.go:19201. These notes are not a complete signature or a stability guarantee.

prob_or

Function

prob_or(kb, formulaA, formulaB) - Compute P(A ∨ B) Example: prob_or(kb, "raining", "sprinkler_on") Call diagnostics (different branches may describe different overloads): • first argument must be a probabilistic logic KB • prob_or requires 3 arguments: kb, formulaA, formulaB • second argument must be a string (formulaA) • third argument must be a string (formulaB) Extracted library reference: evaluator/builtins.go:19171. These notes are not a complete signature or a stability guarantee.

probably

Keyword

Introduce a probabilistic assertion or probability-qualified expression. Probability is not the same as logical entailment; this belongs to the experimental probabilistic interface.

procedure?

Function

callablePredicate: procedure? — true for any callable. Call diagnostics (different branches may describe different overloads): • procedure? requires exactly 1 argument Extracted library reference: evaluator/scheme_extras.go:568. These notes are not a complete signature or a stability guarantee. Manual §22.6.1 Scheme/Lisp-style predicates (`?` suffix); read with manual "22.6.1" Excerpt: # type predicates (join number?/integer?/string?/boolean?/null?/pair?/array?…) list?([1, 2, 3]) # true procedure?(func(x) [x]) # true empty?([]) # true — also "" / set() / {} / dict() ; an infinite set is never empty symbol?('hello) # true — a lit-word is a symbol ; symbol_name('hello) → "hello"

prod

Function

prod(collection)
Computes the product of all elements in an array, tuple, or set. Alias: `product`.

Examples

prod([1, 2, 3, 4])   # Returns 24

prod({2, 3, 5})      # Returns 30

product

Function

product(collection)
Alias for `prod`. Computes the product of all elements in an array, tuple, or set.

Examples

product([1, 2, 3])   # Returns 6

program

Function

Call diagnostics (different branches may describe different overloads): • program argument must be an array • program requires exactly 1 argument (array of statements/expressions) Extracted library reference: evaluator/builtins.go:16532. These notes are not a complete signature or a stability guarantee. Manual §28.2 28.2 Secondary runners: Julia / R / Node.js / TypeScript / Lua / Common Lisp / Free Pascal / C / Haskell; read with manual "28.2" Excerpt: modern dialects. An unknown mode is rejected without spawning fpc. - **Three body shapes.** A full `program` compiles **verbatim**. A headerless fragment ending in `end.` — declarations plus a main block, the shape book chapters print — gets a `program` header prepended. Bare statements (`writeln(2 + 2)`) get a full program/`begin`/`end.`

program?

Function

Call diagnostics (different branches may describe different overloads): • program? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1645. These notes are not a complete signature or a stability guarantee.

project

Function

Call diagnostics (different branches may describe different overloads): • project requires exactly 2 arguments: project(relation, columns) Extracted library reference: evaluator/builtins.go:8006. These notes are not a complete signature or a stability guarantee. Manual §28.2 28.2 Secondary runners: Julia / R / Node.js / TypeScript / Lua / Common Lisp / Free Pascal / C / Haskell; read with manual "28.2" Excerpt: for execution — there is no separate typecheck pass on the hot path. Install with `npm install -g tsx` (or set `AXIOMA_TSX` to a project-local binary). Alias: `[typescript | …]`. - **Multi-statement eval bodies.** Julia bodies sit in `begin … end` and R bodies in `{ … }` — statements run in order and the LAST

prompt

Function

Enhanced Interactive Functions Extracted library reference: evaluator/builtins.go:15045. These notes are not a complete signature or a stability guarantee. Manual §25.8 Reading a value — `read_integer()` / `read_float()` / `read_string()`; read with manual "25.8" Excerpt: `input_number`, `prompt`, `choice`, `confirm`, and `menu` share the same persistent stdin reader, so sequential calls consume successive lines under a pipe. The token readers share it too.

proof

Function

proof(relation, args...)
Walks a derived fact's derivation chain back to its originating axioms. Returns an array of (fact, grounding, depth) tuples. The keyword form `why fact(args)` prints the same chain as readable prose.

Examples

mortal(X) <== human(X)

axiom human("socrates")

proof("mortal", "socrates")

proof_certify

Function

proofKernelBuiltins registers the Go-kernel surface. Merged into the global builtin map by GetBuiltins (evaluator/builtins.go). Extracted library reference: evaluator/proof_kernel.go:1169. These notes are not a complete signature or a stability guarantee.

proof_certify_lines

Function

proof_certify_lines(steps, catalog)
Check proof steps against the supplied rule catalog and return per-line reports including line, kind, ok, formula, reason and depth. See proof_certify for certification of a goal.

proof_conclusion

Function

Extracted library reference: evaluator/proof_kernel.go:1188. These notes are not a complete signature or a stability guarantee. Manual §31 Proof Assistant; read with manual "31" Excerpt: objects after certification cannot change what was certified. Accessors `proof_conclusion` and `proof_hyps` (and library `conclusion` / `hyps`) return fresh, detached representations at every level, including predicate argument arrays. Those returned values remain ordinary mutable data; editing them does not edit the theorem.

proof_hyps

Function

Extracted library reference: evaluator/proof_kernel.go:1198. These notes are not a complete signature or a stability guarantee. Manual §31 Proof Assistant; read with manual "31" Excerpt: objects after certification cannot change what was certified. Accessors `proof_conclusion` and `proof_hyps` (and library `conclusion` / `hyps`) return fresh, detached representations at every level, including predicate argument arrays. Those returned values remain ordinary mutable data; editing them does not edit the theorem.

proof_is_theorem

Function

proof_is_theorem(value)
Return whether the value is a theorem certified by the proof kernel. A user-created record claiming to be a theorem does not qualify. Certification validates derivation from the supplied premises, not their empirical truth.

proper subset

Symbol

=== ⊂ (Glyph) === name: proper_subset words: proper_subset, subsetneq, proper subset latex: subset, subsetneq variants: ⊊ category: set codepoint: U+2282 meaning: A ⊂ B — proper (strict) subset

proper superset

Symbol

=== ⊃ (Glyph) === name: proper_superset words: proper_superset, supsetneq, proper superset latex: supset, supsetneq variants: ⊋ category: set codepoint: U+2283 meaning: A ⊃ B — proper (strict) superset

proper_subset

Symbol

=== ⊂ (Glyph) === name: proper_subset words: proper_subset, subsetneq, proper subset latex: subset, subsetneq variants: ⊊ category: set codepoint: U+2282 meaning: A ⊂ B — proper (strict) subset

proper_superset

Symbol

=== ⊃ (Glyph) === name: proper_superset words: proper_superset, supsetneq, proper superset latex: supset, supsetneq variants: ⊋ category: set codepoint: U+2283 meaning: A ⊃ B — proper (strict) superset

properties

Function

properties(x)
Property/member names of an entity or concept, sorted. Manual §25.5 Runtime reflection — the self-describing surface; read with manual "25.5" Excerpt: this, the reflection wishlist that started the campaign is fully closed: `eval`, `properties`, `arity`, `bindings`, `methods`, `source`, `ast`, and `compile` all exist. ### Multi-line entry — continuation and the dangling `else`

proposition?

Function

Call diagnostics (different branches may describe different overloads): • proposition? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

proprium

Keyword

Ontological relation describing a proper attribute (a property distinct from a definition of essence). See doc "essence" and doc "accident".

prototype

Function

prototype(conceptSet)
Finds the most prototypical concept in a set. Returns the concept with the highest typicality measure.

Examples

prototype({Dog, Cat, Animal})       # Returns Dog

prototype({Bird, Robin, Eagle})     # Most typical bird

best: prototype(vehicles)      # Find best example

prototype_membership

Function

prototype_membership(space, point, prototype_name) - Fuzzy membership Extracted library reference: evaluator/builtin_conceptual.go:464. These notes are not a complete signature or a stability guarantee.

prototypes_of

Function

prototypes_of(space) - Get prototypes Extracted library reference: evaluator/builtin_conceptual.go:304. These notes are not a complete signature or a stability guarantee.

provable

Function

Call diagnostics (different branches may describe different overloads): • provable requires 1 or 2 arguments • provable requires string or Gödel number Extracted library reference: evaluator/builtins.go:6595. These notes are not a complete signature or a stability guarantee.

prove

Keyword

prove goal_expression  |  prove f   (f a contracted function)
Goal-driven theorem proving with detailed proof information including variable bindings and inference chains. When the goal is a bare identifier naming a CONTRACTED FUNCTION, `prove f` is instead the STATIC twin of `check f`: it discharges the function's contract through the SMT solver for EVERY input satisfying requires:, rather than sampling. The verification condition is (requires ∧ result = body) implies ensures, one clause at a time. Verdicts are Belnap: ⊤ᵇ discharged for all inputs (grounding: theorem), ⊥ᵇ refuted with a real counterexample printed, ?ᵇ NOT DISCHARGED — outside the decidable fragment, or the solver was inconclusive. Not-discharged is never reported as refuted: calls to helpers and builtins are uninterpreted in the solver, so a counterexample involving them is an artifact rather than evidence the contract is wrong. Straight-line bodies over Integer/Float/Boolean parameters are in scope, `if`/`else` included; multi-clause functions, indexing, bounded quantifiers and nonlinear multiplication are refused by name. Both spellings work — the statement `prove f`, and the expression `v: prove f` when the verdict is wanted as a value.

Examples

prove mortal("socrates")     # Detailed proof attempt

prove ancestor(X, "alice")   # Find all ancestors of alice

contract inc { requires: x > 0, ensures: result > x }

prove inc                    # ⊤ᵇ — discharged for EVERY x, no sampling

v: prove inc                 # the verdict as a value (the check f twin)

proveIncompleteness

Function

Call diagnostics (different branches may describe different overloads): • proveIncompleteness takes 0 or 1 arguments Extracted library reference: evaluator/builtins.go:6667. These notes are not a complete signature or a stability guarantee.

prune

Keyword

p(X) :- q(X), prune, r(X)
Semantic alias of cut in an explicit Prolog goal. See cut.

pset

Function

Call diagnostics (different branches may describe different overloads): • powerset requires exactly 1 argument: powerset(set) Extracted library reference: evaluator/builtins.go:924. These notes are not a complete signature or a stability guarantee.

pseudo_concept

Function

pseudo_concept(C)
Boolean shortcut for concept-level diagnose() — true when the concept's verdict is vacuously_formed, untestable, or pseudo (no boundary/examples/instances, untestable boundary, or Scheinsatz-class concept). Equivalent to checking diagnose(C).verdict ∈ {vacuously_formed, untestable, pseudo}.

Examples

concept GhostHunter

pseudo_concept(GhostHunter)  # true — bare label only

concept Stock

aapl: a Stock {}

pseudo_concept(Stock)        # false — has an instance

pseudo_statements

Function

pseudo_statements()
Vienna-Circle audit — returns a Set of canonical fact-strings for every stored relational fact that has NO registered verifier (via has_meaning). Advisory in permissive mode (default); pairs with meaning_policy() / set_meaning_policy("strict") for assertion-time enforcement.

Examples

insert("likes", "alice", "bob")

pseudo_statements()  # includes unverified assertion strings

punct?

Function

charPredicate wraps a rune classifier as a builtin accepting a Character or a one-character String. Call diagnostics (different branches may describe different overloads): • punct? requires exactly 1 argument Extracted library reference: evaluator/character.go:81. These notes are not a complete signature or a stability guarantee.

push

Function

push(stack | array, value)
Pushes a value onto the top of a stack, or appends it to an array IN PLACE (July 2026 dynamic-array flip) — both return the same, grown collection. copy() the array first for a functional version.

Examples

s: stack()

push(s, 42)

a: [1, 2]

push(a, 3)  # a is now [1, 2, 3]

puts

Function

Extracted library reference: evaluator/builtins.go:5943. These notes are not a complete signature or a stability guarantee. Manual §28.3 28.3 `[monkey | … ]` — a whole language, in-process; read with manual "28.3" Excerpt: |-------------------------|-----------------------------------------------| | `[monkey \| … ]` | everything `puts` wrote, as a `String` | | `[monkey/eval \| … ]` | the program's final value, typed | Any other mode is rejected before the body runs.

qdup

Function

Conditional operations Call diagnostics (different branches may describe different overloads): • argument to qdup must be a stack • qdup requires 1 argument: stack Extracted library reference: evaluator/builtins.go:12420. These notes are not a complete signature or a stability guarantee.

qed

Symbol

=== ∴ (Glyph) === name: therefore words: therefore latex: therefore, qed, thus category: logic codepoint: U+2234 meaning: p ∴ q — therefore / QED (the conclusion / inference mark; canonicalizes to the `therefore` operator)

ql

Function

ql(text) — parse a formula in the book's exact notation (¬ ∧ ∨ ⊃ ≡, ∀x/∃x/∃!x, juxtaposed predicates Fx/Gxy/Kab, identity = ≠, modal □ ◇) and return its canonical book-notation rendering. The ⊃ here is the conditional — inside ql() the book's reading always wins. Example: ql("∀x(Fx ⊃ Gx)") Call diagnostics (different branches may describe different overloads): • ql requires 1 argument: formula text • ql: argument must be a string Extracted library reference: evaluator/builtins.go:17381. These notes are not a complete signature or a stability guarantee.

ql_decide

Function

ql_decide(argument [, maxDomain]) — bounded countermodel search for the book's exercise form "premises ∴ conclusion" (e.g. the p. 70 block). Monadic arguments are decided outright; relational ones get a capped search. Returns {invalid, verdict, countermodel}. Example: ql_decide("∃x¬Fx ∴ ¬∃xFx") Call diagnostics (different branches may describe different overloads): • ql_decide requires 1-2 arguments: argument text [, max domain size] • ql_decide: first argument must be a string • ql_decide: max domain size must be an integer Extracted library reference: evaluator/builtins.go:17480. These notes are not a complete signature or a stability guarantee.

ql_eval

Function

ql_eval(formula, interp) — truth of a non-modal QL/QLI formula in a finite interpretation (ch. 3 semantics). interp is a hash: {domain: [1, 2], a: 1, F: [1], K: [[1, 2]], p: true} where lowercase a–e keys assign constants, uppercase keys give predicate extensions (n-ary as arrays of arrays), and boolean values are sentence letters. Example: ql_eval("∀x(Fx ⊃ Gx)", {domain: [1,2], F: [1], G: [1,2]}) Call diagnostics (different branches may describe different overloads): • ql_eval requires 2 arguments: formula text, interpretation hash • ql_eval: first argument must be a string Extracted library reference: evaluator/builtins.go:17449. These notes are not a complete signature or a stability guarantee.

qr

Function

Call diagnostics (different branches may describe different overloads): • argument to qr must be a matrix • qr requires exactly 1 argument: matrix Extracted library reference: evaluator/builtins.go:14255. These notes are not a complete signature or a stability guarantee.

qty

Function

qty(magnitude, unit)
Constructs a Quantity — an exact rational tagged with an SI or custom dimension. The unit is a Quantity (`kg`) or a string (`"kg"`, `"m/s^2"`). Nullary `qty()` is refused. `qty(1, kg) == qty(1000, gram)` is true; `qty(1, kg) == 1` is an error (the Money precedent). Not Money and not Magnitude.

Examples

qty(5, kg)

qty(9.8, metre / sec^2)

qty(1, "kg*m/s^2")

qua

Operator

fact qua "handle"
Frames a fact under a specific value-laden aspect or perspective. Allows rules to behave differently depending on the framing.

Examples

departed("estate") qua "lost"

departed("estate") qua "given_back"

quasiquote

Keyword

quasiquote(expression)
Returns the AST of the expression, but evaluates any nested `unquote()` expressions. Used in macros.

Examples

y: 10

quasiquote(1 + unquote(y) * z)  # AST for 1 + 10 * z

quay

Reserved vocabulary

Reserved vocabulary with no dedicated parser implementation in this build. It is not a usable standalone form. Use doc "discover" for the implemented discovery interface, and manual for supported language forms. Recognition of a name is not a claim that its intended feature is implemented.

query

Keyword

query goal_expression
Backward-chaining query system. Tests if a goal can be proven using available facts and rules.

Examples

query mortal("socrates")     # Test specific fact

query human(X)               # Find all humans

query parent("john", Child)  # Find john's children

query grandparent(GP, GC)    # Find all grandparent pairs

query_fol

Function

query_fol(question) - Convert natural language question to FOL query Call diagnostics (different branches may describe different overloads): • query_fol argument must be a string • query_fol requires exactly 1 argument (question) Extracted library reference: evaluator/builtins.go:20623. These notes are not a complete signature or a stability guarantee.

query_prob

Function

query_prob(kb, formula) - Query probability of a formula Example: query_prob(kb, "flies(tweety)") → 0.95 Call diagnostics (different branches may describe different overloads): • first argument must be a probabilistic logic KB • query_prob requires 2 arguments: kb, formula • second argument must be a string (formula) Extracted library reference: evaluator/builtins.go:19086. These notes are not a complete signature or a stability guarantee.

query_prob_conditional

Function

query_prob_conditional(kb, formula, condition) - Query P(formula|condition) Example: query_prob_conditional(kb, "wet_grass", "raining") → 0.9 Call diagnostics (different branches may describe different overloads): • first argument must be a probabilistic logic KB • query_prob_conditional requires 3 arguments: kb, formula, condition • second argument must be a string (formula) • third argument must be a string (condition) Extracted library reference: evaluator/builtins.go:19111. These notes are not a complete signature or a stability guarantee.

qui

Reserved vocabulary

Reserved vocabulary with no dedicated parser implementation in this build. It is not a usable standalone form. Use doc "discover" for the implemented discovery interface, and manual for supported language forms. Recognition of a name is not a claim that its intended feature is implemented.

quote

Keyword

quote(expr)   |   quote <token>
Two forms, disambiguated by what follows. `quote(expr)` is the Lisp-metaprogramming form: returns the AST without evaluating. `quote <token>` (no parens) is the etymology / citation form: prints word origin and 3-5 famous quotes from canonical primary sources for any Axioma keyword, operator, function name, or punctuation. Uncurated tokens fall through to an LLM (tagged) when an API key is configured.

Examples

quote(1 + 2)                  # Lisp form — returns AST node

quote(map(func(n) [n * 2], xs))

quote concept                 # Aristotle, Kant, Frege, Schopenhauer

quote isa                     # IS-A etymology (the isa spelling is retired — the copula is `is`)

quote +                       # Widmann 1489, Peano, Frege

quote lambda                  # Church 1936

quote ∀                       # Gentzen 1935

quote "law of excluded middle"   # string-key for multi-word

quotient

Function

a quotient b | quotient(a, b)
Returns the integer (floor) quotient of dividing a by b. Same-line infix alias of `div` / `idiv` / `÷` (identical AST), and also a prefix builtin `quotient(a, b)`. Division FLOORS (rounds toward −∞) on every numeric kind; mixed operands coerce to float. Divisor 0 raises an error. Companion of `remainder`; `divmod(a, b)` returns both at once. As a soft keyword, infix `quotient` is only an operator between two expressions on the same line; `quotient: 5` is still an ordinary binding.

Examples

8 quotient 7       # Returns 1    (infix, same as 8 div 7)

quotient(100, 7)   # Returns 14   (prefix)

quotient(-7, 3)    # Returns -3   (floor, toward -inf — not -2)

div(-7, 3)         # Returns -3   (prefix form of the div keyword)

100 ÷ 7            # Returns 14   (glyph form)

100 div 7          # Returns 14   (infix keyword form)

quotient(100, 0)   # ERROR: quotient by zero

quu

Reserved vocabulary

Reserved vocabulary with no dedicated parser implementation in this build. It is not a usable standalone form. Use doc "discover" for the implemented discovery interface, and manual for supported language forms. Recognition of a name is not a claim that its intended feature is implemented.

rad

Function

rad(x)
Converts an angle from degrees to radians (x * π/180 — Lua's math.rad). Feed degree-valued inputs to the radian-based trig family through it.

Examples

rad(180)      # Returns pi

sin(rad(90))  # Returns 1

raise

Function

raise(x)
Propagate x: wrap a string, or re-arm an Error. Uncaught, that evaluation stops (script exit 1; REPL prints and the next prompt appears).

Examples

raise("printdots: negative input")

try(raise("x"))

rand_matrix

Function

Call diagnostics (different branches may describe different overloads): • cols must be an integer • matrix dimensions must be positive • rand_matrix requires exactly 2 arguments: rows, cols • rows must be an integer Extracted library reference: evaluator/builtins.go:13822. These notes are not a complete signature or a stability guarantee.

random

Function

random() | random(n) | random(m, n)
Pseudo-random draw from the language's one seedable source (Lua's math.random surface): no arguments → a Float in [0, 1); random(n) → an Integer in 1..n; random(m, n) → an Integer in m..n inclusive. SEEDING MODEL: the source starts with the FIXED seed 1 (the Programming-in-Lua model), so unseeded runs replay the same sequence — use random_seed() to opt into entropy. The same source drives the distribution samplers (sample(normal(...), n)).

Examples

random()        # Float in [0, 1)

random(6)       # die roll: Integer in 1..6

random(10, 20)  # Integer in 10..20 inclusive

random_seed

Function

random_seed(n) | random_seed()
Seeds the shared pseudo-random source. random_seed(n) selects a deterministic stream (returns n) — call it first when a test or doctest pins drawn values. random_seed() with no arguments seeds from OS entropy and RETURNS the seed it chose, so a 'fresh' run can still be logged and replayed — the modern replacement for Lua's randomseed(os.time()) trick. Governs random/shuffle/sample AND the probability-distribution samplers.

Examples

random_seed(42)       # deterministic stream; returns 42

s: random_seed()      # entropy; s is the replayable seed

range

Function

range(stop) or range(start, stop[, step])
Builds a RANGE of integers from start to stop, 1-based and INCLUSIVE at both ends — the call spelling of the `..` operator, so range(1, 5) == 1..5. A negative step counts downward. Wrap in array() for the materialized list. It returned an eager Array until July 2026. The literal form additionally offers `..<`, `by` steps, open-ended `n..` and character ranges ("a".."e") — see `doc ".."`.

Examples

range(5)                 # 1..5

array(range(5))          # [1, 2, 3, 4, 5]

array(range(1, 10, 2))   # [1, 3, 5, 7, 9]

array(range(5, 1, -1))   # [5, 4, 3, 2, 1]

range(1, 5) == 1..5      # true

ranges

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §4.8 Ranges — ordered `a..b`, exclusive `..<`, `by` step, open `n..`; read with manual "4.8" Excerpt: ### Ranges — ordered `a..b`, exclusive `..<`, `by` step, open `n..` `a..b` is a first-class **ordered** `Range` value — it knows its direction, its step, and (optionally) that it has no end. It displays compactly, tests

rank

Function

Call diagnostics (different branches may describe different overloads): • argument to rank must be a matrix • rank requires exactly 1 argument: matrix Extracted library reference: evaluator/builtins.go:13993. These notes are not a complete signature or a stability guarantee. Manual §5.14 Matrices, tensors & dataframes; read with manual "5.14" Excerpt: ```axioma t: tensor([[[1, 2], [3, 4]], [[5, 6], [7, 8]]]) # rank-3 from nesting shape(t) # → [2, 2, 2] ; ndim(t) → 3 tensor([2, 3], 7) # shape + fill → 2×3 of 7s tensor_reshape(tensor([1, 2, 3, 4, 5, 6]), [2, 3]) # → 2×3

rational

Function

rational(numerator, denominator)
Exact rational n/d (normalizes; demotes to Integer when whole). Manual §4.1 Primitives; read with manual "4.1" Excerpt: | `Float` | `3.14159`, `-2.5`, `0.75`, `1.5e6`, `3.14e-2`, `1E+9`, `0x1p-1`, `0xA.Bp2` | IEEE 754 double — **the type is `Float`**, not `Float64` and not `FLOAT`. `:: Float64` names no type (did-you-mean `:: Float`). Scientific notation `e`/`E` ± optional sign; **hexadecimal floats** (Go/C99 syntax — binary exponent `p`/`P` **required**: `0x1p-1` = 2⁻¹ = `0.5`, `0xa.bp2` = `42.75`, `0x2.p3` = `16.0`). The exponent is what distinguishes a hex float from a hex integer (`0x10` stays `Integer` 16), keeps `0xFE`/`0x1E` reading `e`/`E` as digits, and keeps `0x15e-2` a subtraction. Lua's exponentless fraction `0x0.2` is deliberately rejected with a hint (write `0x0.2p0`, or evaluate the Lua form via `[lua/eval \| 0x0.2 ]`). **Display** is the shortest decimal that round-trips the bits: a whole value keeps `.0` (`1.0` not `1`), IEEE remainders are not rounded away (`sin(3.1415926/2)` is `0.9999999999999997`, `0.1+0.2` is `0.30000000000000004`), infinities print `Inf`/`-Inf`, and `eval(string(x))` recovers a Float | | `Rational` | `1/3`, `rational(2, 6)` → `1/3` | Exact `p/q` on big integers, GCD-reduced — `/` on integers stays exact (`1/3 + 1/6` → `1/2`, never `0.4999…`); accessors `numerator(r)` / `denominator(r)` | | `Complex` | `complex(3, 4)` → `3.0 + 4.0i`; `im` → `i` | The **top of the numeric tower** — every other numeric type embeds, so `complex(3, 4) + 1/2` → `3.5 + 4i`. The unit is the shadowable builtin `im` (`complex(0, 1)`); write `1 + im`, `(1 + im)^2` → `2i`, `2 * im`. No juxtaposed literal: `2im` is diagnosed (same as `2x`). Full arithmetic incl. `^` (exact at integer exponents: `im^2` → `-1`) and unary minus; `sqrt`/`exp`/`log`/`sin`/`cos`/`abs`/`conjugate` all accept one. No ordering. Embedding is via `float64`, so exactness stops here. Coefficients use the same Float printer | | `String` | `"hello"`, `"unicode: ∀∃"`, `"\u{2203}"`, `r"raw \n"` | UTF-8; escape sequences + `r"..."` raw prefix — see [Strings](#strings--escape-sequences-raw-form-codepoint-builtins) | | `Boolean` | `true`, `false` | Classical two-valued |

rational?

Function

Call diagnostics (different branches may describe different overloads): • rational? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

rationals

Value

Built-in INFINITE_SET value: InfiniteSet(rationals) Manual §5.10.1 Ellipsis sets — textbook `{2, 4, ..., 100}` / `{2, 4, 6, ...}`; read with manual "5.10.1" Excerpt: **The standard number sets.** The chain **ℕ ⊂ ℤ ⊂ ℚ ⊂ ℝ ⊂ ℂ** is built in. The identifiers `rationals` / `reals` / `complexes` and the glyphs `ℚ` / `ℝ` / `ℂ` are membership sets: ```axioma

rclear

Function

Extracted library reference: evaluator/return_stack.go:32. These notes are not a complete signature or a stability guarantee. Manual §13.37 Hidden slots, scanners, turtles, and concatenative extras; read with manual "13.37" Excerpt: `effect: "( n -- n^2 )"` with `word_effect` / `check_effect`; return stack `rpush` / `rpop` / `rpeek` / `rdepth` / `rclear`. `#language axioma/rpn` is additive (infix still runs). Textbook: HtDKP-in-Axioma Chapter 41. Logo selectors: `butfirst`, `butlast`, `logo_item`, `sentence`.

rdepth

Function

Extracted library reference: evaluator/return_stack.go:29. These notes are not a complete signature or a stability guarantee. Manual §13.37 Hidden slots, scanners, turtles, and concatenative extras; read with manual "13.37" Excerpt: `effect: "( n -- n^2 )"` with `word_effect` / `check_effect`; return stack `rpush` / `rpop` / `rpeek` / `rdepth` / `rclear`. `#language axioma/rpn` is additive (infix still runs). Textbook: HtDKP-in-Axioma Chapter 41. Logo selectors: `butfirst`, `butlast`, `logo_item`, `sentence`.

rdiv

Operator

a rdiv b | rdiv(a, b)
Exact/true division — the word alias of `/`. Same-line soft infix keyword (PRODUCT, left-associative) synthesizing the identical AST operator `/`, and a prefix builtin `rdiv(a, b)` that hands its operands to `/`. Two integers yield a Rational, or an Integer when the quotient is whole. Float operands follow `/` into floating division. `rdiv: 5` is still an ordinary binding. Not `fdiv` (always Float) and not `idiv`/`div` (floor).

Examples

1 rdiv 8           # Returns 1/8

rdiv(1, 8)         # Returns 1/8

8 rdiv 2           # Returns 4     (whole quotient stays Integer)

1.0 rdiv 8.0       # Returns 0.125 (Float, same as /)

re

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §29.4 Constructing & re-raising; read with manual "29.4" Excerpt: ### Constructing & re-raising ```axioma b: error("boom", "fix it") # build an inert error VALUE (does not stop)

read

Function

REBOL-style read function Call diagnostics (different branches may describe different overloads): • read requires exactly 1 argument Extracted library reference: evaluator/builtins.go:6087. These notes are not a complete signature or a stability guarantee. Manual §4.7.6 `read` and file I/O; read with manual "4.7.6" Excerpt: #### `read` and file I/O `read(source)` is the file/URL read verb — one argument, returns a `String`:

read_boolean

Function

read_boolean()
Reads the next whitespace-separated token from stdin as a Boolean (true or false). EOF is none; a bad token is an Error.

Examples

ok: read_boolean()

read_byte

Function

read_byte()
Reads the next whitespace-separated token from stdin as a Byte (0..255). EOF is none; a bad token or a value outside 0..255 is an Error.

Examples

b: read_byte()

read_bytes

Function

===== File I/O ===== Call diagnostics (different branches may describe different overloads): • read_bytes requires exactly 1 argument (file path) Extracted library reference: evaluator/builtin_bytes.go:456. These notes are not a complete signature or a stability guarantee. Manual §4.6.2 Conversions (explicit + fallible); read with manual "4.6.2" Excerpt: | `base64_encode(bs)` / `base64_decode(s)` | round-trip | decoder errors on bad input | | `read_bytes(path)` / `write_bytes(path, bs)` | file I/O | path missing / permission | #### Bitwise ops — word-form infix (v3) + functional form

read_complex

Function

read_complex()
Reads the next whitespace-separated token from stdin as a Complex. Use the compact spelling 3+4i (spaces would split tokens). EOF is none; a bad token is an Error.

Examples

z: read_complex()  # 3+4i

read_csv

Function

read_csv(path, [options])
Read CSV as a DataFrame. Options: schema, delimiter, header, na_strings, extra_columns (reject/ignore), on_error (fail). Schema parsing preserves String cells and reports source records. Manual §5.14 Matrices, tensors & dataframes; read with manual "5.14" Excerpt: `read_csv(path)` loads a file into a `DataFrame`, and `write_csv(df, path [, options])` writes one back (2026-08-27) — options `{delimiter: ";", header: false, na: "NA"}`; it returns the path, and integer cells keep their **exact digits** however large, so write∘read∘write is a fixed

read_f32_be

Function

endianReadBuiltin returns a BuiltinFunction for the read_TYPE_ENDIAN family: read(bs, offset) → value. Offset is 1-based (Axioma indexing convention). Returns Integer for fixed-width ints (with sign extension for signed variants), Float for f32/f64. Call diagnostics (different branches may describe different overloads): • read_f32_be requires exactly 2 arguments (Bytes, offset) Extracted library reference: evaluator/builtin_bytes.go:513. These notes are not a complete signature or a stability guarantee. Manual §4.6.9 Endian-aware read/write at offset (v3); read with manual "4.6.9" Excerpt: | `read_i64_be` / `read_i64_le` | Integer | signed 64-bit | | `read_f32_be` / `read_f32_le` | Float | IEEE 754 single | | `read_f64_be` / `read_f64_le` | Float | IEEE 754 double | | `write_*` (same suffix family) | Bytes | new copy with field overwritten |

read_f32_le

Function

endianReadBuiltin returns a BuiltinFunction for the read_TYPE_ENDIAN family: read(bs, offset) → value. Offset is 1-based (Axioma indexing convention). Returns Integer for fixed-width ints (with sign extension for signed variants), Float for f32/f64. Call diagnostics (different branches may describe different overloads): • read_f32_le requires exactly 2 arguments (Bytes, offset) Extracted library reference: evaluator/builtin_bytes.go:513. These notes are not a complete signature or a stability guarantee. Manual §4.6.9 Endian-aware read/write at offset (v3); read with manual "4.6.9" Excerpt: | `read_i64_be` / `read_i64_le` | Integer | signed 64-bit | | `read_f32_be` / `read_f32_le` | Float | IEEE 754 single | | `read_f64_be` / `read_f64_le` | Float | IEEE 754 double | | `write_*` (same suffix family) | Bytes | new copy with field overwritten |

read_f64_be

Function

endianReadBuiltin returns a BuiltinFunction for the read_TYPE_ENDIAN family: read(bs, offset) → value. Offset is 1-based (Axioma indexing convention). Returns Integer for fixed-width ints (with sign extension for signed variants), Float for f32/f64. Call diagnostics (different branches may describe different overloads): • read_f64_be requires exactly 2 arguments (Bytes, offset) Extracted library reference: evaluator/builtin_bytes.go:513. These notes are not a complete signature or a stability guarantee. Manual §4.6.9 Endian-aware read/write at offset (v3); read with manual "4.6.9" Excerpt: | `read_f32_be` / `read_f32_le` | Float | IEEE 754 single | | `read_f64_be` / `read_f64_le` | Float | IEEE 754 double | | `write_*` (same suffix family) | Bytes | new copy with field overwritten | ```axioma

read_f64_le

Function

endianReadBuiltin returns a BuiltinFunction for the read_TYPE_ENDIAN family: read(bs, offset) → value. Offset is 1-based (Axioma indexing convention). Returns Integer for fixed-width ints (with sign extension for signed variants), Float for f32/f64. Call diagnostics (different branches may describe different overloads): • read_f64_le requires exactly 2 arguments (Bytes, offset) Extracted library reference: evaluator/builtin_bytes.go:513. These notes are not a complete signature or a stability guarantee. Manual §4.6.9 Endian-aware read/write at offset (v3); read with manual "4.6.9" Excerpt: | `read_f32_be` / `read_f32_le` | Float | IEEE 754 single | | `read_f64_be` / `read_f64_le` | Float | IEEE 754 double | | `write_*` (same suffix family) | Bytes | new copy with field overwritten | ```axioma

read_float

Function

read_float()
Reads the next whitespace-separated token from stdin as a Float. EOF is none; a bad token is an Error.

Examples

x: read_float()

read_i16_be

Function

endianReadBuiltin returns a BuiltinFunction for the read_TYPE_ENDIAN family: read(bs, offset) → value. Offset is 1-based (Axioma indexing convention). Returns Integer for fixed-width ints (with sign extension for signed variants), Float for f32/f64. Call diagnostics (different branches may describe different overloads): • read_i16_be requires exactly 2 arguments (Bytes, offset) Extracted library reference: evaluator/builtin_bytes.go:513. These notes are not a complete signature or a stability guarantee. Manual §4.6.9 Endian-aware read/write at offset (v3); read with manual "4.6.9" Excerpt: | `read_u16_be(bs, off)` / `read_u16_le(bs, off)` | Integer 0..65535 | unsigned 16-bit | | `read_i16_be` / `read_i16_le` | Integer ±32767 | signed 16-bit (sign-extended) | | `read_u32_be` / `read_u32_le` | Integer 0..2^32-1 | unsigned 32-bit | | `read_i32_be` / `read_i32_le` | Integer ±2^31 | signed 32-bit | | `read_u64_be` / `read_u64_le` | Integer | may wrap to negative for > int64 max |

read_i16_le

Function

endianReadBuiltin returns a BuiltinFunction for the read_TYPE_ENDIAN family: read(bs, offset) → value. Offset is 1-based (Axioma indexing convention). Returns Integer for fixed-width ints (with sign extension for signed variants), Float for f32/f64. Call diagnostics (different branches may describe different overloads): • read_i16_le requires exactly 2 arguments (Bytes, offset) Extracted library reference: evaluator/builtin_bytes.go:513. These notes are not a complete signature or a stability guarantee. Manual §4.6.9 Endian-aware read/write at offset (v3); read with manual "4.6.9" Excerpt: | `read_u16_be(bs, off)` / `read_u16_le(bs, off)` | Integer 0..65535 | unsigned 16-bit | | `read_i16_be` / `read_i16_le` | Integer ±32767 | signed 16-bit (sign-extended) | | `read_u32_be` / `read_u32_le` | Integer 0..2^32-1 | unsigned 32-bit | | `read_i32_be` / `read_i32_le` | Integer ±2^31 | signed 32-bit | | `read_u64_be` / `read_u64_le` | Integer | may wrap to negative for > int64 max |

read_i32_be

Function

endianReadBuiltin returns a BuiltinFunction for the read_TYPE_ENDIAN family: read(bs, offset) → value. Offset is 1-based (Axioma indexing convention). Returns Integer for fixed-width ints (with sign extension for signed variants), Float for f32/f64. Call diagnostics (different branches may describe different overloads): • read_i32_be requires exactly 2 arguments (Bytes, offset) Extracted library reference: evaluator/builtin_bytes.go:513. These notes are not a complete signature or a stability guarantee. Manual §4.6.9 Endian-aware read/write at offset (v3); read with manual "4.6.9" Excerpt: | `read_u32_be` / `read_u32_le` | Integer 0..2^32-1 | unsigned 32-bit | | `read_i32_be` / `read_i32_le` | Integer ±2^31 | signed 32-bit | | `read_u64_be` / `read_u64_le` | Integer | may wrap to negative for > int64 max | | `read_i64_be` / `read_i64_le` | Integer | signed 64-bit | | `read_f32_be` / `read_f32_le` | Float | IEEE 754 single |

read_i32_le

Function

endianReadBuiltin returns a BuiltinFunction for the read_TYPE_ENDIAN family: read(bs, offset) → value. Offset is 1-based (Axioma indexing convention). Returns Integer for fixed-width ints (with sign extension for signed variants), Float for f32/f64. Call diagnostics (different branches may describe different overloads): • read_i32_le requires exactly 2 arguments (Bytes, offset) Extracted library reference: evaluator/builtin_bytes.go:513. These notes are not a complete signature or a stability guarantee. Manual §4.6.9 Endian-aware read/write at offset (v3); read with manual "4.6.9" Excerpt: | `read_u32_be` / `read_u32_le` | Integer 0..2^32-1 | unsigned 32-bit | | `read_i32_be` / `read_i32_le` | Integer ±2^31 | signed 32-bit | | `read_u64_be` / `read_u64_le` | Integer | may wrap to negative for > int64 max | | `read_i64_be` / `read_i64_le` | Integer | signed 64-bit | | `read_f32_be` / `read_f32_le` | Float | IEEE 754 single |

read_i64_be

Function

endianReadBuiltin returns a BuiltinFunction for the read_TYPE_ENDIAN family: read(bs, offset) → value. Offset is 1-based (Axioma indexing convention). Returns Integer for fixed-width ints (with sign extension for signed variants), Float for f32/f64. Call diagnostics (different branches may describe different overloads): • read_i64_be requires exactly 2 arguments (Bytes, offset) Extracted library reference: evaluator/builtin_bytes.go:513. These notes are not a complete signature or a stability guarantee. Manual §4.6.9 Endian-aware read/write at offset (v3); read with manual "4.6.9" Excerpt: | `read_u64_be` / `read_u64_le` | Integer | may wrap to negative for > int64 max | | `read_i64_be` / `read_i64_le` | Integer | signed 64-bit | | `read_f32_be` / `read_f32_le` | Float | IEEE 754 single | | `read_f64_be` / `read_f64_le` | Float | IEEE 754 double | | `write_*` (same suffix family) | Bytes | new copy with field overwritten |

read_i64_le

Function

endianReadBuiltin returns a BuiltinFunction for the read_TYPE_ENDIAN family: read(bs, offset) → value. Offset is 1-based (Axioma indexing convention). Returns Integer for fixed-width ints (with sign extension for signed variants), Float for f32/f64. Call diagnostics (different branches may describe different overloads): • read_i64_le requires exactly 2 arguments (Bytes, offset) Extracted library reference: evaluator/builtin_bytes.go:513. These notes are not a complete signature or a stability guarantee. Manual §4.6.9 Endian-aware read/write at offset (v3); read with manual "4.6.9" Excerpt: | `read_u64_be` / `read_u64_le` | Integer | may wrap to negative for > int64 max | | `read_i64_be` / `read_i64_le` | Integer | signed 64-bit | | `read_f32_be` / `read_f32_le` | Float | IEEE 754 single | | `read_f64_be` / `read_f64_le` | Float | IEEE 754 double | | `write_*` (same suffix family) | Bytes | new copy with field overwritten |

read_integer

Function

read_integer()
Reads the next whitespace-separated token from stdin as an Integer (exact, any size). Skips spaces and newlines. EOF is none; a token that is not an integer is an Error. Two numbers on one line are two calls. A whole line of text is readline(); input_number() retries until the line is a number.

Examples

n: read_integer()

a: read_integer(); b: read_integer()  # 3 4 on one line is fine

read_rational

Function

read_rational()
Reads the next whitespace-separated token from stdin as a Rational. Write 3/4 as one token (no spaces). EOF is none; a bad token is an Error.

Examples

q: read_rational()  # 3/4

read_string

Function

read_string()
Reads the next whitespace-separated word from stdin. EOF is none. A whole line (spaces included) is readline().

Examples

word: read_string()

read_u16_be

Function

endianReadBuiltin returns a BuiltinFunction for the read_TYPE_ENDIAN family: read(bs, offset) → value. Offset is 1-based (Axioma indexing convention). Returns Integer for fixed-width ints (with sign extension for signed variants), Float for f32/f64. Call diagnostics (different branches may describe different overloads): • read_u16_be requires exactly 2 arguments (Bytes, offset) Extracted library reference: evaluator/builtin_bytes.go:513. These notes are not a complete signature or a stability guarantee. Manual §4.6.9 Endian-aware read/write at offset (v3); read with manual "4.6.9" Excerpt: |---|---|---| | `read_u16_be(bs, off)` / `read_u16_le(bs, off)` | Integer 0..65535 | unsigned 16-bit | | `read_i16_be` / `read_i16_le` | Integer ±32767 | signed 16-bit (sign-extended) | | `read_u32_be` / `read_u32_le` | Integer 0..2^32-1 | unsigned 32-bit | | `read_i32_be` / `read_i32_le` | Integer ±2^31 | signed 32-bit |

read_u16_le

Function

endianReadBuiltin returns a BuiltinFunction for the read_TYPE_ENDIAN family: read(bs, offset) → value. Offset is 1-based (Axioma indexing convention). Returns Integer for fixed-width ints (with sign extension for signed variants), Float for f32/f64. Call diagnostics (different branches may describe different overloads): • read_u16_le requires exactly 2 arguments (Bytes, offset) Extracted library reference: evaluator/builtin_bytes.go:513. These notes are not a complete signature or a stability guarantee. Manual §4.6.9 Endian-aware read/write at offset (v3); read with manual "4.6.9" Excerpt: |---|---|---| | `read_u16_be(bs, off)` / `read_u16_le(bs, off)` | Integer 0..65535 | unsigned 16-bit | | `read_i16_be` / `read_i16_le` | Integer ±32767 | signed 16-bit (sign-extended) | | `read_u32_be` / `read_u32_le` | Integer 0..2^32-1 | unsigned 32-bit | | `read_i32_be` / `read_i32_le` | Integer ±2^31 | signed 32-bit |

read_u32_be

Function

endianReadBuiltin returns a BuiltinFunction for the read_TYPE_ENDIAN family: read(bs, offset) → value. Offset is 1-based (Axioma indexing convention). Returns Integer for fixed-width ints (with sign extension for signed variants), Float for f32/f64. Call diagnostics (different branches may describe different overloads): • read_u32_be requires exactly 2 arguments (Bytes, offset) Extracted library reference: evaluator/builtin_bytes.go:513. These notes are not a complete signature or a stability guarantee. Manual §4.6.9 Endian-aware read/write at offset (v3); read with manual "4.6.9" Excerpt: | `read_i16_be` / `read_i16_le` | Integer ±32767 | signed 16-bit (sign-extended) | | `read_u32_be` / `read_u32_le` | Integer 0..2^32-1 | unsigned 32-bit | | `read_i32_be` / `read_i32_le` | Integer ±2^31 | signed 32-bit | | `read_u64_be` / `read_u64_le` | Integer | may wrap to negative for > int64 max | | `read_i64_be` / `read_i64_le` | Integer | signed 64-bit |

read_u32_le

Function

endianReadBuiltin returns a BuiltinFunction for the read_TYPE_ENDIAN family: read(bs, offset) → value. Offset is 1-based (Axioma indexing convention). Returns Integer for fixed-width ints (with sign extension for signed variants), Float for f32/f64. Call diagnostics (different branches may describe different overloads): • read_u32_le requires exactly 2 arguments (Bytes, offset) Extracted library reference: evaluator/builtin_bytes.go:513. These notes are not a complete signature or a stability guarantee. Manual §4.6.9 Endian-aware read/write at offset (v3); read with manual "4.6.9" Excerpt: | `read_i16_be` / `read_i16_le` | Integer ±32767 | signed 16-bit (sign-extended) | | `read_u32_be` / `read_u32_le` | Integer 0..2^32-1 | unsigned 32-bit | | `read_i32_be` / `read_i32_le` | Integer ±2^31 | signed 32-bit | | `read_u64_be` / `read_u64_le` | Integer | may wrap to negative for > int64 max | | `read_i64_be` / `read_i64_le` | Integer | signed 64-bit |

read_u64_be

Function

endianReadBuiltin returns a BuiltinFunction for the read_TYPE_ENDIAN family: read(bs, offset) → value. Offset is 1-based (Axioma indexing convention). Returns Integer for fixed-width ints (with sign extension for signed variants), Float for f32/f64. Call diagnostics (different branches may describe different overloads): • read_u64_be requires exactly 2 arguments (Bytes, offset) Extracted library reference: evaluator/builtin_bytes.go:513. These notes are not a complete signature or a stability guarantee. Manual §4.6.9 Endian-aware read/write at offset (v3); read with manual "4.6.9" Excerpt: | `read_i32_be` / `read_i32_le` | Integer ±2^31 | signed 32-bit | | `read_u64_be` / `read_u64_le` | Integer | may wrap to negative for > int64 max | | `read_i64_be` / `read_i64_le` | Integer | signed 64-bit | | `read_f32_be` / `read_f32_le` | Float | IEEE 754 single | | `read_f64_be` / `read_f64_le` | Float | IEEE 754 double |

read_u64_le

Function

endianReadBuiltin returns a BuiltinFunction for the read_TYPE_ENDIAN family: read(bs, offset) → value. Offset is 1-based (Axioma indexing convention). Returns Integer for fixed-width ints (with sign extension for signed variants), Float for f32/f64. Call diagnostics (different branches may describe different overloads): • read_u64_le requires exactly 2 arguments (Bytes, offset) Extracted library reference: evaluator/builtin_bytes.go:513. These notes are not a complete signature or a stability guarantee. Manual §4.6.9 Endian-aware read/write at offset (v3); read with manual "4.6.9" Excerpt: | `read_i32_be` / `read_i32_le` | Integer ±2^31 | signed 32-bit | | `read_u64_be` / `read_u64_le` | Integer | may wrap to negative for > int64 max | | `read_i64_be` / `read_i64_le` | Integer | signed 64-bit | | `read_f32_be` / `read_f32_le` | Float | IEEE 754 single | | `read_f64_be` / `read_f64_le` | Float | IEEE 754 double |

readline

Function

readline()  |  readline(path)
Reads one line from stdin, or the first line of a file (String path or %file literal). The trailing newline is stripped. EOF and an empty file answer none (falsy); a blank line answers "" (truthy). A 1-argument call is a path, never a prompt — write input(msg), or print(msg) then readline(), for a prompt.

Examples

line: readline()

first: readline("notes.txt")

print("Your name? "); name: readline()

while line [ println(line); line: readline() ]  # line: readline() first

readlines

Function

readlines()  |  readlines(path)
Reads remaining stdin, or every line of a file, as an Array of strings (newlines stripped). Same split as io.read_lines: no phantom trailing empty line; an empty file is []. 0-arg is stdin; 1-arg is a path, never a prompt. eachline is the exact alias (the for-loop spelling).

Examples

lines: readlines("notes.txt")

for line in eachline("notes.txt") [ println(line) ]

real

Function

real(z)
Real part of a Complex number. Manual §9.3 Łukasiewicz L3 (real-valued); read with manual "9.3" Excerpt: ### Łukasiewicz L3 (real-valued) Continuous truth values in `[0, 1]`; the three canonical points have literals `⊤ł` (1.0), `½ł` (0.5), `⊥ł` (0.0).

really

Keyword

Definition qualifier in a real-definition expression, distinguished from nominal definitions. See doc "nominally".

reals

Value

Built-in INFINITE_SET value: InfiniteSet(reals) Manual §5.10.1 Ellipsis sets — textbook `{2, 4, ..., 100}` / `{2, 4, 6, ...}`; read with manual "5.10.1" Excerpt: **The standard number sets.** The chain **ℕ ⊂ ℤ ⊂ ℚ ⊂ ℝ ⊂ ℂ** is built in. The identifiers `rationals` / `reals` / `complexes` and the glyphs `ℚ` / `ℝ` / `ℂ` are membership sets: ```axioma

rebind

Keyword

rebind NAME = value   |   rebind NAME: value
Writes through to the nearest enclosing binding of NAME — the way a function body reaches a name outside its own frame. Never declares: an unbound name is an error. Takes `:` or `=`. v1 is plain identifiers only (`rebind p.x:` is refused). Not `global` (Julia's module write).

Examples

counter: 0
bump: func() [rebind counter: counter + 1]

recip

Function

recip(number)
The multiplicative inverse — `1 / x`, and nothing else. It goes through the same numeric cores the `/` operator uses, which is the point: division in Axioma is EXACT, so the reciprocal of an Integer is the Rational 1/n rather than a floored 0. recip(4) is 1/4. Consequences worth relying on: recip is an involution (recip(recip(x)) is x), x * recip(x) is 1, and recip(1) normalizes back to the Integer 1. Covers Integer, Float, Rational, Byte (widening to Integer) and Complex. Zero has no reciprocal and raises `division by zero` rather than answering — catch it with try(). A non-number is an error: recip is a function, not a predicate. Added July 2026.

Examples

recip(4)               # → 1/4     — exact, NOT 0

recip(3/4)             # → 4/3

recip(0.5)             # → 2.0

recip(1)               # → 1       — Integer, 1/1 normalizes out

recip(recip(3/4))      # → 3/4     — an involution

4 * recip(4)           # → 1

try(recip(0))          # → Error: division by zero

record

Declaration

type P = record [mutable|mut] {x:: Float} | type P = record [mutable|mut]
 x:: Float
end
Alias of struct in the type kind slot; struct remains the primary spelling. The same struct AST declares a closed nominal record, not a structural Dictionary schema. Immutable by default; record mut and record mutable have the same checked fields and reference identity as struct mut and struct mutable. Braces, end bodies and generic parameters have the same rules. record is contextual: ordinary bindings and functions named record keep their meaning. In the kind slot it always starts a declaration; use type Alias = (record) to reference a type-valued variable instead ($record alone still selects the kind). No standalone record or struct declaration. Evaluator-only; the VM refuses all spellings. See doc struct. The example prints true, false, 2, true, false, 7, one per line.

Examples

type Label = record {value:: Integer}
type Cell[T of Number] = record mut
    value:: T
end
type Counter = struct mut {value:: Integer}
type Gauge = record mutable {value:: Integer}
let cell = Cell(1)
let shared = cell
shared.value = 2
println(Label(1) == Label(1))
println({value: 1} is Label)
println(cell.value)
println(cell == shared)
println(cell == Cell(2))
println(Counter(3).value + Gauge(4).value)

recursion_limit

Function

recursion_limit() — the current Eval-depth ceiling that the recursion guard enforces (issue #10). Deep/infinite recursion errors with "recursion limit exceeded (max Eval depth N)" once Eval re-entrancy crosses this value; the ceiling is target-specific (generous on native's 1 GB stack, tight on the wasm stack). Exposed for introspection — a script that hit the limit can report it. Call diagnostics (different branches may describe different overloads): • recursion_limit takes no arguments Extracted library reference: evaluator/builtins.go:3449. These notes are not a complete signature or a stability guarantee. Manual §29.10 Deep recursion is a catchable error; read with manual "29.10" Excerpt: `recursion_limit()` reports the current ceiling. The default is target-specific — the browser/playground stack is far tighter than a native goroutine stack — and `--vm` refuses at its capped frame stack with the same collapsed shape.

reduce

Function

reduce(accumulator_function, initial_value, collection)
Reduces a collection (array, set, or tuple) to a single value by applying a binary accumulator function from left to right, starting with the initial value.

Examples

reduce(func(acc, x) [acc + x], 0, [1, 2, 3, 4])  # Returns 10 (sum)

reduce(\(acc, x) => acc * x, 1, {1, 2, 3, 4})   # Returns 24 (product)

reference?

Function

Call diagnostics (different branches may describe different overloads): • reference? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

referent_of

Function

Call diagnostics (different branches may describe different overloads): • referent_of() requires exactly 1 argument Extracted library reference: evaluator/builtins.go:5794. These notes are not a complete signature or a stability guarantee.

refute

Keyword

Experimental automated-reasoning syntax. The current evaluator returns a simulated reasoning record for refute; it does not perform a general refutation search. Its reported steps, confidence and timing are placeholders, not evidence that a proposition has been refuted. Use the implemented proof-kernel operations for checked derivations.

regex_captures

Function

regex_captures(s, pattern) → Array<String> — the FIRST match's groups: element 1 is the whole match (group 0), element 2 the first parenthesized group, and so on. Returns an empty array when there is no match. Call diagnostics (different branches may describe different overloads): • regex_captures requires 2 arguments: string, pattern Extracted library reference: evaluator/builtin_regex.go:136. These notes are not a complete signature or a stability guarantee. Manual §4.5.10 Regular expressions — native `regex_*` builtins; read with manual "4.5.10" Excerpt: | `regex_split(s, pat)` | `Array<String>` | `regex_split("one two", "\\s+")` → `["one","two"]` | | `regex_captures(s, pat)` | `Array<String>` | `regex_captures("2026-06-14", "(\\d+)-(\\d+)-(\\d+)")` → `["2026-06-14","2026","06","14"]` | `regex_replace` supports `$1`/`$2` backreferences; `regex_captures` returns group 0 (the whole match) followed by each capture group, or `[]` on no match.

regex_find_all

Function

Return the shared TRUE/FALSE singletons — isTruthy() compares by pointer identity, so a freshly-allocated Boolean{false} would be mis-read as truthy in if/while/comprehension-filter contexts. regex_find_all(s, pattern) → Array<String> — every non-overlapping match. Call diagnostics (different branches may describe different overloads): • regex_find_all requires 2 arguments: string, pattern Extracted library reference: evaluator/builtin_regex.go:71. These notes are not a complete signature or a stability guarantee. Manual §4.5.10 Regular expressions — native `regex_*` builtins; read with manual "4.5.10" Excerpt: | `regex_match(s, pat)` | `Boolean` | `regex_match("a1b2", "[0-9]")` → `true` | | `regex_find_all(s, pat)` | `Array<String>` | `regex_find_all("a1b2c3", "[0-9]")` → `["1","2","3"]` | | `regex_replace(s, pat, repl)` | `String` | `regex_replace("John Smith", "(\\w+) (\\w+)", "$2 $1")` → `"Smith John"` | | `regex_split(s, pat)` | `Array<String>` | `regex_split("one two", "\\s+")` → `["one","two"]` | | `regex_captures(s, pat)` | `Array<String>` | `regex_captures("2026-06-14", "(\\d+)-(\\d+)-(\\d+)")` → `["2026-06-14","2026","06","14"]` |

regex_match

Function

regex_match(s, pattern) → Boolean — true iff pattern matches anywhere in s. Call diagnostics (different branches may describe different overloads): • regex_match requires 2 arguments: string, pattern Extracted library reference: evaluator/builtin_regex.go:52. These notes are not a complete signature or a stability guarantee. Manual §4.5.10 Regular expressions — native `regex_*` builtins; read with manual "4.5.10" Excerpt: |---|---|---| | `regex_match(s, pat)` | `Boolean` | `regex_match("a1b2", "[0-9]")` → `true` | | `regex_find_all(s, pat)` | `Array<String>` | `regex_find_all("a1b2c3", "[0-9]")` → `["1","2","3"]` | | `regex_replace(s, pat, repl)` | `String` | `regex_replace("John Smith", "(\\w+) (\\w+)", "$2 $1")` → `"Smith John"` | | `regex_split(s, pat)` | `Array<String>` | `regex_split("one two", "\\s+")` → `["one","two"]` |

regex_match_groups

Function

regex_match_groups(s, pattern) → Dictionary of captures on match, `none` on no match. This is the builtin that the Perl-borrowed `=~` operator desugars to (subject =~ pattern). The returned hash is TRUTHY (every hash is), and a non-match returns `none` (falsy), so `if s =~ p` works and `s =~ p ?? default` composes with the coalescing operator. Keys: "match" the whole match (group 0) "1".."n" numbered capture groups (stringified indices) <name> one key per (?P<name>...) named group (RE2 syntax) Reusing the standard Dictionary means `(s =~ p).year` and `(s =~ p)["1"]` Just Work via the existing property/index access. Stateless → available under --vm. Call diagnostics (different branches may describe different overloads): • regex_match_groups requires 2 arguments: string, pattern Extracted library reference: evaluator/builtin_regex.go:188. These notes are not a complete signature or a stability guarantee.

regex_no_match

Function

regex_no_match(s, pattern) → Boolean — true iff pattern does NOT match anywhere in s. Backs the Perl-borrowed `!~` operator (subject !~ pattern). Stateless → available under --vm. Call diagnostics (different branches may describe different overloads): • regex_no_match requires 2 arguments: string, pattern Extracted library reference: evaluator/builtin_regex.go:159. These notes are not a complete signature or a stability guarantee.

regex_replace

Function

regex_replace(s, pattern, replacement)
Copy with every RE2 pattern match replaced; replacement takes $1/${name} capture refs (write it raw: r"…"). Manual §4.5.10 Regular expressions — native `regex_*` builtins; read with manual "4.5.10" Excerpt: | `regex_find_all(s, pat)` | `Array<String>` | `regex_find_all("a1b2c3", "[0-9]")` → `["1","2","3"]` | | `regex_replace(s, pat, repl)` | `String` | `regex_replace("John Smith", "(\\w+) (\\w+)", "$2 $1")` → `"Smith John"` | | `regex_split(s, pat)` | `Array<String>` | `regex_split("one two", "\\s+")` → `["one","two"]` | | `regex_captures(s, pat)` | `Array<String>` | `regex_captures("2026-06-14", "(\\d+)-(\\d+)-(\\d+)")` → `["2026-06-14","2026","06","14"]` |

regex_split

Function

regex_split(s, pattern) → Array<String> — split s at each match of pattern. Call diagnostics (different branches may describe different overloads): • regex_split requires 2 arguments: string, pattern Extracted library reference: evaluator/builtin_regex.go:113. These notes are not a complete signature or a stability guarantee. Manual §4.5.10 Regular expressions — native `regex_*` builtins; read with manual "4.5.10" Excerpt: | `regex_replace(s, pat, repl)` | `String` | `regex_replace("John Smith", "(\\w+) (\\w+)", "$2 $1")` → `"Smith John"` | | `regex_split(s, pat)` | `Array<String>` | `regex_split("one two", "\\s+")` → `["one","two"]` | | `regex_captures(s, pat)` | `Array<String>` | `regex_captures("2026-06-14", "(\\d+)-(\\d+)-(\\d+)")` → `["2026-06-14","2026","06","14"]` | `regex_replace` supports `$1`/`$2` backreferences; `regex_captures` returns

regions_of

Function

regions_of(space) - Get regions Extracted library reference: evaluator/builtin_conceptual.go:358. These notes are not a complete signature or a stability guarantee.

register_tool

Function

Call diagnostics (different branches may describe different overloads): • register_tool requires 3 arguments: registry, tool, handler Extracted library reference: evaluator/builtin_agent_tools.go:27. These notes are not a complete signature or a stability guarantee. Manual §33.17 Tool registry and Act guardrails; read with manual "33.17" Excerpt: | `tool_registry()` | empty mutable registry Dictionary | | `register_tool(reg, tool, handler)` | bind `MkToolId` or string → function | | `call_tool(reg, tool, args [, agent])` | run handler → `Result`; optional agent enforces deontic | | `guard_act(agent, step)` | `Ok(step)` or `Err` for `Act`; other `AgentStep`s pass |

rel

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §16.12 Aspectual facts — `qua`; read with manual "16.12" Excerpt: `it qua "h"` binds `it` to every fact tagged `h`; the relation-anchored form `rel(X) qua "h"` instead binds `X` to the argument. `qua` stays an ordinary identifier outside this position (a same-line soft keyword). A handle is metadata on an asserted fact, not an agent's viewpoint or a time

relatedTo

Keyword

Infix relational vocabulary. It does not infer a specific relation from English alone; declare the intended relation and facts explicitly.

relatedTo

Keyword

Infix relational vocabulary. It does not infer a specific relation from English alone; declare the intended relation and facts explicitly.

relation

Keyword

relation name(arg1, arg2, ...)
Declares a logical relation schema. Once declared, facts can be asserted or queried using the relation.

Examples

relation edge(x, y)

assert edge("a", "b")

relation/datalog

Keyword

relation/datalog p(x) | [logic/datalog | {X | X <- p(X)}]
Explicit safe, stratified, finite-domain relational rules. Queries return a SolveResult containing a complete Set. Each head, filter and negative variable must be bound by a positive relational goal in every alternative. No variable-containing compound heads, term generation, cut, once, or Prolog dependencies. Resource exhaustion raises IncompleteReasoningError. See manual Explicit Datalog and Prolog modes.

relation/prolog

Keyword

relation/prolog p(x) | [logic/prolog | X <- p(X)] | [logic/prolog/tabled | X <- p(X)]
Explicit relational search with fresh clause variables, finite-tree unification and occurs check. Depth-first streams preserve clause order and proof duplicates. Positive variant tabling completes recursive tables before exposing answers; cut, once and procedural negation are refused in tabled mode. Immutable scalars, native lists and tagged tuples are terms. See manual Explicit Datalog and Prolog modes.

rem

Function

a rem b | rem(a, b)
Short spelling of remainder / mod — the prefix twin of `div(a, b)`. Floor remainder (sign of the divisor), same path as `%`. Not Julia/Elixir truncated rem: `rem(-7, 3)` is 2, not -1. Soft keyword: infix only same-line and not followed by `:`; `rem: 5` is still a binding. `reminder` is a different word and errors with a pointer here.

Examples

rem(5, 2)       # Returns 1

5 rem 2         # Returns 1

rem(-7, 3)      # Returns 2     (floor, not truncated -1)

div(-7, 3)*3 + rem(-7, 3)  # Returns -7

remainder

Function

a remainder b | remainder(a, b)
Returns the remainder of dividing a by b. Same-line infix alias of `mod` / `modulo` / `rem` / `%` (identical AST), and also a prefix builtin `remainder(a, b)`. Short spelling: `rem(a, b)`. `reminder` is a different English word (a thing that reminds you) and is not this function — that spelling errors with a pointer here. FLOOR-mod on every numeric kind: the remainder takes the sign of the DIVISOR; mixed operands coerce to float. Divisor 0 raises an error. Satisfies quotient(a, b) * b + remainder(a, b) == a. As a soft keyword, infix `remainder` is only an operator between two expressions on the same line; `remainder: 5` is still an ordinary binding.

Examples

8 remainder 7         # Returns 1     (infix, same as 8 mod 7)

remainder(100, 7)     # Returns 2     (prefix)

remainder(-23, 7)     # Returns 5     (sign of divisor — not -2)

remainder(23, -7)     # Returns -5    (sign of divisor)

remainder(-10.5, 3.0) # Returns 1.5   (float: sign of divisor)

mod(-23, 7)           # Returns 5     (prefix form of the mod keyword)

100 % 7               # Returns 2     (symbolic operator form)

100 mod 7             # Returns 2     (infix keyword form)

remainder(100, 0)     # ERROR: remainder by zero

rem(5, 2)             # Returns 1     (short prefix, twin of div)

remove

Function

remove(path)
Deletes a FILE, or an EMPTY directory, and returns true. Errors when the path does not exist — file_exists(path) is the total predicate to test with first, exactly as you would pair it with read(). Refuses a directory that holds entries: recursive deletion still exists as io.remove_dir, but you must name it explicitly rather than reach it through a generic remove(). A symlink is removed as a LINK, not followed. Until July 2026 this recursively wiped whole directory trees and reported success for paths that never existed. Not a collection operation — for arrays use remove_at(a, i), filter(pred, a), or slicing.

Examples

write("/tmp/x.txt", "hi")   # true

remove("/tmp/x.txt")          # true

file_exists("/tmp/x.txt")     # false

remove("/tmp/x.txt")          # ERROR: no such file or directory

remove_at

Function

remove_at(array, position)
Remove the element at a 1-based position in place and return the array (negative counts from the end). Yields the array, not the element — capture with delete a[i] or read xs[pos] first. Manual §5.1 Arrays; read with manual "5.1" Excerpt: `splice!(a, i)` is `delete a[i]`. Capture the removed value from the call; `remove_at(a, i)` still yields the array. Positional surgery keeps the function spellings (`insert_at(a, i, x)`, or two-arg `insert_at(a, x)` which appends; `remove_at(a, i)`), plus

remove_duplicates

Function

dedupeBuiltin: order-preserving removal of duplicates from an array (keyed by the canonical types.ObjectKey, so it matches set value-equality). Backs dedupe / remove_duplicates / unique. A Set already has unique members, so use a Set when order doesn't matter; this is for lists where order does. Call diagnostics (different branches may describe different overloads): • remove_duplicates requires exactly 1 argument Extracted library reference: evaluator/scheme_extras.go:273. These notes are not a complete signature or a stability guarantee. Manual §22.8 List & string helpers; read with manual "22.8" Excerpt: butlast([1, 2, 3, 4]) # → [1, 2, 3] (all but the last) dedupe([1, 2, 2, 3, 1]) # → [1, 2, 3] order-preserving (remove_duplicates / unique) unique!([1, 2, 2, 3, 1]) # → [1, 2, 3] in-place; unique(xs) is the copy chars("abc") # → ["a", "b", "c"] (string → char array) explode("abc") # → ["a", "b", "c"] (SML spelling; exact alias of chars)

repeat

Keyword

repeat count [ body ] | repeat item <- source [ body ] | repeat [body] until condition | repeat
  body
until condition
end
Alternative spelling of loop. A pre-test condition may run zero times; the body-until form tests after executing the body. The end-form dual is repeat … until condition end. See doc loop and manual "Loops".

Examples

repeat 2
  println("again")
end

n: 0
repeat
  n: n + 1
until n >= 3
end

replace

Function

replace(s, old, new)
Copy with every occurrence of old replaced by new. Manual §3.3.1 Uninitialized slots and identity defaults; read with manual "3.3.1" Excerpt: The snapshotted type belongs to that cell: shadowing it creates a different cell and does not replace an earlier closure's contract. Fills through `=`, `:`, `rebind`, `global`, or a writable binding reference retain the destination's type checks and conversions. Persistent Array element and schema contracts govern later mutations. Existing source-sensitive rules still apply: a schema annotation on

replace_all

Function

replace_all(subject, rules)
Fixpoint AST rewrite of a quoted expression: rules = [[pattern, template], …] (optional third element = guard), applied until no rule fires — NOT the string substitution (that is replace/regex_replace). Manual §19.10.4 Pattern rewriting — `match_pattern` / `subst` / `replace_all` / `rules`; read with manual "19.10.4" Excerpt: #### Pattern rewriting — `match_pattern` / `subst` / `replace_all` / `rules` The algebra above is the substrate for **term rewriting** — Mathematica's `expr /. rule` and the heart of a computer-algebra system. Patterns reuse Axioma's existing `?x` variable syntax; no new lexer.

reshape

Function

Call diagnostics (different branches may describe different overloads): • first argument must be an array or matrix • reshape requires exactly 3 arguments: array/matrix, rows, cols Extracted library reference: evaluator/matrix_construction.go:46. These notes are not a complete signature or a stability guarantee. Manual §5.14 Matrices, tensors & dataframes; read with manual "5.14" Excerpt: det(m) # → -2 ; trace(m) → 5 reshape(matrix([[1, 2, 3], [4, 5, 6]]), 3, 2) # 2×3 → 3×2 zeros(2, 2) # 2×2 of 0s ; ones(2, 3) → 2×3 of 1s solve(matrix([[2, 1], [1, 3]]), [5, 10]) # Ax = b → column vector (1, 3)

rest

Function

rest(s, [n])
All but the first element; rest(s, n) drops the first n — the mirror of first(s, n). Array/Tuple/Set/finite Range/infinite set. Manual §12.5 Variadic parameters — `...rest`; read with manual "12.5" Excerpt: ### Variadic parameters — `...rest` A parenthesized parameter list may end with a **rest slot**: `...name` collects every argument beyond the fixed ones into an `Array`, empty when

restrict

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §26.1 CLI flags; read with manual "26.1" Excerpt: | `--verbose` | Verbose output | | `--language <subset>` | Restrict surface to a subset: `axioma/all` (default), `axioma/knowledge`, `axioma/knowledge-core` (monotonic proof-core), **`axioma/beginner`**, **`axioma/rpn`** (additive Forth return stack), **`axioma/hm`** (closed Hindley–Milner island). `axioma/core` and `axioma/functional` are known names with **no AST gate** (they run as host — do not treat them as dialects) | | `-o` / `--oracle` | The word oracle: position-aware hints for unknown words, `what is` / `doc` guidance for known ones, REPL number picker (`:oracle on\|off\|status`). Off by default — with it off, messages are byte-identical to the plain interpreter. See §25 *The word oracle* | | `--mode <name>[,<name>…]` | Educational mode: `functional`, `logic`, `stack`, `mathematical`, `linguistic`, `imperative`, `beginner` | | `--glyphify <file>` / `--asciify <file>` | Token-aware in-place canonicalizer between word operators and Unicode glyphs (`in` ↔ `∈`, `and` ↔ `∧`, `forall` ↔ `∀`; digraphs `` `cup `` → `∪`). Strings/comments untouched; verifies the rewrite lexes+parses identically before writing (see §3 "Typing the glyphs") |

retract

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §12.11 Contracts — `requires` / `ensures` / `check f`; read with manual "12.11" Excerpt: writing form**, not only `insert`: `assert`, a bare relation call, `forget`, `retract`, the deontic and epistemic builtins, and the metadata writers — `set_truth`, `cancel`, `challenge`, and the transaction block — all reach it, including the form with no call expression at all —

retrieve_cases

Function

retrieve_cases(library, problem [, similarity_threshold] [, max_cases])
Retrieves similar cases from a case library based on problem similarity. Implements CBR's RETRIEVE phase with configurable similarity thresholds.

Examples

retrieve_cases(lib, new_problem)

retrieve_cases(lib, new_problem, 0.7, 5)

return

Keyword

return [value]  |  if c then return v  |  return v if c  |  return v unless c
Early exit from a function (a STATEMENT — a function body otherwise returns its last expression, the native idiom). Bare `return` yields none; in a `:: Unit` / `-> Unit` function it yields `()`, the same as omitting the return. The value must start on the return's own line. Unwinds through nested blocks and loops to the enclosing function. Branch position (`if c then return v`) is sugar for the block form `then [return v]`; the postfix guards are the Perl idiom. Not usable in value position (`x: return 5` errors — bind directly). Several results are ONE tuple — `return (a, b)`; a bare comma list (`return a, b`) is a SyntaxError whose hint names the rewrite, and the call site destructures it: `m, i = f(...)`. Top-level return is a benign no-op. Under --vm all function-level forms compile; top-level stays evaluator-only.

Examples

if x == f then return f            # guard clause

return -1 if x < 0                 # postfix guard

return 0 unless x > 10

fn f():: Unit [ println("hi"); return ]   # Unit: bare return is ()

return (best, at)                  # several results = one tuple value

foreach x in xs [ if x == 0 then return x ]   # unwinds through loops

rev

Function

rev(s)
SML List.rev spelling — exact alias of reverse. Manual §5.6 Collection method calls; read with manual "5.6" Excerpt: `reduce(f, init, xs)`. Other registered methods put the receiver first: `push`, `append`, `reverse`, `rev`, `sort`, `sorted`, `sum`, `prod`, `mean`, `min`, `max`, `length`, `len`, `size`, `count`, `first`, `last`, `rest`, `nth`, `contains`, `collect`, `elements`, `each`, `transpose`, and `shape`. Builtin domain and mutation rules are unchanged: `m.length()` still refuses a

reverse

Function

reverse(collection)
Returns a new array, tuple, list, or string with the elements in reverse order. Does not mutate. The in-place twin is `reverse!`.

Examples

reverse([1, 2, 3])   # Returns [3, 2, 1]

reverse!

Function

reverse!(array)
Reverses an Array in place and returns it. Aliases see the write. Tuples, lists, and strings have no place to mutate — use `reverse(collection)` for a copy.

Examples

xs: [1, 2, 3]; reverse!(xs)   # xs is now [3, 2, 1]

right?

Function

right?(value)
Test whether a constructor value has the Right tag. This is a tag test; it does not unwrap or execute the contained value. See manual "Option" for Option, Result and Either.

rightarrow

Symbol

=== → (Glyph) === name: implies words: implies latex: to, rightarrow, implies variants: ⟹ category: logic codepoint: U+2192 meaning: p → q — material implication

ring

Symbol

=== ∘ (Glyph) === name: ring latex: circ category: function codepoint: U+2218 meaning: f ∘ g — function composition, right-to-left: (f ∘ g)(x) = f(g(x)); mirror of compose(g, f)

rng

Function

Call diagnostics (different branches may describe different overloads): • rng requires exactly 1 argument Extracted library reference: evaluator/builtins.go:7624. These notes are not a complete signature or a stability guarantee. Manual §12.11 Contracts — `requires` / `ensures` / `check f`; read with manual "12.11" Excerpt: Generation runs under the ambient **seeded RNG** (fixed startup seed — § Randomness), so an unseeded `check` is reproducible run-to-run; call `random_seed(…)` first to vary the draws. Note the target parses like any `check` expression, so `check f == x` reads as `check (f == x)` — bind

ro

Keyword

Lojban-inspired universal quantifier: all members of the explicit domain.

roll

Function

Call diagnostics (different branches may describe different overloads): • first argument to roll must be a stack • roll requires 2 arguments: stack, index • second argument to roll must be an integer Extracted library reference: evaluator/builtins.go:12347. These notes are not a complete signature or a stability guarantee. Manual §18.2 Stack-shuffle operations; read with manual "18.2" Excerpt: | `pick(s, i)` | `→ … x` | Copy the element at index `i` (0 = top) to the top | | `roll(s, i)` | `→ … x` | Move the element at index `i` to the top | ### Bulk & depth operations

rot

Function

Call diagnostics (different branches may describe different overloads): • argument to rot must be a stack • rot requires 1 argument: stack • rot requires at least 3 items on stack Extracted library reference: evaluator/builtins.go:12055. These notes are not a complete signature or a stability guarantee. Manual §18.2 Stack-shuffle operations; read with manual "18.2" Excerpt: | `swap(s)` | `a b → b a` | Swap top two | | `rot(s)` | `a b c → b c a` | Rotate top three | | `over(s)` | `a b → a b a` | Copy second to top | | `drop(s)` | `a →` | Discard top | | `nip(s)` | `a b → b` | Drop second |

round

Function

round(x, [digits])
Round half away from zero; with digits, to that decimal precision. Manual §5.2 Positional access on sets, list surgery, and range loops (PiL ch5 round); read with manual "5.2" Excerpt: ### Positional access on sets, list surgery, and range loops (PiL ch5 round) Four additions from the *Programming in Lua* chapter-5 comparison (July 2026), each with full `--vm` parity:

rpeek

Function

Extracted library reference: evaluator/return_stack.go:26. These notes are not a complete signature or a stability guarantee. Manual §13.37 Hidden slots, scanners, turtles, and concatenative extras; read with manual "13.37" Excerpt: `effect: "( n -- n^2 )"` with `word_effect` / `check_effect`; return stack `rpush` / `rpop` / `rpeek` / `rdepth` / `rclear`. `#language axioma/rpn` is additive (infix still runs). Textbook: HtDKP-in-Axioma Chapter 41. Logo selectors: `butfirst`, `butlast`, `logo_item`, `sentence`.

rpop

Function

These need the session env. They are intercepted in evalCallExpression when called by name; the table entries exist so they are first-class values and fail with a hint if invoked without a session (e.g. passed as a function value and called later — rare). Extracted library reference: evaluator/return_stack.go:23. These notes are not a complete signature or a stability guarantee. Manual §13.37 Hidden slots, scanners, turtles, and concatenative extras; read with manual "13.37" Excerpt: `effect: "( n -- n^2 )"` with `word_effect` / `check_effect`; return stack `rpush` / `rpop` / `rpeek` / `rdepth` / `rclear`. `#language axioma/rpn` is additive (infix still runs). Textbook: HtDKP-in-Axioma Chapter 41. Logo selectors: `butfirst`, `butlast`, `logo_item`, `sentence`.

rpush

Function

These need the session env. They are intercepted in evalCallExpression when called by name; the table entries exist so they are first-class values and fail with a hint if invoked without a session (e.g. passed as a function value and called later — rare). Extracted library reference: evaluator/return_stack.go:20. These notes are not a complete signature or a stability guarantee. Manual §13.37 Hidden slots, scanners, turtles, and concatenative extras; read with manual "13.37" Excerpt: `effect: "( n -- n^2 )"` with `word_effect` / `check_effect`; return stack `rpush` / `rpop` / `rpeek` / `rdepth` / `rclear`. `#language axioma/rpn` is additive (infix still runs). Textbook: HtDKP-in-Axioma Chapter 41. Logo selectors: `butfirst`, `butlast`, `logo_item`, `sentence`.

rule

Keyword

rule RuleName: condition implies conclusion | head whenever body | head if body | head <== body | head :- body | rule~ head whenever body | typically head whenever body | body ==> head
Defines inference rules. The PRIMARY spelling is the natural one: `path(X, Y) whenever edge(X, Y)` for strict rules and `typically flies(X) whenever bird(X)` (≡ rule~ ≡ normally) for defeasible ones — `whenever` has no conditional reading, so ground heads work bare. Also first-class: `head if body` (gated on an uppercase logic-var arg; unambiguous under the `rule` prefix), the operators <== (legacy <=) and Prolog :- for strict backward, <~~ defeasible backward, and ==> / ~~> for the forward direction (operator-only). A marker contradicting the operator (rule~ or typically with :-) is a parse error. Named canonical rules work with query/prove/derive.

Examples

path(X, Y) whenever edge(X, Y)      # PRIMARY ≡ path(X, Y) :- edge(X, Y)

path(X, Y) whenever edge(X, Z) and path(Z, Y)

typically flies(X) whenever bird(X) # Defeasible ≡ flies(X) <~~ bird(X)

rule~ flies(X) if bird(X)           # Marker spelling of the same

path(X, Y) if edge(X, Y)            # if-form (gated on uppercase arg)

mortal(X) <== human(X)              # Operator form

parent(X, Y) and parent(Y, Z) ==> grandparent(X, Z)

rule Mortality: mortal(X) <== human(X)    # Named rule (operator form)

qualified(P) <== expert(P, Domain) and experience(P, Years) and Years > 5

rules

Function

rulesBuiltin is a flat-pairs sugar constructor: rules(p1, t1, p2, t2, ...) → [[p1, t1], [p2, t2], ...], the rule array replace_all expects. Guarded rules use the explicit [pattern, template, guard] array form. Call diagnostics (different branches may describe different overloads): • rules requires an even number of arguments (pattern, template, ...) Extracted library reference: evaluator/builtin_ast_pattern.go:48. These notes are not a complete signature or a stability guarantee. Manual §19.10.4 Pattern rewriting — `match_pattern` / `subst` / `replace_all` / `rules`; read with manual "19.10.4" Excerpt: #### Pattern rewriting — `match_pattern` / `subst` / `replace_all` / `rules` The algebra above is the substrate for **term rewriting** — Mathematica's `expr /. rule` and the heart of a computer-algebra system. Patterns reuse Axioma's existing `?x` variable syntax; no new lexer.

run_dsl

Function

Call diagnostics (different branches may describe different overloads): • run_dsl requires environment (this should not be called) Extracted library reference: evaluator/builtins.go:5530. These notes are not a complete signature or a stability guarantee.

same

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §3.5 Bare declarations — the same hole, with less syntax; read with manual "3.5" Excerpt: ### Bare declarations — the same hole, with less syntax Each fresh named binder allows omission of `= _`, with or without a type:

sample

Function

sample(coll) | sample(coll, k) | sample(distribution, n)
Random selection. Collection forms: sample(xs) draws one uniformly-random element from an array/tuple/set; sample(xs, k) draws k DISTINCT elements (without replacement; 0 ≤ k ≤ len). Distribution form: sample(dist, n) draws n values from a probability distribution (normal/uniform/binomial/beta) as a Sample object — unwrap the draws with values(s). All forms use the shared seedable source (see random_seed).

Examples

sample([10, 20, 30])          # one element

sample([1, 2, 3, 4, 5], 2)    # 2 distinct elements

values(sample(normal(0, 1), 3))   # 3 Gaussian draws

satisfiable

Function

satisfiable(concept_expr)
Description-logic tableau — decides whether a ConceptExpr (possibly compound with ⊓ ⊔ ¬ ∃ ∀) is satisfiable (has a model). Returns false for contradictions such as SelfContainer ⊓ ¬SelfContainer (Russell staging). Distinct from is_satisfiable(func…) (propositional SAT) and [logic/sat | …].

Examples

concept Person

satisfiable(Person)                              # true

satisfiable(Person ⊓ ¬Person)                    # false

concept SelfContainer

satisfiable(SelfContainer ⊓ ¬SelfContainer)      # false

satisfiable?

Function

Registered alias of is_satisfiable.is_satisfiable(expr) - Check if expression is satisfiable Uses DPLL SAT solver to find satisfying assignment Example: is_satisfiable(func(p, q) [ p and q ]) → true Call diagnostics (different branches may describe different overloads): • is_satisfiable requires exactly 1 argument: a boolean expression Extracted library reference: evaluator/builtins.go:16960. These notes are not a complete signature or a stability guarantee.

satisfies

Operator

object satisfies axiom
Checks if an object satisfies a specific axiom. Returns true/false.

Examples

account satisfies NonNegative

person satisfies PositiveAge

5 satisfies (x > 0)

scanl

Function

scanl(fn, initial, collection)
Left fold keeping every intermediate: [z, fn(z, x1), …] (length n+1). Manual §12.18 List-library verbs (Haskell / OCaml); read with manual "12.18" Excerpt: `scanl`/`scanr` are the folds `reduce`/`foldr` with every intermediate kept (length n+1: `scanl` starts with the seed, `scanr` ends with it). `span` is exactly `(take_while(p, xs), drop_while(p, xs))` computed in one pass; `separate` is `partition` under a different name (`partition` is reserved for

scanner

Function

Extracted library reference: evaluator/builtin_scanner.go:149. These notes are not a complete signature or a stability guarantee. Manual §13.37 Hidden slots, scanners, turtles, and concatenative extras; read with manual "13.37" Excerpt: ```axioma sc: scanner("hello world") p: scanner_match(sc, "hello") scanner_tab(sc, p) # → "hello" scanner_many(sc, " ") # → 7, or none

scanner_at_end

Function

Call diagnostics (different branches may describe different overloads): • scanner_at_end expects a Scanner Extracted library reference: evaluator/builtin_scanner.go:192. These notes are not a complete signature or a stability guarantee.

scanner_end

Function

Call diagnostics (different branches may describe different overloads): • scanner_end expects a Scanner Extracted library reference: evaluator/builtin_scanner.go:182. These notes are not a complete signature or a stability guarantee.

scanner_many

Function

Extracted library reference: evaluator/builtin_scanner.go:202. These notes are not a complete signature or a stability guarantee. Manual §13.37 Hidden slots, scanners, turtles, and concatenative extras; read with manual "13.37" Excerpt: scanner_tab(sc, p) # → "hello" scanner_many(sc, " ") # → 7, or none ``` Logo-style **turtle**. `0°` is north; `right` turns clockwise.

scanner_match

Function

Extracted library reference: evaluator/builtin_scanner.go:222. These notes are not a complete signature or a stability guarantee. Manual §13.37 Hidden slots, scanners, turtles, and concatenative extras; read with manual "13.37" Excerpt: sc: scanner("hello world") p: scanner_match(sc, "hello") scanner_tab(sc, p) # → "hello" scanner_many(sc, " ") # → 7, or none ```

scanner_pos

Function

Call diagnostics (different branches may describe different overloads): • scanner_pos expects a Scanner Extracted library reference: evaluator/builtin_scanner.go:172. These notes are not a complete signature or a stability guarantee.

scanner_subject

Function

Call diagnostics (different branches may describe different overloads): • scanner_subject expects a Scanner Extracted library reference: evaluator/builtin_scanner.go:162. These notes are not a complete signature or a stability guarantee.

scanner_tab

Function

Extracted library reference: evaluator/builtin_scanner.go:236. These notes are not a complete signature or a stability guarantee. Manual §13.37 Hidden slots, scanners, turtles, and concatenative extras; read with manual "13.37" Excerpt: p: scanner_match(sc, "hello") scanner_tab(sc, p) # → "hello" scanner_many(sc, " ") # → 7, or none ```

scanner_upto

Function

scanner_upto(scanner, characters)
Find the first position, at or after the scanner's current position, whose character belongs to the supplied String or Set. Return its 1-based position, or none. This lookup does not move the scanner; scanner_tab moves it.

scanr

Function

scanr(fn, initial, collection)
Right fold keeping every intermediate; ends with the seed (fn receives (x, acc)). Manual §12.18 List-library verbs (Haskell / OCaml); read with manual "12.18" Excerpt: `scanl`/`scanr` are the folds `reduce`/`foldr` with every intermediate kept (length n+1: `scanl` starts with the seed, `scanr` ends with it). `span` is exactly `(take_while(p, xs), drop_while(p, xs))` computed in one pass; `separate` is `partition` under a different name (`partition` is reserved for

schema

Declaration

type Row = schema
 x:: Integer
 label?:: String
end
Explicit end-body spelling of a structural Dictionary schema. Equivalent to type Row = {x:: Integer, label?:: String}. Optional absent fields read as none. Top-level transparent schemas retain VM support.

se

Function

se …
Alternative spelling of sentence. See doc("sentence") for its meaning and call forms.

searchForProof

Function

Call diagnostics (different branches may describe different overloads): • searchForProof requires 1 or 2 arguments • searchForProof requires string argument Extracted library reference: evaluator/builtins.go:6693. These notes are not a complete signature or a stability guarantee.

second

Function

ordinalBuiltin builds a 1-argument ordinal accessor (second..tenth) backed by nthElement, so the whole Racket-style family shares one implementation and works on finite collections and infinite sets alike. Call diagnostics (different branches may describe different overloads): • second requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1528. These notes are not a complete signature or a stability guarantee. Manual §11.2 Second-Order Logic (SOL); read with manual "11.2" Excerpt: ### Second-Order Logic (SOL) Quantification over predicates and functions:

see

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §13.35 `inspect` / `see` — identity-passing evaluate-and-display; read with manual "13.35" Excerpt: ### `inspect` / `see` — identity-passing evaluate-and-display A prefix directive that evaluates an expression, prints `<source> = <value>` to stdout, and returns the value unchanged.

selfEncode

Function

Call diagnostics (different branches may describe different overloads): • selfEncode takes no arguments Extracted library reference: evaluator/builtins.go:6557. These notes are not a complete signature or a stability guarantee.

self_reference

Reserved vocabulary

Reserved vocabulary with no dedicated parser implementation in this build. It is not a usable standalone form. Use doc "discover" for the implemented discovery interface, and manual for supported language forms. Recognition of a name is not a claim that its intended feature is implemented.

semantic_expansion

Function

semantic_expansion(concept, [depth]) - Expand concept with related terms Call diagnostics (different branches may describe different overloads): • semantic_expansion first argument must be a string • semantic_expansion requires 1-2 arguments (concept, [depth]) Extracted library reference: evaluator/builtins.go:21225. These notes are not a complete signature or a stability guarantee.

semantic_link_types

Function

semantic_link_types()
Returns an array of all available semantic link types (ISA, INSTANCE_OF, HAS_PROPERTY, etc.)

Examples

semantic_link_types()

semantic_lookup

Function

==================================================================================== UNIFIED SEMANTIC SYSTEM - Integrated WordNet + ConceptNet ==================================================================================== semantic_lookup(concept) - Unified lookup across WordNet and ConceptNet Call diagnostics (different branches may describe different overloads): • semantic_lookup argument must be a string • semantic_lookup requires exactly 1 argument (concept) Extracted library reference: evaluator/builtins.go:21101. These notes are not a complete signature or a stability guarantee.

semantic_network

Function

semantic_network(name [, description])
Creates a new semantic network for knowledge representation using Minsky's semantic network approach

Examples

semantic_network("Knowledge Base")

semantic_network("Animals", "Classification of animals")

semantic_path

Function

semantic_path(start, end, [max_depth]) - Find semantic path between concepts Call diagnostics (different branches may describe different overloads): • semantic_path first argument must be a string • semantic_path requires 2-3 arguments (start, end, [max_depth]) • semantic_path second argument must be a string Extracted library reference: evaluator/builtins.go:21183. These notes are not a complete signature or a stability guarantee.

semantic_similarity

Function

Call diagnostics (different branches may describe different overloads): • semantic_similarity first argument must be a string • semantic_similarity requires exactly 2 arguments (concept1, concept2) • semantic_similarity second argument must be a string Extracted library reference: evaluator/builtins.go:21158. These notes are not a complete signature or a stability guarantee.

semantic_stats

Function

semantic_stats(network)
Returns comprehensive statistics about the semantic network including node counts, link types, and activation levels

Examples

semantic_stats(net)

semantic_to_graph

Function

semantic_to_graph(network)
Converts a semantic network to a graph object for use with graph algorithms and visualization

Examples

semantic_to_graph(net)

sentence

Function

Extracted library reference: evaluator/builtin_logo.go:128. These notes are not a complete signature or a stability guarantee. Manual §13.37 Hidden slots, scanners, turtles, and concatenative extras; read with manual "13.37" Excerpt: HtDKP-in-Axioma Chapter 41. Logo selectors: `butfirst`, `butlast`, `logo_item`, `sentence`. ---

separate

Function

separate(predicate, collection)
Partition by predicate into a (satisfying, not) 2-tuple (partition is a reserved keyword). Manual §12.18 List-library verbs (Haskell / OCaml); read with manual "12.18" Excerpt: exactly `(take_while(p, xs), drop_while(p, xs))` computed in one pass; `separate` is `partition` under a different name (`partition` is reserved for concept partitions). `all?`/`any?`/`none?` short-circuit and read correctly in `if`.

sepi'o

Keyword

Instrument or using tag in a tagged relational form.

set

Function

set([collection])
With no argument, the empty set (≡ the literal {}). With one argument, deduplicates a collection into a Set — an Array, Tuple, or finite Range; a Set is returned unchanged. The one-argument form absorbed the conversion formerly spelled toSet (July 2026); the old spelling raises an error naming this one.

Examples

set()                # {} — the empty set

set([1, 2, 2, 3])    # {1, 2, 3} — dedups

set((1, 2, 2))       # {1, 2} — from a Tuple

set(1..3)            # {1, 2, 3}

set?

Function

Call diagnostics (different branches may describe different overloads): • set? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

set_default_theory

Function

set_default_theory(theory) - Set active Default Logic theory Example: set_default_theory(dt) Call diagnostics (different branches may describe different overloads): • set_default_theory requires 1 argument: theory Extracted library reference: evaluator/builtins.go:18048. These notes are not a complete signature or a stability guarantee.

set_deontic_model

Function

set_deontic_model(model) - Set active deontic model Example: set_deontic_model(dm) Call diagnostics (different branches may describe different overloads): • set_deontic_model requires 1 argument: model Extracted library reference: evaluator/builtins.go:17994. These notes are not a complete signature or a stability guarantee.

set_dl_kb

Function

set_dl_kb(kb) - Set active Description Logic knowledge base Example: set_dl_kb(kb) Call diagnostics (different branches may describe different overloads): • set_dl_kb requires 1 argument: knowledge base Extracted library reference: evaluator/builtins.go:18009. These notes are not a complete signature or a stability guarantee.

set_epistemic_model

Function

set_epistemic_model(model) - Set active epistemic model Example: set_epistemic_model(em) Call diagnostics (different branches may describe different overloads): • set_epistemic_model requires 1 argument: model Extracted library reference: evaluator/builtins.go:17981. These notes are not a complete signature or a stability guarantee.

set_free_logic_model

Function

set_free_logic_model(model) - Set active Free Logic model Example: set_free_logic_model(flm) Call diagnostics (different branches may describe different overloads): • set_free_logic_model requires 1 argument: model Extracted library reference: evaluator/builtins.go:18035. These notes are not a complete signature or a stability guarantee.

set_free_predicate

Function

set_free_predicate(model, predicate, entity, value) - Set a predicate Example: set_free_predicate(flm, "bald", "socrates", true) Call diagnostics (different branches may describe different overloads): • first argument must be a free logic model • fourth argument must be a boolean (value) • second argument must be a string (predicate) • set_free_predicate requires 4 arguments: model, predicate, entity, value • third argument must be a string (entity) Extracted library reference: evaluator/builtins.go:19394. These notes are not a complete signature or a stability guarantee.

set_intuitionistic_model

Function

set_intuitionistic_model(model) - Set active intuitionistic model Example: set_intuitionistic_model(im) Call diagnostics (different branches may describe different overloads): • set_intuitionistic_model requires 1 argument: model Extracted library reference: evaluator/builtins.go:18146. These notes are not a complete signature or a stability guarantee.

set_kripke_model

Function

set_kripke_model(model) - Set active Kripke model for modal evaluation Example: set_kripke_model(km) Call diagnostics (different branches may describe different overloads): • set_kripke_model requires 1 argument: model Extracted library reference: evaluator/builtins.go:17955. These notes are not a complete signature or a stability guarantee.

set_paraconsistent_model

Function

set_paraconsistent_model(model) - Set active paraconsistent model Example: set_paraconsistent_model(pm) Call diagnostics (different branches may describe different overloads): • set_paraconsistent_model requires 1 argument: model Extracted library reference: evaluator/builtins.go:18254. These notes are not a complete signature or a stability guarantee.

set_prob_evidence

Function

set_prob_evidence(kb, formula, value) - Set evidence for a formula Example: set_prob_evidence(kb, "raining", true) Call diagnostics (different branches may describe different overloads): • first argument must be a probabilistic logic KB • second argument must be a string (formula) • set_prob_evidence requires 3 arguments: kb, formula, value • third argument must be a boolean (truth value) Extracted library reference: evaluator/builtins.go:19016. These notes are not a complete signature or a stability guarantee.

set_prob_kb

Function

set_prob_kb(kb) - Set active Probabilistic Logic knowledge base Example: set_prob_kb(kb) Call diagnostics (different branches may describe different overloads): • set_prob_kb requires 1 argument: knowledge base Extracted library reference: evaluator/builtins.go:18022. These notes are not a complete signature or a stability guarantee.

set_range

Function

set_range(end) | set_range(start, end, [step])
Construct an inclusive Integer range as a Set. The one-argument form starts at 1. Bounds fit int64; an explicit step must be nonzero. A step directed away from the end produces an empty set. The result is eager; see doc range for ordered iteration.

set_temporal_model

Function

set_temporal_model(model) - Set active temporal model Example: set_temporal_model(tm) Call diagnostics (different branches may describe different overloads): • set_temporal_model requires 1 argument: model Extracted library reference: evaluator/builtins.go:17968. These notes are not a complete signature or a stability guarantee.

set_truth

Function

set_truth(relation, args..., "true"|"false"|"both"|"neither")
Attaches a Belnap B4 truth value to a stored fact — the truth-value axis of the knowledge unit, orthogonal to grounding and truth-kind. "both" marks a live contradiction (paraconsistent); "neither" marks an information gap.

Examples

axiom parent("john", "mary")

set_truth("parent", "john", "mary", "true")

set_truth_kind

Function

set_truth_kind(relation, args..., kind)
Sets the Schopenhauerian truth kind of a fact. Valid kinds: "logical", "empirical", "transcendental", "metalogical", "motive".

Examples

set_truth_kind("parent", "john", "mary", "empirical")

set_truth_value

Function

set_truth_value(model, prop, value) - Set the truth value of a proposition Values: "true", "false", "both" (contradiction), "neither" (unknown) Example: set_truth_value(pm, "liar", "both") Call diagnostics (different branches may describe different overloads): • first argument must be a paraconsistent model • second argument must be a string (proposition name) • set_truth_value requires 3 arguments: model, prop, value • third argument must be a string: 'true', 'false', 'both', 'neither' Extracted library reference: evaluator/builtins.go:18211. These notes are not a complete signature or a stability guarantee.

setminus

Symbol

=== \ (Glyph) === name: difference words: difference latex: setminus category: set codepoint: U+005C meaning: A \ B — difference (members of A not in B)

setrange

Function

setrange(start, stop) or set_range(start, stop[, step])
Generates a Set containing a sequence of integers from start to stop (exclusive/inclusive depending on params). Sibling: range.

Examples

setrange(1, 5)        # {1, 2, 3, 4}

set_range(1, 10, 2)   # {1, 3, 5, 7, 9}

seventh

Function

ordinalBuiltin builds a 1-argument ordinal accessor (second..tenth) backed by nthElement, so the whole Racket-style family shares one implementation and works on finite collections and infinite sets alike. Call diagnostics (different branches may describe different overloads): • seventh requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1528. These notes are not a complete signature or a stability guarantee.

shape

Function

Call diagnostics (different branches may describe different overloads): • argument must be tensor, matrix, array, or dataframe • shape requires exactly 1 argument Extracted library reference: evaluator/builtins.go:14498. These notes are not a complete signature or a stability guarantee. Manual §12.15.6 `on` — the shape composition cannot express; read with manual "12.15.6" Excerpt: #### `on` — the shape composition cannot express `cmp ∘ key` would feed `key`'s single result to a two-argument function. `on` applies the preprocessor to **both** arguments instead:

shift

Function

shift(array)  |  a shift
Removes and returns the FIRST element of an Array, shortening it in place. `pop` is the tail twin. `shift(a)` is the same surgery as `delete a[1]`. Empty arrays error. Tuples and lists have no place to mutate. Julia writes `shift!` — Axioma mutators have no bang (`push!` is Undefined word for the same reason).

Examples

a: [1, 2, 3]

shift(a)  # 1 — a is now [2, 3]

a shift   # message form; capture with shift(a)

should

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §6.9 Operator precedence (high → low); read with manual "6.9" Excerpt: deontic; epistemic; causal/aspect. Same-band binary forms generally group left, but `knows/believes/doubts` and `must/may/must_not/should` take a whole expression on the right; `causes/caused by` take a right side tighter than equality, including another causation. `R some C ⊓ D` is `(R some C) ⊓ D`, not `R some (C ⊓ D)`. Prefix modal/temporal forms use the ordinary prefix operand boundary instead.

show

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §6.9 Operator precedence (high → low); read with manual "6.9" Excerpt: **Grammar boundaries.** Rule arrows parse whole heads/bodies; `show` and graph operations use clause grammar even though entered at equality priority. Assignments, `::`, type/pattern syntax, statement messages, comprehensions, commas and semicolons are not extra ordinary binary rows. A semicolon ends an

show_taxonomy

Function

show_taxonomy(taxonomy)
Renders the taxonomy tree with each node's prime and cumulative encoding.

Examples

println(show_taxonomy(create_porphyry()))

shuffle

Function

shuffle(array)
Returns a NEW array with the elements in uniformly-random order (Fisher–Yates on the shared seedable source); the input array is not mutated. Deterministic under random_seed(n). The in-place twin is `shuffle!`.

Examples

shuffle([1, 2, 3, 4, 5])   # e.g. [1, 5, 2, 3, 4]

sorted(shuffle(xs)) == sorted(xs)   # always true — a permutation

shuffle!

Function

shuffle!(array)
Shuffles an Array in place and returns it. Same seedable source as shuffle, so shuffle!(xs) after seed S agrees with shuffle(copy of xs) after seed S.

Examples

xs: [1, 2, 3]; shuffle!(xs)   # xs is now a permutation of itself

sign

Function

sign(x)
Sign of a number: -1, 0, or 1. Manual §22.3 Mathematical functions; read with manual "22.3" Excerpt: | `divmod(a, b)` | Combined: returns `(quotient, remainder)` tuple in one call | | `signum(x)` | Sign as `-1` / `0` / `1`, **preserving type** (Int→Int, Float→Float, Rational→Int). A non-number errors. (`sign(x)` always returns an Integer.) | | `square(x)` | `x * x`, preserving numeric type | | `add1(x)` / `sub1(x)` | `x + 1` / `x - 1` (Lisp `1+` / `1-`) | | `succ(x)` / `pred(x)` | Successor / predecessor over the ordinal types (Pascal/Ada `'Succ`/`'Pred`): Integers (`succ(5)` → 6) and enum members (`succ(Mon)` → Tue, erroring at the ends). On Integers ≡ `add1`/`sub1`; the ordinal-typed, enum-symmetric spelling |

signature

Function

signature(fn)
The callable shape of a function as a String. User functions render from their parameter list (a `...rest` tail shows as `rest...`); spec-registered builtins render from their R3 metadata (`[x]` marks an optional parameter, `xs...` a variadic tail); builtins without a spec yet render as "name(...)". Works under --vm.

Examples

signature(round)         # → "round(x, [digits])"

signature(max)           # → "max(values...)"

signature(func(a, b) [a + b])   # → "func(a, b)"

signum

Function

signum(number)
The sign of a number — -1, 0 or 1 — PRESERVING its numeric type: Integer → Integer, Float → Float, Rational → Integer. This is what separates it from the older `sign`, which always returns an Integer whatever it was given. A non-number is an error, not false: signum is a function, unlike the sign PREDICATES zero? / plus? / minus?, which answer false on a wrong type. Pairs with negate and abs — x is signum(x) * abs(x), and signum(negate(x)) is negate(signum(x)).

Examples

signum(-7)             # → -1

signum(0)              # → 0

signum(7)              # → 1

signum(-3.5)           # → -1.0    — a Float in, a Float out

signum(3/4)            # → 1       — a Rational in, an Integer out

try(signum("7"))       # → Error   (a function, not a predicate)

sim

Symbol

=== ∼ (Glyph) === name: tilde_negation latex: sim category: logic codepoint: U+223C meaning: ∼p — logical negation (philosophical-text tilde; canonicalizes to ¬)

similar

Analogical Logic

concept1 similar concept2
Surface similarity operator. Expresses observable similarities between concepts.

Examples

Dog similar Cat

Car similar Truck

similarity: Concept1 similar Concept2

similarity

Function

similarity(concept1, concept2)
Calculates semantic similarity between two concepts using cognitive science algorithms. Returns a float from 0.0 to 1.0.

Examples

similarity(Dog, Cat)        # ~0.85 (both mammals)

similarity(Dog, Bird)       # ~0.66 (both animals)

similarity(Sprite, Animal)  # ~0.40 (distant relation)

sim: similarity(Car, Vehicle)  # High similarity

sin

Function

sin(x)
Sine (radians — use rad() to convert degrees). Manual §4.1 Primitives; read with manual "4.1" Excerpt: | `Integer` | `42`, `-17`, `0`, `0xFF`, `0b1010_1100`, `0o755`, `1_000_000`, `2^100` | **Arbitrary precision** — integers never overflow (see below); hex/binary/octal prefixes; underscore separators | | `Float` | `3.14159`, `-2.5`, `0.75`, `1.5e6`, `3.14e-2`, `1E+9`, `0x1p-1`, `0xA.Bp2` | IEEE 754 double — **the type is `Float`**, not `Float64` and not `FLOAT`. `:: Float64` names no type (did-you-mean `:: Float`). Scientific notation `e`/`E` ± optional sign; **hexadecimal floats** (Go/C99 syntax — binary exponent `p`/`P` **required**: `0x1p-1` = 2⁻¹ = `0.5`, `0xa.bp2` = `42.75`, `0x2.p3` = `16.0`). The exponent is what distinguishes a hex float from a hex integer (`0x10` stays `Integer` 16), keeps `0xFE`/`0x1E` reading `e`/`E` as digits, and keeps `0x15e-2` a subtraction. Lua's exponentless fraction `0x0.2` is deliberately rejected with a hint (write `0x0.2p0`, or evaluate the Lua form via `[lua/eval \| 0x0.2 ]`). **Display** is the shortest decimal that round-trips the bits: a whole value keeps `.0` (`1.0` not `1`), IEEE remainders are not rounded away (`sin(3.1415926/2)` is `0.9999999999999997`, `0.1+0.2` is `0.30000000000000004`), infinities print `Inf`/`-Inf`, and `eval(string(x))` recovers a Float | | `Rational` | `1/3`, `rational(2, 6)` → `1/3` | Exact `p/q` on big integers, GCD-reduced — `/` on integers stays exact (`1/3 + 1/6` → `1/2`, never `0.4999…`); accessors `numerator(r)` / `denominator(r)` | | `Complex` | `complex(3, 4)` → `3.0 + 4.0i`; `im` → `i` | The **top of the numeric tower** — every other numeric type embeds, so `complex(3, 4) + 1/2` → `3.5 + 4i`. The unit is the shadowable builtin `im` (`complex(0, 1)`); write `1 + im`, `(1 + im)^2` → `2i`, `2 * im`. No juxtaposed literal: `2im` is diagnosed (same as `2x`). Full arithmetic incl. `^` (exact at integer exponents: `im^2` → `-1`) and unary minus; `sqrt`/`exp`/`log`/`sin`/`cos`/`abs`/`conjugate` all accept one. No ordering. Embedding is via `float64`, so exactness stops here. Coefficients use the same Float printer | | `String` | `"hello"`, `"unicode: ∀∃"`, `"\u{2203}"`, `r"raw \n"` | UTF-8; escape sequences + `r"..."` raw prefix — see [Strings](#strings--escape-sequences-raw-form-codepoint-builtins) |

since

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §3.3 Fresh declarations with `let` and `var`; read with manual "3.3" Excerpt: (see **Uninitialized slots and identity defaults** below). - **Reserved word** (since August 2026). `let`, `var`, and `val` are keywords, so a bare `let: 42` is a SyntaxError that names the fix. To use one of them as an ordinary name, guard it: `$let: 42`, `func($val)`, `h.$val`, `$val() = 1` — the same `$` guard every reserved word takes. POP-11 word

sinh

Function

sinh(x)
Hyperbolic sine. Manual §22.3 Mathematical functions; read with manual "22.3" Excerpt: | `atan2(y, x)` | Full-quadrant arctangent — the C/Python spelling of `atan(y, x)` (`atan2(1, 0)` → `pi/2`) | | `sinh(x)` / `cosh(x)` / `tanh(x)` | Hyperbolic functions | | `deg(x)` | Radians → degrees (`deg(pi)` → `180`; Lua `math.deg`) | | `rad(x)` | Degrees → radians (`rad(180)` → `pi`; `sin(rad(90))` → `1`; Lua `math.rad`) | | `quotient(a, b)` / `a quotient b` | Floor division, rounding toward −∞ (same as `a ÷ b` / `a div b`) |

sixth

Function

ordinalBuiltin builds a 1-argument ordinal accessor (second..tenth) backed by nthElement, so the whole Racket-style family shares one implementation and works on finite collections and infinite sets alike. Call diagnostics (different branches may describe different overloads): • sixth requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1528. These notes are not a complete signature or a stability guarantee.

size

Function

size(collection)
Returns the length of a collection (array, tuple, set, range, string, bytes, bag, concept, or hash map). `len`, `length`, and `size` are three spellings of one operation, and each also works as a read accessor — so len(xs), length(xs), size(xs), xs.len, xs.length, xs.size, and xs's len all agree. String length is characters. A Matrix has no single length — size(m) errors and names shape(m) / tuple(shape(m)) / ndim(m).

Examples

size([1, 2, 3])          # Returns 3

size("hello")            # Returns 5

size({1, 2, 3})          # Returns 3

size({"a": 1, "b": 2})   # Returns 2

[1, 2, 3].size        # Returns 3   (dot accessor — same name)

[1, 2, 3]'s size     # Returns 3   (possessive — same name)

sleep

Function

======================================================================== DEBUGGING AND CONTROL FLOW FUNCTIONS ======================================================================== Extracted library reference: evaluator/builtins.go:16679. These notes are not a complete signature or a stability guarantee. Manual §28.7.1 `elapsed expr` and `bench "label" expr` — time an operand; read with manual "28.7.1" Excerpt: what it returned. `Duration` composes with `datetime.sleep` / `datetime.add` / `datetime.time_between`, not with global `sleep` (that takes seconds). `os.monotonic()` remains the snapshot for work you cannot wrap (Float seconds since interpreter start). `time()` is still the time-of-day constructor, not a clock.

slice

Function

Convert 1-based inclusive [s,e] to 0-based half-open [s-1, e). slice(s, start, end) — alias for substring for users who prefer the term. Extracted library reference: evaluator/builtin_strings.go:76. These notes are not a complete signature or a stability guarantee. Manual §5.12.5 Behavior interfaces — attach methods by type; read with manual "5.12.5" Excerpt: | `Sized` | `len` / `length` / `size` — native count, then `dispatch(Sized, "size", x)`. Slot is `size`. Not `cardinality` (F-logic registrar). | | `Indexable` | `a[i]` / `nth(a, i)` — native ordinal read, then `dispatch(Indexable, "at", a, i)`. Optional `put` for `a[i] = v`; optional `slice` for `a[i:j]` (else gather via `at`). Integer keys only. Entity `r["name"]` stays `r.name`. `p[slot -> val]` is a different form (frame write). Dictionary is keyed, not Indexable. | | `Semigroup` | `combine(a, b)` — seeded for String/Array/List/Tuple/Bytes (concatenation). Not Integer. | | `Monoid` | Semigroup plus `mempty(x)` identity. `mconcat(xs)` folds a non-empty collection. `implement Monoid for T` also registers Semigroup. |

so'a

Keyword

Lojban-inspired almost-all quantifier. Its implemented threshold is a modeling convention. Also spelled so'a.

so'i

Keyword

Lojban-inspired many quantifier. Its implemented threshold is a modeling convention, not a universal meaning of the English word many. Also spelled so'i.

so'u

Keyword

Lojban-inspired few quantifier. Its implemented threshold is a modeling convention, not a universal meaning of the English word few. Also spelled so'u.

soha

Keyword

Lojban-inspired almost-all quantifier. Its implemented threshold is a modeling convention. Also spelled so'a.

sohi

Keyword

Lojban-inspired many quantifier. Its implemented threshold is a modeling convention, not a universal meaning of the English word many. Also spelled so'i.

sohu

Keyword

Lojban-inspired few quantifier. Its implemented threshold is a modeling convention, not a universal meaning of the English word few. Also spelled so'u.

sol_analyze_complexity

Function

Call diagnostics (different branches may describe different overloads): • argument must be SOL formula • sol_analyze_complexity requires 1 argument: formula Extracted library reference: evaluator/builtins.go:11452. These notes are not a complete signature or a stability guarantee.

sol_complement_existence

Function

Call diagnostics (different branches may describe different overloads): • sol_complement_existence requires no arguments Extracted library reference: evaluator/builtins.go:11385. These notes are not a complete signature or a stability guarantee.

sol_comprehension

Function

Call diagnostics (different branches may describe different overloads): • first argument must be variable string • second argument must be variable type string • sol_comprehension requires 3-4 arguments: variable, variable_type, formula, [decidable] Extracted library reference: evaluator/builtins.go:11285. These notes are not a complete signature or a stability guarantee.

sol_evaluate

Function

Call diagnostics (different branches may describe different overloads): • first argument must be SOL formula • second argument must be Henkin model • sol_evaluate requires 2 arguments: formula, henkin_model Extracted library reference: evaluator/builtins.go:11409. These notes are not a complete signature or a stability guarantee.

sol_format

Function

Call diagnostics (different branches may describe different overloads): • sol_format requires 1 argument: sol_object Extracted library reference: evaluator/builtins.go:11435. These notes are not a complete signature or a stability guarantee.

sol_henkin_model

Function

Call diagnostics (different branches may describe different overloads): • domain must be a set or array • sol_henkin_model requires 1 argument: domain Extracted library reference: evaluator/builtins.go:11349. These notes are not a complete signature or a stability guarantee.

sol_higher_order_predicate

Function

Call diagnostics (different branches may describe different overloads): • argument types must be strings • first argument must be predicate name string • second argument must be predicate arity integer • sol_higher_order_predicate requires at least 4 arguments: name, predicate_arity, argument_types, definition Extracted library reference: evaluator/builtins.go:11316. These notes are not a complete signature or a stability guarantee.

sol_mathematical_induction

Function

Call diagnostics (different branches may describe different overloads): • sol_mathematical_induction requires no arguments Extracted library reference: evaluator/builtins.go:11373. These notes are not a complete signature or a stability guarantee.

sol_predicate_quantification

Function

Call diagnostics (different branches may describe different overloads): • first argument must be quantifier string • second argument must be predicate variable • sol_predicate_quantification requires 3 arguments: quantifier, variable, body Extracted library reference: evaluator/builtins.go:11261. These notes are not a complete signature or a stability guarantee.

sol_predicate_type

Function

======================================================================= SECOND-ORDER LOGIC (SOL) FUNCTIONS Complete second-order logic with Henkin semantics for computational tractability ======================================================================= Call diagnostics (different branches may describe different overloads): • argument types must be strings • first argument must be integer (arity) • sol_predicate_type requires at least 2 arguments: arity, argument_types Extracted library reference: evaluator/builtins.go:11182. These notes are not a complete signature or a stability guarantee.

sol_predicate_var

Function

Call diagnostics (different branches may describe different overloads): • first argument must be variable name string • second argument must be scope string • sol_predicate_var requires 3 arguments: name, scope, predicate_type • third argument must be predicate type Extracted library reference: evaluator/builtins.go:11234. These notes are not a complete signature or a stability guarantee.

sol_relation_type

Function

Call diagnostics (different branches may describe different overloads): • argument types must be strings • first argument must be integer (arity) • sol_relation_type requires at least 2 arguments: arity, argument_types Extracted library reference: evaluator/builtins.go:11208. These notes are not a complete signature or a stability guarantee.

sol_transitive_closure

Function

Call diagnostics (different branches may describe different overloads): • sol_transitive_closure requires no arguments Extracted library reference: evaluator/builtins.go:11397. These notes are not a complete signature or a stability guarantee.

solve

Function

Call diagnostics (different branches may describe different overloads): • first argument to solve must be a matrix • second argument to solve must be a matrix or array • solve requires exactly 2 arguments: A, b Extracted library reference: evaluator/builtins.go:13948. These notes are not a complete signature or a stability guarantee. Manual §5.14 Matrices, tensors & dataframes; read with manual "5.14" Excerpt: > (`inverse` is the *relation/set* inverse) — for linear systems use > `solve(A, b)` directly. **Tensors** — n-dimensional generalization:

some

Keyword

some S is P   |   some S is not P
Categorical particular forms of the judgment calculus: I (particular affirmative) and O (particular negative). Exact contradictories of E (`no S is P`) and A (`every S is P`) respectively, so the square of opposition holds by construction. Decided against the active taxonomy (Leibniz pair arithmetic) or over Concepts.

Examples

create_porphyry()

some animal is human        # true

some animal is not human    # true

some?

Function

some?(value)
Test whether a constructor value has the Some tag. This is a tag test; it does not unwrap or execute the contained value. See manual "Option" for Option, Result and Either.

sort

Function

sort(collection)
Returns a new sorted array containing all elements of the given array, tuple, set, or list. Sorts numbers numerically and other objects by their string representation. Alias: `sorted`. Does not mutate. The in-place twin is `sort!` (and reverse! / unique! / shuffle! for the other copy-named array functions).

Examples

sort([3, 1, 2])   # Returns [1, 2, 3]; the original is unchanged

sort!

Function

sort!(array)
Sorts an Array in place and returns it. Aliases see the write. Tuples, lists, and sets have no place to mutate — use `sort(collection)` for a copy. `ident!(args)` is a name (the bang glues only when `(` follows); `5!` and `x!` stay factorial.

Examples

xs: [3, 1, 2]; sort!(xs)   # xs is now [1, 2, 3]

sort_by

Function

sortByBuiltinFn returns the collection sorted ascending by the key function (Schwartzian — each key computed once). Stable; always returns an Array. Call diagnostics (different branches may describe different overloads): • sort_by requires exactly 2 arguments: a key function and a collection Extracted library reference: evaluator/builtins.go:22806. These notes are not a complete signature or a stability guarantee. Manual §5.12.2 Unified type declarations; read with manual "5.12.2" Excerpt: `sort!`, `sorted`, `min`, `max`, and the keyed verbs when a key is or contains such a record. Order by a field key instead, `sort_by(func(c) [c.x], cursors)`. Immutable structs keep their structural order in all of those, `min` and `max` included. An immutable `let` binding can hold a mutable struct: changing `p.x` does not rebind `p`.

sort_with

Function

sort_with(comparator, collection)
Sorted copy by a comparator: cmp(a, b) is true when a comes first.

sorted

Function

sorted(collection)
Alias for `sort`. Returns a new sorted array.

Examples

sorted([3, 1, 2])   # Returns [1, 2, 3]

source

Function

source(fn)
Reconstructed Axioma source of a user function, returned as a String (not printed, so it composes: eval(source(f)) re-yields the function). Canonical form rendered from the live AST — comments, type annotations, and original formatting are not preserved. Multi-clause functions render one clausal `func name(pattern) [...]` statement per clause. Builtins error catchably (implemented in Go — see signature/doc). Evaluator-only: under --vm function bodies are bytecode. Shadowable. Distinct from sources_of(rel, args...), which is fact PROVENANCE (attesting entities), not code.

Examples

double: func(x) [x * 2]

source(double)             # → "double: func(x) [(x * 2)]"

eval(source(double))       # the homoiconicity round-trip

println(source(double))    # display is opt-in

space?

Function

charPredicate wraps a rune classifier as a builtin accepting a Character or a one-character String. Call diagnostics (different branches may describe different overloads): • space? requires exactly 1 argument Extracted library reference: evaluator/character.go:81. These notes are not a complete signature or a stability guarantee.

space_similarity

Function

space_similarity(space, point1, point2)
Calculates geometric similarity between two coordinate points in a conceptual space. This is distinct from concept-level similarity(concept1, concept2).

Examples

fruit: conceptual_space("Fruit")

add_dimension(fruit, "sweetness", 0, 10)

add_dimension(fruit, "size", 0, 10)

space_similarity(fruit, [7, 5], [6, 5])

space_stats

Function

space_stats(space) - Get space statistics Extracted library reference: evaluator/builtin_conceptual.go:726. These notes are not a complete signature or a stability guarantee.

space_to_concepts

Function

============================================================================ DESCRIPTION LOGIC BRIDGES ============================================================================ space_to_concepts(space) - Extract DL concepts from space prototypes Extracted library reference: evaluator/builtin_conceptual_bridges.go:252. These notes are not a complete signature or a stability guarantee.

space_typicality

Function

space_typicality(space, point)
Measures how typical a coordinate point is relative to the prototypes in a conceptual space. This is distinct from concept-level typicality(concept).

Examples

fruit: conceptual_space("Fruit")

add_dimension(fruit, "sweetness", 0, 10)

add_dimension(fruit, "size", 0, 10)

space_typicality(fruit, [7, 5])

span

Function

span(predicate, collection)
(take_while, drop_while) pair in one pass, as a 2-tuple. Manual §12.18 List-library verbs (Haskell / OCaml); read with manual "12.18" Excerpt: `scanl`/`scanr` are the folds `reduce`/`foldr` with every intermediate kept (length n+1: `scanl` starts with the seed, `scanr` ends with it). `span` is exactly `(take_while(p, xs), drop_while(p, xs))` computed in one pass; `separate` is `partition` under a different name (`partition` is reserved for concept partitions). `all?`/`any?`/`none?` short-circuit and read correctly in

span_of

Function

span_of(s, sub, [init])
The (start, end) span of the first occurrence of sub in s — a Tuple of 1-based INCLUSIVE rune positions, the same coordinates substring() and s[a..b] slicing use — or none when absent (falsy: composes with if and ??). This is the position-PAIR search (Julia's findfirst range, Swift's range(of:), Lua's string.find pair); index_of returns the start alone. The optional init starts the search at that position (negative counts from the end), which with the absolute returned positions makes scan-all-occurrences loops one-liner-simple. Positions are CHARACTER (rune) coordinates, so they feed substring/slicing safely on multibyte text.

Examples

s, e: span_of("hello Lua users", "Lua")   # (7, 9) — destructures like Lua's s, e = string.find(...)

substring("hello Lua users", 7, 9)         # "Lua" — the span feeds extraction directly

span_of("abc", "z") ?? "absent"            # none on miss composes with ??

span_of("aXbXc", "X", 3)                   # (4, 4) — init offset resumes the scan

span_of_option

Function

spanOfOptionBuiltin is the Option dual of span_of: Some((start, end)) or None. Extracted library reference: evaluator/builtin_strings.go:152. These notes are not a complete signature or a stability guarantee. Manual §33.17 Tool registry and Act guardrails; read with manual "33.17" Excerpt: | `index_of(coll, target [, init])` | `index_of_option(...)` | | `span_of(s, sub [, init])` | `span_of_option(...)` | ```axioma detect(func(x) [x > 10], [1, 12]) # → 12

splice

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §5.1 Arrays; read with manual "5.1" Excerpt: does not (`push!` stays Undefined word). `splice!` keeps the bang because unbanged `splice` is quasiquote splicing. ```axioma b: [1, 2, 3, 4]

splice!

Function

splice!(array, index)
Removes the element at a 1-based index in place and returns it (negative counts from the end). `splice!(a, i)` is the same surgery as `delete a[i]`; `remove_at(a, i)` yields the array instead. Unbanged `splice` is quasiquote splicing (`quasiquote([1, splice(mid), 4])`), not array surgery.

Examples

a: [10, 20, 30, 40]

splice!(a, 2)  # 20 — a is now [10, 30, 40]

split

Function

split(s, separator)
Split a String into an Array on a separator. Manual §3.3 Fresh declarations with `let` and `var`; read with manual "3.3" Excerpt: Because the right-hand side evaluates **before** the new binding exists, `let xs = split(xs)` reads the outer `xs` and then takes over the name — the classic rebind-by-shadowing idiom. Every `let` makes a fresh binding, even for a name already `let` in the same scope, so consecutive `let x = …` lines each leave the previous binding alive inside anything that captured it.

spread_activation

Function

spread_activation(network, source_node [, initial_activation])
Performs spreading activation from a source node through the semantic network, returning activation results

Examples

spread_activation(net, "tweety", 1.0)

spread_activation(net, "bird")

sqcap

Symbol

=== ⊓ (Glyph) === name: concept_and latex: sqcap category: dl codepoint: U+2293 meaning: C ⊓ D — DL concept conjunction

sqcup

Symbol

=== ⊔ (Glyph) === name: concept_or latex: sqcup category: dl codepoint: U+2294 meaning: C ⊔ D — DL concept disjunction

sqrt

Function

sqrt(x)
Square root (errors on a negative Float — construct Complex explicitly). Manual §5.5 Unary dot fallback — `xs.sum ≡ sum(xs) ≡ xs's sum`; read with manual "5.5" Excerpt: Concepts keep their property-not-found errors, and modules stay name qualification (`math.sqrt` is a member lookup, never `sqrt(math)`). Because a miss on every eligible receiver was already an error, the fallback only turns errors into answers.

sqrt2

Value

Built-in FLOAT value: 1.4142135623730951 Manual §22.1 Mathematical constants; read with manual "22.1" Excerpt: | `phi` | 1.618033988749895 | Golden ratio | | `sqrt2` | 1.4142135623730951 | √2 | | `sqrt3` | 1.7320508075688772 | √3 | | `ln2` | 0.6931471805599453 | ln 2 | | `ln10` | 2.302585092994046 | ln 10 |

sqrt3

Value

Built-in FLOAT value: 1.7320508075688772 Manual §22.1 Mathematical constants; read with manual "22.1" Excerpt: | `sqrt2` | 1.4142135623730951 | √2 | | `sqrt3` | 1.7320508075688772 | √3 | | `ln2` | 0.6931471805599453 | ln 2 | | `ln10` | 2.302585092994046 | ln 10 | | `im` | `i` (`complex(0, 1)`) | Imaginary unit. Shadowable like `pi`. Write `1 + im`, `(1 + im)^2` → `2i`, `2 * im`. Not a juxtaposed literal (`2im` is diagnosed) and not the loop index `i` |

sqsubseteq

Symbol

=== ⊑ (Glyph) === name: subsumes latex: sqsubseteq category: dl codepoint: U+2291 meaning: C ⊑ D — DL subsumption

square

Function

squareBuiltin: x*x, preserving numeric type via the shared computeMultiply. Call diagnostics (different branches may describe different overloads): • square requires exactly 1 argument Extracted library reference: evaluator/scheme_extras.go:429. These notes are not a complete signature or a stability guarantee. Manual §22.3 Mathematical functions; read with manual "22.3" Excerpt: | `signum(x)` | Sign as `-1` / `0` / `1`, **preserving type** (Int→Int, Float→Float, Rational→Int). A non-number errors. (`sign(x)` always returns an Integer.) | | `square(x)` | `x * x`, preserving numeric type | | `add1(x)` / `sub1(x)` | `x + 1` / `x - 1` (Lisp `1+` / `1-`) | | `succ(x)` / `pred(x)` | Successor / predecessor over the ordinal types (Pascal/Ada `'Succ`/`'Pred`): Integers (`succ(5)` → 6) and enum members (`succ(Mon)` → Tue, erroring at the ends). On Integers ≡ `add1`/`sub1`; the ordinal-typed, enum-symmetric spelling | | `isqrt(n)` | Integer floor square root of a non-negative integer (exact, big-int aware) |

square_of_opposition

Function

square_of_opposition(S, P)
Renders the classical square for two terms in the current model: all four categorical forms (A/E/I/O) with their truth values, plus the square's laws checked — contradictories (A↔O, E↔I), and subalternation (A→I, E→O).

Examples

create_porphyry()

square_of_opposition(human, stone)

squeeze

Function

Call diagnostics (different branches may describe different overloads): • axis must be an integer • first argument must be tensor or matrix • squeeze requires 1 or 2 arguments: tensor [, axis] • tensor conversion requires a Float matrix; use float(m) explicitly Extracted library reference: evaluator/builtins.go:14376. These notes are not a complete signature or a stability guarantee. Manual §5.14 Matrices, tensors & dataframes; read with manual "5.14" Excerpt: tensor_reshape(tensor([1, 2, 3, 4, 5, 6]), [2, 3]) # → 2×3 squeeze(tensor([[1, 2, 3]])) # drop size-1 axes → vector [3] expand_dims(tensor([1, 2, 3]), 0) # add an axis → 1×3 ```

stable_models

Function

stable_models(program) - Answer Set Programming: stable-model semantics Parses a propositional normal logic program (a string) and returns the array of its answer sets (each a Set of atom strings), via the Gelfond–Lifschitz reduct. Self-contained → VM parity. Example: stable_models("p :- not q. q :- not p.") → [{p}, {q}] Call diagnostics (different branches may describe different overloads): • stable_models argument must be a string (the ASP program) • stable_models requires 1 argument: a program string Extracted library reference: evaluator/builtins.go:19641. These notes are not a complete signature or a stability guarantee.

stack

Function

stack([collection])
With no argument, a fresh empty Stack. With one argument, turns an array, set, tuple or finite range into a Stack, with position 1 as the TOP — the convention stack_to_array already used, so stack(c) equals array_to_stack(array(c)) by construction. A Set is walked in its canonical order; a Stack is returned unchanged. Added July 2026 — Stack had neither a literal nor a lowercase constructor, only the natural-language `a Stack`. The reverse direction is array(s) / set(s) / tuple(s), which now accept a Stack. Replaces stack_new(), retired July 2026: the _new suffix appeared nowhere else in the family (no array_new, no set_new) and stack() additionally converts. stack_new now errors with a migration pointer.

Examples

stack()              # an empty Stack

stack([1, 2, 3])     # Stack[1 | 2 | 3] — 1 is the top

stack(1..3)          # same, from a range

array(stack([1, 2])) # [1, 2] — the round trip

stack?

Function

Call diagnostics (different branches may describe different overloads): • stack? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

stack_cleave

Function

Extracted library reference: evaluator/builtin_stack_combinators.go:58. These notes are not a complete signature or a stability guarantee. Manual §13.37 Hidden slots, scanners, turtles, and concatenative extras; read with manual "13.37" Excerpt: Forth extras: `stack_dip` / `stack_keep` / `stack_cleave`; word `effect: "( n -- n^2 )"` with `word_effect` / `check_effect`; return stack `rpush` / `rpop` / `rpeek` / `rdepth` / `rclear`. `#language axioma/rpn` is additive (infix still runs). Textbook:

stack_dip

Function

Extracted library reference: evaluator/builtin_stack_combinators.go:21. These notes are not a complete signature or a stability guarantee. Manual §13.37 Hidden slots, scanners, turtles, and concatenative extras; read with manual "13.37" Excerpt: Forth extras: `stack_dip` / `stack_keep` / `stack_cleave`; word `effect: "( n -- n^2 )"` with `word_effect` / `check_effect`; return stack `rpush` / `rpop` / `rpeek` / `rdepth` / `rclear`. `#language axioma/rpn` is additive (infix still runs). Textbook:

stack_keep

Function

Extracted library reference: evaluator/builtin_stack_combinators.go:40. These notes are not a complete signature or a stability guarantee. Manual §13.37 Hidden slots, scanners, turtles, and concatenative extras; read with manual "13.37" Excerpt: Forth extras: `stack_dip` / `stack_keep` / `stack_cleave`; word `effect: "( n -- n^2 )"` with `word_effect` / `check_effect`; return stack `rpush` / `rpop` / `rpeek` / `rdepth` / `rclear`. `#language axioma/rpn` is additive (infix still runs). Textbook:

stack_to_array

Function

Call diagnostics (different branches may describe different overloads): • argument to stack_to_array must be a stack • stack_to_array requires 1 argument: stack Extracted library reference: evaluator/builtins.go:12147. These notes are not a complete signature or a stability guarantee. Manual §18.4 Array conversion; read with manual "18.4" Excerpt: |---|---| | `stack_to_array(s)` | Snapshot the stack as an array, top first | | `array_to_stack(arr)` | Build a new stack from an array | ### Example

stacklength

Function

Call diagnostics (different branches may describe different overloads): • argument to stacklength must be a stack • stacklength requires 1 argument: stack Extracted library reference: evaluator/builtins.go:12225. These notes are not a complete signature or a stability guarantee. Manual §18.1 Core operations; read with manual "18.1" Excerpt: | `peek(s)` | `… x → … x` | Return the top without removing it | | `depth(s)` / `stacklength(s)` | `→ n` | Current number of items | | `clear(s)` / `erase(s)` | `… →` | Empty the stack | ### Stack-shuffle operations

starling

Function

starling(f, g, x)
The Starling (S), curried: starling(f)(g)(x) is f(x)(g(x)). With kestrel a complete basis — SKK is identity, S(KS)K is compose.

starts_with

Function

starts_with(s, prefix) — true if s begins with prefix. Call diagnostics (different branches may describe different overloads): • starts_with requires 2 arguments: string, prefix Extracted library reference: evaluator/builtin_strings.go:81. These notes are not a complete signature or a stability guarantee.

std

Function

Call diagnostics (different branches may describe different overloads): • axis must be an integer • ddof must be an integer • first argument must be an array or matrix • std requires 1-3 arguments: data [, axis] [, ddof] Extracted library reference: evaluator/builtins.go:14064. These notes are not a complete signature or a stability guarantee. Manual §5.11 Bags (multisets); read with manual "5.11" Excerpt: evidence merging. Bags are first-class in SETL, Z, B, VDM-SL, Smalltalk, Python's Counter, C++ `std::multiset`, and Guava `Multiset`; they fill the same role in Axioma. Tests: [tests/axioma/collections/test_bag_basic.ax](../../tests/axioma/collections/test_bag_basic.ax),

step

Function

`step(r)` — the range's effective SIGNED stride. This was a placeholder that error()ed unconditionally: the evaluator answered `step(1..10)` from an evalCallExpression intercept keyed on the RangeExpression *AST node*, and the table entry existed only so the name would resolve. Under --vm the AST is gone by call time — the range has already been evaluated to a *types.Range — so every `step` call was "step requires a range expression", including the ones the evaluator answered. Its three siblings (`first`, `last`, `count`) already had real Range-value bodies; `step` was the one left behind. EffectiveStep, not the Step field: the descending default is derived from the endpoints rather than stored, so `step(10..1)` is -1 while the field reads 1. Reporting the field would have made the range that walks 10, 9, … 1 claim a stride of +1 — a wrong answer at exit 0 rather than the rejection this replaces. Extracted library reference: evaluator/builtins.go:7460. These notes are not a complete signature or a stability guarantee. Manual §4.8 Ranges — ordered `a..b`, exclusive `..<`, `by` step, open `n..`; read with manual "4.8" Excerpt: ### Ranges — ordered `a..b`, exclusive `..<`, `by` step, open `n..` `a..b` is a first-class **ordered** `Range` value — it knows its direction, its step, and (optionally) that it has no end. It displays compactly, tests

str

Function

str(x)
Display form of any value, as a String. Manual §5.10 Sets; read with manual "5.10" Excerpt: and `set(xs)` deduplicates any collection into a Set. They join the bare type-name coercions (`str`, `int`, `float`, `bytes`). `tuple(c)` completes the family, materializing any of them as a fixed-arity Tuple. All three also answer the **no-argument** call with their empty value —

str_join

Function

str_join(array, separator)
Join an array of strings with a separator. Manual §6.11 Forward pipe `|>`; read with manual "6.11" Excerpt: `filter(pred, coll)`, `reduce(fn, init, coll)`), so the everyday chain just works. For the collection-**first** builtins (`str_join`, `first`, `push`), an explicit `_` hole says where the value lands: ```axioma

stream

Function

Extracted library reference: evaluator/builtin_stream.go:33. These notes are not a complete signature or a stability guarantee. Manual §14.9.5 Stream API and metadata; read with manual "14.9.5" Excerpt: #### Stream API and metadata Every explicit query returns `SolveResult`. Its `.result` is the set or stream. Both query results and streams expose `.semantics`, `.strategy`, `.complete`,

stream_cons

Function

Call diagnostics (different branches may describe different overloads): • stream_cons requires 2 arguments: head, tail (a Stream or lazy Stream) • stream_cons tail thunk must be lazy (Explicit) — use `lazy …` so the tail is not auto-forced Extracted library reference: evaluator/builtin_stream.go:43. These notes are not a complete signature or a stability guarantee. Manual §13.37 Hidden slots, scanners, turtles, and concatenative extras; read with manual "13.37" Excerpt: a `Stream` is not. `stream()` is empty (a container identity). `stream(xs)` copies a collection. `stream_cons(h, t)` prepends; the tail is a `Stream` or a `lazy` Stream — a transparent thunk is refused, because reading it would collapse the tail.

string

Function

string(x)
Display form of any value, as a String — canonical spelling of `str`. Manual §22.8 List & string helpers; read with manual "22.8" Excerpt: ### List & string helpers ```axioma butlast([1, 2, 3, 4]) # → [1, 2, 3] (all but the last)

string?

Function

Call diagnostics (different branches may describe different overloads): • string? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

string_to_bytes

Function

Call diagnostics (different branches may describe different overloads): • string_to_bytes requires 1-2 arguments (String, [encoding]) Extracted library reference: evaluator/builtin_bytes.go:244. These notes are not a complete signature or a stability guarantee. Manual §4.6.2 Conversions (explicit + fallible); read with manual "4.6.2" Excerpt: | `bytes_to_string(bs, "utf-8")` | `String` | bytes aren't valid UTF-8 | | `string_to_bytes(s, "utf-8")` | `Bytes` | encoding unknown | | `base64_encode(bs)` / `base64_decode(s)` | round-trip | decoder errors on bad input | | `read_bytes(path)` / `write_bytes(path, bs)` | file I/O | path missing / permission |

stringf

Function

stringf(format, args...)
Like printf but RETURNS the formatted String instead of printing — usable inside expressions. Same verb set and the same verb-aware adaptation: integral cross-type numerics convert (%d takes 35.0, %f takes 5, %.2f takes 1/3), %s/%q stringify anything, and every mismatch (fractional value under %d, wrong type, arity, unknown verb) is a loud catchable error with a rewrite hint — never a silent '%!d(float64=…)' badge in the result. format is an exact alias.

Examples

stringf("%d %d", floor(x), floor(x + 0.5))

stringf("%.2f", 1/3)      # "0.33"

stringf("%d", 35.7)       # ERROR — use floor(x)/round(x) or %g

struct

Declaration

type P = struct [mutable|mut] {x:: Float} | type P = struct [mutable|mut]
 x:: Float
end
Closed nominal record with named fields: `x:: Float` is checked and an Integer given for a Float field converts to that Float; a bare lowercase field is open and accepts any value. struct is the primary spelling; record is an alias in the type kind slot, not a Dictionary schema. Both are immutable by default and use the same struct AST and data value semantics. mut and mutable after either word select the same mutable struct. struct mutable permits typed dot/reference writes, has reference equality and stable identity keys; copy() yields a distinct record, and sort/min/max refuse it (order by a field key with sort_by). Functional updates reconstruct validated values. has/had refuse on a struct name. Braces, end bodies and generic parameters work with every spelling. No standalone struct or record declaration. Evaluator-only; the VM refuses all spellings.

Examples

type P = struct mutable {x:: Float}
let p = P(1.0)
p.x = 2.0
println(p.x)

su'o

Keyword

Lojban-inspired existential quantifier: at least one member of the explicit domain. Also spelled su'o.

sub1

Function

numericIncrBuiltin: add1 (1+) / sub1 (1-), preserving numeric type via the shared computeAdd. Call diagnostics (different branches may describe different overloads): • sub1 requires exactly 1 argument Extracted library reference: evaluator/scheme_extras.go:371. These notes are not a complete signature or a stability guarantee. Manual §22.3 Mathematical functions; read with manual "22.3" Excerpt: | `square(x)` | `x * x`, preserving numeric type | | `add1(x)` / `sub1(x)` | `x + 1` / `x - 1` (Lisp `1+` / `1-`) | | `succ(x)` / `pred(x)` | Successor / predecessor over the ordinal types (Pascal/Ada `'Succ`/`'Pred`): Integers (`succ(5)` → 6) and enum members (`succ(Mon)` → Tue, erroring at the ends). On Integers ≡ `add1`/`sub1`; the ordinal-typed, enum-symmetric spelling | | `isqrt(n)` | Integer floor square root of a non-negative integer (exact, big-int aware) | | `numerator(r)` / `denominator(r)` | Rational accessors; an integer `n` is `n/1` (so `denominator(5)` → `1`) |

subclass_of?

Function

Registered alias of is_subclass_of.Concept introspection functions for natural DL syntax Call diagnostics (different branches may describe different overloads): • both arguments to is_subclass_of must be concepts • is_subclass_of requires exactly 2 arguments: subconcept, superconcept Extracted library reference: evaluator/builtins.go:5853. These notes are not a complete signature or a stability guarantee.

subscr_stack

Function

Call diagnostics (different branches may describe different overloads): • first argument to subscr_stack must be a stack • second argument to subscr_stack must be an integer • subscr_stack requires 2 arguments: stack, index Extracted library reference: evaluator/builtins.go:12392. These notes are not a complete signature or a stability guarantee.

subset

Operator

set1 subset set2
Subset operator - checks if set1 is a subset of set2

Examples

{1, 2} subset {1, 2, 3}

required subset available

subseteq

Symbol

=== ⊆ (Glyph) === name: subset words: subset latex: subseteq category: set codepoint: U+2286 meaning: A ⊆ B — subset (or equal)

subsetneq

Symbol

=== ⊂ (Glyph) === name: proper_subset words: proper_subset, subsetneq, proper subset latex: subset, subsetneq variants: ⊊ category: set codepoint: U+2282 meaning: A ⊂ B — proper (strict) subset

subst

Function

substBuiltin(template, bindings) → template with each ?var replaced by its bound AST. bindings is a Dictionary of name→AST (as match_pattern returns). Call diagnostics (different branches may describe different overloads): • subst requires 2 arguments (template, bindings) Extracted library reference: evaluator/builtin_ast_pattern.go:87. These notes are not a complete signature or a stability guarantee. Manual §19.10.4 Pattern rewriting — `match_pattern` / `subst` / `replace_all` / `rules`; read with manual "19.10.4" Excerpt: #### Pattern rewriting — `match_pattern` / `subst` / `replace_all` / `rules` The algebra above is the substrate for **term rewriting** — Mathematica's `expr /. rule` and the heart of a computer-algebra system. Patterns reuse Axioma's existing `?x` variable syntax; no new lexer.

substring

Function

substring(s, start, end)
1-indexed inclusive slice (substring("hello", 2, 4) → "ell"). Manual §4.5.9 Substring search — `index_of` and `span_of`; read with manual "4.5.9" Excerpt: #### Substring search — `index_of` and `span_of` Two builtins locate a substring, both in **1-based character (rune) coordinates** — the same coordinates `substring`, `s[a..b]` slicing, and

subsumed_by?

Function

Registered alias of is_subsumed_by.is_subsumed_by(kb, sub_concept, super_concept) - Check subsumption with transitive closure Example: is_subsumed_by(kb, "Undergrad", "Person") → true Call diagnostics (different branches may describe different overloads): • concept names must be strings • first argument must be a DL knowledge base • is_subsumed_by requires 3 arguments: kb, sub_concept, super_concept Extracted library reference: evaluator/builtins.go:18880. These notes are not a complete signature or a stability guarantee.

subsumes

Function

subsumes(kb, subconcept, superconcept) - Add subsumption axiom C ⊑ D Example: subsumes(kb, "Student", "Person") → Student is a Person Call diagnostics (different branches may describe different overloads): • first argument must be a DL knowledge base • second argument must be a string (subconcept) • subsumes requires 3 arguments: kb, subconcept, superconcept • third argument must be a string (superconcept) Extracted library reference: evaluator/builtins.go:18398. These notes are not a complete signature or a stability guarantee. Manual §13.15 Description Logic — concept algebra `⊓ ⊔ ¬ ⊑ ≡` + `satisfiable`; read with manual "13.15" Excerpt: **`⊑` vs `subsumes` — converse readings.** The glyph `⊑` reads in the standard DL direction (`C ⊑ D` means C is the *more specific* subconcept — `Student ⊑ Person` is true). The English word `subsumes` reads the other way (`A subsumes B` means A is the *more general* superclass — `Person subsumes Student` is true).

subtype_of?

Function

Registered alias of is_subtype_of.is_subtype_of(a, b) - Tests if A is a subtype of B using divisibility Example: is_subtype_of(10374, 6) → true (human has body) Call diagnostics (different branches may describe different overloads): • first argument must be an integer or Leibniz encoding • is_subtype_of requires 2 arguments: a, b • second argument must be an integer or Leibniz encoding Extracted library reference: evaluator/builtins.go:19911. These notes are not a complete signature or a stability guarantee.

succ

Function

succ(x)
Successor: the next Integer (or enum member). Manual §6.3 Compound assignment; read with manual "6.3" Excerpt: Spaced forms keep their math meaning: `-(-x)` and `- -x` are still double negation. For a pure, value-returning step use `succ(n)` / `pred(n)` ([§22](#22-mathematical-constants--built-ins)). ### Logical (auto-dispatched on operand type)

successor

Function

successor(x)
Function symbol that returns the successor (x+1) of a number. Essential for Peano arithmetic and mathematical induction.

Examples

successor(7)  # Returns 8

successor(0)  # Returns 1

forall x in Numbers: greater(successor(x), x)

suho

Keyword

Lojban-inspired existential quantifier: at least one member of the explicit domain. Also spelled su'o.

sum

Function

sum(collection)
Sum of a numeric array/set/tuple — promotes past int64 exactly. Manual §5.5 Unary dot fallback — `xs.sum ≡ sum(xs) ≡ xs's sum`; read with manual "5.5" Excerpt: ### Unary dot fallback — `xs.sum ≡ sum(xs) ≡ xs's sum` On a **slot-less value** — Array, Tuple, String, Set, Range, scalars, Bytes, Bag, AST — a dot or possessive read whose name is not an accessor applies the

superset

Symbol

=== ⊇ (Glyph) === name: superset words: superset latex: supseteq category: set codepoint: U+2287 meaning: A ⊇ B — superset (or equal)

supset

Symbol

=== ⊃ (Glyph) === name: proper_superset words: proper_superset, supsetneq, proper superset latex: supset, supsetneq variants: ⊋ category: set codepoint: U+2283 meaning: A ⊃ B — proper (strict) superset

supseteq

Symbol

=== ⊇ (Glyph) === name: superset words: superset latex: supseteq category: set codepoint: U+2287 meaning: A ⊇ B — superset (or equal)

supsetneq

Symbol

=== ⊃ (Glyph) === name: proper_superset words: proper_superset, supsetneq, proper superset latex: supset, supsetneq variants: ⊋ category: set codepoint: U+2283 meaning: A ⊃ B — proper (strict) superset

suspend

Keyword

ConceptName suspend
Temporarily suspends a concept, making it unavailable but preserving it for later unsuspension

Examples

Person suspend

Stock suspend

Vehicle suspend

svd

Function

Call diagnostics (different branches may describe different overloads): • argument to svd must be a matrix • svd requires exactly 1 argument: matrix Extracted library reference: evaluator/builtins.go:14232. These notes are not a complete signature or a stability guarantee.

swap

Function

Call diagnostics (different branches may describe different overloads): • argument to swap must be a stack • swap requires 1 argument: stack • swap requires at least 2 items on stack Extracted library reference: evaluator/builtins.go:12034. These notes are not a complete signature or a stability guarantee. Manual §18.2 Stack-shuffle operations; read with manual "18.2" Excerpt: | `dup(s)` | `a → a a` | Duplicate top | | `swap(s)` | `a b → b a` | Swap top two | | `rot(s)` | `a b c → b c a` | Rotate top three | | `over(s)` | `a b → a b a` | Copy second to top | | `drop(s)` | `a →` | Discard top |

swapcase

Function

swapcase(s)
Upper becomes lower and lower becomes upper; caseless characters unchanged.

switch

Keyword

switch expr | pattern [when guard] => body | …
ReasonML spelling of `case`. Same matcher, same CASE token: `switch e | p => …` ≡ `case e | p => …`. Reserved (not a name — use `$switch`). `switch/strict` is `case/strict`. First `|` is required. Reason's `{ }` around the arms is not used — `{}` is the empty set ∅. Evaluator-only: `--vm` refuses.

Examples

switch pair | (1, x, 3) => x | _ => 0

switch pair
| (1, x, 3) => x
| _ => 0

switch/strict 1 | 1 => "one" | _ => "no"

syllogism

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §31 Proof Assistant; read with manual "31" Excerpt: commutativity, excluded middle, double-negation elimination, K, hypothetical syllogism, contraposition, `=` reflexivity/symmetry/transitivity) plus a `provenLemmas` catalog you can cite as axioms (each is a proven closed theorem = a derived rule):

sym

Function

symBuiltinSingle backs `sym("x")` — exactly one indeterminate. Call diagnostics (different branches may describe different overloads): • sym expects a single name; use syms(...) for several Extracted library reference: evaluator/symbolic.go:502. These notes are not a complete signature or a stability guarantee.

symbol?

Function

Call diagnostics (different branches may describe different overloads): • symbol? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1633. These notes are not a complete signature or a stability guarantee. Manual §22.6.1 Scheme/Lisp-style predicates (`?` suffix); read with manual "22.6.1" Excerpt: empty?([]) # true — also "" / set() / {} / dict() ; an infinite set is never empty symbol?('hello) # true — a lit-word is a symbol ; symbol_name('hello) → "hello" # float domain (`inf` / `nan` are builtins producing ±∞ / NaN floats) # `is_X` ≡ `X?` — both spellings, same function (`is_nan` ≡ `nan?`)

symbol_name

Function

symbolNameBuiltin: the name string of a symbol/word (Scheme symbol->string). Pairs with the symbol? predicate. Call diagnostics (different branches may describe different overloads): • symbol_name requires exactly 1 argument Extracted library reference: evaluator/scheme_extras.go:720. These notes are not a complete signature or a stability guarantee. Manual §22.6.1 Scheme/Lisp-style predicates (`?` suffix); read with manual "22.6.1" Excerpt: empty?([]) # true — also "" / set() / {} / dict() ; an infinite set is never empty symbol?('hello) # true — a lit-word is a symbol ; symbol_name('hello) → "hello" # float domain (`inf` / `nan` are builtins producing ±∞ / NaN floats) # `is_X` ≡ `X?` — both spellings, same function (`is_nan` ≡ `nan?`)

symbolize

Function

Call diagnostics (different branches may describe different overloads): • argument to symbolize must be a string or natural language • symbolize requires exactly 1 argument: natural language description Extracted library reference: evaluator/builtins.go:16851. These notes are not a complete signature or a stability guarantee. Manual §28.4 28.4 Cross-language translation — `[A -> B | … ]` / `[A --> B | … ]`; read with manual "28.4" Excerpt: | `[A --> B \| body]` | translate, then execute in B | typed value from B's runtime | | `[nl -> B \| description]` | symbolize natural-language description into B | `String` of B's source | | `[nl --> B \| description]` | symbolize, then execute in B | typed value from B's runtime | Every form reads the body **raw** via the same bracket-counting reader

symbols

Function

symbols() | symbols(category)
The Unicode-glyph catalog — the glyph twin of the reserved-word catalog keywords(). With no arguments, returns an Array of every catalogued Glyph value in table order (each carries its character, name, word aliases, LaTeX names, category, and meaning). With one String argument, filters by category (case-insensitive). The catalog is the source behind the backtick digraphs (`union → ∪), the REPL \name+Tab expansion, --glyphify/--asciify, and :doc <glyph>. Not to be confused with sym()/syms(), which construct CAS symbolic indeterminates.

Examples

len(symbols())        # the full glyph catalog

symbols("set")        # only the set-theory glyphs

first(symbols())      # a Glyph value — prints as its character

glyph("union")        # fetch ONE glyph by any alias instead

keywords()            # the word twin: reserved words

symdiff

Symbol

=== △ (Glyph) === name: symmetric_difference words: symmetric_difference, symdiff, symmetric difference latex: triangle, ominus variants: ∆ ⊖ category: set codepoint: U+25B3 meaning: A △ B — symmetric difference (members in exactly one set)

symmetric

Keyword

relation r(x, y) symmetric
Declares a binary relation symmetric (Kant's community/reciprocity): every asserted fact r(a, b) also stores its mirror r(b, a) at the same grounding. Soft modifier — `symmetric` stays an ordinary identifier elsewhere.

Examples

relation friends(x, y) symmetric

axiom friends("alice", "bob")

{X | X <- friends("bob", X)}   # {"alice"}

symmetric difference

Symbol

=== △ (Glyph) === name: symmetric_difference words: symmetric_difference, symdiff, symmetric difference latex: triangle, ominus variants: ∆ ⊖ category: set codepoint: U+25B3 meaning: A △ B — symmetric difference (members in exactly one set)

symmetric_difference

Symbol

=== △ (Glyph) === name: symmetric_difference words: symmetric_difference, symdiff, symmetric difference latex: triangle, ominus variants: ∆ ⊖ category: set codepoint: U+25B3 meaning: A △ B — symmetric difference (members in exactly one set)

syms

Function

symBuiltinMany backs `syms("x y z")` — an Array of indeterminates. Extracted library reference: evaluator/symbolic.go:514. These notes are not a complete signature or a stability guarantee.

synthesize

Reserved vocabulary

Reserved vocabulary with no dedicated parser implementation in this build. It is not a usable standalone form. Use doc "discover" for the implemented discovery interface, and manual for supported language forms. Recognition of a name is not a claim that its intended feature is implemented.

ta'i

Keyword

Manner or method tag in a tagged relational form.

tableform

Function

tableform(relation) | tableform(func, [domain])
Renders a relation's fact extent — or a function's TRUTH TABLE — as an ASCII table with Unicode box-drawing borders. Relation form: headers from declared slot names, rule-derived facts included. Function form: one row per assignment of domain values to the parameters (leftmost varies slowest, the textbook layout); input columns are headed by the parameter names and the result column by the function's body expression ("p and q"; multi-statement bodies fall back to "result"); default domain {true, false}, or name a logic ("kleene", "belnap", "lp", "lukasiewicz", "g3") to print its MVL table, or pass an explicit Array/Set of values for a general function table. truth_table(f) returns the same rows as a Set of tuples — data vs display. Sibling: fullform, treeform, graphform.

Examples

relation edge(x, y)

assert edge("a", "b")

tableform(edge)                          # relation extent as a table

tableform(func(p, q) [p and q])          # classical truth table (4 rows)

tableform(func(p, q) [p ⊼ q], "kleene")  # strong-Kleene NAND, 3×3

tableform(func(p, q) [p and q], "belnap") # the full B4 4×4 table

tableform(func(x) [x * x], [1, 2, 3])    # general function table

tag

Function

chr(codepoint) — return a single-character String containing the given Unicode codepoint. Companion to `ord`. Accepts the full Unicode range U+0000 to U+10FFFF; surrogate codepoints (U+D800–U+DFFF) are rejected as they cannot appear in valid UTF-8. Use this for programmatic codepoint construction when the literal form `"\u{...}"` won't work (e.g. value computed at runtime). tag(c) — the constructor tag of an algebraic data type value, as a String (`tag(Circle(3.0)) → "Circle"`, `tag(Dot) → "Dot"`). The data TYPE name is read with `type(c)` / `@c`; this reads the constructor axis. Errors on any non-ConstructorValue. Call diagnostics (different branches may describe different overloads): • tag requires exactly 1 argument (a constructor value) Extracted library reference: evaluator/builtins.go:3113. These notes are not a complete signature or a stability guarantee. Manual §7.6 Tag-filter comprehensions; read with manual "7.6" Excerpt: ### Tag-filter comprehensions Filter relational-source comprehensions by epistemic grounding tag — in the set, list, dict, multi-variable, and multi-generator forms:

tag?

Function

Call diagnostics (different branches may describe different overloads): • tag? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee. Manual §33.14 Unions — untagged, tagged, and bottoms; read with manual "33.14" Excerpt: | Kind | Form | Value carries a tag? | Typical use | |---|---|---|---| | **Untagged** | `x :: String \| None` | No — just a string or none | “this binding may be one of several *kinds*” | | **Tagged ADT** | `data T = A \| B(x)` | Yes — constructor name | Domain cases, match, exhaustiveness |

tailcall

Function

Call diagnostics (different branches may describe different overloads): • first argument to tailcall must be callable • tailcall requires at least 1 argument: function Extracted library reference: evaluator/builtins.go:5183. These notes are not a complete signature or a stability guarantee.

take

Keyword

take "path.ax" | take NAME [as ALIAS], ... from "path.ax" | take * [hiding NAME, ...] from "path.ax"
Natural-language spelling of `import`. Same forms, including rename and hide.

Examples

take max as bigger from "lib/math.ax"

take * hiding sqrt from "lib/math.ax"

take_solutions

Function

take_solutions(count, stream)
Pull up to count answers into an Array, preserving order and duplicates. count must be a nonnegative Integer. This consumes the stream and does not cancel it. Exactly count pulls need not establish exhaustion. An error aborts the call instead of returning a misleading complete prefix.

take_while

Function

takeWhileBuiltinFn keeps the leading run while the predicate holds, stopping at the first failure. dropWhileBuiltinFn is the complement. Both return an Array. Call diagnostics (different branches may describe different overloads): • take_while requires exactly 2 arguments: a predicate and a collection Extracted library reference: evaluator/builtins.go:22957. These notes are not a complete signature or a stability guarantee. Manual §5.10 Sets; read with manual "5.10" Excerpt: `repeat`, `loop`), `map`, `filter`, `array(s)`, the folds (`reduce`, `foldl`, `foldr`), and the Enumerable verbs (`take_while`, `sort_by`, `min_by`, `group_by`, `flat_map`, …). ```axioma

tally

Function

tallyBuiltinFn counts occurrences of each element, returning a Dictionary of element → count (Ruby's tally / Clojure's frequencies). Keys stringify like group_by: a String element keys by its raw .Value, anything else by Inspect(). Call diagnostics (different branches may describe different overloads): • tally requires exactly 1 argument: a collection Extracted library reference: evaluator/builtins.go:22715. These notes are not a complete signature or a stability guarantee. Manual §5.12.5 Behavior interfaces — attach methods by type; read with manual "5.12.5" Excerpt: | `Enumerable` | marker — arrays, sets, dicts, strings, … | | `Iterable` | `elements(x)` / `dispatch(Iterable, "iterate", x)` — custom types participate in `for` / comprehensions **and** the Enumerable verbs (`sort_by`, `map`, `tally`, `take_while`, …). Matrix is seeded and walks individual cells row-major; it is not `Sized`. The method is `iterate`; the global is `elements`. `iterate(fn, start[, count])` is the list verb (Haskell unfold), a different function. | | `Sized` | `len` / `length` / `size` — native count, then `dispatch(Sized, "size", x)`. Slot is `size`. Not `cardinality` (F-logic registrar). | | `Indexable` | `a[i]` / `nth(a, i)` — native ordinal read, then `dispatch(Indexable, "at", a, i)`. Optional `put` for `a[i] = v`; optional `slice` for `a[i:j]` (else gather via `at`). Integer keys only. Entity `r["name"]` stays `r.name`. `p[slot -> val]` is a different form (frame write). Dictionary is keyed, not Indexable. | | `Semigroup` | `combine(a, b)` — seeded for String/Array/List/Tuple/Bytes (concatenation). Not Integer. |

tan

Function

tan(x)
Tangent (radians). Manual §22.3 Mathematical functions; read with manual "22.3" Excerpt: | `pow(b, e)` | Exponentiation | | `sin(x)` / `cos(x)` / `tan(x)` | Trigonometry — arguments in **radians** (like Lua/C); convert with `rad`/`deg` | | `asin(x)` / `acos(x)` / `atan(x)` | Inverse trig, radians (`asin`/`acos` domain-checked). `atan(y, x)` 2-arg is the full-quadrant form (Lua 5.3+ `math.atan`) | | `atan2(y, x)` | Full-quadrant arctangent — the C/Python spelling of `atan(y, x)` (`atan2(1, 0)` → `pi/2`) | | `sinh(x)` / `cosh(x)` / `tanh(x)` | Hyperbolic functions |

tanh

Function

tanh(x)
Hyperbolic tangent. Manual §22.3 Mathematical functions; read with manual "22.3" Excerpt: | `atan2(y, x)` | Full-quadrant arctangent — the C/Python spelling of `atan(y, x)` (`atan2(1, 0)` → `pi/2`) | | `sinh(x)` / `cosh(x)` / `tanh(x)` | Hyperbolic functions | | `deg(x)` | Radians → degrees (`deg(pi)` → `180`; Lua `math.deg`) | | `rad(x)` | Degrees → radians (`rad(180)` → `pi`; `sin(rad(90))` → `1`; Lua `math.rad`) | | `quotient(a, b)` / `a quotient b` | Floor division, rounding toward −∞ (same as `a ÷ b` / `a div b`) |

tanru

Function

==================================================================================== LOJBAN++ - Phase 2: Tanru (Multi-Word Semantic Compounds) ==================================================================================== tanru(phrase) - Create tanru compound from phrase Call diagnostics (different branches may describe different overloads): • tanru argument must be a string • tanru requires exactly 1 argument (phrase) Extracted library reference: evaluator/builtins.go:20486. These notes are not a complete signature or a stability guarantee.

tap

Function

tapBuiltinFn applies the function to the value for its side effect and returns the value UNCHANGED (Ruby's tap) — for peeking mid-pipeline, e.g. xs |> sort |> tap(println) |> first. Value-last: tap(fn, value); any callback error still propagates. Call diagnostics (different branches may describe different overloads): • tap requires exactly 2 arguments: a function and a value Extracted library reference: evaluator/builtins.go:23200. These notes are not a complete signature or a stability guarantee. Manual §12.17 Enumerable verbs; read with manual "12.17" Excerpt: character). Ruby's first-match is `find`/`detect`; `find` is a reserved solver keyword here, so the collection verb is `detect`. `tap` runs its function for a side effect and returns the value unchanged — handy for peeking inside a `|>` chain. All work under `--vm`.

tau

Value

Built-in FLOAT value: 6.283185307179586 Manual §3.9 `global` — Julia's module write; read with manual "3.9" Excerpt: **Builtins vs constants.** The lowercase math names (`pi`, `e`, `tau`, `im`, …) are *shadowable* fallback builtins — `pi: 3` wins locally and leaves the system untouched. The canonical UPPERCASE constants (`PI`, `TAU`, `EULER`, …) are seeded immutable: `PI: 3` reports `Cannot reassign constant 'PI'`

tautology?

Function

Registered alias of is_tautology.is_tautology(expr) - Check if expression is a tautology (always true) Uses DPLL SAT solver: φ is tautology iff ¬φ is unsatisfiable Example: is_tautology(func(p) [ p or not p ]) → true Call diagnostics (different branches may describe different overloads): • is_tautology requires exactly 1 argument: a boolean expression Extracted library reference: evaluator/builtins.go:16945. These notes are not a complete signature or a stability guarantee.

taxonomy

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §19.10.7 Where Axioma sits in the homoiconicity taxonomy; read with manual "19.10.7" Excerpt: #### Where Axioma sits in the homoiconicity taxonomy Per [Wikipedia's taxonomy of homoiconic languages](https://en.wikipedia.org/wiki/Homoiconicity), Axioma is in the **"weaker tier"** alongside **Julia, Elixir, and Nim** — full toolkit (quote, quasiquote, AST construction, AST evaluation, macros, macroexpand, hygiene primitive) but source code is parsed rather than being a literal data structure.

teleologically

Operator

P teleologically Q
Aristotle's final cause (telos) — the four-cause family with `materially` / `formally` / `efficiently`. Was spelled `finally` until that word became try-cleanup.

Examples

"acorn" teleologically "oak"

temporal_model

Function

temporal_model(type) - Create a new temporal model for Linear Temporal Logic Example: temporal_model("linear") → New LTL model Extracted library reference: evaluator/builtins.go:17717. These notes are not a complete signature or a stability guarantee.

tensor

Function

Tensor operations Call diagnostics (different branches may describe different overloads): • fill value must be numeric • tensor requires at least 1 argument Extracted library reference: evaluator/builtins.go:14280. These notes are not a complete signature or a stability guarantee. Manual §5.14 Matrices, tensors & dataframes; read with manual "5.14" Excerpt: ```axioma t: tensor([[[1, 2], [3, 4]], [[5, 6], [7, 8]]]) # rank-3 from nesting shape(t) # → [2, 2, 2] ; ndim(t) → 3 tensor([2, 3], 7) # shape + fill → 2×3 of 7s tensor_reshape(tensor([1, 2, 3, 4, 5, 6]), [2, 3]) # → 2×3

tensor_reshape

Function

Call diagnostics (different branches may describe different overloads): • array elements must be numeric • first argument must be tensor, matrix, or array • tensor_reshape requires 2 arguments: tensor/matrix, new_shape Extracted library reference: evaluator/builtins.go:14322. These notes are not a complete signature or a stability guarantee. Manual §5.14 Matrices, tensors & dataframes; read with manual "5.14" Excerpt: tensor([2, 3], 7) # shape + fill → 2×3 of 7s tensor_reshape(tensor([1, 2, 3, 4, 5, 6]), [2, 3]) # → 2×3 squeeze(tensor([[1, 2, 3]])) # drop size-1 axes → vector [3] expand_dims(tensor([1, 2, 3]), 0) # add an axis → 1×3 ```

tenth

Function

ordinalBuiltin builds a 1-argument ordinal accessor (second..tenth) backed by nthElement, so the whole Racket-style family shares one implementation and works on finite collections and infinite sets alike. Call diagnostics (different branches may describe different overloads): • tenth requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1528. These notes are not a complete signature or a stability guarantee. Manual §5.3 Sequence accessors — `xs.length`, `xs's first`, `xs.indexed`; read with manual "5.3" Excerpt: | `first` / `last` | edge element | `none` when empty — a query never crashes | | `second` … `tenth` | k-th element | ordinals ≡ `second(xs)`…`tenth(xs)`; `none` when out of range | | `empty` | Boolean | the guard for `first`/`last` | | `indexed` / `enumerated` | Array of `(i, e)` pairs | 1-based, index-first — the indexed view for loops and comprehensions |

tfl

Function

tfl(text) — parse a Term Functor Logic expression (chs. 8–9: Sommers/Englebretsen plus-minus algebra) and return its canonical rendering. Examples: tfl("−A + B"), tfl("±R + (L ∀ J)"). Call diagnostics (different branches may describe different overloads): • tfl requires 1 argument: TFL expression text • tfl: argument must be a string Extracted library reference: evaluator/builtins.go:17606. These notes are not a complete signature or a stability guarantee.

tfl_valid

Function

tfl_valid(argument) — Sommers' algebraic decision procedure (p. 182: Principle of Equivalence + Principle of Validity): valid iff positive-valence premises equal positive conclusions (0 or 1) and the premises sum algebraically to the conclusion. Wild ± quantities resolve by search; pure 2-premise categoricals are cross-checked against the 256-model syllogistic engine. Example: tfl_valid("−M + P, −S + M ∴ −S + P") Call diagnostics (different branches may describe different overloads): • tfl_valid requires 1 argument: `premises ∴ conclusion` • tfl_valid: argument must be a string Extracted library reference: evaluator/builtins.go:17631. These notes are not a complete signature or a stability guarantee.

the

Keyword

the Concept where predicate
Russell-style definite description: denotes the entity (or intensional class) of the concept satisfying the predicate. Bind it and use it as a classification target.

Examples

adults: the Person where age >= 18

{ x | x is adults }

then

Keyword

if condition then expression else expression
Introduce the selected branch of the compact if form. An end-terminated if header omits then and places the body on the next line. See doc if.

Examples

println(if true then 1 else 2)

theorem

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §13.4 Concept formation layer (Phase 1); read with manual "13.4" Excerpt: The stored is-fact inherits `axiom` grounding (not the strict-`defines` default of `theorem`) because Stipulation-formed concepts cross-map to `axiom`. The same active-grounding flow fires at object-instantiation time:

there

Keyword

there is x in S | P  (∃ quantifier)  |  there is subject
Existence (Frege/Russell): `there is x in S | P` is the existential quantifier (same AST as `exists x in S | P`; also `:` separator and ∈); `there is subject` checks a subject's existence (bound identifier / non-null value)

Examples

there is x in nums | x > 3      # ∃ quantifier (== exists x in nums | x > 3)

there is x in {1, 2, 3}: x > 2  # colon separator

there is king                    # subject existence (bound → true)

therefore

Symbol

=== ∴ (Glyph) === name: therefore words: therefore latex: therefore, qed, thus category: logic codepoint: U+2234 meaning: p ∴ q — therefore / QED (the conclusion / inference mark; canonicalizes to the `therefore` operator)

third

Function

ordinalBuiltin builds a 1-argument ordinal accessor (second..tenth) backed by nthElement, so the whole Racket-style family shares one implementation and works on finite collections and infinite sets alike. Call diagnostics (different branches may describe different overloads): • third requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1528. These notes are not a complete signature or a stability guarantee. Manual §3.3.1 Uninitialized slots and identity defaults; read with manual "3.3.1" Excerpt: **`= _` (uninitialized).** Requires a fresh named binding spelling; a `::` type is optional. The slot holds binding *state*, not a third bottom: it is not `none`, not `om`, not `0`. Reading before the first successful assignment is a hard error. Later `x = v` / `x: v` fills the same cell and re-checks any snapshotted annotation. Without an annotation, the first value does not impose a permanent

thus

Symbol

=== ∴ (Glyph) === name: therefore words: therefore latex: therefore, qed, thus category: logic codepoint: U+2234 meaning: p ∴ q — therefore / QED (the conclusion / inference mark; canonicalizes to the `therefore` operator)

tier

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §8.6 Other Tier 1 textbook additions; read with manual "8.6" Excerpt: ### Other Tier 1 textbook additions ```axioma # Biconditional — both Unicode forms lex to IFF

tilde

Symbol

=== ~ (Glyph) === name: tilde category: logic codepoint: U+007E meaning: ~ — tilde (defeasible marker; ~~> is the defeasible-forward rule)

tilde_negation

Symbol

=== ∼ (Glyph) === name: tilde_negation latex: sim category: logic codepoint: U+223C meaning: ∼p — logical negation (philosophical-text tilde; canonicalizes to ¬)

time

Constructor

time(value) | time(hours, minutes, seconds)
Signed relative Time with nanosecond resolution. Accepts Time, Duration, finite numeric seconds, or a colon string. Component hours/minutes are Integer; seconds may be fractional. Nonnegative minutes/seconds overflow normally; a negative hour negates the whole component value. 23:61 becomes 24:01. H:M is hours/minutes; M:S.f is minutes/seconds. Time arithmetic supports addition/subtraction, numeric second offsets and scaling; Time/Time is an exact ratio. Construction rounds ties away from zero; arithmetic truncates below a nanosecond. Values must fit signed int64 nanoseconds. float(Time) and int(Time) expose seconds; Dt.duration(Time), after importing builtin:datetime as Dt, bridges to the datetime package. DateTime remains an instant; Date and Duration APIs are preserved. Interpreter only.

Examples

time(25, 0, 0) # 25:00

time(1.5) # 0:00:01.5

1:30 + 30 # 1:30:30

1:00 / 0:30 # 2

time?

Function

Call diagnostics (different branches may describe different overloads): • time? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

title

Function

title(s)
Title case: first letter of each word up, rest of the word down ("hELLO wORLD" → "Hello World"). Manual §4.5.6 Case mapping — `upper` / `lower` / `title` (and Julia aliases); read with manual "4.5.6" Excerpt: #### Case mapping — `upper` / `lower` / `title` (and Julia aliases) ```axioma upper("Hello") # → "HELLO"

titlecase

Function

titlecase(s)
Julia spelling of title (strict rest-lowercased). Same function, same answers. Not capitalize. Manual §4.5.6 Case mapping — `upper` / `lower` / `title` (and Julia aliases); read with manual "4.5.6" Excerpt: `uppercase` / `lowercase` / `titlecase` are aliases of `upper` / `lower` / `title`. A Character in is a Character out (`uppercase('a')` is `'A'`). `uppercasefirst` is not `capitalize` (Julia leaves the rest of the string alone) and is not shipped.

tl

Function

tl(s, [n])
Short spelling of rest — an exact alias. The TAIL (all but the first), not the last element. Manual §5.4 Lists and recursion — `[h | t]`; read with manual "5.4" Excerpt: `rest`. Note that **`tl` is `rest`, not `last`** — the tail of a list is a *list*: `tl([1,2,3])` is `[2,3]` where `last([1,2,3])` is `3`. And `hd` is partial where `tl` is total: `hd([])` raises, `tl([])` is `[]`, so write the base case as `empty?(xs)` rather than leaning on the tail to fail. - **In a `match` arm, `[h]` is a block, not a one-element array** — it evaluates

to

Symbol

=== → (Glyph) === name: implies words: implies latex: to, rightarrow, implies variants: ⟹ category: logic codepoint: U+2192 meaning: p → q — material implication

to_array

Function

to_array(x) — x as an ordered Array. Extracted library reference: evaluator/builtin_strings.go:649. These notes are not a complete signature or a stability guarantee. Manual §5.11 Bags (multisets); read with manual "5.11" Excerpt: Set support), since `{...}` cannot carry multiplicities. Use `to_array(b)` to iterate every occurrence. **As slot values.** Bags can be slot values on Concepts; the `unify` machinery uses **additive sum** as the merge policy — two partial

to_ast

Function

Call diagnostics (different branches may describe different overloads): • to_ast requires exactly 1 argument Extracted library reference: evaluator/builtins.go:16346. These notes are not a complete signature or a stability guarantee.

to_base

Function

Base conversion. to_base / from_base are the general pair (base 2..36, lowercase digits, big-int aware); hex/oct/bin are the common shorthands. No "0x"/"0o"/"0b" prefix is emitted or required — bare digits, so to_base(255,16) → "ff" and from_base("ff",16) → 255. Call diagnostics (different branches may describe different overloads): • to_base requires exactly 2 arguments: an integer and a base (2..36) Extracted library reference: evaluator/builtins.go:4333. These notes are not a complete signature or a stability guarantee.

to_cnf

Function

to_cnf(expr) - Convert propositional logic expression to Conjunctive Normal Form CNF is a conjunction of disjunctions: (A ∨ B) ∧ (C ∨ D) Example: to_cnf(func(p,q) [ p => q ]) → func(p,q) [ not p or q ] Call diagnostics (different branches may describe different overloads): • to_cnf requires exactly 1 argument: a boolean expression Extracted library reference: evaluator/builtins.go:16887. These notes are not a complete signature or a stability guarantee.

to_data

Function

to_data(ast) → the runtime value a quoted structure denotes (the code→value direction; realizes the AST via the env-less evaluator `do` falls back to). `to_data('[1,2,3])` → [1, 2, 3]; `to_data('({1,2}))` → {1, 2}; `to_data('(5))` → 5. Call diagnostics (different branches may describe different overloads): • to_data requires exactly 1 argument (an AST value) Extracted library reference: evaluator/builtin_ast_algebra.go:69. These notes are not a complete signature or a stability guarantee. Manual §19.10.6 The code ↔ data bridge — `to_data` / `from_data`; read with manual "19.10.6" Excerpt: #### The code ↔ data bridge — `to_data` / `from_data` Two converters cross the line between a quoted AST and an ordinary value:

to_dnf

Function

to_dnf(expr) - Convert propositional logic expression to Disjunctive Normal Form DNF is a disjunction of conjunctions: (A ∧ B) ∨ (C ∧ D) Example: to_dnf(func(p,q) [ not (p and q) ]) → func(p,q) [ (not p) or (not q) ] Call diagnostics (different branches may describe different overloads): • to_dnf requires exactly 1 argument: a boolean expression Extracted library reference: evaluator/builtins.go:16902. These notes are not a complete signature or a stability guarantee.

to_float

Function

to_float(r) - Convert rational to floating point Example: to_float(1/3) → 0.333... Call diagnostics (different branches may describe different overloads): • to_float requires a number • to_float requires exactly 1 argument Extracted library reference: evaluator/builtins.go:17355. These notes are not a complete signature or a stability guarantee.

to_fol

Function

==================================================================================== LOJBAN++ - Phase 3: Predicate Logic Output & Bot Communication ==================================================================================== to_fol(phrase) - Convert Lojban++ phrase to First-Order Logic Call diagnostics (different branches may describe different overloads): • to_fol argument must be a string • to_fol requires exactly 1 argument (phrase) Extracted library reference: evaluator/builtins.go:20589. These notes are not a complete signature or a stability guarantee.

to_json

Function

to_json / from_json — the value↔JSON codec (2026-08-27). PURE (no filesystem): works in the browser build, and the file genre composes as from_json(read(%f.json)) / write(p, to_json(v)). Mapping + refusal rulings: JSON_VALUE_CODEC_DESIGN.md. Extracted library reference: evaluator/builtins.go:14615. These notes are not a complete signature or a stability guarantee. Manual §5.14 Matrices, tensors & dataframes; read with manual "5.14" Excerpt: **JSON** is the value↔string pair `to_json(v [, pretty])` / `from_json(s)` (2026-08-27) — pure functions, so they work in the browser build, and the file genre composes from shipped parts: `from_json(read(%data.json))` and `write(path, to_json(v, true))`.

to_number

Function

toNumberBuiltin: parse a string to a number (Integer if integral, else Float); a number passes through. (Scheme string->number.) Call diagnostics (different branches may describe different overloads): • to_number requires exactly 1 argument Extracted library reference: evaluator/scheme_extras.go:633. These notes are not a complete signature or a stability guarantee. Manual §22.3 Mathematical functions; read with manual "22.3" Excerpt: | `numerator(r)` / `denominator(r)` | Rational accessors; an integer `n` is `n/1` (so `denominator(5)` → `1`) | | `to_number(s)` | Parse a string to a number — Integer if integral, else Float; a number passes through | ### Randomness — `random` / `random_seed` / `shuffle` / `sample`

to_option

Function

toOptionBuiltin: none → Absent; everything else → Some(x). Does not auto-convert Om or Error (those stay wrapped in Some). Call diagnostics (different branches may describe different overloads): • to_option requires exactly 1 argument Extracted library reference: evaluator/builtins.go:2432. These notes are not a complete signature or a stability guarantee. Manual §33.14.1 Bridges — `to_option` / `from_option` / `to_result` / `from_result` / `unwrap_or`; read with manual "33.14.1" Excerpt: #### Bridges — `to_option` / `from_option` / `to_result` / `from_result` / `unwrap_or` Never auto-promote bottoms into ADTs:

to_result

Function

toResultBuiltin: Error → Err(e); everything else → Ok(x). Call diagnostics (different branches may describe different overloads): • to_result requires exactly 1 argument Extracted library reference: evaluator/builtins.go:2465. These notes are not a complete signature or a stability guarantee. Manual §33.14.1 Bridges — `to_option` / `from_option` / `to_result` / `from_result` / `unwrap_or`; read with manual "33.14.1" Excerpt: #### Bridges — `to_option` / `from_option` / `to_result` / `from_result` / `unwrap_or` Never auto-promote bottoms into ADTs:

to_set

Function

to_set(x) — x as a Set, collapsing multiplicity. Extracted library reference: evaluator/builtin_strings.go:669. These notes are not a complete signature or a stability guarantee.

tool_registry

Function

Tool registry + Act guardrails for the agent platform (Aug 2026). tool_registry() → empty Dictionary register_tool(reg, tool, handler) → reg (mutates reg) call_tool(reg, tool, args [, agent]) → Result guard_act(agent, step) → Result Ok(step) | Err(reason) Tool: MkToolId(name) or String. Deontic via permit/forbid + is_permitted / is_forbidden (same action fact strings, e.g. "search()"). Call diagnostics (different branches may describe different overloads): • tool_registry requires 0 arguments Extracted library reference: evaluator/builtin_agent_tools.go:20. These notes are not a complete signature or a stability guarantee. Manual §33.17 Tool registry and Act guardrails; read with manual "33.17" Excerpt: |---|---| | `tool_registry()` | empty mutable registry Dictionary | | `register_tool(reg, tool, handler)` | bind `MkToolId` or string → function | | `call_tool(reg, tool, args [, agent])` | run handler → `Result`; optional agent enforces deontic | | `guard_act(agent, step)` | `Ok(step)` or `Err` for `Act`; other `AgentStep`s pass |

top

Symbol

=== ⊤ (Glyph) === name: verum latex: top category: logic codepoint: U+22A4 meaning: ⊤ — verum (true)

top_k

Function

Call diagnostics (different branches may describe different overloads): • top_k requires exactly 3 arguments: query_vector, items, k Extracted library reference: evaluator/builtin_embeddings.go:38. These notes are not a complete signature or a stability guarantee. Manual §33.16 Embeddings — `cosine` / `top_k` (thin neuro retrieve); read with manual "33.16" Excerpt: ### Embeddings — `cosine` / `top_k` (thin neuro retrieve) Vector similarity for RAG-style **candidate retrieval**. Not a training stack: retrieve → **filter symbolically** → treat hits as `observation(...)`, never as

totient

Function

totient(n)
Computes Euler's totient function φ(n), which counts the positive integers up to n that are relatively prime to n.

Examples

totient(12)   # Returns 4 (1, 5, 7, 11 are coprime)

totient(10)   # Returns 4 (1, 3, 7, 9 are coprime)

trace

Keyword

trace [<domain> ...]   |   trace/<refinement> [<domain> ...]   |   trace [<domain> ...] [ ... ]
Debugging - switches on inline logging for a whole CLASS of operation, with depth-aware indentation. Selection is by domain, not by named function; name several in one statement (`trace func control`) to widen the trace. A typo rejects the WHOLE statement, so a mistyped list never half-applies. Domains: all, binding, comprehension, concepts, control, epistem, func, probabilistic, quantifiers, reasoning, relations, sets, stack, transform. Each also answers to aliases — the epistem domain to the whole grounding ladder and the verbs that write it (axiom, postulate, theorem, conjecture, hypothesis, datum, assert, retract, derive), control to if/while/foreach, func to lambda/closure, and so on. An unrecognized domain is a catchable error naming the recognized set. Refinements: /verbose adds bound variables, condition sources and result types; /debug adds internal state; /step pauses after each operation; /equational (default /reduction) prints a rewrite chain with `==>` for equation-style functions; /calculation is the justified `={ applying f }` form. The domain is optional in BOTH forms: bare means all domains. Session-scoped `trace <domain>` runs until `untrace`; the block form `trace <domain> [ ... ]` traces only its body and RESTORES the previous state on exit, so a forgotten untrace cannot flood the rest of the run and a block nested inside an outer trace leaves that outer domain running. A block is additive (it widens the trace for its extent) and scope-transparent (bindings made inside survive it - switching tracing on never changes what the code does). The transcript survives the block; read it with trace_log(). Note the dual role: in CALL position `trace(m)` is the linear-algebra matrix trace instead.

Examples

trace binding                # watch every value as it is assigned

trace epistem                # assert / axiom / postulate, with the grounding tier

trace control                # log if/while/foreach

trace func control           # several domains in one statement

trace relations              # relation queries + answer counts

trace reasoning              # rule firing, incl. recursive derivation

trace/verbose epistem        # add bound values, sources and types

trace all                    # every domain at once

untrace                      # stop tracing (see: untrace)

trace binding [ total = 7 ]  # scoped: traced here, restored on exit

trace [ x = 1 ]              # scoped, all domains (bare = all)

trace/verbose control [ ... ]  # refinements compose with the block

trace/equational func          # rewrite chain (`==>`); /calculation for `={ applying f }`

trace_log

Function

trace_log()
Reflection - the accumulated trace transcript as an Array of lines, newest last. This is what makes a trace ASSERTABLE: the transcript also goes to stdout, but this reads it back in-language. Lines accumulate only while a trace is active, and SURVIVE `untrace` (you read the log after stopping) - clear with clear_trace_log(). Use str_join(trace_log(), "\n") for the flat form. Shadowable - a user binding of the name wins.

Examples

clear_trace_log()

trace binding

total = 7

untrace

len(trace_log())             # → 1

contains(trace_log()[1], "total = 7")   # → true

traced

Function

traced()   |   traced(domain)
Reflection - reports what `trace` is currently watching. With no arguments returns a sorted Array of the PRIMARY names of the active domains ([] when tracing is off); with a domain name returns a Boolean. An alias reports through to its primary, so `trace lambda` makes traced("func") true. An unrecognized domain is an error, not a quiet false. Named `traced` because `trace` in call position is the linear-algebra matrix trace. Shadowable - a user binding of the name wins.

Examples

traced()                     # → [] or e.g. ["binding", "control"]

traced("control")             # → true / false

trace lambda

traced("func")                # → true — an alias reports its primary

trampoline

Function

Call diagnostics (different branches may describe different overloads): • trampoline requires a value or function • trampoline with a non-callable value takes exactly 1 argument Extracted library reference: evaluator/builtins.go:5197. These notes are not a complete signature or a stability guarantee.

transform

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §19.7.1 The domains; read with manual "19.7.1" Excerpt: | `probabilistic` | probabilistic operations | — | | `transform` | term transformation | — | | `all` | every domain at once (what bare `trace` means) | — | An unrecognized domain is a catchable error naming the recognized set — a typo, a domain that prints nothing, and "the traced operation never ran" would otherwise be indistinguishable.

translate

Function

Call diagnostics (different branches may describe different overloads): • first argument to translate must be a string (code) • second argument to translate must be a string (source language) • third argument to translate must be a string (target language) • translate requires exactly 3 arguments: code, source_language, target_language Extracted library reference: evaluator/builtins.go:16787. These notes are not a complete signature or a stability guarantee. Manual §28.4 28.4 Cross-language translation — `[A -> B | … ]` / `[A --> B | … ]`; read with manual "28.4" Excerpt: **Composable / String-input form: the `translate()` builtin.** When the source code lives in a String variable rather than inline (read from a file, pulled from an API, etc.), use the builtin counterpart:

transpose

Function

Call diagnostics (different branches may describe different overloads): • argument to transpose must be a matrix • transpose requires exactly 1 argument: matrix Extracted library reference: evaluator/builtins.go:13898. These notes are not a complete signature or a stability guarantee. Manual §5.6 Collection method calls; read with manual "5.6" Excerpt: `min`, `max`, `length`, `len`, `size`, `count`, `first`, `last`, `rest`, `nth`, `contains`, `collect`, `elements`, `each`, `transpose`, and `shape`. Builtin domain and mutation rules are unchanged: `m.length()` still refuses a Matrix; use `m.shape()`. Builtin receiver positions come from this registry.

tree

AI Function

tree(root_value, child1, child2, ...)
Creates a tree data structure with specified root and children. Supports both binary and n-ary trees.

Examples

tree(10, 5, 15)                    # Binary tree

tree(1, 2, 3, 4, 5)               # N-ary tree

tree("root", "left", "right")     # String tree

tree_bfs

AI Function

tree_bfs(tree)
Performs breadth-first traversal of a tree, returning array of values in level-order.

Examples

tree_bfs(t)

tree_bfs(tree(10, 5, 15))

tree_dfs

AI Function

tree_dfs(tree)
Performs depth-first traversal of a tree, returning array of values in traversal order.

Examples

tree_dfs(t)

tree_dfs(tree(10, 5, 15))

tree_height

AI Function

tree_height(tree)
Returns the height of a tree (maximum depth from root to leaf).

Examples

tree_height(t)

tree_height(tree(1, 2, 3))

treeform

Function

treeform(expression[, layout])
Returns the AST of an expression as an ASCII tree. Hold semantics — the argument is inspected unevaluated. Optional layout: "vertical" (default) or "horizontal". Sibling: fullform, tableform, graphform.

Examples

treeform(2 + 3)

treeform([1, 2, 3], "horizontal")

treeform(if x then y else z)

triangle

Symbol

=== △ (Glyph) === name: symmetric_difference words: symmetric_difference, symdiff, symmetric difference latex: triangle, ominus variants: ∆ ⊖ category: set codepoint: U+25B3 meaning: A △ B — symmetric difference (members in exactly one set)

triangular

Function

Call diagnostics (different branches may describe different overloads): • center value must be a number • left value must be a number • name must be a string • right value must be a number • triangular requires 4 arguments: name, left, center, right Extracted library reference: evaluator/builtins.go:12978. These notes are not a complete signature or a stability guarantee.

trim

Function

trim(s)
Copy with surrounding whitespace removed. Manual §5.5 Unary dot fallback — `xs.sum ≡ sum(xs) ≡ xs's sum`; read with manual "5.5" Excerpt: {1, 2, 3}.sum # → 6 ; (1..5).sum → 15 "hello".upper # → "HELLO" ; " hi ".trim → "hi" 16.sqrt # → 4 scalars are slot-less, so eligible double: func(x) [x * 2] 7.double # → 14 user functions participate identically

true

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §6.6.1 What counts as true; read with manual "6.6.1" Excerpt: #### What counts as true **Only the bottoms are false.** `false` and `none` are falsy; a typed multi-valued truth value is falsy when its logic does not *designate* it. Every

trunc

Function

trunc(x)
Integer part of x (toward zero) — exact at any magnitude. Manual §4.1.1 Integers don't overflow; read with manual "4.1.1" Excerpt: builtins (`succ`/`pred`, `sum`, `abs`, `divmod`/`quotient`/`remainder`, `floor`/`ceil`/`round`/`trunc`/`int`, `gcd`/`lcm`, `factorial`, …). Consequences of the design:

truncate

Function

truncate(x)
Integer part of x (toward zero) — exact alias of `trunc`. Manual §28.5.1 DDL — `CREATE TABLE`, `DROP TABLE`, `TRUNCATE`; read with manual "28.5.1" Excerpt: #### DDL — `CREATE TABLE`, `DROP TABLE`, `TRUNCATE` ```axioma # CREATE TABLE — declares a new relation

truth

Function

truth(relation, args...)
Returns the Belnap B4 bilattice truth value carried by a stored fact: true (⊤ᵇ), false (⊥ᵇ), both (⊤⊥ᵇ — paraconsistent contradiction), or neither (?ᵇ — information gap). B4 values propagate through rule derivation via lattice meet, so contradictory premises yield contradictory conclusions instead of an error.

Examples

set_truth("parent", "ann", "tim", "both")

truth("parent", "ann", "tim")  # ⊤⊥ᵇ

truth_kind

Function

truth_kind(relation, args...)
Returns the Schopenhauerian truth kind of a fact: "logical", "empirical", "transcendental", "metalogical", or "motive".

Examples

axiom/empirical parent("john", "mary")

truth_kind("parent", "john", "mary")  # "empirical"

truth_table

Function

truth_table(func) | truth_table(func, [var_names])
Generates the full truth table of a Boolean function of 1-10 parameters. Returns a Set of row tuples (input1, ..., inputN, result) — one per assignment, 2^N rows. Compose with set operations or expect() to verify tautologies and equivalences; len(truth_table(f)) is 2^N. To PRINT a formatted grid (including MVL domains), use tableform(f, [domain]) — truth_table is the data, tableform the display.

Examples

truth_table(func(p, q) [p xor q])   # → {(false,false,false), (false,true,true), (true,false,true), (true,true,false)}

truth_table(func(p) [not p])

len(truth_table(func(p, q, r) [(p and q) or r]))  # → 8

try

Keyword

try(expression)  |  try ⏎ body ⏎ [catch e is Kind ⏎ arm]* ⏎ [catch e ⏎ arm] ⏎ [finally ⏎ cleanup] ⏎ end
Captures a propagating error as a first-class Error value (does not unwind). Prefix `try (expr)` is one expression. End-form `try … end` is a statement sequence (newlines, no brackets). RESERVED: `$try` is the name.

Examples

e: try(10 / 0)

println(e.message)

try
    (-3)!
catch e
    42
end

tuck

Function

Call diagnostics (different branches may describe different overloads): • argument to tuck must be a stack • tuck requires 1 argument: stack • tuck requires at least 2 items on stack Extracted library reference: evaluator/builtins.go:12203. These notes are not a complete signature or a stability guarantee. Manual §18.2 Stack-shuffle operations; read with manual "18.2" Excerpt: | `nip(s)` | `a b → b` | Drop second | | `tuck(s)` | `a b → b a b` | Copy top below second | | `pick(s, i)` | `→ … x` | Copy the element at index `i` (0 = top) to the top | | `roll(s, i)` | `→ … x` | Move the element at index `i` to the top |

tuple

Function

tuple([collection])
With no argument, the empty tuple. With one argument, materializes an array, set, or finite range as a fixed-arity, immutable Tuple. A Set is walked in its CANONICAL order, the same guarantee array(s) gives; a Range keeps source order; a Tuple is returned unchanged. Added July 2026 — before it, a Tuple could only be written as the (a, b) literal and never built from computed data. Note make_tuple is a different facility: it builds an AST node, not a value.

Examples

tuple()              # () — the empty tuple

tuple([1, 2, 3])     # (1, 2, 3) — from an Array

tuple({3, 1, 2})     # (1, 2, 3) — canonical order

tuple(1..4)          # (1, 2, 3, 4)

tuple?

Function

Call diagnostics (different branches may describe different overloads): • tuple? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

turtle

Function

Call diagnostics (different branches may describe different overloads): • turtle() takes no arguments Extracted library reference: evaluator/builtin_turtle.go:73. These notes are not a complete signature or a stability guarantee. Manual §13.37 Hidden slots, scanners, turtles, and concatenative extras; read with manual "13.37" Excerpt: ```axioma t: turtle() repeat 4 [ t forward 100 t right 90

turtle_back

Function

Call diagnostics (different branches may describe different overloads): • turtle_back distance must be a number Extracted library reference: evaluator/builtin_turtle.go:94. These notes are not a complete signature or a stability guarantee.

turtle_forward

Function

Call diagnostics (different branches may describe different overloads): • turtle_forward distance must be a number Extracted library reference: evaluator/builtin_turtle.go:79. These notes are not a complete signature or a stability guarantee.

turtle_left

Function

Call diagnostics (different branches may describe different overloads): • turtle_left degrees must be a number Extracted library reference: evaluator/builtin_turtle.go:124. These notes are not a complete signature or a stability guarantee.

turtle_pendown

Function

turtle_pendown(turtle)
Lower a Turtle's pen so subsequent movement draws. Mutates the turtle and returns it.

turtle_penup

Function

turtle_penup(turtle)
Lift a Turtle's pen so subsequent movement does not draw. Mutates the turtle and returns it.

turtle_right

Function

Call diagnostics (different branches may describe different overloads): • turtle_right degrees must be a number Extracted library reference: evaluator/builtin_turtle.go:109. These notes are not a complete signature or a stability guarantee.

turtle_svg

Function

Extracted library reference: evaluator/builtin_turtle.go:161. These notes are not a complete signature or a stability guarantee. Manual §13.37 Hidden slots, scanners, turtles, and concatenative extras; read with manual "13.37" Excerpt: ] turtle_svg(t) ``` **Generators.** `generate [ yield 1; yield 2 ]` is an eager collect: the

twodrop

Function

Call diagnostics (different branches may describe different overloads): • 2drop requires 1 argument: stack • 2drop requires at least 2 items on stack • argument to 2drop must be a stack Extracted library reference: evaluator/builtins.go:12476. These notes are not a complete signature or a stability guarantee.

twodup

Function

Double-cell operations for pairs Call diagnostics (different branches may describe different overloads): • 2dup requires 1 argument: stack • 2dup requires at least 2 items on stack • argument to 2dup must be a stack Extracted library reference: evaluator/builtins.go:12446. These notes are not a complete signature or a stability guarantee.

twoover

Function

Call diagnostics (different branches may describe different overloads): • 2over requires 1 argument: stack • 2over requires at least 4 items on stack • argument to 2over must be a stack Extracted library reference: evaluator/builtins.go:12529. These notes are not a complete signature or a stability guarantee.

twoswap

Function

Call diagnostics (different branches may describe different overloads): • 2swap requires 1 argument: stack • 2swap requires at least 4 items on stack • argument to 2swap must be a stack Extracted library reference: evaluator/builtins.go:12498. These notes are not a complete signature or a stability guarantee.

type

Function

type Name = kind-or-type-expression | type(expression)
In a declaration, `type Name =` accepts a type expression or struct (record is an alias), schema, variant (or data, the same declaration), enum, or concept. struct remains primary; struct and record are nominal, not Dictionary schemas, and immutable by default. mut or mutable after either word selects the same closed checked fields with reference identity. Both spellings reuse the existing struct AST, generic parameters, brace/end bodies and VM refusal. No standalone struct or record declaration. Struct/schema bodies may close with end; concept end bodies explicitly open with with. Existing short declarations remain valid. As a call, returns the DataType Concept of a value (Integer, Tuple, …), not a TitleCase string. Same answer as prefix `:: expr` and `@expr`. Compare with `== Integer`; `5 is Integer` is membership. For a function's written arrow use annotations(f); for the body reading use inferred(f); for the callable shape use signature(f).

Examples

type(42)

:: 42

type("hello")

type([1, 2, 3])

Types

Concept

Integer | Float | String | Boolean | Array | Tuple | Set | Object
Built-in data types in Axioma

Examples

42              # Integer

3.14            # Float

"hello"         # String

true            # Boolean

[1, 2, 3]       # Array

(1, "a", true)  # Tuple

{1, 2, 3}       # Set

typicality

Function

typicality(concept)
Measures how prototypical/typical a concept is within its category. Higher values indicate better prototypes.

Examples

typicality(Dog)             # ~0.44 (good prototype)

typicality(Animal)          # ~0.09 (abstract, low)

typicality(Robin)           # ~0.44 (typical bird)

typical: typicality(Vehicle)  # Measure prototypicality

typically

Keyword

typically head(Args) whenever body | typically head(Args) if body | subject typically predicate (default-logic infix)
At statement start: the natural-language DEFEASIBLE rule marker — `typically flies(X) whenever bird(X)` ≡ `rule~ flies(X) if bird(X)` ≡ `flies(X) <~~ bird(X)` (Reiter's own gloss: "birds typically fly"). Derived facts land on the conjecture grounding tier, so cancel / why / @conjecture apply. `normally` is the synonym twin. A strict operator under the marker (`typically H :- B`) is a loud parse error. In INFIX position the word keeps its separate default-logic reading (`birds typically fly` — the extensions engine).

Examples

typically flies(X) whenever bird(X)   # defeasible rule → conjecture

normally sings(X) if bird(X)          # synonym twin

typically chirps(X) <~~ bird(X)       # idempotent with the operator

cancel("flies", "penguin_pete")       # conjectures are cancelable

ultimate_referent

Function

Referent chain following (Fregean reference resolution) Call diagnostics (different branches may describe different overloads): • ultimate_referent() requires exactly 1 argument Extracted library reference: evaluator/builtins.go:5703. These notes are not a complete signature or a stability guarantee.

unalias

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §19.11 Aliasing the vocabulary — `alias` / `unalias`; read with manual "19.11" Excerpt: ### Aliasing the vocabulary — `alias` / `unalias` `alias new = target` gives an existing spelling a second name; `unalias new` withdraws it. One statement covers four kinds of target:

uncancel

Function

uncancel(relation, args...)
Removes a cancel() marker, restoring the defeated fact to query results.

Examples

uncancel("flies", "pingu")

uncurry

Function

uncurry(f, args)
Apply f to an array of arguments one at a time: uncurry(f, [a, b]) is f(a)(b).

unfold

Function

unfold(fn, seed)
Anamorphism (dual of reduce): fn(seed) → Some((value, next_seed)) to continue or None to stop. Evaluator-only. Manual §12.18 List-library verbs (Haskell / OCaml); read with manual "12.18" Excerpt: The nine verbs above `unfold` work under `--vm` (byte-identical). **`unfold` is evaluator-only**: its step function builds `Some`/`Absent`, which are ADT constructors the VM does not compile, so an `unfold` under `--vm` is rejected at compile time rather than run.

unfreeze

Keyword

ConceptName unfreeze
Synonym for 'unsuspend' - reactivates a suspended concept

Examples

Person unfreeze

Stock unfreeze

uniform

Function

Call diagnostics (different branches may describe different overloads): • a must be a number • b must be a number • uniform requires 2 arguments: a, b Extracted library reference: evaluator/builtins.go:11557. These notes are not a complete signature or a stability guarantee. Manual §22.4 Randomness — `random` / `random_seed` / `shuffle` / `sample`; read with manual "22.4" Excerpt: distributions join the seed contract. When a distribution earns a native home, it lands in `prob`'s seedable source (the `normal`/`uniform`/ `binomial`/`beta` path) precisely so it does. ### Formatted output — `printf` / `stringf` / `format`

unify

Function

unify(term1, term2)
Performs first-order unification between two terms using the Robinson algorithm. Returns unification result with substitutions.

Examples

unify(add(X, 3), add(2, Y))  # Returns substitution {X→2, Y→3}

unify(f(a), f(b))            # Returns failure

unify(X, 5)                  # Returns {X→5}

union

Operator

set1 union set2
Set union operator

Examples

{1, 2} union {2, 3}

evens union odds

unique

Function

unique(collection)
Deduplicate, preserving first-seen order. unique! is the in-place twin. Manual §4.8 Ranges — ordered `a..b`, exclusive `..<`, `by` step, open `n..`; read with manual "4.8" Excerpt: indexing `r[2]` (negative counts from the end), slicing `r[2:4]`, `reverse`, `contains`, `count`, `index_of`, `unique`, `rest`, and `[h | t]` destructuring. Every one of them answers exactly what it answers for `array(r)`. Writing is not in the surface — `push` on a Range is an error, by design. An **open** range answers where arithmetic can (`(1..)[4]`,

unique!

Function

unique!(array)
Drops later duplicates of an Array in place, keeping first-seen order, and returns it. Aliases see the write. `unique(collection)` is the copy.

Examples

xs: [3, 1, 3, 2]; unique!(xs)   # xs is now [3, 1, 2]

unit

Keyword

unit NAME  |  unit NAME = quantity
Declares a unit of measure. Bare `unit share` creates a custom dimension of magnitude 1. `unit g = kg / 1000` names an already-computed quantity (same dimension, new display). Soft keyword: `unit: 5` still binds the name. Short SI letters (m, s, A) are not seeded — write `unit m = metre` or use `metre` / `second` / `ampere`. Money (`$5`) is not a unit.

Examples

unit share

unit m = metre

unit g = kg / 1000

5 * kg + 500 * gram     # same dimension

universally

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §12.15 Function composition; read with manual "12.15" Excerpt: **Why two directions.** On functions, `f ∘ g` universally means "apply `g` first" — a language that reversed the glyph would be wrong to every reader who learned it from a textbook. `compose` cannot follow the glyph, because it *also* composes relations, and a function is its graph: `compose(R, S)` is

universe

Function

universe(set) - Define universal set for complement operations Stores the universal set in the environment under special key "__UNIVERSE__" Required before using complement() function Example: universe({1, 2, 3, 4, 5}) Call diagnostics (different branches may describe different overloads): • universe() requires exactly 1 argument Extracted library reference: evaluator/builtins.go:8136. These notes are not a complete signature or a stability guarantee. Manual §22.2 Set constants; read with manual "22.2" Excerpt: | `complexes` | ℂ — lazy infinite set, membership-only (glyph `ℂ`) | | `universe` | Universal set for demos | ### Mathematical functions

unpack

Function

unpackBuiltin implements unpack(spec, bytes) — reads values out of the Bytes value following the format spec, returns them as a Tuple. The input must be exactly the size required by the format (no trailing bytes — use `@rest`-style extension in a future revision if needed). Call diagnostics (different branches may describe different overloads): • unpack requires exactly 2 arguments (format spec, Bytes) Extracted library reference: evaluator/builtin_pack.go:179. These notes are not a complete signature or a stability guarantee. Manual §4.6.7 Binary serialization — `pack` / `unpack`; read with manual "4.6.7" Excerpt: #### Binary serialization — `pack` / `unpack` Python-`struct`-style format strings. `pack` serializes values into `Bytes`; `unpack` reads `Bytes` back into a `Tuple` of typed values. The format spec is small enough to memorize:

unquote

Keyword

unquote(expression)
Evaluates the expression inside a `quasiquote` context and embeds the result into the surrounding AST.

Examples

macro double(x) quasiquote(unquote(x) * 2)

unquote_splice

Keyword

unquote_splice …
Alternative spelling of splice. See doc("splice") for its meaning and call forms.

unreachable_clauses

Function

Extracted library reference: evaluator/confluence.go:1150. These notes are not a complete signature or a stability guarantee. Manual §33.13 Confluence — does the clause ORDER matter?; read with manual "33.13" Excerpt: redundancy at compile time and deliberately stops at multi-slot constructor patterns and variadic clauses. `unreachable_clauses` is the runtime, full-pattern counterpart: it sees literals, tuples, arrays, hashes and every slot at once, and it answers about a function value rather than about source.

unshift

Function

unshift(array, value)  |  a unshift value
Inserts a value at the front of an Array in place and returns the array. `push` is the tail twin. `unshift(a, v)` is the same surgery as `insert_at(a, 1, v)`. Julia writes `unshift!`.

Examples

a: [2, 3]

unshift(a, 1)  # a is now [1, 2, 3]

a unshift 0    # message form

unsuspend

Keyword

ConceptName unsuspend | ConceptName unfreeze
Reactivates a suspended concept, making it available again

Examples

Person unsuspend

Stock unfreeze

Vehicle unsuspend

until

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §6.8 End-form blocks — `if`, `while`, `for`, `loop`, `repeat`, `function`, `module` … `end`; read with manual "6.8" Excerpt: repeat # post-test dual of `repeat [body] until cond` n: n + 1 # later-line `until` closes the body; `end` until n >= 3 # closes the block. Same-line `p until q` in end # the body stays the LTL operator.

untrace

Keyword

untrace   |   untrace <domain> ...
Debugging - switches off tracing started by `trace`. Bare `untrace` clears every domain and resets the refinements; `untrace <domain>` clears just that one, and several may be named at once (`untrace func control`), mirroring `trace`. An unrecognized domain is a catchable error - silently leaving tracing ON is the more surprising direction. The trace transcript SURVIVES untrace, so trace_log() still reads it afterwards; clear it with clear_trace_log(). Not needed after a `trace <domain> [ ... ]` block, which restores the previous state itself.

Examples

untrace                      # clear all tracing

untrace control              # clear just the control domain

untrace func control         # clear several at once

trace_log()                  # the transcript, still readable after untrace

unwrap_or

Function

unwrapOrBuiltin(wrapper, default): Some/Ok/Right → payload; Absent/Err/Left → default. Also accepts a bare none as "empty" → default (bridge convenience). Call diagnostics (different branches may describe different overloads): • unwrap_or requires exactly 2 arguments (wrapper, default) Extracted library reference: evaluator/builtins.go:2499. These notes are not a complete signature or a stability guarantee. Manual §33.14.1 Bridges — `to_option` / `from_option` / `to_result` / `from_result` / `unwrap_or`; read with manual "33.14.1" Excerpt: #### Bridges — `to_option` / `from_option` / `to_result` / `from_result` / `unwrap_or` Never auto-promote bottoms into ADTs:

unzip

Function

unzip(rows)
The inverse of zip: an array (or tuple) of equal-width rows becomes a tuple of columns, so unzip(zip(a, b)) is (a, b). n-ary — a 3-wide row gives 3 columns, with no separate unzip3 spelling — and rows may be tuples or arrays. Destructure the result with a tuple target: ints, strs: unzip(pairs). The width is read from the rows, never assumed: unzip([]) is the empty tuple () rather than an invented ([], []), and rows of differing widths are rejected. A Set operand is rejected for the same reason zip rejects one — it has no order to read positions from.

Examples

unzip([(1, "one"), (2, "two")])   # Returns ([1, 2], ["one", "two"])

ints, strs: unzip(pairs)            # binds both columns at once

unzip([(1, "a", true), (2, "b", false)])  # 3 columns out of 3-wide rows

unzip([])                           # () — no rows, so no width to report

upper

Function

upper(s)
Uppercase copy. A Character in, a Character out. Manual §4.5.6 Case mapping — `upper` / `lower` / `title` (and Julia aliases); read with manual "4.5.6" Excerpt: #### Case mapping — `upper` / `lower` / `title` (and Julia aliases) ```axioma upper("Hello") # → "HELLO"

upper?

Function

charPredicate wraps a rune classifier as a builtin accepting a Character or a one-character String. Call diagnostics (different branches may describe different overloads): • upper? requires exactly 1 argument Extracted library reference: evaluator/character.go:81. These notes are not a complete signature or a stability guarantee.

uppercase

Function

uppercase(s)
Julia spelling of upper. Same function, same answers. Manual §4.5.6 Case mapping — `upper` / `lower` / `title` (and Julia aliases); read with manual "4.5.6" Excerpt: `uppercase` / `lowercase` / `titlecase` are aliases of `upper` / `lower` / `title`. A Character in is a Character out (`uppercase('a')` is `'A'`). `uppercasefirst` is not `capitalize` (Julia leaves the rest of the string alone) and is not shipped.

url

Function

url(string)
A string to a URL; rejects anything without a scheme://. Manual §1.2 Influences; read with manual "1.2" Excerpt: - **REBOL** — the `:` value binding, the family of scalar value literals (URL, email, file, money, pair, issue, …), the get-word (`:w`), refinements (`name/ref`), and the value-returning (non-throwing) error model. - **Forth / Pop-11** — the stack model: the global interpreter stack, the postfix sequence notation, and the stack-shuffle verbs.

url?

Function

Call diagnostics (different branches may describe different overloads): • url? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1621. These notes are not a complete signature or a stability guarantee.

use

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §28.12 27.4 When to use what; read with manual "28.12" Excerpt: ### 27.4 When to use what | Use | Tool | |---|---|

val

Keyword

val NAME [:: Type] [= value]
A second spelling of `let` (the Scala / Kotlin / Standard ML word for an immutable binding), including bare `val x` or `val x :: T` for a one-fill hole, desugaring to the identical node: fresh cell, shadowing, and a write-refusal on the cell. NOT a spelling of `var` — `var` is the mutable twin. `let` stays canonical. The PATTERN form is `let` only: `val (x, n) = pair` is not a destructuring binding, because `val(...)` is already a call. RESERVED word, like let and var: `val: 100` and `val()` are SyntaxErrors — guard as `$val`.

Examples

val x = 5

val d :: Date = today()

val x = 5
x: 6   # ERROR: `val` bindings are immutable — use `var`

valid_syllogism

Function

valid_syllogism(premise1, premise2, conclusion [, "aristotelian"|"boolean"])
Decides the VALIDITY of a categorical syllogism — true in every model, checked by enumerating all 256 region-models over the three terms. Arguments are categorical propositions read schematically (terms are never resolved; validity is about form). Bare copula premises are accepted with Leibniz's quantity reduction (DAC 1666): `socrates is M` (singular subject) counts as universal, `human is M` (species subject) as particular. Returns {valid, mood, name, figure, reading, counterexample}: the traditional mood classification (Barbara, Celarent, ...) and a countermodel when invalid. Default reading is Aristotelian (every term denotes — 24 valid moods); "boolean" gives the modern reading (15).

Examples

valid_syllogism(every M is P, every S is M, every S is P)   # Barbara, valid

valid_syllogism(every P is M, every S is M, every S is P)   # invalid — undistributed middle

valid_syllogism(every M is P, every M is S, some S is P, "boolean")   # Darapti fails without import

validate

Function

validate object [against axiom]
Validates an object against axioms. Can check against specific axiom or all applicable axioms.

Examples

validate account

validate person against PositiveAge

validate transaction against ConservationOfMass

validate_grammar

Function

validate_grammar() - Validate constrained language grammar Usage: validate_grammar(stmt) returns boolean Call diagnostics (different branches may describe different overloads): • validate_grammar requires 1 argument Extracted library reference: evaluator/builtin_constrained_language.go:226. These notes are not a complete signature or a stability guarantee.

validate_porphyry

Function

validate_porphyry() - Validates the Porphyry tree with all test cases Example: validate_porphyry() → true/false Call diagnostics (different branches may describe different overloads): • validate_porphyry requires 0 arguments Extracted library reference: evaluator/builtins.go:20069. These notes are not a complete signature or a stability guarantee.

value_indifferent

Function

value_indifferent(relation, args..., authority)
The axiological (value) axis: judges a fact to be INDIFFERENT — positively neither-good-nor-bad (the Stoic adiaphoron), as distinct from "neutral" which means no value judgment was ever made. Siblings value_good / value_bad take the same shape. The judging authority is an agent(...).

Examples

stoic: agent("epictetus", "Stoic")

value_indifferent("wealth", "croesus", stoic)

value_kind_of("wealth", "croesus")  # "indifferent"

value_kind_of

Function

value_kind_of(relation, args...)
Returns the value stance attached to a fact: "good", "bad", "indifferent" (an explicit judgment), or "neutral" (silence — never valued at all). Use facts_by_value_kind(kind) to enumerate by stance.

Examples

value_kind_of("wealth", "croesus")

facts_by_value_kind("indifferent")

values

Function

values(hash)
Values of a Dictionary, in sorted-key order. Manual §7.14 Aggregation: `group_by`, `items`, `keys`, `values`; read with manual "7.14" Excerpt: ### Aggregation: `group_by`, `items`, `keys`, `values` Four builtins fill the SQL-style aggregation gap. `group_by(fn, coll)` partitions a collection into a hash; `items(hash)` exposes it as `(key, value)` pairs; `keys`/`values` return the parts individually. All three enumerators walk the hash in **sorted key order** — the same canonical order `println(h)` shows — so repeated calls (and `keys`/`values`/`items` against each other) always agree.

var

Keyword

var NAME [:: Type] [= value]
Declares a FRESH, MUTABLE binding — exactly `let` minus the write-refusal. For the rare case that must shadow an outer name AND mutate the shadow; plain `x: 5` remains the mutable workhorse (accumulators never involve let/var). Same grammar as let throughout: patterns, `::` annotations, multi-target. Second spellings: `local`, `let mut` (Rust) and `let mutable` (F#). Bare `var x` and `var x :: T` alias their explicit `= _` forms; each name independently chooses an annotation. An unannotated cell may change value type after its first fill. Untyped holes explicitly refuse under --vm. RESERVED word; `var(...)` as a call now points at `variance`.

Examples

var counter = 0
counter: counter + 1

let mut counter = 0
counter: counter + 1

var (x, n) = pair

var slot :: Integer = _   # refillable typed hole

variance

Function

Call diagnostics (different branches may describe different overloads): • ddof must be an integer • first argument must be an array or matrix • variance requires 1 or 2 arguments: data [, ddof] Extracted library reference: evaluator/builtins.go:14115. These notes are not a complete signature or a stability guarantee. Manual §28.8.1 Style 1 — pure Axioma; read with manual "28.8.1" Excerpt: mean: sum(xs) / n variance: sum([(x - mean) * (x - mean) | x <- xs]) / n sigma: math.sqrt(float(variance)) # `/` is exact: float() before sqrt outliers: [x | x <- xs, x > mean + sigma] println("mean=", mean, "sigma=", sigma, "outliers=", outliers)

variant

Declaration

type Shape = variant Circle(radius:: Float) | Origin
Family spelling of a tagged data declaration. Constructor and match semantics are unchanged; existing data Shape = ... remains valid, and data is also accepted in this slot: type Shape = data ... is the same declaration. Alternatives can continue on lines beginning with |. No end required. Evaluator-only.

varnothing

Symbol

=== ∅ (Glyph) === name: emptyset words: emptyset, empty_set latex: emptyset, varnothing category: constant codepoint: U+2205 meaning: ∅ — the empty set

varphi

Symbol

=== φ (Glyph) === name: phi words: PHI latex: phi, varphi category: constant codepoint: U+03C6 meaning: φ — the golden ratio (1.61803…)

vee

Symbol

=== ∨ (Glyph) === name: or words: or latex: vee, lor category: logic codepoint: U+2228 meaning: p ∨ q — logical disjunction (canonicalizes to the `or` operator; MVL-dispatched)

veebar

Symbol

=== ⊻ (Glyph) === name: xor words: xor latex: veebar, xor category: logic codepoint: U+22BB meaning: p ⊻ q — exclusive or (canonicalizes to the `xor` operator; MVL-dispatched)

venn

Function

venn(set1, set2[, set3])
Generates a Venn diagram for 2 or 3 sets

Examples

venn({1, 2, 3}, {2, 3, 4})

venn(A, B, C)

verum

Symbol

=== ⊤ (Glyph) === name: verum latex: top category: logic codepoint: U+22A4 meaning: ⊤ — verum (true)

visualize_2d

Function

==================================================================================== CONCEPTUAL SPACES - Visualization System ==================================================================================== Provides visualization capabilities for conceptual spaces: - ASCII 2D/3D projections - Graphviz DOT format generation - Hooks for external visualization tools visualize_2d(space, dim1, dim2, [options]) - Create ASCII 2D visualization Extracted library reference: evaluator/builtin_conceptual_viz.go:22. These notes are not a complete signature or a stability guarantee.

visualize_ascii_3d

Function

visualize_ascii_3d(space, dim1, dim2, dim3, [options]) - ASCII 3D projection Extracted library reference: evaluator/builtin_conceptual_viz.go:112. These notes are not a complete signature or a stability guarantee.

visualize_graph

Function

============================================== VISUALIZATION BUILT-IN FUNCTIONS ============================================== Visualize graph with default settings Call diagnostics (different branches may describe different overloads): • first argument must be a graph • visualize_graph requires 1-2 arguments: graph [, layout] Extracted library reference: evaluator/builtins.go:9118. These notes are not a complete signature or a stability guarantee.

visualize_graphviz

Function

visualize_graphviz(space, [options]) - Generate Graphviz DOT format Extracted library reference: evaluator/builtin_conceptual_viz.go:78. These notes are not a complete signature or a stability guarantee.

visualize_semantic_network

Function

visualize_semantic_network(network [, layout])
Creates a visual representation of the semantic network using graph layout algorithms

Examples

visualize_semantic_network(net)

visualize_semantic_network(net, "force_directed")

visualize_semantic_network(net, "circular")

visualize_space

Function

visualize_space(space, [options]) - Create visualization Extracted library reference: evaluator/builtin_conceptual.go:707. These notes are not a complete signature or a stability guarantee.

visualize_tree

Function

Visualize tree with default settings Call diagnostics (different branches may describe different overloads): • first argument must be a tree • visualize_tree requires 1-2 arguments: tree [, layout] Extracted library reference: evaluator/builtins.go:9147. These notes are not a complete signature or a stability guarantee.

vo

Keyword

Lojban-inspired exact-count quantifier: exactly four members of the explicit domain.

vocab_lookup

Function

vocab_lookup() - Look up a word in the vocabulary registry Usage: vocab_lookup("loves") returns word entry details as dict Call diagnostics (different branches may describe different overloads): • vocab_lookup requires 1 argument Extracted library reference: evaluator/builtin_constrained_language.go:94. These notes are not a complete signature or a stability guarantee.

wait

Function

wait() | wait(seconds)
With no argument, wait for Enter on standard input. With one nonnegative Integer or Float, sleep for that number of seconds. Returns none. The interactive form requires input; do not use it in an unattended script.

warbler

Function

warbler(f, x)
The Warbler (W), curried: warbler(f)(x) is f(x)(x) — duplicates one argument into a binary function.

wedge

Symbol

=== ∧ (Glyph) === name: and words: and latex: wedge, land category: logic codepoint: U+2227 meaning: p ∧ q — logical conjunction (canonicalizes to the `and` operator; MVL-dispatched)

what

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §5.1.1 What a bracket means, by position; read with manual "5.1.1" Excerpt: #### What a bracket means, by position A **body** is a statement sequence; a **branch** and a **value binding** are expression positions. They agree except on a bare comma run, which reduces as

when

Keyword

f(args) when step, step = result | match value with | pattern when step, step => result
An ordered guard sequence. An expression uses Axioma truthiness; pattern <- expression matches one evaluated value; let name = expression introduces a fresh immutable branch-local binding. Commas sequence steps left to right. New names are visible in later steps and the branch body. Falsey conditions and pattern mismatches try the next clause; errors propagate. The first success commits its body, even if that body returns none or errors. Effects are not rolled back. A single expression guard keeps its existing semantics; otherwise means when true, and the existing result-first form f(n) = body, if cond (or , otherwise) remains. No eligible clause at a supported arity returns none. Function clauses also accept one head followed by aligned indented lines | guard = result; external branches start new lines, nested unbracketed arms indent deeper, parentheses and bracket bodies delimit independent nested expressions. Keep the first result token on the = line. Detached signatures and refinements are preserved. Evaluator-only: VM refuses. See manual "Guard sequences and pipe clauses".

Examples

double_small(x) when let y = 2*x, y < 100 = y
double_small(x) otherwise = 0
println(double_small(3))

sign(n)
  | n > 0 = 1
  | n < 0 = -1
  | otherwise = 0
println(sign(-2))

whenever

Keyword

head(Args) whenever body | rule head(Args) whenever body | rule~ head(Args) whenever body | typically head(Args) whenever body
The PRIMARY natural-language rule operator: `path(X, Y) whenever edge(X, Y)` ≡ `path(X, Y) :- edge(X, Y)`. English "whenever" = "in every case where" — the universal conditional, exactly a Horn clause's ∀-bound head. A soft keyword (whenever: 5 still binds) with no conditional reading, so unlike postfix `if` it needs no uppercase-logic-var gate: ground heads work bare (`mortal("socrates") whenever human("socrates")`). Strict rules derive theorems; prefix `typically`/`normally` (≡ rule~) makes the clause defeasible, deriving conjectures. Rules are evaluator-only (no --vm).

Examples

path(X, Y) whenever edge(X, Y)

path(X, Y) whenever edge(X, Z) and path(Z, Y)   # recursive — fixpoint engine

mortal("socrates") whenever human("socrates")   # ground head, no prefix needed

typically flies(X) whenever bird(X)             # defeasible ≡ flies(X) <~~ bird(X)

rule~ hops(X) whenever bird(X)                  # marker spelling, same meaning

where

Keyword

where NAME: value   (statement-initial, inside a body)
Opens the BINDING SECTION of a body: everything after it, to the end of the enclosing body, defines the names the result above uses. Written last, evaluated first, so a definition can lead with its conclusion. Bindings are local to the body and shadow outer names; each may use the ones above it, and two function-valued bindings may refer to each other. Mid-expression, `where` keeps its other senses: the intensional class (`the Integer where p`) and the quantifier condition (`ro x where p`). Position is the discriminator. A bracketed body's `]` closes the section; a BRACKETLESS equation has no closer, so its section ends at the LINE — spread the body over lines by bracketing it. Writing the section across lines without brackets is diagnosed, not silently misread.

Examples

calcChange(owed, paid) = [ if change > 0 then change else 0
                           where change: paid - owed ]

f: func(x) [ y * y  where y: x + 1 ]

qsort([x|xs]) = [ qsort(smaller) + [x] + qsort(larger)
                  where
                    smaller: [a | a <- xs, a <= x]
                    larger:  [b | b <- xs, b >  x] ]

oneLine(owed, paid) = if change > 0 then change else 0 where change: paid - owed

while

Keyword

while condition [ body ] | while condition
  body
end
Test the condition before each iteration and execute the body while it is true. The body may run zero times. Available in the beginner subset as well as the full language. Brackets and end terminate equivalent bodies.

Examples

n: 0
while n < 3
  n = n + 1
end
println(n)

why

Keyword

why conclusion_expression
Explanation system - explains WHY a conclusion is true by showing the reasoning chain and rule applications.

Examples

why mortal("socrates")       # Explain justification

why qualified("alice")       # Show reasoning chain

why diagnosis("patient1")    # Medical diagnosis explanation

with

Keyword

Reserved syntax word. Its meaning depends on the enclosing form; it is not a function call. Manual §28.5.7 Common Table Expressions — `WITH`; read with manual "28.5.7" Excerpt: #### Common Table Expressions — `WITH` ```axioma # Single CTE

with_probability

Keyword

Probability qualifier on an expression in the probabilistic interface. Supply the probability explicitly; it is not computed from an author's wording.

word

Keyword

name: word [ value: str, semantic_primes: [...], cd: ACT ]
Declares a cognitive word with Wierzbicka's semantic primes and Schank's Conceptual Dependency (CD) act.

Examples

give: word [ value: "transfer", semantic_primes: [SOMEONE, DO], cd: ATRANS ]

word?

Function

Call diagnostics (different branches may describe different overloads): • word? requires exactly 1 argument Extracted library reference: evaluator/builtins.go:1633. These notes are not a complete signature or a stability guarantee.

word_do

Function

Call diagnostics (different branches may describe different overloads): • word_do requires at least 1 argument: word Extracted library reference: evaluator/builtin_words.go:69. These notes are not a complete signature or a stability guarantee.

word_doc

Function

word_doc(word)
Return the cognitive word's attached documentation as a String; an undocumented word returns an empty string.

word_effect

Function

Extracted library reference: evaluator/builtin_word_effect.go:60. These notes are not a complete signature or a stability guarantee. Manual §13.37 Hidden slots, scanners, turtles, and concatenative extras; read with manual "13.37" Excerpt: Forth extras: `stack_dip` / `stack_keep` / `stack_cleave`; word `effect: "( n -- n^2 )"` with `word_effect` / `check_effect`; return stack `rpush` / `rpop` / `rpeek` / `rdepth` / `rclear`. `#language axioma/rpn` is additive (infix still runs). Textbook: HtDKP-in-Axioma Chapter 41. Logo selectors: `butfirst`,

word_semantics

Function

word_semantics(word)
Return a dictionary of the cognitive word's semantic slots, such as roles, semantic primes and operations. This inspects attached metadata; it does not infer that the description is true.

word_slot

Function

Call diagnostics (different branches may describe different overloads): • word_slot requires 2 arguments: word, slot Extracted library reference: evaluator/builtin_words.go:35. These notes are not a complete signature or a stability guarantee.

word_slots

Function

word_slots(word)
Return the sorted slot names of a cognitive word as an Array of Strings.

wordnet_antonyms

Function

wordnet_antonyms(word) - Get antonyms for a word Call diagnostics (different branches may describe different overloads): • wordnet_antonyms argument must be a string • wordnet_antonyms requires exactly 1 argument (word) Extracted library reference: evaluator/builtins.go:20842. These notes are not a complete signature or a stability guarantee.

wordnet_definition

Function

wordnet_definition(word) - Get first definition for a word Call diagnostics (different branches may describe different overloads): • wordnet_definition argument must be a string • wordnet_definition requires exactly 1 argument (word) Extracted library reference: evaluator/builtins.go:20719. These notes are not a complete signature or a stability guarantee.

wordnet_definitions

Function

wordnet_definitions(word) - Get all definitions for a word Call diagnostics (different branches may describe different overloads): • wordnet_definitions argument must be a string • wordnet_definitions requires exactly 1 argument (word) Extracted library reference: evaluator/builtins.go:20740. These notes are not a complete signature or a stability guarantee.

wordnet_hypernyms

Function

wordnet_hypernyms(word, [depth]) - Get hypernyms (more general terms) Call diagnostics (different branches may describe different overloads): • wordnet_hypernyms first argument must be a string • wordnet_hypernyms requires 1-2 arguments (word, [depth]) • wordnet_hypernyms second argument (depth) must be an integer Extracted library reference: evaluator/builtins.go:20782. These notes are not a complete signature or a stability guarantee.

wordnet_hyponyms

Function

wordnet_hyponyms(word, [depth]) - Get hyponyms (more specific terms) Call diagnostics (different branches may describe different overloads): • wordnet_hyponyms first argument must be a string • wordnet_hyponyms requires 1-2 arguments (word, [depth]) • wordnet_hyponyms second argument (depth) must be an integer Extracted library reference: evaluator/builtins.go:20812. These notes are not a complete signature or a stability guarantee.

wordnet_synonyms

Function

wordnet_synonyms(word) - Get all synonyms for a word Call diagnostics (different branches may describe different overloads): • wordnet_synonyms argument must be a string • wordnet_synonyms requires exactly 1 argument (word) Extracted library reference: evaluator/builtins.go:20761. These notes are not a complete signature or a stability guarantee.

wordnet_synsets

Function

==================================================================================== WORDNET INTEGRATION - Lexical Database Access ==================================================================================== wordnet_synsets(word, [pos]) - Get all synsets for a word Call diagnostics (different branches may describe different overloads): • wordnet_synsets first argument must be a string • wordnet_synsets requires 1-2 arguments (word, [pos]) • wordnet_synsets second argument (pos) must be a string Extracted library reference: evaluator/builtins.go:20658. These notes are not a complete signature or a stability guarantee.

words_of

Function

words_of() - Extract words from constrained language literal Usage: words_of(stmt) returns array of words Call diagnostics (different branches may describe different overloads): • words_of requires 1 argument Extracted library reference: evaluator/builtin_constrained_language.go:71. These notes are not a complete signature or a stability guarantee.

write

Function

Extracted library reference: evaluator/builtins.go:15325. These notes are not a complete signature or a stability guarantee. Manual §3.9 `global` — Julia's module write; read with manual "3.9" Excerpt: ### `global` — Julia's module write **`global` is not an alias of `rebind`.** It skips enclosing function locals and may declare the name on **this file** (or this nested `module M … end`

write_bytes

Function

Call diagnostics (different branches may describe different overloads): • write_bytes requires exactly 2 arguments (path, Bytes) Extracted library reference: evaluator/builtin_bytes.go:478. These notes are not a complete signature or a stability guarantee. Manual §4.6.2 Conversions (explicit + fallible); read with manual "4.6.2" Excerpt: | `base64_encode(bs)` / `base64_decode(s)` | round-trip | decoder errors on bad input | | `read_bytes(path)` / `write_bytes(path, bs)` | file I/O | path missing / permission | #### Bitwise ops — word-form infix (v3) + functional form

write_csv

Function

write_csv — the writer read_csv shipped without (2026-08-27). Wires dataframe_io.go's WriteCSV with read_csv's own conventions. Returns the path so pipelines can chain on it. Call diagnostics (different branches may describe different overloads): • write_csv requires 2 or 3 arguments: dataframe, path [, options] Extracted library reference: evaluator/builtins.go:14575. These notes are not a complete signature or a stability guarantee. Manual §5.14 Matrices, tensors & dataframes; read with manual "5.14" Excerpt: `read_csv(path)` loads a file into a `DataFrame`, and `write_csv(df, path [, options])` writes one back (2026-08-27) — options `{delimiter: ";", header: false, na: "NA"}`; it returns the path, and integer cells keep their **exact digits** however large, so write∘read∘write is a fixed

write_f32_be

Function

endianWriteBuiltin returns a BuiltinFunction for the write_TYPE_ENDIAN family: write(bs, offset, value) → new Bytes. The original Bytes is not mutated (Axioma's Bytes is immutable); the returned value is a fresh copy with the field overwritten at the given offset. Call diagnostics (different branches may describe different overloads): • write_f32_be requires exactly 3 arguments (Bytes, offset, value) Extracted library reference: evaluator/builtin_bytes.go:567. These notes are not a complete signature or a stability guarantee.

write_f32_le

Function

endianWriteBuiltin returns a BuiltinFunction for the write_TYPE_ENDIAN family: write(bs, offset, value) → new Bytes. The original Bytes is not mutated (Axioma's Bytes is immutable); the returned value is a fresh copy with the field overwritten at the given offset. Call diagnostics (different branches may describe different overloads): • write_f32_le requires exactly 3 arguments (Bytes, offset, value) Extracted library reference: evaluator/builtin_bytes.go:567. These notes are not a complete signature or a stability guarantee.

write_f64_be

Function

endianWriteBuiltin returns a BuiltinFunction for the write_TYPE_ENDIAN family: write(bs, offset, value) → new Bytes. The original Bytes is not mutated (Axioma's Bytes is immutable); the returned value is a fresh copy with the field overwritten at the given offset. Call diagnostics (different branches may describe different overloads): • write_f64_be requires exactly 3 arguments (Bytes, offset, value) Extracted library reference: evaluator/builtin_bytes.go:567. These notes are not a complete signature or a stability guarantee.

write_f64_le

Function

endianWriteBuiltin returns a BuiltinFunction for the write_TYPE_ENDIAN family: write(bs, offset, value) → new Bytes. The original Bytes is not mutated (Axioma's Bytes is immutable); the returned value is a fresh copy with the field overwritten at the given offset. Call diagnostics (different branches may describe different overloads): • write_f64_le requires exactly 3 arguments (Bytes, offset, value) Extracted library reference: evaluator/builtin_bytes.go:567. These notes are not a complete signature or a stability guarantee.

write_i16_be

Function

endianWriteBuiltin returns a BuiltinFunction for the write_TYPE_ENDIAN family: write(bs, offset, value) → new Bytes. The original Bytes is not mutated (Axioma's Bytes is immutable); the returned value is a fresh copy with the field overwritten at the given offset. Call diagnostics (different branches may describe different overloads): • write_i16_be requires exactly 3 arguments (Bytes, offset, value) Extracted library reference: evaluator/builtin_bytes.go:567. These notes are not a complete signature or a stability guarantee.

write_i16_le

Function

endianWriteBuiltin returns a BuiltinFunction for the write_TYPE_ENDIAN family: write(bs, offset, value) → new Bytes. The original Bytes is not mutated (Axioma's Bytes is immutable); the returned value is a fresh copy with the field overwritten at the given offset. Call diagnostics (different branches may describe different overloads): • write_i16_le requires exactly 3 arguments (Bytes, offset, value) Extracted library reference: evaluator/builtin_bytes.go:567. These notes are not a complete signature or a stability guarantee.

write_i32_be

Function

endianWriteBuiltin returns a BuiltinFunction for the write_TYPE_ENDIAN family: write(bs, offset, value) → new Bytes. The original Bytes is not mutated (Axioma's Bytes is immutable); the returned value is a fresh copy with the field overwritten at the given offset. Call diagnostics (different branches may describe different overloads): • write_i32_be requires exactly 3 arguments (Bytes, offset, value) Extracted library reference: evaluator/builtin_bytes.go:567. These notes are not a complete signature or a stability guarantee.

write_i32_le

Function

endianWriteBuiltin returns a BuiltinFunction for the write_TYPE_ENDIAN family: write(bs, offset, value) → new Bytes. The original Bytes is not mutated (Axioma's Bytes is immutable); the returned value is a fresh copy with the field overwritten at the given offset. Call diagnostics (different branches may describe different overloads): • write_i32_le requires exactly 3 arguments (Bytes, offset, value) Extracted library reference: evaluator/builtin_bytes.go:567. These notes are not a complete signature or a stability guarantee.

write_i64_be

Function

endianWriteBuiltin returns a BuiltinFunction for the write_TYPE_ENDIAN family: write(bs, offset, value) → new Bytes. The original Bytes is not mutated (Axioma's Bytes is immutable); the returned value is a fresh copy with the field overwritten at the given offset. Call diagnostics (different branches may describe different overloads): • write_i64_be requires exactly 3 arguments (Bytes, offset, value) Extracted library reference: evaluator/builtin_bytes.go:567. These notes are not a complete signature or a stability guarantee.

write_i64_le

Function

endianWriteBuiltin returns a BuiltinFunction for the write_TYPE_ENDIAN family: write(bs, offset, value) → new Bytes. The original Bytes is not mutated (Axioma's Bytes is immutable); the returned value is a fresh copy with the field overwritten at the given offset. Call diagnostics (different branches may describe different overloads): • write_i64_le requires exactly 3 arguments (Bytes, offset, value) Extracted library reference: evaluator/builtin_bytes.go:567. These notes are not a complete signature or a stability guarantee.

write_u16_be

Function

endianWriteBuiltin returns a BuiltinFunction for the write_TYPE_ENDIAN family: write(bs, offset, value) → new Bytes. The original Bytes is not mutated (Axioma's Bytes is immutable); the returned value is a fresh copy with the field overwritten at the given offset. Call diagnostics (different branches may describe different overloads): • write_u16_be requires exactly 3 arguments (Bytes, offset, value) Extracted library reference: evaluator/builtin_bytes.go:567. These notes are not a complete signature or a stability guarantee. Manual §4.6.9 Endian-aware read/write at offset (v3); read with manual "4.6.9" Excerpt: resp: bytes(0, 0, 0, 0, 0, 0, 0, 0) resp1: write_u16_be(resp, 1, port) resp2: write_u16_be(resp1, 3, length) # resp is still b"\x00\x00\x00\x00\x00\x00\x00\x00" — original untouched. ```

write_u16_le

Function

endianWriteBuiltin returns a BuiltinFunction for the write_TYPE_ENDIAN family: write(bs, offset, value) → new Bytes. The original Bytes is not mutated (Axioma's Bytes is immutable); the returned value is a fresh copy with the field overwritten at the given offset. Call diagnostics (different branches may describe different overloads): • write_u16_le requires exactly 3 arguments (Bytes, offset, value) Extracted library reference: evaluator/builtin_bytes.go:567. These notes are not a complete signature or a stability guarantee.

write_u32_be

Function

endianWriteBuiltin returns a BuiltinFunction for the write_TYPE_ENDIAN family: write(bs, offset, value) → new Bytes. The original Bytes is not mutated (Axioma's Bytes is immutable); the returned value is a fresh copy with the field overwritten at the given offset. Call diagnostics (different branches may describe different overloads): • write_u32_be requires exactly 3 arguments (Bytes, offset, value) Extracted library reference: evaluator/builtin_bytes.go:567. These notes are not a complete signature or a stability guarantee.

write_u32_le

Function

endianWriteBuiltin returns a BuiltinFunction for the write_TYPE_ENDIAN family: write(bs, offset, value) → new Bytes. The original Bytes is not mutated (Axioma's Bytes is immutable); the returned value is a fresh copy with the field overwritten at the given offset. Call diagnostics (different branches may describe different overloads): • write_u32_le requires exactly 3 arguments (Bytes, offset, value) Extracted library reference: evaluator/builtin_bytes.go:567. These notes are not a complete signature or a stability guarantee.

write_u64_be

Function

endianWriteBuiltin returns a BuiltinFunction for the write_TYPE_ENDIAN family: write(bs, offset, value) → new Bytes. The original Bytes is not mutated (Axioma's Bytes is immutable); the returned value is a fresh copy with the field overwritten at the given offset. Call diagnostics (different branches may describe different overloads): • write_u64_be requires exactly 3 arguments (Bytes, offset, value) Extracted library reference: evaluator/builtin_bytes.go:567. These notes are not a complete signature or a stability guarantee.

write_u64_le

Function

endianWriteBuiltin returns a BuiltinFunction for the write_TYPE_ENDIAN family: write(bs, offset, value) → new Bytes. The original Bytes is not mutated (Axioma's Bytes is immutable); the returned value is a fresh copy with the field overwritten at the given offset. Call diagnostics (different branches may describe different overloads): • write_u64_le requires exactly 3 arguments (Bytes, offset, value) Extracted library reference: evaluator/builtin_bytes.go:567. These notes are not a complete signature or a stability guarantee.

wu_palmer

Function

Call diagnostics (different branches may describe different overloads): • wu_palmer requires exactly 2 arguments • wu_palmer requires two concepts Extracted library reference: evaluator/builtins.go:6246. These notes are not a complete signature or a stability guarantee.

xor

Operator

expression1 xor expression2   (glyph: p ⊻ q; digraphs `xor / `veebar)
Logical exclusive OR operator. Returns true if exactly one of the expressions is true, false otherwise. The ⊻ glyph canonicalizes to `xor` (byte-identical semantics, VM parity). MVL-dispatched: Kleene/Belnap/Łukasiewicz operands use their own logic's tables. See also: nand, nor, iff (xnor).

Examples

true xor false

true ⊻ true        # → false (same operator)

x > 5 xor y > 5

zero?

Function

numericSignPredicate builds a 1-arg predicate over a number's sign. A non-number argument yields false (matching the existing positive/negative/ even family, which return false rather than erroring on a wrong type). Call diagnostics (different branches may describe different overloads): • zero? requires exactly 1 argument Extracted library reference: evaluator/scheme_predicates.go:56. These notes are not a complete signature or a stability guarantee. Manual §22.6.1 Scheme/Lisp-style predicates (`?` suffix); read with manual "22.6.1" Excerpt: Lisp/Scheme spell the test marker `?` rather than Common Lisp's `p`. A trailing `?` is part of the identifier (`zero?` is one word), so these read naturally. The sign predicates treat a non-number as `false` (matching `even`/`positive`). ```axioma

zero_sum?

Function

Registered alias of is_zero_sum. Call diagnostics (different branches may describe different overloads): • argument must be a game • is_zero_sum requires 1 argument: game Extracted library reference: evaluator/builtins.go:13692. These notes are not a complete signature or a stability guarantee.

zeros

Function

Call diagnostics (different branches may describe different overloads): • cols must be an integer • matrix dimensions must be positive • rows must be an integer • zeros requires exactly 2 arguments: rows, cols Extracted library reference: evaluator/builtins.go:13714. These notes are not a complete signature or a stability guarantee. Manual §5.14 Matrices, tensors & dataframes; read with manual "5.14" Excerpt: reshape(matrix([[1, 2, 3], [4, 5, 6]]), 3, 2) # 2×3 → 3×2 zeros(2, 2) # 2×2 of 0s ; ones(2, 3) → 2×3 of 1s solve(matrix([[2, 1], [1, 3]]), [5, 10]) # Ax = b → column vector (1, 3) z: zeros(2, 3)

zip

Function

zip(collection1, collection2)
Returns an array of 2-tuples containing paired elements from both collections (arrays, tuples, or ranges). Truncates to the length of the shorter operand — an open-ended range (n..) truncates to the finite side, so zip(1.., xs) numbers xs. A Set operand is rejected (it has no order to pair by): spell the order deliberately, e.g. zip(sort(array(s)), ...).

Examples

zip([1, 2], ["a", "b"])   # Returns [(1, "a"), (2, "b")]

zip(1.., ["a", "b"])      # [(1, "a"), (2, "b")] — open range numbers the list

zip(1..len(a), a)          # index/element pairs, deterministic

zip_with

Function

zip_with(fn, xs, ys)
Apply fn pairwise across two collections, truncating to the shorter (Haskell zipWith). Manual §12.18 List-library verbs (Haskell / OCaml); read with manual "12.18" Excerpt: ```axioma zip_with(func(a, b) [a + b], [1, 2, 3], [10, 20]) # → [11, 22] pairwise, truncates to shorter scanl(func(a, x) [a + x], 0, [1, 2, 3]) # → [0, 1, 3, 6] left fold, keeping every step scanr(func(x, a) [x + a], 0, [1, 2, 3]) # → [6, 5, 3, 0] right fold (f receives (x, acc)) iterate(func(v) [v * 2], 1, 5) # → [1, 2, 4, 8, 16] first n of [x, f(x), f(f(x)), …]

{

Operator / syntax

Open a set, dictionary, comprehension or a construct-specific body. {} is an empty Set; dict() is an empty Dictionary. See manual "Collections".

|

Operator / syntax

Contextual separator in comprehensions, quantifiers, pattern alternatives, type unions and dialect blocks. The forward pipeline is |>; see doc "|>".

|>

Operator

value |> function(args) | value |> name | value |> obj.fn
Forward pipe: threads the value into the call as its LAST argument (the `_` hole overrides the position), so transformation chains read left-to-right instead of inside-out. Left-associative; lowest precedence.

Examples

xs |> map(inc) |> filter(gt2) |> reduce(add, 0)   # ≡ reduce(add, 0, filter(gt2, map(inc, xs)))

21 |> double                                       # → 42

["a", "b"] |> str_join(_, "-")                 # _ hole → "a-b"

|?>

Operator

value |?> function(args)
Error-propagating forward pipe: like |> but SHORT-CIRCUITS on a failed/absent/undetermined value (Error, none, om), skipping the remaining stages. A falsy-but-valid value (0, "") is not a failure and flows through.

Examples

5 |?> double |?> double      # → 20 (nothing fails)

5 |?> boom |?> double        # → the boom Error (double skipped)

input |?> parse |?> validate # stops at the first failing stage

or

Operator

expression1 or expression2
Logical OR; aliases || and ∨. Skips the right operand for Boolean true on the left. Otherwise preserves multivalued logic dispatch; not an operand-returning or truthiness operator.

Examples

true or false

x < 0 or x > 100

}

Operator / syntax

Close the brace-delimited literal or body opened by {.

~

Symbol

=== ~ (Glyph) === name: tilde category: logic codepoint: U+007E meaning: ~ — tilde (defeasible marker; ~~> is the defeasible-forward rule)

~~>

Operator / syntax

Defeasible forward rule: premises ~~> conclusion. See manual "Rules" for defaults and conflicts.

¬

Symbol

=== ¬ (Glyph) === name: not words: not latex: neg, lnot category: logic codepoint: U+00AC meaning: ¬p — logical negation

½ł

Symbol

=== ½ł (Glyph) === name: lukasiewicz_half latex: lhalf category: mvl codepoint: U+00BD meaning: ½ł — Łukasiewicz Ł3 half-true (≡ lukasiewicz(0.5))

÷

Operator

number ÷ number
Floor division glyph (Julia-style). Same operator as soft-keyword `div` / `idiv` / `quotient` and prefixes `div(a, b)` / `idiv(a, b)` / `quotient(a, b)`: rounds toward −∞ on integers and floats. Digraph: `div → ÷. True (exact/real) division is `/` / `rdiv` — there is no glyph for `/`. Note: `//` is a LINE COMMENT (alias of `#`), not floor division.

Examples

100 ÷ 7            # Returns 14

10.0 ÷ 3.0         # Returns 3

-7 ÷ 3             # Returns -3   (floor toward -inf)

2 + 10 ÷ 3         # Returns 5    (÷ binds tighter than +)

100 div 7          # Returns 14   (keyword spelling)

Σ

Symbol

=== Σ (Glyph) === name: sum words: sum latex: Sigma category: constant codepoint: U+03A3 meaning: Σ — summation

Ω

Symbol

=== Ω (Glyph) === name: omega words: om latex: Omega category: constant codepoint: U+03A9 meaning: Ω — the SETL undefined value

λ

Symbol

=== λ (Glyph) === name: lambda words: lambda latex: lambda category: lambda codepoint: U+03BB meaning: λx.e — lambda abstraction

π

Symbol

=== π (Glyph) === name: pi words: PI latex: pi category: constant codepoint: U+03C0 meaning: π — 3.14159… (ratio of circumference to diameter)

τ

Symbol

=== τ (Glyph) === name: tau words: TAU latex: tau category: constant codepoint: U+03C4 meaning: τ — 2π (6.28318…)

φ

Symbol

=== φ (Glyph) === name: phi words: PHI latex: phi, varphi category: constant codepoint: U+03C6 meaning: φ — the golden ratio (1.61803…)

Symbol

=== ℂ (Glyph) === name: complexes words: complexes latex: mathbb{C} category: constant codepoint: U+2102 meaning: ℂ — the complex numbers

Symbol

=== ℕ (Glyph) === name: naturals words: naturals latex: mathbb{N} category: constant codepoint: U+2115 meaning: ℕ — the natural numbers

Symbol

=== ℚ (Glyph) === name: rationals words: rationals latex: mathbb{Q} category: constant codepoint: U+211A meaning: ℚ — the rational numbers

Symbol

=== ℝ (Glyph) === name: reals words: reals latex: mathbb{R} category: constant codepoint: U+211D meaning: ℝ — the real numbers

Symbol

=== ℤ (Glyph) === name: integers words: integers latex: mathbb{Z} category: constant codepoint: U+2124 meaning: ℤ — the integers

Symbol

=== ← (Glyph) === name: backarrow latex: leftarrow category: logic codepoint: U+2190 meaning: ← — conceptual-graph backward arrow

Symbol

=== → (Glyph) === name: implies words: implies latex: to, rightarrow, implies variants: ⟹ category: logic codepoint: U+2192 meaning: p → q — material implication

Symbol

=== ↔ (Glyph) === name: iff words: iff latex: leftrightarrow, iff variants: ⟺ category: logic codepoint: U+2194 meaning: p ↔ q — if and only if (biconditional)

Symbol

=== ∀ (Glyph) === name: forall words: forall latex: forall category: quantifier codepoint: U+2200 meaning: ∀x — for all x (universal quantifier)

Symbol

=== ∃ (Glyph) === name: exists words: exists latex: exists category: quantifier codepoint: U+2203 meaning: ∃x — there exists x (existential quantifier; ∃! = uniqueness)

Symbol

=== ∅ (Glyph) === name: emptyset words: emptyset, empty_set latex: emptyset, varnothing category: constant codepoint: U+2205 meaning: ∅ — the empty set

Symbol

A △ B — symmetric difference (members in exactly one set) Canonical spelling: △; name: symmetric_difference

Symbol

=== ∈ (Glyph) === name: in words: in latex: in category: set codepoint: U+2208 meaning: x ∈ S — set membership

Symbol

=== ∉ (Glyph) === name: notin words: notin, not_in, not in latex: notin category: set codepoint: U+2209 meaning: x ∉ S — not a member

Symbol

=== ∘ (Glyph) === name: ring latex: circ category: function codepoint: U+2218 meaning: f ∘ g — function composition, right-to-left: (f ∘ g)(x) = f(g(x)); mirror of compose(g, f)

Symbol

=== ∧ (Glyph) === name: and words: and latex: wedge, land category: logic codepoint: U+2227 meaning: p ∧ q — logical conjunction (canonicalizes to the `and` operator; MVL-dispatched)

Symbol

=== ∨ (Glyph) === name: or words: or latex: vee, lor category: logic codepoint: U+2228 meaning: p ∨ q — logical disjunction (canonicalizes to the `or` operator; MVL-dispatched)

Symbol

=== ∩ (Glyph) === name: intersect words: intersect, intersection latex: cap category: set codepoint: U+2229 meaning: A ∩ B — intersection (members in both sets)

Symbol

=== ∪ (Glyph) === name: union words: union latex: cup category: set codepoint: U+222A meaning: A ∪ B — union (members in either set)

Symbol

=== ∴ (Glyph) === name: therefore words: therefore latex: therefore, qed, thus category: logic codepoint: U+2234 meaning: p ∴ q — therefore / QED (the conclusion / inference mark; canonicalizes to the `therefore` operator)

Symbol

=== ∼ (Glyph) === name: tilde_negation latex: sim category: logic codepoint: U+223C meaning: ∼p — logical negation (philosophical-text tilde; canonicalizes to ¬)

Symbol

=== ≠ (Glyph) === name: not_equal latex: neq, ne category: logic codepoint: U+2260 meaning: a ≠ b — not equal (canonicalizes to !=)

Symbol

=== ≡ (Glyph) === name: equivalent words: equivalent latex: equiv category: logic codepoint: U+2261 meaning: p ≡ q — equivalence

Symbol

=== ≤ (Glyph) === name: less_equal latex: leq, le, leqslant variants: ⩽ category: logic codepoint: U+2264 meaning: a ≤ b — less than or equal (canonicalizes to <=; ordering comparisons chain: 0 ≤ x < n)

Symbol

=== ≥ (Glyph) === name: greater_equal latex: geq, ge, geqslant variants: ⩾ category: logic codepoint: U+2265 meaning: a ≥ b — greater than or equal (canonicalizes to >=)

Symbol

=== ⊂ (Glyph) === name: proper_subset words: proper_subset, subsetneq, proper subset latex: subset, subsetneq variants: ⊊ category: set codepoint: U+2282 meaning: A ⊂ B — proper (strict) subset

Symbol

=== ⊃ (Glyph) === name: proper_superset words: proper_superset, supsetneq, proper superset latex: supset, supsetneq variants: ⊋ category: set codepoint: U+2283 meaning: A ⊃ B — proper (strict) superset

Symbol

=== ⊆ (Glyph) === name: subset words: subset latex: subseteq category: set codepoint: U+2286 meaning: A ⊆ B — subset (or equal)

Symbol

=== ⊇ (Glyph) === name: superset words: superset latex: supseteq category: set codepoint: U+2287 meaning: A ⊇ B — superset (or equal)

Symbol

A ⊂ B — proper (strict) subset Canonical spelling: ⊂; name: proper_subset

Symbol

A ⊃ B — proper (strict) superset Canonical spelling: ⊃; name: proper_superset

Symbol

=== ⊑ (Glyph) === name: subsumes latex: sqsubseteq category: dl codepoint: U+2291 meaning: C ⊑ D — DL subsumption

Symbol

=== ⊓ (Glyph) === name: concept_and latex: sqcap category: dl codepoint: U+2293 meaning: C ⊓ D — DL concept conjunction

Symbol

=== ⊔ (Glyph) === name: concept_or latex: sqcup category: dl codepoint: U+2294 meaning: C ⊔ D — DL concept disjunction

Symbol

=== ⊕ (Glyph) === name: b4_join latex: oplus category: logic codepoint: U+2295 meaning: a ⊕ b — B4 knowledge-order join (gullibility: accept all testimony; conflict → glut)

Symbol

A △ B — symmetric difference (members in exactly one set) Canonical spelling: △; name: symmetric_difference

Symbol

=== ⊗ (Glyph) === name: b4_meet latex: otimes category: logic codepoint: U+2297 meaning: a ⊗ b — B4 knowledge-order meet (consensus: keep only agreement)

Symbol

=== ⊤ (Glyph) === name: verum latex: top category: logic codepoint: U+22A4 meaning: ⊤ — verum (true)

⊤ł

Symbol

=== ⊤ł (Glyph) === name: lukasiewicz_true latex: ltrue category: mvl codepoint: U+22A4 meaning: ⊤ł — Łukasiewicz Ł3 true (≡ lukasiewicz(1.0))

⊤ᵇ

Symbol

=== ⊤ᵇ (Glyph) === name: belnap_true latex: beltrue category: mvl codepoint: U+22A4 meaning: ⊤ᵇ — Belnap B4 true (≡ belnap("true"))

⊤ᵏ

Symbol

=== ⊤ᵏ (Glyph) === name: kleene_true latex: kltrue category: mvl codepoint: U+22A4 meaning: ⊤ᵏ — Kleene K3 true (≡ kleene("true"))

⊤ⁱ

Symbol

=== ⊤ⁱ (Glyph) === name: g3_true latex: gtrue category: mvl codepoint: U+22A4 meaning: ⊤ⁱ — Gödel G3 true (≡ intuit3("true"))

⊤⊥ᵇ

Symbol

=== ⊤⊥ᵇ (Glyph) === name: belnap_both latex: belboth, glut category: mvl codepoint: U+22A4 meaning: ⊤⊥ᵇ — Belnap B4 both (the glut; ≡ belnap("both"))

Symbol

=== ⊥ (Glyph) === name: falsum latex: bot, perp category: logic codepoint: U+22A5 meaning: ⊥ — falsum (false)

⊥ł

Symbol

=== ⊥ł (Glyph) === name: lukasiewicz_false latex: lfalse category: mvl codepoint: U+22A5 meaning: ⊥ł — Łukasiewicz Ł3 false (≡ lukasiewicz(0.0))

⊥ᵇ

Symbol

=== ⊥ᵇ (Glyph) === name: belnap_false latex: belfalse category: mvl codepoint: U+22A5 meaning: ⊥ᵇ — Belnap B4 false (≡ belnap("false"))

⊥ᵏ

Symbol

=== ⊥ᵏ (Glyph) === name: kleene_false latex: klfalse category: mvl codepoint: U+22A5 meaning: ⊥ᵏ — Kleene K3 false (≡ kleene("false"))

⊥ⁱ

Symbol

=== ⊥ⁱ (Glyph) === name: g3_false latex: gfalse category: mvl codepoint: U+22A5 meaning: ⊥ⁱ — Gödel G3 false (≡ intuit3("false"))

Symbol

=== ⊻ (Glyph) === name: xor words: xor latex: veebar, xor category: logic codepoint: U+22BB meaning: p ⊻ q — exclusive or (canonicalizes to the `xor` operator; MVL-dispatched)

Symbol

=== ⊼ (Glyph) === name: nand latex: barwedge, nand category: logic codepoint: U+22BC meaning: p ⊼ q — NAND, the Sheffer stroke ¬(p ∧ q); functionally complete alone (Post). Prefix form: nand(p, q)

Symbol

=== ⊽ (Glyph) === name: nor latex: barvee, nor category: logic codepoint: U+22BD meaning: p ⊽ q — NOR, the Peirce arrow ¬(p ∨ q); functionally complete alone (Wittgenstein's N is its n-ary form). Prefix form: nor(p, q)

Symbol

◇p — possibly p (alethic possibility; true in some accessible world) Canonical spelling: ◇; name: diamond

Symbol

=== □ (Glyph) === name: box words: necessarily latex: Box, square variants: ◻ category: modal codepoint: U+25A1 meaning: □p — necessarily p (alethic necessity; true in all accessible worlds)

Symbol

=== △ (Glyph) === name: symmetric_difference words: symmetric_difference, symdiff, symmetric difference latex: triangle, ominus variants: ∆ ⊖ category: set codepoint: U+25B3 meaning: A △ B — symmetric difference (members in exactly one set)

Symbol

=== ◇ (Glyph) === name: diamond words: possibly latex: Diamond, diamond, lozenge variants: ◊ ⋄ category: modal codepoint: U+25C7 meaning: ◇p — possibly p (alethic possibility; true in some accessible world)

Symbol

◇p — possibly p (alethic possibility; true in some accessible world) Canonical spelling: ◇; name: diamond

Symbol

□p — necessarily p (alethic necessity; true in all accessible worlds) Canonical spelling: □; name: box

Symbol

p → q — material implication Canonical spelling: →; name: implies

Symbol

p ↔ q — if and only if (biconditional) Canonical spelling: ↔; name: iff

Symbol

a ≤ b — less than or equal (canonicalizes to <=; ordering comparisons chain: 0 ≤ x < n) Canonical spelling: ≤; name: less_equal

Symbol

a ≥ b — greater than or equal (canonicalizes to >=) Canonical spelling: ≥; name: greater_equal