diff --git a/.openclaw-sync/source.json b/.openclaw-sync/source.json index 346923861..e29e62d1b 100644 --- a/.openclaw-sync/source.json +++ b/.openclaw-sync/source.json @@ -1,5 +1,5 @@ { "repository": "openclaw/openclaw", - "sha": "1f03b629befc1e90ebdac72b1e80272e347f7e17", - "syncedAt": "2026-05-02T22:22:21.920Z" + "sha": "9fdc0e703077228b4b8308813ba845cda32c4223", + "syncedAt": "2026-05-02T22:22:51.366Z" } diff --git a/docs/concepts/system-prompt.md b/docs/concepts/system-prompt.md index 66dafe7a0..e8fd9d02e 100644 --- a/docs/concepts/system-prompt.md +++ b/docs/concepts/system-prompt.md @@ -160,6 +160,13 @@ heartbeats are disabled for the default agent or files concise — especially `MEMORY.md`, which can grow over time and lead to unexpectedly high context usage and more frequent compaction. +When a session runs on the native Codex harness, Codex loads `AGENTS.md` +through its own project-doc discovery. OpenClaw still resolves the remaining +bootstrap files and forwards them as Codex config instructions, so `SOUL.md`, +`TOOLS.md`, `IDENTITY.md`, `USER.md`, `HEARTBEAT.md`, `BOOTSTRAP.md`, and +`MEMORY.md` keep the same workspace-context role without duplicating +`AGENTS.md`. + `memory/*.md` daily files are **not** part of the normal bootstrap Project Context. On ordinary turns they are accessed on demand via the `memory_search` and `memory_get` tools, so they do not count against the context window unless the model explicitly reads them. Bare `/new` and `/reset` turns are the exception: the runtime can prepend recent daily memory as a one-shot startup-context block for that first turn. diff --git a/docs/plugins/codex-harness.md b/docs/plugins/codex-harness.md index 47d91aafa..1c23e86c7 100644 --- a/docs/plugins/codex-harness.md +++ b/docs/plugins/codex-harness.md @@ -259,6 +259,20 @@ For live and Docker smoke tests, auth usually comes from the Codex CLI account or an OpenClaw `openai-codex` auth profile. Local stdio app-server launches can also fall back to `CODEX_API_KEY` / `OPENAI_API_KEY` when no account is present. +## Workspace bootstrap files + +Codex handles `AGENTS.md` itself through native project-doc discovery. OpenClaw +does not write synthetic Codex project-doc files or depend on Codex fallback +filenames for persona files, because Codex fallbacks only apply when +`AGENTS.md` is missing. + +For OpenClaw workspace parity, the Codex harness resolves the other bootstrap +files (`SOUL.md`, `TOOLS.md`, `IDENTITY.md`, `USER.md`, `HEARTBEAT.md`, +`BOOTSTRAP.md`, and `MEMORY.md` when present) and forwards them through Codex +config instructions on `thread/start` and `thread/resume`. This keeps +`SOUL.md` and related workspace persona/profile context visible without +duplicating `AGENTS.md`. + ## Add Codex alongside other models Do not set `agentRuntime.id: "codex"` globally if the same agent should freely switch