Text Generation
Transformers
Safetensors
English
qwen2
bf16
bash
shell
command-generation
lora
easycommand
conversational
text-generation-inference
Instructions to use dirac-run/ec-1.5b with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use dirac-run/ec-1.5b with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="dirac-run/ec-1.5b") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("dirac-run/ec-1.5b") model = AutoModelForCausalLM.from_pretrained("dirac-run/ec-1.5b", device_map="auto") messages = [ {"role": "user", "content": "Who are you?"}, ] inputs = tokenizer.apply_chat_template( messages, add_generation_prompt=True, tokenize=True, return_dict=True, return_tensors="pt", ).to(model.device) outputs = model.generate(**inputs, max_new_tokens=256) print(tokenizer.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use dirac-run/ec-1.5b with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "dirac-run/ec-1.5b" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "dirac-run/ec-1.5b", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/dirac-run/ec-1.5b
- SGLang
How to use dirac-run/ec-1.5b 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 "dirac-run/ec-1.5b" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "dirac-run/ec-1.5b", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'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 "dirac-run/ec-1.5b" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "dirac-run/ec-1.5b", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use dirac-run/ec-1.5b with Docker Model Runner:
docker model run hf.co/dirac-run/ec-1.5b
Download training.json from dirac-run/ec-1.5b: direct link, hf CLI and curl.
- Browser
- Download file 2.88 kB
-
https://huggingface.co/dirac-run/ec-1.5b/resolve/main/training.json
- Command line
-
hf download hf://dirac-run/ec-1.5b/training.json
-
curl -L -o training.json https://huggingface.co/dirac-run/ec-1.5b/resolve/main/training.json
2.88 kB
| { | |
| "base_model": { | |
| "repository": "Qwen/Qwen2.5-Coder-1.5B-Instruct", | |
| "revision": "2e1fd397ee46e1388853d2af2c993145b0f1098a", | |
| "parameter_count": 1543714304 | |
| }, | |
| "selected_checkpoint": "A3", | |
| "parent_checkpoint_step": 14833, | |
| "parent_training": { | |
| "seed": 42, | |
| "effective_batch": 32, | |
| "rank": 32, | |
| "alpha": 64, | |
| "dropout": 0.05, | |
| "target_modules": [ | |
| "q_proj", | |
| "k_proj", | |
| "v_proj", | |
| "o_proj", | |
| "gate_proj", | |
| "up_proj", | |
| "down_proj" | |
| ], | |
| "rows": 474635, | |
| "peak_learning_rate": 0.0001, | |
| "updates": 14833, | |
| "warmup_updates": 742, | |
| "optimizer": "AdamW", | |
| "betas": [ | |
| 0.9, | |
| 0.999 | |
| ], | |
| "epsilon": 1e-08, | |
| "weight_decay": 0.0, | |
| "schedule": "linear warmup then cosine decay", | |
| "base_dtype": "bfloat16", | |
| "trainable_adapter_dtype": "float32", | |
| "max_sequence_tokens": 2048, | |
| "assistant_only_loss": true, | |
| "length_bucketed": true, | |
| "prompt_file": "training-system-prompt.txt", | |
| "prompt_sha256": "80e46c8e196e108ea50420d1c7b0b28d9aa07a2df1ccbf49ebd63d466c4a37f5", | |
| "epochs": 1, | |
| "example_order": "shuffled length buckets; one complete weighted epoch" | |
| }, | |
| "continuation": { | |
| "seed": 23042, | |
| "effective_batch": 32, | |
| "rank": 32, | |
| "alpha": 64, | |
| "dropout": 0.05, | |
| "target_modules": [ | |
| "q_proj", | |
| "k_proj", | |
| "v_proj", | |
| "o_proj", | |
| "gate_proj", | |
| "up_proj", | |
| "down_proj" | |
| ], | |
| "rows": 2820, | |
| "peak_learning_rate": 5e-06, | |
| "updates": 200, | |
| "warmup_updates": 10, | |
| "optimizer": "AdamW", | |
| "betas": [ | |
| 0.9, | |
| 0.999 | |
| ], | |
| "epsilon": 1e-08, | |
| "weight_decay": 0.0, | |
| "schedule": "linear warmup then cosine decay", | |
| "base_dtype": "bfloat16", | |
| "trainable_adapter_dtype": "float32", | |
| "max_sequence_tokens": 2048, | |
| "assistant_only_loss": true, | |
| "length_bucketed": false, | |
| "prompt_file": "system-prompt.txt", | |
| "prompt_sha256": "3a9028d5aebb73c3ed7363e63eb3e751689218775ea5572ab0dc6807e522238b", | |
| "repair_mix_fraction": 0.5, | |
| "example_order": "seeded family-aware shuffle; repair/replay cohorts without replacement within cycles" | |
| }, | |
| "training_data_release": "dirac-run/ec-training-data", | |
| "data_release_is_deduplicated_union_not_exact_weighted_epoch": true, | |
| "training_examples_from_other_repairs_also_in_data_release": true, | |
| "full_fidelity_artifacts_in_this_repository": true, | |
| "merged_dtype": "bfloat16", | |
| "adapter_dtype": "float32", | |
| "adapter_subfolder": "adapter", | |
| "optimizer_and_rng_state_included": false, | |
| "merge": "FP32(original BF16 base) + (alpha/r) * FP32(B @ A), then BF16 rounding", | |
| "gguf_repository": "dirac-run/ec-1.5b-gguf", | |
| "source_adapter_sha256": "3ea9ba05f368b8be44ea02e7f6618391ecae8248ea9c550e72397957a1038042", | |
| "source_fp32_merge_sha256": "4f346d07a74b320a88ef06fa09e614ce5d071e4f71f68076c3a79575575ad7d2" | |
| } | |