fix(skills): instruct agent to use exact absolute path for skill files#1104
Open
buidackim wants to merge 1 commit intonextlevelbuilder:devfrom
Open
fix(skills): instruct agent to use exact absolute path for skill files#1104buidackim wants to merge 1 commit intonextlevelbuilder:devfrom
buidackim wants to merge 1 commit intonextlevelbuilder:devfrom
Conversation
The system prompt had conflicting guidance: the Skills section told the agent to read SKILL.md at the provided location path, while the Workspace section said 'do not guess absolute paths'. Weaker models (e.g. MiniMax-M2.7) would try to reconcile both instructions by stripping the absolute prefix and converting to a relative path, causing 'file not found' errors. This change: - Adds '(use the EXACT absolute path provided)' to skill reading instructions in both inline and search modes - Clarifies workspace guidance: relative paths for user files, exact absolute paths for skills - Updates skill_search result instruction with the same emphasis
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
The system prompt contains conflicting guidance that causes weaker models to mangle skill file paths:
Models like MiniMax-M2.7 try to reconcile both instructions by stripping the absolute prefix from the skill path (e.g.
/app/data/skills-store/gpt-image-2-pro-max/1/SKILL.md→skills/gpt-image-2-pro-max-main/SKILL.md), causingfile not founderrors.Fix
Resolves the contradiction by clarifying the boundary:
(use the EXACT absolute path provided)Files Changed
internal/agent/systemprompt.go— 3 string changes in prompt guidanceinternal/tools/skill_search.go— 1 string change in search result instructionImpact
Minimal prompt size increase (~30 tokens). Helps weaker models follow skill paths correctly without affecting stronger models.