Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -1,6 +1,11 @@
|
|
1 |
import streamlit as st
|
2 |
from transformers import pipeline
|
3 |
|
|
|
|
|
|
|
|
|
|
|
4 |
# Initialize the model and tokenizer for CPU
|
5 |
generate_text = pipeline(
|
6 |
model="PAIXAI/Astrid-1B",
|
|
|
1 |
import streamlit as st
|
2 |
from transformers import pipeline
|
3 |
|
4 |
+
|
5 |
+
# Load the model in full precision
|
6 |
+
model = AutoModelForCausalLM.from_pretrained("PAIXAI/Astrid-1B").to(dtype=torch.float32)
|
7 |
+
|
8 |
+
|
9 |
# Initialize the model and tokenizer for CPU
|
10 |
generate_text = pipeline(
|
11 |
model="PAIXAI/Astrid-1B",
|