trustgraph/trustgraph-flow/trustgraph
Cyber MacGeddon 16aa9ae71d SPARQL engine: streaming evaluation, bind joins, and expression fixes
Convert the SPARQL algebra evaluator from eager list-based evaluation to
lazy async generators so results stream incrementally. This lets Slice
terminate early (via generator cleanup) and avoids materialising full
result sets for streamable operators like Project, Filter, Union, and
Extend. Blocking operators (Join, LeftJoin, OrderBy, Group) materialise
at their boundary then yield.

Add bind join optimization for Join nodes where one side is small
(VALUES/ToMultiSet): instead of materialising both sides independently
and hash-joining, iterate the small side's bindings and evaluate the
large side with those bindings pre-seeded. This turns wildcard BGP
queries into selective ones — e.g. VALUES ?x { <uri> } joined with a
BGP now queries the triple store with ?x bound rather than fetching
all triples.

Add TriplesClient.query_gen() async generator that wraps the existing
streaming callback API via an asyncio.Queue bridge, yielding individual
Triple objects as batches arrive.

Add streaming request path in the SPARQL query service that batches
solutions from the live async generator and sends them as they fill.

Fix FILTER IN/NOT IN: rdflib represents these as RelationalExpression
nodes with op="IN", not as Builtin_IN — handle both representations.

Fix Builtin_IN/Builtin_NOTIN dispatch ordering so the specific handlers
are checked before the generic Builtin_ prefix match.

Fix VALUES handling for rdflib's two representations: positional
(var/value) and dict-based (res).
2026-05-21 15:48:25 +01:00
..
agent Per-flow librarian clients and per-workspace response queues (#865) 2026-05-06 12:01:01 +01:00
bootstrap fix: IAM bootstrap atomicity and bootstrapper startup ordering (#935) 2026-05-18 22:08:12 +01:00
chunking Per-flow librarian clients and per-workspace response queues (#865) 2026-05-06 12:01:01 +01:00
config/service Recent fixes -> release/v2.4 (#891) 2026-05-08 19:48:12 +01:00
cores CLI auth migration, document embeddings core lifecycle (#913) 2026-05-14 10:30:21 +01:00
decoding Per-flow librarian clients and per-workspace response queues (#865) 2026-05-06 12:01:01 +01:00
direct Make all Cassandra and Qdrant I/O async-safe with proper concurrency controls (#916) 2026-05-14 16:00:54 +01:00
embeddings Fix Ollama async issue (#854) 2026-04-28 15:43:04 +01:00
external Implement logging strategy (#444) 2025-07-30 23:18:38 +01:00
extract Fix ontology selector defaults, add bypass mode, enforce domain/range (#929) 2026-05-16 15:13:38 +01:00
flow Per-flow librarian clients and per-workspace response queues (#865) 2026-05-06 12:01:01 +01:00
gateway feat: add no-auth IAM regime as a drop-in replacement for iam-svc (#933) 2026-05-18 14:10:05 +01:00
iam fix: IAM bootstrap atomicity and bootstrapper startup ordering (#935) 2026-05-18 22:08:12 +01:00
librarian Recent fixes -> release/v2.4 (#891) 2026-05-08 19:48:12 +01:00
metering feat: workspace-based multi-tenancy, replacing user as tenancy axis (#840) 2026-04-21 23:23:01 +01:00
model Ensure retry exception is properly raised (#926) 2026-05-15 13:35:04 +01:00
processing Fix/startup failure (#445) 2025-07-30 23:42:11 +01:00
prompt feat: workspace-based multi-tenancy, replacing user as tenancy axis (#840) 2026-04-21 23:23:01 +01:00
query SPARQL engine: streaming evaluation, bind joins, and expression fixes 2026-05-21 15:48:25 +01:00
retrieval Fixed document-rag workspace problem (#866) 2026-05-06 14:55:21 +01:00
rev_gateway Update rev-gateway for IAM integration (#940) 2026-05-19 21:45:43 +01:00
storage Make all Cassandra and Qdrant I/O async-safe with proper concurrency controls (#916) 2026-05-14 16:00:54 +01:00
tables fix: IAM bootstrap atomicity and bootstrapper startup ordering (#935) 2026-05-18 22:08:12 +01:00
template Feature/prompts jsonl (#619) 2026-01-26 17:38:00 +00:00
tool_service feat: workspace-based multi-tenancy, replacing user as tenancy axis (#840) 2026-04-21 23:23:01 +01:00
__init__.py Feature/pkgsplit (#83) 2024-09-30 19:36:09 +01:00