Skip to content

feat: show automatic use for personal and organization skills - #31160

Open
jaaydenh wants to merge 348 commits into
mainfrom
chat-project-skills/automatic-use-site
Open

jaaydenh wants to merge 348 commits into
mainfrom
chat-project-skills/automatic-use-site

Conversation

@jaaydenh

@jaaydenh jaaydenh commented Oct 22, 2026 •

Copy link
Copy Markdown
Collaborator

The API already accepts model_invocable for personal, organization, and project skills, but only the project skills dialog exposed it. Personal and organization skills could be made manual-only through the API, but the UI never showed it.

  • The shared SkillEditorDialog (personal and organization skill tables) gets the Agents can use it automatically switch, and SkillsTable sends model_invocable on create and update.
  • SkillsTableView rows show a Manual only badge, matching the project skills dialog.
  • Downloads and Export all save the content the API returns. Since feat: honor disable-model-invocation in uploaded skill content #31159 that content has disable-model-invocation: true for manual-only skills, so this PR has no browser helper for it.
  • Importing a SKILL.md always resets automatic use in create mode. An edit-mode import of a file with disable-model-invocation: true now turns the switch off instead of silently dropping the line, which matches the server rule in feat: honor disable-model-invocation in uploaded skill content #31159.
  • Docs: the automatic-use paragraph moves from the project skills section to a shared "Keep agents from using a skill on their own" section.

Every skill editor dialog story now shows the new switch, so expect Pixel diffs on the SkillsTableView dialog stories.

Skills table Edit dialog
Manual only badge Automatic use switch

Depends on #31159.

Generated by an agent on behalf of the user

…lls/actions-site

# Conflicts:
#	site/src/pages/AgentsPage/components/ProjectPage/ProjectSkillsDialog.tsx
…poser content first and fall back to its plain text
…ject-skills/skill-chips-transcript

# Conflicts:
#	site/src/pages/AgentsPage/components/ChatMessageInput/skillClipboard.ts
@jaaydenh
jaaydenh temporarily deployed to docs-preview November 13, 2026 08:52 — with GitHub Actions Inactive
The server located the key with a text prefix, so quoted or spaced keys
stayed in stored content, and downloads then added a duplicate key that
no parser accepts. Find the key through the YAML node tree, confirm the
other fields survive, and let a false value turn automatic use back on.
Downloads now check the parsed frontmatter before adding the marker.
…ills/automatic-use-site

# Conflicts:
#	site/src/pages/AgentsPage/components/SkillsTable.test.tsx
#	site/src/pages/AgentsPage/utils/skills.test.ts
#	site/src/pages/AgentsPage/utils/skills.ts
@jaaydenh
jaaydenh temporarily deployed to docs-preview November 13, 2026 09:42 — with GitHub Actions Inactive
@linear-code

linear-code Bot commented Nov 13, 2026

Copy link
Copy Markdown

CODAGT-1592

The server removed the key on upload and only the browser added it back
on download. The API returned files that other tools read as automatic,
and a second YAML reader disagreed with the one workspace skills use.

Store skill content as uploaded. Read the key with the shared
workspacesdk reader, and make the content in every API response agree
with model_invocable. Browser downloads now save that content unchanged.
Say which values Coder ignores and which it rejects, describe the returned file by what the reader gets, and note that a stored file whose key cannot be set is returned unchanged.
…skills/automatic-use-site

The base now sets disable-model-invocation on the server in every API response, so the browser copy of that logic goes: skillFileContent, its tests, and the splitSkillMarkdown helper that only it needed. Download and Export all save the content the API returns.
…skills/automatic-use-site

Brings in main's project skill display names. The skill editor keeps both the display name field and the shared automatic-use switch.
Base automatically changed from chat-project-skills/frontmatter-api to main November 18, 2026 07:04
jaaydenh added a commit that referenced this pull request Nov 18, 2026
Addresses @ethanndickson's [review comment on
#30882](#30882 (comment)):
the same `SKILL.md` file could be manual-only in Claude Code and the
project dialog but automatic in Coder, because the server and the
browser each handled `disable-model-invocation` in their own way.

The server now owns the key for personal, organization, and project
skills:

- When a create or update request leaves `model_invocable` unset,
`disable-model-invocation: true` in the content turns automatic use off,
and `false` turns it back on. The key is read with the function
workspace skills use, so a file gets the same setting in both places.
Only YAML booleans count, so a quoted `"true"` is ignored.
- An explicit `model_invocable` in the request always wins.
- New content without the key leaves the setting unchanged, so editing
text never turns it back on.
- Content is stored as uploaded. Every API response returns content
whose key agrees with `model_invocable`: when the stored file says
otherwise, the server replaces the value of the key or adds the key
before the first one, and leaves every other byte alone.
- **Download** and **Export all** save the content the API returns, so
the browser no longer edits the file. `withDisabledModelInvocation` is
removed.
- An upload is rejected with a 400 when the key holds a value the server
can't replace with a boolean, such as a list. A later change to
`model_invocable` can then always reach the file.

Two edges:

- Adding the key makes the returned file about 30 bytes larger, so a
file at the 64 KB upload limit can be too large to upload again.
- A skill stored before the upload check with a value the server can't
replace is returned as stored.

Workspace skills already honor the key since #31147.

#31160, the frontend PR on top of this one, adds the switch to the
personal and organization skill editors.

> Generated by an agent on behalf of the user

---------

Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Nick Vigilante <nickvigilante@users.noreply.github.com>
@jaaydenh

Copy link
Copy Markdown
Collaborator Author

@codex review

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

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: f461151705

ℹ️ 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".

@jaaydenh

Copy link
Copy Markdown
Collaborator Author

@codex review

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Delightful!

Reviewed commit: 41b838ddbc

ℹ️ 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".

@ethanndickson ethanndickson left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

one nit re: docs. could use some human love

Comment on lines +332 to +334
Importing a `SKILL.md` file that sets `disable-model-invocation: true` turns the switch off.
When you add a skill, importing a file without that line turns the switch back on.
When you edit a skill, it leaves the switch unchanged.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This reads weird. Not sure we even need to update docs here?

This branch was previously deployed

2 inactive (1 outdated) deployments
main — 41b838dd Deployed Nov 18, 2026 by jaaydenh via cla #259200
docs-preview — e51d9354 Deployed Nov 13, 2026 by jaaydenh via deploy #85
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.

3 participants