Skip to main content

ApexBase



PyPI Python License

ApexBase is a high-performance embedded HTAP database with a Rust core and a Python-first API.

Install it, write local .apex table files, run analytical SQL, import/export DataFrames, and optionally expose the same data through PostgreSQL Wire or Arrow Flight. No separate database service is required.

Why ApexBase

What you need What ApexBase gives you
Fast local analytics Columnar storage, vectorized execution, SQL aggregations, joins, CTEs, windows, and indexes
Low-friction Python workflows ApexClient, Pandas / Polars / PyArrow conversion, file table functions, and simple local persistence
One engine for mixed workloads HTAP design: fast writes, point lookups, analytical scans, transactions, and MVCC
Search built in Full-text search, vector TopK, Float16/BFloat16/Int8/UInt8/1Bit/TurboQuant storage, and exact reranking from a retained source vector
Tool compatibility PostgreSQL Wire for database clients and Arrow Flight for fast columnar transfer

Install

pip install apexbase

Build from source:

python -m pip install maturin
maturin develop --release

30-Second Example: FTS + SQL + Vector Search In One Local File

from apexbase import ApexClient

with ApexClient("./rag-data") as client:
    client.execute("""
        CREATE TABLE articles (
            title TEXT,
            body TEXT,
            category TEXT,
            views INT,
            embedding FLOAT16_VECTOR
        )
    """)
    client.use_table("articles")

    client.store([
        {
            "title": "Rust-powered local analytics",
            "body": "A columnar embedded database for fast SQL and search.",
            "category": "database",
            "views": 4200,
            "embedding": [0.10, 0.82, 0.20],
        },
        {
            "title": "Hybrid retrieval for RAG",
            "body": "Combine full-text recall, SQL filters, and semantic vector ranking.",
            "category": "ai",
            "views": 6100,
            "embedding": [0.16, 0.74, 0.58],
        },
        {
            "title": "SQLite migration notes",
            "body": "Move local applications to an analytical embedded store.",
            "category": "database",
            "views": 2600,
            "embedding": [0.80, 0.12, 0.10],
        },
    ])

    client.execute("CREATE FTS INDEX ON articles(title, body)")

    # FTS recall + structured SQL guardrails + pgvector-style semantic rerank.
    df = client.execute("""
        SELECT
            title,
            category,
            views,
            cosine_distance(embedding, [0.12, 0.78, 0.25]) AS semantic_dist
        FROM articles
        WHERE MATCH('database')
          AND category = 'database'
          AND views > 3000
        ORDER BY semantic_dist
        LIMIT 5
    """).to_pandas()

    print(df)

ApexBase gives you pgvector-style semantic search, SQL filters, and full-text search in the same embedded database file. It is the kind of stack you would otherwise assemble from SQLite/DuckDB + FTS + pgvector, but without a server process or a separate search/vector service; results still convert directly to Pandas, Polars, or Arrow.

Performance At A Glance

Latest local snapshot (2026-08-15): ApexBase 1.29.0, 1M-row tabular dataset, 1M-vector dataset, Apple arm, Python 3.12.

Area Snapshot
Fair OLAP + OLTP comparison 102 public tabular metrics tracked; ApexBase wins 87 / 102 in the benchmark harness. The remaining losses are the DDL gaps vs SQLite (Table DROP, Table CREATE+DROP cycle, ALTER TABLE ADD COLUMN, 1.3x–2.0x) and a dozen advanced-SQL metrics vs DuckDB at 1.2x–2.0x, plus NOT filter (4.6x) and ORDER BY LENGTH(...) (3.9x) as the two remaining larger gaps — down from the 1.5x–75x these metrics previously showed.
GROUP BY city 2.0x faster than DuckDB in the representative snapshot
FTS search 5.6x faster than SQLite in the representative snapshot
Batch vector TopK cosine 7.1x faster than DuckDB in the representative snapshot

Benchmarks are workload-sensitive. The default benchmark command tracks this public scoreboard; extended diagnostics live in benchmarks/bench_vs_sqlite_duckdb_extended.py. See the full reproducible setup in the Performance documentation.

Documentation

Start here: https://birchkwok.github.io/apexbase/

Goal Page
Get running quickly Installation and Quick Start
Understand the model Core Concepts
Use the Python API Python Client Guide and API Reference
Write SQL SQL Guide
Import files and DataFrames Data Import
Use database tools or Arrow clients Server Protocols
Search text or vectors Full-Text Search, Float16 Vectors, and Vector Quantization
Embed from Rust Rust Embedded API

