रिलीज़ नोट्स

संस्करण 0.9.0-beta.4

इस रिलीज़ के बदलाव, माइग्रेशन नोट्स और संगतता।

v0.9.4 के लिए GitHub पर स्रोत देखें ↗

Shell
pip install "triviumdb==0.9.0b4"
npm install triviumdb@0.9.0-beta.4
cargo add triviumdb@0.9.0-beta.4

This Beta strengthens persistence consistency, resource admission, numeric semantics and graph-query boundaries in the native unified vector, graph and document engine. Rust, Python, Node.js and CLI use the same storage and query implementation, with TQL execution planned through Cascades.

Rust, CLI, Server source and npm use 0.9.0-beta.4; Python/PyPI uses 0.9.0b4; the Git tag is v0.9.0-beta.4. The installation commands above select these versions. npm uses the beta channel and GitHub marks this release as a prerelease. Server and WebUI retain the nightly development channel.

WAL integrity, QuIVer fact binding and BQ boundaries

  • Complete WAL frames with invalid CRCs, decoding or oversized lengths return CorruptedFile while preserving the full log. Physically incomplete tail frames and uncommitted transactions retain commit-boundary recovery. Regressions cover corruption at every frame position, bytewise tail cuts and repeated opens.
  • .quiver.meta v2 binds main-file, separate-vector and index CRCs, checks its own CRC, and validates every active ID/slot pair. Legacy v1 metadata follows the configured fallback/error policy; read-only fallback preserves original artifacts.
  • TQL admits Payload, vector, edge, return, grouping and sorting copies against instance and shared workspace budgets before materialization. DML matching inherits memory limits while retaining whole-set semantics; pipelines account for the columns actually evaluated. An independent allocator checks query-thread heap-request peaks and unchanged facts after rejection.
  • Low-level Rust BQ distance, signature-read and raw-store construction APIs return Result, covering empty stores, out-of-range rows, oversized dimensions, malformed planes and tail bits. Safe entry points validate geometry before invoking existing distance kernels; new cases join the Miri subset.

Reader leases, shared resources and atomic deletion

  • GenerationStore anchors relative paths at construction and resolves default runtime namespaces from canonical roots once they exist. Lease regressions cover construction timing, aliases, working-directory changes and multiple processes. Cooperating processes use consistent root/runtime paths; retire older Reader processes before resuming reclamation after an upgrade.
  • GraphFirst retains a bounded Top-K heap before materializing Payload. Exact retrieval, every reachability mode, neighborhoods and subgraphs admit containers, paths, bitmaps, Metadata and Payload copies through shared workspace reservations. State reservations grow with exploration and unwind correctly on errors.
  • Legacy Rust numeric ranges reuse exact integer/float ordering. Ordered planning falls back to exact evaluation for large floating-point bounds, with positive/negative endpoints, fractions and nonfinite legacy bounds covered.
  • TQL DETACH DELETE uses the core transaction deletion path for connected sets, repeated bindings, parallel edges and self-loops while preserving external facts. Shared native SDK contracts, cross-process leases and WAL/apply fault tests verify complete recovered states.

Graph matching, path budgets and retrieval validation

  • Reverse MATCH traversal preserves a row for every physical parallel edge. Named and unnamed patterns share enumeration; bidirectional single-hop matching counts each self-loop once, with consistent counts before and after indexing.
  • Graph patterns and variable-length paths use explicit stacks. Exploration below the minimum depth, edge scans and backtracking consume a shared step budget and check cancellation/deadlines. Workspace admission precedes traversal. Regressions cover small-stack subprocesses, in-flight interruption and exponential path graphs.
  • Exact, GraphFirst, ordinary and physical vector operators share dimension and finite-value validation. Candidate-pool expansion uses saturating arithmetic, keeping oversized Top-K requests bounded by actual candidates.

Cross-language errors and release provenance

  • Core errors expose stable codes and structured details. Python exceptions and synchronous/asynchronous Node errors retain version, node, constraint, migration and budget fields. Prepared statements report missing and unexpected parameter names through dedicated categories; unexpected names are selected deterministically. Row-limit failures consistently report the query-budget category.
  • Exhaustive Rust matches include the new MissingQueryParameter and UnexpectedQueryParameter variants. Row-limit failures use QueryRowBudgetExceeded. Large integer fields in Node error details have type number | string; callers read them according to their runtime type.
  • Shared real-API cases assert complete error details across all three languages. Rust and Python mapping samples cover every core error variant. Node preserves large integers in error details as decimal strings.
  • Mmap, Rom and snapshot documentation describe the current file group, security references point to current modules, and both READMEs state the Python 3.9–3.12 installation range.
  • Both CD workflows share release provenance validation. Stable tags identify a same-repository dev-to-master merge on master's release history with successful master CI for that exact commit. Historical releases remain eligible for recovery publishing after master advances. Beta releases retain their public-testing quality gates.
  • The provenance validator is loaded from the workflow commit into the runner's temporary directory, while historical tags retain their original source for validation and builds.

