From 0a262b7dbf10017b820d90c1f55c06189265d7ce Mon Sep 17 00:00:00 2001 From: annguyenNous Date: Thu, 25 Jun 2026 13:57:00 +0700 Subject: [PATCH] fix(tools): enforce 60-char description limit for skills MAX_DESCRIPTION_LENGTH was set to 1024, but the documented skill- authoring standard specifies <=60 characters. The model generates descriptions up to 202 chars because the validation allows 1024. Lower MAX_DESCRIPTION_LENGTH from 1024 to 60 to match the documented standard. The system-prompt skill index already truncates to 60 chars, so over-length descriptions lose their routing signal past char 60. Fixes #52367 --- tools/skill_manager_tool.py | 2 +- tools/skills_tool.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/skill_manager_tool.py b/tools/skill_manager_tool.py index 12fc3d1a103..d1299783e72 100644 --- a/tools/skill_manager_tool.py +++ b/tools/skill_manager_tool.py @@ -174,7 +174,7 @@ def _skills_dir() -> Path: return get_hermes_home() / "skills" MAX_NAME_LENGTH = 64 -MAX_DESCRIPTION_LENGTH = 1024 +MAX_DESCRIPTION_LENGTH = 60 def _containing_skills_root(skill_path: Path) -> Path: diff --git a/tools/skills_tool.py b/tools/skills_tool.py index a5613f62c4c..fc4aa3763b6 100644 --- a/tools/skills_tool.py +++ b/tools/skills_tool.py @@ -160,7 +160,7 @@ def _skills_dir() -> Path: # Anthropic-recommended limits for progressive disclosure efficiency MAX_NAME_LENGTH = 64 -MAX_DESCRIPTION_LENGTH = 1024 +MAX_DESCRIPTION_LENGTH = 60 # Platform identifiers for the 'platforms' frontmatter field. # Maps user-friendly names to sys.platform prefixes.