from huggingface_hub import hf_hub_downloadfrom transformers import AutoModelForCausalLM, AutoTokenizer system = open(hf_hub_download("Carlo0001/Prompt2Robo", "system_prompt.md", repo_type="dataset")).read().strip()tok = AutoTokenizer.from_pretrained("moritzzzz/Prompt2Robo-Qwen3-4B-v3-full-4b-full")model = AutoModelForCausalLM.from_pretrained("moritzzzz/Prompt2Robo-Qwen3-4B-v3-full-4b-full", dtype="bfloat16", device_map="auto")msgs = [{"role": "system", "content": system}, {"role": "user", "content": "Objects: 1 (red), 2 (blue)\nPut the red cube on top of the blue cube."}]text = tok.apply_chat_template(msgs, tokenize=False, add_generation_prompt=True, enable_thinking=False)ids = tok(text, return_tensors="pt", add_special_tokens=False).to(model.device)out = model.generate(**ids, max_new_tokens=1500, do_sample=False)print(tok.decode(out[0][ids.input_ids.shape[1]:], skip_special_tokens=True))