openfang

RightNow-AIApache-2.0更新放缓

用 Rust 写的开源 Agent 操作系统,为 AI Agent 提供统一的运行与编排环境,支持 MCP 协议和 LLM 接入。

Open-source Agent Operating System

v0.6.9发布于 2026-05-12 18:42 UTC18,243star +1 / 7 天2,281fork同步于 2026-11-10 05:23 UTC

怎么上手

由 README 提炼,执行前请确认
curl -fsSL https://openfang.sh/install | sh
openfang init
openfang start
硬件要求按 README 说明

README 未说明显存或 GPU 要求;提供约 32MB 单二进制,空闲内存约 40MB,支持 Ollama、vLLM、LM Studio 等本地推理后端。

有 Docker 镜像
下载:源码 zip·GitHub Releases(安装包)本站不镜像安装包

项目说明

由 README 自动翻译提炼

用 Rust 编写的开源 Agent 操作系统,让自主智能体按计划 24/7 替你干活

用 Rust 写的开源 Agent 操作系统,为 AI Agent 提供统一的运行与编排环境,支持 MCP 协议和 LLM 接入。

核心能力

  • 内置 7 个 Hands 自主能力包,按计划独立运行无需提示
  • 单个约 32MB 二进制,一条命令完成安装与启动
  • 支持 27 家 LLM 供应商、123+ 模型,含智能路由与自动回退
  • 提供 OpenAI 兼容 API,可直接替换现有工具接入
  • 一条命令从 OpenClaw 迁移智能体、记忆与配置

容易踩的坑

仍处于 pre-1.0,小版本间可能有破坏性变更,生产环境建议固定到具体 commit;WhatsApp 网页模式需先进入 packages/whatsapp-gateway 执行 npm install 并单独启动网关,默认端口 3009;Dashboard 默认监听 http://localhost:4200。

内容由模型根据 README 生成,可能不完整或不准确,以官方文档为准。看原文 README

最近发版

