From a61f40a4221c1586d801308da9ae1869fb6bdbb6 Mon Sep 17 00:00:00 2001 From: Paul Buetow Date: Sun, 17 Aug 2025 08:54:20 +0300 Subject: cli: add hexai command-line tool and split LSP to hexai-lsp - New cmd/hexai CLI: reads stdin/arg, prints LLM output to stdout - Prints provider/model immediately to stderr; summary at end - Refactor config loader to internal/appconfig - Update Taskfile to build/install/run both binaries - Update README with new CLI and LSP names --- README.md | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) (limited to 'README.md') diff --git a/README.md b/README.md index 2951425..837292c 100644 --- a/README.md +++ b/README.md @@ -43,11 +43,20 @@ Notes: ## CLI usage and configuration - Run LSP server over stdio: - - `hexai` + - `hexai-lsp` -- Flags (minimal): +- LSP flags (minimal): - `-version`: print the Hexai version and exit. - - `-log`: path to log file (optional; default `/tmp/hexai.log`). + - `-log`: path to log file (optional; default `/tmp/hexai-lsp.log`). + +- Run command-line tool (processes text via configured LLM): + - `cat SOMEFILE.txt | hexai` + - `hexai 'some prompt text here'` + - `cat SOMEFILE.txt | hexai 'some prompt text here'` (stdin and arg are concatenated) + +Notes for `hexai` (CLI): +- Prints LLM output to stdout. +- Prints provider/model immediately to stderr, and a summary to stderr at the end (time, input bytes, output bytes, provider/model). Notes: - Token estimation for truncation uses a simple 4 chars/token heuristic. -- cgit v1.2.3