FourOhFour/RP_Phase
Viewer • Updated • 27k • 52 • 3
How to use FourOhFour/Tulu-Tree-Fiddy-8B with Transformers:
# Use a pipeline as a high-level helper
from transformers import pipeline
pipe = pipeline("text-generation", model="FourOhFour/Tulu-Tree-Fiddy-8B")
messages = [
{"role": "user", "content": "Who are you?"},
]
pipe(messages) # Load model directly
from transformers import AutoTokenizer, AutoModelForCausalLM
tokenizer = AutoTokenizer.from_pretrained("FourOhFour/Tulu-Tree-Fiddy-8B")
model = AutoModelForCausalLM.from_pretrained("FourOhFour/Tulu-Tree-Fiddy-8B")
messages = [
{"role": "user", "content": "Who are you?"},
]
inputs = tokenizer.apply_chat_template(
messages,
add_generation_prompt=True,
tokenize=True,
return_dict=True,
return_tensors="pt",
).to(model.device)
outputs = model.generate(**inputs, max_new_tokens=40)
print(tokenizer.decode(outputs[0][inputs["input_ids"].shape[-1]:]))How to use FourOhFour/Tulu-Tree-Fiddy-8B with vLLM:
# Install vLLM from pip:
pip install vllm
# Start the vLLM server:
vllm serve "FourOhFour/Tulu-Tree-Fiddy-8B"
# Call the server using curl (OpenAI-compatible API):
curl -X POST "http://localhost:8000/v1/chat/completions" \
-H "Content-Type: application/json" \
--data '{
"model": "FourOhFour/Tulu-Tree-Fiddy-8B",
"messages": [
{
"role": "user",
"content": "What is the capital of France?"
}
]
}'docker model run hf.co/FourOhFour/Tulu-Tree-Fiddy-8B
How to use FourOhFour/Tulu-Tree-Fiddy-8B with SGLang:
# Install SGLang from pip:
pip install sglang
# Start the SGLang server:
python3 -m sglang.launch_server \
--model-path "FourOhFour/Tulu-Tree-Fiddy-8B" \
--host 0.0.0.0 \
--port 30000
# Call the server using curl (OpenAI-compatible API):
curl -X POST "http://localhost:30000/v1/chat/completions" \
-H "Content-Type: application/json" \
--data '{
"model": "FourOhFour/Tulu-Tree-Fiddy-8B",
"messages": [
{
"role": "user",
"content": "What is the capital of France?"
}
]
}'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 "FourOhFour/Tulu-Tree-Fiddy-8B" \
--host 0.0.0.0 \
--port 30000
# Call the server using curl (OpenAI-compatible API):
curl -X POST "http://localhost:30000/v1/chat/completions" \
-H "Content-Type: application/json" \
--data '{
"model": "FourOhFour/Tulu-Tree-Fiddy-8B",
"messages": [
{
"role": "user",
"content": "What is the capital of France?"
}
]
}'How to use FourOhFour/Tulu-Tree-Fiddy-8B with Docker Model Runner:
docker model run hf.co/FourOhFour/Tulu-Tree-Fiddy-8B
axolotl version: 0.5.2
base_model: huihui-ai/Llama-3.1-Tulu-3-8B-abliterated
model_type: AutoModelForCausalLM
tokenizer_type: AutoTokenizer
load_in_8bit: false
load_in_4bit: false
strict: false
datasets:
- path: FourOhFour/RP_Phase
type: chat_template
chat_template: llama3
roles_to_train: ["gpt"]
field_messages: conversations
message_field_role: from
message_field_content: value
train_on_eos: turn
shuffle_merged_datasets: true
default_system_message:
dataset_prepared_path:
val_set_size: 0.0125
output_dir: ./output/out
hub_model_id: jeiku/evil8b
hub_strategy: "all_checkpoints"
push_dataset_to_hub:
hf_use_auth_token: true
sequence_len: 8192
sample_packing: true
eval_sample_packing: false
pad_to_sequence_len:
wandb_project: evil
wandb_entity:
wandb_watch:
wandb_name: evil
wandb_log_model:
gradient_accumulation_steps: 16
micro_batch_size: 2
num_epochs: 2
optimizer: paged_adamw_8bit
lr_scheduler: cosine
learning_rate: 1e-5
train_on_inputs: false
group_by_length: false
bf16: auto
fp16:
tf32: false
gradient_checkpointing: true
gradient_checkpointing_kwargs:
use_reentrant: false
early_stopping_patience:
resume_from_checkpoint:
local_rank:
logging_steps: 1
xformers_attention:
flash_attention: true
warmup_steps: 10
evals_per_epoch: 2
eval_table_size:
eval_max_new_tokens:
saves_per_epoch: 1
debug:
deepspeed:
weight_decay: 0.05
fsdp:
fsdp_config:
special_tokens:
pad_token: <|finetune_right_pad_id|>
eos_token: <|eot_id|>
This model is a fine-tuned version of huihui-ai/Llama-3.1-Tulu-3-8B-abliterated on the FourOhFour/RP_Phase dataset. It achieves the following results on the evaluation set:
More information needed
More information needed
More information needed
The following hyperparameters were used during training:
| Training Loss | Epoch | Step | Validation Loss |
|---|---|---|---|
| 1.5229 | 0.5004 | 131 | 1.0768 |
| 2.103 | 1.0012 | 262 | 1.0223 |
| 1.3982 | 1.5016 | 393 | 1.0089 |