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
7fcfb4ac
Commit
7fcfb4ac
authored
Jul 12, 2025
by
Baber
Browse files
refactor: simplify docstrings and improve task name matching logic
parent
5e632643
Changes
2
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
215 additions
and
337 deletions
+215
-337
lm_eval/api/group.py
lm_eval/api/group.py
+7
-2
lm_eval/tasks/__init__.py
lm_eval/tasks/__init__.py
+208
-335
No files found.
lm_eval/api/group.py
View file @
7fcfb4ac
import
abc
from
dataclasses
import
asdict
,
dataclass
from
dataclasses
import
asdict
,
dataclass
from
inspect
import
getsource
from
inspect
import
getsource
from
typing
import
Any
,
Callable
,
List
,
Optional
,
Union
from
typing
import
Any
,
Callable
,
List
,
Optional
,
Union
...
@@ -83,8 +82,14 @@ class GroupConfig(dict):
...
@@ -83,8 +82,14 @@ class GroupConfig(dict):
except
(
TypeError
,
OSError
):
except
(
TypeError
,
OSError
):
return
str
(
value
)
return
str
(
value
)
@
property
def
version
(
self
)
->
str
:
"""Returns the version of the group configuration."""
return
self
.
metadata
.
get
(
"version"
,
"1.0"
)
class
ConfigurableGroup
(
abc
.
ABC
):
@
dataclass
class
ConfigurableGroup
:
def
__init__
(
def
__init__
(
self
,
self
,
config
:
Optional
[
dict
]
=
None
,
config
:
Optional
[
dict
]
=
None
,
...
...
lm_eval/tasks/__init__.py
View file @
7fcfb4ac
This diff is collapsed.
Click to expand it.
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