Views
No views yet
chipcraftx-rtlgen-7b handles first-pass Verilog generation at zero API cost. Within the full ChipCraftX hybrid pipeline, the system achieves 98.7% functional pass rate on VerilogEval-Human (154/156).| Model | Parameters | Pass Rate |
|---|---|---|
| VeriGen | 16B | 26.0% |
| chipcraftx-rtlgen-7b (standalone) | 7B | 36.5% |
| RTLCoder | 7B | 37.0% |
| CodeV | 7B | 53.2% |
| ChipCraftX hybrid system | 7B + Claude | 98.7% |
1from transformers import AutoModelForCausalLM, AutoTokenizer
2
3model_name = "ChipCraftX/chipcraftx-rtlgen-7b"
4tokenizer = AutoTokenizer.from_pretrained(model_name)
5model = AutoModelForCausalLM.from_pretrained(model_name, torch_dtype="auto", device_map="auto")
6
7system_prompt = """You are ChipCraft-RTL, an expert Verilog design engineer.
8Generate synthesizable, lint-clean RTL that exactly matches the specification.
9Rules:
10- Output ONLY Verilog code (no prose, no markdown fences).
11- Use reg and wire types ONLY -- NEVER use logic.
12- Use always @(posedge clk) and always @(*) -- NEVER use always_ff or always_comb.
13- Module name MUST be TopModule."""
14
15spec = """Implement a module named TopModule with the following interface.
16 - input clk
17 - input reset
18 - output [3:0] count
19
20The module should implement a 4-bit up counter with synchronous reset."""
21
22messages = [
23 {"role": "system", "content": system_prompt},
24 {"role": "user", "content": spec},
25]
26
27text = tokenizer.apply_chat_template(messages, tokenize=False, add_generation_prompt=True)
28inputs = tokenizer(text, return_tensors="pt").to(model.device)
29outputs = model.generate(**inputs, max_new_tokens=4096, temperature=0.2, do_sample=True)
30print(tokenizer.decode(outputs[0][inputs.input_ids.shape[1]:], skip_special_tokens=True))1@misc{chipcraftx-rtlgen-7b,
2 title={chipcraftx-rtlgen-7b: Local RTL Generation Engine for ChipCraftX},
3 author={Eryilmaz, Cagri},
4 year={2026},
5 publisher={HuggingFace},
6 url={https://huggingface.co/ChipCraftX/chipcraftx-rtlgen-7b}
7}