Upload arcee-ai_AFM-4.5B_0.py with huggingface_hub
Browse files- arcee-ai_AFM-4.5B_0.py +2 -8
arcee-ai_AFM-4.5B_0.py
CHANGED
|
@@ -7,14 +7,8 @@
|
|
| 7 |
# ///
|
| 8 |
|
| 9 |
try:
|
| 10 |
-
|
| 11 |
-
|
| 12 |
-
|
| 13 |
-
pipe = pipeline("text-generation", model="arcee-ai/AFM-4.5B")
|
| 14 |
-
messages = [
|
| 15 |
-
{"role": "user", "content": "Who are you?"},
|
| 16 |
-
]
|
| 17 |
-
pipe(messages)
|
| 18 |
with open('arcee-ai_AFM-4.5B_0.txt', 'w') as f:
|
| 19 |
f.write('Everything was good in arcee-ai_AFM-4.5B_0.txt')
|
| 20 |
except Exception as e:
|
|
|
|
| 7 |
# ///
|
| 8 |
|
| 9 |
try:
|
| 10 |
+
from huggingface_hub import login
|
| 11 |
+
login(new_session=False)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 12 |
with open('arcee-ai_AFM-4.5B_0.txt', 'w') as f:
|
| 13 |
f.write('Everything was good in arcee-ai_AFM-4.5B_0.txt')
|
| 14 |
except Exception as e:
|