honcho-cli

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

Honcho CLI

Honcho CLI

honcho
wraps the Honcho Python SDK with agent-friendly defaults: JSON output, structured errors, input validation. Use it to inspect workspace state, debug peer memory, and diagnose the dialectic.
honcho
基于Honcho Python SDK封装了对Agent友好的默认配置:JSON输出、结构化错误、输入验证。可用于检查工作区状态、调试peer内存和诊断辩证逻辑。

Output & config

输出与配置

  • TTY: human-readable tables (default when interactive)
  • Piped /
    --json
    : JSON — collection commands emit arrays, single-resource commands emit objects
  • Exit codes:
    0
    success ·
    1
    client error (bad input, not found) ·
    2
    server error ·
    3
    auth error
  • Config:
    ~/.honcho/config.json
    (shared with other Honcho tools). The CLI owns
    apiKey
    and
    environmentUrl
    at the top level; run
    honcho init
    to confirm or set them. Per-command scope (workspace / peer / session) is via
    -w
    /
    -p
    /
    -s
    flags or
    HONCHO_*
    env vars.
  • TTY:人类可读的表格(交互模式下默认)
  • 管道输出 /
    --json
    :JSON格式——集合类命令返回数组,单资源命令返回对象
  • 退出码
    0
    成功 ·
    1
    客户端错误(输入无效、未找到资源) ·
    2
    服务端错误 ·
    3
    认证错误
  • 配置
    ~/.honcho/config.json
    (与其他Honcho工具共享)。CLI使用顶层的
    apiKey
    environmentUrl
    ;运行
    honcho init
    可确认或设置这些参数。每个命令的作用域(工作区/peer/会话)可通过
    -w
    /
    -p
    /
    -s
    标志或
    HONCHO_*
    环境变量指定。

Command groups

命令组

  • honcho config
    — CLI configuration
  • honcho workspace
    — inspect, delete, search
  • honcho peer
    — inspect, card, chat, search
  • honcho session
    — inspect, messages, context, summaries
  • honcho message
    — list and get
  • honcho conclusion
    — list, search, create, delete
  • honcho config
    — CLI配置
  • honcho workspace
    — 检查、删除、搜索
  • honcho peer
    — 检查、查看卡片、聊天、搜索
  • honcho session
    — 检查、查看消息、上下文、摘要
  • honcho message
    — 列出和获取消息
  • honcho conclusion
    — 列出、搜索、创建、删除

Rules

规则

  • Always pass
    --json
    when processing output programmatically.
  • Run
    honcho peer inspect
    before
    honcho peer chat
    to understand context.
  • Use
    honcho session context
    to see exactly what an agent receives.
  • Never run
    honcho workspace delete
    without
    honcho workspace inspect
    first.
  • Check queue status when derivation seems stalled.
  • Compare peer card with conclusions to understand memory state.
  • 程序化处理输出时,务必传递
    --json
    参数。
  • 在运行
    honcho peer chat
    之前,先运行
    honcho peer inspect
    以了解上下文。
  • 使用
    honcho session context
    查看Agent接收的完整内容。
  • 未先运行
    honcho workspace inspect
    时,切勿执行
    honcho workspace delete
  • 当推导似乎停滞时,检查队列状态。
  • 对比peer卡片与结论以了解内存状态。

Inspection tour

检查流程

When orienting to a Honcho deployment, walk outside-in:
当熟悉Honcho部署时,从外到内逐步操作:

1. Understand the workspace

1. 了解工作区

bash
honcho workspace inspect --json
bash
honcho workspace inspect --json

2. Find the peer

2. 找到目标peer

bash
honcho peer list --json
honcho peer inspect <peer_id> --json
bash
honcho peer list --json
honcho peer inspect <peer_id> --json

3. Check peer's memory

3. 检查peer的内存

bash
honcho peer card <peer_id> --json
honcho conclusion list --observer <peer_id> --json
honcho conclusion search "topic" --observer <peer_id> --json
bash
honcho peer card <peer_id> --json
honcho conclusion list --observer <peer_id> --json
honcho conclusion search "topic" --observer <peer_id> --json

4. Debug a session

4. 调试会话

bash
honcho session inspect <session_id> --json
honcho message list <session_id> --last 20 --json
honcho session context <session_id> --json
honcho session summaries <session_id> --json
bash
honcho session inspect <session_id> --json
honcho message list <session_id> --last 20 --json
honcho session context <session_id> --json
honcho session summaries <session_id> --json

5. Search across workspace

5. 跨工作区搜索

bash
honcho workspace search "query" --json
honcho peer search <peer_id> "query" --json
bash
honcho workspace search "query" --json
honcho peer search <peer_id> "query" --json

Debugging playbook

调试指南

Peer not learning?

Peer无法学习?

bash
undefined
bash
undefined

Is observation enabled?

观察功能是否启用?

honcho peer inspect <peer_id> --json | jq '.configuration'
honcho peer inspect <peer_id> --json | jq '.configuration'

Is the deriver queue processing messages?

推导队列是否在处理消息?

honcho workspace queue-status --json
honcho workspace queue-status --json

What conclusions exist?

存在哪些结论?

honcho conclusion list --observer <peer_id> --json honcho conclusion search "expected topic" --observer <peer_id> --json
undefined
honcho conclusion list --observer <peer_id> --json honcho conclusion search "expected topic" --observer <peer_id> --json
undefined

Session context looks wrong?

会话上下文异常?

bash
undefined
bash
undefined

Raw context an agent would receive

Agent接收的原始上下文

honcho session context <session_id> --json
honcho session context <session_id> --json

Summaries feeding the context

提供上下文的摘要

honcho session summaries <session_id> --json
honcho session summaries <session_id> --json

Recent message history

近期消息历史

honcho message list <session_id> --last 50 --json
undefined
honcho message list <session_id> --last 50 --json
undefined

Dialectic giving bad answers?

辩证逻辑给出错误答案?

bash
undefined
bash
undefined

What the peer card says

peer卡片的内容

honcho peer card <peer_id> --json
honcho peer card <peer_id> --json

Conclusions on the specific topic

特定主题的结论

honcho conclusion search "topic" --observer <peer_id> --json
honcho conclusion search "topic" --observer <peer_id> --json

Exercise the dialectic directly

直接测试辩证逻辑

honcho peer chat <peer_id> "what do you know about X?" --json
undefined
honcho peer chat <peer_id> "what do you know about X?" --json
undefined