5 个版本v0.6.9
  1. v0.6.9v0.6.9 — security patches最新正式版2026-05-12 · 2026-05-12 18:42 UTC

    Security patches (RUSTSEC advisories that broke v0.6.8 CI):

    • rustls-webpki 0.103.10 → 0.103.13:
      • RUSTSEC-2026-0104 — reachable panic in CRL parsing
      • RUSTSEC-2026-0098 — name constraints for URI names incorrectly accepted
      • RUSTSEC-2026-0099 — wildcard name constraints accepted incorrectly
    • wasmtime 43.0.1 → 43.0.2:
      • RUSTSEC-2026-0114 — panic allocating a table exceeding host address space

    Maintenance:

    • cargo fmt applied workspace-wide (CI Format gate green)

    All v0.6.8 fixes carried forward:

    • #1097 workspace state_dir split
    • #1085 dashboard WS auth aligned with HTTP middleware
    • #1038 skill_list / skill_describe / skill_execute agent tools
    • #995 Requesty provider added
    • #1154 OLLAMA_HOST / LMSTUDIO_HOST env override
    • #1170 require_signed wired through POST /api/skills/install
    • #1174 POST /api/audit/append endpoint
    • #1172 HAND.toml SHA-256 to Merkle audit chain
    • #780 Telegram message_thread_id routing
    • Codex installer findings: CRLF/BOM, package.json, symlink, TOCTOU all closed
  2. v0.6.82026-05-12 · 2026-05-12 17:44 UTC
    查看更新说明

    Fixes:

    • #1097 workspace state_dir split — private state stays under ~/.openfang/, user workspace untouched
    • #1085 dashboard WS auth aligned with HTTP middleware
    • #1038 skill_list / skill_describe / skill_execute agent tools (replaces filesystem fallback)
    • #1170 require_signed wired through POST /api/skills/install with allowed_signer_keys allow-list
    • #1174 POST /api/audit/append endpoint for instance-side wrapper audit integration
    • #1172 HAND.toml SHA-256 auto-logged to Merkle audit chain on every load
    • #780 Telegram message_thread_id routing per-topic to named agents
    • Codex audit findings on installer.rs binding check closed:
      • CRLF and UTF-8 BOM normalization on both sides of compare
      • package.json added to manifest candidate list
      • symlink and canonicalization escape protection
      • TOCTOU closed via private staging dir plus atomic rename

    Providers:

    • #995 Requesty added (https://router.requesty.ai/v1) with 5 catalog entries
    • #1154 OLLAMA_HOST / LMSTUDIO_HOST / VLLM_HOST / LEMONADE_HOST env override for local providers

    PR dispositions:

    • closed: #1185, #1166, #1162, #1055, #1044, #1039, #969
    • held pending external rebase: #1151, #997, #1093, #946 (all reviewed clean)
    • author rework requested: #943 (IDOR on session endpoints)

    Tests: 2696+ across 14 crates, 0 clippy warnings.

  3. v0.6.7v0.6.7: Reconnect, Uninstall, Stop, Shell Env, TTS URLs2026-05-12 · 2026-05-12 12:45 UTC
    查看更新说明

    Resolves 7 community issues. 2657 tests passing, zero clippy warnings, zero regressions.

    Web Dashboard

    • #1179 WebSocket reconnects to the active agent after page refresh. localStorage persists the agent id, init restores it, history hydrates from /api/agents/{id}/session.
    • #1163 Uninstall an agent from chat. New DELETE /api/agents/{id}/uninstall removes the in-memory entry plus the ~/.openfang/agents/<name>/ directory. Red Uninstall button next to Stop in both the chat header and the agent detail modal. Path-traversal rejected.

    Kernel

    • #1164 Agent Stop now deactivates the owning hand. Hand-owned agents no longer hit "Hand already active" on re-activation. WS /stop command mirrors the same path.

    Runtime

    • #1169 shell_exec env passthrough. New exec_policy.shell_env_passthrough Vec with aliases env_passthrough and env_allowlist. Wildcard "*" forwards every parent env var. Tested across the merge helper and 10 deser cases.
    • #1051 TTS and image generation base URLs configurable. media.tts_openai_base_url, media.tts_elevenlabs_base_url, media.image_gen_base_url. Same pattern as audio_base_url from v0.6.4. Local OpenAI-compat services for Whisper, TTS, and DALL-E flavors all swappable now. 8 new tests.

    Skills

    • #1170 Backend InstallOptions::require_signed enforces Ed25519 signature verification at install time. Allowed-signer pubkey allowlist supported. CLI wiring pending follow-up.

    Docs

    • #1173 Docker host-gateway and curl-equipped reference image documented in troubleshooting.md and getting-started.md. docker-compose.yml has a commented extra_hosts: baseline.

    PR review activity

    • 4 PRs merged in round 7-8 (#1147 channel_id binding, #1143 Discord images, #1176 Shift+Enter, #1168 LaTeX render).
    • 8 PRs closed as abandoned or unfit (#1115, #1116, #1117, #1066, #1057, #1030, #1050, #1056, #1046).
    • #1055 caught smuggling an X-Frame-Options regression in a metering-named PR. Request-changes posted.

    Stats

    • 2657 tests passing (+32 from v0.6.6)
    • Zero clippy warnings (--workspace --all-targets)
    • Zero regressions

    Full Changelog: https://github.com/RightNow-AI/openfang/compare/v0.6.6...v0.6.7

  4. v0.6.6v0.6.6: Discord Images, vLLM 0.19, create_directory, Bindings2026-05-12 · 2026-05-12 12:27 UTC
    查看更新说明

    Resolves 11 community issues and 7 PRs merged across drivers, channels, and dashboard. 2625 tests passing, zero clippy warnings, zero regressions.

    LLM Drivers

    • #1157 vLLM 0.19+ reasoning field support. The driver now reads both reasoning (new) and reasoning_content (legacy) and emits both on the wire, keeping agentic loops working across vLLM upgrades and other OpenAI-compatible servers.

    Channels

    • #1142 PR #1143 Discord image attachments surface to text-only providers as a caption + image multipart, so models without vision still get the caption text instead of seeing the image silently dropped.
    • #1144 PR #1147 channel_id binding hardening. Single source of truth for routing, adapter allowlist, deny_unknown_fields on AgentBinding and BindingMatchRule. 14 new tests.
    • #1141 PR #1176 Shift+Enter inserts a newline in the chat input. Plain Enter still sends.

    Tools

    • #1134 New create_directory tool. Routes through workspace sandbox with path traversal protection. 13 aliases (mkdir, make_directory, create_folder, etc.) wired in tool_compat.

    Web Dashboard

    • #1167 PR #1168 LaTeX math now renders in chat messages via the lazy-loaded KaTeX bundle. CSP updated for jsdelivr.
    • #1140 Chat tab now lists agents from ~/.openfang/agents/. Boot scans the directory after DB restore and registers any agent.toml the DB didn't know about. Bad TOML logged and skipped, never aborts boot.

    Investigations and Design

    • #1097 Workspaces unintended behavior documented (multi-component refactor scope, design comment posted).
    • #1149 OpenAI Responses API migration design-only (affects 26 providers, separate driver gated by flag recommended).

    Quick closes

    • #1048 MiniMax setup answered.
    • #1152 Update command pointed to openfang.sh/update.
    • #1153 Chinese localization dedupe to #1186.
    • #1155 0.0.0.0 bind documented in v0.6.5, comment added.
    • #1156 Agent-as-tool already supported via agent_send.
    • #1159 Server install pointed to docs.
    • #1161 Website restored.

    Stats

    • 2625 tests passing (+40 from v0.6.5)
    • Zero clippy warnings (--workspace --all-targets)
    • Zero regressions

    Full Changelog: https://github.com/RightNow-AI/openfang/compare/v0.6.5...v0.6.6

  5. v0.6.5v0.6.5: Agent Wakeup, Server IDs, cloneAgent2026-05-12 · 2026-05-12 12:06 UTC
    查看更新说明

    Resolves 8 community issues + 3 PRs merged from trusted contributors. 2585 tests passing, zero clippy warnings, zero regressions.

    Agents

    • #890 New agent_activate tool and POST /api/agents/{id}/activate endpoint. Orchestrator agents can wake suspended or crashed peers. Idempotent on Running, rejects Terminated.
    • #868 cloneAgent API. POST /api/agents/{template_id}/clone deep-clones a template, applies overrides, assigns a fresh agent ID and workspace path. Excludes MEMORY.md so the new agent starts fresh.
    • #869 Server-assigned message IDs. Every Message now carries a UUID v4 msg_id stamped at construction, plus an optional provider_msg_id for debugging. Legacy on-disk sessions get fresh IDs on first load.

    Web Dashboard

    • #1026 Inferencing indicator. Live pulse next to agents currently calling the LLM. Computed from running_tasks DashMap.
    • #931 Providers screen overhauled. Search, filter by status, group by category (frontier / oss / aggregator / regional / local), configured providers first.
    • #915 Telegram user_id surfaced. metadata.telegram_user_id and prompt prefix [From: Name (tg_id:NNN)] give agents a stable per-user identifier.

    Channels

    • #1146 Lenient binding parse. One malformed binding entry no longer drops the entire bindings table. Bad entries are logged at ERROR and dropped, survivors pass through.

    Docs

    • #1097 Workspaces gap documented (multi-component refactor needed, design comment posted).
    • #1037 follow-up. docs/configuration.md auth posture wording corrected. Middleware fail-closes on authenticated routes but a small set of public routes (health, static, OAuth callback) remain reachable so the login page can render. OPENFANG_ALLOW_NO_AUTH opt-in still required for open access.
    • #1175 Getting-started doc links fixed.

    Dependencies

    • open 5.3.3 to 5.3.4

    Stats

    • 2585 tests passing (+42 from v0.6.4)
    • Zero clippy warnings (--workspace --all-targets)
    • Zero regressions

    Full Changelog: https://github.com/RightNow-AI/openfang/compare/v0.6.4...v0.6.5

用户点评

登录用户的真实使用记录,可按版本和硬件筛选
共 0 条

    还没有人点评。第一个说出真实体验的人最有价值。

    README 原文

    未翻译

    v0.5.10 (April 2026)

    OpenFang is feature complete but still pre-1.0. Expect rough edges and breaking changes between minor versions. We ship fast and fix fast. Pin to a specific commit for production use until v1.0. Report issues here.


    What is OpenFang?

    OpenFang is an open-source Agent Operating System. Not a chatbot framework. Not a Python wrapper around an LLM. Not a "multi-agent orchestrator." A full operating system for autonomous agents, built from scratch in Rust.

    Traditional agent frameworks wait for you to type something. OpenFang runs autonomous agents that work for you: on schedules, 24/7, building knowledge graphs, monitoring targets, generating leads, managing your social media, and reporting results to your dashboard.

    The entire system compiles to a single ~32MB binary. One install, one command, your agents are live.

    curl -fsSL https://openfang.sh/install | sh
    openfang init
    openfang start
    # Dashboard live at http://localhost:4200
    
    irm https://openfang.sh/install.ps1 | iex
    openfang init
    openfang start
    

    Hands: Agents That Actually Do Things

    Hands are OpenFang's core innovation. Pre-built autonomous capability packages that run independently, on schedules, without you having to prompt them. This is not a chatbot. This is an agent that wakes up at 6 AM, researches your competitors, builds a knowledge graph, scores the findings, and delivers a report to your Telegram before you've had coffee.

    Each Hand bundles:

    • HAND.toml: manifest declaring tools, settings, requirements, and dashboard metrics.
    • System Prompt: multi-phase operational playbook. Not a one-liner. These are 500+ word expert procedures.
    • SKILL.md: domain expertise reference injected into context at runtime.
    • Guardrails: approval gates for sensitive actions (e.g. Browser Hand requires approval before any purchase).

    All compiled into the binary. No downloading, no pip install, no Docker pull.

    The 7 Bundled Hands

    HandWhat It Actually Does
    ClipTakes a YouTube URL, downloads it, identifies the best moments, cuts them into vertical shorts with captions and thumbnails, optionally adds AI voice-over, and publishes to Telegram and WhatsApp. 8-phase pipeline. FFmpeg + yt-dlp + 5 STT backends.
    LeadRuns daily. Discovers prospects matching your ICP, enriches them with web research, scores 0-100, deduplicates against your existing database, and delivers qualified leads in CSV/JSON/Markdown. Builds ICP profiles over time.
    CollectorOSINT grade intelligence. You give it a target (company, person, topic). It monitors continuously: change detection, sentiment tracking, knowledge graph construction, and critical alerts when something important shifts.
    PredictorSuperforecasting engine. Collects signals from multiple sources, builds calibrated reasoning chains, makes predictions with confidence intervals, and tracks its own accuracy using Brier scores. Has a contrarian mode that deliberately argues against consensus.
    ResearcherDeep autonomous researcher. Cross-references multiple sources, evaluates credibility using CRAAP criteria (Currency, Relevance, Authority, Accuracy, Purpose), generates cited reports with APA formatting, supports multiple languages.
    TwitterAutonomous Twitter/X account manager. Creates content in 7 rotating formats, schedules posts for optimal engagement, responds to mentions, tracks performance metrics. Has an approval queue, so nothing posts without your OK.
    BrowserWeb automation agent. Navigates sites, fills forms, clicks buttons, handles multi-step workflows. Uses Playwright bridge with session persistence. Mandatory purchase approval gate: it will never spend your money without explicit confirmation.
    # Activate the Researcher Hand. It starts working immediately.
    openfang hand activate researcher
    
    # Check its progress anytime
    openfang hand status researcher
    
    # Activate lead generation on a daily schedule
    openfang hand activate lead
    
    # Pause without losing state
    openfang hand pause lead
    
    # See all available Hands
    openfang hand list
    

    Build your own. Define a HAND.toml with tools, settings, and a system prompt. Publish to FangHub.


    OpenFang vs The Landscape

    Benchmarks: Measured, Not Marketed

    All data from official documentation and public repositories, February 2026.

    Cold Start Time (lower is better)
    ZeroClaw   ██░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░   10 ms
    OpenFang   ██████░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░  180 ms    ★
    LangGraph  █████████████████░░░░░░░░░░░░░░░░░░░░░░░░░  2.5 sec
    CrewAI     ████████████████████░░░░░░░░░░░░░░░░░░░░░░  3.0 sec
    AutoGen    ██████████████████████████░░░░░░░░░░░░░░░░░  4.0 sec
    OpenClaw   █████████████████████████████████████████░░  5.98 sec
    
    Idle Memory Usage (lower is better)
    ZeroClaw   █░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░    5 MB
    OpenFang   ████░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░   40 MB    ★
    LangGraph  ██████████████████░░░░░░░░░░░░░░░░░░░░░░░░░  180 MB
    CrewAI     ████████████████████░░░░░░░░░░░░░░░░░░░░░░░  200 MB
    AutoGen    █████████████████████████░░░░░░░░░░░░░░░░░░  250 MB
    OpenClaw   ████████████████████████████████████████░░░░  394 MB
    
    Install Size (lower is better)
    ZeroClaw   █░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░  8.8 MB
    OpenFang   ███░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░   32 MB    ★
    CrewAI     ████████░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░  100 MB
    LangGraph  ████████████░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░  150 MB
    AutoGen    ████████████████░░░░░░░░░░░░░░░░░░░░░░░░░░░  200 MB
    OpenClaw   ████████████████████████████████████████░░░░  500 MB
    
    Security Systems (higher is better)
    OpenFang   ████████████████████████████████████████████   16      ★
    ZeroClaw   ███████████████░░░░░░░░░░░░░░░░░░░░░░░░░░░░    6
    OpenClaw   ████████░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░    3
    AutoGen    █████░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░    2
    LangGraph  █████░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░    2
    CrewAI     ███░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░    1
    
    Channel Adapters (higher is better)
    OpenFang   ████████████████████████████████████████████   40      ★
    ZeroClaw   ███████████████░░░░░░░░░░░░░░░░░░░░░░░░░░░░   15
    OpenClaw   █████████████░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░   13
    CrewAI     ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░    0
    AutoGen    ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░    0
    LangGraph  ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░    0
    
    LLM Providers (higher is better)
    ZeroClaw   ████████████████████████████████████████████   28
    OpenFang   ██████████████████████████████████████████░░   27      ★
    LangGraph  ██████████████████████░░░░░░░░░░░░░░░░░░░░░   15
    CrewAI     ██████████████░░░░░░░░░░░░░░░░░░░░░░░░░░░░░   10
    OpenClaw   ██████████████░░░░░░░░░░░░░░░░░░░░░░░░░░░░░   10
    AutoGen    ███████████░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░    8
    

    Feature-by-Feature Comparison

    FeatureOpenFangOpenClawZeroClawCrewAIAutoGenLangGraph
    LanguageRustTypeScriptRustPythonPythonPython
    Autonomous Hands7 built-inNoneNoneNoneNoneNone
    Security Layers16 discrete3 basic6 layers1 basicDockerAES enc.
    Agent SandboxWASM dual-meteredNoneAllowlistsNoneDockerNone
    Channel Adapters401315000
    Built-in Tools53 + MCP + A2A50+12PluginsMCPLC tools
    MemorySQLite + vectorFile-basedSQLite FTS54-layerExternalCheckpoints
    Desktop AppTauri 2.0NoneNoneNoneStudioNone
    Audit TrailMerkle hash-chainLogsLogsTracingLogsCheckpoints
    Cold Start<200ms~6s~10ms~3s~4s~2.5s
    Install Size~32 MB~500 MB~8.8 MB~100 MB~200 MB~150 MB
    LicenseMITMITMITMITApache 2.0MIT

    16 Security Systems: Defense in Depth

    OpenFang doesn't bolt security on after the fact. Every layer is independently testable and operates without a single point of failure.

    #SystemWhat It Does
    1WASM Dual-Metered SandboxTool code runs in WebAssembly with fuel metering + epoch interruption. A watchdog thread kills runaway code.
    2Merkle Hash-Chain Audit TrailEvery action is cryptographically linked to the previous one. Tamper with one entry and the entire chain breaks.
    3Information Flow Taint TrackingLabels propagate through execution. Secrets are tracked from source to sink.
    4Ed25519 Signed Agent ManifestsEvery agent identity and capability set is cryptographically signed.
    5SSRF ProtectionBlocks private IPs, cloud metadata endpoints, and DNS rebinding attacks.
    6Secret ZeroizationZeroizing<String> auto-wipes API keys from memory the instant they're no longer needed.
    7OFP Mutual AuthenticationHMAC-SHA256 nonce-based, constant-time verification for P2P networking.
    8Capability GatesRole based access control. Agents declare required tools, the kernel enforces it.
    9Security HeadersCSP, X-Frame-Options, HSTS, X-Content-Type-Options on every response.
    10Health Endpoint RedactionPublic health check returns minimal info. Full diagnostics require authentication.
    11Subprocess Sandboxenv_clear() + selective variable passthrough. Process tree isolation with cross-platform kill.
    12Prompt Injection ScannerDetects override attempts, data exfiltration patterns, and shell reference injection in skills.
    13Loop GuardSHA256-based tool call loop detection with circuit breaker. Handles ping-pong patterns.
    14Session Repair7-phase message history validation and automatic recovery from corruption.
    15Path Traversal PreventionCanonicalization with symlink escape prevention. ../ doesn't work here.
    16GCRA Rate LimiterCost-aware token bucket rate limiting with per-IP tracking and stale cleanup.

    Architecture

    14 Rust crates. 137,728 lines of code. Modular kernel design.

    openfang-kernel      Orchestration, workflows, metering, RBAC, scheduler, budget tracking
    openfang-runtime     Agent loop, 3 LLM drivers, 53 tools, WASM sandbox, MCP, A2A
    openfang-api         140+ REST/WS/SSE endpoints, OpenAI-compatible API, dashboard
    openfang-channels    40 messaging adapters with rate limiting, DM/group policies
    openfang-memory      SQLite persistence, vector embeddings, canonical sessions, compaction
    openfang-types       Core types, taint tracking, Ed25519 manifest signing, model catalog
    openfang-skills      60 bundled skills, SKILL.md parser, FangHub marketplace
    openfang-hands       7 autonomous Hands, HAND.toml parser, lifecycle management
    openfang-extensions  25 MCP templates, AES-256-GCM credential vault, OAuth2 PKCE
    openfang-wire        OFP P2P protocol with HMAC-SHA256 mutual authentication
    openfang-cli         CLI with daemon management, TUI dashboard, MCP server mode
    openfang-desktop     Tauri 2.0 native app (system tray, notifications, global shortcuts)
    openfang-migrate     OpenClaw, LangChain, AutoGPT migration engine
    xtask                Build automation
    

    40 Channel Adapters

    Connect your agents to every platform your users are on.

    Core: Telegram, Discord, Slack, WhatsApp, Signal, Matrix, Email (IMAP/SMTP) Enterprise: Microsoft Teams, Mattermost, Google Chat, Webex, Feishu/Lark, Zulip Social: LINE, Viber, Facebook Messenger, Mastodon, Bluesky, Reddit, LinkedIn, Twitch Community: IRC, XMPP, Guilded, Revolt, Keybase, Discourse, Gitter Privacy: Threema, Nostr, Mumble, Nextcloud Talk, Rocket.Chat, Ntfy, Gotify Workplace: Pumble, Flock, Twist, DingTalk, Zalo, Webhooks

    Each adapter supports per-channel model overrides, DM/group policies, rate limiting, and output formatting.


    WhatsApp Web Gateway (QR Code)

    Connect your personal WhatsApp account to OpenFang via QR code, just like WhatsApp Web. No Meta Business account required.

    Prerequisites

    • Node.js >= 18 installed (download)
    • OpenFang installed and initialized

    Setup

    1. Install the gateway dependencies:

    cd packages/whatsapp-gateway
    npm install
    

    2. Configure config.toml:

    [channels.whatsapp]
    mode = "web"
    default_agent = "assistant"
    

    3. Set the gateway URL (choose one):

    Add to your shell profile for persistence:

    # macOS / Linux
    echo 'export WHATSAPP_WEB_GATEWAY_URL="http://127.0.0.1:3009"' >> ~/.zshrc
    source ~/.zshrc
    

    Or set it inline when starting the gateway:

    export WHATSAPP_WEB_GATEWAY_URL="http://127.0.0.1:3009"
    

    4. Start the gateway:

    node packages/whatsapp-gateway/index.js
    

    The gateway listens on port 3009 by default. Override with WHATSAPP_GATEWAY_PORT.

    5. Start OpenFang:

    openfang start
    # Dashboard at http://localhost:4200
    

    6. Scan the QR code:

    Open the dashboard → Channels → WhatsApp. A QR code will appear. Scan it with your phone:

    WhatsApp → Settings → Linked Devices → Link a Device

    Once scanned, the status changes to connected and incoming messages are routed to your configured agent.

    Gateway Environment Variables

    VariableDescriptionDefault
    WHATSAPP_WEB_GATEWAY_URLGateway URL for OpenFang to connect to(empty = disabled)
    WHATSAPP_GATEWAY_PORTPort the gateway listens on3009
    OPENFANG_URLOpenFang API URL the gateway reports tohttp://127.0.0.1:4200
    OPENFANG_DEFAULT_AGENTAgent that handles incoming messagesassistant

    Gateway API Endpoints

    MethodRouteDescription
    POST/login/startGenerate QR code (returns base64 PNG)
    GET/login/statusConnection status (disconnected, qr_ready, connected)
    POST/message/sendSend a message ({ "to": "5511999999999", "text": "Hello" })
    GET/healthHealth check

    Alternative: WhatsApp Cloud API

    For production workloads, use the WhatsApp Cloud API with a Meta Business account. See the Cloud API configuration docs.


    27 LLM Providers, 123+ Models

    3 native drivers (Anthropic, Gemini, OpenAI-compatible) route to 27 providers:

    Anthropic, Gemini, OpenAI, Groq, DeepSeek, OpenRouter, Together, Mistral, Fireworks, Cohere, Perplexity, xAI, AI21, Cerebras, SambaNova, HuggingFace, Replicate, Ollama, vLLM, LM Studio, Qwen, MiniMax, Zhipu, Moonshot, Qianfan, Bedrock, and more.

    Intelligent routing with task complexity scoring, automatic fallback, cost tracking, and per-model pricing.


    Migrate from OpenClaw

    Already running OpenClaw? One command:

    # Migrate everything: agents, memory, skills, configs.
    openfang migrate --from openclaw
    
    # Migrate from a specific path
    openfang migrate --from openclaw --path ~/.openclaw
    
    # Dry run first to see what would change
    openfang migrate --from openclaw --dry-run
    

    The migration engine imports your agents, conversation history, skills, and configuration. OpenFang reads SKILL.md natively and is compatible with the ClawHub marketplace.


    OpenAI-Compatible API

    Drop-in replacement. Point your existing tools at OpenFang:

    curl -X POST localhost:4200/v1/chat/completions \
      -H "Content-Type: application/json" \
      -d '{
        "model": "researcher",
        "messages": [{"role": "user", "content": "Analyze Q4 market trends"}],
        "stream": true
      }'
    

    140+ REST/WS/SSE endpoints covering agents, memory, workflows, channels, models, skills, A2A, Hands, and more.


    Quick Start

    # 1. Install (macOS/Linux)
    curl -fsSL https://openfang.sh/install | sh
    
    # 2. Initialize. Walks you through provider setup.
    openfang init
    
    # 3. Start the daemon
    openfang start
    
    # 4. Dashboard is live at http://localhost:4200
    
    # 5. Activate a Hand. It starts working for you.
    openfang hand activate researcher
    
    # 6. Chat with an agent
    openfang chat researcher
    > "What are the emerging trends in AI agent frameworks?"
    
    # 7. Spawn a pre-built agent
    openfang agent spawn coder
    
    irm https://openfang.sh/install.ps1 | iex
    openfang init
    openfang start
    

    Development

    # Build the workspace
    cargo build --workspace --lib
    
    # Run all tests (1,767+)
    cargo test --workspace
    
    # Lint (must be 0 warnings)
    cargo clippy --workspace --all-targets -- -D warnings
    
    # Format
    cargo fmt --all -- --check
    

    Stability Notice

    OpenFang v0.5.10 is pre-1.0. The architecture is solid, the test suite is comprehensive, and the security model is deep. That said:

    • Breaking changes may occur between minor versions until v1.0.
    • Some Hands are more mature than others. Browser and Researcher are the most battle tested.
    • Edge cases exist. If you find one, open an issue.
    • Pin to a specific commit for production deployments until v1.0.

    We ship fast and fix fast. The goal is a rock solid v1.0 by mid 2026.


    Security

    To report a security vulnerability, email [email protected]. We take all reports seriously and will respond within 48 hours.


    License

    MIT. Use it however you want.


    Links


    Built by RightNow