Content
<p align="center">
<strong>Hesi: Universal Terminal Center in Browser</strong><br>
<em>Where multiple AIs meet to think together</em><br>
<em>Run any CLI, connect any Agent, control any browser</em>
</p>
<p align="center">
<a href="https://github.com/qiuqiukof-oss/Hesi/blob/main/LICENSE"><img src="https://img.shields.io/badge/license-MIT-blue.svg" alt="License"></a>
<a href="https://nodejs.org/en/"><img src="https://img.shields.io/badge/node-%3E%3D18.0.0-brightgreen" alt="Node Version"></a>
<img src="https://img.shields.io/badge/tested_on-Windows%20%7C%20macOS%20%7C%20Linux-lightgrey" alt="Platform Support">
</p>
<p align="center">
<img width="2549" height="1191" alt="image" src="https://github.com/user-attachments/assets/0ee0f21a-d3f9-49f8-a8a6-0e605aafe11a" />
</p>
<p align="center">
<b>Turn your browser into your development command center</b> — Multi-session terminal, multi-Agent round-table collaboration, browser automation, and MCP services, all self-hosted and ready to use.
</p>
---
> 🌐 **English documentation available:** [README_en.md](./README_en.md)
> ⚠️ **Security Warning**
>
> Hesi can execute arbitrary terminal commands and control browsers through WebSocket (CDP integration).
> **It is strongly recommended to use it locally on loopback addresses (`127.0.0.1` and `::1`) only. If you must expose it to a non-local network, be sure to set `QCLI_ACCESS_TOKEN` and read the "Secure Deployment" section below.**
> Public deployment without authentication may lead to remote code execution (RCE) risks.
---
## 🚀 30-Second Quick Start
**Want to get started quickly?** Use the offline portable package, double-click to use, no need to install Node:
| What do you want to do? | How to do it |
|------|--------|
| 💻 **Try without installation** (recommended for beginners) | Download the [Desktop Tray Bundle](#desktop-tray-bundle), double-click `tray.bat`(Windows)/`./tray.sh`(macOS/Linux), and your browser will automatically open `http://127.0.0.1:4264` |
| 🛠️ **Run from source code** (for developers) | `git clone` → `npm install` → `npm run build` → `npm start`, open `http://127.0.0.1:4264` |
| 🤖 **Let AI work for you** | In "Settings", fill in `OPENAI_API_KEY` or `ANTHROPIC_API_KEY`, and then directly chat in the chat box ( **you can still use the terminal without filling in** ) |
> 💡 You will see a new user guide bubble on the first opening. If you don't know what to do, try: **Open a terminal tab → Enter `dir`(Win)/`ls`(Mac/Linux) → Ask AI in the chat box "Explain the current directory"**.
📖 **Complete Beginner's Guide**: [docs/getting-started.md](./docs/getting-started.md) | 🧑💻 **Contributor's Guide**: [CONTRIBUTING.md](./CONTRIBUTING.md)
---
## ✨ Why Choose Hesi
- 🧭 **One tab, control everything** — Terminal, AI Agent, browser, document conversion, MCP tools, all unified in one web console.
- 🤝 **Multi-Agent round-table collaboration** — Let opencode, Codex, aider, and other CLI Agents have a multi-round "round-table discussion" on the same task, colliding solutions instead of fighting alone.
- 🛡️ **Headless execution, no conflict** — CLI Agents run headlessly in the background, rendering and your interactive terminal completely decoupled, with a clean and non-interfering experience.
- 🔌 **Open and scalable** — Modular MCP server + plugin system + CLI preset templates, connect to your toolchain as needed.
- 💻 **Desktop tray portable version** — Comes with an offline Node runtime, double-click `tray.bat` to use immediately, zero installation.
- 🔒 **Secure and auditable** — Session-level authentication, audit logs, and security policies, with default zero configuration on local loopback.
---
## Table of Contents
- [✨ Why Choose Hesi](#✨-why-choose-hesi)
- [Overview](#overview)
- [The Name](#the-name)
- [Features](#features)
- [🚀 30-Second Quick Start](#-30-second-quick-start)
- [Quick Start](#quick-start)
- [Desktop Tray Bundle](#desktop-tray-bundle)
- [Architecture](#architecture)
- [Tech Stack](#tech-stack)
- [Testing](#testing)
- [Contributing](#contributing)
- [Secure Deployment](#secure-deployment)
- [License](#license)
---
## Overview
**Hesi** is a web-based universal terminal bridge platform. It combines `node-pty` + `xterm.js` with WebSocket real-time communication, allowing you to experience a native terminal in your browser. On top of this, it integrates AI dialogue, Agent management, MCP modular services, visual panels, browser automation, and more.
### Core Philosophy
| Concept | Description |
|------|------|
| **Everything is CLI** | Launch any command-line tool in your browser, with multiple tabs running independently |
| **AI Native** | AI assistant integrates terminal context awareness + tool call chain (loop detection to prevent loss of control) |
| **AI × CLI Agent Collaboration** | Let AI assistants and CLI Agents (like opencode, Codex, aider) have multi-round "round-table discussions" on the same issue, colliding solutions |
| **Modular MCP** | Model Context Protocol service, supporting session persistence, security policies, and audit logs |
| **Browser Control** | Control Chrome/Edge through CDP integration, supporting script injection, network monitoring |
| **Scalable** | Plugin system + preset templates + theme customizer + custom CSS injection |
---
## The Name
**HeSi** — A name, two layers of thought.
**Chinese**
- **He** — Collaboration and combination: multiple Agents gather in one place, with Western and Chinese tool ecosystems connected here.
- **Si** — Thinking and inspiration: AI's intellectual activity, as well as that fleeting idea.
- Together, "HeSi" is homophonic with "coincidental inspiration", with a bit of unexpected surprise. The two characters are memorable at a glance.
**English**
- **HeSi** — four letters, one keystroke away in your terminal. A name built for the CLI.
- **He** + **Si** (pinyin "Si") happens to be read as *"He thinks"* — A thinking partner, purely a wonderful coincidence.
- The ending vowel makes it smooth to pronounce.
> In one sentence: **HeSi is where multiple minds meet to think — together.**
---
## Features
### 🖥️ Multi-Session Terminal
- **xterm.js + WebGL rendering** — Smooth terminal output, supporting WebGL and Canvas dual rendering backends
- **Multi-tab management** — Each tab has an independent PTY process, not interfering with each other, supporting drag-and-drop sorting and pinning
- **Terminal search** — Ctrl+Shift+F search in terminal output, supporting up and down navigation
- **Link recognition** — Automatically recognize file paths, URLs, and click to preview in the browser
- **Adaptive width and height** — Adapt to container size through FitAddon
- **Session persistence** — IndexedDB stores terminal content, restoring after page closure
- **Font adjustment** — Ctrl+= / Ctrl+- real-time adjustment, supporting 8-32px range
### 🔍 CLI Auto-Discovery & Presets
- **PATH scanning** — Automatically scan system executable files, generating a quick launch list
- **Preset system** — Built-in presets for developers, data scientists, system administrators, media engineers, and more
- **Preset inheritance** — Presets support `extends` chain inheritance, sharing basic configurations
- **Cache acceleration** — 24-hour disk cache, avoiding repeated scanning on each launch
- **Version detection** — Automatically detect CLI version numbers (trying multiple flags: `--version`, `-v`, `-V`)
- **Type classification** — Automatically determine interactive/batch type, supporting custom classification
- **Folder organization** — Support creating folder groups for management, drag-and-drop classification
- **Favorites** — Left sidebar can collect commonly used CLI; discussion mode Agent dropdown and favorites **automatically synchronize** (favorite items default to checked, pinned, and marked with ★)
### 🤖 AI Integration
- **Multi-provider** — Support OpenAI, Anthropic, LM Studio (local model)
- **SSE streaming output** — Structured event types (token/status/error/tool_calls/usage), 120s idle timeout protection (configurable `HESI_LLM_STREAM_IDLE_MS`)
- **Terminal context awareness** — Automatically capture the latest 100 lines of terminal output as a system message
- **Incremental context pruning** — Only send changed incremental lines, saving tokens
- **Tool call chain** — Continuous tool calls with loop detection (ring detection + window deduplication + hard limit), preventing "instant overflow" style loss of control; depth thinking panel presents real-time tool cards (running → completion time + result preview, XSS security)
- **Lightweight self-inspection** — Identify "comprehensive self-inspection / self-inspection" intent, automatically set the tool round limit to 6 rounds, significantly reducing redundant LLM calls
- **Tool set** — File read/write, web search, terminal execution, document conversion, image/video generation
- **Browser control tools** — Navigation, screenshot, click, input, execute JS, DOM snapshot, form filling
- **Self-evolution** — Can read/modify its own source code, rebuild frontend, screenshot check UI
### 🧠 Cross-Session Memory
> Let AI remember you: conversations are no longer lost after refresh/restart, and can be **recalled across sessions**.
- **Server-side persistence** — Each conversation is stored in `data/memory/` ("session" as the unit, not relying on browser localStorage, still recoverable after refresh/restart).
- **Left column session list** — Chat panel left column adds session column: new / continue / search / double-click rename / delete; grouped by "today / yesterday / past 7 days / earlier".
- **🧠 Memory drawer** — Top 🧠 button opens, displaying **automatically generated user profile** and **remembered facts**, each fact can be "forgotten".
- **Automatic summary compression** — Long conversations exceeding the threshold are automatically compressed into `<session_summary>` (retaining decisions/facts/preferences), releasing context; LLM unavailable downgrades to retain original text.
- **BM25 recall** — Each question automatically retrieves relevant historical conversations and facts as `<memory>` blocks injected into AI context (zero dependency, pure local, offline capable).
- **User profile / facts (Layer A)** — Fades out stable facts (preferences, projects, identity), deduplicates accumulated confidence, distills into `profile.md`; viewable, forgettable.
- **Degradable switch** — Environment variable `HESI_MEMORY_ENABLED=0` closes the subsystem, chat returns to original localStorage behavior, **zero behavioral change**.
- **Old history migration** — First upgrade automatically imports browser old `localStorage['qcli-chat-history']` as the first session; can also use `node scripts/memory-migrate.js --file legacy.json` offline import.
> Privacy: all memories are stored locally in `data/memory/`, not connected to any cloud; `facts.json` / `profile.md` can be manually edited or deleted.
### 🤝 AI Assistant × CLI Agent Collaborative Discussion (Round-Table)
> This feature is Hesi's core collaboration scenario: let "AI assistants" and one or more "CLI Agents (like opencode) have **multi-round discussions** on the same issue, questioning, supplementing, and refining solutions.
- **Multi-select discussion partners** — In the chat panel, click the "Discuss" button, multi-select (up to 4) from discovered CLI Agents as discussion objects
- **Multi-round iteration** — Supports configuration discussion rounds, AI assistants and Agents take turns speaking, converging round by round
- **Incremental extraction** — Each round only feeds Agent's **new output** to AI (preventing same text from filling up context)
- **Favorites synchronization** — Discussion dropdown merges `/api/agents` and `/api/clis`, and reads left sidebar favorites, **favorite items default to checked, pinned, and marked with ★**
- **Timeout and cleanup** — Single Agent session 5 minutes timeout automatic termination, completed sessions 5 minutes TTL after cleanup
### 🛡️ CLI Agent Rendering
> Full-screen TUI CLI Agents (like **opencode**) draw ASCII interfaces/status bars in PTY, their rendering frames are literal text, stripped of escape sequences, polluting discussion text fed to AI (manifesting as "stuck in interface rendering, not providing substantial analysis").
- **Headless subcommand** — For Agents declaring headless mode, use non-interactive subcommands and **stdin pipeline** injection tasks (non-TTY, from the source to prevent TUI), outputting clean plain text
- **Multi-CLI support** — `lib/cli-headless.js` `HEADLESS` maps current built-in four (all tested, task prompts unified stdin, no argv拼): `opencode` (`opencode run`), `claude` (`claude -p`), `codex` (`codex exec -`), `aider` (`--yes-always --no-auto-commits --no-pretty --no-stream`); add other CLI just need to make up a description
- **Windows security points** — Headless execution on Windows starts with `shell:true`, argv will be re-parsed, so **multi-line/quoted prompts must be injected via stdin** (tested with `test/cli-headless.test.js` with malicious prompts covering `"`/newline/`rm -rf`)
- **Fallback compatibility** — Agents not declaring headless still use PTY + escape cleaning (`lib/terminal-clean.js`), behavior unchanged
- **TUI retention** — Human interactive terminal (`ws/agent.js`) and workflow (`ws/orchestrator.js`) TUI complete retention, unaffected
### 🌐 Browser Control (CDP)
- **Automatic connection** — Detect Chrome/Edge CDP port (default `localhost:9222`)
- **Page operation** — Navigation, forward/backward, refresh, screenshot, execute JS
- **Element interaction** — Click, input, hover, scroll
- **Console monitoring** — Real-time browser console log acquisition
- **Tab management** — List/switch all browser tabs
- **Browser farm** — Multiple isolated browser sessions parallel management
- **User script** — Inject custom JS scripts in specified URL patterns automatically execute
- **DOM Diff** — DOM snapshot comparison, tracking page changes
- **Form auto-filling** — Automatic detection and filling of form fields
- **Accessibility analysis** — Page accessibility issue detection
- **Network monitoring** — Real-time capture of HTTP request/response, supporting HAR import/export
### 📄 Document Format Conversion
- **AI-driven** — Through `convert_document` tool in AI dialogue direct conversion
- **Multi-format support** — PDF / DOCX / PPTX / HTML / EPUB / LaTeX / RST / Markdown
- **Pandoc-driven** — Automatic detection of system pandoc, supporting `PANDOC_PATH` environment variable
- **Intelligent degradation** — Without pandoc, automatically use built-in Markdown→HTML converter
### 🔌 MCP Server
- **Modular architecture** — `mcp/` directory contains tools, resources, security, session management submodules
- **Session management** — `SessionManager` + `RingBuffer` + TTL automatic expiration
- **Security layer** — Bearer authentication + audit logs + YAML policy file
- **Cache layer** — LRU cache + METRIC statistics + heartbeat report
- **AI bridging** — MCP → OpenAI Function Calling conversion
- **Automatic restart** — Health check + exponential backoff restart
- **Rate limiting** — Token Bucket algorithm, preventing tool call storm
- **Output truncation** — Tool result automatic truncation (4K character limit)
### ✅ Code Quality & Security
- **PTY environment variable filtering** — Automatic filtering of API_KEY/TOKEN/PASSWORD sensitive patterns
- **Double-layer current limiting** — Global API current limiting + WebSocket message current limiting + upload current limiting + upload limiting
- **Regression testing** — Terminal cleaning, discussion coordinator, stability (tool interruption/current limiting/stream completion/ring detection) three-layer verification
- **Prettier + ESLint** — Code unified formatting + lint-staged pre-commit check###
🎙️ User Experience
- **Command — Ctrl+K CLI and operation search **Voice Input/Output** — Web Speech API for input; TTS for reading AI responses
- **Theme Customizer** — Built-in presets + custom saving
- **Multilingual Interface** — English / Chinese for instant switching
- **Notification System** — Toast notifications + Notification Center
- **Custom CSS** — Real-time injection of custom styles
- **Welcome Carousel** — Guided introduction for first-time## Quick Start
### Prerequisites
| Item ||------|-------------|
| **Node.js** | >= 0.0 |
|** | >= 9.0.0 |
| **** | Windows / mac Linux |
### Install
```bash
git clone https:///qiuqiukofesi.git
cd Hesi # (need to extract portable node to directory)
npm install
npm run build # Production build for frontend (outputs public/bundle.js)
npx playwright install chromium # Optional, for browser control functionality
cd Hesi/tray
npm install
```
### Start
```bash
npm start # → http://localhost:3001 (default listen on 127.0.0.1 and ::1)
npm run dev # Development mode ()
npm run # Start MCP service```
### Environment Variables
| Default Value | Description |
|----------|---------------|-------------|
| `PORT` | `3001` | HTTP service port |
| `HOST` | `loopback` | Listen address; set0.0.0.0` will print warning |
| `OPENAI_API_KEY` / `ANTHROPIC_API_KEY` | — | LLM provider keys (optional) |
| `STABILITY_API_KEY` / `B_API_KEY` / `TAVILY_API_KEY` | — | Image/search keys (optional) |
| `PANDOC_PATH` | — | Pandoc path (optional, for document conversion) |
| `QCLI_ACCESS_TOKEN` | `""` | Access token; set to require authentication forapi` and WebSocket (loopback exempt by default) |
| `QCLI_TOKEN_REQUIRE_LOOPBACK` | `""` | Set to `1` to enforce token even on loopback |
| `QCLI_CORS_ORIGINS` | `""` | Comma-separated CORS whitelist |
| `QCLI_POLICY_PATH` | `""` | MCP security policy file (default `blocklist`) |
| `QCLI_WITH_MCP` / `QCLI_MCP_TOKEN` | `""` | Auto-start MCP / MCP Bearer token |
| `QCLI_AUDIT_LOG` | `""` | MCP audit log path |
| `QCLI_SESSION_TTL` | `900000` | Session idle expiration (ms) |
| `QCLI_MAX_SESSIONS` | `10` | Maximum concurrent sessions |
> 💡 See complete variables in `./.env.example`
## Desktop Tray Bundle
Hesi also provides an **out-of-the-box offline intelligent package**: comes with a portable Node.js, no installation required, and can be started by double-clicking.
```text
Windows: Double-click tray.bat
macOS : Run ./tray.sh in terminal (need chmod +x tray.sh for first time)
Linux : Run ./tray.sh in terminal
```
- After starting, Hesi icon appears in the tray, and automatically opens `http://127.0.0.1:4264`
- On the welcome page, click 「AI Agent (one-click install)」 to install OpenCode / Codex offline
- Tray menu: Open Hesi / Open (CDP mode) / Stop service / Exit
- By default, only binds to the local loopback address and does not expose to the LAN
- macOS 「Cannot verify developer」: `xattr -dr com.apple.quarantine .` and retry
- Port occupied: set `PORT` environment variable to change port
## Architecture
```
├── server.js # Express entry + static file service
├── ws-handler.js # WebSocket connection management + PTY (core terminal logic)
├── cli-discovery.js # CLI auto-discovery engine (including disk registry cli-registry.json)
├── cli-registry.json # CLI registry (agent list / favorite source, runtime persistence)
├── preset-loader.js # Preset loader
├── rate-limiter.js # API rate limiting
├── ring-buffer.js # Ring buffer
├── mcp-server.js # MCP sidecar entry
├── mcp/ # Modular MCP architecture (tools/resources/security/session)
├── ws/ # WebSocket subsystem
│ ├── pty.js # PTY creation abstraction + createHeadlessExec (headless Agent execution)
│ ├── pty-policy.js # PTY policy engine
│ ├── message-dispatch.js # WebSocket message routing
│ ├── agent.js # Human-computer interaction Agent terminal (保留 TUI)
│ ├── orchestrator.js # Workflow orchestration TUI, support single ws concurrent multi-workflow)
│-employee.js # Digital employee team (role/persona/task assignment)
│ ├── digital-employee-worker.js # Digital employee task executor (reuse agentPool, real task execution)
│ └── context-store.js # Shared context storage
/ # RESTful API routes
│ ├── # AI chat + discuss (AI × CLI Agent roundtable)
│ ├── ai-tools/ # Agent pool-pool.js) + synchronous delegation (builtin/agent.js)
├── clis.js / agents.js # CLI / Agentincluding category, support favorite synchronization)
│ └── ... # Other routes
├── lib/
│ ├── cli-headless.js # Headless Agent description table (opencode/claude/codex/aider, all stdin injection)
│ ├── asset-hash.js # bundle.js/lazy-bundle.js content hash (?v= cache penetration)
│ ├── terminal-clean.js # TUI escape cleaning (CSI/OSC/raw ESC stream cleaning)
│ ├── env-filter.js # PTY environment variable filtering
│ ├── access-auth.js # Optional access token authentication
│ └── mcp-process.js # MCP subprocess management
├── public/ # resources (bundle.js esbuild)
├── cli-presets/ # CLI preset configurations
├── workflows/ # Preset workflow orchestration
├── plugins/ # Plugin system
├── tray/ + tray.bat/tray.sh # Desktop tray launcher (offline portable package)
└── node/ # Portable Node.js runtime offline package)
```
## Tech Stack
| Layer | Technology |
|----|------------|
| **Backend** | Node.js |
| **Terminal** | node-pty + xterm.js + WebGL |
| **Communication** | WebSocket ( + SSE |
| **Build** | esbuild |
| **AI** | OpenAI API / Anthropic API |
| **Browser Control** | Playwright + CDP |
| **Storage** | IndexedDB + safeStorage |
| **Code Quality** | ESLint + Prettier + Husky |
| **Testing** | node --test + plans/ regression suite |
| **Documentation** | OpenAPI 3.0 + JSDoc |
| **Speech** | Web Speech API |
| **Charts** | Self-developed Canvas engine (ChartCore) |
## Testing
Regression suite located in `plans/` (pure Node script, no framework):
```bash
node plans/verify-terminal-clean.js # Terminal escape cleaning (9 items)
node plans/test-discuss.js # Discussion coordinator module contract regression (7 items: load/export/shape/async/arity/cache)
node plans/test-stability.js # Stability37 items: tool interruption/rate limiting/stream completion/loop detection)
```
Syntax and structure check:
```bash
npm run check:server # All server-side modules node --check syntax check
npm run lint # ESLint
```
## Scripts
| Command | Description |
|----------|-------------|
| `npm start` | Start production service |
| `npm run dev` | Development mode (`--watch` hot reload) |
| `npm run build` | Build frontend (esbuild compression, output public/bundle.js| `npm run build:dev` | Development build (with sourcemap) |
| `npm run watch` | Frontend listen mode |
| `npm run mcp` | Start MCP service independently |
| `npm run check:server` | Server-side module syntax check |
| `npm run lint` / `npm run format` | ESLint / Prettier |
## Contributing
Contributions welcome! Feature requests, bug reports, and code PRs. Complete guide (including build pitfalls, husky hooks, gh-pages process, bundle dual-track trap) see **[CONTRIBUTING.md](./CONTRIBUTING.md)**.
### Development Process
```bash
git clone <your-fork>
cd Hesi
npm install
npm run dev
npm run build
```
### Code Style
- Backend: CommonJS (`require`/`module.exports`)
- Frontend: ESM (`import`/`export`), packaged by esbuild
- New features please attach regression tests (located in `plans/`)
## Secure Deployment
Hesi is essentially a **local-first** terminal/browser hub: it executes arbitrary commands via WebSocket and controls the browser via CDP. Therefore, the default configuration follows the principle of "minimum exposure" and is secure out of the box.
### About `npm audit` warnings
After `npm install`, `npm audit` may report some vulnerabilities (including a moderate one from `@hono/node-server`). These come from **indirect dependencies of `@modelcontextprotocol/sdk`**, Hesi itself uses the **Express** server, **does not call Hono's `serve-static`**, and the service **only listens to the local loopback**, not exposing it to the public network. Therefore, this path is dead code not called, **has no actual impact on local deployment**, and is a false positive in the supply chain, no need to handle. The rest of the vulnerabilities that can be directly fixed have been upgraded to compatible versions via `npm audit fix` (not `--force`).
### Default Security Posture (Secure Out of the Box)
| Item | Default Behavior |
|----|----------|
| Listen Address | address `127.0.0.1` and `::1` (local only). Set=0.0.0.0` will warning |
| CORS | Only allow same-origin/loopback; cross-domain requires explicit whitelist with `QCLI_CORS_ORIGINS` |
| Access Token | Disabled when `QCLI_ACCESS_TOKEN` is not set; set to require token for all sensitive `/api` and WebSocket (loopback exempt) |
| Command Policy | `blocklist` mode,-in dangerous command blacklist be overridden by `QCLI_POLICY_PATH` |
Limiting | Global API + WebSocket message + upload rate **local loopback exempt by default** |
Isolation | node-pty degrades gracefully if not compiled, PTY functionality |
| Upload Directory | User uploads `uploads/.user/` (hidden, authenticated and |
### Public Network / Multi-Person Deployment Checklist ⚠️ Only expose to non-local network when all conditions are met.
1. ** Token**: `QCLI_ACCESS_TOKEN=<strong-random-token>`, HTTP header `Authorization: Bearer <token>`, WebSocket append `?token=<token>`
2. **Tighten CORS**: `QCLI_CORS_ORIGINS=https://your-frontend.example.com`
3. **Strengthen Command Policy**: Use `QCLI_POLICY_PATH` to point to `blocklist`/`allowlist` policy, or tighten to `allowlist`
4. **MCP Authentication**: `QCLI_MCP_TOKEN` + keep `QCLI_AUDIT_LOG` enabled
5. **Reverse Proxy**: Place Nginx/Caddy in front to enable HTTPS/HSTS, restrict `/api/uploads` origin
6. **Do not run as root**, and update dependencies regularly
### Security Baseline Self-Check
```bash
[ "$HOST" = "0.0.0.0" ] && echo "WARN: HOST=0.0.0.0 exposes all interfaces" || echo "OK: loopback by default"
[ -n "$QCLI_ACCESS_TOKEN" ] && echo "OK: access token set" || echo "WARN: no access token"
```
## License
MIT License — see [LICENSE](./LICENSE) for details.
<p align="center">
<sub>Built with ❤️ by Hesi Contributors</sub>
</p>
## Why Hesi
An open-source platform for running any CLI/terminal in the browser, core values:
- **🌐 Browser Terminal** — `node-pty` + `xterm.js` + WebSocket, native terminal experience, multi-tab independent operation, session persistence, no need for SSH.
- **🤝 AI Agent Collaboration** — Let AI assistants and opencode/codex and other CLI Agents have multi-round "roundtable discussions", and headless execution from the source eliminates TUI pollution🔌 Ecosystem** — Built-in enterprise wechat, Feishu and other, a hub connecting and business system.
- **💾 Offline Portable Comes with a portable Node.js runtime desktop package, double-click `tray.exe use, no cloud.
📖 Open Source MIT license, local can be privatized, capabilities auditable-hosted.
##
> Replace the badges with actual CI/version/download links.
[
[](https:///qiuqiukoss/Hesi/releases](https:///badge/license-blue.svg)](./LICENSE)
[](https://github.com/qiuqiukof-oss/Hesi)
[](https://github.com/qiuqiukof-oss/Hesi/stargazers)
## Demo
- 3 demo: [docs](./docs/demo-script.md) (out of the box → AI roundtable → terminal/browser control → → offline portable).
ready**: Desktop double-click `tray.exe` (Windows) `tray.sh` (macOS/Linux) to start, comes with portable Node, default only bind local loopback, no installation required, no internet connection needed the "Desktop Tray Bundle (Offline Portable Package for details.
## Contributing
Contributions welcome requests, bug reports, documentation, and code PRs are all encouraged. Complete contributor guide (development process, code style, build traps, husky hooks, gh-pages release process) see **[CONTRIBUTING.md](./CONTRIBUTING.md)**.
### Reference Documentation
- Getting started guide for newcomers: [docs/getting-started.md](./docs/getting-started.md)
- Architecture whitepaper: [docs/architecture.md](./docs/architecture- Compliance and-inspection: [COMPLIANCE.mdPLIANCE.md)
- Secure deployment guide:_DEPLOY.md](./SECURE_DEPLOY
MCP Config
Below is the configuration for this MCP Server. You can copy it directly to Cursor or other MCP clients.
mcp.json
Connection Info
You Might Also Like
everything-claude-code
Complete Claude Code configuration collection - agents, skills, hooks,...
markitdown
MarkItDown-MCP is a lightweight server for converting URIs to Markdown.
cc-switch
All-in-One Assistant for Claude Code, Codex & Gemini CLI across platforms.
servers
Model Context Protocol Servers
servers
Model Context Protocol Servers
Time
A Model Context Protocol server for time and timezone conversions.