Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -3,11 +3,12 @@ import gradio as gr
|
|
3 |
title = "Neural Plagiarism Detection Demo"
|
4 |
description = """# <p style="text-align: center;"> π© π Plagiarism Detection Demo π π©</p>
|
5 |
The model was trained on the [Machine Paraphrase Dataset](https://huggingface.co/datasets/jpwahle/machine-paraphrase-dataset) to detect machine-generated paraphrases. It works best for paraphrases from research papers, wikipedia, or graduation theses."""
|
|
|
6 |
examples = [
|
7 |
[
|
8 |
"The North Pacific right whale seems to happen in two populaces. The"
|
9 |
" populace in the eastern North Pacific/Bering Sea is amazingly low,"
|
10 |
-
" numbering around 30 people. A bigger western populace of 100
|
11 |
" 200 seems, by all accounts, to be making due in the Sea of Okhotsk,"
|
12 |
" yet next to no is thought about this populace. In this manner, the"
|
13 |
" two northern right whale species are the most jeopardized of every"
|
@@ -16,14 +17,14 @@ examples = [
|
|
16 |
" species are anticipated to end up wiped out inside 200 years. The"
|
17 |
" Pacific species was truly found in summer from the Sea of Okhotsk in"
|
18 |
" the west to the Gulf of Alaska in the east, for the most part north"
|
19 |
-
" of 50
|
20 |
" most part happen in the mouth of the Sea of Okhotsk and in the"
|
21 |
" eastern Bering Sea. In spite of the fact that this species is all"
|
22 |
" around prone to be transitory like the other two species, its"
|
23 |
" development designs are not known."
|
24 |
],
|
25 |
[
|
26 |
-
"""On 12 June 1917, a long time before "Mutsu" was set down, Hiraga proposed a modified structure for the ship that mirrored the exercises from the Battle of Jutland that had happened the earlier year, and consolidated advances in kettle innovation. Given undertaking number A-125, his structure included an additional twin primary firearm turret, utilizing space and weight made accessible by the decrease of the quantity of boilers from 21 to 12, while the power continued as before. He diminished the auxiliary weapon from 20 firearms to 16, in spite of the fact that they were brought up in stature to improve their capacity to discharge amid overwhelming climate and to improve their bends of shoot. To expand the ship's insurance he proposed calculating the belt protection outwards to improve its protection from flat flame, and expanding the thickness of the lower deck
|
27 |
],
|
28 |
[
|
29 |
"On 24 February 2022, Russia invaded Ukraine in a major escalation of"
|
@@ -49,10 +50,13 @@ examples = [
|
|
49 |
],
|
50 |
]
|
51 |
|
52 |
-
gr.Interface.load(
|
53 |
"huggingface/jpwahle/longformer-base-plagiarism-detection",
|
54 |
-
inputs=gr.
|
55 |
title=title,
|
56 |
description=description,
|
57 |
examples=examples,
|
58 |
-
)
|
|
|
|
|
|
|
|
3 |
title = "Neural Plagiarism Detection Demo"
|
4 |
description = """# <p style="text-align: center;"> π© π Plagiarism Detection Demo π π©</p>
|
5 |
The model was trained on the [Machine Paraphrase Dataset](https://huggingface.co/datasets/jpwahle/machine-paraphrase-dataset) to detect machine-generated paraphrases. It works best for paraphrases from research papers, wikipedia, or graduation theses."""
|
6 |
+
|
7 |
examples = [
|
8 |
[
|
9 |
"The North Pacific right whale seems to happen in two populaces. The"
|
10 |
" populace in the eastern North Pacific/Bering Sea is amazingly low,"
|
11 |
+
" numbering around 30 people. A bigger western populace of 100ΓΒ’ΓΓ"
|
12 |
" 200 seems, by all accounts, to be making due in the Sea of Okhotsk,"
|
13 |
" yet next to no is thought about this populace. In this manner, the"
|
14 |
" two northern right whale species are the most jeopardized of every"
|
|
|
17 |
" species are anticipated to end up wiped out inside 200 years. The"
|
18 |
" Pacific species was truly found in summer from the Sea of Okhotsk in"
|
19 |
" the west to the Gulf of Alaska in the east, for the most part north"
|
20 |
+
" of 50ΓΓΒ°N. Today, sightings are exceptionally uncommon and for the"
|
21 |
" most part happen in the mouth of the Sea of Okhotsk and in the"
|
22 |
" eastern Bering Sea. In spite of the fact that this species is all"
|
23 |
" around prone to be transitory like the other two species, its"
|
24 |
" development designs are not known."
|
25 |
],
|
26 |
[
|
27 |
+
"""On 12 June 1917, a long time before "Mutsu" was set down, Hiraga proposed a modified structure for the ship that mirrored the exercises from the Battle of Jutland that had happened the earlier year, and consolidated advances in kettle innovation. Given undertaking number A-125, his structure included an additional twin primary firearm turret, utilizing space and weight made accessible by the decrease of the quantity of boilers from 21 to 12, while the power continued as before. He diminished the auxiliary weapon from 20 firearms to 16, in spite of the fact that they were brought up in stature to improve their capacity to discharge amid overwhelming climate and to improve their bends of shoot. To expand the ship's insurance he proposed calculating the belt protection outwards to improve its protection from flat flame, and expanding the thickness of the lower deck protective layer and the torpedo bulkhead. Hiraga additionally intended to add against torpedo lumps to improve submerged security. He assessed that his ship would dislodge as much as "Nagato", in spite of the fact that it would cost around a million yen more. Hiraga's progressions would have impressively deferred "Mutsu"s fruition and were dismissed by the Navy Ministry."""
|
28 |
],
|
29 |
[
|
30 |
"On 24 February 2022, Russia invaded Ukraine in a major escalation of"
|
|
|
50 |
],
|
51 |
]
|
52 |
|
53 |
+
demo = gr.Interface.load(
|
54 |
"huggingface/jpwahle/longformer-base-plagiarism-detection",
|
55 |
+
inputs=gr.Textbox(lines=5, label="Input Text"),
|
56 |
title=title,
|
57 |
description=description,
|
58 |
examples=examples,
|
59 |
+
)
|
60 |
+
|
61 |
+
if __name__ == "__main__":
|
62 |
+
demo.launch()
|