T-QK1S-adopt-preview-honours-group-under-plugin
State: planning/draft · Impact: medium · Complexity: medium
The import preview always reports paths under the default “adopted” group, even when the reader typed a different plugin name. The real import honours the typed name and lands the notes correctly, so the preview shows the reader the wrong destination for their own import.
| Location | Role today |
|---|---|
solutions/determined/crates/determined-platform/src/api/v1/agent_skills.rs:288-294 | get_adopt_preview(state, vault_id, source) takes no plugin argument; ontogen routes it as GET /agent-skills/adopt-preview/{vault_id}/{source} |
solutions/determined/crates/determined-agent-skills/src/lib.rs:1426-1440 | get_adopt_preview hardcodes plugin: None into the AgentSkillAdoptRequest it builds for the dry run |
solutions/determined/experiences/agent-pants/app/composables/useAgentSkillAdopt.ts:17-27 | useAgentSkillAdoptPreview(vault, source) calls the transport with only vault and source; it has no plugin parameter to pass |
solutions/determined/packages/vault-platform-client/src/generated/transport.ts:388,1146-1153,3061-3065 | Generated transport method agentSkillGetAdoptPreview(vaultId, source); regenerates once the Rust signature changes |
Proposed
Section titled “Proposed”The preview takes the same plugin name the reader typed and reports
every row’s entry_path/plugin under that name, matching what the
real import will do.
Approach
Section titled “Approach”- Add
plugin: Option<String>toget_adopt_previewindetermined-platform/src/api/v1/agent_skills.rs. Ontogen already routes an optional trailingStringargument as a query parameter (seeactivity.rs’sathlete_id/qparams), so this stays a GET. - Thread
pluginthrough todetermined_agent_skills::get_adopt_previewand into theAgentSkillAdoptRequestit builds, replacing the hardcodedNone. - Regenerate the HTTP/IPC transports and
core.generated.ts-equivalent TS client soagentSkillGetAdoptPreviewgains the new parameter. - Update
useAgentSkillAdoptPreviewto accept and forward a plugin accessor, and wire the import page’s typed field into it. - Add a fixture test asserting a preview with a typed plugin name reports rows under that name, not “adopted”.
| Area | Note |
|---|---|
solutions/determined/crates/determined-platform/src/api/v1/agent_skills.rs | Add plugin: Option<String> to get_adopt_preview |
solutions/determined/crates/determined-agent-skills/src/lib.rs | Forward plugin instead of hardcoding None |
solutions/determined/crates/determined-platform/src/api/transport/http/generated.rs | Regenerated: query param on the preview route |
solutions/determined/crates/determined-platform/src/api/transport/ipc/generated.rs | Regenerated: new IPC argument |
solutions/determined/packages/vault-platform-client/src/generated/transport.ts | Regenerated: new transport parameter |
solutions/determined/experiences/agent-pants/app/composables/useAgentSkillAdopt.ts | useAgentSkillAdoptPreview takes and forwards a plugin accessor |
solutions/determined/experiences/agent-pants/app/pages/apps/agent-pants/import.vue | Pass the typed “Group under plugin” field into the preview call |
Acceptance criteria
Section titled “Acceptance criteria”- AC-1: Typing a plugin name and clicking Preview reports every row’s
entry_pathandpluginunder that typed name, not “adopted”. - AC-2: Leaving the plugin field at its default still previews under “adopted”, unchanged from today.
- AC-3: A fixture test covers both cases against
get_adopt_preview.
Out of scope
Section titled “Out of scope”- Changing how the real import (
runAgentSkillAdopt) resolves the plugin name — it already honours it correctly.
Dependencies
Section titled “Dependencies”- none
Discovery context
Section titled “Discovery context”Found by the agent-pants bug survey, N-5LD4-bug-sweep-2026-09-12-agent-pants (row AP-68).