-
Notifications
You must be signed in to change notification settings - Fork 325
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add support for FinMTEB benchmark #1379
Open
alt-glitch
wants to merge
12
commits into
embeddings-benchmark:v2.0.0
Choose a base branch
from
alt-glitch:add_finmteb
base: v2.0.0
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from 8 commits
Commits
Show all changes
12 commits
Select commit
Hold shift + click to select a range
585cdeb
FinMTEB: classification, clustering, pairclassification, reranking, r…
alt-glitch cd86c8c
fix __init__
alt-glitch cdebb41
fix references not being URLs
alt-glitch 231bd95
fix: update import statements; add summarization tasks; update pair_c…
alt-glitch 4ccdb06
revert FinQA naming
alt-glitch 4caa688
fix AbsTaskSTS default human/generated columns
alt-glitch 2b38e05
refactor: update dataset column names and add references for various …
alt-glitch a598a31
Merge branch 'v2.0.0' into add_finmteb
isaac-chung 866cb70
fix merge conflicts, imports, and lint
isaac-chung 8d3bfa1
use existing datasets and lint
isaac-chung eb58e81
fix typos in evaluator
isaac-chung ebe121b
wip: task metadata
alt-glitch File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,6 @@ | ||
from __future__ import annotations | ||
|
||
|
||
from .ara import ( | ||
AJGT, | ||
HotelReviewSentimentClassification, | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
from __future__ import annotations | ||
|
||
from mteb.abstasks.AbsTaskClassification import AbsTaskClassification | ||
from mteb.abstasks.TaskMetadata import TaskMetadata | ||
|
||
|
||
class ESGClassification(AbsTaskClassification): | ||
metadata = TaskMetadata( | ||
name="ESGClassification", | ||
description="A finance dataset performs sentence classification under the environmental, social, and corporate governance (ESG) framework.", | ||
reference="https://arxiv.org/abs/2309.13064", | ||
dataset={ | ||
"path": "FinanceMTEB/ESG", | ||
"revision": "521d56feabadda80b11d6adcc6b335d4c5ad8285", | ||
}, | ||
type="Classification", | ||
category="s2s", | ||
eval_splits=["test"], | ||
eval_langs=["eng-Latn"], | ||
main_score="accuracy", | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
from __future__ import annotations | ||
|
||
from mteb.abstasks.AbsTaskClassification import AbsTaskClassification | ||
from mteb.abstasks.TaskMetadata import TaskMetadata | ||
|
||
|
||
class FLSClassification(AbsTaskClassification): | ||
metadata = TaskMetadata( | ||
name="FLSClassification", | ||
description="A finance dataset detects whether the sentence is a forward-looking statement.", | ||
reference="https://arxiv.org/abs/2309.13064", | ||
dataset={ | ||
"path": "FinanceMTEB/FLS", | ||
"revision": "39b6719f1d7197df4498fea9fce20d4ad782a083", | ||
}, | ||
type="Classification", | ||
category="s2s", | ||
eval_splits=["test"], | ||
eval_langs=["eng-Latn"], | ||
main_score="accuracy", | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
from __future__ import annotations | ||
|
||
from mteb.abstasks.AbsTaskClassification import AbsTaskClassification | ||
from mteb.abstasks.TaskMetadata import TaskMetadata | ||
|
||
|
||
class FOMCClassification(AbsTaskClassification): | ||
metadata = TaskMetadata( | ||
name="FOMCClassification", | ||
description="A task of hawkish-dovish classification in finance domain.", | ||
reference="https://github.com/gtfintechlab/fomc-hawkish-dovish", | ||
dataset={ | ||
"path": "FinanceMTEB/FOMC", | ||
"revision": "cdaf1306a24bc5e7441c7c871343efdf4c721bc2", | ||
}, | ||
type="Classification", | ||
category="s2s", | ||
eval_splits=["test"], | ||
eval_langs=["eng-Latn"], | ||
main_score="accuracy", | ||
) | ||
|
||
def dataset_transform(self): | ||
self.dataset = self.dataset.rename_column("sentence", "text") |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
General comment: Meta data is required to be filled out.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah understood. Working on it.