Text Generation
Transformers
PyTorch
English
mistral
Generated from Trainer
text-generation-inference
Instructions to use Dans-DiscountModels/TinyMistral-v2.5-MiniPile-Guidelines-E1 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use Dans-DiscountModels/TinyMistral-v2.5-MiniPile-Guidelines-E1 with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="Dans-DiscountModels/TinyMistral-v2.5-MiniPile-Guidelines-E1")# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("Dans-DiscountModels/TinyMistral-v2.5-MiniPile-Guidelines-E1") model = AutoModelForCausalLM.from_pretrained("Dans-DiscountModels/TinyMistral-v2.5-MiniPile-Guidelines-E1") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use Dans-DiscountModels/TinyMistral-v2.5-MiniPile-Guidelines-E1 with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "Dans-DiscountModels/TinyMistral-v2.5-MiniPile-Guidelines-E1" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Dans-DiscountModels/TinyMistral-v2.5-MiniPile-Guidelines-E1", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/Dans-DiscountModels/TinyMistral-v2.5-MiniPile-Guidelines-E1
- SGLang
How to use Dans-DiscountModels/TinyMistral-v2.5-MiniPile-Guidelines-E1 with SGLang:
Install from pip and serve model
# Install SGLang from pip: pip install sglang # Start the SGLang server: python3 -m sglang.launch_server \ --model-path "Dans-DiscountModels/TinyMistral-v2.5-MiniPile-Guidelines-E1" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Dans-DiscountModels/TinyMistral-v2.5-MiniPile-Guidelines-E1", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker images
docker run --gpus all \ --shm-size 32g \ -p 30000:30000 \ -v ~/.cache/huggingface:/root/.cache/huggingface \ --env "HF_TOKEN=<secret>" \ --ipc=host \ lmsysorg/sglang:latest \ python3 -m sglang.launch_server \ --model-path "Dans-DiscountModels/TinyMistral-v2.5-MiniPile-Guidelines-E1" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Dans-DiscountModels/TinyMistral-v2.5-MiniPile-Guidelines-E1", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use Dans-DiscountModels/TinyMistral-v2.5-MiniPile-Guidelines-E1 with Docker Model Runner:
docker model run hf.co/Dans-DiscountModels/TinyMistral-v2.5-MiniPile-Guidelines-E1
Create README.md
Browse files
README.md
ADDED
|
@@ -0,0 +1,152 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
tags:
|
| 3 |
+
- generated_from_trainer
|
| 4 |
+
base_model: Locutusque/TinyMistral-248M-v2.5
|
| 5 |
+
model-index:
|
| 6 |
+
- name: TinyMistral-v2.5-MiniPile-Guidelines-E1/
|
| 7 |
+
results: []
|
| 8 |
+
datasets:
|
| 9 |
+
- JeanKaddour/minipile
|
| 10 |
+
- epfl-llm/guidelines
|
| 11 |
+
license: apache-2.0
|
| 12 |
+
language:
|
| 13 |
+
- en
|
| 14 |
+
---
|
| 15 |
+
|
| 16 |
+
<!-- This model card has been generated automatically according to the information the Trainer had access to. You
|
| 17 |
+
should probably proofread and complete it, then remove this comment. -->
|
| 18 |
+
|
| 19 |
+
[<img src="https://raw.githubusercontent.com/OpenAccess-AI-Collective/axolotl/main/image/axolotl-badge-web.png" alt="Built with Axolotl" width="200" height="32"/>](https://github.com/OpenAccess-AI-Collective/axolotl)
|
| 20 |
+
<details><summary>See axolotl config</summary>
|
| 21 |
+
|
| 22 |
+
axolotl version: `0.3.0`
|
| 23 |
+
```yaml
|
| 24 |
+
base_model: Locutusque/TinyMistral-248M-v2.5
|
| 25 |
+
model_type: MistralForCausalLM
|
| 26 |
+
is_mistral_derived_model: true
|
| 27 |
+
|
| 28 |
+
load_in_8bit: false
|
| 29 |
+
load_in_4bit: false
|
| 30 |
+
strict: false
|
| 31 |
+
|
| 32 |
+
dataset_processes: 20
|
| 33 |
+
|
| 34 |
+
datasets:
|
| 35 |
+
- path: epfl-llm/guidelines
|
| 36 |
+
type: completion
|
| 37 |
+
field: clean_text
|
| 38 |
+
- path: JeanKaddour/minipile
|
| 39 |
+
type: completion
|
| 40 |
+
field: text
|
| 41 |
+
|
| 42 |
+
dataset_prepared_path: TinyMistral-FFT-data
|
| 43 |
+
val_set_size: 0.001
|
| 44 |
+
output_dir: ./TinyMistral-FFT
|
| 45 |
+
|
| 46 |
+
sequence_len: 2048
|
| 47 |
+
sample_packing: false
|
| 48 |
+
pad_to_sequence_len: true
|
| 49 |
+
|
| 50 |
+
adapter:
|
| 51 |
+
lora_model_dir:
|
| 52 |
+
lora_r:
|
| 53 |
+
lora_alpha:
|
| 54 |
+
lora_dropout:
|
| 55 |
+
lora_target_linear:
|
| 56 |
+
lora_fan_in_fan_out:
|
| 57 |
+
|
| 58 |
+
# wandb configuration
|
| 59 |
+
wandb_project: TinyMistral-FFT
|
| 60 |
+
wandb_watch:
|
| 61 |
+
wandb_run_id:
|
| 62 |
+
wandb_log_model:
|
| 63 |
+
|
| 64 |
+
gradient_accumulation_steps: 8
|
| 65 |
+
micro_batch_size: 1
|
| 66 |
+
num_epochs: 1
|
| 67 |
+
optimizer: paged_adamw_32bit
|
| 68 |
+
lr_scheduler: constant
|
| 69 |
+
cosine_min_lr_ratio:
|
| 70 |
+
|
| 71 |
+
learning_rate: 0.00005
|
| 72 |
+
|
| 73 |
+
train_on_inputs: true
|
| 74 |
+
group_by_length: false
|
| 75 |
+
bf16: false
|
| 76 |
+
fp16: false
|
| 77 |
+
tf32: true
|
| 78 |
+
|
| 79 |
+
gradient_checkpointing: false
|
| 80 |
+
early_stopping_patience:
|
| 81 |
+
resume_from_checkpoint:
|
| 82 |
+
auto_resume_from_checkpoints: false
|
| 83 |
+
local_rank:
|
| 84 |
+
logging_steps: 1
|
| 85 |
+
xformers_attention:
|
| 86 |
+
flash_attention: false
|
| 87 |
+
flash_attn_cross_entropy: false
|
| 88 |
+
flash_attn_rms_norm: true
|
| 89 |
+
flash_attn_fuse_qkv: false
|
| 90 |
+
flash_attn_fuse_mlp: true
|
| 91 |
+
|
| 92 |
+
warmup_steps: 10
|
| 93 |
+
evals_per_epoch: 100
|
| 94 |
+
# eval_steps: 10
|
| 95 |
+
eval_table_size:
|
| 96 |
+
saves_per_epoch: 50
|
| 97 |
+
debug:
|
| 98 |
+
deepspeed: #deepspeed/zero2.json # multi-gpu only
|
| 99 |
+
weight_decay: 0
|
| 100 |
+
|
| 101 |
+
# tokens:
|
| 102 |
+
|
| 103 |
+
|
| 104 |
+
special_tokens:
|
| 105 |
+
bos_token: "<|bos|>"
|
| 106 |
+
eos_token: "<|endoftext|>"
|
| 107 |
+
unk_token: "<unk>"
|
| 108 |
+
```
|
| 109 |
+
|
| 110 |
+
</details><br>
|
| 111 |
+
|
| 112 |
+
# TinyMistral-StructureEvaluator
|
| 113 |
+
|
| 114 |
+
This model was further trained on the epfl-llm/guidelines and JeanKaddour/minipile datasets.
|
| 115 |
+
|
| 116 |
+
## Model description
|
| 117 |
+
|
| 118 |
+
More information needed
|
| 119 |
+
|
| 120 |
+
## Intended uses & limitations
|
| 121 |
+
|
| 122 |
+
More information needed
|
| 123 |
+
|
| 124 |
+
## Training and evaluation data
|
| 125 |
+
|
| 126 |
+
More information needed
|
| 127 |
+
|
| 128 |
+
## Training procedure
|
| 129 |
+
|
| 130 |
+
### Training hyperparameters
|
| 131 |
+
|
| 132 |
+
The following hyperparameters were used during training:
|
| 133 |
+
- learning_rate: 5e-05
|
| 134 |
+
- train_batch_size: 1
|
| 135 |
+
- eval_batch_size: 1
|
| 136 |
+
- seed: 42
|
| 137 |
+
- gradient_accumulation_steps: 8
|
| 138 |
+
- total_train_batch_size: 8
|
| 139 |
+
- optimizer: Adam with betas=(0.9,0.999) and epsilon=1e-08
|
| 140 |
+
- lr_scheduler_type: constant
|
| 141 |
+
- training_steps: 197279
|
| 142 |
+
|
| 143 |
+
### Training results
|
| 144 |
+
|
| 145 |
+
|
| 146 |
+
|
| 147 |
+
### Framework versions
|
| 148 |
+
|
| 149 |
+
- Transformers 4.37.0.dev0
|
| 150 |
+
- Pytorch 2.0.1+cu117
|
| 151 |
+
- Datasets 2.15.0
|
| 152 |
+
- Tokenizers 0.15.0
|