Text Generation
Transformers
PyTorch
TensorBoard
Safetensors
llama
Generated from Trainer
text-generation-inference
Instructions to use flytech/devchat-llama-7b with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use flytech/devchat-llama-7b with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="flytech/devchat-llama-7b")# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("flytech/devchat-llama-7b") model = AutoModelForCausalLM.from_pretrained("flytech/devchat-llama-7b") - Notebooks
- Google Colab
- Kaggle
- Local Apps
- vLLM
How to use flytech/devchat-llama-7b with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "flytech/devchat-llama-7b" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "flytech/devchat-llama-7b", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/flytech/devchat-llama-7b
- SGLang
How to use flytech/devchat-llama-7b 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 "flytech/devchat-llama-7b" \ --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": "flytech/devchat-llama-7b", "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 "flytech/devchat-llama-7b" \ --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": "flytech/devchat-llama-7b", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use flytech/devchat-llama-7b with Docker Model Runner:
docker model run hf.co/flytech/devchat-llama-7b
Model save
Browse files
README.md
CHANGED
|
@@ -17,7 +17,7 @@ This model is a fine-tuned version of [openlm-research/open_llama_7b_v2](https:/
|
|
| 17 |
|
| 18 |
## Model description
|
| 19 |
|
| 20 |
-
|
| 21 |
|
| 22 |
## Intended uses & limitations
|
| 23 |
|
|
@@ -32,16 +32,16 @@ More information needed
|
|
| 32 |
### Training hyperparameters
|
| 33 |
|
| 34 |
The following hyperparameters were used during training:
|
| 35 |
-
- learning_rate: 0.
|
| 36 |
- train_batch_size: 8
|
| 37 |
-
- eval_batch_size:
|
| 38 |
- seed: 42
|
| 39 |
- gradient_accumulation_steps: 2
|
| 40 |
- total_train_batch_size: 16
|
| 41 |
- optimizer: Adam with betas=(0.9,0.999) and epsilon=1e-08
|
| 42 |
- lr_scheduler_type: constant
|
| 43 |
- lr_scheduler_warmup_ratio: 0.1
|
| 44 |
-
- num_epochs:
|
| 45 |
|
| 46 |
### Training results
|
| 47 |
|
|
|
|
| 17 |
|
| 18 |
## Model description
|
| 19 |
|
| 20 |
+
More information needed
|
| 21 |
|
| 22 |
## Intended uses & limitations
|
| 23 |
|
|
|
|
| 32 |
### Training hyperparameters
|
| 33 |
|
| 34 |
The following hyperparameters were used during training:
|
| 35 |
+
- learning_rate: 0.0002
|
| 36 |
- train_batch_size: 8
|
| 37 |
+
- eval_batch_size: 8
|
| 38 |
- seed: 42
|
| 39 |
- gradient_accumulation_steps: 2
|
| 40 |
- total_train_batch_size: 16
|
| 41 |
- optimizer: Adam with betas=(0.9,0.999) and epsilon=1e-08
|
| 42 |
- lr_scheduler_type: constant
|
| 43 |
- lr_scheduler_warmup_ratio: 0.1
|
| 44 |
+
- num_epochs: 3
|
| 45 |
|
| 46 |
### Training results
|
| 47 |
|
adapter_model.safetensors
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 40036040
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:9e43cc0c9ffc839503ed86081c685d255f2b96e031049a8035a433511935f8f7
|
| 3 |
size 40036040
|
events.out.tfevents.1694220463.ef7f542c87ff.577235.0
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
-
size
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:b67dc17e0018218fcf3c0f63e77e72b5cd4aadd6940740a832052fef9af2db7f
|
| 3 |
+
size 8269
|
events.out.tfevents.1694220463.ef7f542c87ff.577235.1
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
-
size
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:9069aa9df906a360d6ec9c13bec18f4a515699066943c60f6baa4dcfb5a55ba3
|
| 3 |
+
size 8269
|