T-L7YP-git-panel-commit-with-validation
State: planning/proposed · Impact: high · Complexity: large
The user wants to commit a vault’s changes without leaving the app, but only after a check that the changed skills and notes still conform to their models. This task adds a Git section to the stacked left panel with stage/message/commit, running pluggable per-aspect validators first, so a broken skill or an invalid frontmatter schema is caught before it lands in history.
| Location | Role today |
|---|---|
solutions/determined/crates/determined-platform/src/api/v1/ | One route module per capability; no git_commit op and no validation-before-write hook |
solutions/agent-pants/crates/agent-adapt-core/src/discover.rs#discover_components | Refuses malformed components (bad name, missing description, path collisions, symlinks); reachable today only through get_component_tree |
solutions/determined/crates/determined-agent-skills/src/lib.rs#get_component_tree | The one caller of discover_components reachable from the UI; returns a tree plus an in-band scan-refusal banner, not a standalone check |
solutions/determined/experiences/agent-pants/app/utils/componentTreeState.ts | Renders that scan-refusal banner; has no notion of “run this as a pre-commit check” |
solutions/determined/experiences/polish/app/components/PolishSchemaValidationPane.vue | Polish’s own schema-validation UI, over scan_schema_validation/get_schema_validation_results |
solutions/determined/crates/determined-platform/src/api/v1/polish_schema.rs | scan_schema_validation, get_schema_validation_results; a full scan, not scoped to a commit’s changed files |
solutions/determined/packages/vault-contracts/ | @sksizer/vault-contracts, polish’s shared markdown-contract config; the schema source those endpoints validate against |
solutions/determined/crates/determined-platform/src/api/v1/settings.rs | get_namespace/set_namespace/set_value/delete_value over a whole-namespace key-value store; no “ignore this rule” convention yet |
packages/ts/app-frame/app/composables/useSettingsSection.ts | Declarative zod-mode settings persistence over that same transport; no per-vault ignore-list section |
solutions/determined/crates/determined-backup/src/git.rs | The one existing process-shelling git module; bare-repo-specific, not reusable for a live-vault commit |
Proposed
Section titled “Proposed”A Git section inside the stacked left panel (from T-SK5T-stacked-left-panel) lists changed
files, opens a diff of the selected one in the code viewer
(T-MVW5-code-editor-package), and lets the user write a message and commit through a new
git_commit op. Before the commit runs, every aspect-registered validator from
T-QGMQ-vault-facilities-decision runs against the changed paths: agent-pants contributes a
new check_vault op wrapping discover_components’s refusals (promoted out from behind
get_component_tree into its own callable check), and polish contributes its existing schema
validation. A dialog lists what each validator found: a refusal (a conflict, an unreadable
symlink) blocks the commit outright; a warning can be dismissed once or silenced permanently
per rule, with the silence recorded in the vault’s settings namespace so it survives a restart. A
changed container whose closure hash has moved gets the version-bump suggestion from
T-5CZO-version-bump-suggestions inline in the same dialog.
Approach
Section titled “Approach”- Land
check_vaultinagent-adapt-core/determined-agent-skills: a callable op that runsdiscover_components(or a narrower single-path variant) and returns its refusals and warnings as a typed list, independent ofget_component_tree’s tree response. - Define the pluggable-validator seam named by T-QGMQ-vault-facilities-decision: a trait or a
registry keyed by
VaultAspect(or by vault contents) thatcheck_vaultand polish’s schema validation both implement; the exact shape follows that task’s outcome. - Add
git_commit(vault_id, paths, message)todetermined-platform/src/api/v1/git.rs(created by T-NS6Z-vault-git-status-service), staging the given paths and committing overeasy-git/fluent-git. - Wire the validator run before
git_commitdispatches: a refusal returnsInvalidand never reaches git; a warning rides back to the caller for the dialog to render. - Add an ignore-store settings namespace (e.g.
git.ignored_rules) read throughuseSettingsSection.ts/settings.rs, keyed by rule id, so “Always ignore this rule” persists per vault. - Build the Git section’s Vue surface inside the stacked panel: file list, diff via the code viewer, message field, commit button, and the warnings dialog with Ignore once / Always ignore.
- Wire the version-bump suggestion’s commit-time half into the same dialog for containers whose closure hash changed since the last published manifest.
| Area | Note |
|---|---|
solutions/agent-pants/crates/agent-adapt-core/src/discover.rs | Expose a callable check_vault-shaped result independent of the tree walk |
solutions/determined/crates/determined-agent-skills/src/lib.rs | New check_vault op |
solutions/determined/crates/determined-platform/src/api/v1/git.rs | git_commit op (the file also carries git_status from T-NS6Z-vault-git-status-service) |
solutions/determined/crates/determined-platform/src/api/v1/settings.rs | Ignore-store namespace conventions, if the generic settings surface needs a new shape |
solutions/determined/experiences/polish/app/components/PolishSchemaValidationPane.vue | Expose its validation as a callable pre-commit contributor |
packages/ts/app-frame/app/composables/useSettingsSection.ts | Ignore-store read/write for the commit dialog |
solutions/determined/packages/shell/app/components/ShellGitPanel.vue | The Git section inside the stacked panel |
solutions/determined/packages/shell/app/components/ShellGitCommitDialog.vue | The validation-warnings and commit dialog |
Acceptance criteria
Section titled “Acceptance criteria”- AC-1: Committing a vault with an agent-pants refusal (e.g. a path collision) is blocked, and the dialog names the refused path and reason.
- AC-2: Committing a vault with only warnings succeeds after “Ignore once”, and the same warning does not block a later commit once “Always ignore this rule” is set for it.
- AC-3: A changed container whose closure hash differs from its last published manifest shows the version-bump suggestion in the commit dialog.
- AC-4: The diff for a selected changed file renders in the code viewer from T-MVW5-code-editor-package.
- AC-5:
check_vaultis callable independent ofget_component_treeand covered by a unit test asserting it surfaces the same refusalsdiscover_componentsalready tests.
Out of scope
Section titled “Out of scope”- Resolving merge conflicts; a conflicted path blocks the commit with no in-app resolution UI.
- Push, pull, branch switching, or any remote operation.
- A generic plugin API for third-party validators; only agent-pants and polish contribute this pass.
Dependencies
Section titled “Dependencies”- T-NS6Z-vault-git-status-service supplies the changed-file list and the
git.rsmodule this task extends withgit_commit. - T-SK5T-stacked-left-panel supplies the Git section’s host.
- T-MVW5-code-editor-package supplies the diff viewer.
- T-QGMQ-vault-facilities-decision names the pluggable-validator seam and the ignore-store shape.
- T-5CZO-version-bump-suggestions’s commit-time half runs inside this dialog.
Discovery context
Section titled “Discovery context”From the user’s Agent Manager planning request of 2026-09-07, expanded in
solutions/agent-pants/docs/vault/design/workflow-and-ux-assessment.md. The agent-pants half of
the validator — promoting discover_components’s refusals out from behind get_component_tree
— is grounded in solutions/agent-pants/docs/vault/research/agent-skills-conformance.md’s
finding that spec validation runs nowhere client-facing today (its gap G10).
Depends on
Section titled “Depends on”T-NS6Z-vault-git-status-service, T-SK5T-stacked-left-panel, T-MVW5-code-editor-package, T-QGMQ-vault-facilities-decision