Persisted types, Windows mappings and loading admission

  • .tdb v10 stores dtype, element width and a header CRC. Mismatched types are rejected before writes, and both layouts require exact vector geometry. New databases pass admission and persist type identity before accepting WAL entries. Nonempty v5–v9 checkpoints establish dtype from geometry; historical WAL-only data and untyped empty checkpoints with nonempty WAL must first be recovered and checkpointed with their original version. Downgrades use pre-upgrade backups. Empty legacy databases migrate their complete file group and retain index definitions; read-only loading retains empty Hash index fields.
  • Vector replacement or remapping failures that invalidate a live mapping quarantine the instance and shared query handles. The original I/O error and WAL remain available; release the instance and reopen writable to recover.
  • Every TQL string parser requires complete input consumption. Limits on bytes, tokens, nesting and operators cover repeated NOT and flat expression chains. Invalid mutation tails are rejected before execution.
  • Opening checks conservative allocation peaks for nodes, payloads, graph data, derived indexes and WAL, then verifies the final heap estimate. WAL migration/truncation follows admission. Rejected opens release shared reservations and preserve the WAL for a later retry. Recovery defers parsed-cache population and configures the cache against remaining heap headroom afterward.
  • Rust, Python and Node regressions cover type, parser, budget and recovery boundaries. Linux CI runs optimized parsing on a 2 MiB stack; Windows tests use actual file-sharing flags to exercise replacement failures.

Unique constraints, composite fields and graph indexes

  • Unique constraint creation and removal hold the write lock through publication. Publication errors quarantine the instance and shared query handles; writable reopening uses the actual commit point to recover the old schema or accept the new schema, then replays WAL. Validation failures leave the instance usable.
  • .pidx v8 encodes composite fields as a JSON string array, preserving NUL, escapes and Unicode. Legacy composite postings fall back to ground-truth queries; unique constraints rebuild from authoritative main-file definitions. Recreate ordinary composite indexes with their original field list. Composite names total at most 1 MiB across 2–65,535 fields.
  • Node JSON boundaries use length-aware property names throughout CRUD, transactions, filters, business edges, hooks and query results. Nested NUL keys and own __proto__ data properties round-trip; invalid JSON values and cyclic structures are rejected before writes.
  • Graph sidecars validate every edge, count and directory against each other and compare endpoints, labels, weights and Metadata with main-file facts before adoption. Read-only failures preserve the file group and report corruption; writers can explicitly rebuild the sidecar. Validation and JSON decode peaks participate in load admission.
  • Regression coverage includes pre/post-commit failures, retained handles, recovered data and constraints, v7 composite compatibility, CRC-consistent graph mutations and actual Python/Node artifacts.

Exact numerics, binary fingerprints and migration

  • Cosine kernels fall back to f64 accumulation when norms, dot products or denominators overflow or underflow, while ordinary finite magnitudes retain SIMD execution. Both general and cached 384-dimensional paths share the checks; zero vectors score zero.
  • Basic u64 retrieval preserves complete query bit patterns and consistently scores matching bits through exact Hamming search. Automatic QuIVer construction selects floating-point dtypes; historical binary sidecars are skipped, and explicit u64 construction returns a structured input error. Observable floating-point hook query rewrites are rejected for binary fingerprints.
  • Dimension migration rejects existing destination artifacts before writing, builds a private staging database, publishes under the destination write lock, and transfers that lock to the returned instance. Publication uses atomic same-filesystem hard links. Pre-commit failures reclaim only newly created entries; post-commit failures preserve the complete new database. Source data and colliding files remain unchanged.
  • Independent geometry/integer examples, SIMD/cached-norm checks, native SDK retrieval, migration faults, commit boundaries and lock interleavings extend regression coverage.

Upgrade and compatibility

  1. Close existing instances and preserve the complete file group or a directory snapshot before opening it with this version. The v10 main file persists dtype, element width and a header CRC. Recover historical WAL-only data or untyped empty checkpoints with nonempty WAL using the original version and complete a checkpoint first. Downgrades use the full pre-upgrade backup.
  2. .pidx v8 uses an unambiguous field-list encoding. Legacy composite postings query current facts; recreate ordinary composite indexes with the original field list. Unique constraints rebuild from authoritative main-file definitions.
  3. .quiver.meta v2 binds the index to main/vector content and active ID/slot mappings. Legacy v1 metadata follows MissingIndexPolicy: default fallback or a strict error. Read-only fallback preserves the original sidecars; writable instances can explicitly rebuild and publish them.
  4. Complete corrupt WAL frames return CorruptedFile and preserve the log. Physically incomplete tail frames and transactions without a commit seal recover to completed commit boundaries. Mismatched dtypes are rejected before writes. Reopen instances according to the reported recovery state after invalidated mappings or failed schema publication.
  5. Low-level Rust Bq2Signature::distance and Bq2Store::{distance,distance_to_sig,distance_to_sig_cheap,get_sig,from_raw} return Result; callers use ?. Exhaustive Rust error matches include the new structured missing/unexpected-parameter variants. Python and Node retain their language-specific names and result wrappers, with stable error categories and required details preserved.
  6. Cooperating Reader processes use consistent canonical root paths and a shared writable runtime directory, keeping the root location stable while Readers are alive. Retire older Reader processes before enabling old-generation reclamation after the upgrade.

Validation scope

Local validation completed on Windows for workspace tests, test-hooks concurrency/differential/fault and planner suites, release library/storage/allocation regressions, Clippy, an installed npm package and an installed Python wheel. The Miri subset checks BQ pointer boundaries and concurrent adjacency storage. An independent allocator measures query-thread heap requests on 20 nodes and 400 edges under a 512 KiB limit, verifies unchanged facts after rejection, and checks complete results after releasing the limit. Optional ablation benchmarks passed compilation checks.

Cross-platform, ASan, TSan, fuzz and release-artifact scopes are recorded by the corresponding CI/CD runs. Cross-dataset performance comparisons and the separate extended fault matrix run independently. See testing, public APIs and lifecycle/snapshots for commands and operating conditions.