pgibler / cmdh

Create Linux commands from natural language, in the shell.
MIT License
83 stars 6 forks source link

Check system for existing packages related to setup commands #6

Closed pgibler closed 6 months ago

pgibler commented 7 months ago

Add functionality to check the system for existing packages that are related to the setup commands. There are two ways that this could be done:

  1. Before the setup commands are requested, add a step that does the following
    • Returns all the packages required to run the desired command.
    • Then, run the which command to detect installed packages
    • Then, in the system prompt, tell the LLM to exclude all setup commands related to existing packages
  2. Include in the full prompt output the required packages alongside the setup commands
    • then, run the which command on the system for each existing package
    • regex the setup commands and remove the ones that match