How to use from
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 "InterstellarCG/HRM-Text-1B-Code-FT" \
    --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": "InterstellarCG/HRM-Text-1B-Code-FT",
		"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 "InterstellarCG/HRM-Text-1B-Code-FT" \
        --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": "InterstellarCG/HRM-Text-1B-Code-FT",
		"prompt": "Once upon a time,",
		"max_tokens": 512,
		"temperature": 0.5
	}'
Quick Links

HRM-Text-1B Code Fine-tuned

Fine-tuned from HRM-Text-1B on combined code dataset (192M tokens).

Training Details

  • Base: HRM-Text-1B (stacked from HTML/CSS 100k checkpoint)
  • Dataset: Combined code (Python, JavaScript, TypeScript, SQL, HTML/CSS)
  • Tokens: 192M
  • Epochs: 3
  • Learning rate: 1e-5

Capabilities

  • Python code generation
  • JavaScript functions
  • SQL queries
  • General QA (improved over base)

Limitations

  • Weak at React/TSX syntax
  • HTML/CSS output can be malformed
  • TypeScript interfaces not well-formed

Usage

from transformers import AutoModelForCausalLM, AutoTokenizer

model = AutoModelForCausalLM.from_pretrained("InterstellarCG/HRM-Text-1B-Code-FT")
tokenizer = AutoTokenizer.from_pretrained("InterstellarCG/HRM-Text-1B-Code-FT")

Evaluation

Task Base Fine-tuned
Python (is_prime) Garbage Correct
JS (reverse array) Garbage Correct
SQL (join query) Garbage Correct
QA (Paris capital) Garbage Correct
Downloads last month
18
Safetensors
Model size
1B params
Tensor type
BF16
ยท
Inference Providers NEW
This model isn't deployed by any Inference Provider. ๐Ÿ™‹ Ask for provider support