Update app.py
Browse files
app.py
CHANGED
|
@@ -3,10 +3,16 @@ import streamlit as st
|
|
| 3 |
x = st.slider('Select a value')
|
| 4 |
st.write(x, 'squared is', x * x)
|
| 5 |
|
| 6 |
-
|
| 7 |
-
|
| 8 |
-
|
| 9 |
-
tokenizer
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 10 |
|
| 11 |
# Load your dataset (replace with your dataset path or identifier)
|
| 12 |
dataset = load_dataset("Lexim011/Compliance")
|
|
|
|
| 3 |
x = st.slider('Select a value')
|
| 4 |
st.write(x, 'squared is', x * x)
|
| 5 |
|
| 6 |
+
from transformers import T5ForConditionalGeneration, T5Tokenizer
|
| 7 |
+
from datasets import load_dataset
|
| 8 |
+
|
| 9 |
+
# Load the T5-small model and tokenizer (or your custom model)
|
| 10 |
+
model_name = "Lexim011/NISTER" # Ensure this is the correct string identifier for your model
|
| 11 |
+
model = T5ForConditionalGeneration.from_pretrained(model_name)
|
| 12 |
+
tokenizer = T5Tokenizer.from_pretrained(model_name)
|
| 13 |
+
|
| 14 |
+
# Load your dataset
|
| 15 |
+
dataset = load_dataset("Lexim011/Compliance")
|
| 16 |
|
| 17 |
# Load your dataset (replace with your dataset path or identifier)
|
| 18 |
dataset = load_dataset("Lexim011/Compliance")
|