--- id: preshed version: "3.0.13" license: MIT license_treatment: permissive maintenance: active --- # preshed — Cython hash table that trusts the keys are pre-hashed License: permissive · Maintenance: active · Popularity: top 1,000 on PyPI ## Install pip install preshed uv add preshed poetry add preshed ## Description # preshed: Cython Hash Table for Pre-Hashed Keys Simple but high performance Cython hash table mapping pre-randomized keys to `void*` values. Inspired by [Jeff Preshing](http://preshing.com/20130107/this-hash-table-is-faster-than-a-judy-array/). All Python APIs provded by the `BloomFilter` and `PreshMap` classes are thread-safe on both the GIL-enabled build and the free-threaded build of Python 3.14 and newer. If you use the C API or the `PreshCounter` class, you must provide external synchronization if you use the data structures by this library in a multithreaded environment. [![tests](https://github.com/explosion/preshed/actions/workflows/tests.yml/badge.svg)](https://github.com/explosion/preshed/actions/workflows/tests.yml) [![pypi Version](https://img.shields.io/pypi/v/preshed.svg?style=flat-square&logo=pypi&logoColor=white)](https://pypi.python.org/pypi/preshed) [![conda Version](https://img.shields.io/conda/vn/conda-forge/preshed.svg?style=flat-square&logo=conda-forge&logoColor=white)](https://anaconda.org/conda-forge/preshed) [![Python... ## AI interpretation — verify before relying preshed provides high-performance Cython hash tables and probabilistic data structures (PreshMap, BloomFilter, PreshCounter) for fast lookups and counting of pre-hashed integer keys, with thread-safe Python APIs and low-level C access. Verdict: preshed is a mature, actively maintained library with no security issues, permissive licensing, and broad platform support. Medium install friction is offset by pre-built wheels and a stable maintenance track record. Suitable for production use in data-intensive applications requiring fast integer-key lookups. [View on SkillFed](https://skillfed.io/packages/preshed) · [View on PyPI](https://pypi.org/project/preshed/)