Skip to content

claw: fix skill dispatch and rename /skill to /skills#104

Merged
zevorn merged 2 commits intomainfrom
claw/skill-dispatch-fix
Mar 20, 2026
Merged

claw: fix skill dispatch and rename /skill to /skills#104
zevorn merged 2 commits intomainfrom
claw/skill-dispatch-fix

Conversation

@zevorn
Copy link
Copy Markdown
Owner

@zevorn zevorn commented Mar 20, 2026

Summary

  • Fix skill dispatch: check ai_skill_find() before attempting execution. Unregistered skill names fall through to "Unknown command" without triggering AI calls.
  • Rename /skill/skills: consistent plural naming.

Changes (2 commits)

Commit Description
claw: fix skill dispatch to only execute registered skills Gate execution on ai_skill_find() in all 3 shells
claw: rename /skill command to /skills Command table rename

Test plan

  • make build-linux — zero warnings
  • make build-zynq-a9-qemu — zero warnings
  • make test-unit-zynq — all suites pass
  • make build-esp32c3-qemu (CI)
  • Manual: /nonexistent → "Unknown command"
  • Manual: /skills → lists registered skills
  • Manual: /greet → executes built-in skill

zevorn added 2 commits March 20, 2026 22:03
Previously, dispatch_command tried ai_skill_try_command for any
unrecognized /command. When the skill didn't exist, it returned
CLAW_ERROR and fell through to "Unknown command", but
ai_skill_try_command internally called ai_skill_execute which
could produce confusing output before failing.

Now dispatch_command explicitly checks ai_skill_find() first.
If the skill exists, it executes and returns (even on failure).
If the skill does not exist, it falls through to "Unknown command"
without attempting execution. This ensures only NVS-persisted or
built-in skills are treated as commands.

Signed-off-by: Chao Liu <chao.liu.zevorn@gmail.com>
Signed-off-by: Chao Liu <chao.liu.zevorn@gmail.com>
@zevorn zevorn changed the title claw: fix skill dispatch to only execute registered skills claw: fix skill dispatch and rename /skill to /skills Mar 20, 2026
@zevorn zevorn merged commit a9eee5c into main Mar 20, 2026
11 checks passed
@zevorn zevorn deleted the claw/skill-dispatch-fix branch March 23, 2026 09:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant