Skip to main content

Documentation Index

Fetch the complete documentation index at: https://astron-bb4261fd.mintlify.app/llms.txt

Use this file to discover all available pages before exploring further.

Test Environment

  • Hardware: Apple M-series (Rosetta 2 emulation for PostgreSQL)
  • PostgreSQL: 17.x with pgvector 0.8.x
  • Embedding dimensions: 1536 (text-embedding-3-small)
  • Note: All timings include Rosetta overhead. Native ARM builds are estimated 30-40% faster.

HNSW Vector Search Performance

Semantic recall latency using HNSW index (m=16, ef_construction=128, ef_search=64):
Dataset Sizep50 Latencyp95 Latencyp99 LatencyRecall@10
10,000 memories1.8 ms3.2 ms4.1 ms0.98
50,000 memories2.9 ms5.1 ms6.8 ms0.97
100,000 memories4.2 ms7.3 ms9.5 ms0.96

Native ARM Estimates

Dataset Sizep50 (est.)p95 (est.)
10,000 memories~1.1 ms~2.0 ms
50,000 memories~1.8 ms~3.1 ms
100,000 memories~2.5 ms~4.4 ms

IVFFlat vs HNSW Comparison

Tested at 100K memories with top_k=10:
MetricIVFFlat (nlist=100, nprobe=10)HNSW (m=16, ef=64)
p50 latency6.1 ms4.2 ms
p95 latency11.4 ms7.3 ms
Recall@100.910.96
Index build time12.3 s45.7 s
Index size on disk234 MB312 MB
Incremental insertRequires retrainImmediate
Decision: HNSW chosen for production. The higher recall and no-retrain property outweigh the larger index size and slower initial build.

Audit Log Performance

Append-only audit table with BRIN index on created_at:
Table SizeInsert (p50)Range Query 24h (p50)Range Query 7d (p50)
100K rows0.3 ms1.2 ms3.8 ms
1M rows0.3 ms1.4 ms5.1 ms
10M rows0.4 ms1.9 ms8.7 ms
Insert latency remains constant due to append-only writes. BRIN indexing keeps range scans efficient even at 10M+ rows.

Store Operation (End-to-End)

Full store including embedding generation, DB insert, and graph edge creation:
ComponentTime
Embedding API call80-150 ms
DB insert (memory + audit)1.2 ms
Graph edge creation0.8 ms
Total~85-155 ms
Embedding generation dominates. With local embeddings (e.g., ONNX), total drops to ~5 ms.

Test Suite Results

Phase 1 + Phase 2 combined test run:
========================= test session starts =========================
collected 646 items

tests/unit/          ... 412 passed
tests/integration/   ... 189 passed
tests/performance/   ... 45 passed

================ 646 passed, 0 failed, 0 warnings ================

Total time: 127.4s
CategoryTestsPass Rate
Unit tests412100%
Integration tests189100%
Performance tests45100%
Total646100%

Rosetta Overhead Note

All benchmarks were collected on Apple Silicon under Rosetta 2 emulation (x86_64 PostgreSQL binary). Based on comparison testing:
  • CPU-bound operations (embedding similarity computation): ~35% overhead
  • I/O-bound operations (disk reads, network): ~5-10% overhead
  • Mixed workloads (typical Z3rno queries): ~20-30% overhead
Production deployments on native x86_64 or native ARM PostgreSQL builds should see proportionally better numbers. The benchmarks above represent conservative worst-case estimates.