-
Notifications
You must be signed in to change notification settings - Fork 41
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
This makes use of the new SDG API under the generate_data() method used by the CLI. It uses new simple workflows for knowlege and skills that inteded for basic usable with a small model for testing and demo purposes. The full pipelines provided in the library will only work in larger environments capable of running Mixtral-8x7b. There are still various TODOs in the code, but this is enough to start with. I'm sure we will make enhancements to these basic workflows that still work for the small environments. Signed-off-by: Russell Bryant <[email protected]>
- Loading branch information
Showing
11 changed files
with
385 additions
and
782 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
33 changes: 33 additions & 0 deletions
33
src/instructlab/sdg/configs/skills/simple_generate_qa_freeform.yaml
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,33 @@ | ||
system: You are a very knowledgeable AI Assistant that will faithfully assist the user with their task. | ||
|
||
introduction: Develop a series of question and answer pairs to perform a task. | ||
|
||
principles: | | ||
Here are the requirements: | ||
1. Try not to repeat the verb for each instruction to maximize diversity. | ||
2. The language used for the instruction also should be diverse. For example, you should combine questions with imperative instructions. | ||
3. The type of instructions should be similar to provided examples. The generated instruction and the output should be grounded in the provided document. | ||
4. A GPT language model should be able to complete the instruction. For example, do not ask the assistant to create any visual or audio output. For another example, do not ask the assistant to wake you up at 5pm or set a reminder because it cannot perform any action. | ||
5. The instructions should be in English. | ||
6. The instructions should be 1 to 2 sentences long. Either an imperative sentence or a question is permitted. | ||
7. The output should be an appropriate response to the input and the instruction. Long outputs are preferable. | ||
|
||
examples: | | ||
The task is {task_description}. | ||
Here are some examples to help you understand the type of questions that are asked for: | ||
{question_1} | ||
{response_1} | ||
{question_2} | ||
{response_2} | ||
{question_3} | ||
{response_3} | ||
generation: | | ||
Provide a single question and answer pair based on the examples. | ||
start_tags: [""] | ||
end_tags: [""] |
37 changes: 37 additions & 0 deletions
37
src/instructlab/sdg/configs/skills/simple_generate_qa_grounded.yaml
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,37 @@ | ||
system: You are a very knowledgeable AI Assistant that will faithfully assist the user with their task. | ||
|
||
introduction: Develop a series of question and answer pairs to perform a task. | ||
|
||
principles: | | ||
Here are the requirements: | ||
1. Try not to repeat the verb for each instruction to maximize diversity. | ||
2. The language used for the instruction also should be diverse. For example, you should combine questions with imperative instructions. | ||
3. The type of instructions should be similar to provided examples. The generated instruction and the output should be grounded in the provided document. | ||
4. A GPT language model should be able to complete the instruction. For example, do not ask the assistant to create any visual or audio output. For another example, do not ask the assistant to wake you up at 5pm or set a reminder because it cannot perform any action. | ||
5. The instructions should be in English. | ||
6. The instructions should be 1 to 2 sentences long. Either an imperative sentence or a question is permitted. | ||
7. The output should be an appropriate response to the input and the instruction. Long outputs are preferable. | ||
|
||
examples: | | ||
The task is {task_description}. | ||
Here is some context for the example questions: | ||
{context} | ||
Here are some examples to help you understand the type of questions that are asked for: | ||
{question_1} | ||
{response_1} | ||
{question_2} | ||
{response_2} | ||
{question_3} | ||
{response_3} | ||
generation: | | ||
Provide a single question and answer pair based on the examples. | ||
start_tags: [""] | ||
end_tags: [""] |
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
Oops, something went wrong.