Metadata-Version: 2.4
Name: hashtagAI
Version: 0.3.1
Author: Thanabordee N. (Noun)
Author-email: thanabordee.noun@gmail.com
Classifier: Programming Language :: Python :: 3
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Classifier: Topic :: Utilities
Requires-Python: >=3.7
Description-Content-Type: text/markdown
Requires-Dist: dspy
Requires-Dist: distro
Requires-Dist: importlib-metadata
Dynamic: author
Dynamic: author-email
Dynamic: classifier
Dynamic: description
Dynamic: description-content-type
Dynamic: requires-dist
Dynamic: requires-python

# hashtagAI

hashtagAI is a command-line tool that generates terminal command responses using various providers' language models. It helps users find and execute the right terminal commands by providing clear explanations and ready-to-use commands.

## Features

- **AI-powered command generation**: Get terminal commands from natural language descriptions
- **Multi-provider support**: Works with different LLM providers
- **Interactive mode**: Ask follow-up questions and maintain conversation context
- **Command execution**: Run suggested commands directly from the interface
- **Command history**: View and recall previous commands and explanations
- **Cross-platform support**: Works on Linux, macOS, and Windows

## Installation

To install the package, run:

```sh
pip install hashtagAI
```

## Usage

After installation, you can use the `ask` command to generate terminal command responses. The `ask` command takes a natural language description as input and provides a concise explanation and the exact terminal command to accomplish the task.

### Examples

**Basic usage:**
```shell
ask How do I update all packages on Fedora?
```

**Output:**
```
#AI Assistant:
Explanation:
To update all packages on your Fedora system, you can use the dnf package manager. The following command will check for updates and install them for all installed packages.

Command:
sudo dnf update
```

**More examples:**
```shell
ask How do I find large files in my home directory?
ask How can I check CPU temperature on Ubuntu?
ask Create a backup of my Documents folder with date in filename
```

### Interactive Mode

Launch hashtagAI in interactive mode by running:

```shell
hashtagai
```

This will start a conversation where you can ask multiple questions and maintain context.

## Configuration

Ensure you have set the required environment variables:

- `PROVIDER_API_KEY`: Your API key for the LLM provider
- `LITELLM_MODEL_ID`: The ID of the model to use (optional, default: `gemini/gemini-2.0-flash`)
- `HASHTAGAI_TYPING_SPEED`: Controls the typing animation speed (optional, default: `0.001`)
- `HASHTAGAI_MAX_HISTORY`: Maximum number of interactions to keep in history (optional, default: `10`)

### Example Configuration

```sh
# Required
export PROVIDER_API_KEY='YOUR_API_KEY'

# Optional configurations
export LITELLM_MODEL_ID='meta-llama/Meta-Llama-3.1-70B-Instruct-Turbo'
export HASHTAGAI_TYPING_SPEED='0.002'
export HASHTAGAI_MAX_HISTORY='15'
```

## Development

To contribute to this project, follow these steps:

1. Clone the repository:
   ```sh
   git clone https://github.com/thanabordeen/hashtagai_terminal_llm.git
   cd hashtagai_terminal_llm
   ```

2. Install development dependencies:
   ```sh
   pip install -r requirements-dev.txt
   ```

3. Make your changes and test them locally:
   ```sh
   python -m hashtagai
   ```

4. Submit a pull request with your changes.

## License

This project is licensed under the MIT License.

## Author

Thanabordee N. (Noun)
