Instructions to use ReXeeD/TASX-Cmd-0.5B with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Local Apps Settings
- Unsloth Studio
How to use ReXeeD/TASX-Cmd-0.5B with Unsloth Studio:
Install Unsloth Studio (macOS, Linux, WSL)
curl -fsSL https://unsloth.ai/install.sh | sh # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for ReXeeD/TASX-Cmd-0.5B to start chatting
Install Unsloth Studio (Windows)
irm https://unsloth.ai/install.ps1 | iex # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for ReXeeD/TASX-Cmd-0.5B to start chatting
Using HuggingFace Spaces for Unsloth
# No setup required # Open https://huggingface.co/spaces/unsloth/studio in your browser # Search for ReXeeD/TASX-Cmd-0.5B to start chatting
Load model with FastModel
pip install unsloth from unsloth import FastModel model, tokenizer = FastModel.from_pretrained( model_name="ReXeeD/TASX-Cmd-0.5B", max_seq_length=2048, )
Update README.md
Browse files
README.md
CHANGED
|
@@ -67,4 +67,66 @@ If you ask it to perform a delivery (e.g., *"Fetch my laptop from the server roo
|
|
| 67 |
{"type": "nav2", "cmd": "go_to_waypoint", "target": "john_desk"},
|
| 68 |
{"type": "stunt", "cmd": "full_sit"}
|
| 69 |
]
|
| 70 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 67 |
{"type": "nav2", "cmd": "go_to_waypoint", "target": "john_desk"},
|
| 68 |
{"type": "stunt", "cmd": "full_sit"}
|
| 69 |
]
|
| 70 |
+
}
|
| 71 |
+
|
| 72 |
+
```
|
| 73 |
+
## TEST SCRIPT
|
| 74 |
+
```
|
| 75 |
+
# ============================================================
|
| 76 |
+
# ============================================================
|
| 77 |
+
from unsloth import FastLanguageModel
|
| 78 |
+
import torch
|
| 79 |
+
|
| 80 |
+
MODEL_PATH = "./tasx_sft_merged"
|
| 81 |
+
MAX_SEQ_LENGTH = 512
|
| 82 |
+
|
| 83 |
+
print("⏳ Loading your fine-tuned TASX model...")
|
| 84 |
+
model, tokenizer = FastLanguageModel.from_pretrained(
|
| 85 |
+
model_name = MODEL_PATH,
|
| 86 |
+
max_seq_length = MAX_SEQ_LENGTH,
|
| 87 |
+
dtype = torch.float16,
|
| 88 |
+
load_in_4bit = False,
|
| 89 |
+
)
|
| 90 |
+
|
| 91 |
+
FastLanguageModel.for_inference(model)
|
| 92 |
+
|
| 93 |
+
print("\n" + "="*50)
|
| 94 |
+
print("TASX ROBOT COMMAND TESTER READY")
|
| 95 |
+
print("Type a command in the box below and press Enter.")
|
| 96 |
+
print("Type 'quit' or 'q' to stop.")
|
| 97 |
+
print("="*50 + "\n")
|
| 98 |
+
|
| 99 |
+
|
| 100 |
+
while True:
|
| 101 |
+
user_text = input("🎤 You: ")
|
| 102 |
+
|
| 103 |
+
if user_text.lower() in ['quit', 'exit', 'q']:
|
| 104 |
+
print("Stopping inference. Great job!")
|
| 105 |
+
break
|
| 106 |
+
|
| 107 |
+
if not user_text.strip():
|
| 108 |
+
continue
|
| 109 |
+
|
| 110 |
+
|
| 111 |
+
prompt = f"<|im_start|>user\n{user_text}<|im_end|>\n<|im_start|>assistant\n"
|
| 112 |
+
|
| 113 |
+
|
| 114 |
+
inputs = tokenizer([prompt], return_tensors="pt").to("cuda")
|
| 115 |
+
|
| 116 |
+
# Generate the output
|
| 117 |
+
outputs = model.generate(
|
| 118 |
+
**inputs,
|
| 119 |
+
max_new_tokens=150,
|
| 120 |
+
use_cache=True,
|
| 121 |
+
temperature=0.1,
|
| 122 |
+
do_sample=True,
|
| 123 |
+
)
|
| 124 |
+
|
| 125 |
+
# Decode the output (slice off the prompt so we only see the assistant's new text)
|
| 126 |
+
response = tokenizer.batch_decode(
|
| 127 |
+
outputs[:, inputs.input_ids.shape[1]:],
|
| 128 |
+
skip_special_tokens=True
|
| 129 |
+
)[0]
|
| 130 |
+
|
| 131 |
+
print(f"TASX: {response.strip()}\n")
|
| 132 |
+
```
|