Instructions to use OpenBuddy/openbuddy-llama2-13b-v8.1-fp16 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use OpenBuddy/openbuddy-llama2-13b-v8.1-fp16 with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="OpenBuddy/openbuddy-llama2-13b-v8.1-fp16")# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("OpenBuddy/openbuddy-llama2-13b-v8.1-fp16") model = AutoModelForCausalLM.from_pretrained("OpenBuddy/openbuddy-llama2-13b-v8.1-fp16", device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use OpenBuddy/openbuddy-llama2-13b-v8.1-fp16 with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "OpenBuddy/openbuddy-llama2-13b-v8.1-fp16" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "OpenBuddy/openbuddy-llama2-13b-v8.1-fp16", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/OpenBuddy/openbuddy-llama2-13b-v8.1-fp16
- SGLang
How to use OpenBuddy/openbuddy-llama2-13b-v8.1-fp16 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 "OpenBuddy/openbuddy-llama2-13b-v8.1-fp16" \ --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": "OpenBuddy/openbuddy-llama2-13b-v8.1-fp16", "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 "OpenBuddy/openbuddy-llama2-13b-v8.1-fp16" \ --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": "OpenBuddy/openbuddy-llama2-13b-v8.1-fp16", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use OpenBuddy/openbuddy-llama2-13b-v8.1-fp16 with Docker Model Runner:
docker model run hf.co/OpenBuddy/openbuddy-llama2-13b-v8.1-fp16
这个模型和llama2的关系和差异是啥
#1
by songt - opened
vocab是否做了中文的适配
是否做了中文的二次预训练、SFT
songt changed discussion status to closed
songt changed discussion status to open
扩充了接近6000个CJK字词。
为了尽可能保留模型原有知识,无二次预训练,基于 llama2-13b 进行 SFT,使用了 一百万样本数的多语言多轮对话数据集。
扩充了接近6000个CJK字词。
为了尽可能保留模型原有知识,无二次预训练,基于 llama2-13b 进行 SFT,使用了 一百万样本数的多语言多轮对话数据集。
这个信息挺重要的,希望可以放到model card或github上
不对,我看错了,加上了6k是这么多
楼主是说,扩充了此表但是没有在此pretrain吗?那resize embedding之后岂不是权重都是随机权重了?这应该很难直接sft吧
楼主是说,扩充了此表但是没有在此pretrain吗?那resize embedding之后岂不是权重都是随机权重了?这应该很难直接sft吧
我们在SFT过程中调整的token embedding,目前来看效果还行