HKUDS/nanobot
A self-hosted Python gateway for personal AI across web, terminal and chat.
Automated SPDX check for reference only — not legal advice. Disclaimer
GitHub Star History
Full-history star trajectory from GitHub official history. Switch ranges or hover any point for exact counts.
Evidence-Backed Technical Brief
AI Deep ReviewArchitecture & Core Mechanics
Nanobot is a self-hosted agent application built around a single Python gateway. The bundled WebUI, native TUI and chat integrations use the gateway to manage sessions and call configured model providers and tools. The same gateway handles memory, automations and security policy. Since v0.4.0, it stores model history and browser transcripts in SQLite, with support for importing existing conversations.
The nanobot-ai package requires Python 3.11+ and declares Typer, Pydantic, pydantic-settings, the Anthropic SDK and websockets. The packaged interfaces do not need a separate frontend build. MCP servers, Agent Plugins and CLI Apps extend the workbench and can be attached to topics; the Python SDK is a separate integration path for embedding nanobot in another application.
Key Capabilities & Differentiators
Nanobot can use cloud APIs such as OpenRouter, Anthropic and OpenAI, OAuth subscriptions such as OpenAI Codex and GitHub Copilot, or model servers such as Ollama, vLLM and LM Studio. More than 15 chat integrations include Telegram, Discord, Slack, Feishu and Email. The agent can read images, PDFs and Office files (.docx, .xlsx, .pptx), and edit files within the access granted to the topic.
The browser workbench can group up to four topics in resizable panes, fork a conversation from an earlier reply and reference another topic with @. Tool activity, inline diffs and context usage are inspectable in the UI. Dream provides long-term memory; temporary chats stay outside saved history and memory. Scheduled jobs, local triggers and sustained goals cover recurring work beyond interactive chat.
Trade-offs & Limitations
A chat-only model UI is simpler when all you need is conversation; a single-platform bot is simpler when one channel is enough. Nanobot trades that simplicity for a shared workbench with file access, tool integrations, memory and scheduling. Centralizing those functions also concentrates access: start with a Restricted workspace, limit who can talk to the agent on each channel, and review what an MCP server, plugin or scheduled task can access before enabling it.
A cloud endpoint shifts inference hardware off the gateway host but introduces provider charges, network dependence and external data handling. A local endpoint gives you more control but moves inference capacity and maintenance onto infrastructure you operate. The package metadata still classifies the project as Alpha; test upgrades against your chosen providers, channels and persistent state. MIT licensing permits commercial use, but connected models and services may have separate terms.
Hardware & Deployment Guide
For a packaged install, use uv tool install nanobot-ai and launch nanobot webui; configure a model preset before sending a test message. For terminal-only setup, use nanobot onboard --wizard. On a server, Compose runs gateway and mounts ~/.nanobot at /home/nanobot/.nanobot. It binds port 18790 to loopback but publishes 8765 without a loopback-only host binding. Review that exposure and configure authentication before allowing network access. An alternative is nanobot webui --no-open with port 8765 forwarded over SSH.
A self-hosted gateway still needs a supported model endpoint; put inference on a local server if you want to avoid a cloud model API. Review chat and tool connections separately if offline operation is required. v0.4.0 introduced SQLite persistence, v0.4.1 addressed TLS certificate verification, sandboxed shell execution and workspace permissions, and v0.4.2 expanded SSH support. SSH quick pairing remains Linux-only, and gateway-native TLS and trustedProxyAuth are not supported over SSH.
Individuals or small teams that want a self-hosted personal agent for file work, tool calls and recurring tasks across browser, terminal and chat, with a choice of model providers.
You only need a chat interface, want a managed service that takes care of updates and integrations, or require verified offline operation and cannot vet every configured dependency and connection.
Quick Start & Installation
curl -fsSL https://raw.githubusercontent.com/HKUDS/nanobot/main/scripts/install.sh | sh
Comparison vs. Top Agents & Frameworks Alternatives
Full comparison →| Repository | Stars | 7d Trend | Stack | License | Core Positioning |
|---|---|---|---|---|---|
| nanobot ★ | 50.5k | +157 | Python | MIT | A self-hosted Python gateway for personal AI across web, terminal and chat. |
| AstrBot | 47.9k | +298 | Python | AGPL-3.0 | A self-hosted Python agent hub that connects chat platforms to model providers |
| QwenPaw | 38.5k | +246 | Python | Apache-2.0 | Self-hosted agent workspace for scheduled tasks and chat across apps |
| CowAgent | 48.2k | +116 | Python | MIT | Self-hosted agent harness for running and remembering work across chat channels |
AI Context Briefing (for Claude / Cursor / Windsurf)
Standardized architecture summary & quickstart commands ready to paste into coding agents.
curl -sL https://repoforai.com/repo/HKUDS/nanobot.md
Active README embeds unlock Hot-Tier 6h Telemetry Refresh automatically (zero pay-to-rank).
Frequently Asked Questions about nanobot
How do clients and extensions connect to nanobot?
Does nanobot need a GPU, and how should I size the host?
Can we use it commercially, and does self-hosting keep data on-premises?
When is nanobot a better fit than a model chat UI or a single-platform bot?
Upstream README & Documentation
This profile focuses on independent engineering analysis and live telemetry. Read the full upstream README, changelog, and examples directly on GitHub.
Top 10 Breakout Open-Source AI Repos, Every Thursday
Signal-only digest of fast-growing AI repos, SPDX license alerts, and architecture picks. Zero spam.
Zero spam · 1-click unsubscribe · Privacy Policy