-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[GenAI] pack GenAI core package (#7246)
* update * enable llama3_2 * fix tests * pack GenAI core
- Loading branch information
1 parent
817a77f
commit be1e428
Showing
15 changed files
with
591 additions
and
21 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,4 @@ | ||
// See https://aka.ms/new-console-template for more information | ||
using Microsoft.ML.GenAI.Samples.Mistral; | ||
using Microsoft.ML.GenAI.Samples.Phi3Mini; | ||
using Microsoft.ML.GenAI.Samples.Llama; | ||
|
||
await Mistral_7B_Instruct.WeatherChatAsync(); | ||
await LlamaSample.RunLlama(@"C:\Users\xiaoyuz\source\repos\Llama-3.2-3B-Instruct"); |
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
35 changes: 35 additions & 0 deletions
35
src/Microsoft.ML.GenAI.LLaMA/Resource/Config/meta-llama-3.2-1B-Instruct.json
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,35 @@ | ||
{ | ||
"attention_bias": false, | ||
"attention_dropout": 0.0, | ||
"bos_token_id": 128000, | ||
"eos_token_id": [ | ||
128001, | ||
128008, | ||
128009 | ||
], | ||
"head_dim": 64, | ||
"hidden_act": "silu", | ||
"hidden_size": 2048, | ||
"initializer_range": 0.02, | ||
"intermediate_size": 8192, | ||
"max_position_embeddings": 131072, | ||
"mlp_bias": false, | ||
"model_type": "llama", | ||
"num_attention_heads": 32, | ||
"num_hidden_layers": 16, | ||
"num_key_value_heads": 8, | ||
"pretraining_tp": 1, | ||
"rms_norm_eps": 1e-05, | ||
"rope_scaling": { | ||
"factor": 32.0, | ||
"high_freq_factor": 4.0, | ||
"low_freq_factor": 1.0, | ||
"original_max_position_embeddings": 8192, | ||
"rope_type": "llama3" | ||
}, | ||
"rope_theta": 500000.0, | ||
"tie_word_embeddings": true, | ||
"torch_dtype": "bfloat16", | ||
"use_cache": true, | ||
"vocab_size": 128256 | ||
} |
35 changes: 35 additions & 0 deletions
35
src/Microsoft.ML.GenAI.LLaMA/Resource/Config/meta-llama-3.2-3B-Instruct.json
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,35 @@ | ||
{ | ||
"attention_bias": false, | ||
"attention_dropout": 0.0, | ||
"bos_token_id": 128000, | ||
"eos_token_id": [ | ||
128001, | ||
128008, | ||
128009 | ||
], | ||
"head_dim": 128, | ||
"hidden_act": "silu", | ||
"hidden_size": 3072, | ||
"initializer_range": 0.02, | ||
"intermediate_size": 8192, | ||
"max_position_embeddings": 131072, | ||
"mlp_bias": false, | ||
"model_type": "llama", | ||
"num_attention_heads": 24, | ||
"num_hidden_layers": 28, | ||
"num_key_value_heads": 8, | ||
"pretraining_tp": 1, | ||
"rms_norm_eps": 1e-05, | ||
"rope_scaling": { | ||
"factor": 32.0, | ||
"high_freq_factor": 4.0, | ||
"low_freq_factor": 1.0, | ||
"original_max_position_embeddings": 8192, | ||
"rope_type": "llama3" | ||
}, | ||
"rope_theta": 500000.0, | ||
"tie_word_embeddings": true, | ||
"torch_dtype": "bfloat16", | ||
"use_cache": true, | ||
"vocab_size": 128256 | ||
} |
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
Oops, something went wrong.