安卓手机上安装 Hermes Agent(国内网络环境)

发布于 2026-06-08 16:57

安卓手机上安装 Hermes Agent(国内网络环境)

记录在 Termux 上安装 Hermes Agent 时遇到的典型问题及解决方案,适用于国内网络。


1. 安装 Termux

国内 F-Droid 经常访问不了,直接从 GitHub 下载 APK 安装。

https://github.com/termux/termux-app/releases/

选最新的 termux-app_v0.118.x+github-debug_universal.apk

也可以从清华镜像下载旧版 com.termux_118.apk,但推荐用 GitHub 最新版。

https://mirrors.tuna.tsinghua.edu.cn/fdroid/archive/com.termux_118.apk

2. 配置软件源

这是国内用户最常踩的坑,不配好会直接报错。

报错信息

Failed to fetch https://deb.kcubeterm.me/termux-main/dists/stable/InRelease
Clearsigned file isn't valid, got 'NOSPLIT' (does the network require authentication?)
E: The repository 'https://deb.kcubeterm.me/termux-main stable InRelease' is not signed.

原因:deb.kcubeterm.me 这个源已经停止维护,旧版 Termux 默认指向它。

解决方法

方法一(推荐):交互式换源

termux-change-repo
  1. 用空格勾选 Main repository,按回车确认
  2. 在镜像列表里选 Tsinghua University(清华源)

方法二:手动替换源地址

sed -i 's|deb.kcubeterm.me/termux-main|packages.termux.dev/apt/termux-main|g' $PREFIX/etc/apt/sources.list

3. 更新环境并安装依赖

pkg update && pkg upgrade -y
pkg install -y curl

4. 安装 Hermes Agent

curl -fsSL https://raw.githubusercontent.com/NousResearch/hermes-agent/main/scripts/install.sh | bash
source ~/.bashrc
hermes --version

5. 常见问题

pip 安装 jiter 时卡住不动

现象:安装过程停在 Collecting jiter<1,>=0.10.0 处,长时间没有反应。

原因:jiter 是用 Rust 写的 Python 库,Termux 上没有预编译包,pip 在从源码编译。手机 CPU 编译 Rust 很慢,看起来像卡死,实际后台在跑。

解决:耐心等 5 到 10 分钟,一般能编译完。超过 15 分钟没动静再考虑中断换方案。

GitHub 访问慢或失败

如果 curl 拉安装脚本时连不上 GitHub,可以:

  • 用代理工具
  • 或者在电脑上下载脚本,通过局域网传到手机

如果你觉得本文有用,请点赞,收藏,转发


← 返回博客列表