| Crates.io | xa |
| lib.rs | xa |
| version | 0.1.0 |
| created_at | 2026-01-07 05:08:43.254323+00 |
| updated_at | 2026-01-07 05:08:43.254323+00 |
| description | Execute Anything via LLM - A CLI tool for arbitrary text processing using LLMs |
| homepage | |
| repository | |
| max_upload_size | |
| id | 2027558 |
| size | 102,057 |
xa is a minimal yet powerful CLI executor that enables arbitrary text processing through user-defined prompts + LLMs, such as translation, polishing, rewriting, continuation, summarization, etc.
User defines intent. xa executes it.
Compared to opening ChatGPT or web tools, xa aims to be:
# Clone the repository
git clone <repository-url>
cd xa
# Build the project
cargo build --release
# The binary will be available at target/release/xa
First, configure your LLM API settings:
xa --set openai
This will prompt you for:
Configuration is stored in ~/.config/xa/config.toml.
List all available commands:
xa --ls
Add new commands with custom prompts:
xa --add
This will prompt you to enter:
{input} as placeholder)The prompts are stored in ~/.config/xa/prompts.toml and can be edited with your favorite text editor.
Remove existing commands:
xa --rm command_name
Configure your LLM API settings:
xa --set openai
During setup, xa will:
Execute a command with input:
xa translate "Hello, how are you?"
xa polish "This is a draft text that needs improvement"
xa summarize "Long text to summarize..."
By default, xa streams the response from the LLM in real-time. To disable streaming:
xa translate "Hello" --no-stream
xa supports fuzzy command matching:
xa trans "Hello" # Matches to 'translate'
xa pol "text" # Matches to 'polish'
-s, --set: Configure API settings-l, --ls: List all available commands-a, --add: Add a new command/prompt-r, --rm: Remove a command/prompttranslate: Translate textpolish: Polish text for clarityrewrite: Rewrite text in different stylesummarize: Summarize text~/.config/xa/config.toml~/.config/xa/prompts.tomlMIT