Fix inconsistencies in the project

This commit is contained in:
Hassan Abedi 2026-04-09 12:46:26 +02:00
parent 0986e13669
commit dd7b16ce93
4 changed files with 47 additions and 17 deletions

View File

@ -1,5 +1,5 @@
# Variables # Variables
BINARY_NAME := chase-rs BINARY_NAME := query-engine
BINARY := target/release/$(BINARY_NAME) BINARY := target/release/$(BINARY_NAME)
DEBUG_PROJ := 0 DEBUG_PROJ := 0
RUST_BACKTRACE := 1 RUST_BACKTRACE := 1
@ -39,17 +39,17 @@ run: build ## Build and run the binary
.PHONY: repl .PHONY: repl
repl: format ## Start the interactive REPL repl: format ## Start the interactive REPL
@echo "Starting chase-rs REPL..." @echo "Starting query-engine REPL..."
@DEBUG_PROJ=$(DEBUG_PROJ) cargo run -- repl @DEBUG_PROJ=$(DEBUG_PROJ) cargo run -- repl
.PHONY: gui .PHONY: gui
gui: format ## Start the local GUI at 127.0.0.1:7878 gui: format ## Start the local GUI at 127.0.0.1:7878
@echo "Starting chase-rs GUI on http://127.0.0.1:7878..." @echo "Starting query-engine GUI on http://127.0.0.1:7878..."
@DEBUG_PROJ=$(DEBUG_PROJ) cargo run -- gui @DEBUG_PROJ=$(DEBUG_PROJ) cargo run -- gui
.PHONY: gui-addr .PHONY: gui-addr
gui-addr: format ## Start the local GUI at GUI_ADDR=<host:port> gui-addr: format ## Start the local GUI at GUI_ADDR=<host:port>
@echo "Starting chase-rs GUI on http://$(or $(GUI_ADDR),127.0.0.1:7878)..." @echo "Starting query-engine GUI on http://$(or $(GUI_ADDR),127.0.0.1:7878)..."
@DEBUG_PROJ=$(DEBUG_PROJ) cargo run -- gui $(or $(GUI_ADDR),127.0.0.1:7878) @DEBUG_PROJ=$(DEBUG_PROJ) cargo run -- gui $(or $(GUI_ADDR),127.0.0.1:7878)
.PHONY: script .PHONY: script

View File

@ -3,8 +3,9 @@
An experimental Rust project for building query-engine components. An experimental Rust project for building query-engine components.
Right now the repository is centered on a chase-based reasoning core plus a Right now the repository is centered on a chase-based reasoning core plus a
small interactive frontend. The broader target shape is a query engine with small interactive frontend, plus an early relational/SQL scaffold. The broader
clearer front-end, planning, optimization, and execution boundaries. target shape is a query engine with clearer front-end, planning, optimization,
and execution boundaries.
### Current scope ### Current scope
@ -12,20 +13,22 @@ clearer front-end, planning, optimization, and execution boundaries.
- Restricted-chase style materialization with active-trigger checks - Restricted-chase style materialization with active-trigger checks
- Provenance-oriented explanations for derived answers - Provenance-oriented explanations for derived answers
- Script, REPL, and local web UI for experimentation - Script, REPL, and local web UI for experimentation
- Relational schema, catalog, logical-plan, and execution scaffolding
- A minimal SQL slice for single-table `SELECT-FROM-WHERE` queries
### Intended direction ### Intended Direction
The medium-term direction is to evolve this project from a copied The medium-term direction is to evolve this project into a more general
`chase-rs` codebase into a more general query-engine playground with: query-engine playground with:
- explicit front-end and parsing layers - explicit front-end and parsing layers
- internal planning representations - internal planning representations
- clearer separation between logical meaning and execution strategy - clearer separation between logical meaning and execution strategy
- support for multiple query-engine experiments instead of only chase logic - support for multiple query-engine experiments instead of only chase logic
The current code does not yet implement a SQL front end, logical plan, or The current code now includes an initial SQL front end, logical plan, and
physical plan. The repository naming, docs, and user-facing surfaces now execution path. It is still intentionally narrow and should not be read as full
reflect that more honestly. SQL support.
### Quickstart ### Quickstart
@ -81,6 +84,32 @@ reset
help help
``` ```
#### Current SQL Slice
The repository now has a narrow SQL pipeline with:
- predicate-backed catalog inference
- relational schemas, rows, and values
- SQL parsing for a small subset
- logical planning
- execution for single-table queries
Currently supported examples:
```sql
SELECT * FROM Parent
SELECT c0 FROM Parent
SELECT c0 FROM Parent WHERE c1 = 'bob'
```
Current limits:
- single-table only
- positional column names such as `c0`, `c1`
- no joins
- no aggregates
- no aliases
### Development ### Development
For non-trivial changes, run: For non-trivial changes, run:
@ -93,9 +122,9 @@ cargo fmt --check
### Notes ### Notes
This repository is still centered on a rule-engine core. The longer-term goal This repository is still centered on a rule-engine core. The new SQL-related
is to grow it into a broader query-engine project without claiming SQL, modules are scaffolding for a broader query-engine direction, not a claim of
logical-planning, or physical-planning support before those layers exist. feature-complete SQL support.
### License ### License

View File

@ -31,7 +31,7 @@
]; ];
shellHook = '' shellHook = ''
echo "chase-rs development shell" echo "query-engine development shell"
echo "Rust: $(rustc --version)" echo "Rust: $(rustc --version)"
''; '';

View File

@ -2,7 +2,8 @@
//! //!
//! The current codebase primarily contains a chase-based reasoning core plus //! The current codebase primarily contains a chase-based reasoning core plus
//! lightweight frontends for experimenting with rule-driven query answering. //! lightweight frontends for experimenting with rule-driven query answering.
//! It is not yet a full SQL engine with logical and physical planning layers. //! It also contains an early relational and SQL scaffold for a narrow
//! single-table `SELECT-FROM-WHERE` slice. It is not yet a full SQL engine.
pub mod catalog; pub mod catalog;
pub mod chase; pub mod chase;