Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -10,7 +10,7 @@ from evaluate import load
|
|
| 10 |
|
| 11 |
from guidelines import guidelines
|
| 12 |
|
| 13 |
-
human2_annotation_file = "
|
| 14 |
space = "Iker/ClickbaitAnnotation"
|
| 15 |
|
| 16 |
|
|
@@ -68,7 +68,7 @@ class AnnotationManager:
|
|
| 68 |
def __init__(self):
|
| 69 |
self.dataset = list(
|
| 70 |
load_dataset(
|
| 71 |
-
"Iker/
|
| 72 |
)
|
| 73 |
)
|
| 74 |
|
|
@@ -81,9 +81,9 @@ class AnnotationManager:
|
|
| 81 |
try:
|
| 82 |
huggingface_hub.hf_hub_download(
|
| 83 |
repo_id=space,
|
| 84 |
-
repo_type="
|
| 85 |
token=os.environ.get("TOKEN") or True,
|
| 86 |
-
filename=
|
| 87 |
local_dir=os.getcwd(),
|
| 88 |
)
|
| 89 |
|
|
@@ -130,10 +130,10 @@ class AnnotationManager:
|
|
| 130 |
self.references.append([clean_text(example["summary"])])
|
| 131 |
|
| 132 |
huggingface_hub.upload_file(
|
| 133 |
-
repo_id=
|
| 134 |
-
repo_type="
|
| 135 |
token=os.environ.get("TOKEN") or True,
|
| 136 |
-
path_in_repo=
|
| 137 |
path_or_fileobj=human2_annotation_file,
|
| 138 |
)
|
| 139 |
|
|
|
|
| 10 |
|
| 11 |
from guidelines import guidelines
|
| 12 |
|
| 13 |
+
human2_annotation_file = "test.jsonl"
|
| 14 |
space = "Iker/ClickbaitAnnotation"
|
| 15 |
|
| 16 |
|
|
|
|
| 68 |
def __init__(self):
|
| 69 |
self.dataset = list(
|
| 70 |
load_dataset(
|
| 71 |
+
"Iker/NoticIA_Human_Validation", token=os.environ.get("TOKEN") or True, split="test"
|
| 72 |
)
|
| 73 |
)
|
| 74 |
|
|
|
|
| 81 |
try:
|
| 82 |
huggingface_hub.hf_hub_download(
|
| 83 |
repo_id=space,
|
| 84 |
+
repo_type="dataset",
|
| 85 |
token=os.environ.get("TOKEN") or True,
|
| 86 |
+
filename="test.jsonl",
|
| 87 |
local_dir=os.getcwd(),
|
| 88 |
)
|
| 89 |
|
|
|
|
| 130 |
self.references.append([clean_text(example["summary"])])
|
| 131 |
|
| 132 |
huggingface_hub.upload_file(
|
| 133 |
+
repo_id="Iker/NoticIA_Human_Validation",
|
| 134 |
+
repo_type="dataset",
|
| 135 |
token=os.environ.get("TOKEN") or True,
|
| 136 |
+
path_in_repo="test.jsonl",
|
| 137 |
path_or_fileobj=human2_annotation_file,
|
| 138 |
)
|
| 139 |
|