Repository navigation
feat(coderd/x/chatd): offer stored personal and organization agent types to spawn_agent - #69
Conversation
…pes to spawn_agent
|
@codex review
|
Codex Review Summary: ✅ CompletedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: b4c2375553
ℹ️ 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".
A stored definition disabled after the catalog listed it no longer spawns, and its content must keep the row's name, so a row cannot spawn as a built-in type.
|
@codex review
|
|
Codex Review: Didn't find any major issues. Delightful! Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
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". |
Closing and reopening only to make GitHub recompute the merge ref against current main ( |
The merge ref now points at current main ( |
Merge evidence for head
|
Part of #7
spawn_agentnow offers stored agent definitions next to the workspace ones, behindfork-agent-definitions. Before this PR, it offered only the types pinned from the workspace's agent files.What spawn_agent offers
workspacepersonalorgchatOwnerSubject, the same subject org skills use), so dbauthz from feat(coderd/database): store agent definitions for users and organizations #62 applies organization membership and ACLs. A probe confirmed that this subject carries the owner's organization roles.skillspkg.MergeSkillsandLookup). A name that several tiers define is listed only aspersonal/reviewer,org/reviewerandworkspace/reviewer, and the bare name is rejected. A name that one tier defines is listed bare, and its qualified form also works.general,explore) stay reserved in every tier.Tests
TestForkAgentDefinitionStoredTiers: a name in three tiers is listed only qualified, and the bare name is rejected. Each qualified form and a single-tier name spawn with the right prompt and record the plain name onchat_subagents. Disabled rows and built-in names are hidden, and a row whose content namesgeneralfails to spawn.TestParseStoredAgentDefinitionDisabled: a row disabled after listing does not load.TestForkAgentDefinitionStoredTiersAuthz(dbauthz-wrapped store): a member sees their own personal type and the Everyone-shared org type, but not another member's type or an org type with an empty ACL. A non-member sees nothing.Lookup, removing the built-in reservation, dropping the stored tiers, or removing the load-time enabled or name check makes a test fail.go test ./coderd/x/chatd/...(20 packages ok) and golangci-lint on./coderd/x/chatd/...(no findings in the changed files).ARCHITECTURE.mdgets a TODO for the owner to describe the stored tiers.Size
About 375 changed lines: about 195 implementation, about 180 tests and 1 doc TODO.