Overview
WinkTerm is an open-source AI terminal positioned as "an AI that shares the terminal session with the user." According to the project description, it is not a chatbot pasted into the terminal, nor an assistant that only gives suggestions, but an operator collaborating with the user in the same PTY (pseudo-terminal)—the AI writes commands directly into the terminal input line, and the user presses Enter to execute them, or can freely edit or cancel them. The project address is https://github.com/Cznorth/winkterm,采用 MIT License.
Main capabilities
- Shared PTY session: AI and the user operate in the same terminal process, with no need to copy and paste.
- In-terminal chat: At the shell prompt, type
#plus a question to ask, without switching windows. - Sidebar AI panel: Provides a full conversation interface, supporting multiple session tabs, AI-generated titles, and chat/craft mode switching.
- Persistent chat history: Conversations are saved to
~/.winkterm/chat_history.json, restored when the page loads, and can survive WebSocket reconnections and backend restarts. - Streaming recovery and queueing: Refreshing or reconnecting mid-response does not lose tokens; subsequent messages can be queued while the AI is replying, and the queue can be interrupted or discarded; after each answer, one-click follow-up suggestions are provided.
- External Agent API: An authenticated HTTP interface through which external agents (such as Claude Code and Cursor) can drive the terminal, SSH, and file transfer via an installable skill.
- SSH remote connections: Built-in file transfer; when editing a connection, saved credentials are retained if the password is not re-entered.
- Multi-model support: Bring your own LLM (OpenAI, Anthropic, Ollama, and any compatible endpoint), or use Codex OAuth to directly use a ChatGPT / Codex subscription.
- Docker and desktop: Can be deployed via
docker compose up, or packaged as a standalone Windows/macOS desktop application. - Internationalization: Built-in English / Chinese interface, with language selection on first launch.
Agent API highlights
The project describes its HTTP Agent API as designed for AI agents to remotely drive the terminal: exit codes are returned directly as a first-class field (no need to grep output to determine failure); more than 30 named keys are provided (such as ctrl+c / up / tab / esc / f1), so raw control characters are not needed in JSON; complex commands can be passed via command_b64 as base64; after each execution it reports $PWD to continuously track the working directory; terminals are automatically cleaned up after a default 30-minute idle TTL;wait has a reason field distinguishing idle / timeout / no_output. The internal craft agent and the external HTTP API share the same terminal session pool and tool surface (list / create / close / snapshot / input / exec / ssh_run).
How to use
- Docker:
docker compose upthen open http://localhost:3000 ; the compose file mounts thewinkterm-datavolume to/root/.winkterm, configuration, chat history, and SSH credentials can be retained across container rebuilds. - Desktop: Download the installer package for the corresponding platform from the Releases page (Windows is a .exe installer, macOS is a .app, supporting Intel and Apple Silicon).
- Configuration: WinkTerm uses the OpenAI-compatible protocol; set
OPENAI_BASE_URLto connect to Ollama, vLLM, Groq, OpenRouter, etc.; Codex OAuth requires no environment variables—just enable it in settings and complete browser login, and status queryGET /api/codex/status, initiate loginPOST /api/codex/oauth/start.
Applicable Scenarios
Suitable for scenarios that require collaborating with AI in a real terminal to complete operations tasks, such as SSH remote server management, Docker operations, troubleshooting, and automated processes in which AI agents remotely drive terminal task execution. The project also provides a case: the user only said "the 107.173 server load is very high," and the AI agent, via the Agent API, completed discovery, investigation, attack chain reconstruction, hardening, and abuse reporting within 30 minutes.
Limitations and Notes
Specific fees, pricing, and commercial licensing details are not yet provided. The project roadmap mentions multiple plans (such as Vim/Neovim integration, terminal recording and playback, multi-agent orchestration, a plugin system, native tmux integration, and Kubernetes context awareness); these are future plans, not existing features. Web access is protected by an access key, and the local desktop client requires no authentication.