https://github.com/cpcf/meh
Machine Enhanced Help (meh) is a command-line tool for interacting with large language models.
https://github.com/cpcf/meh
cli go llm
Last synced: 5 months ago
JSON representation
Machine Enhanced Help (meh) is a command-line tool for interacting with large language models.
- Host: GitHub
- URL: https://github.com/cpcf/meh
- Owner: cpcf
- Created: 2025-02-19T11:13:07.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2025-03-01T20:04:54.000Z (over 1 year ago)
- Last Synced: 2025-03-15T07:53:32.615Z (over 1 year ago)
- Topics: cli, go, llm
- Language: Go
- Homepage:
- Size: 54.7 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# meh
## Overview
`meh` is a simple CLI tool that constructs and executes queries based on command-line arguments and piped input. It supports file-based input, configurable settings, persona selection, and an interactive TUI mode.
## Usage
```sh
meh [options] [query]
```
### Options
- `-f `: Read input from a specified file.
- `-c`: Edit configuration settings.
- `-p `: Select a persona.
- `-h`: Display usage instructions.
### Behavior
1. **Query Construction**:
- CLI arguments are combined with any piped input.
- If a query is constructed, it is passed to the application.
2. **File Input (`-f`)**:
- Reads input from a specified file and processes it as a query.
3. **Config Mode (`-c`)**:
- Allows editing of configuration settings.
4. **Persona Selection (`-p`)**:
- Assigns a predefined persona to the session.
5. **Interactive TUI Mode**:
- If no query is provided, a text-based user interface (TUI) is launched.
- The TUI allows creating new personas, selecting an existing persona, and engaging in interactive chat.
6. **Help (`-h`)**:
- Displays usage instructions.
7. **Error Handling**:
- Logs fatal errors if issues occur while reading input or processing commands.
## Example Usage
```sh
meh "Hello World"
```
```sh
echo "piped input" | meh
```
```sh
meh -f input.txt
```
```sh
meh # Launches the interactive TUI
```
## Dependencies
- go 1.23
## Running the Application
```sh
go run meh.go [options] [query]
```