Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Amazon KDD Cup 2024 Starter Kit
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
der2933
Amazon KDD Cup 2024 Starter Kit
Commits
4e2c3116
Commit
4e2c3116
authored
1 year ago
by
spmohanty
Browse files
Options
Downloads
Patches
Plain Diff
add generation task response to docs
parent
2bf03313
No related branches found
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
models/README.md
+1
-0
1 addition, 0 deletions
models/README.md
models/base_model.py
+1
-0
1 addition, 0 deletions
models/base_model.py
models/dummy_model.py
+3
-0
3 additions, 0 deletions
models/dummy_model.py
with
5 additions
and
0 deletions
models/README.md
+
1
−
0
View file @
4e2c3116
...
...
@@ -21,6 +21,7 @@ The output from your model's `predict` function should always be a string. Depen
-
A single integer (in the range [0, 3]) for multiple choice tasks.
-
A comma-separated list of integers for ranking tasks.
-
A comma-separated list of named entities for Named Entity Recognition (NER) tasks.
-
(unconstrained) generated response for the generation tasks
For more information on how these responses are processed, please see
[
parsers.py
](
../parsers.py
)
.
...
...
This diff is collapsed.
Click to expand it.
models/base_model.py
+
1
−
0
View file @
4e2c3116
...
...
@@ -18,6 +18,7 @@ class ShopBenchBaseModel:
str: The prediction as a string representing a single integer[0, 3] for multiple choice tasks,
or a string representing a comma separated list of integers for Ranking, Retrieval tasks,
or a string representing a comma separated list of named entities for Named Entity Recognition tasks.
or a string representing the (unconstrained) generated response for the generation tasks
Please refer to parsers.py for more details on how these responses will be parsed by the evaluator.
"""
raise
NotImplementedError
(
"
predict method not implemented
"
)
This diff is collapsed.
Click to expand it.
models/dummy_model.py
+
3
−
0
View file @
4e2c3116
...
...
@@ -35,6 +35,7 @@ class DummyModel(ShopBenchBaseModel):
str: The prediction as a string representing a single integer[0, 3] for multiple choice tasks,
or a string representing a comma separated list of integers for Ranking, Retrieval tasks,
or a string representing a comma separated list of named entities for Named Entity Recognition tasks.
or a string representing the (unconstrained) generated response for the generation tasks
Please refer to parsers.py for more details on how these responses will be parsed by the evaluator.
"""
possible_responses
=
[
1
,
2
,
3
,
4
]
...
...
@@ -46,3 +47,5 @@ class DummyModel(ShopBenchBaseModel):
# For other tasks, shuffle the possible responses and return as a string
random
.
shuffle
(
possible_responses
)
return
str
(
possible_responses
)
# Note: As this is dummy model, we are returning random responses for non-multiple choice tasks.
# For generation tasks, this should ideally return an unconstrained string.
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment