Metadata-Version: 2.4
Name: btrcache
Version: 0.1.0
Summary: High-performance caching tools, memoization decorators, and cache collections for Python.
Project-URL: Homepage, https://github.com/lucas-azdias/btrcache?tab=readme-ov-file
Project-URL: Source, https://github.com/lucas-azdias/btrcache
Project-URL: Issues, https://github.com/lucas-azdias/btrcache/issues
Author-email: Lucas Dias <lucas@azdias.com.br>
Maintainer-email: Lucas Dias <lucas@azdias.com.br>
License-Expression: MIT
License-File: LICENSE
Classifier: Development Status :: 2 - Pre-Alpha
Classifier: Intended Audience :: Developers
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.14
Classifier: Topic :: Software Development :: Libraries :: Python Modules
Requires-Python: >=3.14
Description-Content-Type: text/markdown

# `btrcache`

[![License](https://img.shields.io/github/license/lucas-azdias/btrcache)](https://raw.github.com/lucas-azdias/btrcache/master/LICENSE)

[![Coverage](https://img.shields.io/codecov/c/github/lucas-azdias/btrcache/main.svg)](https://codecov.io/gh/lucas-azdias/btrcache)

High-performance caching tools, memoization decorators, and cache collections for Python.

---

## Overview

**`btrcache`** is a Python library that provides a flexible set of in-memory caching primitives, decorators, and cache collections designed for both synchronous and asynchronous workloads.

## Installation

```bash
pip install btrcache
```

<!--
## Quick Start

### Simple function memoization

```python
from btrcache import cached

@cached()
def fib(n: int) -> int:
    if n < 2:
        return n
    return fib(n - 1) + fib(n - 2)
```

### Custom cache size

```python
from btrcache import cached, LRUCache

@cached(cache_factory=lambda: LRUCache(maxsize=1024))
def compute(x):
    return x * x
```
-->

## Roadmap

* [X] Key generators
* [X] Asynchronous decorators
* [ ] Create tests
* [ ] Release in PyPi
* [ ] Synchronous decorators
* [ ] Cache collections
* [ ] Optimizations

## Contributing

Contributions are welcome. Please ensure:

* Code is type-annotated;
* Tests cover edge cases.

## Acknowledgements

This project builds upon ideas and implementations from the following open-source projects:

- [`cachetools`](https://github.com/tkem/cachetools/) - An extensible set of memoizing collections and decorators for Python. Developed and maintained by [Thomas Kemmer](https://github.com/tkem/).
- [`cachetools-async`](https://github.com/imnotjames/cachetools-async/) - Python library that extends `cachetools` with async decorators. Created by [James Ward](https://github.com/imnotjames/).

## License

Copyright (C) 2026 Lucas Dias.

Licensed under the [MIT License](LICENSE).
