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, fuzzy matching, vector TopK search, and float16 embedding storage
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: ApexBase 1.23.0, 1M-row tabular dataset, 1M-vector dataset, Apple arm, Python 3.12.

Area Snapshot
Fair OLAP + OLTP comparison 72 public tabular metrics tracked; ApexBase wins 71 / 72 in the benchmark harness
GROUP BY city 2.3x faster than DuckDB in the representative snapshot
FTS search 170.2x faster than SQLite in the representative snapshot
Batch vector TopK cosine 10.7x 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 and Float16 Vectors
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.27.0.tar.gz (1.4 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.27.0-cp313-cp313-win_amd64.whl (10.5 MB view details)

Uploaded CPython 3.13Windows x86-64

apexbase-1.27.0-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (10.2 MB view details)

Uploaded CPython 3.13manylinux: glibc 2.17+ x86-64

apexbase-1.27.0-cp313-cp313-macosx_11_0_arm64.whl (9.1 MB view details)

Uploaded CPython 3.13macOS 11.0+ ARM64

apexbase-1.27.0-cp312-cp312-win_amd64.whl (10.5 MB view details)

Uploaded CPython 3.12Windows x86-64

apexbase-1.27.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (10.2 MB view details)

Uploaded CPython 3.12manylinux: glibc 2.17+ x86-64

apexbase-1.27.0-cp312-cp312-macosx_11_0_arm64.whl (9.1 MB view details)

Uploaded CPython 3.12macOS 11.0+ ARM64

apexbase-1.27.0-cp311-cp311-win_amd64.whl (10.5 MB view details)

Uploaded CPython 3.11Windows x86-64

apexbase-1.27.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (10.2 MB view details)

Uploaded CPython 3.11manylinux: glibc 2.17+ x86-64

apexbase-1.27.0-cp311-cp311-macosx_11_0_arm64.whl (9.1 MB view details)

Uploaded CPython 3.11macOS 11.0+ ARM64

apexbase-1.27.0-cp310-cp310-win_amd64.whl (10.5 MB view details)

Uploaded CPython 3.10Windows x86-64

apexbase-1.27.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (10.2 MB view details)

Uploaded CPython 3.10manylinux: glibc 2.17+ x86-64

apexbase-1.27.0-cp310-cp310-macosx_11_0_arm64.whl (9.1 MB view details)

Uploaded CPython 3.10macOS 11.0+ ARM64

apexbase-1.27.0-cp39-cp39-win_amd64.whl (10.5 MB view details)

Uploaded CPython 3.9Windows x86-64

apexbase-1.27.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (10.2 MB view details)

Uploaded CPython 3.9manylinux: glibc 2.17+ x86-64

apexbase-1.27.0-cp39-cp39-macosx_11_0_arm64.whl (9.1 MB view details)

Uploaded CPython 3.9macOS 11.0+ ARM64

File details

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

File metadata

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

File hashes

Hashes for apexbase-1.27.0.tar.gz
Algorithm Hash digest
SHA256 a277424e55fe7674ea211ed369d7b3cf6cdf95f16be0e4493f70bc2654008fe8
MD5 0d05b3488148dfa2192985b06ed84cac
BLAKE2b-256 392478f7b1748227a6f7866d8e4d366424a062459770fd1260956d0125984556

See more details on using hashes here.

File details

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

File metadata

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

File hashes

Hashes for apexbase-1.27.0-cp313-cp313-win_amd64.whl
Algorithm Hash digest
SHA256 1c8a85b120fa8e23447fd35cc45109833c2cb9c5e0f2d451c9b825bdda6db7de
MD5 fa70a4642f0132d3793b4dd56472e3e2
BLAKE2b-256 a7045821b5936f9592d65b339d8ca394500b9d203b56d0178acff4487d2bebb5

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for apexbase-1.27.0-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 090fb195134378130df2d8bc0eaa7137dc4284837fd3931337372846511a5773
MD5 efa626703ce6d81f7c61f6f5259d531a
BLAKE2b-256 7734944943e033ba088ec1f53f9731462caaad882a811e0f87f2d0428f30692e

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for apexbase-1.27.0-cp313-cp313-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 9649737ec1c61ab41742f6ab43a5ce47d26b3bbc6977ae5833b6365a03995c28
MD5 f76e93368354c1e3de9e5e9b418efa9a
BLAKE2b-256 4cb08123a26d423b2bc83db4dae2609d8d93dd2a12ec09b915520d7aeeebd6d2

See more details on using hashes here.

File details

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

File metadata

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

File hashes

Hashes for apexbase-1.27.0-cp312-cp312-win_amd64.whl
Algorithm Hash digest
SHA256 6a4d686c38817a177173273b092f13c4cd4e74edf481132f9bbbb34774e299b3
MD5 3d200c397c32985d0eb72368d6c59574
BLAKE2b-256 60cbfe3429e9fa46ef3c1a53daaae0828c16f86704da5a902424a5102216b4c1

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for apexbase-1.27.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 dac3776d5d2a752406759dccbe54b6823865b91c7d71db989c10dc392df48ac1
MD5 dd10e3c3d6b6f927d70e93ea5e5019c4
BLAKE2b-256 f550a7a1d2aa2a1844938b8ed8fdd9c3bb9c23efb9bc3a9c0d3dbdcd4ce69412

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for apexbase-1.27.0-cp312-cp312-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 4503b41397ab0cb13fa6daef478cca528b121a9b61bd68fd9a11d12ba25c5afd
MD5 bf6de61949622d4206cd1cf25c42efa2
BLAKE2b-256 1fb65d19a1070d7504340ad51da0fe536ceb524b5c4d84034e57771cbce0272c

See more details on using hashes here.

File details

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

File metadata

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

File hashes

Hashes for apexbase-1.27.0-cp311-cp311-win_amd64.whl
Algorithm Hash digest
SHA256 98def65fa3bf85df134169d9e3fea2c30d837b1432ed05de94492c5dc1f8126c
MD5 f638cf04681abafcbb4297e0331f1578
BLAKE2b-256 fa84301ce633eb0d28847e6173e02af2d6ca102aaab461d57e87851a0ccbe270

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for apexbase-1.27.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 ce65d9fef5ce02c8f82e8f1d81663dc42785344ce50c7efa3ecd446ea3f157ab
MD5 f72a1a034804cf310f9f871ee1b0ea52
BLAKE2b-256 942b38495ee669eb3021a2cdaa402d942b09f793e041d616538c61517bf97564

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for apexbase-1.27.0-cp311-cp311-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 df408c8e7a314ed61938a83bccb3babf9678a6658ac4d9b203ac331cba25d7f8
MD5 bd2038afc1b5f6c91c068e2d28d2febd
BLAKE2b-256 3dbe3d47be58b08120813ecea67c64cc649f4e47912085c22cd472ccdd9aefb4

See more details on using hashes here.

File details

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

File metadata

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

File hashes

Hashes for apexbase-1.27.0-cp310-cp310-win_amd64.whl
Algorithm Hash digest
SHA256 93cf04353601052b4f49a1809a324dd8908231df604474eae0569d090df78367
MD5 4b89f9b16085c8ac2d73e056bb58246a
BLAKE2b-256 637939964a51fed2673e324fbaf4f1e759161ba753f1f88c9b51c0107fed62b4

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for apexbase-1.27.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 72e5db2e023ac787641dbdccfb6e22f6bd29b1927fa361230f6e219f4eb3ddd2
MD5 9baa8491ebe57ad9930c080307fd5c06
BLAKE2b-256 32172e4aa315544a66b18c8c147bfa277bfe5ed8447ad7221519e4f9f487c109

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for apexbase-1.27.0-cp310-cp310-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 203bcd5d64b9f5a0131ca9e129ddbb82886a3f36880e2e4f562a840175417303
MD5 29ec1a1544d8ae1b215095092d7994b2
BLAKE2b-256 084ecf36af34738c334a1d87f369683be4d24c13010efc7bc81ae6166528827c

See more details on using hashes here.

File details

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

File metadata

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

File hashes

Hashes for apexbase-1.27.0-cp39-cp39-win_amd64.whl
Algorithm Hash digest
SHA256 6c7027e28cdcb7e5672a07baa775623354649cb0e4bcf697637ecafe72960ae8
MD5 2f50377c6746c904a1f803ecc4af21e3
BLAKE2b-256 867d8c92fe53eff74aebd9cc83e2a263887e5f0df29e73fe0fc81a371efff00c

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for apexbase-1.27.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 ed9ce80543fd03c208a1ae2f355a3b1f6a34f9ee9c798282f6bcf641caa458b3
MD5 be17799793e445b1e69e13e2b7a23df0
BLAKE2b-256 df8e87b9a767d691868560af6ca4a3007655e7422f9987c91db4d873ef25e219

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for apexbase-1.27.0-cp39-cp39-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 300f66f9dc594ff84a77edc4c590dbea9accac0a7430e1170062aca6b28ec636
MD5 680b3a070b3c025696b9b859aa4b63cc
BLAKE2b-256 b78f41ccbb2e119640a35554be90e8af0820131d28429af75ac6db387ca45e84

See more details on using hashes here.

Release history Release notifications | RSS feed

1.30.0

16 files

1.29.0

16 files

1.28.0

16 files

This release

1.27.0 This release

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