Documentation
Everything you need to build, query, and analyze with Rayforce — the pure C17 zero-dependency columnar dataframe library with a native graph engine.
Getting Started
Quick Start — Install prerequisites, build from source, start the REPL, create your first table, and run your first query in under 5 minutes.
Rayfall Language
Syntax & Types — Complete reference for the Rayfall language: atoms (integers, floats, booleans, symbols, strings, dates, times, timestamps, GUIDs), vectors, lists, tables, dictionaries, function calls, quoting, and comments.
Functions Reference — All 120+ built-in functions organized by category: arithmetic, comparison, logic, aggregation, higher-order, collection, sorting, table, query, join, I/O, string, temporal, type, and system operations.
Queries
Select & Update — The select and update query verbs with filtering, grouping, column expressions, and aggregation. Bridges directly to the Rayforce DAG executor.
Joins — Left joins, inner joins, window joins, and as-of joins. Time-windowed matching for event data.
Pivot & Window — Pivot tables for reshaping data, xbar for bucketing, and xrank for ranking within groups.
Operations
Math & Aggregation — Arithmetic operators (+ - * / %), rounding, aggregates (sum, avg, min, max, med, dev, count), and statistical functions.
String Operations — String splitting, pattern matching with like, concatenation, and format.
C API
Core API — The ray_t abstraction, vector operations, table construction, and the single public header include/rayforce.h.
DAG & Execution — Build lazy DAGs with ray_graph_new(), chain operations, and execute with the fused morsel-driven executor.
Graph Engine
CSR Storage — Double-indexed CSR (forward + reverse) edge indices, .col file persistence, and mmap support.
Algorithms — 1-hop expand, BFS variable-length paths, shortest paths, A*, Yen's K-shortest, betweenness/closeness centrality, clustering coefficients, random walks, MST, and worst-case optimal joins (LFTJ).
Architecture
Pipeline & Optimizer — The lazy DAG execution pipeline: type inference, constant folding, sideways information passing, factorize, predicate pushdown, filter reorder, fusion, and dead code elimination.
Memory Model — Buddy allocator with thread-local arenas, slab cache, COW ref counting, arena (bump) allocator, per-VM heaps with lock-free cross-heap reclamation.
Storage
Files & Partitions — Cross-platform file I/O with locking, atomic rename, sym intern table persistence, and CSV loading with parallel parse.