generated from opentensor/bittensor-subnet-template
-
Notifications
You must be signed in to change notification settings - Fork 45
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'staging' into hotfix/pre-release
- Loading branch information
Showing
17 changed files
with
282 additions
and
167 deletions.
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
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 |
---|---|---|
|
@@ -13,4 +13,5 @@ rouge | |
scipy==1.10.1 | ||
sentencepiece | ||
wandb==0.15.10 | ||
tenacity | ||
tenacity | ||
antlr4-python3-runtime==4.11 |
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
Empty file.
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,51 @@ | ||
|
||
from prompting.tools import MockDataset, CodingDataset, WikiDataset, StackOverflowDataset, DateQADataset, MathDataset | ||
|
||
DATASETS = [ | ||
# MockDataset, | ||
CodingDataset, | ||
WikiDataset, | ||
# StackOverflowDataset, | ||
DateQADataset, | ||
MathDataset, | ||
] | ||
|
||
WIKI_ARTICLE = { | ||
'title': 'Emilio Alvarez (bishop)', | ||
'url': 'https://en.wikipedia.org/wiki/Emilio_Alvarez_(bishop)', | ||
'length': 8185, | ||
'extract': '<p><b>Emilio Alvarez</b> (born January 16) is a religious leader in the United States, and founding bishop of the Union of Charismatic Orthodox Churches. He is also the founding director of the Institute for Paleo-Orthodox Christian Studies (formerly the certificate in Convergence Studies Program at New York Theological Seminary).', | ||
'backlinks': 7, | ||
'categories': [ | ||
'21st-century American bishops', | ||
'21st-century Puerto Rican peopl', | ||
'nvergence Movemen', | ||
'Living peopl', | ||
'People of Afro–Puerto Rican descen', | ||
'Puerto Rican bishops', | ||
'Religious leaders from New York (state)', | ||
'Short description matches Wikid', | ||
'Writers from New York (state)', | ||
'Year of birth missing (living people)' | ||
] | ||
} | ||
|
||
WIKI_CONTEXT = WikiDataset().next(info=WIKI_ARTICLE) | ||
CODING_CONTEXT = CodingDataset(buffer_size=10).next() | ||
MATH_CONTEXT = MathDataset(seed=123).next() | ||
DATEQA_CONTEXT = DateQADataset(seed=123).next() | ||
|
||
CONTEXTS = { | ||
WikiDataset: WIKI_CONTEXT, | ||
CodingDataset: CODING_CONTEXT, | ||
MathDataset: MATH_CONTEXT, | ||
DateQADataset: DATEQA_CONTEXT, | ||
} | ||
|
||
|
||
CONTEXT_FIELDS = { | ||
WikiDataset: {"text", "title", "categories", "url", "sections", "fetch_time", "length", "backlinks", "extract"}, | ||
CodingDataset: {"code", "repo_name", "path", "language", "size", "fetch_time", "license"}, | ||
MathDataset: {"problem", "solution", 'topic', 'subtopic', "fetch_time", "solution_raw"}, | ||
DateQADataset: {"section", "event", 'date', "next_page", "fetch_time"}, | ||
} |
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,3 @@ | ||
from prompting.mock import MockPipeline | ||
|
||
LLM_PIPELINE = MockPipeline("This is just another test.") |
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,20 @@ | ||
from prompting.tasks import Task, QuestionAnsweringTask, SummarizationTask, DebuggingTask, MathTask, DateQuestionAnsweringTask | ||
from .dataset import WIKI_CONTEXT, CODING_CONTEXT, MATH_CONTEXT, DATEQA_CONTEXT | ||
|
||
TASKS = [ | ||
QuestionAnsweringTask, | ||
SummarizationTask, | ||
DebuggingTask, | ||
MathTask, | ||
DateQuestionAnsweringTask, | ||
] | ||
|
||
# TODO: Make fully deterministic | ||
CONTEXTS = { | ||
QuestionAnsweringTask: WIKI_CONTEXT, | ||
SummarizationTask: WIKI_CONTEXT, | ||
DebuggingTask: CODING_CONTEXT, | ||
MathTask: MATH_CONTEXT, | ||
DateQuestionAnsweringTask: DATEQA_CONTEXT, | ||
} | ||
|
Oops, something went wrong.