include/t81/types, include/t81/tensor, include/t81/ternary)include/t81/frontend)include/t81/tisc, include/t81/vm)include/t81/weights, tooling/model)include/t81/canonfs, include/t81/axion)This guide catalogs the public C++ APIs under include/t81/, highlights threading/error-handling expectations, and points readers toward the generated Doxygen docs.
include/t81/ (organized per subsystem). Prefer the generated API reference at build/api/html/index.html after running cmake --build build --target docs.t81::... (and nested namespaces such as t81::core, t81::frontend, t81::lang, t81::vm, t81::weights). Respect the t81::v1 inline namespace alias for future ABI compatibility.include/t81/types, include/t81/tensor, include/t81/ternary)T81Int.hpp, T81Float.hpp, T81Tensor.hpp, T81Matrix.hpp, T81List.hpp, T81Set.hpp, T81Map.hpp, T81Result.hpp, T81Maybe.hpp.t81::support::expected (which is copy-on-write safe) when sharing results across threads.t81::support::expected/T81Result wrappers or emit controlled Axion traps for overflow/entropy violations. Rare unrecoverable faults throw std::domain_error/std::runtime_error (documented in ../explanation/DESIGN.md). Prefer the noexcept helpers in internal/support/assert.hpp for invariants.include/t81/frontend)frontend::Lexer, frontend::Parser, frontend::SemanticAnalyzer, frontend::IRGenerator.t81 CLI tool provides the canonical implementation of this error reporting.t81 CLI driver, which serves as the primary public interface for compiling and running T81Lang code.include/t81/cli/driver.hpp) exposes build_program_from_source, compile, check_syntax, run_tisc, and repl. build_program_from_source is the canonical entry point for lex/parse/semantic/IR/TISC generation and now accepts the original source string so diagnostics can print the exact line and caret for semantic errors.build_program_from_source returns t81::tisc::Program plus Axion loop metadata and optional weights attachments. Use it to integrate the frontend pipeline into custom tooling or tests (see tests/cpp/cli_diagnostic_context_test.cpp for an example that verifies the Option/Result/loop/match diagnostics).compile/check/repl, ensuring all commands share a single diagnostics path and deterministic semantic context.include/t81/tisc, include/t81/vm)BinaryEmitter, Program), runtime state/VM (vm::IVirtualMachine, vm::State, vm::OptionValue).t81::vm::State instances or guard access via your scheduler to prevent concurrent mutation.vm::AxionEvent; invalid instructions throw std::runtime_error/AxionTrap. Memory faults wrap the t81::vm::AxionEvent::type enum.include/t81/weights, tooling/model)t81 weights ... commands.t81::support::expected results; disk concurrency control is handled by the caller (e.g., the CLI). Unexpected formats result in descriptive diagnostics rather than crashes.include/t81/canonfs, include/t81/axion)spec/supplemental/canonfs-spec.md and spec/axion-kernel.md as the normative source.t81::axion::Verdict/event metadata, and CanonFS operations report deterministic outcomes suitable for replay/audit.namespace t81 { ... } and /// comments; keep them updated when adding APIs).tests/cpp/ and a short entry in docs/guides/public-api-overview.md.include/t81/ should introduce raw new/delete, global mutable state, or hidden nondeterminism; refer to ../../AGENTS.md/../explanation/DESIGN.md when in doubt.