trustgraph/tests/unit/test_cli
cybermaggedon 1740e315f4
feat: batch row imports and split index configuration (#1055)
Adds batching to structured data row imports. Previously each row was
sent as a separate WebSocket message, causing one embeddings service
call per row. The bulk import clients now accumulate rows into batches
(default 40) before sending, and the --batch-size CLI argument is
wired through from tg-load-structured-data to the import call.

Splits the schema "indexes" field into two separate configurations:
- "query-indexes": fields for Cassandra exact-match retrieval
- "vector-indexes": fields for vector embedding and semantic search

This avoids wasting compute embedding primary key integers that only
need exact lookup, while allowing each field to independently opt in
to either or both retrieval patterns.

Adds row_id (the primary key value) as a clustering column in the
Cassandra rows table so multiple rows sharing the same index value
no longer silently overwrite each other.

Tests updated for new Cassandra schema.
2026-07-22 10:20:06 +01:00
..
__init__.py Knowledge load utility CLI (#456) 2025-08-13 16:07:58 +01:00
conftest.py feat: export/import workspace knowledge in .tgx bundles (#877 Phase 2) (#1024) 2026-07-06 10:48:41 +01:00
test_config_commands.py feat: workspace-based multi-tenancy, replacing user as tenancy axis (#840) 2026-04-21 23:23:01 +01:00
test_error_handling_edge_cases.py feat: batch row imports and split index configuration (#1055) 2026-07-22 10:20:06 +01:00
test_load_knowledge.py feat: workspace-based multi-tenancy, replacing user as tenancy axis (#840) 2026-04-21 23:23:01 +01:00
test_load_structured_data.py Structured data, minor features (#500) 2025-09-05 17:25:12 +01:00
test_nquads.py feat: export/import workspace knowledge in .tgx bundles (#877 Phase 2) (#1024) 2026-07-06 10:48:41 +01:00
test_schema_descriptor_generation.py Structured data, minor features (#500) 2025-09-05 17:25:12 +01:00
test_tool_commands.py feat: workspace-based multi-tenancy, replacing user as tenancy axis (#840) 2026-04-21 23:23:01 +01:00
test_workspace_bundle_commands.py feat: export/import workspace knowledge in .tgx bundles (#877 Phase 2) (#1024) 2026-07-06 10:48:41 +01:00
test_xml_xpath_parsing.py Structured data, minor features (#500) 2025-09-05 17:25:12 +01:00