Repository navigation
find_skills/search_skills returns each matched skill's full instruction subtree, not just its description - #1360
Conversation
#1356) Add `instructions` field to each matched skill in `find_skills` output: the skill's child node subtree rendered to flat markdown via a single-query depth-first walk. Childless skills return an empty string without error. Reuses the `get_subtree_data` + adjacency-list pattern from NodeService. Co-Authored-By: Claude Sonnet 4.6 <[email protected]>
Code Review — PR #1360Review Type: Initial Review Requirements Check
Code Review FindingsSuggested Improvements
The issue's Proposed Solution says "reusing the existing root+children rendering (
Minor but worth noting:
NitpicksNit:
Nit: Using SummaryThis is a clean, well-scoped fix for a confirmed defect. The implementation correctly uses the existing The AC3 prompt-injection concern is not a blocker — the field is delivered to the model as a tool result content field, which satisfies the issue's primary stated goal. The higher-level "agent injects instructions into the system prompt" behavior is clearly scoped to the follow-on routing issue (#1352). Recommendation: APPROVE — the tautological test is the only thing worth addressing; it does not block the fix from landing. |
- Replace tautological serialisation test with real pipeline test that exercises render_subtree_dfs → join; can now catch separator/DFS regressions - Drop &Arc<NodeService> param; take &NodeService (callers use .as_ref()) - Add Vec::with_capacity(node_map.len()) to avoid reallocations - Add comments: root_node discard intent + per-skill query tradeoff note Co-Authored-By: Claude Sonnet 4.6 <[email protected]>
Review Feedback AddressedAddressed (4/5 recommendations):
Skipped (0): All recommendations addressed. |
…on subtree, not just its description (#1360) * Deliver skill instruction subtrees via find_skills/search_skills (closes #1356) Add `instructions` field to each matched skill in `find_skills` output: the skill's child node subtree rendered to flat markdown via a single-query depth-first walk. Childless skills return an empty string without error. Reuses the `get_subtree_data` + adjacency-list pattern from NodeService. Co-Authored-By: Claude Sonnet 4.6 <[email protected]> * Address review feedback: tighten render_skill_instructions - Replace tautological serialisation test with real pipeline test that exercises render_subtree_dfs → join; can now catch separator/DFS regressions - Drop &Arc<NodeService> param; take &NodeService (callers use .as_ref()) - Add Vec::with_capacity(node_map.len()) to avoid reallocations - Add comments: root_node discard intent + per-skill query tradeoff note Co-Authored-By: Claude Sonnet 4.6 <[email protected]> --------- Co-authored-by: Claude Sonnet 4.6 <[email protected]>
Closes #1356