Skip to content

refactor(agents): prepare hot-path runtime facts - #113167

Merged
steipete merged 2 commits into
mainfrom
steipete/simplify-w7-prepared-facts
Jul 23, 2026
Merged

steipete merged 2 commits into
mainfrom
steipete/simplify-w7-prepared-facts

Conversation

@steipete

Copy link
Copy Markdown
Contributor

What Problem This Solves

Agent attempts repeatedly rediscovered stable runtime metadata. System-prompt preparation walked workspace and cwd ancestors for a Git root on every attempt, while message-tool schema construction rescanned the loaded channel registry and durable-final capabilities.

Why This Change Was Made

Resolve the repository root once at run admission, including the explicit configured override, and carry it in the prepared runtime snapshot. Settle a versioned PreparedMessageToolCatalog for each exact plugin registry generation, carry it through the same prepared runtime, and keep supplied catalogs authoritative across registry reloads while retaining immutable bundled fallbacks.

The added code is the typed lifecycle seam plus focused generation tests; request-time filesystem and registry discovery are removed from the prepared paths. No auto-reply or dispatch-owned files are changed.

AI-assisted: implemented and reviewed with Codex; I understand the ownership and generation boundaries in this change.

User Impact

No user-visible behavior change. Agent attempts avoid repeated synchronous filesystem checks and loaded-channel scans on two hot preparation paths.

Evidence

@openclaw-barnacle openclaw-barnacle Bot added agents Agent runtime and tooling size: M maintainer Maintainer-authored PR labels Jul 23, 2026
@steipete steipete self-assigned this Jul 23, 2026
@steipete
steipete marked this pull request as ready for review July 23, 2026 22:34
@steipete
steipete merged commit af443b4 into main Jul 23, 2026
119 checks passed
@steipete
steipete deleted the steipete/simplify-w7-prepared-facts branch July 23, 2026 23:14
@steipete

Copy link
Copy Markdown
Contributor Author

Merged via squash.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

agents Agent runtime and tooling maintainer Maintainer-authored PR size: M

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant