gizmodel
The application data layer: shapes, typed queries, sources, policies, live feeds and search on one SQL API. Import a module by name, for example import * as Store from "gizmodel/store";. Each page lists the module's public declarations exactly as an installed toolchain provides them.
| Module | Purpose |
|---|---|
| gizmodel/copy | The pieces every copy into GizDB shares: the page credit, the rows a source answers, and the one proof of a copy, an order-free checksum of its rows (Store.copy and Store.move, gizdb migrate). |
| gizmodel/core/analyzer | Text analysis: the tokens of a text for the inverted index and for queries. |
| gizmodel/core/column | Columns: the one in-memory layout of data, shared by segments, the delta's scans and the executor's batches. |
| gizmodel/core/inverted | The inverted index of a text column and BM25 top-k search over it. One byte layout is the index, in memory and in a segment's file (segment.giz), read in pages of PAGE bytes: a resident index holds every page, a cold one the pages its queries read. |
| gizmodel/core/kernels | The vector loops over column storage: the one owner of SIMD in the GizDB executor. |
| gizmodel/core/names | Quoted names that keep their case. |
| gizmodel/core/parquet | Apache Parquet files read as GizDB columns (model/source.giz reads them as a table): the footer's schema and row groups, and each row group's column chunks decoded into column.giz columns, a dictionary-encoded text chunk keeping its dictionary as the column's. |
| gizmodel/data | A stored application's typed records, by their Model.Shape: on a GizDB engine this process serves, or on a SQL store. |
| gizmodel/decimal | Exact decimals, as PostgreSQL's NUMERIC: a value is C × 10^-s with a scale s of 0..16383 and at most 131072 digits before the point. |
| gizmodel/error | Typed failures shared by database owners; protocol spelling lives in sql/errors.giz. |
| gizmodel/gate | who may read and write which rows of a Shape. |
| gizmodel/held | the types of a typed read and of the Db that runs it. |
| gizmodel/insert | the INSERT of a stored Model.Shape's records, as the tree every engine runs. |
| gizmodel/model | a record type's meaning as a value (a Shape), and what is derived from it besides HTML: typed input validation, SQL wire rows, DDL for SQLite and PostgreSQL, additive migration, JSON and agent tool schemas. |
| gizmodel/policy | The DAL's Policy. |
| gizmodel/query | a typed read of stored records. |
| gizmodel/relay | realtime as a position in a log the database keeps. |
| gizmodel/schema | One pure schema planner. |
| gizmodel/search | A search index of any source of documents: a folder (a POSIX tree or a GizFS mount) or a system of your own that implements Source. |
| gizmodel/semantic | Analytical meaning is metadata attached to stable declarations. |
| gizmodel/source | One typed data-source contract. |
| gizmodel/sql/aggnames | which function names are aggregates, the one owner of that list. |
| gizmodel/sql/ast | The SQL syntax tree. |
| gizmodel/sql/batch | a batch of typed columns and the replies that carry batches (FinitePoll, Rows, Delivery). |
| gizmodel/sql/catalog/gucs | PostgreSQL's configuration parameters, as pg_settings and SHOW ALL list them: the one owner of their names, boot values, units, limits and descriptions. |
| gizmodel/sql/catalog/routine | Stored routines and triggers as the catalog keeps them: one text per object (Engine.setObject), written by the parser from CREATE FUNCTION, PROCEDURE or TRIGGER in any dialect and read back by the binder (which inlines functions, proc.giz) and the session (which runs the rest). |
| gizmodel/sql/catalog/sequence | Sequences as Oracle and PostgreSQL define them: a step (negative counts down), bounds, and CYCLE, which starts again at the far bound instead of failing. |
| gizmodel/sql/errors | Protocol representations have one owner; no diagnostic text classifies a failure. |
| gizmodel/sql/lex | SQL tokens. |
| gizmodel/sql/parse | The SQL parser: recursive descent over lex.giz's tokens into ast.giz's nodes. |
| gizmodel/sql/render | The one place the DAL prints a syntax tree as SQL text of a dialect: external pushdown, the SQL stores of gizmodel/store and gizmodel/data, and the views of gizweb/view. |
| gizmodel/sql/tree | A stored table that follows a record type. |
| gizmodel/sql/types/dialect | A SQL dialect as a value: its name and the rules where the engines it imitates differ in meaning, not spelling. |
| gizmodel/sql/types/geo | PostgreSQL's geometric types (point, lseg, line, box, path, polygon, circle) as PostgreSQL 16's geo_ops.c reads, writes and compares them. |
| gizmodel/sql/types/inet | PostgreSQL's network address types inet and cidr as PostgreSQL 16's network.c and inet_net_pton.c read, write and compare them. |
| gizmodel/sql/types/json | JSON as PostgreSQL 16 reads, prints and queries it: JSON text as exact items (json, jsonb), and SQL/JSON paths, the jsonpath type: its parser (jsonpath_scan.l, jsonpath_gram.y), its canonical text (jsonpath_out) and its evaluation (jsonpath_exec.c). |
| gizmodel/sql/types/lsn | PostgreSQL's pg_lsn type as PostgreSQL 16's pg_lsn.c reads, writes and computes it. |
| gizmodel/sql/types/scalar | What every SQL function shares: the context it may read (Cx), the function value (Fn, Scalar) and the helpers that make and read argument values. |
| gizmodel/sql/types/snowball | |
| gizmodel/sql/types/tsdict | |
| gizmodel/sql/types/tsearch | Text search as PostgreSQL 16 does it: the tsvector and tsquery types and their canonical text (tsvector_parser.c, tsvector.c, tsquery.c), the default parser (wparser_def.c) and its tokens through the configurations and dictionaries of tsdict.giz, to_tsquery and its relatives, @@ (tsvector_op.c TS_execute), ts_rank and ts_rank_cd (tsrank.c) and the editing functions. |
| gizmodel/sql/types/types | SQL values: how a declared type is stored, what text a value reads as, casts, comparison, arithmetic, dates and intervals, and printing, for each dialect. |
| gizmodel/sql/types/xml | PostgreSQL's xml type: well-formedness, a node tree, XPath 1.0 and serialization (PostgreSQL's xml.c over libxml2). |
| gizmodel/store | the database a web app keeps its records in, by its location. |
| gizmodel/typed | Typed data contracts: Slot, Codec, the codecs, logical Contract and the exact JSON transport of a Value. |
| gizmodel/value | Values, types and schemas, and how they are written with the words, blobs and order keys of gizfs/codec, the one binary encoding of stored bytes (the log and segment files alike). |