ahnlich

Library Listed

Suite of tools containing an in-memory vector datastore and AI proxy

Checked · Sources

Downloads
744
Dependents
0
Stars
249
Forks
30
Contributors
14
Commits
541
Latest release
0.4.5 ·

About

From the project README ·

ahnlich

⚠️ Note: Ahnlich continues to evolve rapidly, and while stable for most use cases, it may still receive occasional breaking updates as features improve.

"ähnlich" means similar in german. It comprises of multiple tools for usage and development such as:

  • ahnlich-db: In-memory vector key value store for storing embeddings/vectors with corresponding metadata(key-value maps). It's a powerful system which enables AI/ML engineers to store and search similar vectors using linear (cosine, euclidean) or non-linear similarity (hnsw) algorithms. It also leverages search within metadata values to be able to filter out entries using metadata values. A simple example can look like
GETSIMN 2 WITH [0.2, 0.1] USING cosinesimilarity IN my_store WHERE (page != hidden)

// example query
get_sim_n(
    store="my_store",
    search_input=[0.2, 0.1],
    closest_n=2,
    algorithm=CosineSimilarity,
    condition=Predicate::NotEquals{
      key="page",
      value="hidden",
  },
)
Read the full README
  • ahnlich-ai: AI proxy to communicate with ahnlich-db, receiving raw input, transforming into embeddings, and storing within the DB. It extends the capabilities by then allowing developers/engineers to issue queries to the same store using raw input such as images/text. It features multiple off-the-shelf models that can be selected for store index and query.
CREATESTORE my_store QUERYMODEL all-minilm-l6-v2 INDEXMODEL all-minilm-l6-v2

// example query
create_store(
    store="my_store",
    index_model="all-minilm-l6-v2",
    query_model="all-minilm-l6-v2",
)

Architecture

flowchart TD
  subgraph ai [ahnlich‑ai]
    direction TB
    AIClient["AI Client"]
    StoreHandlerAI["Store Handler"]
    StoreA_AI["Store A"]
    ModelNode["Index Model → Model B<br/>Query Model → Model A<br/>Preprocess Method"]
    PersistenceAI[(Persistence)]
    
    AIClient --> |"original + metadata"| StoreHandlerAI
    StoreHandlerAI --> StoreA_AI
    StoreA_AI --> ModelNode
    ModelNode -.-> PersistenceAI
    class PersistenceAI optionalNode
  end

  subgraph db [ahnlich‑db]
    direction TB
    DBClient["DB Client"]
    StoreHandlerDB["Store Handler"]
    StoreA_DB["Store A"]
    PersistenceDB[(Persistence)]
    
    DBClient --> |"DB query"| StoreHandlerDB
    StoreHandlerDB --> StoreA_DB
    StoreA_DB -.-> PersistenceDB
    class PersistenceDB optionalNode
  end

  %% Interactions between services
  StoreHandlerAI -.-> |"Set: vector + metadata"| StoreHandlerDB
  StoreHandlerAI -.-> |"GetSimN: vector"| StoreHandlerDB
  StoreHandlerDB -.-> |"TopN results"| StoreHandlerAI

  classDef optionalNode stroke-dasharray: 5 5, color: gray, stroke: gray;
  class PersistenceAI,PersistenceDB optionalNode

Usage

ahnlich-db, ahnlich-ai and ahnlich-cli are packaged and released as binaries for multiple platforms alongside docker images

The DB can be used without the AI proxy for more fine grained control of the generated vector embeddings as all clients support both

Docker Images.

Note:

  1. Arguments and commands must be passed in quotes. E.G: docker run <image_name> "ahnlich-db run --enable-tracing --port 8000"

  2. The CLI comes packaged into the docker images.


Installation
Download Binaries

You can download the Ahnlich binaries for ai and db from GitHub Releases.

  • wget:

    wget https://github.com/deven96/ahnlich/releases/download/bin%2Fdb%2F0.0.0/aarch64-darwin-ahnlich-db.tar.gz  
    
  • Extract the file:

    tar -xvzf aarch64-darwin-ahnlich-db.tar.gz  
    
  • Run the binary:

    ./ahnlich-db  
    

