Commit
•
a79388a
1
Parent(s):
44c9b16
Update app.py
Browse files
app.py
CHANGED
@@ -9,10 +9,15 @@ def main():
|
|
9 |
if button:
|
10 |
st.write(f"Hello, {name}! Nice to meet you!")
|
11 |
|
12 |
-
#Load model
|
13 |
pipe = pipeline("text-classification")
|
14 |
results = pipe(name)
|
15 |
st.write(results)
|
16 |
|
|
|
|
|
|
|
|
|
|
|
17 |
if __name__ == "__main__":
|
18 |
main()
|
|
|
9 |
if button:
|
10 |
st.write(f"Hello, {name}! Nice to meet you!")
|
11 |
|
12 |
+
#Load default class model
|
13 |
pipe = pipeline("text-classification")
|
14 |
results = pipe(name)
|
15 |
st.write(results)
|
16 |
|
17 |
+
#Load custom model from user/repoName
|
18 |
+
pipe2 = pipeline(model="FacebookAI/roberta-large-mnli")
|
19 |
+
results2 = pipe2(name)
|
20 |
+
st.write(results2)
|
21 |
+
|
22 |
if __name__ == "__main__":
|
23 |
main()
|