Interfaces

# Embedded Python
python -c "from apexbase import ApexClient; print(ApexClient)"

# PostgreSQL Wire + Arrow Flight together
apexbase-serve --dir ./data

# Individual protocol servers
apexbase-server --dir ./data --port 5432
apexbase-flight --dir ./data --port 50051

Lance Interop

from apexbase import ApexClient

with ApexClient("./data") as client:
    client.use_table("articles")
    client.to_lance("./articles.lance")

with ApexClient("./imported") as client:
    client.from_lance("./articles.lance", table_name="articles")

Lance conversion uses Arrow tables as the handoff path. This keeps the in-process conversion lean and Arrow-native, while each format still writes its own on-disk layout.

License

Apache-2.0

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

apexbase-1.31.0.tar.gz (1.6 MB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

apexbase-1.31.0-cp313-cp313-win_amd64.whl (11.1 MB view details)

Uploaded CPython 3.13Windows x86-64

apexbase-1.31.0-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (10.7 MB view details)

Uploaded CPython 3.13manylinux: glibc 2.17+ x86-64

apexbase-1.31.0-cp313-cp313-macosx_11_0_arm64.whl (9.5 MB view details)

Uploaded CPython 3.13macOS 11.0+ ARM64

apexbase-1.31.0-cp312-cp312-win_amd64.whl (11.1 MB view details)

Uploaded CPython 3.12Windows x86-64

apexbase-1.31.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (10.7 MB view details)

Uploaded CPython 3.12manylinux: glibc 2.17+ x86-64

apexbase-1.31.0-cp312-cp312-macosx_11_0_arm64.whl (9.5 MB view details)

Uploaded CPython 3.12macOS 11.0+ ARM64

apexbase-1.31.0-cp311-cp311-win_amd64.whl (11.1 MB view details)

Uploaded CPython 3.11Windows x86-64

apexbase-1.31.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (10.7 MB view details)

Uploaded CPython 3.11manylinux: glibc 2.17+ x86-64

apexbase-1.31.0-cp311-cp311-macosx_11_0_arm64.whl (9.5 MB view details)

Uploaded CPython 3.11macOS 11.0+ ARM64

apexbase-1.31.0-cp310-cp310-win_amd64.whl (11.1 MB view details)

Uploaded CPython 3.10Windows x86-64

apexbase-1.31.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (10.7 MB view details)

Uploaded CPython 3.10manylinux: glibc 2.17+ x86-64

apexbase-1.31.0-cp310-cp310-macosx_11_0_arm64.whl (9.5 MB view details)

Uploaded CPython 3.10macOS 11.0+ ARM64

apexbase-1.31.0-cp39-cp39-win_amd64.whl (11.1 MB view details)

Uploaded CPython 3.9Windows x86-64

apexbase-1.31.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (10.7 MB view details)

Uploaded CPython 3.9manylinux: glibc 2.17+ x86-64

apexbase-1.31.0-cp39-cp39-macosx_11_0_arm64.whl (9.5 MB view details)

Uploaded CPython 3.9macOS 11.0+ ARM64

File details

Details for the file apexbase-1.31.0.tar.gz.

File metadata

  • Download URL: apexbase-1.31.0.tar.gz
  • Upload date:
  • Size: 1.6 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.11.16

File hashes

Hashes for apexbase-1.31.0.tar.gz
Algorithm Hash digest
SHA256 86307999cf5247e19777e95d5680fa0cbbe8c40b405a9802929836b76daf8cbd
MD5 6b7329719345809cca9af669654057a4
BLAKE2b-256 1549d27c3b0490fb01b0c322b879e0f6a46b3a1b03400609f895e6a12577dd58

See more details on using hashes here.

File details

Details for the file apexbase-1.31.0-cp313-cp313-win_amd64.whl.

File metadata

  • Download URL: apexbase-1.31.0-cp313-cp313-win_amd64.whl
  • Upload date:
  • Size: 11.1 MB
  • Tags: CPython 3.13, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.11.16

File hashes

Hashes for apexbase-1.31.0-cp313-cp313-win_amd64.whl
Algorithm Hash digest
SHA256 3f8c0599cf3226b6b0e005ed310f4067cd0bb51b7c5df7c7d76bc2cac9947b18
MD5 8c02c476dd063063b2e69233756466ad
BLAKE2b-256 af37517b0ae5481dc80c7965825a6baba5f51b30a68d577b4615e549da356f75

See more details on using hashes here.

File details

Details for the file apexbase-1.31.0-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for apexbase-1.31.0-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 233f64b3fd79abca6891c3f4247c40924c7ad9eea12b3d80a3ef3e1d2e2c7c6b
MD5 168e8fbd74ed293f3bc3e45d9eca40be
BLAKE2b-256 d84dd1f16c716a13d46c7fd4254b01b410608ad16d90a97594a846f9cc576651

See more details on using hashes here.

File details

Details for the file apexbase-1.31.0-cp313-cp313-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for apexbase-1.31.0-cp313-cp313-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 ef723c1c3c59bbacef16a84059f5770abeeb1254da44e7d1699c4a21570f82bf
MD5 1ad8d87f606f3c746020d5849d03b2bd
BLAKE2b-256 e45c1062cadd2e4f6f21903f8979e1c2b9ca125842c4d0e41a1f2ff445c246e2

See more details on using hashes here.

File details

Details for the file apexbase-1.31.0-cp312-cp312-win_amd64.whl.

File metadata

  • Download URL: apexbase-1.31.0-cp312-cp312-win_amd64.whl
  • Upload date:
  • Size: 11.1 MB
  • Tags: CPython 3.12, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.11.16

File hashes

Hashes for apexbase-1.31.0-cp312-cp312-win_amd64.whl
Algorithm Hash digest
SHA256 3286ac953f7c2a0fc09f03f0b03d84549594bbe1bf280ee430f432aee14e85f4
MD5 4e4522fa316df0922c0b0f0d9af42d34
BLAKE2b-256 822070f2d5bcae19c85ba2f2f53ef7f2e8f616c96eb4c3bb4b53dfe62de19ab6

See more details on using hashes here.

File details

Details for the file apexbase-1.31.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for apexbase-1.31.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 256f244f86bea2f2c9b33b232dcbe595968130ae2ee658e94b9bf48bd366fc6a
MD5 e7120774b4131b9a501b7876f79a9dbe
BLAKE2b-256 d86ee7b1c198ffb8a8cd694d451cdd42f1cfc72b953c421ebb0da2953c3955ed

See more details on using hashes here.

File details

Details for the file apexbase-1.31.0-cp312-cp312-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for apexbase-1.31.0-cp312-cp312-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 85094150d3d82dd007054f487a247b48eda06ebfafe49da0095fbf4b56e0dd50
MD5 a46add7868dee29b625531e5877d6698
BLAKE2b-256 cf33d29978963288da282d773177d5884957cb06c3c2101a298f04f095f53333

See more details on using hashes here.

File details

Details for the file apexbase-1.31.0-cp311-cp311-win_amd64.whl.

File metadata

  • Download URL: apexbase-1.31.0-cp311-cp311-win_amd64.whl
  • Upload date:
  • Size: 11.1 MB
  • Tags: CPython 3.11, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.11.16

File hashes

Hashes for apexbase-1.31.0-cp311-cp311-win_amd64.whl
Algorithm Hash digest
SHA256 e85ef6996988bdc950457a4423de818da3153db28a3d760b5c1c15ea1cc98532
MD5 e258609eaf54f18c7eff65efeba37acf
BLAKE2b-256 0ff65bece41f8d64a4a7b10cfa22831a0958306402db558823d68dd94681318b

See more details on using hashes here.

File details

Details for the file apexbase-1.31.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for apexbase-1.31.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 232e0e8984a89458d5b04539f378d8e3fbccd965c3435e6eec91a3fdb90e5f1f
MD5 f08d933ecfd4856f5b82590c7a0af11d
BLAKE2b-256 0da5f2a2953d298997ce39f5b21b1475b64132825f3bf13549a1b6d92c7a509d

See more details on using hashes here.

File details

Details for the file apexbase-1.31.0-cp311-cp311-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for apexbase-1.31.0-cp311-cp311-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 05378528371d29582f52f34209efd451f2a663aef139cedcae00a40f6b5bced2
MD5 5a372f72e971d37bbcb4868cb9b8d7cc
BLAKE2b-256 5f27101f4cbf94204510ec0adb0fee9020f7961071a8782438241cfa83097024

See more details on using hashes here.

File details

Details for the file apexbase-1.31.0-cp310-cp310-win_amd64.whl.

File metadata

  • Download URL: apexbase-1.31.0-cp310-cp310-win_amd64.whl
  • Upload date:
  • Size: 11.1 MB
  • Tags: CPython 3.10, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.11.16

File hashes

Hashes for apexbase-1.31.0-cp310-cp310-win_amd64.whl
Algorithm Hash digest
SHA256 19b13251151ede239453b79092ed415b103a041c78ec526678bf44b1dec48814
MD5 bf23d78ff59705e5094d8ffbd5e56e4f
BLAKE2b-256 a89ccf974be24305361cca10486f72a21771e6f96debace285fc794d34215f3e

See more details on using hashes here.

File details

Details for the file apexbase-1.31.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for apexbase-1.31.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 dd3e0b1044159f9ee5258e283c3e0ecbe292ed55fa950c88773c2ee4e24b0925
MD5 9d8a8c2d956c17c5174c0f2c7feac5aa
BLAKE2b-256 f199b9841038a9eba5067497e29506f1b59e36d4eb4e7c3eebede85c6d021236

See more details on using hashes here.

File details

Details for the file apexbase-1.31.0-cp310-cp310-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for apexbase-1.31.0-cp310-cp310-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 56b6d86e30a0c23bde8907f1b64f8b08f6aec89dc176cc9ad9504add53f7c930
MD5 9a627fd6e5df5b4f204dad5e6d5f7f14
BLAKE2b-256 7e8ab32fcfc7b4aede3a042ba8c9338b86bd17c07173e4603aa6d12db2d105d2

See more details on using hashes here.

File details

Details for the file apexbase-1.31.0-cp39-cp39-win_amd64.whl.

File metadata

  • Download URL: apexbase-1.31.0-cp39-cp39-win_amd64.whl
  • Upload date:
  • Size: 11.1 MB
  • Tags: CPython 3.9, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.11.16

File hashes

Hashes for apexbase-1.31.0-cp39-cp39-win_amd64.whl
Algorithm Hash digest
SHA256 66e02a6c0341e49adb51a6d78d813d9516ae2a9ab5ea1d1365627e010488e28f
MD5 f04c796c7c83fa1b826e1421e2d94fb6
BLAKE2b-256 84c152f895622797864d98b5068810689899c8129dab0d112fd87f20a82ed102

See more details on using hashes here.

File details

Details for the file apexbase-1.31.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for apexbase-1.31.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 3c07998f77519a4578ea14cc129c83cf132829e264213c3b2f21263fd68a15f8
MD5 853be407508678649d74ae98befa9e2a
BLAKE2b-256 b3ef0e9fe39fd3259a7366c0496d4b08d6245ff2e764014430552ba04171f132

See more details on using hashes here.

File details

Details for the file apexbase-1.31.0-cp39-cp39-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for apexbase-1.31.0-cp39-cp39-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 a38608e9b7ca9e0d4ad9bb454e068ca4fcde210fba294a8d1a6fd897797dbe24
MD5 4ce23d834febbb63d0bc4c4a68edf619
BLAKE2b-256 7646d05a302d32b7ba4ce390051d52f16a5a44c1e5b2fbe619c0c21e63af2071

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

1.31.0 This release

16 files

1.30.0

16 files

1.29.0

16 files

1.28.0

16 files

1.27.0

16 files

1.26.0

16 files

1.25.0

16 files

1.24.0

16 files

1.23.0

16 files

1.22.0

16 files

1.21.0

16 files

1.20.1

16 files

1.20.0

16 files

1.19.1

16 files

1.19.0

16 files

1.18.0

16 files

1.17.0

16 files

1.16.0

16 files

1.15.0

16 files

1.14.0

16 files

1.13.0

16 files

1.12.0

16 files

1.11.0

16 files

1.10.0

16 files

1.9.0

16 files

1.8.0

16 files

1.7.0

16 files

1.6.0

16 files

1.5.0

16 files

1.4.0

16 files

1.3.0

16 files

1.2.0

16 files

1.1.0

16 files

1.0.0

16 files

0.6.0

16 files

0.5.0

16 files

0.4.2

16 files

0.4.0

16 files

0.3.0

16 files

0.2.3

16 files

0.2.2

12 files

0.2.1

2 files

0.2.0

1 file

0.1.0

2 files

0.0.2

2 files

0.0.1

2 files

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page