GitHub - sagivo/improve-my-text

2 min read Original article ↗

A lightweight macOS menu bar app that improves any selected text using LLMs. Highlight text anywhere, press a shortcut, and get an improved version pasted back — powered by the Vercel AI SDK.

How It Works

  1. Select text in any app
  2. Press ⌘⇧I (customizable)
  3. The app captures the selection, sends it to your chosen LLM, and pastes the improved text back

No windows, no context-switching — it lives entirely in your menu bar.

Features

  • System-wide — works in any app that supports standard copy/paste
  • Multiple LLM providers — OpenAI, Anthropic, Google, or any OpenAI-compatible API (Groq, Together, Ollama, etc.)
  • 6 built-in prompts — Improve Writing, Fix Grammar, Make Concise, Make Friendly, Make Professional, Simplify
  • Custom prompts — add your own prompt templates with system instructions and {text} placeholders
  • Configurable shortcut — record any key combo in settings
  • Dark mode support

Getting Started

Prerequisites

  • macOS
  • Node.js 18+

Install & Run

First Run

  1. The app appears as a menu bar icon. Click or right-click to access Settings.
  2. Grant Accessibility permissions — the app uses System Events to read selected text. Go to System Settings → Privacy & Security → Accessibility and add the Electron app.
  3. Add a model — open Settings → Models → Add Model. Enter your API key and model ID.
  4. Select text anywhere, press ⌘⇧I, and the improved text replaces your selection.

Configuration

Models

Add one or more models in Settings → Models. Each needs:

Field Description
Display Name Label shown in the dropdown
Provider OpenAI, Anthropic, Google, or OpenAI-Compatible
API Key Your provider API key
Base URL (optional) Custom endpoint, e.g. http://localhost:11434/v1 for Ollama
Model ID e.g. gpt-4o, claude-sonnet-4-20250514, gemini-2.0-flash

Prompts

Each prompt template has a name, a system prompt (sets the AI's behavior), and a user template that must include {text} as the placeholder for selected text. The 6 defaults cover the most common use cases, and you can add as many custom prompts as you like.

Keyboard Shortcuts

Shortcut Action
⌘⇧I (default) Trigger text improvement

Change the trigger shortcut in Settings → General → Record.

Tech Stack

  • Electron — menu bar app, no dock icon
  • Vercel AI SDKai, @ai-sdk/openai, @ai-sdk/anthropic, @ai-sdk/google
  • Vanilla JS — no framework, no build step

License

MIT