Create app.py
Browse files
app.py
ADDED
@@ -0,0 +1,12 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
# app.py
|
2 |
+
import gradio as gr
|
3 |
+
from transformers import pipeline
|
4 |
+
|
5 |
+
detector = pipeline("text-classification", model="debojit01/fake-review-detector")
|
6 |
+
|
7 |
+
gr.Interface(
|
8 |
+
fn=lambda x: detector(x)[0],
|
9 |
+
inputs="text",
|
10 |
+
outputs="label",
|
11 |
+
title="Fake Review Detector"
|
12 |
+
).launch()
|