Replace aarch64-darwin-ahnlich-db.tar.gz with the appropriate file name for your architecture. For ai, download the corresponding ai binary, extract it, and run it using ./ahnlich-ai.


Using Docker

You can pull the prebuilt Docker images for Ahnlich:

  • Ahnlich AI:

    docker pull ghcr.io/deven96/ahnlich-ai:latest  
    
  • Ahnlich DB:

    docker pull ghcr.io/deven96/ahnlich-db:latest  
    

Example Docker Compose

Below is an example docker-compose.yaml configuration to run both ahnlich-db and ahnlich-ai with tracing:

services:
  ahnlich_db:
    image: ghcr.io/deven96/ahnlich-db:latest
    command: >
      "ahnlich-db run --host 0.0.0.0 \
      --enable-tracing \
      --otel-endpoint http://jaeger:4317"
    ports:
      - "1369:1369"

  ahnlich_ai:
    image: ghcr.io/deven96/ahnlich-ai:latest
    command: >
      "ahnlich-ai run --db-host ahnlich_db --host 0.0.0.0 \
      --supported-models all-minilm-l6-v2,resnet-50 \
      --enable-tracing \
      --otel-endpoint http://jaeger:4317"
    ports:
      - "1370:1370"

  # optional jaeger service whenever --enable-tracing and
  # --otel-endpoint is used
  jaeger:
    image: jaegertracing/all-in-one:${JAEGER_VERSION:-latest}
    ports:
      - "16686:16686"
      - "1888:1888" # pprof extension
      - "8888:8888" # Prometheus metrics exposed by the collector
      - "8889:8889" # Prometheus exporter metrics
      - "4317:4317" # otlp grpc
      - "4318:4318" # otlp http

Below is an example docker-compose.yaml configuration with persistence:


services:
  ahnlich_db:
    image: ghcr.io/deven96/ahnlich-db:latest
    command: >
      "ahnlich-db run --host 0.0.0.0 \
      --enable-persistence --persist-location /root/.ahnlich/data/db.dat \
      --persistence-interval 300"
    ports:
      - "1369:1369"
    volumes:
      - "./data/:/root/.ahnlich/data" # Persistence Location

  ahnlich_ai:
    image: ghcr.io/deven96/ahnlich-ai:latest
    command: >
      "ahnlich-ai run --db-host ahnlich_db --host 0.0.0.0 \
      --supported-models all-minilm-l6-v2,resnet-50 \
      --enable-persistence --persist-location /root/.ahnlich/data/ai.dat \
      --persistence-interval 300"
    ports:
      - "1370:1370"
    volumes:
      - "./ahnlich_ai_model_cache:/root/.ahnlich/models" # Model cache storage
      - "./data/:/root/.ahnlich/data" # Persistence Location

Below is an example docker-compose.yaml configuration with health checks using the CLI in non-interactive mode:


services:
  ahnlich_db:
    image: ghcr.io/deven96/ahnlich-db:latest
    command: >
      "ahnlich-db run --host 0.0.0.0"
    ports:
      - "1369:1369"
    healthcheck:
      test: ["CMD-SHELL", "echo 'PING' | ahnlich-cli ahnlich --agent db --host 127.0.0.1 --port 1369 --no-interactive"]
      interval: 10s
      timeout: 5s
      retries: 3
      start_period: 5s

  ahnlich_ai:
    image: ghcr.io/deven96/ahnlich-ai:latest
    command: >
      "ahnlich-ai run --db-host ahnlich_db --host 0.0.0.0 \
      --supported-models all-minilm-l6-v2"
    ports:
      - "1370:1370"
    depends_on:
      ahnlich_db:
        condition: service_healthy
    healthcheck:
      test: ["CMD-SHELL", "echo 'PING' | ahnlich-cli ahnlich --agent ai --host 127.0.0.1 --port 1370 --no-interactive"]
      interval: 10s
      timeout: 5s
      retries: 3
      start_period: 10s

