Text Generation
Transformers
TensorBoard
Safetensors
opt
Generated from Trainer
text-generation-inference
Instructions to use ccore/getcode-v2 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use ccore/getcode-v2 with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="ccore/getcode-v2")# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("ccore/getcode-v2") model = AutoModelForCausalLM.from_pretrained("ccore/getcode-v2") - Notebooks
- Google Colab
- Kaggle
- Local Apps
- vLLM
How to use ccore/getcode-v2 with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "ccore/getcode-v2" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "ccore/getcode-v2", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/ccore/getcode-v2
- SGLang
How to use ccore/getcode-v2 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 "ccore/getcode-v2" \ --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": "ccore/getcode-v2", "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 "ccore/getcode-v2" \ --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": "ccore/getcode-v2", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use ccore/getcode-v2 with Docker Model Runner:
docker model run hf.co/ccore/getcode-v2
Training in progress, epoch 1, checkpoint
Browse files
last-checkpoint/model.safetensors
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 500979600
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:f746b5739e28ed8ae2191cfc3a28ef9dd9cbc44604b6789cd53bf9eda7d42a17
|
| 3 |
size 500979600
|
last-checkpoint/optimizer.pt
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 1002078330
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:f1fd180c6763f5d63483fe0a8c08012dd8b4705c90fd0583248dda0dc4539572
|
| 3 |
size 1002078330
|
last-checkpoint/trainer_state.json
CHANGED
|
@@ -1,5 +1,5 @@
|
|
| 1 |
{
|
| 2 |
-
"best_metric": 0.
|
| 3 |
"best_model_checkpoint": "./opt_trained3/checkpoint-1361",
|
| 4 |
"epoch": 1.0,
|
| 5 |
"eval_steps": 500,
|
|
@@ -10,24 +10,24 @@
|
|
| 10 |
"log_history": [
|
| 11 |
{
|
| 12 |
"epoch": 0.3675457134981163,
|
| 13 |
-
"grad_norm": 1.
|
| 14 |
"learning_rate": 9.189154158168292e-05,
|
| 15 |
-
"loss": 0.
|
| 16 |
"step": 500
|
| 17 |
},
|
| 18 |
{
|
| 19 |
"epoch": 0.7350914269962326,
|
| 20 |
-
"grad_norm": 1.
|
| 21 |
"learning_rate": 7.019605024359474e-05,
|
| 22 |
-
"loss": 0.
|
| 23 |
"step": 1000
|
| 24 |
},
|
| 25 |
{
|
| 26 |
"epoch": 1.0,
|
| 27 |
-
"eval_loss": 0.
|
| 28 |
-
"eval_runtime":
|
| 29 |
-
"eval_samples_per_second": 50.
|
| 30 |
-
"eval_steps_per_second": 12.
|
| 31 |
"step": 1361
|
| 32 |
}
|
| 33 |
],
|
|
|
|
| 1 |
{
|
| 2 |
+
"best_metric": 0.9197561740875244,
|
| 3 |
"best_model_checkpoint": "./opt_trained3/checkpoint-1361",
|
| 4 |
"epoch": 1.0,
|
| 5 |
"eval_steps": 500,
|
|
|
|
| 10 |
"log_history": [
|
| 11 |
{
|
| 12 |
"epoch": 0.3675457134981163,
|
| 13 |
+
"grad_norm": 1.09419846534729,
|
| 14 |
"learning_rate": 9.189154158168292e-05,
|
| 15 |
+
"loss": 0.9262,
|
| 16 |
"step": 500
|
| 17 |
},
|
| 18 |
{
|
| 19 |
"epoch": 0.7350914269962326,
|
| 20 |
+
"grad_norm": 1.0400797128677368,
|
| 21 |
"learning_rate": 7.019605024359474e-05,
|
| 22 |
+
"loss": 0.9246,
|
| 23 |
"step": 1000
|
| 24 |
},
|
| 25 |
{
|
| 26 |
"epoch": 1.0,
|
| 27 |
+
"eval_loss": 0.9197561740875244,
|
| 28 |
+
"eval_runtime": 761.7722,
|
| 29 |
+
"eval_samples_per_second": 50.796,
|
| 30 |
+
"eval_steps_per_second": 12.699,
|
| 31 |
"step": 1361
|
| 32 |
}
|
| 33 |
],
|
last-checkpoint/training_args.bin
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 5368
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:ae610ca3ba358abeebc6af3521a544fd6c45bd94a76da5a597144463f080a452
|
| 3 |
size 5368
|