Datasets:
messages listlengths 3 3 | category stringclasses 3
values | utility stringclasses 89
values |
|---|---|---|
[
{
"role": "system",
"content": "You are a Bash expert."
},
{
"role": "user",
"content": "Give 'dd if=/dev/zero of=test.img bs=1M count=1024' a boosted CPU priority of -5."
},
{
"role": "assistant",
"content": "sudo nice -n -5 dd if=/dev/zero of=test.img bs=1M count=1024"
}
] | single | nice |
[
{
"role": "system",
"content": "You are a helpful assistant that writes correct, idiomatic Bash commands."
},
{
"role": "user",
"content": "Show the kernel routing table numerically."
},
{
"role": "assistant",
"content": "netstat -rn"
}
] | single | netstat |
[
{
"role": "system",
"content": "You are a helpful assistant that writes correct, idiomatic Bash commands."
},
{
"role": "user",
"content": "Please show its size, owner and permissions in notes.py."
},
{
"role": "assistant",
"content": "stat notes.py"
}
] | single | stat |
[
{
"role": "system",
"content": "You translate natural-language requests into correct Bash commands."
},
{
"role": "user",
"content": "Check if invoice.py exists and cat it, otherwise say it's missing."
},
{
"role": "assistant",
"content": "[ -f invoice.py ] && cat invoice.py || echo ... | pipeline | chain |
[
{
"role": "system",
"content": "You are a Linux shell expert. Respond with Bash only."
},
{
"role": "user",
"content": "Recursively make everything in data readable and writable by the owner only."
},
{
"role": "assistant",
"content": "chmod -R 600 data"
}
] | single | chmod |
[
{
"role": "system",
"content": "You are a helpful assistant that writes correct, idiomatic Bash commands."
},
{
"role": "user",
"content": "List logged-in users without the header line."
},
{
"role": "assistant",
"content": "w -h"
}
] | single | w |
[
{
"role": "system",
"content": "You are a command-line assistant specializing in Bash and GNU coreutils."
},
{
"role": "user",
"content": "Show kernel notice-level messages."
},
{
"role": "assistant",
"content": "dmesg -l notice"
}
] | single | dmesg |
[
{
"role": "system",
"content": "You are a command-line assistant specializing in Bash and GNU coreutils."
},
{
"role": "user",
"content": "Read the hostname straight from its config file."
},
{
"role": "assistant",
"content": "cat /etc/hostname"
}
] | single | hostname |
[
{
"role": "system",
"content": "You are a Bash expert."
},
{
"role": "user",
"content": "Read manifest.ini, then count the lines β as a pipeline."
},
{
"role": "assistant",
"content": "cat manifest.ini | wc -l"
}
] | pipeline | wc |
[
{
"role": "system",
"content": "You are a helpful assistant that writes correct, idiomatic Bash commands."
},
{
"role": "user",
"content": "Make a timestamped log directory under logs/."
},
{
"role": "assistant",
"content": "mkdir -p logs/$(date +%Y-%m-%d)"
}
] | pipeline | cmdsub |
[
{
"role": "system",
"content": "You are a helpful assistant that writes correct, idiomatic Bash commands."
},
{
"role": "user",
"content": "Start 'dd if=/dev/zero of=test.img bs=1M count=1024' with nice value 10 so it doesn't hog the CPU."
},
{
"role": "assistant",
"content": "nice -... | single | nice |
[
{
"role": "system",
"content": "You are a command-line assistant specializing in Bash and GNU coreutils."
},
{
"role": "user",
"content": "Display w with numeric IPs."
},
{
"role": "assistant",
"content": "w -i"
}
] | single | w |
[
{
"role": "system",
"content": "You are a helpful assistant that writes correct, idiomatic Bash commands."
},
{
"role": "user",
"content": "Given index.log, count each unique line, most common first."
},
{
"role": "assistant",
"content": "cat index.log | sort | uniq -c | sort -nr"
... | pipeline | uniq |
[
{
"role": "system",
"content": "You are a Bash expert."
},
{
"role": "user",
"content": "List all open TCP connections."
},
{
"role": "assistant",
"content": "lsof -i tcp"
}
] | single | lsof |
[
{
"role": "system",
"content": "You are a helpful assistant that writes correct, idiomatic Bash commands."
},
{
"role": "user",
"content": "Give './import.sh' a boosted CPU priority of -5."
},
{
"role": "assistant",
"content": "sudo nice -n -5 ./import.sh"
}
] | single | nice |
[
{
"role": "system",
"content": "You are a Bash expert."
},
{
"role": "user",
"content": "How do I count how many cron processes are running?"
},
{
"role": "assistant",
"content": "pgrep -c cron"
}
] | pipeline | pgrep |
[
{
"role": "system",
"content": "You are a helpful assistant that writes correct, idiomatic Bash commands."
},
{
"role": "user",
"content": "What is tomcat running right now?"
},
{
"role": "assistant",
"content": "w tomcat"
}
] | single | w |
[
{
"role": "system",
"content": "You are a helpful assistant that writes correct, idiomatic Bash commands."
},
{
"role": "user",
"content": "Show the process tree including command-line arguments."
},
{
"role": "assistant",
"content": "pstree -a"
}
] | single | pstree |
[
{
"role": "system",
"content": "You are a Bash expert."
},
{
"role": "user",
"content": "Show established TCP connections numerically."
},
{
"role": "assistant",
"content": "netstat -tn"
}
] | single | netstat |
[
{
"role": "system",
"content": "You translate natural-language requests into correct Bash commands."
},
{
"role": "user",
"content": "Bump process 6994 to a higher priority (nice -5). Requires root."
},
{
"role": "assistant",
"content": "sudo renice -n -5 -p 6994"
}
] | single | renice |
[
{
"role": "system",
"content": "You are a Linux shell expert. Respond with Bash only."
},
{
"role": "user",
"content": "Print ec2-user's process hierarchy including PIDs."
},
{
"role": "assistant",
"content": "pstree -p ec2-user"
}
] | single | pstree |
[
{
"role": "system",
"content": "You are a helpful assistant that writes correct, idiomatic Bash commands."
},
{
"role": "user",
"content": "Set changelog.sql to permissions 644."
},
{
"role": "assistant",
"content": "chmod 644 changelog.sql"
}
] | single | chmod |
[
{
"role": "system",
"content": "You are a Linux shell expert. Respond with Bash only."
},
{
"role": "user",
"content": "I need getopts handling for three options: -i, -d and -t; print usage on bad input."
},
{
"role": "assistant",
"content": "#!/usr/bin/env bash\nset -euo pipefail\ni... | script | getopts |
[
{
"role": "system",
"content": "You translate natural-language requests into correct Bash commands."
},
{
"role": "user",
"content": "Print current vmstat counters once."
},
{
"role": "assistant",
"content": "vmstat"
}
] | single | vmstat |
[
{
"role": "system",
"content": "You are a Bash expert."
},
{
"role": "user",
"content": "Display kernel messages from the journal with priority error or worse."
},
{
"role": "assistant",
"content": "journalctl -k -p err"
}
] | single | journalctl |
[
{
"role": "system",
"content": "You are a helpful assistant that writes correct, idiomatic Bash commands."
},
{
"role": "user",
"content": "Download https://db01.example.com/file.zip and save it with its remote name."
},
{
"role": "assistant",
"content": "curl -O https://db01.example... | single | curl |
[
{
"role": "system",
"content": "You are a helpful assistant that writes correct, idiomatic Bash commands."
},
{
"role": "user",
"content": "Bump process 6456 to a higher priority (nice -5). Requires root."
},
{
"role": "assistant",
"content": "sudo renice -n -5 -p 6456"
}
] | single | renice |
[
{
"role": "system",
"content": "You are a Bash expert."
},
{
"role": "user",
"content": "Lower the priority of process 1145 to nice value 10."
},
{
"role": "assistant",
"content": "renice -n 10 -p 1145"
}
] | single | renice |
[
{
"role": "system",
"content": "You are a helpful assistant that writes correct, idiomatic Bash commands."
},
{
"role": "user",
"content": "Show TCP connections to api.internal."
},
{
"role": "assistant",
"content": "ss -tn dst api.internal"
}
] | single | ss |
[
{
"role": "system",
"content": "You are a command-line assistant specializing in Bash and GNU coreutils."
},
{
"role": "user",
"content": "Log vmstat output to a file with timestamps every 5 seconds."
},
{
"role": "assistant",
"content": "vmstat 5 | while read line; do echo \"$(date ... | pipeline | vmstat |
[
{
"role": "system",
"content": "You are a Bash expert."
},
{
"role": "user",
"content": "Create a script that dumps every MySQL database into its own gzip file under /mnt/backup, keeping 14 days."
},
{
"role": "assistant",
"content": "#!/usr/bin/env bash\nset -euo pipefail\ndest=/mnt... | script | mysqldump |
[
{
"role": "system",
"content": "You are a Linux shell expert. Respond with Bash only."
},
{
"role": "user",
"content": "Launch 'dd if=/dev/zero of=test.img bs=1M count=1024' at reduced priority (1)."
},
{
"role": "assistant",
"content": "nice -n 1 dd if=/dev/zero of=test.img bs=1M co... | single | nice |
[
{
"role": "system",
"content": "You are a Bash expert."
},
{
"role": "user",
"content": "Show vmstat memory counters in megabytes."
},
{
"role": "assistant",
"content": "vmstat -s -S M"
}
] | single | vmstat |
[
{
"role": "system",
"content": "You are a Bash expert."
},
{
"role": "user",
"content": "Report disk I/O counters via vmstat -d."
},
{
"role": "assistant",
"content": "vmstat -d"
}
] | single | vmstat |
[
{
"role": "system",
"content": "You translate natural-language requests into correct Bash commands."
},
{
"role": "user",
"content": "Show memory usage with a total line for RAM plus swap."
},
{
"role": "assistant",
"content": "free -h -t"
}
] | single | free |
[
{
"role": "system",
"content": "You are a Bash expert."
},
{
"role": "user",
"content": "monitor system performance with vmstat every 5 seconds using human-readable units"
},
{
"role": "assistant",
"content": "vmstat -S M 5"
}
] | single | vmstat |
[
{
"role": "system",
"content": "You are a command-line assistant specializing in Bash and GNU coreutils."
},
{
"role": "user",
"content": "List all files opened by cron."
},
{
"role": "assistant",
"content": "lsof -c cron"
}
] | single | lsof |
[
{
"role": "system",
"content": "You are a helpful assistant that writes correct, idiomatic Bash commands."
},
{
"role": "user",
"content": "Show the process tree sorted numerically by PID."
},
{
"role": "assistant",
"content": "pstree -n"
}
] | single | pstree |
[
{
"role": "system",
"content": "You translate natural-language requests into correct Bash commands."
},
{
"role": "user",
"content": "When was the system booted, per who -b?"
},
{
"role": "assistant",
"content": "who -b"
}
] | single | uptime |
[
{
"role": "system",
"content": "You are a Linux shell expert. Respond with Bash only."
},
{
"role": "user",
"content": "Write a countdown script from 10 to 1 that prints each number one second apart."
},
{
"role": "assistant",
"content": "#!/usr/bin/env bash\nset -euo pipefail\ni=10\... | script | while |
[
{
"role": "system",
"content": "You translate natural-language requests into correct Bash commands."
},
{
"role": "user",
"content": "Show a short w listing without the login/JCPU/PCPU columns."
},
{
"role": "assistant",
"content": "w -s"
}
] | single | w |
[
{
"role": "system",
"content": "You are a Bash expert."
},
{
"role": "user",
"content": "Show logged-in users with their IP addresses instead of hostnames."
},
{
"role": "assistant",
"content": "w -i"
}
] | single | w |
[
{
"role": "system",
"content": "You translate natural-language requests into correct Bash commands."
},
{
"role": "user",
"content": "Show detailed per-device iostat, 3s apart, 10 times."
},
{
"role": "assistant",
"content": "iostat -x 3 10"
}
] | single | iostat |
[
{
"role": "system",
"content": "You are a Linux shell expert. Respond with Bash only."
},
{
"role": "user",
"content": "Watch the kernel log live."
},
{
"role": "assistant",
"content": "dmesg -w"
}
] | single | dmesg |
[
{
"role": "system",
"content": "You translate natural-language requests into correct Bash commands."
},
{
"role": "user",
"content": "Print just the short hostname."
},
{
"role": "assistant",
"content": "hostname -s"
}
] | single | hostname |
[
{
"role": "system",
"content": "You are a command-line assistant specializing in Bash and GNU coreutils."
},
{
"role": "user",
"content": "For event.sql, show the last 20 lines."
},
{
"role": "assistant",
"content": "tail -n 20 event.sql"
}
] | single | tail |
[
{
"role": "system",
"content": "You are a Linux shell expert. Respond with Bash only."
},
{
"role": "user",
"content": "strip leading whitespace from every line of config.json and save to clean.txt"
},
{
"role": "assistant",
"content": "sed 's/^[[:space:]]*//' config.json > clean.txt... | pipeline | sed |
[
{
"role": "system",
"content": "You are a helpful assistant that writes correct, idiomatic Bash commands."
},
{
"role": "user",
"content": "Show all TCP sockets numerically."
},
{
"role": "assistant",
"content": "ss -tan"
}
] | single | ss |
[
{
"role": "system",
"content": "You are a helpful assistant that writes correct, idiomatic Bash commands."
},
{
"role": "user",
"content": "Fetch JSON from https://registry.example.org/api/users and pretty-print it with jq."
},
{
"role": "assistant",
"content": "curl -s https://regis... | pipeline | curl |
[
{
"role": "system",
"content": "You are a Linux shell expert. Respond with Bash only."
},
{
"role": "user",
"content": "Get the bare PID that holds port 443."
},
{
"role": "assistant",
"content": "lsof -i :443 -t"
}
] | single | lsof |
[
{
"role": "system",
"content": "You are a Linux shell expert. Respond with Bash only."
},
{
"role": "user",
"content": "strip leading whitespace from every line of settings.ini and save to clean.txt"
},
{
"role": "assistant",
"content": "sed 's/^[[:space:]]*//' settings.ini > clean.t... | pipeline | sed |
[
{
"role": "system",
"content": "You translate natural-language requests into correct Bash commands."
},
{
"role": "user",
"content": "Print how many CPU cores this machine has."
},
{
"role": "assistant",
"content": "echo \"Cores: $(nproc)\""
}
] | pipeline | cmdsub |
[
{
"role": "system",
"content": "You are a Linux shell expert. Respond with Bash only."
},
{
"role": "user",
"content": "On this box, show which processes are listening and on which ports."
},
{
"role": "assistant",
"content": "ss -tlnp | awk 'NR>1 {print $4, $6}'"
}
] | pipeline | ss |
[
{
"role": "system",
"content": "You translate natural-language requests into correct Bash commands."
},
{
"role": "user",
"content": "Extract the idle-CPU column from a vmstat snapshot."
},
{
"role": "assistant",
"content": "vmstat 1 2 | tail -n1 | awk '{print $15}'"
}
] | pipeline | vmstat |
[
{
"role": "system",
"content": "You are a helpful assistant that writes correct, idiomatic Bash commands."
},
{
"role": "user",
"content": "Launch 'make -j4' at reduced priority (5)."
},
{
"role": "assistant",
"content": "nice -n 5 make -j4"
}
] | single | nice |
[
{
"role": "system",
"content": "You are a Linux shell expert. Respond with Bash only."
},
{
"role": "user",
"content": "Show a summary of socket counts."
},
{
"role": "assistant",
"content": "ss -s"
}
] | single | ss |
[
{
"role": "system",
"content": "You are a Bash expert."
},
{
"role": "user",
"content": "Find files in include larger than +100M."
},
{
"role": "assistant",
"content": "find include -type f -size +100M"
}
] | single | find |
[
{
"role": "system",
"content": "You are a Linux shell expert. Respond with Bash only."
},
{
"role": "user",
"content": "Write a Bash script that alerts if the root filesystem is more than 85% full."
},
{
"role": "assistant",
"content": "#!/usr/bin/env bash\nset -euo pipefail\nthresho... | script | if |
[
{
"role": "system",
"content": "You translate natural-language requests into correct Bash commands."
},
{
"role": "user",
"content": "How many active sessions are there per w?"
},
{
"role": "assistant",
"content": "w | wc -l"
}
] | single | w |
[
{
"role": "system",
"content": "You are a helpful assistant that writes correct, idiomatic Bash commands."
},
{
"role": "user",
"content": "Show TCP sockets in the TIME-WAIT state with their process."
},
{
"role": "assistant",
"content": "ss -tp state time-wait"
}
] | single | ss |
[
{
"role": "system",
"content": "You are a Bash expert."
},
{
"role": "user",
"content": "Show kernel ring buffer messages with human-readable timestamps."
},
{
"role": "assistant",
"content": "dmesg -T"
}
] | single | dmesg |
[
{
"role": "system",
"content": "You are a Bash expert."
},
{
"role": "user",
"content": "Show listening TCP/UDP sockets and their PIDs."
},
{
"role": "assistant",
"content": "netstat -tulpn"
}
] | single | netstat |
[
{
"role": "system",
"content": "You are a command-line assistant specializing in Bash and GNU coreutils."
},
{
"role": "user",
"content": "List connections stuck in TIME-WAIT."
},
{
"role": "assistant",
"content": "ss -tp state time-wait"
}
] | single | ss |
[
{
"role": "system",
"content": "You are a helpful assistant that writes correct, idiomatic Bash commands."
},
{
"role": "user",
"content": "How long has the system been running?"
},
{
"role": "assistant",
"content": "uptime"
}
] | single | uptime |
[
{
"role": "system",
"content": "You are a Linux shell expert. Respond with Bash only."
},
{
"role": "user",
"content": "Add a timestamp column to vmstat, 3s interval, 10 rounds."
},
{
"role": "assistant",
"content": "vmstat -t 3 10"
}
] | single | vmstat |
[
{
"role": "system",
"content": "You are a helpful assistant that writes correct, idiomatic Bash commands."
},
{
"role": "user",
"content": "Check what holds port 5672 with ss."
},
{
"role": "assistant",
"content": "ss -tlnp sport = :5672"
}
] | single | ss |
[
{
"role": "system",
"content": "You are a Linux shell expert. Respond with Bash only."
},
{
"role": "user",
"content": "Count how many established TCP connections there are."
},
{
"role": "assistant",
"content": "ss -t state established | tail -n +2 | wc -l"
}
] | pipeline | ss |
[
{
"role": "system",
"content": "You are a Linux shell expert. Respond with Bash only."
},
{
"role": "user",
"content": "Print just the PID using port 8000."
},
{
"role": "assistant",
"content": "lsof -i :8000 -t"
}
] | single | lsof |
[
{
"role": "system",
"content": "You are a Linux shell expert. Respond with Bash only."
},
{
"role": "user",
"content": "Show the kernel routing table."
},
{
"role": "assistant",
"content": "netstat -rn"
}
] | single | netstat |
[
{
"role": "system",
"content": "You are a Bash expert."
},
{
"role": "user",
"content": "List the unique 'critical' messages in messages."
},
{
"role": "assistant",
"content": "grep 'critical' messages | sort -u"
}
] | pipeline | grep |
[
{
"role": "system",
"content": "You are a command-line assistant specializing in Bash and GNU coreutils."
},
{
"role": "user",
"content": "Show the process tree with PIDs, highlighting the current process."
},
{
"role": "assistant",
"content": "pstree -hp"
}
] | single | pstree |
[
{
"role": "system",
"content": "You are a Bash expert."
},
{
"role": "user",
"content": "Check if results.html exists and cat it, otherwise say it's missing."
},
{
"role": "assistant",
"content": "[ -f results.html ] && cat results.html || echo 'not found'"
}
] | pipeline | chain |
[
{
"role": "system",
"content": "You are a command-line assistant specializing in Bash and GNU coreutils."
},
{
"role": "user",
"content": "List all files opened by redis-server."
},
{
"role": "assistant",
"content": "lsof -c redis-server"
}
] | single | lsof |
[
{
"role": "system",
"content": "You are a Bash expert."
},
{
"role": "user",
"content": "Show only the load averages."
},
{
"role": "assistant",
"content": "uptime | awk -F'load average:' '{print $2}'"
}
] | single | uptime |
[
{
"role": "system",
"content": "You are a Bash expert."
},
{
"role": "user",
"content": "Download https://8.8.8.8/file.zip and save it with its remote name."
},
{
"role": "assistant",
"content": "curl -O https://8.8.8.8/file.zip"
}
] | single | curl |
[
{
"role": "system",
"content": "You are a Bash expert."
},
{
"role": "user",
"content": "List all listening TCP and UDP sockets with programs."
},
{
"role": "assistant",
"content": "ss -tulnp"
}
] | single | ss |
[
{
"role": "system",
"content": "You are a Bash expert."
},
{
"role": "user",
"content": "Timestamped vmstat every 3s for 5 samples."
},
{
"role": "assistant",
"content": "vmstat -t 3 5"
}
] | single | vmstat |
[
{
"role": "system",
"content": "You are a Bash expert."
},
{
"role": "user",
"content": "List active TCP sessions with numeric addresses."
},
{
"role": "assistant",
"content": "netstat -tn"
}
] | single | netstat |
[
{
"role": "system",
"content": "You are a Linux shell expert. Respond with Bash only."
},
{
"role": "user",
"content": "Print just the PID using port 80."
},
{
"role": "assistant",
"content": "lsof -i :80 -t"
}
] | single | lsof |
[
{
"role": "system",
"content": "You are a helpful assistant that writes correct, idiomatic Bash commands."
},
{
"role": "user",
"content": "Show a one-shot CPU and disk I/O summary."
},
{
"role": "assistant",
"content": "iostat"
}
] | single | iostat |
[
{
"role": "system",
"content": "You are a Bash expert."
},
{
"role": "user",
"content": "Print git's process hierarchy including PIDs."
},
{
"role": "assistant",
"content": "pstree -p git"
}
] | single | pstree |
[
{
"role": "system",
"content": "You are a helpful assistant that writes correct, idiomatic Bash commands."
},
{
"role": "user",
"content": "Display the process hierarchy for user deploy."
},
{
"role": "assistant",
"content": "pstree deploy"
}
] | single | pstree |
[
{
"role": "system",
"content": "You translate natural-language requests into correct Bash commands."
},
{
"role": "user",
"content": "Give 'find / -name '*.core'' a boosted CPU priority of -5."
},
{
"role": "assistant",
"content": "sudo nice -n -5 find / -name '*.core'"
}
] | single | nice |
[
{
"role": "system",
"content": "You are a Bash expert."
},
{
"role": "user",
"content": "Show TCP connections to db01.example.org."
},
{
"role": "assistant",
"content": "ss -tn dst db01.example.org"
}
] | single | ss |
[
{
"role": "system",
"content": "You translate natural-language requests into correct Bash commands."
},
{
"role": "user",
"content": "Launch 'ffmpeg -i in.mp4 out.mp4' at reduced priority (15)."
},
{
"role": "assistant",
"content": "nice -n 15 ffmpeg -i in.mp4 out.mp4"
}
] | single | nice |
[
{
"role": "system",
"content": "You are a Bash expert."
},
{
"role": "user",
"content": "Show the 50 most recent grafana-server log lines, newest last."
},
{
"role": "assistant",
"content": "journalctl -u grafana-server -n 50"
}
] | single | journalctl |
[
{
"role": "system",
"content": "You are a Linux shell expert. Respond with Bash only."
},
{
"role": "user",
"content": "Print the used percentage of the root filesystem as a number."
},
{
"role": "assistant",
"content": "df -h / | awk 'NR==2 {print $5}'"
}
] | pipeline | df |
[
{
"role": "system",
"content": "You are a helpful assistant that writes correct, idiomatic Bash commands."
},
{
"role": "user",
"content": "download https://db01.example.com/list.txt and count the lines"
},
{
"role": "assistant",
"content": "curl -s https://db01.example.com/list.txt ... | pipeline | curl |
[
{
"role": "system",
"content": "You are a Linux shell expert. Respond with Bash only."
},
{
"role": "user",
"content": "list only the .gif files in lib"
},
{
"role": "assistant",
"content": "ls lib | grep '\\.gif$'"
}
] | pipeline | ls |
[
{
"role": "system",
"content": "You are a Linux shell expert. Respond with Bash only."
},
{
"role": "user",
"content": "Include a combined RAM+swap total in the free output."
},
{
"role": "assistant",
"content": "free -h -t"
}
] | single | free |
[
{
"role": "system",
"content": "You are a command-line assistant specializing in Bash and GNU coreutils."
},
{
"role": "user",
"content": "List active (established) sessions on port 53."
},
{
"role": "assistant",
"content": "lsof -i :53 -sTCP:ESTABLISHED"
}
] | single | lsof |
[
{
"role": "system",
"content": "You are a Linux shell expert. Respond with Bash only."
},
{
"role": "user",
"content": "Show detailed per-device iostat, 2s apart, 3 times."
},
{
"role": "assistant",
"content": "iostat -x 2 3"
}
] | single | iostat |
[
{
"role": "system",
"content": "You are a helpful assistant that writes correct, idiomatic Bash commands."
},
{
"role": "user",
"content": "Tally how many times each log level appears in audit.log."
},
{
"role": "assistant",
"content": "grep -oE '(INFO|WARN|ERROR|DEBUG)' audit.log | ... | pipeline | grep |
[
{
"role": "system",
"content": "You translate natural-language requests into correct Bash commands."
},
{
"role": "user",
"content": "Show the process tree for user dave."
},
{
"role": "assistant",
"content": "pstree dave"
}
] | single | pstree |
[
{
"role": "system",
"content": "You are a Linux shell expert. Respond with Bash only."
},
{
"role": "user",
"content": "Sum the response sizes (column 10) in metrics.log."
},
{
"role": "assistant",
"content": "awk '{s+=$10} END{print s}' metrics.log"
}
] | pipeline | awk |
[
{
"role": "system",
"content": "You are a Linux shell expert. Respond with Bash only."
},
{
"role": "user",
"content": "Run 'rsync -a /data /mnt/backup' at a lower priority (nice 19)."
},
{
"role": "assistant",
"content": "nice -n 19 rsync -a /data /mnt/backup"
}
] | single | nice |
[
{
"role": "system",
"content": "You are a Bash expert."
},
{
"role": "user",
"content": "Show memory usage using powers of 1000 (SI units)."
},
{
"role": "assistant",
"content": "free -h --si"
}
] | single | free |
[
{
"role": "system",
"content": "You translate natural-language requests into correct Bash commands."
},
{
"role": "user",
"content": "Show the systemd journal for the apache2 service."
},
{
"role": "assistant",
"content": "journalctl -u apache2"
}
] | single | journalctl |
[
{
"role": "system",
"content": "You are a command-line assistant specializing in Bash and GNU coreutils."
},
{
"role": "user",
"content": "Show every network socket in use."
},
{
"role": "assistant",
"content": "lsof -i"
}
] | single | lsof |
[
{
"role": "system",
"content": "You translate natural-language requests into correct Bash commands."
},
{
"role": "user",
"content": "Show just the amount of free memory in MB."
},
{
"role": "assistant",
"content": "free -m | awk '/Mem/ {print $4}'"
}
] | pipeline | free |
Bash Instruction-Tuning Dataset (~55k)
A synthetic instruction-tuning dataset that pairs natural-language requests with correct Bash solutions, built for fine-tuning small LLMs to translate plain requests into runnable shell commands, pipelines, and scripts.
Each example is a chat conversation (system / user / assistant) plus two metadata
fields (category, utility) for slicing and analysis.
Format
One JSON object per line (bash_dataset.jsonl):
{
"messages": [
{"role": "system", "content": "You are a Bash expert."},
{"role": "user", "content": "Show the last 20 lines of error.log."},
{"role": "assistant", "content": "tail -n 20 error.log"}
],
"category": "single",
"utility": "tail"
}
messagesβ the training conversation. The system prompt is one of 5 equivalent Bash-assistant prompts (rotated so the model doesn't overfit a single string).categoryβsingle|pipeline|script(see below).utilityβ the primary command of the solution (e.g.grep,awk,find,for), used to enforce a per-command cap and to analyze coverage.
Scripts (category == "script") contain real multi-line Bash (JSON-escaped \n),
typically with set -euo pipefail, functions, getopts, trap cleanup, loops,
here-docs, etc.
Statistics
| Metric | Value |
|---|---|
| Examples | 55,000 |
single (one-shot commands) |
22,000 (40%) |
pipeline (pipes, &&/||, $(...), xargs) |
19,250 (35%) |
script (multi-line) |
13,750 (25%) |
| Distinct primary utilities | 89 |
| Max share of any one utility | 4.00% (hard cap 2,200/util) |
| Unique user (NL) strings | 98.7% |
| Unique assistant (Bash) strings | 75.6% |
| Argument fidelity | 100% (0 request/command noun mismatches) |
| Largest shared 4-word NL opening | 1.4% |
Validity: 100% pass bash -n (0 syntax errors). Static analysis with
shellcheck flags no warning-level findings on 96% of a 4,000-example sample;
almost all remaining findings are a single style nit (SC2010, ls | grep).
Argument fidelity: every example is checked so the command actually
references the concrete nouns named in the request β the same filename,
extension, user, group, service, process, and port. This is enforced at
generation time by a hard gate (argcheck.py); the shipped file has 0
mismatches. (An earlier version of this generator had ~12% argument mismatches
that bash -n/shellcheck could not detect, because a wrong filename still
parses and lints; the gate exists specifically to prevent that.)
Coverage of system/info utilities that small models often get wrong (counts include single + pipeline + script uses):
| util | n | util | n | util | n |
|---|---|---|---|---|---|
| journalctl | 2200 | lsof | 648 | ss | 481 |
| pstree | 753 | renice | 365 | nice | 293 |
| vmstat | 288 | netstat | 234 | iostat | 183 |
| w | 158 | dmesg | 154 | free | 90 |
| uptime | 34 | hostname | 25 |
(uptime / hostname are lower because their genuine idiomatic command space is
small; they are covered with real flag variants rather than padded phrasings.)
How it was built
Generated by a recipe engine (generate.py, included). Each recipe family emits
(request, command) pairs by combining hand-written phrasing templates
(imperative / question / casual) with realistic parameter pools (plausible file
names, directories, ports, services, users, patterns). The generator enforces:
- category quotas (40 / 35 / 25),
- a 4% per-utility cap so no command dominates (a real failure mode of earlier runs),
- minimum floors for the info/system utilities above,
- SHA-1 deduplication of
(request, command)pairs, - an argument-fidelity gate (
argcheck.py) β the command must reference the same concrete nouns the request names, or the pair is rejected, - phrasing diversification so no single opening template dominates,
- a
bash -nsyntax gate on every command before it is written.
Every parameter (filename, dir, extension, user, ...) is drawn once per example and reused in both the request and the command, so they never disagree.
Loading
from datasets import load_dataset
ds = load_dataset("json", data_files="bash_dataset.jsonl", split="train")
print(ds[0]["messages"])
# analyze by slice
import collections
print(collections.Counter(ds["category"]))
print(collections.Counter(ds["utility"]).most_common(15))
The dataset viewer will expose messages, category, and utility as columns.
Intended use & limitations
Good for: teaching a small model to map natural-language requests to correct single Bash commands, short pipelines, and small scripts β including the system/info utilities listed above.
Limitations (be aware before relying on it):
- Synthetic. Variety comes from recombining templates and token pools, not from human authorship. Phrasing is diversified (no opening template exceeds ~1.5% of rows, NL strings are 98.7% unique), but the underlying request shapes are still generated from a finite set of families; ~24% of commands recur with different phrasings.
- Validity β full semantic correctness.
bash -n+ shellcheck prove the commands parse and lint clean, and the argument-fidelity gate guarantees the command uses the nouns from the request; none of these prove the command's logic perfectly satisfies the intent. Some pairs are plausible-but-approximate (e.g. anawkcolumn index assumes a particular log layout). - Single-turn, one canonical answer. No explanations, alternatives, negative examples, or multi-turn dialogue.
- Not executed at scale on real Linux. Many commands (
systemctl,journalctl,apt,vmstat, β¦) are idiomatic but were validated statically, not run.
Files
bash_dataset.jsonlβ the dataset (55,000 rows).generate.pyβ the generator (reproducible; resumable viaprogress.json).argcheck.pyβ the argument-fidelity checker used as the generation gate; also runnable as a standalone auditor over the dataset.README.mdβ this card.
- Downloads last month
- 37