Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
gaoqiong
lm-evaluation-harness
Commits
fbc26541
Commit
fbc26541
authored
Jul 18, 2023
by
haileyschoelkopf
Browse files
remove template_aliases fully from taskconfig
parent
98c5411c
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
0 additions
and
16 deletions
+0
-16
lm_eval/api/task.py
lm_eval/api/task.py
+0
-16
No files found.
lm_eval/api/task.py
View file @
fbc26541
...
@@ -88,18 +88,6 @@ class TaskConfig(dict):
...
@@ -88,18 +88,6 @@ class TaskConfig(dict):
metadata
:
str
=
None
# by default, not used in the code. allows for users to pass arbitrary info to tasks
metadata
:
str
=
None
# by default, not used in the code. allows for users to pass arbitrary info to tasks
def
__post_init__
(
self
):
def
__post_init__
(
self
):
# allow user-specified aliases so that users can
# force prompt-compatibility for some prompt regardless of
# field names in prompt
# if self.template_aliases:
# if type(self.doc_to_text) == str:
# self.doc_to_text = self.template_aliases + self.doc_to_text
# if type(self.doc_to_target) == str:
# self.doc_to_target = self.template_aliases + self.doc_to_target
# if type(self.gold_alias) == str:
# self.gold_alias = self.template_aliases + self.gold_alias
if
self
.
generation_kwargs
is
not
None
:
if
self
.
generation_kwargs
is
not
None
:
if
self
.
output_type
!=
"greedy_until"
:
if
self
.
output_type
!=
"greedy_until"
:
...
@@ -619,10 +607,6 @@ class ConfigurableTask(Task):
...
@@ -619,10 +607,6 @@ class ConfigurableTask(Task):
list
(
self
.
fewshot_docs
()),
self
,
rnd
=
random
.
Random
(
1234
)
list
(
self
.
fewshot_docs
()),
self
,
rnd
=
random
.
Random
(
1234
)
)
)
# if self._config.template_aliases is not None:
# for key, alias in self._config.template_aliases:
# self.dataset.rename_column(key, alias)
if
self
.
has_test_docs
():
if
self
.
has_test_docs
():
docs
=
self
.
test_docs
()
docs
=
self
.
test_docs
()
elif
self
.
has_validation_docs
():
elif
self
.
has_validation_docs
():
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment