-
Notifications
You must be signed in to change notification settings - Fork 7.4k
Support enable/disable skill via config/api. #9328
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
bbb9839 to
1bbf53c
Compare
1bbf53c to
a4495f2
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: a4495f2c05
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: d97e5a3ebc
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| self.thread_manager.skills_manager().clear_cache(); | ||
| self.outgoing | ||
| .send_response( | ||
| request_id, | ||
| SkillsConfigWriteResponse { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Refresh user instructions after skill toggle
On success, skills_config_write only clears the skills cache. Existing threads keep the user_instructions that were computed at session spawn from the then‑enabled skills, so toggling a skill while a thread is active leaves the old skill list in the system prompt. In that scenario the model can still be guided by the stale list until the session restarts. Consider reloading thread configs or regenerating user_instructions for active sessions after a successful write.
Useful? React with 👍 / 👎.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That's true but we don't want to modify the history. We will think of a better solution later.
81eb1a8 to
840a901
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 840a9012b1
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
840a901 to
6e129b3
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 6e129b3d52
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
@codex review again |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 6e129b3d52
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| let mut seen: HashSet<PathBuf> = HashSet::new(); | ||
| outcome | ||
| .skills | ||
| .retain(|skill| seen.insert(skill.name.clone())); | ||
| .retain(|skill| seen.insert(skill.path.clone())); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Preserve name-level dedupe or update clients to disambiguate
By deduping only on skill.path here, the loader now allows multiple skills with the same name (e.g., repo and user copies) to coexist. Existing clients still resolve $SkillName mentions by name only (see codex-rs/tui/src/chatwidget.rs find_skill_mentions which skips duplicates by skill.name), so the first entry in the list always wins and the other same‑name skill becomes unreachable. This is a regression from the prior name-based dedupe and can cause the wrong skill’s instructions to be injected when a user intends the other copy. Consider keeping name-level dedupe for user-visible lists or updating clients to disambiguate by path.
Useful? React with 👍 / 👎.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That's OK.
In config.toml:
API:
skills/list, skills/config/write