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.22.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.22.0.tar.gz (1.3 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.22.0-cp313-cp313-win_amd64.whl (9.9 MB view details)

Uploaded CPython 3.13Windows x86-64

apexbase-1.22.0-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (9.5 MB view details)

Uploaded CPython 3.13manylinux: glibc 2.17+ x86-64

apexbase-1.22.0-cp313-cp313-macosx_11_0_arm64.whl (8.6 MB view details)

Uploaded CPython 3.13macOS 11.0+ ARM64

apexbase-1.22.0-cp312-cp312-win_amd64.whl (9.9 MB view details)

Uploaded CPython 3.12Windows x86-64

apexbase-1.22.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (9.5 MB view details)

Uploaded CPython 3.12manylinux: glibc 2.17+ x86-64

apexbase-1.22.0-cp312-cp312-macosx_11_0_arm64.whl (8.6 MB view details)

Uploaded CPython 3.12macOS 11.0+ ARM64

apexbase-1.22.0-cp311-cp311-win_amd64.whl (9.9 MB view details)

Uploaded CPython 3.11Windows x86-64

apexbase-1.22.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (9.5 MB view details)

Uploaded CPython 3.11manylinux: glibc 2.17+ x86-64

apexbase-1.22.0-cp311-cp311-macosx_11_0_arm64.whl (8.6 MB view details)

Uploaded CPython 3.11macOS 11.0+ ARM64

apexbase-1.22.0-cp310-cp310-win_amd64.whl (9.9 MB view details)

Uploaded CPython 3.10Windows x86-64

apexbase-1.22.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (9.5 MB view details)

Uploaded CPython 3.10manylinux: glibc 2.17+ x86-64

apexbase-1.22.0-cp310-cp310-macosx_11_0_arm64.whl (8.6 MB view details)

Uploaded CPython 3.10macOS 11.0+ ARM64

apexbase-1.22.0-cp39-cp39-win_amd64.whl (9.9 MB view details)

Uploaded CPython 3.9Windows x86-64

apexbase-1.22.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (9.5 MB view details)

Uploaded CPython 3.9manylinux: glibc 2.17+ x86-64

apexbase-1.22.0-cp39-cp39-macosx_11_0_arm64.whl (8.6 MB view details)

Uploaded CPython 3.9macOS 11.0+ ARM64

File details

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

File metadata

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

File hashes

Hashes for apexbase-1.22.0.tar.gz
Algorithm Hash digest
SHA256 b62c5bf53cec4b71602bd81101ac12cc2851d2e8007eb752690e8f35857d6b09
MD5 8c42299ec2ffabfb5de1116f5242c692
BLAKE2b-256 ae0614a36d958456ac504e6deeb59b624674bce2a67f3408ef4ed7fe53d51f84

See more details on using hashes here.

File details

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

File metadata

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

File hashes

Hashes for apexbase-1.22.0-cp313-cp313-win_amd64.whl
Algorithm Hash digest
SHA256 e8e1955ec0a0ea835314f7c27b2d87ac51c87235426877d3ab826d1630a25fc4
MD5 6a45232587b9294f882a12394fdc8738
BLAKE2b-256 5980d242a425603ba81442f16ba76a89fe40fe6e5c8f20fb842ea80e9278213b

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for apexbase-1.22.0-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 c19eba53ef4e524df403ae44642d6e63b31bde692e1bc00139f45f0bdaae3c49
MD5 99134944e48aee9ae2244d57467bd45f
BLAKE2b-256 1047511e67ccf08863f0f2d6cb182aacec8376c80b127c62a86662ff85a00802

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for apexbase-1.22.0-cp313-cp313-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 bbe7b2aeca29bbeb329cd859776279d6154ab12feabc375c60d2b9ea9ebd4cf9
MD5 9c157fbd42e01c414de9a6abad69eb1f
BLAKE2b-256 2cd23ec0c1eb016f893ff1fbc37ebaa3ffeb964f37e7e09c2f07800f9a0c251c

See more details on using hashes here.

File details

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

File metadata

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

File hashes

Hashes for apexbase-1.22.0-cp312-cp312-win_amd64.whl
Algorithm Hash digest
SHA256 f1ff22bade260f70921b6c95abea69b5cbcd0eb8393a5695bc39fc973fb9ed4b
MD5 54b579e750631ee86f2e91671306544c
BLAKE2b-256 e5d7bfd168042270a31c8d34cd9208d5d80914498de08d1a734e266ebe052d8c

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for apexbase-1.22.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 8c209997b210524eb7caaf8f0d72b17239bef963f7e8583d99dd8fb833e35845
MD5 ae51600b70303e524f534fde2589b175
BLAKE2b-256 1f160e7ba77f29f6e2680fbdf48250a9b6832df791fc2ba5984ca258f1307a6a

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for apexbase-1.22.0-cp312-cp312-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 20322b1cb412b60c2214a3205947bfc55e18c9b65300fc63032b9d57051d6423
MD5 c5a5440247a809f0a15f96c27ad4d6e2
BLAKE2b-256 67b48049daf74d3bfbba22071e74aa7d47ad9cff516200650d82c727b3d49759

See more details on using hashes here.

File details

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

File metadata

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

File hashes

Hashes for apexbase-1.22.0-cp311-cp311-win_amd64.whl
Algorithm Hash digest
SHA256 fdf865c180efd4284846ab9e029329a730f54f4058e23038e0ca8c26ef9a0f5e
MD5 34f777cb8ad379c2052bf42782f38a1c
BLAKE2b-256 74d7e5b15c62fb19c5e9bd840841cc6ebe88116b86e1e6774042ff6f1d5c4c9e

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for apexbase-1.22.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 22202c9605d8e4e50fc239a5867b38503981ce364607306b54e6b4ebc6fe2ae8
MD5 309dfa34e6f0843137a5ef0d051dca97
BLAKE2b-256 2e6851ebff901c3980895fe0af8fc4cb46bddf425b1bec97e8c2d3f2af6a57ba

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for apexbase-1.22.0-cp311-cp311-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 c78ac031eafa5bbd7c83c0353d43784cca9aa46dfa09f3242a8f6703d76efd58
MD5 ea8e81d949e199a9da2b96bd48d6bba4
BLAKE2b-256 b76c14a883fe71801ee3c44c2d865910db5dd1289d46d34e73e67dccab332441

See more details on using hashes here.

File details

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

File metadata

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

File hashes

Hashes for apexbase-1.22.0-cp310-cp310-win_amd64.whl
Algorithm Hash digest
SHA256 c47766031a418b434d32b52ab5f5ca53d87d42aafb0fcdf41995df71e2422b7a
MD5 6e8ec9257d14265545382667da4f8b87
BLAKE2b-256 41e80e69bcacd80d864222922e80a020173b68219bed3fbbfe923b4341f6e281

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for apexbase-1.22.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 f4c88fd0f18e94a87f48b7882fe15e4eb42b0e769651e65087b6c133ea3d858a
MD5 2339d9bb19ffc0df020f436b0be5a20f
BLAKE2b-256 1d59abbddd023d7cde8cf6fbff52858c5545f2b2c46163e2447f1cde2caec7b7

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for apexbase-1.22.0-cp310-cp310-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 bb1d070ad53910ecb0f7894b7d23ea64295e3e81660ad166b5eaf576d3b907d0
MD5 35a4d850e2a7d21fd68cce115ea02116
BLAKE2b-256 657a808ccb365f5095759390f35dc2a576e3bf6b0812e5353341574c260827bf

See more details on using hashes here.

File details

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

File metadata

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

File hashes

Hashes for apexbase-1.22.0-cp39-cp39-win_amd64.whl
Algorithm Hash digest
SHA256 9348611767f815136742f3b90a1ca5d1c060327cc77d3ea41c05ff8dd78bab73
MD5 26d2208c580657999613f958b7027c9c
BLAKE2b-256 8d13e8427fd3db33e9cb4c7c83d6e59734efe428e4713638b71af2f07bf94f30

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for apexbase-1.22.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 5fc78ae975fb3f6f11a230e4e4086748afd387c6308b8fcf71d3a16c724c86f4
MD5 e6641e6f54deccb58e8ba22e9074b527
BLAKE2b-256 0fcf780c84b403a3adb69be4e72495218f2c964992e9f1f2f762c5dfa4a4e400

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for apexbase-1.22.0-cp39-cp39-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 d5550e6818bf0ac3fe24c70389c4261dabadaaf364fcab751caf4915d0ca446a
MD5 b278670f2f3a0c5e359fb5fd1e259619
BLAKE2b-256 40ea3b83e06431bb0ef720eb0b0d5251823dd31473a9b25b2772044f771f5443

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

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

This release

1.22.0 This release

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