Tencent/WeKnora · error

skill name cannot contain reserved word: %s

Error message

skill name cannot contain reserved word: %s

What it means

Naming-policy guard in Skill.Validate: the skill's Name contains one of the reserved words checked by the loop (Claude-spec reserved substrings). The name is syntactically valid but disallowed to prevent impersonation/collision with built-in skill semantics; the reserved word is interpolated into the message.

Source

Thrown at internal/agent/skills/skill.go:95

	Content  string // File content
	IsScript bool   // Whether this is an executable script
}

// Validate checks if the skill metadata is valid according to Claude's specification
func (s *Skill) Validate() error {
	// Validate name
	if s.Name == "" {
		return errors.New("skill name is required")
	}
	if n := utf8.RuneCountInString(s.Name); n > MaxNameLength {
		return fmt.Errorf("skill name is %d characters; maximum is %d", n, MaxNameLength)
	}
	if !namePattern.MatchString(s.Name) {
		return errors.New("skill name must contain only letters, numbers, hyphens, and underscores")
	}
	for _, reserved := range reservedWords {
		if strings.Contains(s.Name, reserved) {
			return fmt.Errorf("skill name cannot contain reserved word: %s", reserved)
		}
	}
	if xmlTagPattern.MatchString(s.Name) {
		return errors.New("skill name cannot contain XML tags")
	}

	// Validate description
	if s.Description == "" {
		return errors.New("skill description is required")
	}
	if n := utf8.RuneCountInString(s.Description); n > MaxDescriptionLength {
		return fmt.Errorf("skill description is %d characters; maximum is %d", n, MaxDescriptionLength)
	}
	if xmlTagPattern.MatchString(s.Description) {
		return errors.New("skill description cannot contain XML tags")
	}

	return nil

View on GitHub (pinned to 988cbb0330)

Solutions

  1. Rename the skill to avoid the reserved substring in its frontmatter `name` field
  2. Use a hyphenated or prefixed variant, e.g. add a project prefix
  3. Re-validate after rename via ParseSkillFile
Defensive patterns

Strategy: validation

When it happens

Trigger: Thrown at internal/agent/skills/skill.go:95 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of Tencent/WeKnora@988cbb0330 (2026-09-02). Data as JSON: /api/errors/939601514d3e9f81. Report an issue: GitHub.