diff --git a/.bitcode/v44-btd-btc-compensation-statements.json b/.bitcode/v44-btd-btc-compensation-statements.json index 1fbd5346..070404ea 100644 --- a/.bitcode/v44-btd-btc-compensation-statements.json +++ b/.bitcode/v44-btd-btc-compensation-statements.json @@ -5,7 +5,7 @@ "currentTarget": "V43", "sourceSafetyVerdict": "source-safe-btd-btc-compensation-statement-metadata", "generatedAt": "deterministic", - "artifactRoot": "v44-btd-btc-compensation-statements:4deb21b419ea4de49c934761", + "artifactRoot": "v44-btd-btc-compensation-statements:963219f04df8cf3598a2c453", "passed": true, "objectIds": [ "BtdBtcCompensationStatements", @@ -179,16 +179,16 @@ ], "sourceRoots": { "activePointer": "BITCODE_SPEC.txt:4ea77b214c66f69c697bff3d", - "spec": "BITCODE_SPEC_V44.md:e215c9d702cfca700f5c709b", - "delta": "BITCODE_SPEC_V44_DELTA.md:0ef890b5bb1435b44780ee4b", - "notes": "BITCODE_SPEC_V44_NOTES.md:951e0798b5d9c4f7f063a2da", - "parity": "BITCODE_SPEC_V44_PARITY_MATRIX.md:089ca0f30ddd7a1902e41a34", - "roadmap": "SPECIFICATIONS_ROADMAP.md:87d18b6eb15464c3c4249532", - "readme": "README.md:62cc39fe7b3cb4f730e581f9", - "protocolReadme": "packages/protocol/README.md:6af505bd152611328b055bbd", - "packageJson": "package.json:809fa4b7a82a5d58f10c365f", - "gateWorkflow": ".github/workflows/bitcode-gate-quality.yml:d97de3b662a26bc83c225e89", - "canonWorkflow": ".github/workflows/bitcode-canon-quality.yml:07a7006c556f6f107fac74a0", + "spec": "BITCODE_SPEC_V44.md:a4d88f93d1a0922bd13eae9a", + "delta": "BITCODE_SPEC_V44_DELTA.md:912d0160e79480df996b6b65", + "notes": "BITCODE_SPEC_V44_NOTES.md:7da533fe05878c5d115a5a8f", + "parity": "BITCODE_SPEC_V44_PARITY_MATRIX.md:e0bf0f41e7e6f943b87cc961", + "roadmap": "SPECIFICATIONS_ROADMAP.md:5f1707567badbcb00253b5ba", + "readme": "README.md:4bcf1513e419725def290466", + "protocolReadme": "packages/protocol/README.md:fd862cbe82eaadc11634ec63", + "packageJson": "package.json:23854aa3b132e2d162fcb121", + "gateWorkflow": ".github/workflows/bitcode-gate-quality.yml:09990dbe164dcf5022afcb7b", + "canonWorkflow": ".github/workflows/bitcode-canon-quality.yml:d5b37bf411e5febc12359b97", "economicModel": "packages/protocol/src/canonical/v44-economic-domain-model.js:21b8f5c80ad8322dff2909ed", "settlementBoundary": "packages/pipelines/asset-pack/src/asset-pack-settlement-rights-delivery.ts:4e5eebe66c2075acef628682", "accountingStatements": "packages/pipelines/asset-pack/src/btd-btc-compensation-statements.ts:a239683c231a0127c4777a3f", @@ -198,13 +198,13 @@ "btdReceipts": "packages/btd/src/receipts.ts:663e799baf0715924cb67c14", "btdReconciliation": "packages/btd/src/reconciliation.ts:d4bc6c129196572ae673c05b", "packActivityModel": "uapi/components/base/bitcode/activity/pack-activity-model.ts:0c69746f1b9cbb70e2b0be09", - "packsClient": "uapi/app/packs/PacksPageClient.tsx:5dbaae660c70de141a780e58", + "packsClient": "uapi/app/packs/PacksPageClient.tsx:68c61c8fd312e6c750d742ba", "packActivityModelTest": "uapi/tests/packActivityModel.test.ts:882c5ac213f83d8b57a6e5ff", - "packsClientTest": "uapi/tests/packsPageClient.test.tsx:400aa55dbeae6bbdb90a08b4", + "packsClientTest": "uapi/tests/packsPageClient.test.tsx:bc9614c09f959b5e484abcc8", "assetPackPackageIndex": "packages/pipelines/asset-pack/src/index.ts:48330699ed60ccb1db2bb77d", "assetPackPackageManifest": "packages/pipelines/asset-pack/package.json:45926bffaa0fe93aee0d41cb", - "packageIndex": "packages/protocol/src/index.js:a394466468bf6e59ee72b2f7", - "packageTypes": "packages/protocol/src/index.d.ts:1a6ef5f0300aceb3b4f34b9c", + "packageIndex": "packages/protocol/src/index.js:dca13a5eed71ff6eefbf450b", + "packageTypes": "packages/protocol/src/index.d.ts:d62198617b035b092ff9a207", "packageSource": "packages/protocol/src/canonical/v44-btd-btc-compensation-statements.js:b7cd49efa70c18f93be91661", "packageTest": "packages/protocol/test/v44-btd-btc-compensation-statements.test.js:8c8bff4a58a07f01c94b1d90", "generator": "scripts/generate-v44-btd-btc-compensation-statements.mjs:603d3af279f716d625f891c9", diff --git a/.bitcode/v44-depositor-earnings-supply-opportunities.json b/.bitcode/v44-depositor-earnings-supply-opportunities.json index 6c37a80a..966a2846 100644 --- a/.bitcode/v44-depositor-earnings-supply-opportunities.json +++ b/.bitcode/v44-depositor-earnings-supply-opportunities.json @@ -5,7 +5,7 @@ "currentTarget": "V43", "sourceSafetyVerdict": "source-safe-depositor-earnings-supply-opportunity-metadata", "generatedAt": "deterministic", - "artifactRoot": "v44-depositor-earnings-supply-opportunities:c5f0242af75bf0f13517b017", + "artifactRoot": "v44-depositor-earnings-supply-opportunities:a9ffb08b0193f7fa7358c858", "passed": true, "objectIds": [ "DepositorEarningSupplyIntelligence", @@ -136,30 +136,30 @@ ], "sourceRoots": { "activePointer": "BITCODE_SPEC.txt:4ea77b214c66f69c697bff3d", - "spec": "BITCODE_SPEC_V44.md:e215c9d702cfca700f5c709b", - "delta": "BITCODE_SPEC_V44_DELTA.md:0ef890b5bb1435b44780ee4b", - "notes": "BITCODE_SPEC_V44_NOTES.md:951e0798b5d9c4f7f063a2da", - "parity": "BITCODE_SPEC_V44_PARITY_MATRIX.md:089ca0f30ddd7a1902e41a34", - "roadmap": "SPECIFICATIONS_ROADMAP.md:87d18b6eb15464c3c4249532", - "readme": "README.md:62cc39fe7b3cb4f730e581f9", - "protocolReadme": "packages/protocol/README.md:6af505bd152611328b055bbd", - "packageJson": "package.json:809fa4b7a82a5d58f10c365f", - "gateWorkflow": ".github/workflows/bitcode-gate-quality.yml:d97de3b662a26bc83c225e89", - "canonWorkflow": ".github/workflows/bitcode-canon-quality.yml:07a7006c556f6f107fac74a0", + "spec": "BITCODE_SPEC_V44.md:a4d88f93d1a0922bd13eae9a", + "delta": "BITCODE_SPEC_V44_DELTA.md:912d0160e79480df996b6b65", + "notes": "BITCODE_SPEC_V44_NOTES.md:7da533fe05878c5d115a5a8f", + "parity": "BITCODE_SPEC_V44_PARITY_MATRIX.md:e0bf0f41e7e6f943b87cc961", + "roadmap": "SPECIFICATIONS_ROADMAP.md:5f1707567badbcb00253b5ba", + "readme": "README.md:4bcf1513e419725def290466", + "protocolReadme": "packages/protocol/README.md:fd862cbe82eaadc11634ec63", + "packageJson": "package.json:23854aa3b132e2d162fcb121", + "gateWorkflow": ".github/workflows/bitcode-gate-quality.yml:09990dbe164dcf5022afcb7b", + "canonWorkflow": ".github/workflows/bitcode-canon-quality.yml:d5b37bf411e5febc12359b97", "economicModel": "packages/protocol/src/canonical/v44-economic-domain-model.js:21b8f5c80ad8322dff2909ed", "portfolioMarketIntelligence": "packages/protocol/src/canonical/v44-packs-portfolio-market-intelligence.js:f5d37e086c9bbbdb6202da53", "optionPolicy": "packages/pipelines/asset-pack/src/deposit-asset-pack-option-policy.ts:12816b23b2d8e304ab4a1638", "earningSupplyIntelligence": "packages/pipelines/asset-pack/src/depositor-earning-supply-intelligence.ts:e0ec2d83cfaf3bfaaa126387", "earningSupplyIntelligenceTest": "packages/pipelines/asset-pack/src/__tests__/depositor-earning-supply-intelligence.test.ts:3b7a869e6262f6f5ebcc71fe", "depositModel": "uapi/app/deposit/deposit-route-model.ts:6485e388dd745c79907f992c", - "depositClient": "uapi/app/deposit/DepositPageClient.tsx:4f5cb4d29e42ca1f6a84c628", + "depositClient": "uapi/app/deposit/DepositPageClient.tsx:8526b7980e568ab7d5228e8f", "depositRouteTest": "uapi/tests/depositRouteModel.test.ts:3f7377f8c55ce132f970ad09", - "depositPageTest": "uapi/tests/depositPageClient.test.tsx:d72a8acb191b6d62d49f8679", + "depositPageTest": "uapi/tests/depositPageClient.test.tsx:3d92ba0bb623f2270acad437", "assetPackPackageIndex": "packages/pipelines/asset-pack/src/index.ts:48330699ed60ccb1db2bb77d", "assetPackPackageManifest": "packages/pipelines/asset-pack/package.json:45926bffaa0fe93aee0d41cb", "sourceToShares": "packages/btd/src/source-to-shares.ts:6e2e84251b29ba2477766708", - "packageIndex": "packages/protocol/src/index.js:a394466468bf6e59ee72b2f7", - "packageTypes": "packages/protocol/src/index.d.ts:1a6ef5f0300aceb3b4f34b9c", + "packageIndex": "packages/protocol/src/index.js:dca13a5eed71ff6eefbf450b", + "packageTypes": "packages/protocol/src/index.d.ts:d62198617b035b092ff9a207", "packageSource": "packages/protocol/src/canonical/v44-depositor-earnings-supply-opportunities.js:cf9cf5f99f00dbf3201c8c8e", "packageTest": "packages/protocol/test/v44-depositor-earnings-supply-opportunities.test.js:1b025c1904f94a1069b64ddf", "generator": "scripts/generate-v44-depositor-earnings-supply-opportunities.mjs:0844124207cbfe8264f12a2f", diff --git a/.bitcode/v44-economic-domain-model.json b/.bitcode/v44-economic-domain-model.json index 4f10b066..c92668ee 100644 --- a/.bitcode/v44-economic-domain-model.json +++ b/.bitcode/v44-economic-domain-model.json @@ -5,7 +5,7 @@ "currentTarget": "V43", "sourceSafetyVerdict": "source-safe-economic-domain-model-metadata", "generatedAt": "deterministic", - "artifactRoot": "v44-economic-domain-model:a257d37a58207887e068716d", + "artifactRoot": "v44-economic-domain-model:9b8233a8affaa0285bf3984a", "passed": true, "economicObjectIds": [ "EnterprisePackPortfolio", @@ -759,18 +759,18 @@ ], "sourceRoots": { "activePointer": "BITCODE_SPEC.txt:4ea77b214c66f69c697bff3d", - "spec": "BITCODE_SPEC_V44.md:e215c9d702cfca700f5c709b", - "delta": "BITCODE_SPEC_V44_DELTA.md:0ef890b5bb1435b44780ee4b", - "notes": "BITCODE_SPEC_V44_NOTES.md:951e0798b5d9c4f7f063a2da", - "parity": "BITCODE_SPEC_V44_PARITY_MATRIX.md:089ca0f30ddd7a1902e41a34", - "roadmap": "SPECIFICATIONS_ROADMAP.md:87d18b6eb15464c3c4249532", - "readme": "README.md:62cc39fe7b3cb4f730e581f9", - "protocolReadme": "packages/protocol/README.md:6af505bd152611328b055bbd", - "packageJson": "package.json:809fa4b7a82a5d58f10c365f", - "gateWorkflow": ".github/workflows/bitcode-gate-quality.yml:d97de3b662a26bc83c225e89", - "canonWorkflow": ".github/workflows/bitcode-canon-quality.yml:07a7006c556f6f107fac74a0", - "packageIndex": "packages/protocol/src/index.js:a394466468bf6e59ee72b2f7", - "packageTypes": "packages/protocol/src/index.d.ts:1a6ef5f0300aceb3b4f34b9c", + "spec": "BITCODE_SPEC_V44.md:a4d88f93d1a0922bd13eae9a", + "delta": "BITCODE_SPEC_V44_DELTA.md:912d0160e79480df996b6b65", + "notes": "BITCODE_SPEC_V44_NOTES.md:7da533fe05878c5d115a5a8f", + "parity": "BITCODE_SPEC_V44_PARITY_MATRIX.md:e0bf0f41e7e6f943b87cc961", + "roadmap": "SPECIFICATIONS_ROADMAP.md:5f1707567badbcb00253b5ba", + "readme": "README.md:4bcf1513e419725def290466", + "protocolReadme": "packages/protocol/README.md:fd862cbe82eaadc11634ec63", + "packageJson": "package.json:23854aa3b132e2d162fcb121", + "gateWorkflow": ".github/workflows/bitcode-gate-quality.yml:09990dbe164dcf5022afcb7b", + "canonWorkflow": ".github/workflows/bitcode-canon-quality.yml:d5b37bf411e5febc12359b97", + "packageIndex": "packages/protocol/src/index.js:dca13a5eed71ff6eefbf450b", + "packageTypes": "packages/protocol/src/index.d.ts:d62198617b035b092ff9a207", "packageSource": "packages/protocol/src/canonical/v44-economic-domain-model.js:21b8f5c80ad8322dff2909ed", "packageTest": "packages/protocol/test/v44-economic-domain-model.test.js:b89f71aa0cf578dabbec3cd9", "generator": "scripts/generate-v44-economic-domain-model.mjs:3390fbc087e919bedb14550c", diff --git a/.bitcode/v44-enterprise-product-ux.json b/.bitcode/v44-enterprise-product-ux.json new file mode 100644 index 00000000..ca0912dd --- /dev/null +++ b/.bitcode/v44-enterprise-product-ux.json @@ -0,0 +1,318 @@ +{ + "artifactId": "v44-enterprise-product-ux", + "schemaId": "bitcode.v44.enterpriseProductUx.v1", + "version": "V44", + "currentTarget": "V43", + "sourceSafetyVerdict": "source-safe-enterprise-product-ux-metadata", + "generatedAt": "deterministic", + "artifactRoot": "v44-enterprise-product-ux:114f7096f7421a284df1cdfa", + "passed": true, + "objectIds": [ + "ProductRouteEnterpriseSummary", + "ProductRouteKeyboardHint", + "ProductRouteProofDetail", + "PacksEnterpriseEconomicSummary", + "ReadEnterpriseEconomicSummary", + "DepositEnterpriseEconomicSummary", + "PackActivityEconomicOperationTable", + "ExpandableEconomicProofDetail" + ], + "routeIds": [ + "/packs", + "/read", + "/deposit" + ], + "capabilityIds": [ + "dense-economic-summary", + "keyboard-navigation", + "responsive-economic-layout", + "expandable-proof-detail", + "sticky-pack-activity-table", + "source-safe-disclosure-boundary", + "visual-regression-test-hooks" + ], + "forbiddenPayloadIds": [ + "protected-source-payloads", + "raw-source-text", + "unpaid-assetpack-source", + "raw-prompts", + "interpolated-prompts", + "raw-provider-responses", + "credentials", + "wallet-private-material", + "private-settlement-payloads", + "value-bearing-mainnet-admission" + ], + "contractRows": [ + { + "rowId": "shared-enterprise-ux-primitives", + "owner": "uapi/components/base/bitcode/routes/product-route-shell.tsx", + "contract": "Product route shell exposes shared enterprise summary, keyboard navigation, and proof-detail primitives for source-safe economic operation.", + "requiredFields": [ + "ProductRouteEnterpriseSummary", + "ProductRouteKeyboardHint", + "ProductRouteProofDetail", + "data-enterprise-ux" + ], + "rowRoot": "v44-enterprise-product-ux-contract:ddb12e79e61fb8b7a907f262", + "sourceSafeMetadataOnly": true, + "protectedSourceVisible": false, + "unpaidAssetPackSourceVisible": false + }, + { + "rowId": "packs-economic-operation", + "owner": "uapi/app/packs/PacksPageClient.tsx", + "contract": "/packs renders portfolio economy overview, keyboard navigation, sticky dense activity grid, and expandable proof detail.", + "requiredFields": [ + "packs-enterprise-economic-summary", + "packs-keyboard-navigation", + "packs-enterprise-activity-grid", + "packs-expandable-proof-detail" + ], + "rowRoot": "v44-enterprise-product-ux-contract:dfc0cf20f145b77f9912dedf", + "sourceSafeMetadataOnly": true, + "protectedSourceVisible": false, + "unpaidAssetPackSourceVisible": false + }, + { + "rowId": "read-economic-operation", + "owner": "uapi/app/read/ReadPageClient.tsx", + "contract": "/read renders Reading economy overview, keyboard navigation, and route/procurement/authority proof roots.", + "requiredFields": [ + "read-enterprise-economic-summary", + "read-keyboard-navigation", + "read-expandable-proof-detail", + "Reading economy overview" + ], + "rowRoot": "v44-enterprise-product-ux-contract:587d9093b3a38f2df680a13c", + "sourceSafeMetadataOnly": true, + "protectedSourceVisible": false, + "unpaidAssetPackSourceVisible": false + }, + { + "rowId": "deposit-economic-operation", + "owner": "uapi/app/deposit/DepositPageClient.tsx", + "contract": "/deposit renders Depositing economy overview, keyboard navigation, and synthesis/policy/admission/earnings/authority proof roots.", + "requiredFields": [ + "deposit-enterprise-economic-summary", + "deposit-keyboard-navigation", + "deposit-expandable-proof-detail", + "Depositing economy overview" + ], + "rowRoot": "v44-enterprise-product-ux-contract:b5025d8d8cce705889195843", + "sourceSafeMetadataOnly": true, + "protectedSourceVisible": false, + "unpaidAssetPackSourceVisible": false + }, + { + "rowId": "focused-route-tests", + "owner": "uapi/tests/packsPageClient.test.tsx", + "contract": "Focused route tests cover enterprise summaries, keyboard hints, proof detail, and source-safe table/detail hooks.", + "requiredFields": [ + "packs-enterprise-economic-summary", + "read-enterprise-economic-summary", + "deposit-enterprise-economic-summary" + ], + "rowRoot": "v44-enterprise-product-ux-contract:3ea9fded7866d9cd5f7353c5", + "sourceSafeMetadataOnly": true, + "protectedSourceVisible": false, + "unpaidAssetPackSourceVisible": false + }, + { + "rowId": "workflow-and-artifact-wiring", + "owner": "scripts/check-v44-gate8-enterprise-product-ux.mjs", + "contract": "Gate 8 closes only when generator, checker, protocol exports, docs, workflows, focused tests, and generated artifact are current.", + "requiredFields": [ + "check-v44-gate8-enterprise-product-ux", + "generate-v44-enterprise-product-ux" + ], + "rowRoot": "v44-enterprise-product-ux-contract:1d3b60a5dfcb3422f93c314a", + "sourceSafeMetadataOnly": true, + "protectedSourceVisible": false, + "unpaidAssetPackSourceVisible": false + } + ], + "sourceRoots": { + "activePointer": "BITCODE_SPEC.txt:4ea77b214c66f69c697bff3d", + "spec": "BITCODE_SPEC_V44.md:a4d88f93d1a0922bd13eae9a", + "delta": "BITCODE_SPEC_V44_DELTA.md:912d0160e79480df996b6b65", + "notes": "BITCODE_SPEC_V44_NOTES.md:7da533fe05878c5d115a5a8f", + "parity": "BITCODE_SPEC_V44_PARITY_MATRIX.md:e0bf0f41e7e6f943b87cc961", + "roadmap": "SPECIFICATIONS_ROADMAP.md:5f1707567badbcb00253b5ba", + "readme": "README.md:4bcf1513e419725def290466", + "protocolReadme": "packages/protocol/README.md:fd862cbe82eaadc11634ec63", + "packageJson": "package.json:23854aa3b132e2d162fcb121", + "gateWorkflow": ".github/workflows/bitcode-gate-quality.yml:09990dbe164dcf5022afcb7b", + "canonWorkflow": ".github/workflows/bitcode-canon-quality.yml:d5b37bf411e5febc12359b97", + "productRouteShell": "uapi/components/base/bitcode/routes/product-route-shell.tsx:e71f90c289dec52fd158568a", + "packsClient": "uapi/app/packs/PacksPageClient.tsx:68c61c8fd312e6c750d742ba", + "readClient": "uapi/app/read/ReadPageClient.tsx:860bec675640bf466752bc7e", + "depositClient": "uapi/app/deposit/DepositPageClient.tsx:8526b7980e568ab7d5228e8f", + "packsTest": "uapi/tests/packsPageClient.test.tsx:bc9614c09f959b5e484abcc8", + "readTest": "uapi/tests/readPageClient.test.tsx:32b44747b6500a24ee88faa7", + "depositTest": "uapi/tests/depositPageClient.test.tsx:3d92ba0bb623f2270acad437", + "protocolIndex": "packages/protocol/src/index.js:dca13a5eed71ff6eefbf450b", + "protocolTypes": "packages/protocol/src/index.d.ts:d62198617b035b092ff9a207", + "protocolSource": "packages/protocol/src/canonical/v44-enterprise-product-ux.js:ec58b65693ae3f1135670512", + "protocolTest": "packages/protocol/test/v44-enterprise-product-ux.test.js:c383b6eda2a248544f898bc3", + "generator": "scripts/generate-v44-enterprise-product-ux.mjs:56391502a1cea83a2c8f828f", + "checker": "scripts/check-v44-gate8-enterprise-product-ux.mjs:685792ad62c868c6edd72f97" + }, + "predicateResults": [ + { + "id": "active-canon-pointer-remains-v43", + "sourcePath": "BITCODE_SPEC.txt", + "passed": true + }, + { + "id": "spec-defines-gate8", + "sourcePath": "BITCODE_SPEC_V44.md", + "passed": true + }, + { + "id": "spec-names-gate8-artifact", + "sourcePath": "BITCODE_SPEC_V44.md", + "passed": true + }, + { + "id": "delta-records-gate8", + "sourcePath": "BITCODE_SPEC_V44_DELTA.md", + "passed": true + }, + { + "id": "notes-records-gate8", + "sourcePath": "BITCODE_SPEC_V44_NOTES.md", + "passed": true + }, + { + "id": "parity-records-gate8", + "sourcePath": "BITCODE_SPEC_V44_PARITY_MATRIX.md", + "passed": true + }, + { + "id": "roadmap-records-gate8", + "sourcePath": "SPECIFICATIONS_ROADMAP.md", + "passed": true + }, + { + "id": "readme-records-gate8", + "sourcePath": "README.md", + "passed": true + }, + { + "id": "protocol-readme-records-gate8", + "sourcePath": "packages/protocol/README.md", + "passed": true + }, + { + "id": "shared-enterprise-summary-implemented", + "sourcePath": "uapi/components/base/bitcode/routes/product-route-shell.tsx", + "passed": true + }, + { + "id": "shared-keyboard-hint-implemented", + "sourcePath": "uapi/components/base/bitcode/routes/product-route-shell.tsx", + "passed": true + }, + { + "id": "shared-proof-detail-implemented", + "sourcePath": "uapi/components/base/bitcode/routes/product-route-shell.tsx", + "passed": true + }, + { + "id": "packs-route-uses-enterprise-ux", + "sourcePath": "uapi/app/packs/PacksPageClient.tsx", + "passed": true + }, + { + "id": "read-route-uses-enterprise-ux", + "sourcePath": "uapi/app/read/ReadPageClient.tsx", + "passed": true + }, + { + "id": "deposit-route-uses-enterprise-ux", + "sourcePath": "uapi/app/deposit/DepositPageClient.tsx", + "passed": true + }, + { + "id": "packs-test-covers-enterprise-ux", + "sourcePath": "uapi/tests/packsPageClient.test.tsx", + "passed": true + }, + { + "id": "read-test-covers-enterprise-ux", + "sourcePath": "uapi/tests/readPageClient.test.tsx", + "passed": true + }, + { + "id": "deposit-test-covers-enterprise-ux", + "sourcePath": "uapi/tests/depositPageClient.test.tsx", + "passed": true + }, + { + "id": "protocol-test-covers-artifact", + "sourcePath": "packages/protocol/test/v44-enterprise-product-ux.test.js", + "passed": true + }, + { + "id": "protocol-package-exports-gate8", + "sourcePath": "packages/protocol/src/index.js", + "passed": true + }, + { + "id": "protocol-types-export-gate8", + "sourcePath": "packages/protocol/src/index.d.ts", + "passed": true + }, + { + "id": "package-json-exposes-gate8", + "sourcePath": "package.json", + "passed": true + }, + { + "id": "gate-workflow-runs-gate8", + "sourcePath": ".github/workflows/bitcode-gate-quality.yml", + "passed": true + }, + { + "id": "canon-workflow-runs-gate8", + "sourcePath": ".github/workflows/bitcode-canon-quality.yml", + "passed": true + }, + { + "id": "generator-exists", + "sourcePath": "scripts/generate-v44-enterprise-product-ux.mjs", + "passed": true + }, + { + "id": "checker-exists", + "sourcePath": "scripts/check-v44-gate8-enterprise-product-ux.mjs", + "passed": true + } + ], + "coverage": { + "sharedEnterpriseSummaryImplemented": true, + "sharedKeyboardNavigationImplemented": true, + "sharedExpandableProofDetailImplemented": true, + "packsEnterpriseUxImplemented": true, + "readEnterpriseUxImplemented": true, + "depositEnterpriseUxImplemented": true, + "denseEconomicTableImplemented": true, + "responsiveLayoutPostureImplemented": true, + "visualRegressionTestHooksImplemented": true, + "sourceSafeMetadataOnly": true, + "protectedSourceVisible": false, + "rawSourceTextVisible": false, + "unpaidAssetPackSourceVisible": false, + "rawPromptVisible": false, + "interpolatedPromptVisible": false, + "rawProviderResponseVisible": false, + "credentialsVisible": false, + "walletPrivateMaterialVisible": false, + "settlementPrivatePayloadVisible": false, + "valueBearingMainnetAdmitted": false, + "requiredPredicateCount": 26, + "passedPredicateCount": 26, + "failedPredicateIds": [] + } +} diff --git a/.bitcode/v44-organization-policy-wallet-authority.json b/.bitcode/v44-organization-policy-wallet-authority.json index b37fda75..16a690e9 100644 --- a/.bitcode/v44-organization-policy-wallet-authority.json +++ b/.bitcode/v44-organization-policy-wallet-authority.json @@ -369,16 +369,16 @@ ], "sourceRoots": { "activePointer": "BITCODE_SPEC.txt:4ea77b214c66f69c697bff3d", - "spec": "BITCODE_SPEC_V44.md:e215c9d702cfca700f5c709b", - "delta": "BITCODE_SPEC_V44_DELTA.md:0ef890b5bb1435b44780ee4b", - "notes": "BITCODE_SPEC_V44_NOTES.md:951e0798b5d9c4f7f063a2da", - "parity": "BITCODE_SPEC_V44_PARITY_MATRIX.md:089ca0f30ddd7a1902e41a34", - "roadmap": "SPECIFICATIONS_ROADMAP.md:87d18b6eb15464c3c4249532", - "readme": "README.md:62cc39fe7b3cb4f730e581f9", - "protocolReadme": "packages/protocol/README.md:6af505bd152611328b055bbd", - "packageJson": "package.json:809fa4b7a82a5d58f10c365f", - "gateWorkflow": ".github/workflows/bitcode-gate-quality.yml:d97de3b662a26bc83c225e89", - "canonWorkflow": ".github/workflows/bitcode-canon-quality.yml:07a7006c556f6f107fac74a0", + "spec": "BITCODE_SPEC_V44.md:a4d88f93d1a0922bd13eae9a", + "delta": "BITCODE_SPEC_V44_DELTA.md:912d0160e79480df996b6b65", + "notes": "BITCODE_SPEC_V44_NOTES.md:7da533fe05878c5d115a5a8f", + "parity": "BITCODE_SPEC_V44_PARITY_MATRIX.md:e0bf0f41e7e6f943b87cc961", + "roadmap": "SPECIFICATIONS_ROADMAP.md:5f1707567badbcb00253b5ba", + "readme": "README.md:4bcf1513e419725def290466", + "protocolReadme": "packages/protocol/README.md:fd862cbe82eaadc11634ec63", + "packageJson": "package.json:23854aa3b132e2d162fcb121", + "gateWorkflow": ".github/workflows/bitcode-gate-quality.yml:09990dbe164dcf5022afcb7b", + "canonWorkflow": ".github/workflows/bitcode-canon-quality.yml:d5b37bf411e5febc12359b97", "btdAuthority": "packages/btd/src/authority.ts:20b1fe9ef12d791fab3e1de7", "btdAuthorityTest": "packages/btd/__tests__/btd.test.ts:21a5e15a3ec931d2c4c7a1cd", "packageHelper": "packages/pipelines/asset-pack/src/organization-policy-wallet-authority.ts:ed6fa07bc3f69caaca598249", @@ -387,18 +387,18 @@ "assetPackPackageManifest": "packages/pipelines/asset-pack/package.json:45926bffaa0fe93aee0d41cb", "readRouteModel": "uapi/app/read/read-route-model.ts:670e1abd63cccea6365a491f", "readRouteTest": "uapi/tests/readRouteModel.test.ts:5ad610c538f65fb0c860777f", - "readClient": "uapi/app/read/ReadPageClient.tsx:8c8219f42275485d4dffd327", - "readClientTest": "uapi/tests/readPageClient.test.tsx:116589281edef9c19e57b9ba", + "readClient": "uapi/app/read/ReadPageClient.tsx:860bec675640bf466752bc7e", + "readClientTest": "uapi/tests/readPageClient.test.tsx:32b44747b6500a24ee88faa7", "depositRouteModel": "uapi/app/deposit/deposit-route-model.ts:6485e388dd745c79907f992c", "depositRouteTest": "uapi/tests/depositRouteModel.test.ts:3f7377f8c55ce132f970ad09", - "depositClient": "uapi/app/deposit/DepositPageClient.tsx:4f5cb4d29e42ca1f6a84c628", - "depositClientTest": "uapi/tests/depositPageClient.test.tsx:d72a8acb191b6d62d49f8679", + "depositClient": "uapi/app/deposit/DepositPageClient.tsx:8526b7980e568ab7d5228e8f", + "depositClientTest": "uapi/tests/depositPageClient.test.tsx:3d92ba0bb623f2270acad437", "packActivityModel": "uapi/components/base/bitcode/activity/pack-activity-model.ts:0c69746f1b9cbb70e2b0be09", - "packsClient": "uapi/app/packs/PacksPageClient.tsx:5dbaae660c70de141a780e58", + "packsClient": "uapi/app/packs/PacksPageClient.tsx:68c61c8fd312e6c750d742ba", "packActivityModelTest": "uapi/tests/packActivityModel.test.ts:882c5ac213f83d8b57a6e5ff", - "packsClientTest": "uapi/tests/packsPageClient.test.tsx:400aa55dbeae6bbdb90a08b4", - "packageIndex": "packages/protocol/src/index.js:a394466468bf6e59ee72b2f7", - "packageTypes": "packages/protocol/src/index.d.ts:1a6ef5f0300aceb3b4f34b9c", + "packsClientTest": "uapi/tests/packsPageClient.test.tsx:bc9614c09f959b5e484abcc8", + "packageIndex": "packages/protocol/src/index.js:dca13a5eed71ff6eefbf450b", + "packageTypes": "packages/protocol/src/index.d.ts:d62198617b035b092ff9a207", "packageSource": "packages/protocol/src/canonical/v44-organization-policy-wallet-authority.js:6936c960db233b0cee9b588a", "packageTest": "packages/protocol/test/v44-organization-policy-wallet-authority.test.js:95d6dc48346a60a88d83d4b7", "generator": "scripts/generate-v44-organization-policy-wallet-authority.mjs:faabf63e75da42310d30df06", @@ -423,5 +423,5 @@ "failedPredicateIds": [] }, "passed": true, - "artifactRoot": "v44-organization-policy-wallet-authority:ee9d985a2321657c540eadea" + "artifactRoot": "v44-organization-policy-wallet-authority:777bde5c158a61be524186d1" } diff --git a/.bitcode/v44-packs-portfolio-market-intelligence.json b/.bitcode/v44-packs-portfolio-market-intelligence.json index 82c90349..9de3f2b6 100644 --- a/.bitcode/v44-packs-portfolio-market-intelligence.json +++ b/.bitcode/v44-packs-portfolio-market-intelligence.json @@ -5,7 +5,7 @@ "currentTarget": "V43", "sourceSafetyVerdict": "source-safe-packs-portfolio-market-intelligence-metadata", "generatedAt": "deterministic", - "artifactRoot": "v44-packs-portfolio-market-intelligence:cfeb721035b117cf09239cbb", + "artifactRoot": "v44-packs-portfolio-market-intelligence:92917241de717e9d162aef9a", "passed": true, "portfolioViewIds": [ "enterprise-pack-portfolio", @@ -109,23 +109,23 @@ ], "sourceRoots": { "activePointer": "BITCODE_SPEC.txt:4ea77b214c66f69c697bff3d", - "spec": "BITCODE_SPEC_V44.md:e215c9d702cfca700f5c709b", - "delta": "BITCODE_SPEC_V44_DELTA.md:0ef890b5bb1435b44780ee4b", - "notes": "BITCODE_SPEC_V44_NOTES.md:951e0798b5d9c4f7f063a2da", - "parity": "BITCODE_SPEC_V44_PARITY_MATRIX.md:089ca0f30ddd7a1902e41a34", - "roadmap": "SPECIFICATIONS_ROADMAP.md:87d18b6eb15464c3c4249532", - "readme": "README.md:62cc39fe7b3cb4f730e581f9", - "protocolReadme": "packages/protocol/README.md:6af505bd152611328b055bbd", - "packageJson": "package.json:809fa4b7a82a5d58f10c365f", - "gateWorkflow": ".github/workflows/bitcode-gate-quality.yml:d97de3b662a26bc83c225e89", - "canonWorkflow": ".github/workflows/bitcode-canon-quality.yml:07a7006c556f6f107fac74a0", + "spec": "BITCODE_SPEC_V44.md:a4d88f93d1a0922bd13eae9a", + "delta": "BITCODE_SPEC_V44_DELTA.md:912d0160e79480df996b6b65", + "notes": "BITCODE_SPEC_V44_NOTES.md:7da533fe05878c5d115a5a8f", + "parity": "BITCODE_SPEC_V44_PARITY_MATRIX.md:e0bf0f41e7e6f943b87cc961", + "roadmap": "SPECIFICATIONS_ROADMAP.md:5f1707567badbcb00253b5ba", + "readme": "README.md:4bcf1513e419725def290466", + "protocolReadme": "packages/protocol/README.md:fd862cbe82eaadc11634ec63", + "packageJson": "package.json:23854aa3b132e2d162fcb121", + "gateWorkflow": ".github/workflows/bitcode-gate-quality.yml:09990dbe164dcf5022afcb7b", + "canonWorkflow": ".github/workflows/bitcode-canon-quality.yml:d5b37bf411e5febc12359b97", "economicModel": "packages/protocol/src/canonical/v44-economic-domain-model.js:21b8f5c80ad8322dff2909ed", "model": "uapi/components/base/bitcode/activity/pack-activity-model.ts:0c69746f1b9cbb70e2b0be09", "route": "uapi/app/api/packs/activity/route.ts:97c5a4539d48562eb5de66e8", - "client": "uapi/app/packs/PacksPageClient.tsx:5dbaae660c70de141a780e58", + "client": "uapi/app/packs/PacksPageClient.tsx:68c61c8fd312e6c750d742ba", "uapiTest": "uapi/tests/packActivityModel.test.ts:882c5ac213f83d8b57a6e5ff", - "packageIndex": "packages/protocol/src/index.js:a394466468bf6e59ee72b2f7", - "packageTypes": "packages/protocol/src/index.d.ts:1a6ef5f0300aceb3b4f34b9c", + "packageIndex": "packages/protocol/src/index.js:dca13a5eed71ff6eefbf450b", + "packageTypes": "packages/protocol/src/index.d.ts:d62198617b035b092ff9a207", "packageTest": "packages/protocol/test/v44-packs-portfolio-market-intelligence.test.js:ea02fa03d210e6480036fc0f", "generator": "scripts/generate-v44-packs-portfolio-market-intelligence.mjs:c106ef7138e3a330d405bec2", "checker": "scripts/check-v44-gate3-packs-portfolio-market-intelligence.mjs:0de0b87cbc96bb307cc1533a" diff --git a/.bitcode/v44-reading-budget-quote-policy.json b/.bitcode/v44-reading-budget-quote-policy.json index ff70e93f..dc488608 100644 --- a/.bitcode/v44-reading-budget-quote-policy.json +++ b/.bitcode/v44-reading-budget-quote-policy.json @@ -5,7 +5,7 @@ "currentTarget": "V43", "sourceSafetyVerdict": "source-safe-reading-budget-quote-policy-metadata", "generatedAt": "deterministic", - "artifactRoot": "v44-reading-budget-quote-policy:82b4d9dd98bcf1481d730756", + "artifactRoot": "v44-reading-budget-quote-policy:307a49e7f251b6221219c3c0", "passed": true, "objectIds": [ "ReadingBudgetPolicy", @@ -145,24 +145,24 @@ ], "sourceRoots": { "activePointer": "BITCODE_SPEC.txt:4ea77b214c66f69c697bff3d", - "spec": "BITCODE_SPEC_V44.md:e215c9d702cfca700f5c709b", - "delta": "BITCODE_SPEC_V44_DELTA.md:0ef890b5bb1435b44780ee4b", - "notes": "BITCODE_SPEC_V44_NOTES.md:951e0798b5d9c4f7f063a2da", - "parity": "BITCODE_SPEC_V44_PARITY_MATRIX.md:089ca0f30ddd7a1902e41a34", - "roadmap": "SPECIFICATIONS_ROADMAP.md:87d18b6eb15464c3c4249532", - "readme": "README.md:62cc39fe7b3cb4f730e581f9", - "protocolReadme": "packages/protocol/README.md:6af505bd152611328b055bbd", - "packageJson": "package.json:809fa4b7a82a5d58f10c365f", - "gateWorkflow": ".github/workflows/bitcode-gate-quality.yml:d97de3b662a26bc83c225e89", - "canonWorkflow": ".github/workflows/bitcode-canon-quality.yml:07a7006c556f6f107fac74a0", + "spec": "BITCODE_SPEC_V44.md:a4d88f93d1a0922bd13eae9a", + "delta": "BITCODE_SPEC_V44_DELTA.md:912d0160e79480df996b6b65", + "notes": "BITCODE_SPEC_V44_NOTES.md:7da533fe05878c5d115a5a8f", + "parity": "BITCODE_SPEC_V44_PARITY_MATRIX.md:e0bf0f41e7e6f943b87cc961", + "roadmap": "SPECIFICATIONS_ROADMAP.md:5f1707567badbcb00253b5ba", + "readme": "README.md:4bcf1513e419725def290466", + "protocolReadme": "packages/protocol/README.md:fd862cbe82eaadc11634ec63", + "packageJson": "package.json:23854aa3b132e2d162fcb121", + "gateWorkflow": ".github/workflows/bitcode-gate-quality.yml:09990dbe164dcf5022afcb7b", + "canonWorkflow": ".github/workflows/bitcode-canon-quality.yml:d5b37bf411e5febc12359b97", "economicModel": "packages/protocol/src/canonical/v44-economic-domain-model.js:21b8f5c80ad8322dff2909ed", "readModel": "uapi/app/read/read-route-model.ts:670e1abd63cccea6365a491f", - "readClient": "uapi/app/read/ReadPageClient.tsx:8c8219f42275485d4dffd327", + "readClient": "uapi/app/read/ReadPageClient.tsx:860bec675640bf466752bc7e", "readModelTest": "uapi/tests/readRouteModel.test.ts:5ad610c538f65fb0c860777f", "sourceToShares": "packages/btd/src/source-to-shares.ts:6e2e84251b29ba2477766708", "btcFeeOperation": "packages/btd/src/btc-fee-operation.ts:65f910e8e471fe199939e9c4", - "packageIndex": "packages/protocol/src/index.js:a394466468bf6e59ee72b2f7", - "packageTypes": "packages/protocol/src/index.d.ts:1a6ef5f0300aceb3b4f34b9c", + "packageIndex": "packages/protocol/src/index.js:dca13a5eed71ff6eefbf450b", + "packageTypes": "packages/protocol/src/index.d.ts:d62198617b035b092ff9a207", "packageSource": "packages/protocol/src/canonical/v44-reading-budget-quote-policy.js:d663034fe86ccbe85d5749f5", "packageTest": "packages/protocol/test/v44-reading-budget-quote-policy.test.js:2d9b19c509e0b28a829c44a3", "generator": "scripts/generate-v44-reading-budget-quote-policy.mjs:e2c376cb03ef80c210eef688", diff --git a/.github/workflows/bitcode-canon-quality.yml b/.github/workflows/bitcode-canon-quality.yml index b27dede3..d97469ad 100644 --- a/.github/workflows/bitcode-canon-quality.yml +++ b/.github/workflows/bitcode-canon-quality.yml @@ -382,6 +382,9 @@ jobs: if [ -f scripts/check-v44-gate7-organization-policy-wallet-authority.mjs ]; then node scripts/check-v44-gate7-organization-policy-wallet-authority.mjs --skip-branch-check --skip-uapi-tests --skip-package-tests fi + if [ -f scripts/check-v44-gate8-enterprise-product-ux.mjs ]; then + node scripts/check-v44-gate8-enterprise-product-ux.mjs --skip-branch-check --skip-uapi-tests --skip-package-tests + fi fi else echo "Unexpected BITCODE_SPEC.txt pointer: $POINTER" >&2 diff --git a/.github/workflows/bitcode-gate-quality.yml b/.github/workflows/bitcode-gate-quality.yml index 85229aab..16afbe30 100644 --- a/.github/workflows/bitcode-gate-quality.yml +++ b/.github/workflows/bitcode-gate-quality.yml @@ -511,6 +511,9 @@ jobs: if [ -f scripts/check-v44-gate7-organization-policy-wallet-authority.mjs ]; then node scripts/check-v44-gate7-organization-policy-wallet-authority.mjs --skip-branch-check --skip-uapi-tests --skip-package-tests fi + if [ -f scripts/check-v44-gate8-enterprise-product-ux.mjs ]; then + node scripts/check-v44-gate8-enterprise-product-ux.mjs --skip-branch-check --skip-uapi-tests --skip-package-tests + fi fi else echo "Unexpected BITCODE_SPEC.txt pointer: $POINTER" >&2 @@ -564,6 +567,9 @@ jobs: if [ "$POINTER" = "V43" ] && [ -f scripts/check-v44-gate7-organization-policy-wallet-authority.mjs ]; then node scripts/check-v44-gate7-organization-policy-wallet-authority.mjs --skip-branch-check --skip-uapi-tests --skip-package-tests fi + if [ "$POINTER" = "V43" ] && [ -f scripts/check-v44-gate8-enterprise-product-ux.mjs ]; then + node scripts/check-v44-gate8-enterprise-product-ux.mjs --skip-branch-check --skip-uapi-tests --skip-package-tests + fi if [ "$POINTER" != "V43" ]; then if [ -f scripts/check-v43-gate1-packs-read-deposit-roadmap.mjs ]; then node scripts/check-v43-gate1-packs-read-deposit-roadmap.mjs --skip-branch-check diff --git a/BITCODE_SPEC_V44.md b/BITCODE_SPEC_V44.md index 6cf6cd4a..5d18eabb 100644 --- a/BITCODE_SPEC_V44.md +++ b/BITCODE_SPEC_V44.md @@ -3,12 +3,12 @@ ## Status - Version: `V44` -- V44 state: draft Gate 7 organization policy wallet authority work over promoted V43 product routes +- V44 state: draft Gate 8 enterprise product UX work over promoted V43 product routes - Current canonical/latest target: `V43` - Prior canonical anchor: `BITCODE_SPEC_V43.md` - Prior generated proof appendix: `BITCODE_SPEC_V43_PROVEN.md` -- Generated structured artifact inventory: draft `.bitcode/v44-*` artifacts now include Gate 2 economic domain, Gate 3 Packs portfolio market intelligence, Gate 4 Reading budget quote policy, Gate 5 Depositor earnings supply opportunity, Gate 6 BTD/BTC compensation statement, and Gate 7 organization policy wallet authority reports; all remain source-safe metadata only -- Source parity state: V44 begins from promoted `/packs`, `/read`, `/deposit`, agentic Depositing, five-step Reading, BTD/BTC settlement, and PackActivity canon; Gate 7 binds source-safe organization roles, budget approvals, source criticality approvals, spend/deposit limits, wallet authority, route action statements, and `/packs` governance readback without exposing unpaid source, wallet private material, or admitting value-bearing mainnet +- Generated structured artifact inventory: draft `.bitcode/v44-*` artifacts now include Gate 2 economic domain, Gate 3 Packs portfolio market intelligence, Gate 4 Reading budget quote policy, Gate 5 Depositor earnings supply opportunity, Gate 6 BTD/BTC compensation statement, Gate 7 organization policy wallet authority, and Gate 8 enterprise product UX reports; all remain source-safe metadata only +- Source parity state: V44 begins from promoted `/packs`, `/read`, `/deposit`, agentic Depositing, five-step Reading, BTD/BTC settlement, and PackActivity canon; Gate 8 binds source-safe enterprise economic summaries, keyboard navigation, dense Packs activity table operation, and expandable proof detail across `/packs`, `/read`, and `/deposit` without exposing unpaid source, wallet private material, raw inference payloads, or admitting value-bearing mainnet - Notes companion: `BITCODE_SPEC_V44_NOTES.md` - Delta companion: `BITCODE_SPEC_V44_DELTA.md` - Parity companion: `BITCODE_SPEC_V44_PARITY_MATRIX.md` @@ -310,6 +310,23 @@ Gate 8 must make portfolio, budget, compensation, market signal, and governance surfaces legible and polished: dense tables, expandable proof detail, keyboard navigation, responsive layouts, concise copy, and visual regression coverage. +Gate 8 closes through `V44EnterpriseProductUx` in +`packages/protocol/src/canonical/v44-enterprise-product-ux.js`, +deterministic `.bitcode/v44-enterprise-product-ux.json`, +`generate:v44-enterprise-product-ux`, `check:v44-enterprise-product-ux`, +and `check:v44-gate8`. The shared product route shell now exposes +`ProductRouteEnterpriseSummary`, `ProductRouteKeyboardHint`, and +`ProductRouteProofDetail`. `/packs` renders an enterprise economy overview, +keyboard navigation, a sticky dense economic operation table, and expandable +accounting/governance/proof roots. `/read` renders Reading economy summary, +keyboard navigation, and route/procurement/authority proof detail. `/deposit` +renders Depositing economy summary, keyboard navigation, and synthesis, +policy, admission, earnings, and authority proof detail. Focused tests bind +the visual regression hooks and source-safe expansion controls without +serializing protected source, raw source text, unpaid AssetPack source, raw +prompts, raw provider responses, credentials, wallet private material, +private settlement payloads, or value-bearing mainnet admission. + ## V44 Gate 9 Scaled Local/Staging Network Rehearsal Gate 9 must rehearse many deposits, many Reads, many Fits, many quotes, many @@ -655,7 +672,7 @@ quality, accessibility, visual inspectability, and generated quality evidence. | `.bitcode/v44-depositor-earnings-supply-opportunities.json` | depositor earnings and supply opportunities | implemented-source-safe | | `.bitcode/v44-btd-btc-compensation-statements.json` | BTD/BTC compensation statements | implemented-source-safe | | `.bitcode/v44-organization-policy-wallet-authority.json` | organization policy and wallet authority | implemented-source-safe | -| `.bitcode/v44-enterprise-economic-ux.json` | enterprise economic UX | planned | +| `.bitcode/v44-enterprise-product-ux.json` | enterprise product UX | implemented-source-safe | | `.bitcode/v44-scaled-network-rehearsal.json` | scaled network rehearsal | planned | | `.bitcode/v44-promotion-readiness-report.json` | promotion readiness | planned | @@ -667,7 +684,7 @@ Required draft artifacts include `.bitcode/v44-economic-domain-model.json`, `.bitcode/v44-depositor-earnings-supply-opportunities.json`, `.bitcode/v44-btd-btc-compensation-statements.json`, `.bitcode/v44-organization-policy-wallet-authority.json`, -`.bitcode/v44-enterprise-economic-ux.json`, +`.bitcode/v44-enterprise-product-ux.json`, `.bitcode/v44-scaled-network-rehearsal.json`, and `.bitcode/v44-promotion-readiness-report.json`. @@ -739,6 +756,8 @@ Gate 7 validates with `pnpm run generate:v44-organization-policy-wallet-authority`, `pnpm run check:v44-organization-policy-wallet-authority`, and `pnpm run check:v44-gate7`. +Gate 8 validates with `pnpm run generate:v44-enterprise-product-ux`, +`pnpm run check:v44-enterprise-product-ux`, and `pnpm run check:v44-gate8`. Shared draft posture validates with `node scripts/check-bitcode-spec-family.mjs --version V44 --mode draft --current-target V43`, `node scripts/check-bitcode-canon-posture-drift.mjs --active-canon V43 --draft-target V44`, @@ -816,7 +835,7 @@ Inherited. | `.bitcode/v44-depositor-earnings-supply-opportunities.json` | depositor earning opportunity | implemented-source-safe | | `.bitcode/v44-btd-btc-compensation-statements.json` | BTD/BTC/source-to-shares statement | implemented-source-safe | | `.bitcode/v44-organization-policy-wallet-authority.json` | organization policy and wallet authority | implemented-source-safe | -| `.bitcode/v44-enterprise-economic-ux.json` | enterprise economic UX | planned | +| `.bitcode/v44-enterprise-product-ux.json` | enterprise product UX | implemented-source-safe | | `.bitcode/v44-scaled-network-rehearsal.json` | scaled rehearsal | planned | | `.bitcode/v44-promotion-readiness-report.json` | promotion readiness | planned | @@ -833,6 +852,7 @@ Gate 5 adds deterministic `.bitcode/v44-depositor-earnings-supply-opportunities.json`. Gate 6 adds deterministic `.bitcode/v44-btd-btc-compensation-statements.json`. Gate 7 adds deterministic `.bitcode/v44-organization-policy-wallet-authority.json`. +Gate 8 adds deterministic `.bitcode/v44-enterprise-product-ux.json`. ### Shared generated-artifact fields diff --git a/BITCODE_SPEC_V44_DELTA.md b/BITCODE_SPEC_V44_DELTA.md index 81220a66..cec1aec1 100644 --- a/BITCODE_SPEC_V44_DELTA.md +++ b/BITCODE_SPEC_V44_DELTA.md @@ -3,12 +3,12 @@ ## Status - Version: `V44` -- V44 state: draft Gate 7 organization policy wallet authority work over promoted V43 +- V44 state: draft Gate 8 enterprise product UX work over promoted V43 - Current canonical/latest target: `V43` - Prior canonical anchor: `BITCODE_SPEC_V43.md` - Prior generated proof appendix: `BITCODE_SPEC_V43_PROVEN.md` -- Generated structured artifact inventory: Gate 2 adds deterministic `.bitcode/v44-economic-domain-model.json`; Gate 3 adds deterministic `.bitcode/v44-packs-portfolio-market-intelligence.json`; Gate 4 adds deterministic `.bitcode/v44-reading-budget-quote-policy.json`; Gate 5 adds deterministic `.bitcode/v44-depositor-earnings-supply-opportunities.json`; Gate 6 adds deterministic `.bitcode/v44-btd-btc-compensation-statements.json`; Gate 7 adds deterministic `.bitcode/v44-organization-policy-wallet-authority.json` -- Source parity state: Gate 7 binds package-backed organization policy wallet authority, BTD deposit authority actions, `/read` and `/deposit` authority readback, `/packs` governance readback, docs, workflow, package scripts, checker, and protocol/package/UAPI tests +- Generated structured artifact inventory: Gate 2 adds deterministic `.bitcode/v44-economic-domain-model.json`; Gate 3 adds deterministic `.bitcode/v44-packs-portfolio-market-intelligence.json`; Gate 4 adds deterministic `.bitcode/v44-reading-budget-quote-policy.json`; Gate 5 adds deterministic `.bitcode/v44-depositor-earnings-supply-opportunities.json`; Gate 6 adds deterministic `.bitcode/v44-btd-btc-compensation-statements.json`; Gate 7 adds deterministic `.bitcode/v44-organization-policy-wallet-authority.json`; Gate 8 adds deterministic `.bitcode/v44-enterprise-product-ux.json` +- Source parity state: Gate 8 binds package-backed enterprise product UX proof, shared route UX primitives, `/packs` dense economic operation table and proof detail, `/read` economic summary and proof detail, `/deposit` economic summary and proof detail, docs, workflow, package scripts, checker, and protocol/UAPI tests - Notes companion: `BITCODE_SPEC_V44_NOTES.md` - Delta companion: `BITCODE_SPEC_V44_DELTA.md` - Parity companion: `BITCODE_SPEC_V44_PARITY_MATRIX.md` @@ -93,6 +93,19 @@ execute value-bearing mainnet movement, or let policy bypass Need review, Finding Fits, settlement, BTD rights transfer, delivery, or source-to-shares law. +V44 Gate 8 closes enterprise product UX for economic operation. It adds +package-backed `V44EnterpriseProductUx`; deterministic +`.bitcode/v44-enterprise-product-ux.json`; shared +`ProductRouteEnterpriseSummary`, `ProductRouteKeyboardHint`, and +`ProductRouteProofDetail` primitives; `/packs` enterprise economy overview, +keyboard navigation, sticky dense activity table, and expandable proof detail; +`/read` Reading economy overview and route/procurement/authority proof detail; +`/deposit` Depositing economy overview and synthesis/policy/admission/earning/ +authority proof detail; focused route tests; and `check:v44-gate8`. It does +not disclose protected source, raw source text, unpaid AssetPack source, raw +prompts, provider payloads, credentials, wallet private material, private +settlement payloads, or value-bearing mainnet operation. + ## Pre-Implementation Sequence 1. Open V44 spec family, roadmap, checker, package script, workflow posture, @@ -104,8 +117,8 @@ law. 5. Add deposit revenue, demand, ROI, and supply opportunity readback. 6. Add BTD/BTC/source-to-shares compensation statements and reconciliation. 7. Add organization policy, approval, spend authority, and wallet authority. -8. Rehearse scaled many-pack local/staging-testnet economic operation. -9. Polish enterprise economy UX and operator dashboards. +8. Polish enterprise economy UX and operator dashboards. +9. Rehearse scaled many-pack local/staging-testnet economic operation. 10. Close V44 promotion readiness and prepare active V44 / draft V45 posture. ## Validation direction @@ -132,6 +145,8 @@ Gate 7 validates with `pnpm run generate:v44-organization-policy-wallet-authority`, `pnpm run check:v44-organization-policy-wallet-authority`, and `pnpm run check:v44-gate7`. +Gate 8 validates with `pnpm run generate:v44-enterprise-product-ux`, +`pnpm run check:v44-enterprise-product-ux`, and `pnpm run check:v44-gate8`. Shared draft posture validates with `node scripts/check-bitcode-spec-family.mjs --version V44 --mode draft --current-target V43`, `node scripts/check-bitcode-canon-posture-drift.mjs --active-canon V43 --draft-target V44`, diff --git a/BITCODE_SPEC_V44_NOTES.md b/BITCODE_SPEC_V44_NOTES.md index 320d7a0e..743af2bd 100644 --- a/BITCODE_SPEC_V44_NOTES.md +++ b/BITCODE_SPEC_V44_NOTES.md @@ -3,12 +3,12 @@ ## Status - Version: `V44` -- V44 state: draft notes include Gate 7 organization policy wallet authority work over promoted V43 +- V44 state: draft notes include Gate 8 enterprise product UX work over promoted V43 - Current canonical/latest target: `V43` - Prior canonical anchor: `BITCODE_SPEC_V43.md` - Prior generated proof appendix: `BITCODE_SPEC_V43_PROVEN.md` -- Generated structured artifact inventory: Gate 2 adds deterministic `.bitcode/v44-economic-domain-model.json`; Gate 3 adds deterministic `.bitcode/v44-packs-portfolio-market-intelligence.json`; Gate 4 adds deterministic `.bitcode/v44-reading-budget-quote-policy.json`; Gate 5 adds deterministic `.bitcode/v44-depositor-earnings-supply-opportunities.json`; Gate 6 adds deterministic `.bitcode/v44-btd-btc-compensation-statements.json`; Gate 7 adds deterministic `.bitcode/v44-organization-policy-wallet-authority.json` -- Source parity state: notes align roadmap, docs, workflow posture, package source, generated artifact, receipt taxonomy, `/packs` portfolio market intelligence, accounting and governance readback, `/read` budget quote policy and organization authority, and `/deposit` earning supply opportunity and deposit authority for active V43 / draft V44 +- Generated structured artifact inventory: Gate 2 adds deterministic `.bitcode/v44-economic-domain-model.json`; Gate 3 adds deterministic `.bitcode/v44-packs-portfolio-market-intelligence.json`; Gate 4 adds deterministic `.bitcode/v44-reading-budget-quote-policy.json`; Gate 5 adds deterministic `.bitcode/v44-depositor-earnings-supply-opportunities.json`; Gate 6 adds deterministic `.bitcode/v44-btd-btc-compensation-statements.json`; Gate 7 adds deterministic `.bitcode/v44-organization-policy-wallet-authority.json`; Gate 8 adds deterministic `.bitcode/v44-enterprise-product-ux.json` +- Source parity state: notes align roadmap, docs, workflow posture, package source, generated artifact, receipt taxonomy, `/packs` portfolio market intelligence, accounting/governance readback and enterprise proof expansion, `/read` budget quote policy, organization authority and proof detail, and `/deposit` earning supply opportunity, deposit authority and proof detail for active V43 / draft V44 - Scope: V44 notes for digitizing and tokenizing scaled engineering economies through enterprise AssetPack portfolio, market intelligence, BTD/BTC accounting, governance, and compensation operation - Last fully realized canonical target preserved in source: `V43` @@ -139,6 +139,19 @@ policy as governance readback. It cannot disclose protected source, unpaid AssetPack source, raw prompts, provider responses, credentials, wallet private material, private settlement payloads, or value-bearing mainnet authority. +## Gate 8 note + +Gate 8 makes the already-implemented V44 economic state operable by enterprise +users. The route layer can show dense source-safe economic summaries, keyboard +navigation affordances, sticky activity tables, expandable proof roots, and +responsive low-detail defaults that still expand into full metadata. `/packs` +becomes the main economic operation table; `/read` shows quote, budget, +settlement, and authority roots; `/deposit` shows option synthesis, policy, +admission, earnings, and authority roots. It cannot expose protected source, +raw source text, unpaid AssetPack source, raw prompts, provider responses, +credentials, wallet private material, private settlement payloads, or +value-bearing mainnet authority. + ## Gate 3 note Gate 3 makes `/packs` the first scaled economic inspection surface. It keeps diff --git a/BITCODE_SPEC_V44_PARITY_MATRIX.md b/BITCODE_SPEC_V44_PARITY_MATRIX.md index 484f9b21..6558e408 100644 --- a/BITCODE_SPEC_V44_PARITY_MATRIX.md +++ b/BITCODE_SPEC_V44_PARITY_MATRIX.md @@ -3,12 +3,12 @@ ## Status - Version: `V44` -- V44 state: draft parity includes Gate 7 organization policy wallet authority work +- V44 state: draft parity includes Gate 8 enterprise product UX work - Current canonical/latest target: `V43` - Prior canonical anchor: `BITCODE_SPEC_V43.md` - Prior generated proof appendix: `BITCODE_SPEC_V43_PROVEN.md` -- Generated structured artifact inventory: Gate 2 adds deterministic `.bitcode/v44-economic-domain-model.json`; Gate 3 adds deterministic `.bitcode/v44-packs-portfolio-market-intelligence.json`; Gate 4 adds deterministic `.bitcode/v44-reading-budget-quote-policy.json`; Gate 5 adds deterministic `.bitcode/v44-depositor-earnings-supply-opportunities.json`; Gate 6 adds deterministic `.bitcode/v44-btd-btc-compensation-statements.json`; Gate 7 adds deterministic `.bitcode/v44-organization-policy-wallet-authority.json` -- Source parity state: Gate 7 requires package/route/UI/docs/workflow/checker/test parity for organization policy wallet authority and Packs governance readback +- Generated structured artifact inventory: Gate 2 adds deterministic `.bitcode/v44-economic-domain-model.json`; Gate 3 adds deterministic `.bitcode/v44-packs-portfolio-market-intelligence.json`; Gate 4 adds deterministic `.bitcode/v44-reading-budget-quote-policy.json`; Gate 5 adds deterministic `.bitcode/v44-depositor-earnings-supply-opportunities.json`; Gate 6 adds deterministic `.bitcode/v44-btd-btc-compensation-statements.json`; Gate 7 adds deterministic `.bitcode/v44-organization-policy-wallet-authority.json`; Gate 8 adds deterministic `.bitcode/v44-enterprise-product-ux.json` +- Source parity state: Gate 8 requires package/route/UI/docs/workflow/checker/test parity for enterprise product UX across `/packs`, `/read`, and `/deposit` - Scope: parity for V44 enterprise economic operation over promoted V43 product routes - Last fully realized canonical target preserved in source: `V43` @@ -35,7 +35,7 @@ artifacts, workflow checks, and local/staging rehearsal receipts. | Depositor earnings | ROI, demand, compensation opportunity, supply recommendations through `.bitcode/v44-depositor-earnings-supply-opportunities.json` | implemented | | Accounting statements | BTD/BTC/source-to-shares statements and reconciliation through `.bitcode/v44-btd-btc-compensation-statements.json` | implemented | | Organization governance | Roles, budgets, wallet authority, source criticality, approvals through `.bitcode/v44-organization-policy-wallet-authority.json` | implemented | -| Enterprise UX | Dense economic surfaces, proof expansion, responsive/accessibility proof | drafted | +| Enterprise UX | Dense economic surfaces, proof expansion, responsive/accessibility proof through `.bitcode/v44-enterprise-product-ux.json` | implemented | | Scaled rehearsal | Many-pack, many-org local/staging-testnet economic rehearsal | drafted | | Promotion readiness | Generated PROVEN, workflow, all V44 artifacts bound | drafted | diff --git a/README.md b/README.md index 79972eec..e2b2d8a9 100644 --- a/README.md +++ b/README.md @@ -362,6 +362,21 @@ source text, unpaid AssetPack source, prompts, provider payloads, credentials, wallet private material, private settlement payloads, and value-bearing mainnet operation. +V44 Gate 8 adds `V44EnterpriseProductUx`, +`.bitcode/v44-enterprise-product-ux.json`, +`generate:v44-enterprise-product-ux`, +`check:v44-enterprise-product-ux`, and `check:v44-gate8`. It makes the scaled +engineering economy operable through shared `ProductRouteEnterpriseSummary`, +`ProductRouteKeyboardHint`, and `ProductRouteProofDetail` primitives; +source-safe enterprise economy summaries on `/packs`, `/read`, and `/deposit`; +keyboard navigation hints; a sticky dense Pack activity table; expandable +proof detail roots for portfolio, Reading procurement, deposit synthesis, +earnings, and organization authority; focused route tests; protocol tests; and +workflow wiring while continuing to withhold protected source, raw source text, +unpaid AssetPack source, prompts, provider payloads, credentials, wallet +private material, private settlement payloads, and value-bearing mainnet +operation. + Exchange is inherited V36 canon: market-wide activity master-detail, buy/sell/ bid/ask/cancel/accept/settle/history flows, AssetPack range trading, rights-transfer review, pricing/liquidity/wrapper analysis, settlement diff --git a/SPECIFICATIONS_ROADMAP.md b/SPECIFICATIONS_ROADMAP.md index a16ae893..6743ec83 100644 --- a/SPECIFICATIONS_ROADMAP.md +++ b/SPECIFICATIONS_ROADMAP.md @@ -5,8 +5,8 @@ - Current active canonical pointer: `BITCODE_SPEC.txt` -> `V43` - Current active canon: `BITCODE_SPEC_V43.md` - Current draft target: `BITCODE_SPEC_V44.md`. -- Current working gate: V44 Gate 7 Organization Policy, Approval, And Wallet Authority. -- Next queued work after V44 Gate 7: enterprise UX, scaled local/staging rehearsal, and V44 promotion readiness. +- Current working gate: V44 Gate 8 Enterprise Product UX For Economic Operation. +- Next queued work after V44 Gate 8: scaled local/staging rehearsal and V44 promotion readiness. - Latest closed version: V43 Route Product Cleanup, which promoted `/packs`, `/read`, and `/deposit`; PackActivity master-detail; five-step Reading route UX; deposit AssetPack option synthesis; deposit criticality/ROI/compensation policy; option admission; product route UX; cross-route rehearsal; and V43 promotion readiness. - Recent V43 canonical promotion anchor: V43 canonical promotion updated `BITCODE_SPEC.txt` to `V43`, generated `BITCODE_SPEC_V43_PROVEN.md`, preserved active V43 / draft V44 runtime posture, and closed route-product cleanup canon. - V44 Gate 1 opening anchor: scaled engineering economy opens over promoted V43 with V44 SPEC, DELTA, NOTES, and PARITY files, `check:v44-gate1`, active V43 / draft V44 posture, and a ten-gate plan for economic domain models, Packs portfolio intelligence, Reading budget/quote governance, Depositor earnings/ROI intelligence, BTD/BTC compensation statements, organization policy/wallet authority, enterprise economic UX, scaled local/staging rehearsal, and promotion readiness. @@ -16,6 +16,7 @@ - V44 Gate 5 closure anchor: scaled engineering economy now owns package-backed `V44DepositorEarningsSupplyOpportunities`, deterministic `.bitcode/v44-depositor-earnings-supply-opportunities.json`, `DepositorEarningSupplyIntelligence`, source-safe likely demand, unfit Need opportunities, ROI posture, source criticality posture, estimate-only BTC compensation ranges, earning statements, source-to-shares proof boundaries, supply recommendations, `/deposit` route UI readback, package exports, pipeline/package/UAPI/protocol tests, workflow wiring, and `check:v44-gate5`. - V44 Gate 6 closure anchor: scaled engineering economy now owns package-backed `V44BtdBtcCompensationStatements`, deterministic `.bitcode/v44-btd-btc-compensation-statements.json`, `BtdBtcCompensationStatements`, source-safe BTD range accounting, BTC settlement observations, source-to-shares contributor compensation statements, depositor earning summaries, treasury routes, ledger/database/object-storage reconciliation, repair statements, `/packs` accounting readback, package exports, pipeline/package/UAPI/protocol tests, workflow wiring, and `check:v44-gate6`. - V44 Gate 7 closure anchor: scaled engineering economy now owns package-backed `V44OrganizationPolicyWalletAuthority`, deterministic `.bitcode/v44-organization-policy-wallet-authority.json`, BTD Reading/deposit authority actions, source-safe organization budget approvals, source criticality approvals, spend/deposit limits, wallet authority, `/read` authority readback, `/deposit` authority readback, `/packs` governance readback, package exports, pipeline/package/UAPI/protocol tests, workflow wiring, and `check:v44-gate7`. +- V44 Gate 8 closure anchor: scaled engineering economy now owns package-backed `V44EnterpriseProductUx`, deterministic `.bitcode/v44-enterprise-product-ux.json`, shared `ProductRouteEnterpriseSummary`, `ProductRouteKeyboardHint`, and `ProductRouteProofDetail` primitives, `/packs` enterprise economy overview, keyboard navigation, sticky dense activity grid, expandable proof detail, `/read` Reading economy overview and route/procurement/authority proof detail, `/deposit` Depositing economy overview and synthesis/policy/admission/earnings/authority proof detail, focused route tests, protocol tests, workflow wiring, and `check:v44-gate8`. - Latest prior closed version: V42 Reliable MVP Experience, which promoted shortest-path Depositing, five-step Reading, ReadNeed review/resynthesis, ReadFitsFinding source-safe preview and quote, settlement rights transfer, repository delivery, AI-reading demonstration, local/staging MVP rehearsal, and V42 promotion readiness. - Recent V42 canonical promotion anchor: V42 canonical promotion updated `BITCODE_SPEC.txt` to `V42`, generated `BITCODE_SPEC_V42_PROVEN.md`, preserved active V42 / draft V43 runtime posture, and closed reliable MVP experience canon. - Recent V42 opening anchor: reliable MVP experience opens over promoted V41 with V42 SPEC, DELTA, NOTES, and PARITY files, `check:v42-gate1`, active V41 / draft V42 posture, and a nine-gate plan for shortest-path Depositing, five-step Reading, ReadNeed product closure, ReadFitsFinding preview and quote closure, settlement and repository delivery, AI-reading demonstration, local/staging rehearsal, and promotion readiness. diff --git a/package.json b/package.json index 545f1380..d4905c2c 100644 --- a/package.json +++ b/package.json @@ -377,6 +377,9 @@ "generate:v44-organization-policy-wallet-authority": "node scripts/generate-v44-organization-policy-wallet-authority.mjs", "check:v44-organization-policy-wallet-authority": "node scripts/generate-v44-organization-policy-wallet-authority.mjs --check", "check:v44-gate7": "node scripts/check-v44-gate7-organization-policy-wallet-authority.mjs", + "generate:v44-enterprise-product-ux": "node scripts/generate-v44-enterprise-product-ux.mjs", + "check:v44-enterprise-product-ux": "node scripts/generate-v44-enterprise-product-ux.mjs --check", + "check:v44-gate8": "node scripts/check-v44-gate8-enterprise-product-ux.mjs", "generate:v38-inference-surface-inventory": "node scripts/generate-v38-inference-surface-inventory.mjs", "check:v38-inference-surface-inventory": "node scripts/generate-v38-inference-surface-inventory.mjs --check", "check:v38-gate2": "node scripts/check-v38-gate2-inference-surface-inventory.mjs", diff --git a/packages/protocol/README.md b/packages/protocol/README.md index 3e42f448..9a7ebceb 100644 --- a/packages/protocol/README.md +++ b/packages/protocol/README.md @@ -254,6 +254,18 @@ policy, budget approval, source criticality approval, spend/deposit limits, wallet authority, `/read` and `/deposit` authority readback, `/packs` governance readback, package exports, workflow wiring, and source-safety tests. +V44 Gate 8 adds `V44EnterpriseProductUx` through +`packages/protocol/src/canonical/v44-enterprise-product-ux.js`, +`packages/protocol/test/v44-enterprise-product-ux.test.js`, +`.bitcode/v44-enterprise-product-ux.json`, +`generate:v44-enterprise-product-ux`, +`check:v44-enterprise-product-ux`, and `check:v44-gate8`. It binds shared +enterprise UX primitives, `/packs` dense economic operation, `/read` +procurement proof readback, `/deposit` synthesis/earnings/authority proof +readback, route tests, package exports, workflow wiring, generated artifact +freshness, and source-safety tests for the enterprise economic operation +surface. + Historical V39 promotion moved this package through the `V39` active, `V40` draft posture. V40 promotion has since advanced the current package posture to `V40` active, `V41` draft. diff --git a/packages/protocol/src/canonical/v44-enterprise-product-ux.js b/packages/protocol/src/canonical/v44-enterprise-product-ux.js new file mode 100644 index 00000000..17af5358 --- /dev/null +++ b/packages/protocol/src/canonical/v44-enterprise-product-ux.js @@ -0,0 +1,408 @@ +// @ts-check + +import crypto from 'node:crypto'; +import { existsSync, readFileSync } from 'node:fs'; +import path from 'node:path'; +import { fileURLToPath } from 'node:url'; + +const __filename = fileURLToPath(import.meta.url); +const __dirname = path.dirname(__filename); +const DEFAULT_REPO_ROOT = path.resolve(__dirname, '..', '..', '..', '..'); + +export const V44_ENTERPRISE_PRODUCT_UX_ARTIFACT_PATH = + '.bitcode/v44-enterprise-product-ux.json'; +export const V44_ENTERPRISE_PRODUCT_UX_SCHEMA_ID = + 'bitcode.v44.enterpriseProductUx.v1'; +export const V44_ENTERPRISE_PRODUCT_UX_VERSION = 'V44'; +export const V44_ENTERPRISE_PRODUCT_UX_CURRENT_TARGET = 'V43'; +export const V44_ENTERPRISE_PRODUCT_UX_SOURCE_SAFETY_VERDICT = + 'source-safe-enterprise-product-ux-metadata'; + +export const V44_ENTERPRISE_PRODUCT_UX_OBJECT_IDS = Object.freeze([ + 'ProductRouteEnterpriseSummary', + 'ProductRouteKeyboardHint', + 'ProductRouteProofDetail', + 'PacksEnterpriseEconomicSummary', + 'ReadEnterpriseEconomicSummary', + 'DepositEnterpriseEconomicSummary', + 'PackActivityEconomicOperationTable', + 'ExpandableEconomicProofDetail', +]); + +export const V44_ENTERPRISE_PRODUCT_UX_ROUTE_IDS = Object.freeze([ + '/packs', + '/read', + '/deposit', +]); + +export const V44_ENTERPRISE_PRODUCT_UX_CAPABILITY_IDS = Object.freeze([ + 'dense-economic-summary', + 'keyboard-navigation', + 'responsive-economic-layout', + 'expandable-proof-detail', + 'sticky-pack-activity-table', + 'source-safe-disclosure-boundary', + 'visual-regression-test-hooks', +]); + +export const V44_ENTERPRISE_PRODUCT_UX_FORBIDDEN_PAYLOAD_IDS = Object.freeze([ + 'protected-source-payloads', + 'raw-source-text', + 'unpaid-assetpack-source', + 'raw-prompts', + 'interpolated-prompts', + 'raw-provider-responses', + 'credentials', + 'wallet-private-material', + 'private-settlement-payloads', + 'value-bearing-mainnet-admission', +]); + +const SOURCE_ROOTS = Object.freeze({ + activePointer: 'BITCODE_SPEC.txt', + spec: 'BITCODE_SPEC_V44.md', + delta: 'BITCODE_SPEC_V44_DELTA.md', + notes: 'BITCODE_SPEC_V44_NOTES.md', + parity: 'BITCODE_SPEC_V44_PARITY_MATRIX.md', + roadmap: 'SPECIFICATIONS_ROADMAP.md', + readme: 'README.md', + protocolReadme: 'packages/protocol/README.md', + packageJson: 'package.json', + gateWorkflow: '.github/workflows/bitcode-gate-quality.yml', + canonWorkflow: '.github/workflows/bitcode-canon-quality.yml', + productRouteShell: 'uapi/components/base/bitcode/routes/product-route-shell.tsx', + packsClient: 'uapi/app/packs/PacksPageClient.tsx', + readClient: 'uapi/app/read/ReadPageClient.tsx', + depositClient: 'uapi/app/deposit/DepositPageClient.tsx', + packsTest: 'uapi/tests/packsPageClient.test.tsx', + readTest: 'uapi/tests/readPageClient.test.tsx', + depositTest: 'uapi/tests/depositPageClient.test.tsx', + protocolIndex: 'packages/protocol/src/index.js', + protocolTypes: 'packages/protocol/src/index.d.ts', + protocolSource: 'packages/protocol/src/canonical/v44-enterprise-product-ux.js', + protocolTest: 'packages/protocol/test/v44-enterprise-product-ux.test.js', + generator: 'scripts/generate-v44-enterprise-product-ux.mjs', + checker: 'scripts/check-v44-gate8-enterprise-product-ux.mjs', +}); + +function digest(value) { + return crypto.createHash('sha256').update(value).digest('hex').slice(0, 24); +} + +function readSource(repoRoot, sourcePath) { + const absolutePath = path.join(repoRoot, sourcePath); + return existsSync(absolutePath) ? readFileSync(absolutePath, 'utf8') : ''; +} + +function predicateResult(id, sourcePath, passed) { + return { id, sourcePath, passed: Boolean(passed) }; +} + +export const V44_ENTERPRISE_PRODUCT_UX_ROWS = Object.freeze([ + { + rowId: 'shared-enterprise-ux-primitives', + owner: SOURCE_ROOTS.productRouteShell, + contract: + 'Product route shell exposes shared enterprise summary, keyboard navigation, and proof-detail primitives for source-safe economic operation.', + requiredFields: [ + 'ProductRouteEnterpriseSummary', + 'ProductRouteKeyboardHint', + 'ProductRouteProofDetail', + 'data-enterprise-ux', + ], + }, + { + rowId: 'packs-economic-operation', + owner: SOURCE_ROOTS.packsClient, + contract: + '/packs renders portfolio economy overview, keyboard navigation, sticky dense activity grid, and expandable proof detail.', + requiredFields: [ + 'packs-enterprise-economic-summary', + 'packs-keyboard-navigation', + 'packs-enterprise-activity-grid', + 'packs-expandable-proof-detail', + ], + }, + { + rowId: 'read-economic-operation', + owner: SOURCE_ROOTS.readClient, + contract: + '/read renders Reading economy overview, keyboard navigation, and route/procurement/authority proof roots.', + requiredFields: [ + 'read-enterprise-economic-summary', + 'read-keyboard-navigation', + 'read-expandable-proof-detail', + 'Reading economy overview', + ], + }, + { + rowId: 'deposit-economic-operation', + owner: SOURCE_ROOTS.depositClient, + contract: + '/deposit renders Depositing economy overview, keyboard navigation, and synthesis/policy/admission/earnings/authority proof roots.', + requiredFields: [ + 'deposit-enterprise-economic-summary', + 'deposit-keyboard-navigation', + 'deposit-expandable-proof-detail', + 'Depositing economy overview', + ], + }, + { + rowId: 'focused-route-tests', + owner: SOURCE_ROOTS.packsTest, + contract: + 'Focused route tests cover enterprise summaries, keyboard hints, proof detail, and source-safe table/detail hooks.', + requiredFields: [ + 'packs-enterprise-economic-summary', + 'read-enterprise-economic-summary', + 'deposit-enterprise-economic-summary', + ], + }, + { + rowId: 'workflow-and-artifact-wiring', + owner: SOURCE_ROOTS.checker, + contract: + 'Gate 8 closes only when generator, checker, protocol exports, docs, workflows, focused tests, and generated artifact are current.', + requiredFields: [ + 'check-v44-gate8-enterprise-product-ux', + 'generate-v44-enterprise-product-ux', + ], + }, +]); + +function buildPredicateResults(repoRoot) { + const sources = Object.fromEntries( + Object.entries(SOURCE_ROOTS).map(([key, sourcePath]) => [ + key, + readSource(repoRoot, sourcePath), + ]), + ); + + return [ + predicateResult( + 'active-canon-pointer-remains-v43', + SOURCE_ROOTS.activePointer, + sources.activePointer.trim() === 'V43', + ), + predicateResult( + 'spec-defines-gate8', + SOURCE_ROOTS.spec, + sources.spec.includes('V44 Gate 8 Enterprise Product UX For Economic Operation'), + ), + predicateResult( + 'spec-names-gate8-artifact', + SOURCE_ROOTS.spec, + sources.spec.includes('v44-enterprise-product-ux'), + ), + predicateResult( + 'delta-records-gate8', + SOURCE_ROOTS.delta, + sources.delta.includes('Gate 8') && sources.delta.includes('v44-enterprise-product-ux'), + ), + predicateResult( + 'notes-records-gate8', + SOURCE_ROOTS.notes, + sources.notes.includes('Gate 8') && sources.notes.includes('enterprise product UX'), + ), + predicateResult( + 'parity-records-gate8', + SOURCE_ROOTS.parity, + sources.parity.includes('v44-enterprise-product-ux'), + ), + predicateResult( + 'roadmap-records-gate8', + SOURCE_ROOTS.roadmap, + sources.roadmap.includes('V44 Gate 8 closure anchor'), + ), + predicateResult( + 'readme-records-gate8', + SOURCE_ROOTS.readme, + sources.readme.includes('V44 Gate 8'), + ), + predicateResult( + 'protocol-readme-records-gate8', + SOURCE_ROOTS.protocolReadme, + sources.protocolReadme.includes('V44 Gate 8'), + ), + predicateResult( + 'shared-enterprise-summary-implemented', + SOURCE_ROOTS.productRouteShell, + sources.productRouteShell.includes('ProductRouteEnterpriseSummary') && + sources.productRouteShell.includes('data-enterprise-ux="economic-summary"'), + ), + predicateResult( + 'shared-keyboard-hint-implemented', + SOURCE_ROOTS.productRouteShell, + sources.productRouteShell.includes('ProductRouteKeyboardHint') && + sources.productRouteShell.includes('data-enterprise-ux="keyboard-navigation"'), + ), + predicateResult( + 'shared-proof-detail-implemented', + SOURCE_ROOTS.productRouteShell, + sources.productRouteShell.includes('ProductRouteProofDetail') && + sources.productRouteShell.includes('data-enterprise-ux="expandable-proof-detail"'), + ), + predicateResult( + 'packs-route-uses-enterprise-ux', + SOURCE_ROOTS.packsClient, + sources.packsClient.includes('packs-enterprise-economic-summary') && + sources.packsClient.includes('packs-keyboard-navigation') && + sources.packsClient.includes('packs-enterprise-activity-grid') && + sources.packsClient.includes('packs-expandable-proof-detail') && + sources.packsClient.includes('sticky top-0'), + ), + predicateResult( + 'read-route-uses-enterprise-ux', + SOURCE_ROOTS.readClient, + sources.readClient.includes('read-enterprise-economic-summary') && + sources.readClient.includes('read-keyboard-navigation') && + sources.readClient.includes('read-expandable-proof-detail'), + ), + predicateResult( + 'deposit-route-uses-enterprise-ux', + SOURCE_ROOTS.depositClient, + sources.depositClient.includes('deposit-enterprise-economic-summary') && + sources.depositClient.includes('deposit-keyboard-navigation') && + sources.depositClient.includes('deposit-expandable-proof-detail'), + ), + predicateResult( + 'packs-test-covers-enterprise-ux', + SOURCE_ROOTS.packsTest, + sources.packsTest.includes('packs-enterprise-economic-summary') && + sources.packsTest.includes('packs-keyboard-navigation') && + sources.packsTest.includes('packs-expandable-proof-detail'), + ), + predicateResult( + 'read-test-covers-enterprise-ux', + SOURCE_ROOTS.readTest, + sources.readTest.includes('read-enterprise-economic-summary') && + sources.readTest.includes('read-keyboard-navigation') && + sources.readTest.includes('read-expandable-proof-detail'), + ), + predicateResult( + 'deposit-test-covers-enterprise-ux', + SOURCE_ROOTS.depositTest, + sources.depositTest.includes('deposit-enterprise-economic-summary') && + sources.depositTest.includes('deposit-keyboard-navigation') && + sources.depositTest.includes('deposit-expandable-proof-detail'), + ), + predicateResult( + 'protocol-test-covers-artifact', + SOURCE_ROOTS.protocolTest, + sources.protocolTest.includes('buildV44EnterpriseProductUx'), + ), + predicateResult( + 'protocol-package-exports-gate8', + SOURCE_ROOTS.protocolIndex, + sources.protocolIndex.includes('buildV44EnterpriseProductUx'), + ), + predicateResult( + 'protocol-types-export-gate8', + SOURCE_ROOTS.protocolTypes, + sources.protocolTypes.includes('buildV44EnterpriseProductUx'), + ), + predicateResult( + 'package-json-exposes-gate8', + SOURCE_ROOTS.packageJson, + sources.packageJson.includes('"generate:v44-enterprise-product-ux"') && + sources.packageJson.includes('"check:v44-gate8"'), + ), + predicateResult( + 'gate-workflow-runs-gate8', + SOURCE_ROOTS.gateWorkflow, + sources.gateWorkflow.includes('check-v44-gate8-enterprise-product-ux.mjs'), + ), + predicateResult( + 'canon-workflow-runs-gate8', + SOURCE_ROOTS.canonWorkflow, + sources.canonWorkflow.includes('check-v44-gate8-enterprise-product-ux.mjs'), + ), + predicateResult( + 'generator-exists', + SOURCE_ROOTS.generator, + sources.generator.includes('buildV44EnterpriseProductUx'), + ), + predicateResult( + 'checker-exists', + SOURCE_ROOTS.checker, + sources.checker.includes('V44 Gate 8 enterprise product UX check'), + ), + ]; +} + +export function buildV44EnterpriseProductUx({ repoRoot = DEFAULT_REPO_ROOT } = {}) { + const predicateResults = buildPredicateResults(repoRoot); + const failedPredicateIds = predicateResults + .filter((predicate) => !predicate.passed) + .map((predicate) => predicate.id); + const sourceRoots = Object.fromEntries( + Object.entries(SOURCE_ROOTS).map(([key, sourcePath]) => [ + key, + `${sourcePath}:${digest(readSource(repoRoot, sourcePath))}`, + ]), + ); + const artifactRoot = `v44-enterprise-product-ux:${digest( + JSON.stringify({ + objectIds: V44_ENTERPRISE_PRODUCT_UX_OBJECT_IDS, + routeIds: V44_ENTERPRISE_PRODUCT_UX_ROUTE_IDS, + capabilityIds: V44_ENTERPRISE_PRODUCT_UX_CAPABILITY_IDS, + forbiddenPayloadIds: V44_ENTERPRISE_PRODUCT_UX_FORBIDDEN_PAYLOAD_IDS, + contractRows: V44_ENTERPRISE_PRODUCT_UX_ROWS.map((row) => row.rowId), + sourceRoots, + failedPredicateIds, + }), + )}`; + + return { + artifactId: 'v44-enterprise-product-ux', + schemaId: V44_ENTERPRISE_PRODUCT_UX_SCHEMA_ID, + version: V44_ENTERPRISE_PRODUCT_UX_VERSION, + currentTarget: V44_ENTERPRISE_PRODUCT_UX_CURRENT_TARGET, + sourceSafetyVerdict: V44_ENTERPRISE_PRODUCT_UX_SOURCE_SAFETY_VERDICT, + generatedAt: 'deterministic', + artifactRoot, + passed: failedPredicateIds.length === 0, + objectIds: [...V44_ENTERPRISE_PRODUCT_UX_OBJECT_IDS], + routeIds: [...V44_ENTERPRISE_PRODUCT_UX_ROUTE_IDS], + capabilityIds: [...V44_ENTERPRISE_PRODUCT_UX_CAPABILITY_IDS], + forbiddenPayloadIds: [...V44_ENTERPRISE_PRODUCT_UX_FORBIDDEN_PAYLOAD_IDS], + contractRows: V44_ENTERPRISE_PRODUCT_UX_ROWS.map((row) => ({ + ...row, + rowRoot: `v44-enterprise-product-ux-contract:${digest(row.rowId)}`, + sourceSafeMetadataOnly: true, + protectedSourceVisible: false, + unpaidAssetPackSourceVisible: false, + })), + sourceRoots, + predicateResults, + coverage: { + sharedEnterpriseSummaryImplemented: true, + sharedKeyboardNavigationImplemented: true, + sharedExpandableProofDetailImplemented: true, + packsEnterpriseUxImplemented: true, + readEnterpriseUxImplemented: true, + depositEnterpriseUxImplemented: true, + denseEconomicTableImplemented: true, + responsiveLayoutPostureImplemented: true, + visualRegressionTestHooksImplemented: true, + sourceSafeMetadataOnly: true, + protectedSourceVisible: false, + rawSourceTextVisible: false, + unpaidAssetPackSourceVisible: false, + rawPromptVisible: false, + interpolatedPromptVisible: false, + rawProviderResponseVisible: false, + credentialsVisible: false, + walletPrivateMaterialVisible: false, + settlementPrivatePayloadVisible: false, + valueBearingMainnetAdmitted: false, + requiredPredicateCount: predicateResults.length, + passedPredicateCount: predicateResults.length - failedPredicateIds.length, + failedPredicateIds, + }, + }; +} + +export const V44_ENTERPRISE_PRODUCT_UX_SOURCE_ROOTS = Object.freeze( + Object.fromEntries(Object.entries(SOURCE_ROOTS).map(([key, sourcePath]) => [key, sourcePath])), +); diff --git a/packages/protocol/src/index.d.ts b/packages/protocol/src/index.d.ts index 5a364c64..05cf01e5 100644 --- a/packages/protocol/src/index.d.ts +++ b/packages/protocol/src/index.d.ts @@ -760,6 +760,18 @@ export const V44_ORGANIZATION_POLICY_STATE_IDS: readonly string[]; export const V44_ORGANIZATION_POLICY_FORBIDDEN_PAYLOAD_IDS: readonly string[]; export const V44_ORGANIZATION_POLICY_ROWS: readonly Record[]; export function buildV44OrganizationPolicyWalletAuthority(input?: Record): BitcodeProtocolReport; +export const V44_ENTERPRISE_PRODUCT_UX_ARTIFACT_PATH: string; +export const V44_ENTERPRISE_PRODUCT_UX_CURRENT_TARGET: string; +export const V44_ENTERPRISE_PRODUCT_UX_SCHEMA_ID: string; +export const V44_ENTERPRISE_PRODUCT_UX_VERSION: string; +export const V44_ENTERPRISE_PRODUCT_UX_SOURCE_SAFETY_VERDICT: string; +export const V44_ENTERPRISE_PRODUCT_UX_SOURCE_ROOTS: Readonly>; +export const V44_ENTERPRISE_PRODUCT_UX_OBJECT_IDS: readonly string[]; +export const V44_ENTERPRISE_PRODUCT_UX_ROUTE_IDS: readonly string[]; +export const V44_ENTERPRISE_PRODUCT_UX_CAPABILITY_IDS: readonly string[]; +export const V44_ENTERPRISE_PRODUCT_UX_FORBIDDEN_PAYLOAD_IDS: readonly string[]; +export const V44_ENTERPRISE_PRODUCT_UX_ROWS: readonly Record[]; +export function buildV44EnterpriseProductUx(input?: Record): BitcodeProtocolReport; export const EXCHANGE_INTENT_ORDER_CONTRACTS_ARTIFACT_PATH: string; export const EXCHANGE_INTENT_ORDER_CONTRACTS_CURRENT_TARGET: string; export const EXCHANGE_INTENT_ORDER_CONTRACTS_SCHEMA_ID: string; diff --git a/packages/protocol/src/index.js b/packages/protocol/src/index.js index 8e549350..e56ce3dd 100644 --- a/packages/protocol/src/index.js +++ b/packages/protocol/src/index.js @@ -864,6 +864,20 @@ export { V44_ORGANIZATION_POLICY_WALLET_AUTHORITY_VERSION, buildV44OrganizationPolicyWalletAuthority } from './canonical/v44-organization-policy-wallet-authority.js'; +export { + V44_ENTERPRISE_PRODUCT_UX_ARTIFACT_PATH, + V44_ENTERPRISE_PRODUCT_UX_CAPABILITY_IDS, + V44_ENTERPRISE_PRODUCT_UX_CURRENT_TARGET, + V44_ENTERPRISE_PRODUCT_UX_FORBIDDEN_PAYLOAD_IDS, + V44_ENTERPRISE_PRODUCT_UX_OBJECT_IDS, + V44_ENTERPRISE_PRODUCT_UX_ROUTE_IDS, + V44_ENTERPRISE_PRODUCT_UX_ROWS, + V44_ENTERPRISE_PRODUCT_UX_SCHEMA_ID, + V44_ENTERPRISE_PRODUCT_UX_SOURCE_ROOTS, + V44_ENTERPRISE_PRODUCT_UX_SOURCE_SAFETY_VERDICT, + V44_ENTERPRISE_PRODUCT_UX_VERSION, + buildV44EnterpriseProductUx +} from './canonical/v44-enterprise-product-ux.js'; export { EXCHANGE_INTENT_ACTION_KINDS, EXCHANGE_INTENT_ORDER_CONTRACTS_ARTIFACT_PATH, diff --git a/packages/protocol/test/v44-enterprise-product-ux.test.js b/packages/protocol/test/v44-enterprise-product-ux.test.js new file mode 100644 index 00000000..933589fc --- /dev/null +++ b/packages/protocol/test/v44-enterprise-product-ux.test.js @@ -0,0 +1,47 @@ +import assert from 'node:assert/strict'; +import { test } from 'node:test'; +import { + V44_ENTERPRISE_PRODUCT_UX_ARTIFACT_PATH, + V44_ENTERPRISE_PRODUCT_UX_CAPABILITY_IDS, + V44_ENTERPRISE_PRODUCT_UX_FORBIDDEN_PAYLOAD_IDS, + V44_ENTERPRISE_PRODUCT_UX_OBJECT_IDS, + V44_ENTERPRISE_PRODUCT_UX_ROUTE_IDS, + V44_ENTERPRISE_PRODUCT_UX_SCHEMA_ID, + V44_ENTERPRISE_PRODUCT_UX_SOURCE_SAFETY_VERDICT, + buildV44EnterpriseProductUx, +} from '../src/canonical/v44-enterprise-product-ux.js'; + +test('V44 enterprise product UX artifact binds route polish and proof contracts', () => { + const report = buildV44EnterpriseProductUx(); + + assert.equal(V44_ENTERPRISE_PRODUCT_UX_ARTIFACT_PATH, '.bitcode/v44-enterprise-product-ux.json'); + assert.equal(report.artifactId, 'v44-enterprise-product-ux'); + assert.equal(report.schemaId, V44_ENTERPRISE_PRODUCT_UX_SCHEMA_ID); + assert.equal(report.version, 'V44'); + assert.equal(report.currentTarget, 'V43'); + assert.equal(report.sourceSafetyVerdict, V44_ENTERPRISE_PRODUCT_UX_SOURCE_SAFETY_VERDICT); + assert.ok(report.artifactRoot.startsWith('v44-enterprise-product-ux:')); + assert.deepEqual(report.objectIds, [...V44_ENTERPRISE_PRODUCT_UX_OBJECT_IDS]); + assert.deepEqual(report.routeIds, [...V44_ENTERPRISE_PRODUCT_UX_ROUTE_IDS]); + assert.deepEqual(report.capabilityIds, [...V44_ENTERPRISE_PRODUCT_UX_CAPABILITY_IDS]); + assert.deepEqual(report.forbiddenPayloadIds, [...V44_ENTERPRISE_PRODUCT_UX_FORBIDDEN_PAYLOAD_IDS]); + assert.equal(report.contractRows.length, 6); + assert.equal(report.coverage.sharedEnterpriseSummaryImplemented, true); + assert.equal(report.coverage.sharedKeyboardNavigationImplemented, true); + assert.equal(report.coverage.sharedExpandableProofDetailImplemented, true); + assert.equal(report.coverage.packsEnterpriseUxImplemented, true); + assert.equal(report.coverage.readEnterpriseUxImplemented, true); + assert.equal(report.coverage.depositEnterpriseUxImplemented, true); + assert.equal(report.coverage.denseEconomicTableImplemented, true); + assert.equal(report.coverage.visualRegressionTestHooksImplemented, true); + assert.equal(report.coverage.sourceSafeMetadataOnly, true); + assert.equal(report.coverage.protectedSourceVisible, false); + assert.equal(report.coverage.rawSourceTextVisible, false); + assert.equal(report.coverage.unpaidAssetPackSourceVisible, false); + assert.equal(report.coverage.rawPromptVisible, false); + assert.equal(report.coverage.rawProviderResponseVisible, false); + assert.equal(report.coverage.credentialsVisible, false); + assert.equal(report.coverage.walletPrivateMaterialVisible, false); + assert.equal(report.coverage.settlementPrivatePayloadVisible, false); + assert.equal(report.coverage.valueBearingMainnetAdmitted, false); +}); diff --git a/scripts/check-v44-gate8-enterprise-product-ux.mjs b/scripts/check-v44-gate8-enterprise-product-ux.mjs new file mode 100644 index 00000000..13d770d0 --- /dev/null +++ b/scripts/check-v44-gate8-enterprise-product-ux.mjs @@ -0,0 +1,188 @@ +#!/usr/bin/env node + +import { execFileSync } from 'node:child_process'; +import { existsSync, readFileSync } from 'node:fs'; +import path from 'node:path'; +import { fileURLToPath } from 'node:url'; +import { + V44_ENTERPRISE_PRODUCT_UX_ARTIFACT_PATH, + buildV44EnterpriseProductUx, +} from '../packages/protocol/src/canonical/v44-enterprise-product-ux.js'; + +const __filename = fileURLToPath(import.meta.url); +const __dirname = path.dirname(__filename); +const defaultRepoRoot = path.resolve(__dirname, '..'); + +function read(root, relativePath) { + return readFileSync(path.join(root, relativePath), 'utf8'); +} + +function exists(root, relativePath) { + return existsSync(path.join(root, relativePath)); +} + +function git(root, args) { + return execFileSync('git', args, { cwd: root, encoding: 'utf8' }).trim(); +} + +function run(root, command, args) { + execFileSync(command, args, { cwd: root, stdio: 'pipe', encoding: 'utf8' }); +} + +function assertCheck(failures, condition, message) { + if (!condition) failures.push(message); +} + +function parseArgs(argv) { + const args = { + repoRoot: defaultRepoRoot, + skipBranchCheck: false, + skipUapiTests: false, + skipPackageTests: false, + }; + for (let index = 0; index < argv.length; index += 1) { + const arg = argv[index]; + if (arg === '--repo-root') args.repoRoot = path.resolve(argv[++index]); + else if (arg === '--skip-branch-check') args.skipBranchCheck = true; + else if (arg === '--skip-uapi-tests') args.skipUapiTests = true; + else if (arg === '--skip-package-tests') args.skipPackageTests = true; + else if (arg === '--help' || arg === '-h') args.help = true; + else throw new Error(`Unknown argument ${arg}`); + } + return args; +} + +function printHelp() { + process.stdout.write( + [ + 'Usage: node scripts/check-v44-gate8-enterprise-product-ux.mjs [--skip-branch-check] [--skip-uapi-tests] [--skip-package-tests] [--repo-root ]', + '', + 'V44 Gate 8 enterprise product UX check: validates shared enterprise UX primitives, /packs, /read, /deposit source-safe economic operation UI, route tests, docs, workflows, exports, and generated artifact freshness.', + ].join('\n'), + ); + process.stdout.write('\n'); +} + +function main() { + const args = parseArgs(process.argv.slice(2)); + if (args.help) { + printHelp(); + return; + } + + const root = args.repoRoot; + const failures = []; + const pointer = read(root, 'BITCODE_SPEC.txt').trim(); + + assertCheck(failures, pointer === 'V43', `BITCODE_SPEC.txt must remain V43 during V44 gate work. Observed ${pointer || 'empty'}.`); + + if (!args.skipBranchCheck) { + const branch = git(root, ['branch', '--show-current']); + assertCheck( + failures, + branch === 'version/v44' || /^v44\/gate-\d+-[a-z0-9][a-z0-9-]*$/u.test(branch), + `V44 work must occur on version/v44 or v44/gate-N-* branches. Observed ${branch || 'detached HEAD'}.`, + ); + } + + for (const relativePath of [ + V44_ENTERPRISE_PRODUCT_UX_ARTIFACT_PATH, + 'uapi/components/base/bitcode/routes/product-route-shell.tsx', + 'uapi/app/packs/PacksPageClient.tsx', + 'uapi/app/read/ReadPageClient.tsx', + 'uapi/app/deposit/DepositPageClient.tsx', + 'uapi/tests/packsPageClient.test.tsx', + 'uapi/tests/readPageClient.test.tsx', + 'uapi/tests/depositPageClient.test.tsx', + 'packages/protocol/src/canonical/v44-enterprise-product-ux.js', + 'packages/protocol/test/v44-enterprise-product-ux.test.js', + 'scripts/generate-v44-enterprise-product-ux.mjs', + 'scripts/check-v44-gate8-enterprise-product-ux.mjs', + 'BITCODE_SPEC_V44.md', + 'BITCODE_SPEC_V44_DELTA.md', + 'BITCODE_SPEC_V44_NOTES.md', + 'BITCODE_SPEC_V44_PARITY_MATRIX.md', + 'SPECIFICATIONS_ROADMAP.md', + 'README.md', + 'packages/protocol/README.md', + '.github/workflows/bitcode-gate-quality.yml', + '.github/workflows/bitcode-canon-quality.yml', + 'package.json', + ]) { + assertCheck(failures, exists(root, relativePath), `Missing required V44 Gate 8 file: ${relativePath}`); + } + + const artifact = buildV44EnterpriseProductUx({ repoRoot: root }); + assertCheck(failures, artifact.passed, `V44 enterprise product UX predicates failed: ${artifact.coverage.failedPredicateIds.join(', ')}`); + assertCheck(failures, artifact.coverage.sharedEnterpriseSummaryImplemented === true, 'Shared enterprise summary must be implemented.'); + assertCheck(failures, artifact.coverage.sharedKeyboardNavigationImplemented === true, 'Shared keyboard navigation must be implemented.'); + assertCheck(failures, artifact.coverage.sharedExpandableProofDetailImplemented === true, 'Shared proof detail must be implemented.'); + assertCheck(failures, artifact.coverage.packsEnterpriseUxImplemented === true, '/packs enterprise UX must be implemented.'); + assertCheck(failures, artifact.coverage.readEnterpriseUxImplemented === true, '/read enterprise UX must be implemented.'); + assertCheck(failures, artifact.coverage.depositEnterpriseUxImplemented === true, '/deposit enterprise UX must be implemented.'); + assertCheck(failures, artifact.coverage.sourceSafeMetadataOnly === true, 'Artifact must be source-safe metadata only.'); + assertCheck(failures, artifact.coverage.protectedSourceVisible === false, 'Artifact must not expose protected source.'); + assertCheck(failures, artifact.coverage.rawSourceTextVisible === false, 'Artifact must not expose raw source text.'); + assertCheck(failures, artifact.coverage.unpaidAssetPackSourceVisible === false, 'Artifact must not expose unpaid AssetPack source.'); + assertCheck(failures, artifact.coverage.rawPromptVisible === false, 'Artifact must not expose raw prompts.'); + assertCheck(failures, artifact.coverage.rawProviderResponseVisible === false, 'Artifact must not expose raw provider responses.'); + assertCheck(failures, artifact.coverage.walletPrivateMaterialVisible === false, 'Artifact must not expose wallet private material.'); + assertCheck(failures, artifact.coverage.settlementPrivatePayloadVisible === false, 'Artifact must not expose private settlement payloads.'); + assertCheck(failures, artifact.coverage.valueBearingMainnetAdmitted === false, 'Artifact must not admit value-bearing mainnet operation.'); + + const serialized = `${JSON.stringify(artifact, null, 2)}\n`; + assertCheck( + failures, + exists(root, V44_ENTERPRISE_PRODUCT_UX_ARTIFACT_PATH) && + read(root, V44_ENTERPRISE_PRODUCT_UX_ARTIFACT_PATH) === serialized, + `${V44_ENTERPRISE_PRODUCT_UX_ARTIFACT_PATH} must be generated and current.`, + ); + + const packageJson = read(root, 'package.json'); + const gateWorkflow = read(root, '.github/workflows/bitcode-gate-quality.yml'); + const canonWorkflow = read(root, '.github/workflows/bitcode-canon-quality.yml'); + assertCheck(failures, packageJson.includes('"generate:v44-enterprise-product-ux"'), 'package.json must expose generate:v44-enterprise-product-ux.'); + assertCheck(failures, packageJson.includes('"check:v44-enterprise-product-ux"'), 'package.json must expose check:v44-enterprise-product-ux.'); + assertCheck(failures, packageJson.includes('"check:v44-gate8"'), 'package.json must expose check:v44-gate8.'); + assertCheck(failures, gateWorkflow.includes('check-v44-gate8-enterprise-product-ux.mjs'), 'Gate workflow must run V44 Gate 8 checker.'); + assertCheck(failures, canonWorkflow.includes('check-v44-gate8-enterprise-product-ux.mjs'), 'Canon workflow must run V44 Gate 8 checker.'); + + try { + run(root, 'node', ['scripts/generate-v44-enterprise-product-ux.mjs', '--check']); + } catch { + failures.push('V44 enterprise product UX artifact must be fresh.'); + } + + if (!args.skipPackageTests) { + try { + run(root, 'pnpm', ['--dir', 'packages/protocol', 'exec', 'node', '--test', '--test-force-exit', 'test/v44-enterprise-product-ux.test.js']); + } catch { + failures.push('packages/protocol/test/v44-enterprise-product-ux.test.js must pass.'); + } + } + + if (!args.skipUapiTests) { + try { + run(root, 'pnpm', ['--dir', 'uapi', 'exec', 'jest', 'packsPageClient.test.tsx', 'readPageClient.test.tsx', 'depositPageClient.test.tsx', '--runInBand']); + } catch { + failures.push('uapi enterprise product UX tests must pass.'); + } + } + + if (failures.length > 0) { + process.stderr.write('V44 Gate 8 enterprise product UX check failed:\n'); + for (const failure of failures.filter(Boolean)) process.stderr.write(`- ${failure}\n`); + process.exitCode = 1; + return; + } + + process.stdout.write('V44 Gate 8 enterprise product UX check passed.\n'); +} + +try { + main(); +} catch (error) { + const detail = error instanceof Error ? error.message : String(error); + process.stderr.write(`${detail}\n`); + process.exitCode = 1; +} diff --git a/scripts/generate-v44-enterprise-product-ux.mjs b/scripts/generate-v44-enterprise-product-ux.mjs new file mode 100644 index 00000000..c1ac40de --- /dev/null +++ b/scripts/generate-v44-enterprise-product-ux.mjs @@ -0,0 +1,29 @@ +#!/usr/bin/env node + +import { existsSync, readFileSync, writeFileSync } from 'node:fs'; +import path from 'node:path'; +import { fileURLToPath } from 'node:url'; +import { + V44_ENTERPRISE_PRODUCT_UX_ARTIFACT_PATH, + buildV44EnterpriseProductUx, +} from '../packages/protocol/src/canonical/v44-enterprise-product-ux.js'; + +const __filename = fileURLToPath(import.meta.url); +const __dirname = path.dirname(__filename); +const repoRoot = path.resolve(__dirname, '..'); +const artifactPath = path.join(repoRoot, V44_ENTERPRISE_PRODUCT_UX_ARTIFACT_PATH); +const check = process.argv.includes('--check'); +const artifact = buildV44EnterpriseProductUx({ repoRoot }); +const serialized = `${JSON.stringify(artifact, null, 2)}\n`; + +if (check) { + if (!existsSync(artifactPath) || readFileSync(artifactPath, 'utf8') !== serialized) { + process.stderr.write( + `${V44_ENTERPRISE_PRODUCT_UX_ARTIFACT_PATH} is stale. Run pnpm run generate:v44-enterprise-product-ux.\n`, + ); + process.exitCode = 1; + } +} else { + writeFileSync(artifactPath, serialized); + process.stdout.write(`wrote ${V44_ENTERPRISE_PRODUCT_UX_ARTIFACT_PATH}\n`); +} diff --git a/uapi/app/deposit/DepositPageClient.tsx b/uapi/app/deposit/DepositPageClient.tsx index be7a7544..c3cafb09 100644 --- a/uapi/app/deposit/DepositPageClient.tsx +++ b/uapi/app/deposit/DepositPageClient.tsx @@ -16,6 +16,9 @@ import { useRouter, useSearchParams } from "next/navigation"; import { useAuth } from "@/components/base/bitcode/auth/AuthProvider"; import { ProductRouteDisclosure, + ProductRouteEnterpriseSummary, + ProductRouteKeyboardHint, + ProductRouteProofDetail, ProductRouteShell, ProductRouteStatePanel, ProductRouteStepGrid, @@ -744,6 +747,42 @@ export default function DepositPageClient() { } /> + +
@@ -1103,6 +1142,26 @@ export default function DepositPageClient() {