Spaces:
Sleeping
Sleeping
File size: 366 Bytes
7ef1045 e4e73f5 34893b8 7ef1045 34893b8 7ef1045 e4e73f5 7ef1045 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 |
import torch
from transformers import pipeline
import streamlit as st
import os
model_id = "meta-llama/Llama-3.2-1B"
pipe = pipeline(
"text-generation",
model=model_id,
torch_dtype=torch.bfloat16,
device_map="auto",
token = os.getenv('HF_TOKEN')
)
input = st.text_input("Ingrese el Promt")
st.write(pipe(input))
pipe("The key to life is")
|