Update README.md
Browse files
README.md
CHANGED
|
@@ -1,200 +1,90 @@
|
|
| 1 |
---
|
| 2 |
language:
|
| 3 |
-
- en
|
| 4 |
license: other
|
| 5 |
library_name: transformers
|
| 6 |
pipeline_tag: text-generation
|
| 7 |
tags:
|
| 8 |
-
-
|
| 9 |
-
-
|
| 10 |
-
-
|
| 11 |
-
-
|
| 12 |
-
-
|
| 13 |
-
-
|
| 14 |
-
-
|
| 15 |
-
-
|
| 16 |
-
-
|
| 17 |
base_model:
|
| 18 |
-
- tencent/Hunyuan-0.5B-Instruct
|
| 19 |
-
model-index:
|
| 20 |
-
- name: Hunyuan-PythonGOD-0.5B
|
| 21 |
-
results: []
|
| 22 |
datasets:
|
| 23 |
-
- WithinUsAI/Python_GOD_Coder_Omniforge_AI_12k
|
| 24 |
-
- WithinUsAI/Python_GOD_Coder_5k
|
| 25 |
-
- WithinUsAI/Legend_Python_CoderV.1
|
|
|
|
|
|
|
|
|
|
| 26 |
---
|
| 27 |
|
| 28 |
-
# Hunyuan-PythonGOD-0.5B
|
| 29 |
|
| 30 |
-
Hunyuan-PythonGOD-0.5B is a Python-
|
| 31 |
|
| 32 |
-
This
|
| 33 |
|
| 34 |
## Model Details
|
| 35 |
|
| 36 |
-
###
|
| 37 |
-
|
| 38 |
-
- **Model name:** `gss1147/Hunyuan-PythonGOD-0.5B`
|
| 39 |
- **Base model:** `tencent/Hunyuan-0.5B-Instruct`
|
| 40 |
-
- **Architecture:**
|
| 41 |
-
- **
|
| 42 |
-
- **
|
| 43 |
-
- **
|
| 44 |
-
- **Weights format:** safetensors
|
| 45 |
-
- **Tensor type in repo:** F16
|
| 46 |
-
|
| 47 |
-
### Developed by
|
| 48 |
-
|
| 49 |
-
- **Shared by:** `gss1147`
|
| 50 |
-
|
| 51 |
-
### Finetuned from model
|
| 52 |
-
|
| 53 |
-
- `tencent/Hunyuan-0.5B-Instruct`
|
| 54 |
-
|
| 55 |
-
## Intended Uses
|
| 56 |
-
|
| 57 |
-
### Direct Use
|
| 58 |
-
|
| 59 |
-
This model is intended for:
|
| 60 |
-
|
| 61 |
-
- Python function generation
|
| 62 |
-
- Python script writing
|
| 63 |
-
- debugging-oriented coding help
|
| 64 |
-
- implementation tasks
|
| 65 |
-
- code completion
|
| 66 |
-
- coding chat assistants
|
| 67 |
-
- lightweight local or cloud inference where a small coding model is preferred
|
| 68 |
-
|
| 69 |
-
### Downstream Use
|
| 70 |
-
|
| 71 |
-
Possible downstream uses include:
|
| 72 |
-
|
| 73 |
-
- code copilots
|
| 74 |
-
- coding bots
|
| 75 |
-
- Python tutoring helpers
|
| 76 |
-
- automation script generation
|
| 77 |
-
- benchmark experimentation for small code LLMs
|
| 78 |
-
|
| 79 |
-
### Out-of-Scope Use
|
| 80 |
-
|
| 81 |
-
This model is not designed for:
|
| 82 |
-
|
| 83 |
-
- safety-critical code deployment without human review
|
| 84 |
-
- medical, legal, or financial decision support
|
| 85 |
-
- secure production code without auditing
|
| 86 |
-
- autonomous execution pipelines without sandboxing
|
| 87 |
-
- guaranteed factual or bug-free code generation
|
| 88 |
-
|
| 89 |
-
## Training Details
|
| 90 |
-
|
| 91 |
-
### Training Objective
|
| 92 |
-
|
| 93 |
-
This model was trained as a **full fine-tune**, not as an adapter-only release.
|
| 94 |
-
|
| 95 |
-
Based on the training workflow you described and the run logs you shared, this release is meant to represent:
|
| 96 |
|
| 97 |
-
|
| 98 |
-
-
|
| 99 |
-
-
|
| 100 |
-
-
|
| 101 |
-
- **standard exported Hugging Face model weights**
|
| 102 |
|
| 103 |
-
##
|
| 104 |
|
| 105 |
-
This
|
| 106 |
|
|
|
|
| 107 |
- `WithinUsAI/Python_GOD_Coder_Omniforge_AI_12k`
|
| 108 |
- `WithinUsAI/Python_GOD_Coder_5k`
|
| 109 |
- `WithinUsAI/Legend_Python_CoderV.1`
|
| 110 |
|
| 111 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
| 112 |
|
| 113 |
-
|
| 114 |
-
- **5,000 rows** from `Python_GOD_Coder_5k`
|
| 115 |
-
- **5,000 rows** from `Legend_Python_CoderV.1`
|
| 116 |
-
|
| 117 |
-
**Total rows:** **21,760**
|
| 118 |
-
|
| 119 |
-
### Training Procedure
|
| 120 |
-
|
| 121 |
-
From the training setup you shared, this model was trained with:
|
| 122 |
-
|
| 123 |
-
- **dual-GPU Kaggle training**
|
| 124 |
-
- **DeepSpeed-assisted distributed training**
|
| 125 |
-
- **full model fine-tuning**
|
| 126 |
-
- **evaluation during training**
|
| 127 |
-
- **final-save upload flow to Hugging Face**
|
| 128 |
-
|
| 129 |
-
### Sequence Length
|
| 130 |
-
|
| 131 |
-
- **Practical fine-tuning sequence length:** 4096 tokens
|
| 132 |
-
|
| 133 |
-
### Context Window Note
|
| 134 |
-
|
| 135 |
-
If the base model family exposes larger context metadata in config fields, that should not be taken as proof that the full fine-tuning run itself was performed at that larger length. This release should be treated as fine-tuned at **4096 tokens** unless revalidated separately.
|
| 136 |
-
|
| 137 |
-
## Evaluation
|
| 138 |
-
|
| 139 |
-
Formal benchmark results are not finalized in this card.
|
| 140 |
-
|
| 141 |
-
Benchmark attempts were made on free public coding benchmarks such as:
|
| 142 |
-
|
| 143 |
-
- HumanEval+
|
| 144 |
-
- MBPP+
|
| 145 |
-
- BigCodeBench-style workflows
|
| 146 |
-
|
| 147 |
-
However, based on the evaluation runs you shared, the harness setup encountered tool/runtime issues during some benchmark attempts, so this card does **not** claim final official benchmark scores yet.
|
| 148 |
-
|
| 149 |
-
### Observed Training Behavior
|
| 150 |
-
|
| 151 |
-
From the run logs you shared during training, the model showed:
|
| 152 |
-
|
| 153 |
-
- strong reduction in training loss over time
|
| 154 |
-
- strong reduction in eval loss over time
|
| 155 |
-
- stable continued learning well into the run
|
| 156 |
-
- increasingly code-specialized behavior relative to the base model
|
| 157 |
-
|
| 158 |
-
Examples from your shared eval progression included values around:
|
| 159 |
-
|
| 160 |
-
- ~0.2879 early in training
|
| 161 |
-
- ~0.1071
|
| 162 |
-
- ~0.0604
|
| 163 |
-
- ~0.0550
|
| 164 |
-
- ~0.0422
|
| 165 |
-
- ~0.0329
|
| 166 |
-
- ~0.0266
|
| 167 |
-
- ~0.0299
|
| 168 |
-
- ~0.0290
|
| 169 |
-
|
| 170 |
-
These are training/eval-run observations, not official public benchmark scores.
|
| 171 |
-
|
| 172 |
-
## How to Use
|
| 173 |
|
| 174 |
-
###
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 175 |
|
| 176 |
-
|
| 177 |
-
|
| 178 |
-
|
|
|
|
|
|
|
| 179 |
|
| 180 |
-
|
| 181 |
|
| 182 |
-
|
| 183 |
-
model = AutoModelForCausalLM.from_pretrained(
|
| 184 |
-
model_id,
|
| 185 |
-
trust_remote_code=True,
|
| 186 |
-
torch_dtype=torch.float16,
|
| 187 |
-
device_map="auto",
|
| 188 |
-
)
|
| 189 |
|
| 190 |
-
|
| 191 |
-
|
|
|
|
| 192 |
|
| 193 |
-
|
| 194 |
-
outputs = model.generate(
|
| 195 |
-
**inputs,
|
| 196 |
-
max_new_tokens=512,
|
| 197 |
-
do_sample=False,
|
| 198 |
-
)
|
| 199 |
|
| 200 |
-
|
|
|
|
|
|
| 1 |
---
|
| 2 |
language:
|
| 3 |
+
- en
|
| 4 |
license: other
|
| 5 |
library_name: transformers
|
| 6 |
pipeline_tag: text-generation
|
| 7 |
tags:
|
| 8 |
+
- gguf
|
| 9 |
+
- hunyuan
|
| 10 |
+
- python
|
| 11 |
+
- code-generation
|
| 12 |
+
- code-assistant
|
| 13 |
+
- instruct
|
| 14 |
+
- conversational
|
| 15 |
+
- causal-lm
|
| 16 |
+
- full-finetune
|
| 17 |
base_model:
|
| 18 |
+
- tencent/Hunyuan-0.5B-Instruct
|
|
|
|
|
|
|
|
|
|
| 19 |
datasets:
|
| 20 |
+
- WithinUsAI/Python_GOD_Coder_Omniforge_AI_12k
|
| 21 |
+
- WithinUsAI/Python_GOD_Coder_5k
|
| 22 |
+
- WithinUsAI/Legend_Python_CoderV.1
|
| 23 |
+
model-index:
|
| 24 |
+
- name: Hunyuan-PythonGOD-0.5B-GGUF
|
| 25 |
+
results: []
|
| 26 |
---
|
| 27 |
|
| 28 |
+
# Hunyuan-PythonGOD-0.5B-GGUF
|
| 29 |
|
| 30 |
+
**Hunyuan-PythonGOD-0.5B-GGUF** is a compact Python-specialized coding model released in GGUF format for lightweight local inference. It is derived from a full fine-tune of `tencent/Hunyuan-0.5B-Instruct` and is aimed at code generation, Python scripting, debugging help, implementation tasks, and coding-oriented chat workflows.
|
| 31 |
|
| 32 |
+
This repo provides quantized GGUF builds for efficient use with llama.cpp-compatible runtimes and other GGUF-serving backends.
|
| 33 |
|
| 34 |
## Model Details
|
| 35 |
|
| 36 |
+
### Base Model
|
|
|
|
|
|
|
| 37 |
- **Base model:** `tencent/Hunyuan-0.5B-Instruct`
|
| 38 |
+
- **Architecture:** Causal decoder-only language model
|
| 39 |
+
- **Parameter scale:** ~0.5B
|
| 40 |
+
- **Specialization:** Python coding and general code-assistant behavior
|
| 41 |
+
- **Release format:** GGUF
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 42 |
|
| 43 |
+
### Included Files
|
| 44 |
+
- `Hunyuan-PythonGOD-0.5B.Q4_K_M.gguf`
|
| 45 |
+
- `Hunyuan-PythonGOD-0.5B.Q5_K_M.gguf`
|
| 46 |
+
- `Hunyuan-PythonGOD-0.5B.f16.gguf`
|
|
|
|
| 47 |
|
| 48 |
+
## Training Summary
|
| 49 |
|
| 50 |
+
This GGUF release is based on a **full fine-tune**, not an adapter-only export.
|
| 51 |
|
| 52 |
+
### Training Datasets
|
| 53 |
- `WithinUsAI/Python_GOD_Coder_Omniforge_AI_12k`
|
| 54 |
- `WithinUsAI/Python_GOD_Coder_5k`
|
| 55 |
- `WithinUsAI/Legend_Python_CoderV.1`
|
| 56 |
|
| 57 |
+
### Training Characteristics
|
| 58 |
+
- Full-parameter fine-tuning
|
| 59 |
+
- Python/code-oriented instruction tuning
|
| 60 |
+
- Exported as standard model weights before GGUF conversion
|
| 61 |
+
- Intended for compact coding assistance and local inference experimentation
|
| 62 |
|
| 63 |
+
## Intended Uses
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 64 |
|
| 65 |
+
### Good Fits
|
| 66 |
+
- Python function generation
|
| 67 |
+
- Python script writing
|
| 68 |
+
- Debugging assistance
|
| 69 |
+
- Automation script drafting
|
| 70 |
+
- Code-oriented local assistants
|
| 71 |
+
- Small-model coding experiments
|
| 72 |
|
| 73 |
+
### Not Intended For
|
| 74 |
+
- Safety-critical software deployment without review
|
| 75 |
+
- Autonomous execution without sandboxing
|
| 76 |
+
- Guaranteed bug-free or secure code generation
|
| 77 |
+
- Medical, legal, or financial decision support
|
| 78 |
|
| 79 |
+
## Quantization Notes
|
| 80 |
|
| 81 |
+
This repo includes multiple tradeoff points:
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 82 |
|
| 83 |
+
- **Q4_K_M**: smaller footprint, faster/lighter inference
|
| 84 |
+
- **Q5_K_M**: stronger quality-to-size balance
|
| 85 |
+
- **F16**: highest fidelity in this repo, larger memory cost
|
| 86 |
|
| 87 |
+
## Example llama.cpp Usage
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 88 |
|
| 89 |
+
```bash
|
| 90 |
+
./llama-cli -m Hunyuan-PythonGOD-0.5B.Q5_K_M.gguf -p "Write a Python function that validates an email address." -n 256
|