mirror of
https://github.com/openclaw/openclaw.git
synced 2026-10-26 10:13:27 +08:00
Related: #176053, #176308 ## What Problem This Solves Fixes: agents working in a subsystem load scoped `AGENTS.md` guides that name removed code and commands, repeat root rules, and in places contradict current root rules (restart the Gateway for proof, run `check-changed.mjs` locally, avoid `importOriginal` mocks that a check now requires). ## User Impact No user-visible change. Agents get shorter scoped guides with current names and commands and one owner per rule. Scoped `AGENTS.md` total: 98,031 → 73,215 characters (−25%). Six guides with no remaining unique rule are deleted. ## Why This Change Was Made Every line of the 28 scoped guides was checked against `origin/main` and its history. Edits only remove or rewrite lines that are stale, duplicated, behavior-free, or in conflict with root; conflicts resolve toward current root. Lines that encode a recent maintainer decision are unchanged. **Stale (fixed):** - Telegram: `createTelegramTransportIngressDrain` (removed in #111214) → the monitor in `telegram-ingress-drain-factory.ts`; throttle owner → `getOrCreateAccountThrottler` (#157349). - `src/channels`: memory profile command → `pnpm test:extensions:memory`. - `extensions`: removed the `src/plugin-sdk/<id>.ts` facade allowance (the SDK guide forbids new ones) and the deleted `src/plugin-sdk-internal/**` path. - `apps/macos`: `AppLaunchPresentationPolicy` → `AppLaunchRuntimePlan`. - Embedded runner: `sessionFile` → `sessionTarget`. - `src/gateway/server-methods`: the raw JSONL transcript warning (transcripts are SQLite); its live `appendMessageAsync` rule moved to `src/agents`. The stale `server-methods/CLAUDE.md` entries in `.gitattributes` and `.oxfmtrc.jsonc` are removed. - `docs`: the "up to 30 pages" preview claim does not exist in `scripts/docs-dev.mjs`. **Conflicts with root (resolved toward root):** - acpx "restart the gateway" → validate in an isolated Gateway. - Telegram "bot-to-bot QA lane" proof → the userbot e2e skill route in root. - `scripts` and `apps/macos`: local `check-changed.mjs` suggestions removed (root: PR CI is the broad proof). - `src/agents`: "avoid `importOriginal` partial mocks" → pass the real module or annotate `// mock-isolation:` (`check:test-mock-exports`). - Embedded runner "prefer focused helper tests" → aligned with root end-to-end proof. **Duplicates and owner moves:** - `scripts/AGENTS.md` "Proof Rules" repeated root, the testing skill and `remote-gates.md`. - Release mechanics in `apps/ios` and `apps/android` repeated each app's `VERSIONING.md`; guardrails stay. - Rules that stylelint, lint scripts or tests already enforce now name the check instead of restating it. - Core ingress-drain rules moved word for word from the Telegram guide to `src/channels/AGENTS.md`, since five channels share that monitor. - `src/agents/tools/AGENTS.md` and `src/gateway/server-methods/AGENTS.md` deleted after moving their one live rule each into `src/agents/AGENTS.md`. - SDK compatibility: one bullet keeps both meanings (internal callers removed freely; third-party exports need a deprecation window and maintainer approval). **Test notes moved to their tests:** the per-test ownership notes in the litellm, lmstudio, ollama and vllm guides now sit as comments in the 20 test files they describe (several live outside the plugin folders, where those guides never loaded); the four guides are deleted. One vLLM note described a test deleted in #165813 and is dropped. **Telegram test rules → test-audit:** the copied test-ownership rules point at the `test-audit` skill; the Telegram-specific crash-window/restart-replay rule stays. **`openclaw-testing` skill:** the worktree hint no longer suggests local `check-changed.mjs`. **One check instead of prose:** `scripts/check-test-helper-extension-import-boundary.mts` now also scans `src/channels/plugins/contracts/test-helpers` (zero violations today), so that guide no longer restates the boundary. **Unchanged on purpose (recent maintainer decisions):** the Gateway session row projection contract, the UI session roster contract, the `NO_REPLY` reply rules, and the SDK SQLite removal date. ## Evidence - Every relative link in the changed guides resolves; no file links to the deleted guides. - `test/test-helper-extension-import-boundary.test.ts` passes; the script reports `[]` on the new root and flagged a temporary violating file during the check. - `oxfmt` and `git diff --check` clean; the pre-commit hook ran on this commit, including the `AGENTS.md` size check. - The 20 test files that received comments pass (318 tests, plus the shared SGLang discovery contract); comments only, no test logic changed. - Diff: 57 files, +191/−441. **Merge danger:** two-way door; a revert restores every guide. No runtime change. Blast radius: agent instructions for work in these directories, and one repository check that now scans one more test-helper directory. Co-authored-by: Ayaan Zaidi <hi@obviy.us>
13 lines
702 B
Plaintext
13 lines
702 B
Plaintext
* text=auto eol=lf
|
|
CLAUDE.md -text
|
|
ui/src/i18n/.i18n/* linguist-generated
|
|
apps/.i18n/** linguist-generated
|
|
apps/android/app/src/main/res/values-*/strings.xml linguist-generated
|
|
apps/android/app/src/main/res/values-*/assistant.xml linguist-generated
|
|
apps/android/app/src/thirdParty/res/values-*/accessibility_strings.xml linguist-generated
|
|
apps/android/wear/src/main/res/values-*/strings.xml linguist-generated
|
|
apps/android/app/src/main/java/ai/openclaw/app/i18n/NativeStringResources.kt linguist-generated
|
|
apps/ios/Resources/Localizable.xcstrings linguist-generated
|
|
apps/macos/Sources/OpenClaw/Resources/Localizable.xcstrings linguist-generated
|
|
apps/ios/**/*.lproj/InfoPlist.strings linguist-generated
|