Text Generation
GGUF
English
code
coding
programming
reasoning
small-model
efficient
local
qwen
qwen3
qwen3.5
4b
small
developer
coding-assistant
python
debugging
daily-use
localai
ai
gpt
dqnlabs
dqngpt
lmstudio
ollama
conversational
Instructions to use DQN-Labs-AI/dqnCode-v1 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- llama.cpp
How to use DQN-Labs-AI/dqnCode-v1 with llama.cpp:
Install (macOS, Linux)
curl -LsSf https://llama.app/install.sh | sh # Start a local OpenAI-compatible server with a web UI: llama serve -hf DQN-Labs-AI/dqnCode-v1:Q4_K_M # Run inference directly in the terminal: llama cli -hf DQN-Labs-AI/dqnCode-v1:Q4_K_M
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama serve -hf DQN-Labs-AI/dqnCode-v1:Q4_K_M # Run inference directly in the terminal: llama cli -hf DQN-Labs-AI/dqnCode-v1:Q4_K_M
Build from source code
git clone https://github.com/ggml-org/llama.cpp.git cd llama.cpp cmake -B build cmake --build build -j --target llama-app # Start a local OpenAI-compatible server with a web UI: ./build/bin/llama serve -hf DQN-Labs-AI/dqnCode-v1:Q4_K_M # Run inference directly in the terminal: ./build/bin/llama cli -hf DQN-Labs-AI/dqnCode-v1:Q4_K_M
Use Docker
docker model run hf.co/DQN-Labs-AI/dqnCode-v1:Q4_K_M
- Llama new
- LM Studio
- Jan
- vLLM
How to use DQN-Labs-AI/dqnCode-v1 with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "DQN-Labs-AI/dqnCode-v1" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "DQN-Labs-AI/dqnCode-v1", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/DQN-Labs-AI/dqnCode-v1:Q4_K_M
- Ollama
How to use DQN-Labs-AI/dqnCode-v1 with Ollama:
ollama run hf.co/DQN-Labs-AI/dqnCode-v1:Q4_K_M
- Unsloth Desktop
- Pi
How to use DQN-Labs-AI/dqnCode-v1 with Pi:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf DQN-Labs-AI/dqnCode-v1:Q4_K_M
Configure the model in Pi
# Install Pi: npm install -g @earendil-works/pi-coding-agent # Add to ~/.pi/agent/models.json: { "providers": { "llama-cpp": { "baseUrl": "http://localhost:8080/v1", "api": "openai-completions", "apiKey": "none", "models": [ { "id": "DQN-Labs-AI/dqnCode-v1:Q4_K_M" } ] } } }Run Pi
# Start Pi in your project directory: pi
- Docker Model Runner
How to use DQN-Labs-AI/dqnCode-v1 with Docker Model Runner:
docker model run hf.co/DQN-Labs-AI/dqnCode-v1:Q4_K_M
- Lemonade
How to use DQN-Labs-AI/dqnCode-v1 with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull DQN-Labs-AI/dqnCode-v1:Q4_K_M
Run and chat with the model
lemonade run user.dqnCode-v1-Q4_K_M
List all available models
lemonade list
- Hermes Agent
How to use DQN-Labs-AI/dqnCode-v1 with Hermes Agent:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf DQN-Labs-AI/dqnCode-v1:Q4_K_M
Configure Hermes
# Install Hermes: curl -fsSL https://hermes-agent.nousresearch.com/install.sh | bash hermes setup # Point Hermes at the local server: hermes config set model.provider custom hermes config set model.base_url http://127.0.0.1:8080/v1 hermes config set model.default DQN-Labs-AI/dqnCode-v1:Q4_K_M
Run Hermes
hermes
- Atomic Chat
- OpenClaw
How to use DQN-Labs-AI/dqnCode-v1 with OpenClaw:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf DQN-Labs-AI/dqnCode-v1:Q4_K_M
Configure OpenClaw
# Install OpenClaw: npm install -g openclaw@latest # Register the local server and set it as the default model: openclaw onboard --non-interactive --mode local \ --auth-choice custom-api-key \ --custom-base-url http://127.0.0.1:8080/v1 \ --custom-model-id "DQN-Labs-AI/dqnCode-v1:Q4_K_M" \ --custom-provider-id llama-cpp \ --custom-compatibility openai \ --custom-text-input \ --accept-risk \ --skip-health
Run OpenClaw
openclaw agent --local --agent main --message "Hello from Hugging Face"
Create README.md
Browse files
README.md
ADDED
|
@@ -0,0 +1,197 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
license: apache-2.0
|
| 3 |
+
language:
|
| 4 |
+
- en
|
| 5 |
+
tags:
|
| 6 |
+
- code
|
| 7 |
+
- coding
|
| 8 |
+
- programming
|
| 9 |
+
- reasoning
|
| 10 |
+
- small-model
|
| 11 |
+
- efficient
|
| 12 |
+
- local
|
| 13 |
+
- qwen
|
| 14 |
+
- qwen3
|
| 15 |
+
- qwen3.5
|
| 16 |
+
- 4b
|
| 17 |
+
- small
|
| 18 |
+
- developer
|
| 19 |
+
- coding-assistant
|
| 20 |
+
- python
|
| 21 |
+
- debugging
|
| 22 |
+
- daily-use
|
| 23 |
+
- localai
|
| 24 |
+
- ai
|
| 25 |
+
- gpt
|
| 26 |
+
- dqnlabs
|
| 27 |
+
- dqngpt
|
| 28 |
+
- gguf
|
| 29 |
+
- lmstudio
|
| 30 |
+
- ollama
|
| 31 |
+
pipeline_tag: text-generation
|
| 32 |
+
---
|
| 33 |
+
|
| 34 |
+
# dqnCode-v1
|
| 35 |
+
|
| 36 |
+
dqnCode-v1 is a 4B-parameter language model designed for fast, clear, and practical coding assistance.
|
| 37 |
+
|
| 38 |
+
It focuses on writing, fixing, and explaining code efficiently, with minimal verbosity and strong real-world usefulness. It is optimized for everyday programming tasks with low latency and concise outputs.
|
| 39 |
+
|
| 40 |
+
---
|
| 41 |
+
|
| 42 |
+
## Benchmark
|
| 43 |
+
|
| 44 |
+
dqnCode-v1 is positioned as a high-performance compact coding model, with strong results on standard code generation benchmarks. It is trained with simple prompts in mind, so you don't need to be a developer to use it!
|
| 45 |
+
|
| 46 |
+
### HumanEval
|
| 47 |
+
|
| 48 |
+
- **pass@1:** 63.4%
|
| 49 |
+
|
| 50 |
+
This score places dqnCode-v1 among the strongest models in the 4B parameter class for coding tasks (only beaten by Gemma 3 4B in the 4B or below models class!)
|
| 51 |
+
|
| 52 |
+
| Model | Provider | HumanEval (pass@1) |
|
| 53 |
+
|--------------------------|-----------------|--------------------|
|
| 54 |
+
| GPT-3.5 Turbo | OpenAI | 68% |
|
| 55 |
+
| GPT-4 | OpenAI | 67% |
|
| 56 |
+
| dqnCode v1 (4B) | DQN Labs | 63.4% |
|
| 57 |
+
| Phi-3.5-mini-instruct | Microsoft | 62.8% |
|
| 58 |
+
| DeepSeek Coder 33B | DeepSeek | 52.4% |
|
| 59 |
+
| Gemma 2 27B | Google | 51.8% |
|
| 60 |
+
| Nous Hermes 3 405B | Nous Research | 51.4% |
|
| 61 |
+
---
|
| 62 |
+
|
| 63 |
+
## Benchmark Context
|
| 64 |
+
|
| 65 |
+
- Evaluated on HumanEval (Python code generation benchmark)
|
| 66 |
+
- Focused on functional correctness of generated code
|
| 67 |
+
- Designed to reflect real-world coding performance in a compact model
|
| 68 |
+
|
| 69 |
+
---
|
| 70 |
+
|
| 71 |
+
## Positioning
|
| 72 |
+
|
| 73 |
+
dqnCode-v1 is designed to deliver coding performance comparable to significantly larger models while maintaining a small footprint.
|
| 74 |
+
|
| 75 |
+
- Approaches GPT-3.5 / GPT-4-level performance on many practical coding tasks
|
| 76 |
+
- Achieves strong performance with significantly fewer parameters
|
| 77 |
+
- Optimized for fast local inference and real-world development workflows
|
| 78 |
+
- Excellent at all languages, especially HTML-CSS-JS, Python, Java, and more!
|
| 79 |
+
|
| 80 |
+
|
| 81 |
+
## Model Description
|
| 82 |
+
|
| 83 |
+
- **Model type:** Causal Language Model
|
| 84 |
+
- **Parameters:** 4B
|
| 85 |
+
- **Primary use:** Coding and programming assistance
|
| 86 |
+
- **Style:** Direct code generation with minimal explanation
|
| 87 |
+
|
| 88 |
+
dqnCode-v1 4B is optimized for practical coding workflows rather than long-form development or benchmark performance.
|
| 89 |
+
|
| 90 |
+
---
|
| 91 |
+
|
| 92 |
+
## Intended Uses
|
| 93 |
+
|
| 94 |
+
### Direct Use
|
| 95 |
+
|
| 96 |
+
- Writing code snippets
|
| 97 |
+
- Debugging errors
|
| 98 |
+
- Explaining code logic
|
| 99 |
+
- Converting code between languages
|
| 100 |
+
- Assisting with small to medium programming tasks
|
| 101 |
+
- Competitive programming support
|
| 102 |
+
|
| 103 |
+
---
|
| 104 |
+
|
| 105 |
+
## Key Characteristics
|
| 106 |
+
|
| 107 |
+
- Produces clean and functional code
|
| 108 |
+
- Prioritizes correctness and simplicity
|
| 109 |
+
- Minimizes unnecessary explanation
|
| 110 |
+
- Strong at debugging and fixing issues
|
| 111 |
+
- Designed for consistent outputs across common coding tasks
|
| 112 |
+
- Excellent instruction following and stability.
|
| 113 |
+
- Trained with simple prompts in mind, so you don't need to be a developer to use it!
|
| 114 |
+
|
| 115 |
+
---
|
| 116 |
+
|
| 117 |
+
## Example
|
| 118 |
+
|
| 119 |
+
**Input**
|
| 120 |
+
```text
|
| 121 |
+
Write a Python function to check if a number is prime
|
| 122 |
+
```
|
| 123 |
+
|
| 124 |
+
**Output**
|
| 125 |
+
```python
|
| 126 |
+
def is_prime(n):
|
| 127 |
+
if n < 2:
|
| 128 |
+
return False
|
| 129 |
+
for i in range(2, int(n**0.5) + 1):
|
| 130 |
+
if n % i == 0:
|
| 131 |
+
return False
|
| 132 |
+
return True
|
| 133 |
+
```
|
| 134 |
+
|
| 135 |
+
---
|
| 136 |
+
|
| 137 |
+
**Input**
|
| 138 |
+
```text
|
| 139 |
+
Fix this code:
|
| 140 |
+
for i in range(5)
|
| 141 |
+
print(i)
|
| 142 |
+
```
|
| 143 |
+
|
| 144 |
+
**Output**
|
| 145 |
+
```python
|
| 146 |
+
for i in range(5):
|
| 147 |
+
print(i)
|
| 148 |
+
```
|
| 149 |
+
|
| 150 |
+
---
|
| 151 |
+
|
| 152 |
+
## Usage
|
| 153 |
+
|
| 154 |
+
This model is available on many platforms and is compatible with many formats.
|
| 155 |
+
|
| 156 |
+
The GGUF format is compatible with llama.cpp and LM Studio.
|
| 157 |
+
Other formats include MLX (LM Studio, optimized for Apple devices), and HF (universal compatibility).
|
| 158 |
+
|
| 159 |
+
---
|
| 160 |
+
|
| 161 |
+
## Training Details
|
| 162 |
+
|
| 163 |
+
dqnCode-v1 is fine-tuned for practical coding tasks and efficient problem solving.
|
| 164 |
+
|
| 165 |
+
The training process emphasizes:
|
| 166 |
+
|
| 167 |
+
- Functional correctness
|
| 168 |
+
- Minimal and clean outputs
|
| 169 |
+
- Real-world coding scenarios
|
| 170 |
+
- Debugging and code repair
|
| 171 |
+
|
| 172 |
+
---
|
| 173 |
+
|
| 174 |
+
## Limitations
|
| 175 |
+
|
| 176 |
+
- Limited performance on very large or complex codebases
|
| 177 |
+
- Not optimized for long-form software architecture design
|
| 178 |
+
- May simplify explanations rather than provide deep theoretical detail
|
| 179 |
+
|
| 180 |
+
---
|
| 181 |
+
|
| 182 |
+
## Efficiency
|
| 183 |
+
|
| 184 |
+
dqnCode-v1 is designed to run efficiently on consumer hardware, with support for quantized formats.
|
| 185 |
+
|
| 186 |
+
---
|
| 187 |
+
|
| 188 |
+
## License
|
| 189 |
+
|
| 190 |
+
Apache 2.0
|
| 191 |
+
|
| 192 |
+
---
|
| 193 |
+
|
| 194 |
+
## Author
|
| 195 |
+
|
| 196 |
+
Developed by DQN Labs.
|
| 197 |
+
This model card was generated with the help of dqnGPT v0.2!
|