The --no-interactive flag allows the CLI to accept commands via stdin and exit immediately after processing, making it ideal for Docker health checks, CI/CD pipelines, and automated scripts.

Execution Providers (Ahnlich AI)
  • CUDA: Only supports >= CUDAv12 and might need to sudo apt install libcudnn9-dev-cuda-12
  • CoreML (Apple): Not advised for NLP models due to often large dimensionality.
  • MIGraphX (AMD GPUs, Linux): AMD's recommended execution provider (upstream ONNX Runtime removed the older ROCm provider in release 1.23). Requires the migraphx runtime to be installed (ships in AMD's ROCm apt repository). Supported AMD Instinct accelerators are listed in the ROCm compatibility matrix; select Radeon cards are also supported. When unsupported, ORT falls back to CPU.
Contributing

View contribution guide

Runs on
GPU support unknown
What shows it
  • no dependency or feature matches a backend row
Native code
None found
  • No native code found
Python bindings
No Python binding crate found
License
MIT

Compare with similar projects

Order: strongest tier first, then most downloads, then name, with unmeasured values last. A library counts downloads over 30 days. An app counts binary downloads per release. An app with none counts its crate downloads over 30 days. ML Rust runs this catalogue, so its closest project always gets a row.

ahnlich beside the projects that share a topic with it
ProjectDownloadsDependentsStarsLatest releaseRuns on (GPU)Native codeLicense
ahnlich This page Listed

Suite of tools containing an in-memory vector datastore and AI proxy

744 downloads over 30 days 0 249 0.4.5 GPU support unknown No native code found MIT
qdrant App Featured

Qdrant - High-performance, massive-scale Vector Database and Vector Search Engine for the next generation of AI. Also available in the cloud https://cloud.qdrant.io/

34,017 binary downloads per release Not applicable 35,478 Not measured Not measured Apache-2.0
pgvectorscale App Listed

Postgres extension for vector search (DiskANN), complements pgvector for performance and scale. Postgres OSS licensed.

33,328 binary downloads per release Not applicable 3,161 Not measured Not measured PostgreSQL
arroy Listed

Annoy-inspired Approximate Nearest Neighbors in Rust, based on LMDB and optimized for memory usage

22,053 downloads over 30 days 6 314 0.9.0 GPU support unknown Binds native code: lmdb-master-sys MIT
splintr Listed

Tokenizer for Rust and Python: pure Rust by default, with 18 bundled vocabularies and four backends covering BPE, SentencePiece and WordPiece. Its output matches Hugging Face tokenizers id for id on 14 model families, including GPT-2, Qwen, Whisper, T5 and BERT.

Python bindings

8,204 downloads over 30 days 7 63 0.22.2 GPU support unknown Binds native code: pcre2-sys (feature pcre2) MIT
memvdb Listed Dormant

A Rust in-memory vector database

305 downloads over 30 days 2 2 0.1.1 GPU support unknown No native code found MIT
oasysdb App Listed Dormant

In-memory vector store with efficient read and write performance for semantic caching and retrieval system. Redis for Semantic Caching.

0 binary downloads per release Not applicable 376 Not measured Not measured Apache-2.0
Why ListedNo archive, New or Featured rule places it, so it is Listed.

What it lacks for Featured

  • It has 0.5 active dependents and 0 new dependents in 365 days. Featured needs 11 active dependents or 9 new dependents in 365 days. The repository route reads 249 stars, 30 forks and 14 contributors. It needs 4,539 stars, 434 forks and 79 contributors together.
  • Docs are missing: the primary crate publishes no README.

What else the check found

  • The last activity is on 30 Oct 2026, 10 days ago. The rules expect an update within 450 days. Dormancy rule

Check notes

  • the latest release was packaged from a dirty working tree

Exact rules: Listed, Featured library. The check on applied thresholds version 9.

