Search for Linux commands on the command-line right away
Sometimes, we forget the command we planned to use if we haven't used it in a while. For new command line users, this happens more often, as they just started learning and aren't familiar with the commands. This is where this tool, Ask-Filius, comes in handy. It allows users to search for the command by describing what the command should do, then it will recommend several candidates the user is likely looking for.
Ask-Filius relies on information on the internet. Descriptions of commands are scraped down and analyzed using TF-IDF and apriori method. The recommendation is then made according to the analysis result.
The current challenge of this project is that it lacks accuracy. This is probably because of the defective collection of data I use to analyze. Also, I wonder if there is a better way to implement this idea. If you have a better solution in mind, please feel free to raise an issue.
- Download archive from the Release page
- Extract the tool
tar -xzf ask_filius_0.1.0_linux.tar.gz -C /usr/local/bin
ask
The tool will ask you to describe the command
$ ask
What command are you looking for?
Try describe what the command does:
Describe the command and get results from the tool!
- Install all packages
pip install -r requirements.txt
-
Create a programmable search engine on Google. See more on Programmable Search Engine
-
Add
API_KEY
andSE_ID
(search engin id) in.env
file. See more on Programmable Search Engine for how to get these variables
API_KEY=<YOUR_API_KEY>
SE_ID=<YOUR_SEARCH_ENGINE_ID>
- Run the following python scripts
python3 text-scrape.py
python3 tfidf.py
python3 association-scrape.py
python3 apriori.py
- Start the tool by running
main.py
python3 main.py
Pull requests and advice are welcomed. Please feel free to raise issues and PRs.