license: mit
language:
- en
task_categories:
- translation
- text-generation
- robotics
tags:
- robotics
- tool-calling
- rc-car
- langchain
- nodemcu
size_categories:
- n<1K
configs:
- config_name: default
data_files:
- split: train
path: data/rc_dataset.csv
RC-Car Command Dataset
A hand-authored dataset for training a tiny language model that maps a natural-language command to a structured list of tool calls (LangChain/LangGraph style), to drive an RC car via a NodeMCU.
- File:
data/rc_dataset.csv - Columns:
input(natural language),output(JSON tool-call list) - Rows: 700
- Task type: sequence-to-sequence (translation)
Output grammar
Each output is a JSON array of tool-call objects:
[{"name":"Forward","args":{"duration":2}},{"name":"Turn_Left","args":{}},{"name":"Stop","args":{}}]
Tools
| Tool | args | Meaning |
|---|---|---|
Forward |
{"duration": n} |
drive forward n seconds (n = 1–10) |
Backward |
{"duration": n} |
drive backward n seconds (n = 1–10) |
Turn_Right |
{} |
turn right 90° |
Turn_Left |
{} |
turn left 90° |
Stop |
{} |
stop the motors |
Labeling rules (applied to every row)
- Default duration = 2. If a Forward/Backward command has no explicit time, duration is
2. - Word-numbers → digits ("five seconds" →
5). Vague durations ("a bit", "briefly", "a moment") → default2. - Durations are clamped to 1–10.
- Turns take no arguments.
- Exactly one trailing
Stopis always present — appended even when the user didn't say "stop", and never duplicated when they did.
Composite shape templates (stylized, 90° turns only)
Notation: F(n)=Forward, B(n)=Backward, R=Turn_Right, L=Turn_Left, S=Stop.
| Shape | Decomposition |
|---|---|
| U-turn | F(2) R R F(2) S |
| Square | F(2) R F(2) R F(2) R F(2) R S |
| Triangle | F(2) R F(2) R F(2) R S (stylized) |
| Circle | F(1) R F(1) R F(1) R F(1) R S (short segments) |
| Star | F(2) R R F(2) R R F(2) R R F(2) R R F(2) R R S |
| Zigzag | F(2) R F(2) L F(2) R S |
| Figure-8 | F(1) R F(1) R F(1) R F(1) R F(1) L F(1) L F(1) L F(1) L S |
Because turns are fixed at 90°, only Square is geometrically exact. Triangle, Circle, Star, and Figure-8 are stylized approximations built from 90° steps. They are easy to retune — just change the template above and regenerate those rows.
Left-handed (counterclockwise) shape variants
The first 500 rows draw all shapes clockwise (Turn_Right). Rows 501–700 add left-handed variants for balance — same templates with Turn_Right↔Turn_Left swapped, triggered by phrasings like "to the left", "going left", "counterclockwise". The Zigzag/Figure-8 variants are the mirror image (start with the opposite turn). This is what brings Turn_Left coverage close to parity with Turn_Right.
Coverage (700 rows)
The original 500 rows (see table below) plus 200 rebalancing rows added to fix tool/duration imbalance:
| Category | Rows |
|---|---|
| Forward (durations, defaults, word-numbers, synonyms) | 60 |
| Backward | 50 |
| Turn left only | 30 |
| Turn right only | 30 |
| Stop only | 20 |
| 2-action compounds | 90 |
| 3–4 action compounds | 80 |
| U-turn | 25 |
| Square | 25 |
| Circle | 20 |
| Triangle | 20 |
| Star | 15 |
| Zigzag | 20 |
| Figure-8 | 15 |
| — rebalancing rows (501–700) — | |
| Backward primitives + compounds (all durations 1–10) | ~90 |
| Forward with long durations (3–10) | ~40 |
| Turn-left-heavy compounds | ~40 |
| Left-handed shape variants (square/circle/triangle/u-turn/star/zigzag/figure-8) | ~30 |
Resulting balance (tool occurrences across all rows)
| Tool | Occurrences |
|---|---|
| Forward | 1029 |
| Turn_Right | 707 |
| Stop | 700 |
| Turn_Left | 496 |
| Backward | 211 |
Duration spread: 2 is still the most common (it's the default), 1 is common (circles/figure-8 use 1s segments), and 3–10 each appear 18–44 times.
Notes for training (next step)
- Treat this as seq2seq. Build two small vocabularies (input words; output JSON tokens) plus special tokens
<pad>,<bos>,<eos>,<unk>. - The JSON output is verbose and regular — tokenize it structurally (tool names,
"name","args","duration", digits, and each{ } [ ] : ,as tokens) so the vocabulary stays tiny. - Hold out a small portion (e.g. 10%) as a test set with phrasings not seen in training to measure real generalization.
- The longest outputs are the Star (16 calls) and Figure-8 (17 calls) — use these to choose your max sequence length for padding.