hermes - 💡(How to fix) Fix [Feature]: Configurable default working directory for QQBot and Weixin gateway sessions

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…

Root Cause

That directory is implementation/internal state for Hermes itself, not the user's normal workspace. It is surprising and risky for gateway sessions because:

Fix Action

Fix / Workaround

  • the system prompt's reported current working directory;
  • terminal tool default workdir;
  • file/search/patch tools that operate relative to the session cwd;
  • new sessions after /new or gateway restart.

Code Example

/c/Users/yangg/AppData/Local/hermes/hermes-agent

---

C:\Users\yangg\AppData\Local\hermes\hermes-agent

---

gateway:
  default_cwd: E:/workplace
  platforms:
    qqbot:
      cwd: E:/workplace
    weixin:
      cwd: E:/workplace

---

/c/Users/yangg/AppData/Local/hermes/hermes-agent

---

E:/workplace
RAW_BUFFERClick to expand / collapse

Feature Description

Allow messaging gateway channels such as QQBot and Weixin/WeChat to configure a custom default working directory, instead of always starting in the Hermes Agent source checkout.

Motivation

When using Hermes from QQBot or Weixin, the current working directory is the Hermes Agent project source directory:

/c/Users/yangg/AppData/Local/hermes/hermes-agent

On Windows, this corresponds to:

C:\Users\yangg\AppData\Local\hermes\hermes-agent

That directory is implementation/internal state for Hermes itself, not the user's normal workspace. It is surprising and risky for gateway sessions because:

  • file discovery starts from the Hermes source tree instead of the user's projects;
  • commands such as pwd, relative file operations, and context-file discovery are anchored to the wrong place;
  • users may accidentally inspect or edit Hermes internals when they expected to work in their own workspace;
  • CLI/TUI and messaging-platform behavior can diverge, making the agent harder to reason about.

Proposed Solution

Add a supported configuration path for gateway sessions to set the default working directory, ideally usable per platform/channel/profile. For example:

gateway:
  default_cwd: E:/workplace
  platforms:
    qqbot:
      cwd: E:/workplace
    weixin:
      cwd: E:/workplace

Alternatively, if terminal.cwd is intended to be the single source of truth, QQBot and Weixin gateway sessions should consistently honor it for:

  • the system prompt's reported current working directory;
  • terminal tool default workdir;
  • file/search/patch tools that operate relative to the session cwd;
  • new sessions after /new or gateway restart.

Current Behavior

In a QQBot DM session, asking for the current working directory returns the Hermes Agent source checkout:

/c/Users/yangg/AppData/Local/hermes/hermes-agent

Expected Behavior

Users should be able to configure a workspace directory such as:

E:/workplace

and QQBot/Weixin sessions should start there by default.

Affected Component

Gateway (QQBot / Weixin)

Environment

  • OS: Windows 10
  • Hermes Agent: v0.14.0 (2026.5.16), 1 commit behind at the time of reporting
  • Python: 3.11.13
  • Current observed cwd: C:\Users\yangg\AppData\Local\hermes\hermes-agent

Related Issues

This appears related to prior gateway cwd reports such as #27383 and #11312, but this report is specifically for QQBot and Weixin/WeChat and asks for an explicit, user-configurable gateway working directory rather than defaulting to the Hermes source checkout.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING