@piagent/platform 1.3.0 → 1.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +56 -3
- package/README.md +3 -3
- package/architecture/layers.json +96 -1
- package/docs/README.md +1 -0
- package/docs/architecture.md +1 -0
- package/docs/authority-manifest.md +1 -0
- package/docs/auto-delegation-policy.md +1 -0
- package/docs/capability-packs.md +10 -2
- package/docs/command-reference-vietnamese.md +5 -4
- package/docs/context-engine.md +1 -0
- package/docs/context-window-policy.md +1 -0
- package/docs/distribution-standard.md +8 -7
- package/docs/herdr-workflow.md +1 -0
- package/docs/mcp-and-tools.md +14 -9
- package/docs/memory-policy.md +1 -0
- package/docs/model-options.md +1 -0
- package/docs/oauth-providers.md +1 -0
- package/docs/operator-manual-vietnamese.md +15 -12
- package/docs/package-architecture-notes.md +1 -0
- package/docs/project-adapters.md +1 -0
- package/docs/project-onboarding.md +1 -0
- package/docs/publishing-for-teams.md +1 -0
- package/docs/quality-benchmark.md +1 -0
- package/docs/quickstart-vietnamese.md +3 -2
- package/docs/release-install-policy.md +11 -7
- package/docs/runtime-harness-standard.md +1 -0
- package/docs/runtime-policy-design.md +1 -0
- package/docs/runtime-quality-baseline.md +1 -0
- package/docs/security-redaction-benchmark.md +1 -0
- package/docs/security-threat-model.md +2 -1
- package/docs/subagent-orchestration-capabilities.md +1 -0
- package/docs/subagents-and-multiagent.md +1 -0
- package/docs/task-implementation-contract.md +1 -0
- package/docs/task-lifecycle-vietnamese.md +1 -0
- package/docs/team-onboarding.md +3 -2
- package/docs/third-party-neutrality.md +26 -0
- package/docs/usage-observability.md +1 -0
- package/docs/vercel-docs-site.md +1 -0
- package/docs/workflow-recipes.md +1 -0
- package/docs-site/architecture.html +1 -1
- package/docs-site/benchmark.html +1 -1
- package/docs-site/commands.html +1 -1
- package/docs-site/context-engine.html +1 -1
- package/docs-site/en/architecture.html +1 -1
- package/docs-site/en/benchmark.html +1 -1
- package/docs-site/en/commands.html +1 -1
- package/docs-site/en/context-engine.html +1 -1
- package/docs-site/en/index.html +1 -1
- package/docs-site/en/mcp-approval.html +1 -1
- package/docs-site/en/mcp-auth.html +1 -1
- package/docs-site/en/mcp-servers.html +1 -1
- package/docs-site/en/mcp.html +1 -1
- package/docs-site/en/permissions.html +1 -1
- package/docs-site/en/profiles.html +1 -1
- package/docs-site/en/quickstart.html +1 -1
- package/docs-site/en/runtime.html +1 -1
- package/docs-site/en/scope.html +1 -1
- package/docs-site/en/security.html +1 -1
- package/docs-site/en/team.html +1 -1
- package/docs-site/en/whats-new.html +1 -1
- package/docs-site/en/workflows.html +1 -1
- package/docs-site/index.html +1 -1
- package/docs-site/mcp-approval.html +1 -1
- package/docs-site/mcp-auth.html +1 -1
- package/docs-site/mcp-servers.html +1 -1
- package/docs-site/mcp.html +1 -1
- package/docs-site/permissions.html +1 -1
- package/docs-site/profiles.html +1 -1
- package/docs-site/quickstart.html +1 -1
- package/docs-site/runtime.html +1 -1
- package/docs-site/scope.html +1 -1
- package/docs-site/security.html +1 -1
- package/docs-site/team.html +1 -1
- package/docs-site/whats-new.html +1 -1
- package/docs-site/workflows.html +1 -1
- package/evals/fixtures/mutation-provenance-record.invalid.json +17 -0
- package/evals/fixtures/mutation-provenance-record.valid.json +27 -0
- package/evals/fixtures/piagent-webui/approval-v1.invalid.json +54 -0
- package/evals/fixtures/piagent-webui/approval-v1.valid.json +58 -0
- package/evals/fixtures/piagent-webui/attachment-v1.invalid.json +25 -0
- package/evals/fixtures/piagent-webui/attachment-v1.valid.json +25 -0
- package/evals/fixtures/piagent-webui/capabilities-v1.invalid.json +51 -0
- package/evals/fixtures/piagent-webui/capabilities-v1.valid.json +122 -0
- package/evals/fixtures/piagent-webui/commit-summary-v1.invalid.json +10 -0
- package/evals/fixtures/piagent-webui/commit-summary-v1.valid.json +25 -0
- package/evals/fixtures/piagent-webui/control-command-v1.invalid.json +37 -0
- package/evals/fixtures/piagent-webui/control-command-v1.valid.json +35 -0
- package/evals/fixtures/piagent-webui/diff-v1.invalid.json +13 -0
- package/evals/fixtures/piagent-webui/diff-v1.valid.json +141 -0
- package/evals/fixtures/piagent-webui/gateway-capabilities-v1.invalid.json +35 -0
- package/evals/fixtures/piagent-webui/gateway-capabilities-v1.valid.json +35 -0
- package/evals/fixtures/piagent-webui/gateway-protocol-v1.invalid.json +14 -0
- package/evals/fixtures/piagent-webui/gateway-protocol-v1.valid.json +14 -0
- package/evals/fixtures/piagent-webui/handoff-history-v1.invalid.json +16 -0
- package/evals/fixtures/piagent-webui/handoff-history-v1.valid.json +16 -0
- package/evals/fixtures/piagent-webui/model-catalog-v1.invalid.json +31 -0
- package/evals/fixtures/piagent-webui/model-catalog-v1.valid.json +43 -0
- package/evals/fixtures/piagent-webui/queue-v1.invalid.json +29 -0
- package/evals/fixtures/piagent-webui/queue-v1.valid.json +44 -0
- package/evals/fixtures/piagent-webui/recovery-history-v1.invalid.json +17 -0
- package/evals/fixtures/piagent-webui/recovery-history-v1.valid.json +20 -0
- package/evals/fixtures/piagent-webui/release-monitor-v1.invalid.json +12 -0
- package/evals/fixtures/piagent-webui/release-monitor-v1.valid.json +29 -0
- package/evals/fixtures/piagent-webui/review-state-v1.invalid.json +25 -0
- package/evals/fixtures/piagent-webui/review-state-v1.valid.json +38 -0
- package/evals/fixtures/piagent-webui/runtime-event-v2.invalid.json +49 -0
- package/evals/fixtures/piagent-webui/runtime-event-v2.valid.json +49 -0
- package/evals/fixtures/piagent-webui/session-catalog-v1.invalid.json +17 -0
- package/evals/fixtures/piagent-webui/session-catalog-v1.valid.json +58 -0
- package/evals/fixtures/piagent-webui/session-command-v1.invalid.json +19 -0
- package/evals/fixtures/piagent-webui/session-command-v1.valid.json +19 -0
- package/evals/fixtures/piagent-webui/snapshot-v1.invalid.json +5 -0
- package/evals/fixtures/piagent-webui/snapshot-v1.valid.json +191 -0
- package/evals/fixtures/piagent-webui/source-change-v1.invalid.json +57 -0
- package/evals/fixtures/piagent-webui/source-change-v1.valid.json +98 -0
- package/evals/fixtures/piagent-webui/source-mutation-v1.invalid.json +19 -0
- package/evals/fixtures/piagent-webui/source-mutation-v1.valid.json +38 -0
- package/evals/fixtures/piagent-webui/source-revert-v1.invalid.json +20 -0
- package/evals/fixtures/piagent-webui/source-revert-v1.valid.json +62 -0
- package/evals/fixtures/piagent-webui/subagent-tree-v1.invalid.json +26 -0
- package/evals/fixtures/piagent-webui/subagent-tree-v1.valid.json +39 -0
- package/evals/fixtures/piagent-webui/task-index-v1.invalid.json +15 -0
- package/evals/fixtures/piagent-webui/task-index-v1.valid.json +15 -0
- package/evals/fixtures/piagent-webui/task-timeline-v1.invalid.json +14 -0
- package/evals/fixtures/piagent-webui/task-timeline-v1.valid.json +16 -0
- package/evals/fixtures/piagent-webui/transcript-v1.invalid.json +35 -0
- package/evals/fixtures/piagent-webui/transcript-v1.valid.json +55 -0
- package/evals/fixtures/task-baseline-manifest.invalid.json +16 -0
- package/evals/fixtures/task-baseline-manifest.valid.json +41 -0
- package/evals/fixtures/verifier-file-snapshot.invalid.json +21 -0
- package/evals/fixtures/verifier-file-snapshot.valid.json +21 -0
- package/package.json +30 -3
- package/packages/piagent-core/benchmark/benchmark-candidate.d.ts +1 -0
- package/packages/piagent-core/benchmark/benchmark-forensics.d.ts +1 -0
- package/packages/piagent-core/benchmark/benchmark-ledger.d.ts +4 -0
- package/packages/piagent-core/benchmark/benchmark-record-validation.d.ts +1 -0
- package/packages/piagent-core/benchmark/benchmark-runtime.d.ts +1 -0
- package/packages/piagent-core/capabilities/capability-core.js +2 -2
- package/packages/piagent-core/capabilities/capability-verification-cache.js +280 -0
- package/packages/piagent-core/capabilities/runtime-integrity.js +153 -1
- package/packages/piagent-core/extensions/document-intake.ts +24 -10
- package/packages/piagent-core/extensions/piagent-guard.ts +90 -73
- package/packages/piagent-core/extensions/redaction-core.d.ts +2 -0
- package/packages/piagent-core/extensions/state-retention.js +77 -44
- package/packages/piagent-core/extensions/task-journal.js +30 -1
- package/packages/piagent-core/extensions/task-state.js +33 -36
- package/packages/piagent-core/mcp/mcp-server-catalog.js +5 -5
- package/packages/piagent-core/package.json +1 -1
- package/packages/piagent-core/runtime/hooks/session-start-hook.ts +2 -2
- package/packages/piagent-core/runtime/hooks/tool-call-hook.ts +5 -2
- package/packages/piagent-core/runtime/hooks/tool-result-hook.ts +20 -19
- package/packages/piagent-core/runtime/hooks/tool-result-metadata.ts +13 -0
- package/packages/piagent-core/runtime/input/chat-images.ts +2 -2
- package/packages/piagent-core/runtime/inspection/activity-event-adapter.ts +94 -0
- package/packages/piagent-core/runtime/inspection/approval-broker.ts +318 -0
- package/packages/piagent-core/runtime/inspection/commit-summary-projection.ts +59 -0
- package/packages/piagent-core/runtime/inspection/context-telemetry-inspection.ts +37 -0
- package/packages/piagent-core/runtime/inspection/criteria-links.ts +295 -0
- package/packages/piagent-core/runtime/inspection/diff-projection.ts +499 -0
- package/packages/piagent-core/runtime/inspection/git-filter-safety.ts +38 -0
- package/packages/piagent-core/runtime/inspection/git-numstat-adapter.ts +71 -0
- package/packages/piagent-core/runtime/inspection/git-status-adapter.ts +493 -0
- package/packages/piagent-core/runtime/inspection/git-tree-adapter.ts +108 -0
- package/packages/piagent-core/runtime/inspection/mcp-control.ts +10 -0
- package/packages/piagent-core/runtime/inspection/mutation-provenance-contract.ts +131 -0
- package/packages/piagent-core/runtime/inspection/mutation-provenance-recorder.ts +48 -0
- package/packages/piagent-core/runtime/inspection/mutation-provenance-store.ts +161 -0
- package/packages/piagent-core/runtime/inspection/project-runtime-inspection.ts +36 -0
- package/packages/piagent-core/runtime/inspection/review-state-contract.ts +108 -0
- package/packages/piagent-core/runtime/inspection/review-state-projection.ts +93 -0
- package/packages/piagent-core/runtime/inspection/review-state-store.ts +112 -0
- package/packages/piagent-core/runtime/inspection/runtime-event-store.ts +262 -0
- package/packages/piagent-core/runtime/inspection/same-process-bridge-proof.ts +103 -0
- package/packages/piagent-core/runtime/inspection/source-change-projection.ts +471 -0
- package/packages/piagent-core/runtime/inspection/source-evidence-contract.ts +139 -0
- package/packages/piagent-core/runtime/inspection/source-evidence-store.ts +315 -0
- package/packages/piagent-core/runtime/inspection/source-handoff-store.ts +70 -0
- package/packages/piagent-core/runtime/inspection/source-inspection-plan.ts +34 -0
- package/packages/piagent-core/runtime/inspection/source-mutation-projection.ts +164 -0
- package/packages/piagent-core/runtime/inspection/source-mutation-store.ts +168 -0
- package/packages/piagent-core/runtime/inspection/source-open-target.ts +38 -0
- package/packages/piagent-core/runtime/inspection/source-revert-projection.ts +147 -0
- package/packages/piagent-core/runtime/inspection/task-baseline-start-capture.ts +22 -0
- package/packages/piagent-core/runtime/inspection/task-compaction-history.ts +160 -0
- package/packages/piagent-core/runtime/inspection/task-control-journal.ts +131 -0
- package/packages/piagent-core/runtime/inspection/task-handoff-history.ts +95 -0
- package/packages/piagent-core/runtime/inspection/task-provenance-projection.ts +60 -0
- package/packages/piagent-core/runtime/inspection/task-recovery-timeline.ts +88 -0
- package/packages/piagent-core/runtime/inspection/task-run-index.ts +87 -0
- package/packages/piagent-core/runtime/inspection/task-source-projection.ts +401 -0
- package/packages/piagent-core/runtime/inspection/task-subagent-tree.ts +101 -0
- package/packages/piagent-core/runtime/inspection/text-diff.ts +60 -0
- package/packages/piagent-core/runtime/inspection/verifier-snapshot-contract.ts +114 -0
- package/packages/piagent-core/runtime/inspection/verifier-snapshot-store.ts +189 -0
- package/packages/piagent-core/runtime/inspection/webui-snapshot.ts +320 -0
- package/packages/piagent-core/runtime/inspection/workspace-file-reader.ts +132 -0
- package/packages/piagent-core/runtime/inspection/workspace-source-projection.ts +96 -0
- package/packages/piagent-core/runtime/inspection/zero-turn-conformance.ts +175 -0
- package/packages/piagent-core/runtime/orchestration/owned-work-budget.ts +68 -4
- package/packages/piagent-core/runtime/policy/source-index-transaction.ts +173 -0
- package/packages/piagent-core/runtime/policy/source-mutation-guard-binding.ts +42 -0
- package/packages/piagent-core/runtime/policy/source-mutation-guard.ts +184 -0
- package/packages/piagent-core/runtime/policy/source-worktree-transaction.ts +105 -0
- package/packages/piagent-core/runtime/product/activity-inspector-footer.ts +5 -3
- package/packages/piagent-core/runtime/product/activity-inspector.ts +85 -343
- package/packages/piagent-core/runtime/recovery/resume-state.ts +38 -1
- package/packages/piagent-core/runtime/registration/activity-inspector-command.ts +68 -14
- package/packages/piagent-core/runtime/registration/task-start-tool.ts +13 -14
- package/packages/piagent-core/runtime/session/model-authorship-state.ts +31 -3
- package/packages/piagent-core/runtime/session/runtime-state.ts +11 -1
- package/packages/piagent-webui/dist/client/assets/index-DjMntaK5.js +172 -0
- package/packages/piagent-webui/dist/client/assets/index-DwKCWbwd.css +1 -0
- package/packages/piagent-webui/dist/client/index.html +16 -0
- package/packages/piagent-webui/extension/attachment-store.ts +323 -0
- package/packages/piagent-webui/extension/held-message-queue.ts +311 -0
- package/packages/piagent-webui/extension/lifecycle-controller.ts +408 -0
- package/packages/piagent-webui/extension/lifecycle-event-adapter.ts +23 -0
- package/packages/piagent-webui/extension/piagent-webui.ts +470 -0
- package/packages/piagent-webui/extension/review-controller.ts +160 -0
- package/packages/piagent-webui/extension/same-session-bridge.ts +500 -0
- package/packages/piagent-webui/extension/session-options-controller.ts +281 -0
- package/packages/piagent-webui/extension/session-stream-adapter.ts +249 -0
- package/packages/piagent-webui/extension/source-mutation-controller.ts +215 -0
- package/packages/piagent-webui/extension/source-open-controller.ts +136 -0
- package/packages/piagent-webui/extension/source-revert-controller.ts +189 -0
- package/packages/piagent-webui/extension/terminal-session-adapter.ts +73 -0
- package/packages/piagent-webui/extension/vscode-handoff.ts +51 -0
- package/packages/piagent-webui/gateway/control-socket.ts +92 -0
- package/packages/piagent-webui/gateway/gateway-events.ts +60 -0
- package/packages/piagent-webui/gateway/gateway-protocol-service.ts +64 -0
- package/packages/piagent-webui/gateway/gateway-service.ts +215 -0
- package/packages/piagent-webui/gateway/gateway-session-stream.ts +110 -0
- package/packages/piagent-webui/gateway/mcp-auth-broker.ts +158 -0
- package/packages/piagent-webui/gateway/native-project-picker.ts +29 -0
- package/packages/piagent-webui/gateway/pi-host.ts +41 -0
- package/packages/piagent-webui/gateway/profile-state.ts +1 -0
- package/packages/piagent-webui/gateway/project-registry.ts +108 -0
- package/packages/piagent-webui/gateway/provider-auth-broker.ts +172 -0
- package/packages/piagent-webui/gateway/session-catalog.ts +128 -0
- package/packages/piagent-webui/gateway/session-command-controller.ts +237 -0
- package/packages/piagent-webui/gateway/session-command-store.ts +224 -0
- package/packages/piagent-webui/gateway/session-inspection-registry.ts +204 -0
- package/packages/piagent-webui/gateway/session-lease-store.ts +1 -0
- package/packages/piagent-webui/gateway/session-metadata-store.ts +152 -0
- package/packages/piagent-webui/gateway/session-runtime-supervisor.ts +485 -0
- package/packages/piagent-webui/ownership/gateway-runtime-context.ts +8 -0
- package/packages/piagent-webui/ownership/profile-state.ts +117 -0
- package/packages/piagent-webui/ownership/session-lease-store.ts +329 -0
- package/packages/piagent-webui/ownership/session-refs.ts +8 -0
- package/packages/piagent-webui/package.json +33 -0
- package/packages/piagent-webui/server/README.md +4 -0
- package/packages/piagent-webui/server/benchmark-release-monitor.ts +230 -0
- package/packages/piagent-webui/server/core-inspection-provider.ts +403 -0
- package/packages/piagent-webui/server/gateway-websocket.ts +143 -0
- package/packages/piagent-webui/server/http-security.ts +27 -0
- package/packages/piagent-webui/server/ipc-read-model-client.ts +89 -0
- package/packages/piagent-webui/server/loopback-server.ts +368 -0
- package/packages/piagent-webui/server/read-model-provider.ts +37 -0
- package/packages/piagent-webui/server/read-only-router.ts +105 -0
- package/packages/piagent-webui/server/session-auth.ts +88 -0
- package/packages/piagent-webui/server/sidecar-main.ts +86 -0
- package/packages/piagent-webui/server/sse-hub.ts +76 -0
- package/packages/piagent-webui/server/static-bundle.ts +40 -0
- package/packages/piagent-webui/server/transcript-projection.ts +110 -0
- package/schemas/mutation-provenance-record.schema.json +100 -0
- package/schemas/piagent-webui/approval-v1.schema.json +654 -0
- package/schemas/piagent-webui/attachment-v1.schema.json +267 -0
- package/schemas/piagent-webui/capabilities-v1.schema.json +729 -0
- package/schemas/piagent-webui/catalog-v1.json +240 -0
- package/schemas/piagent-webui/commit-summary-v1.schema.json +63 -0
- package/schemas/piagent-webui/common-v1.schema.json +479 -0
- package/schemas/piagent-webui/control-command-v1.schema.json +1780 -0
- package/schemas/piagent-webui/diff-v1.schema.json +826 -0
- package/schemas/piagent-webui/gateway-capabilities-v1.schema.json +136 -0
- package/schemas/piagent-webui/gateway-protocol-v1.schema.json +456 -0
- package/schemas/piagent-webui/handoff-history-v1.schema.json +92 -0
- package/schemas/piagent-webui/model-catalog-v1.schema.json +95 -0
- package/schemas/piagent-webui/queue-v1.schema.json +99 -0
- package/schemas/piagent-webui/recovery-history-v1.schema.json +144 -0
- package/schemas/piagent-webui/release-monitor-v1.schema.json +173 -0
- package/schemas/piagent-webui/review-state-v1.schema.json +206 -0
- package/schemas/piagent-webui/runtime-event-v2.schema.json +5206 -0
- package/schemas/piagent-webui/session-catalog-v1.schema.json +222 -0
- package/schemas/piagent-webui/session-command-v1.schema.json +390 -0
- package/schemas/piagent-webui/snapshot-v1.schema.json +2622 -0
- package/schemas/piagent-webui/source-change-v1.schema.json +763 -0
- package/schemas/piagent-webui/source-mutation-v1.schema.json +96 -0
- package/schemas/piagent-webui/source-revert-v1.schema.json +130 -0
- package/schemas/piagent-webui/subagent-tree-v1.schema.json +88 -0
- package/schemas/piagent-webui/task-index-v1.schema.json +74 -0
- package/schemas/piagent-webui/task-timeline-v1.schema.json +49 -0
- package/schemas/piagent-webui/transcript-v1.schema.json +243 -0
- package/schemas/task-baseline-manifest.schema.json +122 -0
- package/schemas/verifier-file-snapshot.schema.json +81 -0
- package/scripts/check-architecture.mjs +1 -0
- package/scripts/check-doc-languages.mjs +19 -2
- package/scripts/check-third-party-neutrality.mjs +43 -0
- package/scripts/install-global.sh +1 -1
- package/scripts/piagent-cli.mjs +17 -3
- package/scripts/piagent-dashboard.mjs +208 -0
- package/scripts/piagent-webui-launcher.mjs +121 -0
- package/scripts/typescript-loader.mjs +26 -1
- package/scripts/verify-local.sh +253 -0
- package/scripts/verify-release-identity.mjs +4 -1
|
@@ -0,0 +1,763 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://piagent.io.vn/schemas/piagent-webui/source-change-v1.schema.json",
|
|
4
|
+
"title": "Piagent WebUI source change view v1",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"additionalProperties": false,
|
|
7
|
+
"required": [
|
|
8
|
+
"schemaVersion",
|
|
9
|
+
"version",
|
|
10
|
+
"generatedAt",
|
|
11
|
+
"identity",
|
|
12
|
+
"view",
|
|
13
|
+
"viewRevision",
|
|
14
|
+
"bases",
|
|
15
|
+
"availability",
|
|
16
|
+
"files",
|
|
17
|
+
"page",
|
|
18
|
+
"truncationReason",
|
|
19
|
+
"redaction",
|
|
20
|
+
"health",
|
|
21
|
+
"issues"
|
|
22
|
+
],
|
|
23
|
+
"properties": {
|
|
24
|
+
"schemaVersion": { "const": 1 },
|
|
25
|
+
"version": { "const": "piagent-webui-source-change-v1" },
|
|
26
|
+
"generatedAt": { "$ref": "common-v1.schema.json#/$defs/timestamp" },
|
|
27
|
+
"identity": { "$ref": "common-v1.schema.json#/$defs/identity" },
|
|
28
|
+
"view": { "$ref": "#/$defs/view" },
|
|
29
|
+
"viewRevision": { "$ref": "common-v1.schema.json#/$defs/revisionToken" },
|
|
30
|
+
"bases": {
|
|
31
|
+
"type": "array",
|
|
32
|
+
"minItems": 1,
|
|
33
|
+
"maxItems": 32,
|
|
34
|
+
"items": { "$ref": "#/$defs/viewBasis" }
|
|
35
|
+
},
|
|
36
|
+
"availability": { "$ref": "#/$defs/availability" },
|
|
37
|
+
"files": {
|
|
38
|
+
"type": "array",
|
|
39
|
+
"maxItems": 2000,
|
|
40
|
+
"items": { "$ref": "#/$defs/fileChange" }
|
|
41
|
+
},
|
|
42
|
+
"page": { "$ref": "common-v1.schema.json#/$defs/page" },
|
|
43
|
+
"truncationReason": { "$ref": "common-v1.schema.json#/$defs/nullableReasonCode" },
|
|
44
|
+
"redaction": { "$ref": "common-v1.schema.json#/$defs/redaction" },
|
|
45
|
+
"health": { "$ref": "common-v1.schema.json#/$defs/health" },
|
|
46
|
+
"issues": {
|
|
47
|
+
"type": "array",
|
|
48
|
+
"maxItems": 64,
|
|
49
|
+
"items": { "$ref": "common-v1.schema.json#/$defs/issue" }
|
|
50
|
+
}
|
|
51
|
+
},
|
|
52
|
+
"allOf": [
|
|
53
|
+
{
|
|
54
|
+
"if": {
|
|
55
|
+
"type": "object",
|
|
56
|
+
"properties": { "view": { "const": "task" } },
|
|
57
|
+
"required": ["view"]
|
|
58
|
+
},
|
|
59
|
+
"then": {
|
|
60
|
+
"type": "object",
|
|
61
|
+
"properties": {
|
|
62
|
+
"identity": {
|
|
63
|
+
"type": "object",
|
|
64
|
+
"properties": {
|
|
65
|
+
"taskId": { "$ref": "common-v1.schema.json#/$defs/publicId" },
|
|
66
|
+
"taskRunId": { "$ref": "common-v1.schema.json#/$defs/publicId" }
|
|
67
|
+
}
|
|
68
|
+
},
|
|
69
|
+
"bases": { "type": "array", "items": { "$ref": "#/$defs/taskBasis" } }
|
|
70
|
+
}
|
|
71
|
+
}
|
|
72
|
+
},
|
|
73
|
+
{
|
|
74
|
+
"if": {
|
|
75
|
+
"type": "object",
|
|
76
|
+
"properties": { "view": { "const": "working-tree" } },
|
|
77
|
+
"required": ["view"]
|
|
78
|
+
},
|
|
79
|
+
"then": {
|
|
80
|
+
"type": "object",
|
|
81
|
+
"properties": {
|
|
82
|
+
"bases": { "type": "array", "items": { "$ref": "#/$defs/workingTreeBasis" } }
|
|
83
|
+
}
|
|
84
|
+
}
|
|
85
|
+
},
|
|
86
|
+
{
|
|
87
|
+
"if": {
|
|
88
|
+
"type": "object",
|
|
89
|
+
"properties": { "view": { "const": "staged" } },
|
|
90
|
+
"required": ["view"]
|
|
91
|
+
},
|
|
92
|
+
"then": {
|
|
93
|
+
"type": "object",
|
|
94
|
+
"properties": {
|
|
95
|
+
"bases": { "type": "array", "items": { "$ref": "#/$defs/stagedBasis" } },
|
|
96
|
+
"files": {
|
|
97
|
+
"type": "array",
|
|
98
|
+
"items": {
|
|
99
|
+
"type": "object",
|
|
100
|
+
"properties": {
|
|
101
|
+
"status": { "enum": ["A", "M", "D", "R", "C"] }
|
|
102
|
+
}
|
|
103
|
+
}
|
|
104
|
+
}
|
|
105
|
+
}
|
|
106
|
+
}
|
|
107
|
+
},
|
|
108
|
+
{
|
|
109
|
+
"if": {
|
|
110
|
+
"type": "object",
|
|
111
|
+
"properties": {
|
|
112
|
+
"availability": {
|
|
113
|
+
"type": "object",
|
|
114
|
+
"properties": { "state": { "const": "unavailable" } },
|
|
115
|
+
"required": ["state"]
|
|
116
|
+
}
|
|
117
|
+
},
|
|
118
|
+
"required": ["availability"]
|
|
119
|
+
},
|
|
120
|
+
"then": {
|
|
121
|
+
"type": "object",
|
|
122
|
+
"properties": {
|
|
123
|
+
"files": { "type": "array", "maxItems": 0 },
|
|
124
|
+
"page": {
|
|
125
|
+
"type": "object",
|
|
126
|
+
"properties": {
|
|
127
|
+
"total": { "const": 0 },
|
|
128
|
+
"returned": { "const": 0 },
|
|
129
|
+
"truncated": { "const": false },
|
|
130
|
+
"nextCursor": { "type": "null" }
|
|
131
|
+
}
|
|
132
|
+
},
|
|
133
|
+
"truncationReason": { "type": "null" }
|
|
134
|
+
}
|
|
135
|
+
}
|
|
136
|
+
},
|
|
137
|
+
{
|
|
138
|
+
"if": {
|
|
139
|
+
"type": "object",
|
|
140
|
+
"properties": {
|
|
141
|
+
"page": {
|
|
142
|
+
"type": "object",
|
|
143
|
+
"properties": { "truncated": { "const": true } },
|
|
144
|
+
"required": ["truncated"]
|
|
145
|
+
}
|
|
146
|
+
},
|
|
147
|
+
"required": ["page"]
|
|
148
|
+
},
|
|
149
|
+
"then": {
|
|
150
|
+
"type": "object",
|
|
151
|
+
"properties": {
|
|
152
|
+
"page": {
|
|
153
|
+
"type": "object",
|
|
154
|
+
"properties": {
|
|
155
|
+
"nextCursor": { "$ref": "common-v1.schema.json#/$defs/revisionToken" }
|
|
156
|
+
}
|
|
157
|
+
},
|
|
158
|
+
"truncationReason": { "$ref": "common-v1.schema.json#/$defs/reasonCode" }
|
|
159
|
+
}
|
|
160
|
+
},
|
|
161
|
+
"else": {
|
|
162
|
+
"type": "object",
|
|
163
|
+
"properties": {
|
|
164
|
+
"page": {
|
|
165
|
+
"type": "object",
|
|
166
|
+
"properties": { "nextCursor": { "type": "null" } }
|
|
167
|
+
},
|
|
168
|
+
"truncationReason": { "type": "null" }
|
|
169
|
+
}
|
|
170
|
+
}
|
|
171
|
+
}
|
|
172
|
+
],
|
|
173
|
+
"$defs": {
|
|
174
|
+
"view": {
|
|
175
|
+
"enum": ["task", "working-tree", "staged"]
|
|
176
|
+
},
|
|
177
|
+
"availability": {
|
|
178
|
+
"type": "object",
|
|
179
|
+
"additionalProperties": false,
|
|
180
|
+
"required": ["state", "reasonCode", "message"],
|
|
181
|
+
"properties": {
|
|
182
|
+
"state": { "enum": ["current", "stale", "unavailable"] },
|
|
183
|
+
"reasonCode": { "$ref": "common-v1.schema.json#/$defs/nullableReasonCode" },
|
|
184
|
+
"message": { "$ref": "common-v1.schema.json#/$defs/nullableDisplayText" }
|
|
185
|
+
},
|
|
186
|
+
"allOf": [
|
|
187
|
+
{
|
|
188
|
+
"if": {
|
|
189
|
+
"type": "object",
|
|
190
|
+
"properties": { "state": { "const": "current" } },
|
|
191
|
+
"required": ["state"]
|
|
192
|
+
},
|
|
193
|
+
"then": {
|
|
194
|
+
"type": "object",
|
|
195
|
+
"properties": { "reasonCode": { "type": "null" } }
|
|
196
|
+
},
|
|
197
|
+
"else": {
|
|
198
|
+
"type": "object",
|
|
199
|
+
"properties": {
|
|
200
|
+
"reasonCode": { "$ref": "common-v1.schema.json#/$defs/reasonCode" }
|
|
201
|
+
}
|
|
202
|
+
}
|
|
203
|
+
}
|
|
204
|
+
]
|
|
205
|
+
},
|
|
206
|
+
"taskBasis": {
|
|
207
|
+
"type": "object",
|
|
208
|
+
"additionalProperties": false,
|
|
209
|
+
"required": [
|
|
210
|
+
"basisRef",
|
|
211
|
+
"repoRef",
|
|
212
|
+
"view",
|
|
213
|
+
"state",
|
|
214
|
+
"reasonCode",
|
|
215
|
+
"basisRevision",
|
|
216
|
+
"taskRunId",
|
|
217
|
+
"taskRevision",
|
|
218
|
+
"workspaceRevision",
|
|
219
|
+
"baselineManifestRef",
|
|
220
|
+
"baselineTreeDigest"
|
|
221
|
+
],
|
|
222
|
+
"properties": {
|
|
223
|
+
"basisRef": { "$ref": "common-v1.schema.json#/$defs/opaqueRef" },
|
|
224
|
+
"repoRef": { "$ref": "common-v1.schema.json#/$defs/opaqueRef" },
|
|
225
|
+
"view": { "const": "task" },
|
|
226
|
+
"state": { "enum": ["current", "stale", "unavailable"] },
|
|
227
|
+
"reasonCode": { "$ref": "common-v1.schema.json#/$defs/nullableReasonCode" },
|
|
228
|
+
"basisRevision": { "$ref": "common-v1.schema.json#/$defs/revisionToken" },
|
|
229
|
+
"taskRunId": { "$ref": "common-v1.schema.json#/$defs/publicId" },
|
|
230
|
+
"taskRevision": { "$ref": "common-v1.schema.json#/$defs/revisionToken" },
|
|
231
|
+
"workspaceRevision": { "$ref": "common-v1.schema.json#/$defs/revisionToken" },
|
|
232
|
+
"baselineManifestRef": { "$ref": "common-v1.schema.json#/$defs/nullableOpaqueRef" },
|
|
233
|
+
"baselineTreeDigest": { "$ref": "common-v1.schema.json#/$defs/nullableWorkingTreeDigest" }
|
|
234
|
+
},
|
|
235
|
+
"allOf": [
|
|
236
|
+
{
|
|
237
|
+
"if": {
|
|
238
|
+
"type": "object",
|
|
239
|
+
"properties": { "state": { "const": "current" } },
|
|
240
|
+
"required": ["state"]
|
|
241
|
+
},
|
|
242
|
+
"then": {
|
|
243
|
+
"type": "object",
|
|
244
|
+
"properties": {
|
|
245
|
+
"reasonCode": { "type": "null" },
|
|
246
|
+
"baselineManifestRef": { "$ref": "common-v1.schema.json#/$defs/opaqueRef" },
|
|
247
|
+
"baselineTreeDigest": { "$ref": "common-v1.schema.json#/$defs/workingTreeDigest" }
|
|
248
|
+
}
|
|
249
|
+
},
|
|
250
|
+
"else": {
|
|
251
|
+
"type": "object",
|
|
252
|
+
"properties": {
|
|
253
|
+
"reasonCode": { "$ref": "common-v1.schema.json#/$defs/reasonCode" }
|
|
254
|
+
}
|
|
255
|
+
}
|
|
256
|
+
}
|
|
257
|
+
]
|
|
258
|
+
},
|
|
259
|
+
"workingTreeBasis": {
|
|
260
|
+
"type": "object",
|
|
261
|
+
"additionalProperties": false,
|
|
262
|
+
"required": [
|
|
263
|
+
"basisRef",
|
|
264
|
+
"repoRef",
|
|
265
|
+
"view",
|
|
266
|
+
"state",
|
|
267
|
+
"reasonCode",
|
|
268
|
+
"basisRevision",
|
|
269
|
+
"headState",
|
|
270
|
+
"headRef",
|
|
271
|
+
"workspaceRevision",
|
|
272
|
+
"indexRevision"
|
|
273
|
+
],
|
|
274
|
+
"properties": {
|
|
275
|
+
"basisRef": { "$ref": "common-v1.schema.json#/$defs/opaqueRef" },
|
|
276
|
+
"repoRef": { "$ref": "common-v1.schema.json#/$defs/opaqueRef" },
|
|
277
|
+
"view": { "const": "working-tree" },
|
|
278
|
+
"state": { "enum": ["current", "stale", "unavailable"] },
|
|
279
|
+
"reasonCode": { "$ref": "common-v1.schema.json#/$defs/nullableReasonCode" },
|
|
280
|
+
"basisRevision": { "$ref": "common-v1.schema.json#/$defs/revisionToken" },
|
|
281
|
+
"headState": { "enum": ["head", "unborn", "unavailable"] },
|
|
282
|
+
"headRef": { "$ref": "common-v1.schema.json#/$defs/nullableOpaqueRef" },
|
|
283
|
+
"workspaceRevision": { "$ref": "common-v1.schema.json#/$defs/revisionToken" },
|
|
284
|
+
"indexRevision": { "$ref": "common-v1.schema.json#/$defs/revisionToken" }
|
|
285
|
+
},
|
|
286
|
+
"allOf": [
|
|
287
|
+
{
|
|
288
|
+
"if": {
|
|
289
|
+
"type": "object",
|
|
290
|
+
"properties": { "headState": { "const": "head" } },
|
|
291
|
+
"required": ["headState"]
|
|
292
|
+
},
|
|
293
|
+
"then": {
|
|
294
|
+
"type": "object",
|
|
295
|
+
"properties": { "headRef": { "$ref": "common-v1.schema.json#/$defs/opaqueRef" } }
|
|
296
|
+
},
|
|
297
|
+
"else": {
|
|
298
|
+
"type": "object",
|
|
299
|
+
"properties": { "headRef": { "type": "null" } }
|
|
300
|
+
}
|
|
301
|
+
},
|
|
302
|
+
{
|
|
303
|
+
"if": {
|
|
304
|
+
"type": "object",
|
|
305
|
+
"properties": { "state": { "const": "current" } },
|
|
306
|
+
"required": ["state"]
|
|
307
|
+
},
|
|
308
|
+
"then": {
|
|
309
|
+
"type": "object",
|
|
310
|
+
"properties": {
|
|
311
|
+
"reasonCode": { "type": "null" },
|
|
312
|
+
"headState": { "enum": ["head", "unborn"] }
|
|
313
|
+
}
|
|
314
|
+
},
|
|
315
|
+
"else": {
|
|
316
|
+
"type": "object",
|
|
317
|
+
"properties": {
|
|
318
|
+
"reasonCode": { "$ref": "common-v1.schema.json#/$defs/reasonCode" }
|
|
319
|
+
}
|
|
320
|
+
}
|
|
321
|
+
}
|
|
322
|
+
]
|
|
323
|
+
},
|
|
324
|
+
"stagedBasis": {
|
|
325
|
+
"type": "object",
|
|
326
|
+
"additionalProperties": false,
|
|
327
|
+
"required": [
|
|
328
|
+
"basisRef",
|
|
329
|
+
"repoRef",
|
|
330
|
+
"view",
|
|
331
|
+
"state",
|
|
332
|
+
"reasonCode",
|
|
333
|
+
"basisRevision",
|
|
334
|
+
"headState",
|
|
335
|
+
"headRef",
|
|
336
|
+
"indexRevision",
|
|
337
|
+
"workspaceRevision"
|
|
338
|
+
],
|
|
339
|
+
"properties": {
|
|
340
|
+
"basisRef": { "$ref": "common-v1.schema.json#/$defs/opaqueRef" },
|
|
341
|
+
"repoRef": { "$ref": "common-v1.schema.json#/$defs/opaqueRef" },
|
|
342
|
+
"view": { "const": "staged" },
|
|
343
|
+
"state": { "enum": ["current", "stale", "unavailable"] },
|
|
344
|
+
"reasonCode": { "$ref": "common-v1.schema.json#/$defs/nullableReasonCode" },
|
|
345
|
+
"basisRevision": { "$ref": "common-v1.schema.json#/$defs/revisionToken" },
|
|
346
|
+
"headState": { "enum": ["head", "unborn", "unavailable"] },
|
|
347
|
+
"headRef": { "$ref": "common-v1.schema.json#/$defs/nullableOpaqueRef" },
|
|
348
|
+
"indexRevision": { "$ref": "common-v1.schema.json#/$defs/revisionToken" },
|
|
349
|
+
"workspaceRevision": { "$ref": "common-v1.schema.json#/$defs/nullableRevisionToken" }
|
|
350
|
+
},
|
|
351
|
+
"allOf": [
|
|
352
|
+
{
|
|
353
|
+
"if": {
|
|
354
|
+
"type": "object",
|
|
355
|
+
"properties": { "headState": { "const": "head" } },
|
|
356
|
+
"required": ["headState"]
|
|
357
|
+
},
|
|
358
|
+
"then": {
|
|
359
|
+
"type": "object",
|
|
360
|
+
"properties": { "headRef": { "$ref": "common-v1.schema.json#/$defs/opaqueRef" } }
|
|
361
|
+
},
|
|
362
|
+
"else": {
|
|
363
|
+
"type": "object",
|
|
364
|
+
"properties": { "headRef": { "type": "null" } }
|
|
365
|
+
}
|
|
366
|
+
},
|
|
367
|
+
{
|
|
368
|
+
"if": {
|
|
369
|
+
"type": "object",
|
|
370
|
+
"properties": { "state": { "const": "current" } },
|
|
371
|
+
"required": ["state"]
|
|
372
|
+
},
|
|
373
|
+
"then": {
|
|
374
|
+
"type": "object",
|
|
375
|
+
"properties": {
|
|
376
|
+
"reasonCode": { "type": "null" },
|
|
377
|
+
"headState": { "enum": ["head", "unborn"] }
|
|
378
|
+
}
|
|
379
|
+
},
|
|
380
|
+
"else": {
|
|
381
|
+
"type": "object",
|
|
382
|
+
"properties": {
|
|
383
|
+
"reasonCode": { "$ref": "common-v1.schema.json#/$defs/reasonCode" }
|
|
384
|
+
}
|
|
385
|
+
}
|
|
386
|
+
}
|
|
387
|
+
]
|
|
388
|
+
},
|
|
389
|
+
"viewBasis": {
|
|
390
|
+
"oneOf": [
|
|
391
|
+
{ "$ref": "#/$defs/taskBasis" },
|
|
392
|
+
{ "$ref": "#/$defs/workingTreeBasis" },
|
|
393
|
+
{ "$ref": "#/$defs/stagedBasis" }
|
|
394
|
+
]
|
|
395
|
+
},
|
|
396
|
+
"rawGitStatus": {
|
|
397
|
+
"anyOf": [
|
|
398
|
+
{ "enum": [".", "M", "T", "A", "D", "R", "C", "U", "?", "!"] },
|
|
399
|
+
{ "type": "null" }
|
|
400
|
+
]
|
|
401
|
+
},
|
|
402
|
+
"gitState": {
|
|
403
|
+
"type": "object",
|
|
404
|
+
"additionalProperties": false,
|
|
405
|
+
"required": ["indexStatus", "worktreeStatus", "conflict"],
|
|
406
|
+
"properties": {
|
|
407
|
+
"indexStatus": { "$ref": "#/$defs/rawGitStatus" },
|
|
408
|
+
"worktreeStatus": { "$ref": "#/$defs/rawGitStatus" },
|
|
409
|
+
"conflict": { "type": "boolean" }
|
|
410
|
+
}
|
|
411
|
+
},
|
|
412
|
+
"contentState": {
|
|
413
|
+
"type": "object",
|
|
414
|
+
"additionalProperties": false,
|
|
415
|
+
"required": ["kind", "access", "reasonCode"],
|
|
416
|
+
"properties": {
|
|
417
|
+
"kind": { "enum": ["text", "binary", "symlink", "submodule", "unknown"] },
|
|
418
|
+
"access": { "enum": ["available", "protected", "oversized", "unavailable"] },
|
|
419
|
+
"reasonCode": { "$ref": "common-v1.schema.json#/$defs/nullableReasonCode" }
|
|
420
|
+
},
|
|
421
|
+
"allOf": [
|
|
422
|
+
{
|
|
423
|
+
"if": {
|
|
424
|
+
"type": "object",
|
|
425
|
+
"properties": { "access": { "const": "available" } },
|
|
426
|
+
"required": ["access"]
|
|
427
|
+
},
|
|
428
|
+
"then": {
|
|
429
|
+
"type": "object",
|
|
430
|
+
"properties": {
|
|
431
|
+
"kind": { "enum": ["text", "binary", "symlink", "submodule"] },
|
|
432
|
+
"reasonCode": { "type": "null" }
|
|
433
|
+
}
|
|
434
|
+
},
|
|
435
|
+
"else": {
|
|
436
|
+
"type": "object",
|
|
437
|
+
"properties": {
|
|
438
|
+
"reasonCode": { "$ref": "common-v1.schema.json#/$defs/reasonCode" }
|
|
439
|
+
}
|
|
440
|
+
}
|
|
441
|
+
}
|
|
442
|
+
]
|
|
443
|
+
},
|
|
444
|
+
"lineStats": {
|
|
445
|
+
"type": "object",
|
|
446
|
+
"additionalProperties": false,
|
|
447
|
+
"required": ["state", "additions", "deletions", "reasonCode"],
|
|
448
|
+
"properties": {
|
|
449
|
+
"state": { "enum": ["exact", "unavailable"] },
|
|
450
|
+
"additions": {
|
|
451
|
+
"anyOf": [
|
|
452
|
+
{ "type": "integer", "minimum": 0, "maximum": 10000000 },
|
|
453
|
+
{ "type": "null" }
|
|
454
|
+
]
|
|
455
|
+
},
|
|
456
|
+
"deletions": {
|
|
457
|
+
"anyOf": [
|
|
458
|
+
{ "type": "integer", "minimum": 0, "maximum": 10000000 },
|
|
459
|
+
{ "type": "null" }
|
|
460
|
+
]
|
|
461
|
+
},
|
|
462
|
+
"reasonCode": { "$ref": "common-v1.schema.json#/$defs/nullableReasonCode" }
|
|
463
|
+
},
|
|
464
|
+
"allOf": [
|
|
465
|
+
{
|
|
466
|
+
"if": {
|
|
467
|
+
"type": "object",
|
|
468
|
+
"properties": { "state": { "const": "exact" } },
|
|
469
|
+
"required": ["state"]
|
|
470
|
+
},
|
|
471
|
+
"then": {
|
|
472
|
+
"type": "object",
|
|
473
|
+
"properties": {
|
|
474
|
+
"additions": { "type": "integer", "minimum": 0, "maximum": 10000000 },
|
|
475
|
+
"deletions": { "type": "integer", "minimum": 0, "maximum": 10000000 },
|
|
476
|
+
"reasonCode": { "type": "null" }
|
|
477
|
+
}
|
|
478
|
+
},
|
|
479
|
+
"else": {
|
|
480
|
+
"type": "object",
|
|
481
|
+
"properties": {
|
|
482
|
+
"additions": { "type": "null" },
|
|
483
|
+
"deletions": { "type": "null" },
|
|
484
|
+
"reasonCode": { "$ref": "common-v1.schema.json#/$defs/reasonCode" }
|
|
485
|
+
}
|
|
486
|
+
}
|
|
487
|
+
}
|
|
488
|
+
]
|
|
489
|
+
},
|
|
490
|
+
"provenance": {
|
|
491
|
+
"type": "object",
|
|
492
|
+
"additionalProperties": false,
|
|
493
|
+
"required": [
|
|
494
|
+
"classification",
|
|
495
|
+
"evidence",
|
|
496
|
+
"baselineEvidenceRef",
|
|
497
|
+
"mutationEvidenceRefs",
|
|
498
|
+
"reasonCode"
|
|
499
|
+
],
|
|
500
|
+
"properties": {
|
|
501
|
+
"classification": {
|
|
502
|
+
"enum": [
|
|
503
|
+
"pre-existing-user",
|
|
504
|
+
"runtime-observed-agent",
|
|
505
|
+
"post-baseline-unattributed",
|
|
506
|
+
"mixed"
|
|
507
|
+
]
|
|
508
|
+
},
|
|
509
|
+
"evidence": { "enum": ["exact", "derived", "unavailable"] },
|
|
510
|
+
"baselineEvidenceRef": { "$ref": "common-v1.schema.json#/$defs/nullableOpaqueRef" },
|
|
511
|
+
"mutationEvidenceRefs": {
|
|
512
|
+
"type": "array",
|
|
513
|
+
"maxItems": 64,
|
|
514
|
+
"uniqueItems": true,
|
|
515
|
+
"items": { "$ref": "common-v1.schema.json#/$defs/opaqueRef" }
|
|
516
|
+
},
|
|
517
|
+
"reasonCode": { "$ref": "common-v1.schema.json#/$defs/nullableReasonCode" }
|
|
518
|
+
},
|
|
519
|
+
"allOf": [
|
|
520
|
+
{
|
|
521
|
+
"if": {
|
|
522
|
+
"type": "object",
|
|
523
|
+
"properties": { "classification": { "const": "runtime-observed-agent" } },
|
|
524
|
+
"required": ["classification"]
|
|
525
|
+
},
|
|
526
|
+
"then": {
|
|
527
|
+
"type": "object",
|
|
528
|
+
"properties": {
|
|
529
|
+
"evidence": { "const": "exact" },
|
|
530
|
+
"mutationEvidenceRefs": { "type": "array", "minItems": 1 },
|
|
531
|
+
"reasonCode": { "type": "null" }
|
|
532
|
+
}
|
|
533
|
+
}
|
|
534
|
+
},
|
|
535
|
+
{
|
|
536
|
+
"if": {
|
|
537
|
+
"type": "object",
|
|
538
|
+
"properties": { "classification": { "const": "mixed" } },
|
|
539
|
+
"required": ["classification"]
|
|
540
|
+
},
|
|
541
|
+
"then": {
|
|
542
|
+
"type": "object",
|
|
543
|
+
"properties": {
|
|
544
|
+
"evidence": { "const": "exact" },
|
|
545
|
+
"baselineEvidenceRef": { "$ref": "common-v1.schema.json#/$defs/opaqueRef" },
|
|
546
|
+
"mutationEvidenceRefs": { "type": "array", "minItems": 1 },
|
|
547
|
+
"reasonCode": { "type": "null" }
|
|
548
|
+
}
|
|
549
|
+
}
|
|
550
|
+
},
|
|
551
|
+
{
|
|
552
|
+
"if": {
|
|
553
|
+
"type": "object",
|
|
554
|
+
"properties": { "classification": { "const": "pre-existing-user" } },
|
|
555
|
+
"required": ["classification"]
|
|
556
|
+
},
|
|
557
|
+
"then": {
|
|
558
|
+
"type": "object",
|
|
559
|
+
"properties": {
|
|
560
|
+
"evidence": { "enum": ["exact", "derived"] },
|
|
561
|
+
"baselineEvidenceRef": { "$ref": "common-v1.schema.json#/$defs/opaqueRef" },
|
|
562
|
+
"mutationEvidenceRefs": { "type": "array", "maxItems": 0 },
|
|
563
|
+
"reasonCode": { "type": "null" }
|
|
564
|
+
}
|
|
565
|
+
}
|
|
566
|
+
},
|
|
567
|
+
{
|
|
568
|
+
"if": {
|
|
569
|
+
"type": "object",
|
|
570
|
+
"properties": { "classification": { "const": "post-baseline-unattributed" } },
|
|
571
|
+
"required": ["classification"]
|
|
572
|
+
},
|
|
573
|
+
"then": {
|
|
574
|
+
"type": "object",
|
|
575
|
+
"properties": {
|
|
576
|
+
"evidence": { "enum": ["derived", "unavailable"] },
|
|
577
|
+
"mutationEvidenceRefs": { "type": "array", "maxItems": 0 },
|
|
578
|
+
"reasonCode": { "$ref": "common-v1.schema.json#/$defs/reasonCode" }
|
|
579
|
+
}
|
|
580
|
+
}
|
|
581
|
+
},
|
|
582
|
+
{
|
|
583
|
+
"if": {
|
|
584
|
+
"type": "object",
|
|
585
|
+
"properties": { "evidence": { "const": "unavailable" } },
|
|
586
|
+
"required": ["evidence"]
|
|
587
|
+
},
|
|
588
|
+
"then": {
|
|
589
|
+
"type": "object",
|
|
590
|
+
"properties": {
|
|
591
|
+
"baselineEvidenceRef": { "type": "null" },
|
|
592
|
+
"mutationEvidenceRefs": { "type": "array", "maxItems": 0 },
|
|
593
|
+
"reasonCode": { "$ref": "common-v1.schema.json#/$defs/reasonCode" }
|
|
594
|
+
}
|
|
595
|
+
}
|
|
596
|
+
}
|
|
597
|
+
]
|
|
598
|
+
},
|
|
599
|
+
"fileChange": {
|
|
600
|
+
"type": "object",
|
|
601
|
+
"additionalProperties": false,
|
|
602
|
+
"required": [
|
|
603
|
+
"repoRef",
|
|
604
|
+
"basisRef",
|
|
605
|
+
"fileRef",
|
|
606
|
+
"fileRevision",
|
|
607
|
+
"path",
|
|
608
|
+
"oldPath",
|
|
609
|
+
"pathDisplay",
|
|
610
|
+
"status",
|
|
611
|
+
"git",
|
|
612
|
+
"baseDigest",
|
|
613
|
+
"currentDigest",
|
|
614
|
+
"content",
|
|
615
|
+
"stats",
|
|
616
|
+
"provenance",
|
|
617
|
+
"criterionIds",
|
|
618
|
+
"verifierAttemptIds",
|
|
619
|
+
"health"
|
|
620
|
+
],
|
|
621
|
+
"properties": {
|
|
622
|
+
"repoRef": { "$ref": "common-v1.schema.json#/$defs/opaqueRef" },
|
|
623
|
+
"basisRef": { "$ref": "common-v1.schema.json#/$defs/opaqueRef" },
|
|
624
|
+
"fileRef": { "$ref": "common-v1.schema.json#/$defs/opaqueRef" },
|
|
625
|
+
"fileRevision": { "$ref": "common-v1.schema.json#/$defs/revisionToken" },
|
|
626
|
+
"path": { "$ref": "common-v1.schema.json#/$defs/safeDisplayPath" },
|
|
627
|
+
"oldPath": { "$ref": "common-v1.schema.json#/$defs/nullableSafeDisplayPath" },
|
|
628
|
+
"pathDisplay": { "enum": ["exact-safe", "escaped", "redacted"] },
|
|
629
|
+
"status": { "enum": ["A", "M", "D", "R", "U", "C"] },
|
|
630
|
+
"git": { "$ref": "#/$defs/gitState" },
|
|
631
|
+
"baseDigest": {
|
|
632
|
+
"anyOf": [
|
|
633
|
+
{ "$ref": "common-v1.schema.json#/$defs/digest" },
|
|
634
|
+
{ "type": "null" }
|
|
635
|
+
]
|
|
636
|
+
},
|
|
637
|
+
"currentDigest": {
|
|
638
|
+
"anyOf": [
|
|
639
|
+
{ "$ref": "common-v1.schema.json#/$defs/digest" },
|
|
640
|
+
{ "type": "null" }
|
|
641
|
+
]
|
|
642
|
+
},
|
|
643
|
+
"content": { "$ref": "#/$defs/contentState" },
|
|
644
|
+
"stats": { "$ref": "#/$defs/lineStats" },
|
|
645
|
+
"provenance": { "$ref": "#/$defs/provenance" },
|
|
646
|
+
"criterionIds": {
|
|
647
|
+
"type": "array",
|
|
648
|
+
"maxItems": 128,
|
|
649
|
+
"uniqueItems": true,
|
|
650
|
+
"items": { "$ref": "common-v1.schema.json#/$defs/publicId" }
|
|
651
|
+
},
|
|
652
|
+
"verifierAttemptIds": {
|
|
653
|
+
"type": "array",
|
|
654
|
+
"maxItems": 128,
|
|
655
|
+
"uniqueItems": true,
|
|
656
|
+
"items": { "$ref": "common-v1.schema.json#/$defs/publicId" }
|
|
657
|
+
},
|
|
658
|
+
"health": { "$ref": "common-v1.schema.json#/$defs/health" }
|
|
659
|
+
},
|
|
660
|
+
"allOf": [
|
|
661
|
+
{
|
|
662
|
+
"if": {
|
|
663
|
+
"type": "object",
|
|
664
|
+
"properties": { "status": { "const": "R" } },
|
|
665
|
+
"required": ["status"]
|
|
666
|
+
},
|
|
667
|
+
"then": {
|
|
668
|
+
"type": "object",
|
|
669
|
+
"properties": {
|
|
670
|
+
"oldPath": { "$ref": "common-v1.schema.json#/$defs/safeDisplayPath" }
|
|
671
|
+
}
|
|
672
|
+
},
|
|
673
|
+
"else": {
|
|
674
|
+
"type": "object",
|
|
675
|
+
"properties": { "oldPath": { "type": "null" } }
|
|
676
|
+
}
|
|
677
|
+
},
|
|
678
|
+
{
|
|
679
|
+
"if": {
|
|
680
|
+
"type": "object",
|
|
681
|
+
"properties": { "status": { "const": "C" } },
|
|
682
|
+
"required": ["status"]
|
|
683
|
+
},
|
|
684
|
+
"then": {
|
|
685
|
+
"type": "object",
|
|
686
|
+
"properties": {
|
|
687
|
+
"git": {
|
|
688
|
+
"type": "object",
|
|
689
|
+
"properties": { "conflict": { "const": true } }
|
|
690
|
+
},
|
|
691
|
+
"stats": {
|
|
692
|
+
"type": "object",
|
|
693
|
+
"properties": { "state": { "const": "unavailable" } }
|
|
694
|
+
}
|
|
695
|
+
}
|
|
696
|
+
},
|
|
697
|
+
"else": {
|
|
698
|
+
"type": "object",
|
|
699
|
+
"properties": {
|
|
700
|
+
"git": {
|
|
701
|
+
"type": "object",
|
|
702
|
+
"properties": { "conflict": { "const": false } }
|
|
703
|
+
}
|
|
704
|
+
}
|
|
705
|
+
}
|
|
706
|
+
},
|
|
707
|
+
{
|
|
708
|
+
"if": {
|
|
709
|
+
"type": "object",
|
|
710
|
+
"properties": { "status": { "enum": ["A", "U"] } },
|
|
711
|
+
"required": ["status"]
|
|
712
|
+
},
|
|
713
|
+
"then": {
|
|
714
|
+
"type": "object",
|
|
715
|
+
"properties": { "baseDigest": { "type": "null" } }
|
|
716
|
+
}
|
|
717
|
+
},
|
|
718
|
+
{
|
|
719
|
+
"if": {
|
|
720
|
+
"type": "object",
|
|
721
|
+
"properties": { "status": { "const": "D" } },
|
|
722
|
+
"required": ["status"]
|
|
723
|
+
},
|
|
724
|
+
"then": {
|
|
725
|
+
"type": "object",
|
|
726
|
+
"properties": { "currentDigest": { "type": "null" } }
|
|
727
|
+
}
|
|
728
|
+
},
|
|
729
|
+
{
|
|
730
|
+
"if": {
|
|
731
|
+
"type": "object",
|
|
732
|
+
"properties": {
|
|
733
|
+
"content": {
|
|
734
|
+
"anyOf": [
|
|
735
|
+
{
|
|
736
|
+
"type": "object",
|
|
737
|
+
"properties": { "kind": { "enum": ["binary", "symlink", "submodule", "unknown"] } },
|
|
738
|
+
"required": ["kind"]
|
|
739
|
+
},
|
|
740
|
+
{
|
|
741
|
+
"type": "object",
|
|
742
|
+
"properties": { "access": { "enum": ["protected", "oversized", "unavailable"] } },
|
|
743
|
+
"required": ["access"]
|
|
744
|
+
}
|
|
745
|
+
]
|
|
746
|
+
}
|
|
747
|
+
},
|
|
748
|
+
"required": ["content"]
|
|
749
|
+
},
|
|
750
|
+
"then": {
|
|
751
|
+
"type": "object",
|
|
752
|
+
"properties": {
|
|
753
|
+
"stats": {
|
|
754
|
+
"type": "object",
|
|
755
|
+
"properties": { "state": { "const": "unavailable" } }
|
|
756
|
+
}
|
|
757
|
+
}
|
|
758
|
+
}
|
|
759
|
+
}
|
|
760
|
+
]
|
|
761
|
+
}
|
|
762
|
+
}
|
|
763
|
+
}
|