Instructions to use andreaskoepf/pythia-1.4b-gpt4all-pretrain with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use andreaskoepf/pythia-1.4b-gpt4all-pretrain with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="andreaskoepf/pythia-1.4b-gpt4all-pretrain")# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("andreaskoepf/pythia-1.4b-gpt4all-pretrain") model = AutoModelForCausalLM.from_pretrained("andreaskoepf/pythia-1.4b-gpt4all-pretrain") - Notebooks
- Google Colab
- Kaggle
- Local Apps
- vLLM
How to use andreaskoepf/pythia-1.4b-gpt4all-pretrain with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "andreaskoepf/pythia-1.4b-gpt4all-pretrain" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "andreaskoepf/pythia-1.4b-gpt4all-pretrain", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/andreaskoepf/pythia-1.4b-gpt4all-pretrain
- SGLang
How to use andreaskoepf/pythia-1.4b-gpt4all-pretrain 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 "andreaskoepf/pythia-1.4b-gpt4all-pretrain" \ --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": "andreaskoepf/pythia-1.4b-gpt4all-pretrain", "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 "andreaskoepf/pythia-1.4b-gpt4all-pretrain" \ --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": "andreaskoepf/pythia-1.4b-gpt4all-pretrain", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use andreaskoepf/pythia-1.4b-gpt4all-pretrain with Docker Model Runner:
docker model run hf.co/andreaskoepf/pythia-1.4b-gpt4all-pretrain
wandb: https://wandb.ai/open-assistant/supervised-finetuning/runs/t2adm3wu
checkpoint: 11000 step (2 epochs)
datasets:
pretrain:
weight_decay: 0.01
use_custom_sampler: true
sort_by_length: false
datasets:
- joke
- webgpt:
val_split: 0.1
- gpt4all:
val_split: 0.01
- alpaca:
val_split: 0.025
- code_alpaca:
val_split: 0.05
- minimath
- humaneval_mbpp_codegen_qa
- humaneval_mbpp_testgen_qa
- grade_school_math_instructions
- recipes
- cmu_wiki_qa
- oa_wiki_qa_bart_10000row
- prosocial_dialogue:
fraction: 0.1
- explain_prosocial:
fraction: 0.05
pythia:
pythia-1.4b-pretrain:
dtype: fp16
learning_rate: 6e-6
model_name: EleutherAI/pythia-1.4b-deduped
deepspeed_config: configs/zero_config_pretrain.json
weight_decay: 0.0
max_length: 2048
use_flash_attention: true
warmup_steps: 50
gradient_checkpointing: false
gradient_accumulation_steps: 1
per_device_train_batch_size: 16
per_device_eval_batch_size: 16
num_train_epochs: 2
save_total_limit: 2
command: deepspeed trainer_sft.py --configs defaults pretrain pythia-1.4b-pretrain --cache_dir .cache/ --output_dir .saved_models/pythia-1.4b-pre --residual_dropout 0.0 --deepspeed
- Downloads last month
- 250