Repository navigation
Conversation
The / command list and thread start listed .bb/skills and then read each SKILL.md with a separate host RPC. Add host.read_skill_files, which returns every top-level SKILL.md in one call, and keep validation on the server. Bump the host daemon protocol to 231. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
host.read_file enforced rootPath containment for each SKILL.md. Require rootPath on host.read_skill_files and reject a skills root whose real path escapes it, such as a .bb directory symlinked outside the workspace. Co-Authored-By: Claude Opus 5.5 <[email protected]>
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 1074291f78
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| return { | ||
| directoryName: args.directoryName, | ||
| sizeBytes: stat.size, | ||
| content: await fs.readFile(filePath, "utf8"), |
There was a problem hiding this comment.
Cap the aggregate skill-file payload
When a workspace contains many large but individually permitted skill files, this retains every file body for one RPC response; the server requests up to 1,000 files at 10 MiB each, so the daemon can accumulate and JSON-serialize nearly 10 GiB in a single WebSocket message. A much smaller collection can already exhaust daemon memory or exceed transport message limits, causing thread startup and /commands resolution to fail, whereas the previous batched per-file RPCs did not aggregate all bodies into one payload. Add an aggregate byte cap or paginate the results while preserving the reduced round-trip behavior.
Useful? React with 👍 / 👎.
One response carried every SKILL.md with only a per-file cap, so a .bb/skills tree over the 100 MiB daemon socket frame limit would drop the host session on every retry. Add maxTotalBytes (32 MiB from the server); skills past the budget return without content and are skipped with a warning. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Local disk reads do not need the batched two-phase stat-then-read loop. One pass keeps the same budget, limit, and missing-file behavior. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Skip the server's excluded directory names and require an exact-case SKILL.md, as the host.list_files path did on case-insensitive filesystems. Co-Authored-By: Claude Opus 5.5 <[email protected]>
The response is JSON, where control characters expand up to 6x, so a raw 32 MiB budget could still exceed the 100 MiB daemon socket frame limit. Count each file's JSON-encoded length against maxTotalBytes. Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
Closing as superseded. #5257 (merged) added
|
Human comments
What was wrong
Loading project skills took two serial host round trips: list
.bb/skills, then read eachSKILL.md. That made it the slowest branch of the/commandsroute, and thread start paid the same cost.What changed
host.read_skill_files..bb/skills.HOST_DAEMON_PROTOCOL_VERSIONgoes from 230 to 231.<dir>/SKILL.mdfiles inside the workspace..bbor.bb/skillsfolder that symlinks outside the workspace.venv, and requires an exact-caseSKILL.md, as before.How you verified
New daemon tests cover:
skill.mdBranch dev app at
59489178dc(10-skill fixture), one/commandscall:86ac764436Same run: all 10 skills appeared in the
/menu.Same run: a claude-code thread listed all 10 skills.
Same run: a mismatched name,
venv/, and a lowercaseskill.mdwere all skipped.New daemon test: the budget counts encoded size, so control-character content can't exceed it.
Remote CI passed on head
9d68b83622.Part of #5192 (row 5: daemon round trips)
BB-Thread: Investigate slow command lookup
🤖 Generated with Claude Code