Instructions to use ccore/getcode-350m with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use ccore/getcode-350m with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="ccore/getcode-350m")# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("ccore/getcode-350m") model = AutoModelForCausalLM.from_pretrained("ccore/getcode-350m") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use ccore/getcode-350m with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "ccore/getcode-350m" # 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-350m", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/ccore/getcode-350m
- SGLang
How to use ccore/getcode-350m 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-350m" \ --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-350m", "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-350m" \ --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-350m", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use ccore/getcode-350m with Docker Model Runner:
docker model run hf.co/ccore/getcode-350m
Training in progress, epoch 3, 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 1324830880
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:35a123679c890b84cd07673e25fd00f78bbb627c3fa1a21dd6dc4a5636ddb2e3
|
| 3 |
size 1324830880
|
last-checkpoint/optimizer.pt
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 2649896030
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:df46f4182bc972bb1cf019b753cbd4198dc862768069655a3cdabe54e3932c09
|
| 3 |
size 2649896030
|
last-checkpoint/rng_state.pth
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 14244
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:1de4498a0de62c098b1cb8172b9b1220b1b62c62b8e96d152d6e567f4efc9a50
|
| 3 |
size 14244
|
last-checkpoint/scheduler.pt
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 1064
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:05e2d1622657dcc0dcd51ce58722af936ea03498ab99a1d3c8cd80669cb28819
|
| 3 |
size 1064
|
last-checkpoint/trainer_state.json
CHANGED
|
@@ -1,9 +1,9 @@
|
|
| 1 |
{
|
| 2 |
"best_metric": 2.4022321701049805,
|
| 3 |
"best_model_checkpoint": "./opt_trained1/checkpoint-268",
|
| 4 |
-
"epoch":
|
| 5 |
"eval_steps": 500,
|
| 6 |
-
"global_step":
|
| 7 |
"is_hyper_param_search": false,
|
| 8 |
"is_local_process_zero": true,
|
| 9 |
"is_world_process_zero": true,
|
|
@@ -30,6 +30,14 @@
|
|
| 30 |
"eval_samples_per_second": 13.822,
|
| 31 |
"eval_steps_per_second": 1.728,
|
| 32 |
"step": 536
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 33 |
}
|
| 34 |
],
|
| 35 |
"logging_steps": 500,
|
|
@@ -49,7 +57,7 @@
|
|
| 49 |
"attributes": {}
|
| 50 |
}
|
| 51 |
},
|
| 52 |
-
"total_flos":
|
| 53 |
"train_batch_size": 12,
|
| 54 |
"trial_name": null,
|
| 55 |
"trial_params": null
|
|
|
|
| 1 |
{
|
| 2 |
"best_metric": 2.4022321701049805,
|
| 3 |
"best_model_checkpoint": "./opt_trained1/checkpoint-268",
|
| 4 |
+
"epoch": 3.0,
|
| 5 |
"eval_steps": 500,
|
| 6 |
+
"global_step": 804,
|
| 7 |
"is_hyper_param_search": false,
|
| 8 |
"is_local_process_zero": true,
|
| 9 |
"is_world_process_zero": true,
|
|
|
|
| 30 |
"eval_samples_per_second": 13.822,
|
| 31 |
"eval_steps_per_second": 1.728,
|
| 32 |
"step": 536
|
| 33 |
+
},
|
| 34 |
+
{
|
| 35 |
+
"epoch": 3.0,
|
| 36 |
+
"eval_loss": 6.932552814483643,
|
| 37 |
+
"eval_runtime": 207.3048,
|
| 38 |
+
"eval_samples_per_second": 13.777,
|
| 39 |
+
"eval_steps_per_second": 1.722,
|
| 40 |
+
"step": 804
|
| 41 |
}
|
| 42 |
],
|
| 43 |
"logging_steps": 500,
|
|
|
|
| 57 |
"attributes": {}
|
| 58 |
}
|
| 59 |
},
|
| 60 |
+
"total_flos": 5.429845542887424e+16,
|
| 61 |
"train_batch_size": 12,
|
| 62 |
"trial_name": null,
|
| 63 |
"trial_params": null
|