Instructions to use ArthurZ/d3 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use ArthurZ/d3 with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("zero-shot-classification", model="ArthurZ/d3")# pip install -U transformers accelerate # Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("ArthurZ/d3", device_map="auto") - Notebooks
- Google Colab
- Kaggle
Default dtype and device map in the snippets
Browse files
README.md
CHANGED
|
@@ -19,7 +19,7 @@ Each question is answered with a probability for every option: `noul` (yes/no),
|
|
| 19 |
```python
|
| 20 |
from transformers import pipeline
|
| 21 |
|
| 22 |
-
decide = pipeline("decision", model="ArthurZ/d3"
|
| 23 |
answers = decide(
|
| 24 |
{
|
| 25 |
"state": {"customer": "Lena", "message": "I was charged twice for my order and I want my money back today."},
|
|
@@ -43,7 +43,6 @@ A bare state is asked the questions of the last request, or the ones given up fr
|
|
| 43 |
decide = pipeline(
|
| 44 |
"decision",
|
| 45 |
model="ArthurZ/d3",
|
| 46 |
-
device_map="auto",
|
| 47 |
questions={"spam": {"type": "noul", "instructions": "Is this spam?"}},
|
| 48 |
)
|
| 49 |
decide("WIN A FREE IPHONE!!! click here to claim your prize")
|
|
|
|
| 19 |
```python
|
| 20 |
from transformers import pipeline
|
| 21 |
|
| 22 |
+
decide = pipeline("decision", model="ArthurZ/d3")
|
| 23 |
answers = decide(
|
| 24 |
{
|
| 25 |
"state": {"customer": "Lena", "message": "I was charged twice for my order and I want my money back today."},
|
|
|
|
| 43 |
decide = pipeline(
|
| 44 |
"decision",
|
| 45 |
model="ArthurZ/d3",
|
|
|
|
| 46 |
questions={"spam": {"type": "noul", "instructions": "Is this spam?"}},
|
| 47 |
)
|
| 48 |
decide("WIN A FREE IPHONE!!! click here to claim your prize")
|