Zero-Shot Classification
Transformers
ONNX
Safetensors
English
watersheep
feature-extraction
decision-model
calibration
multi-label
custom_code
Instructions to use samratduttaofficial/WaterSheep with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use samratduttaofficial/WaterSheep with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("zero-shot-classification", model="samratduttaofficial/WaterSheep", trust_remote_code=True)# pip install -U transformers accelerate # Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("samratduttaofficial/WaterSheep", trust_remote_code=True, device_map="auto") - Notebooks
- Google Colab
- Kaggle
Download handler.py from samratduttaofficial/WaterSheep: direct link, hf CLI and curl.
- Browser
- Download file 263 Bytes
-
https://huggingface.co/samratduttaofficial/WaterSheep/resolve/main/handler.py
- Command line
-
hf download hf://samratduttaofficial/WaterSheep/handler.py
-
curl -L -o handler.py https://huggingface.co/samratduttaofficial/WaterSheep/resolve/main/handler.py
263 Bytes
| from transformers import pipeline | |
| class EndpointHandler: | |
| def __init__(self, path=""): | |
| self.pipe = pipeline(model=path, trust_remote_code=True) | |
| def __call__(self, data): | |
| return self.pipe(data["inputs"], **(data.get("parameters") or {})) | |