Every rule outcome, as the check records it
  • expected-interval: version 0.4.5 base 450: E = 450 days
  • dormancy: last activity 2026-10-30, 10 days ago, E = 450: active
  • featured: not featured: active_users 0.5 < 11 and new_adopters 0 < 9 and repository route stars 249 (needs 4539), forks 30 (needs 434), contributors 14 (needs 79); docs missing
  • listed: listed: no archive, new or featured rule applies
Crates2 crates

Measurements and sources

Each signal row shows the raw value, its source and the fetch date. The Sources list gathers every distinct source on this page. Movement needs more history.

Sources6 sources
Adoption1 active dependents, 0 new dependents in 365 days1 not measured
Adoption measurements
SignalValueSourceFetchedCounts
Active dependents0.5crates.io database dumpYes
New dependents (365 days)0crates.io database dumpYes
Peak active dependents0.5crates.io database dumpYes
Active dependents as a share of the peak1crates.io database dumpYes
Binary downloads per releaseNot measuredYes
MaintenanceLatest human commit: 10 days ago3 not measured
Maintenance measurements
SignalValueSourceFetchedCounts
Latest human commit2026-10-30GitHub repositoryYes
Latest release2026-10-10crates.io database dumpYes
First release2024-12-02crates.io database dumpYes
Latest version0.4.5crates.io database dumpYes
Days the oldest outside issue waits for a reply0GitHub repositoryYes
Maintainer replies over 365 days25GitHub repositoryYes
Repository archivedfalseGitHub repositoryYes
Repository gonefalseGitHub repositoryYes
Release commit or manifest in the repotruecrates.io packageYes
Published docsfalsecrates.io database dumpYes
Latest release fails cargo checkNot measuredYes
Build check dateNot measuredYes
Build check toolchainNot measuredYes
SecurityUnpatched vulnerabilities: none
Security measurements
SignalValueSourceFetchedCounts
Unpatched vulnerabilities past the grace windownoneRustSec advisory databaseYes
RustSec unmaintained advisorynoneRustSec advisory databaseYes
Deprecation noticenonecrates.io database dumpYes
Deprecated requirementnonecrates.io database dumpYes
Distribution11 releases, 744 downloads over 30 days5 not measured
Distribution measurements
SignalValueSourceFetchedCounts
Releases11crates.io database dumpYes
Downloads over 30 days744crates.io database dumpYes
Binary downloads over the last 3 releasesNot measuredYes
Homebrew installs on request over 365 daysNot measuredYes
Repology repository familiesNot measuredYes
Docker pull growth over 90 daysNot measuredYes
Docker pulls at the growth baselineNot measuredYes
Every version a prereleasefalsecrates.io database dumpYes
Every version 0.0.xfalsecrates.io database dumpYes
Every version yankedfalsecrates.io database dumpYes
Crate deleted from crates.iofalsecrates.io database dumpYes
Repository249 stars, 30 forks, 14 contributors, 541 commits. Stars alone never qualify a project.
Repository measurements
SignalValueSourceFetchedCounts
GitHub stars249GitHub repositoryYes — one part of the repository route
GitHub forks30GitHub repositoryYes — one part of the repository route
Contributors with a GitHub account14GitHub contributorsYes — one part of the repository route
Commits on the default branch541GitHub repositoryNo
Repository's main crate left out of the entrynonecrates.io database dumpYes
Facts that never count
Facts that never count measurements
SignalValueSourceFetchedCounts
LicenseMITGitHub repositoryNo
Runs on, from listed crates and their direct dependenciesGPU support unknowncrates.io database dumpNo
What shows each backendno dependency or feature matches a backend rowcrates.io database dumpNo
Native code, from listed crates and their dependenciesNo native code foundcrates.io database dumpNo
Python bindings, from direct dependencies of listed cratesNo Python binding crate foundcrates.io database dumpNo
Crates that depend on a listed crate directly0crates.io database dumpNo

Corrections and review history

Report a correction

No correction applies to this entry.

Judgments

A judgment enters only through an approved issue and a merged pull request.

No judgment applies to this entry.