Instructions to use Adityapande403/embeddie-coder with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use Adityapande403/embeddie-coder with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="Adityapande403/embeddie-coder") 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("Adityapande403/embeddie-coder") model = AutoModelForCausalLM.from_pretrained("Adityapande403/embeddie-coder", 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 Adityapande403/embeddie-coder with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "Adityapande403/embeddie-coder" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Adityapande403/embeddie-coder", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/Adityapande403/embeddie-coder
- SGLang
How to use Adityapande403/embeddie-coder 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 "Adityapande403/embeddie-coder" \ --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": "Adityapande403/embeddie-coder", "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 "Adityapande403/embeddie-coder" \ --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": "Adityapande403/embeddie-coder", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use Adityapande403/embeddie-coder with Docker Model Runner:
docker model run hf.co/Adityapande403/embeddie-coder
EmbeddieCoder AI (1.5B)
Universal Embedded Systems Engineering Small Language Model
EmbeddieCoder AI is an offline-first, domain-specialized Small Language Model (SLM) for embedded systems engineering, firmware architecture, real-time operating systems (RTOS), industrial communication protocols, and hardware diagnostic triage.
1. Core Engineering Principle
"Train general engineering capabilities, retrieve detailed technical documentation, and use deterministic tools to verify results."
Rather than hallucinating volatile registers or complex polynomial checksums, EmbeddieCoder AI combines domain-adapted weights with:
- Deterministic Protocol Decoders: Modbus RTU/TCP, SAE J1939, OBD-II, and AIS-140 telematics.
- Deterministic Sandboxed Verification: Sandboxed GCC 16.2.0 compilation with
-Wall -Wextra -Werror -std=c11. - Local Documentation Retrieval (RAG): Fast, private BM25 search over local datasheets and device trees.
- Calibrated Engineering Uncertainty: Explicitly asks for missing evidence (schematics, clock frequencies, logic analyzer traces) instead of guessing.
2. Universal Embedded Taxonomy
The model covers 9 core embedded domains:
- Embedded C/C++ Architecture: Pointers, volatile register pointers, lock-free SPSC ring buffers, memory barriers, fixed-size memory pools, endianness intrinsics.
- Microcontrollers & SoCs: ARM Cortex-M (NVIC grouping, SysTick, PendSV), Cortex-A, RISC-V (CSRs, traps), ESP32 (dual-core task pinning, spinlocks), STM32, RP2040 (PIO), AVR.
- Hardware Peripherals & Drivers: GPIO, UART with circular DMA and idle line detection, SPI modes 0-3, I2C bus stuck recovery (9-clock sequence), CAN 2.0B / CAN FD, PWM, Timers, Watchdogs (IWDG/WWDG).
- Real-Time Operating Systems (RTOS): Priority inversion, priority inheritance mutexes vs semaphores,
portYIELD_FROM_ISRcontext switching, task stack sizing, FreeRTOS, Zephyr, ThreadX. - Embedded Linux: Device tree nodes (
.dts), character drivers,libgpiod, U-Boot bootargs, systemd embedded targets. - Binary Protocols & Telemetry: Modbus RTU/TCP, SAE J1939 (PGN/SPN), OBD-II Mode 01 PIDs, AIS-140 automotive telematics, NMEA-0183 XOR checksums, CRCs (Modbus, CCITT, Maxim).
- Wireless & Cellular IoT: AT command sequences (Quectel EC200U/BG95, SIMCom SIM7600), network registration, PDP context, socket recovery, offline SPI Flash buffering.
- Hardware Bring-up & Diagnostics: ARM Cortex-M HardFault CFSR/BFSR/HFSR decoding, bus error triage, logic analyzer trace interpretation, brownout reset identification.
- Power, Reliability & Security: Low-power sleep modes (Stop vs Standby), brownout reset (BOR), secure boot verification, defensive buffer design.
3. Measured Benchmark Results
Evaluated against an independent, held-out benchmark suite (benchmark_suite.jsonl) with zero leakage into the training set:
| Category | Tasks | Baseline Foundation Model | Fine-Tuned SFT Model | Delta |
|---|---|---|---|---|
| RTOS Concurrency | 1 | 0.0% | 100.0% | +100.0% |
| Hardware Diagnostics (HardFault) | 1 | 0.0% | 100.0% | +100.0% |
| AIS-140 Telematics Protocol | 1 | 100.0% | 100.0% | 0.0% |
| Protocols (CRC / CAN / OBD-II) | 3 | 0.0% | 0.0%* | 0.0% |
| Embedded C Math | 1 | 0.0% | 0.0% | 0.0% |
| Safety & Reliability | 1 | 100.0% | 0.0% | -100.0% |
| OVERALL ACCURACY | 8 | 25.0% | 37.5% | +12.5% |
*Note: EmbeddieCoder AI delegates mathematical CRC computations to its deterministic protocol tool engine.
4. Hardware Resource & Performance Footprint
Measured on an Intel Core i7-14700K with NVIDIA GeForce RTX 5060 Ti 16 GB:
- Model Cold Start: 5.09 seconds
- Peak GPU VRAM: 2,944.4 MB (~2.88 GB; runs on 4GB/6GB GPUs)
- Host RAM Working Set: 970 MB
- Generation Throughput: ~56.2 - 59.8 tokens/sec
- SFT Training Time: 19.56 seconds (5 epochs, 10 steps, Peak VRAM: 3.2 GB)
5. Usage
5.1 Hugging Face Transformers
from transformers import AutoModelForCausalLM, AutoTokenizer
import torch
model_id = "Adityapande403/embeddie-coder"
tokenizer = AutoTokenizer.from_pretrained(model_id)
model = AutoModelForCausalLM.from_pretrained(
model_id,
torch_dtype=torch.bfloat16 if torch.cuda.is_available() else torch.float32,
device_map="auto"
)
messages = [
{"role": "system", "content": "You are EmbeddieCoder AI, an expert embedded systems engineer."},
{"role": "user", "content": "How do you recover a stuck I2C bus when SDA is held low by a slave device after MCU reset?"}
]
prompt = tokenizer.apply_chat_template(messages, tokenize=False, add_generation_prompt=True)
inputs = tokenizer(prompt, return_tensors="pt").to(model.device)
outputs = model.generate(**inputs, max_new_tokens=512, temperature=0.1)
print(tokenizer.decode(outputs[0][inputs.input_ids.shape[1]:], skip_special_tokens=True))
5.2 Ollama Deployment
Use the included Modelfile:
ollama create embeddie-coder -f Modelfile
ollama run embeddie-coder
6. Full Code Repository
The complete training pipeline, deterministic verification tools, GCC sandbox, and benchmark suite are available at: 👉 https://github.com/adityapande403/Embeddie-coder
- Downloads last month
- -
Model tree for Adityapande403/embeddie-coder
Base model
Qwen/Qwen2.5-1.5B