--- license: cc-by-nc-sa-2.0 datasets: - Edoigtrd/tldr-pages language: - en library_name: transformers tags: - code --- # T5-nl2cmd T5-nl2cmd is a model that generates bash commands from natural language descriptions. This repository contains the trained model, fine-tuned from [Flan-T5 base](https://huggingface.co/google/flan-t5-base). # Training data - Tldr.sh pages - [tldr-dataset](https://huggingface.co/datasets/Edoigtrd/tldr-pages) - nl2bash - [nl2bash](https://github.com/TellinaTool/nl2bash) # Model The model is fine-tuned from the [Flan-T5 base](https://huggingface.co/google/flan-t5-base) model. It has been trained on a single Nvidia L4 from Scaleway, for 4 hours and 4 epochs. The model aims to generate bash commands from natural language descriptions. # Results > The results are evaluated on an 500 eval subset of the data cited above. | Metric | Flan-T5 - Nl2cmd | |--------------------|------------| | exact | 0.064 | | rouge | 0.530054 | | bleu | 0.177511 | | levenstein average | 0.612479 | | levenstein median | 0.608696 | # Examples : | Task | Command | |------|---------| | Count time, calls, and errors for each system call and report a summary on program exit | `slurmctl -c path/to/file` | | Search for a word in all the normal/regular files in the current folder | `find . -type f -exec grep -H` | | Start the daemon with verbose output coming from specific files in the bluetoothd or plugins source | `bluetoothd-start --verbose path/to/file` | | Find all directories under current directory and make them read, write, and executable for owner & group and remove read-write-execute permission for others | `find . -type d -exec chmod ug=` | | Set the verbosity level (error, warn, info, debug, or trace) | `svn -v verbosity` | | Show the configuration of a virtual machine, specifying its ID | `qm show vm_id` | | Import VPN configuration | `ipconfig import config` | | Find all the files ending with ".coffee" in the current folder and search for the words "re" in each line | `find . -name "*.coffee" -exec grep` | | Run a program from a file | `pstool --run path/to/file` | | Display details and metadata about a specified portable service image | `portablectl show-image path/to/image` | | Display all the files in the current folder excluding those which are in the path of ".git" | `find . -path '*.git' -prune -` | | Find all *.ogg files on the system ignoring the case | `find / -iname "*.ogg"` | | Print and recursively remove the alphabetically last directory in the current directory | `rmdir -rf` | # License : [Creative Commons cc-by-nc-sa 4.0](https://creativecommons.org/licenses/by-nc-sa/4.0/)