Metadata-Version: 2.1
Name: zerohero
Version: 0.1.1
Summary: Easy Embedding-Based Zero-Shot Classfication
License: MIT
Author: edkrueger
Author-email: edkrueger@gmail.com
Requires-Python: >=3.10,<3.13
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Requires-Dist: backoff (>=2.2.1,<3.0.0)
Requires-Dist: openai (>=0.28.1,<0.29.0)
Requires-Dist: sentence-transformers (>=2.2.2,<3.0.0)
Requires-Dist: tiktoken (>=0.5.1,<0.6.0)
Requires-Dist: torch (>=2.1.0,<3.0.0)
Description-Content-Type: text/markdown

# zerohero

Example:

```
from pprint import pprint
from zerohero import make_zero_shot_classifier

categories = ["cat", "dog", "mouse", "human"]
zsc = make_zero_shot_classifier(
    categories=categories,
    model_type="sentence-transformers",
    model_name="paraphrase-albert-small-v2",
)
cat_text = (
    """The cat (Felis catus),
    commonly referred to as the domestic cat or house cat,
    is the only domesticated species in the family Felidae.
    """
    )

result = zsc(cat_text)

pprint(result)
```
## Development Instructions

Install Dependencies: `poetry install --with dev`  
Configure pre-commit hooks: `poetry run pre-commit install`  
Manually run black: `poetry run black zerohero/* tests/*`  
Manually run pylint: `poetry run pylint zerohero/* tests/*`

