Skip to content

feat(assets): simplify Skill publication - #162

Merged
kl3inIT merged 8 commits into
mainfrom
feat/skill-sharing-simplification
Jul 31, 2026
Merged

feat(assets): simplify Skill publication#162
kl3inIT merged 8 commits into
mainfrom
feat/skill-sharing-simplification

Conversation

@kl3inIT

@kl3inIT kl3inIT commented Jul 31, 2026

Copy link
Copy Markdown
Owner

Outcome

  • lets accountable owners publish a validated Skill Draft directly as an immutable release
  • preserves the reviewed path and blocks direct publication while a review is active
  • records and exposes DIRECT versus REVIEWED provenance in governance, delivery, and install manifests
  • keeps every non-Skill profile on the existing reviewed lifecycle

Authorization and safety

  • adds dedicated OpenFGA can_publish_skill instead of broadening can_edit
  • atomically pins Draft -> Revision -> Release package references and writes a distinct audit policy
  • UI states that structural validation is not independent content review
  • independent architecture challenge and decision 0022 are included

Verification

  • OpenFGA: model valid; 9/9 tests, 75/75 checks, 31/31 ListObjects
  • Backend: clean build tree + full test; focused Core/API checks and Postgres integration tests
  • Web (Node 24.15.0): generated API drift, typecheck, 30 unit tests, lint, production build
  • Browser: 12/12 Playwright tests
  • Docs: OpenAPI, lint, types, content, manifest, publication, routes, and links

Summary by CodeRabbit

  • New Features

    • Skill owners with permission can publish drafts directly as immutable releases.
    • Releases now identify whether publication was direct or reviewed.
    • The asset interface displays publication provenance and supports direct publishing with version labels.
    • Skill distribution manifests include publication provenance.
  • Bug Fixes

    • Direct publication is blocked for non-Skill assets and drafts with active reviews.
  • Documentation

    • Added API documentation for publishing Skill drafts as immutable releases.

@coderabbitai

coderabbitai Bot commented Jul 31, 2026

Copy link
Copy Markdown

Review Change Stack

Warning

Review limit reached

@kl3inIT, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 40 minutes

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro Plus

Run ID: edc3cf89-8339-4d59-80a1-21ff404dfbdb

📥 Commits

Reviewing files that changed from the base of the PR and between cf2d504 and 5f1b02c.

📒 Files selected for processing (2)
  • core/src/main/java/com/orgmemory/core/assetregistry/AssetRegistryCoordinator.java
  • core/src/main/resources/db/migration/V15__record_asset_publication_mode.sql
📝 Walkthrough

Walkthrough

The asset registry now supports direct publication of Skill drafts. It adds authorization, immutable release provenance, API and UI flows, persistence, distribution metadata, documentation, and test coverage for direct and reviewed publication paths.

Changes

Skill publication and provenance

Layer / File(s) Summary
Publication provenance contracts
core/src/main/java/com/orgmemory/core/assetregistry/*, core/src/main/resources/db/migration/*, core/src/test/java/com/orgmemory/core/assetregistry/*
Releases and Skill manifests now record REVIEWED or DIRECT publication mode. The database stores and constrains this value.
Authorization and publication flow
core/src/main/java/com/orgmemory/core/assetregistry/AssetRegistryService.java, core/src/main/java/com/orgmemory/core/assetregistry/AssetRegistryCoordinator.java, integrations/authorization-openfga/*
Authorized owner-class actors can publish eligible Skill drafts directly. The coordinator validates the draft, creates the revision and release, activates the asset, and records an audit event.
API and integration validation
apps/api/src/main/java/com/orgmemory/api/assetregistry/*, apps/api/src/test/java/com/orgmemory/api/assetregistry/*, apps/docs/content/docs/reference/api-reference/assets.mdx, ARCHITECTURE.md
The API exposes POST /api/assets/{assetId}/skill-releases. Documentation and integration tests cover direct publication, provenance, active reviews, and unsupported asset types.
Web governance and release display
apps/web/src/features/assets/*, apps/web/test/e2e/*
The governance workspace supports direct Skill publication, hides Review when it is not applicable, routes published drafts to Releases, and displays publication provenance.

Estimated code review effort: 4 (Complex) | ~45 minutes

Sequence Diagram(s)

sequenceDiagram
  participant Client
  participant API
  participant Registry
  participant Coordinator
  participant Database
  Client->>API: Submit version label
  API->>Registry: Publish Skill draft
  Registry->>Coordinator: Authorize and publish draft
  Coordinator->>Database: Persist direct publication
  Database-->>Coordinator: Return persisted release
  Coordinator-->>Registry: Return AssetView
  Registry-->>API: Return published asset
  API-->>Client: Return created response
Loading

Possibly related PRs

  • kl3inIT/OrgMemory#50: Introduces the asset-registry models and flows extended by this publication change.
  • kl3inIT/OrgMemory#93: Adds the governance actions and workspace flows extended for direct Skill publication.
  • kl3inIT/OrgMemory#88: Uses the Skill distribution and manifest models that now expose publication provenance.
🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly summarizes the main change: simplifying Skill publication through direct publishing while retaining the reviewed path.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches 💡 1
📝 Generate docstrings 💡
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/skill-sharing-simplification

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@kl3inIT

kl3inIT commented Jul 31, 2026

Copy link
Copy Markdown
Owner Author

@coderabbitai review

@coderabbitai

coderabbitai Bot commented Jul 31, 2026

Copy link
Copy Markdown
✅ Action performed

Review finished.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 3

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@apps/web/src/features/assets/components/governance-draft-workspace.tsx`:
- Around line 74-78: Update canSubmit in the governance draft workspace so
eligible reviewed submission remains true even when actions.canPublishSkill is
enabled; do not gate reviewed submission on direct publication capability.
Ensure the action rendering around canPublishSkill, canSubmit, and hasAction
exposes both choices when both permissions are true, and add coverage for that
Skill scenario.

In
`@core/src/main/java/com/orgmemory/core/assetregistry/AssetRegistryCoordinator.java`:
- Around line 563-580: Update publishSkillDraft() and submit() to load the asset
via requiredAssetForUpdate() instead of requiredAsset(), ensuring both
operations acquire the same asset-row lock before checking or creating review
state. Keep the existing review-state validation and surrounding behavior
unchanged.

In `@core/src/main/resources/db/migration/V15__record_asset_publication_mode.sql`:
- Around line 1-7: Update the publication_mode column definition in the
migration to use TEXT instead of varchar(16). Add
asset_release_publication_mode_check as NOT VALID, then validate it in a
follow-up migration step with VALIDATE CONSTRAINT, while preserving the existing
default removal and allowed values.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro Plus

Run ID: ffd558bc-66a9-4042-98eb-1ac165877cdb

📥 Commits

Reviewing files that changed from the base of the PR and between ecda960 and cf2d504.

⛔ Files ignored due to path filters (12)
  • apps/docs/generated/openapi.public.json is excluded by !**/generated/**
  • contracts/openapi.json is excluded by !contracts/openapi.json
  • docs/decisions/0022-skill-publication-is-direct-by-default-and-reviewable.md is excluded by !docs/**
  • docs/increments/active/2026-07-31-skill-direct-sharing/challenge-brief.md is excluded by !docs/**
  • docs/increments/active/2026-07-31-skill-direct-sharing/challenge-verdict.md is excluded by !docs/**
  • docs/increments/active/2026-07-31-skill-direct-sharing/design.md is excluded by !docs/**
  • docs/increments/active/2026-07-31-skill-direct-sharing/plan.md is excluded by !docs/**
  • docs/increments/active/2026-07-31-skill-direct-sharing/verification.md is excluded by !docs/**
  • docs/roadmap.md is excluded by !docs/**
  • docs/specs/domains/asset-registry.md is excluded by !docs/**
  • docs/tests/domains/asset-registry.md is excluded by !docs/**
  • docs/vision.md is excluded by !docs/**
📒 Files selected for processing (31)
  • ARCHITECTURE.md
  • apps/api/src/main/java/com/orgmemory/api/assetregistry/AssetRegistryController.java
  • apps/api/src/test/java/com/orgmemory/api/assetregistry/AssetConsumptionControllerTests.java
  • apps/api/src/test/java/com/orgmemory/api/assetregistry/AssetRegistryIntegrationTests.java
  • apps/api/src/test/java/com/orgmemory/api/assetregistry/SkillDistributionControllerTests.java
  • apps/docs/content/docs/reference/api-reference/assets.mdx
  • apps/web/src/features/assets/components/asset-detail-page.tsx
  • apps/web/src/features/assets/components/governance-draft-workspace.tsx
  • apps/web/src/features/assets/components/governance-workspace-page.tsx
  • apps/web/src/features/assets/governance-policy.test.ts
  • apps/web/src/features/assets/governance-policy.ts
  • apps/web/test/e2e/asset-registry-golden-poc.spec.ts
  • core/src/main/java/com/orgmemory/core/assetregistry/AssetAuthorizationTarget.java
  • core/src/main/java/com/orgmemory/core/assetregistry/AssetConsumptionRelease.java
  • core/src/main/java/com/orgmemory/core/assetregistry/AssetDeliveryRelease.java
  • core/src/main/java/com/orgmemory/core/assetregistry/AssetGovernanceActions.java
  • core/src/main/java/com/orgmemory/core/assetregistry/AssetPublicationMode.java
  • core/src/main/java/com/orgmemory/core/assetregistry/AssetRegistryCoordinator.java
  • core/src/main/java/com/orgmemory/core/assetregistry/AssetRegistryService.java
  • core/src/main/java/com/orgmemory/core/assetregistry/AssetRelease.java
  • core/src/main/java/com/orgmemory/core/assetregistry/AssetView.java
  • core/src/main/java/com/orgmemory/core/assetregistry/SkillDistributionService.java
  • core/src/main/java/com/orgmemory/core/assetregistry/SkillInstallManifest.java
  • core/src/main/resources/db/migration/V15__record_asset_publication_mode.sql
  • core/src/test/java/com/orgmemory/core/assetregistry/AssetRegistryServiceTests.java
  • core/src/test/java/com/orgmemory/core/assetregistry/AssetValidationTests.java
  • core/src/test/java/com/orgmemory/core/assetregistry/CapabilityPackServiceTests.java
  • core/src/test/java/com/orgmemory/core/assetregistry/PromptExecutionServiceTests.java
  • core/src/test/java/com/orgmemory/core/assetregistry/SkillDistributionServiceTests.java
  • integrations/authorization-openfga/src/main/openfga/model.fga
  • integrations/authorization-openfga/src/test/openfga/store.fga.yaml
📜 Review details
🧰 Additional context used
📓 Path-based instructions (14)
**/*

📄 CodeRabbit inference engine (CLAUDE.md)

**/*: Always read the repository guidance and relevant sections of ARCHITECTURE.md; before changing a domain, read its specification, test-coverage document, and binding decision filenames.
Treat the repository as the engineering system of record; current repository and runtime evidence take precedence over chat or Northstar.
Read docs/guidelines/agent-safety.md before retrieval, AI, MCP, permission, upload, graph, or export work. Never commit secrets or customer data.

Files:

  • core/src/main/java/com/orgmemory/core/assetregistry/AssetAuthorizationTarget.java
  • integrations/authorization-openfga/src/main/openfga/model.fga
  • core/src/main/resources/db/migration/V15__record_asset_publication_mode.sql
  • core/src/test/java/com/orgmemory/core/assetregistry/AssetValidationTests.java
  • apps/web/src/features/assets/components/asset-detail-page.tsx
  • core/src/main/java/com/orgmemory/core/assetregistry/AssetGovernanceActions.java
  • core/src/main/java/com/orgmemory/core/assetregistry/AssetPublicationMode.java
  • ARCHITECTURE.md
  • apps/docs/content/docs/reference/api-reference/assets.mdx
  • core/src/main/java/com/orgmemory/core/assetregistry/SkillDistributionService.java
  • core/src/main/java/com/orgmemory/core/assetregistry/AssetRelease.java
  • core/src/test/java/com/orgmemory/core/assetregistry/PromptExecutionServiceTests.java
  • apps/web/src/features/assets/components/governance-workspace-page.tsx
  • core/src/main/java/com/orgmemory/core/assetregistry/SkillInstallManifest.java
  • core/src/test/java/com/orgmemory/core/assetregistry/CapabilityPackServiceTests.java
  • apps/api/src/test/java/com/orgmemory/api/assetregistry/SkillDistributionControllerTests.java
  • core/src/test/java/com/orgmemory/core/assetregistry/SkillDistributionServiceTests.java
  • apps/api/src/test/java/com/orgmemory/api/assetregistry/AssetConsumptionControllerTests.java
  • apps/web/src/features/assets/components/governance-draft-workspace.tsx
  • core/src/test/java/com/orgmemory/core/assetregistry/AssetRegistryServiceTests.java
  • core/src/main/java/com/orgmemory/core/assetregistry/AssetView.java
  • apps/api/src/main/java/com/orgmemory/api/assetregistry/AssetRegistryController.java
  • apps/web/src/features/assets/governance-policy.test.ts
  • integrations/authorization-openfga/src/test/openfga/store.fga.yaml
  • apps/api/src/test/java/com/orgmemory/api/assetregistry/AssetRegistryIntegrationTests.java
  • core/src/main/java/com/orgmemory/core/assetregistry/AssetConsumptionRelease.java
  • apps/web/src/features/assets/governance-policy.ts
  • core/src/main/java/com/orgmemory/core/assetregistry/AssetRegistryService.java
  • core/src/main/java/com/orgmemory/core/assetregistry/AssetDeliveryRelease.java
  • apps/web/test/e2e/asset-registry-golden-poc.spec.ts
  • core/src/main/java/com/orgmemory/core/assetregistry/AssetRegistryCoordinator.java
**/*.{java,gradle,gradle.kts,properties,yml,yaml}

📄 CodeRabbit inference engine (CLAUDE.md)

Before using unfamiliar Spring Boot 4, Spring Modulith 2, Spring AI 2, or Gradle APIs, consult current official documentation, Context7, and the relevant project verification skill.

Files:

  • core/src/main/java/com/orgmemory/core/assetregistry/AssetAuthorizationTarget.java
  • core/src/test/java/com/orgmemory/core/assetregistry/AssetValidationTests.java
  • core/src/main/java/com/orgmemory/core/assetregistry/AssetGovernanceActions.java
  • core/src/main/java/com/orgmemory/core/assetregistry/AssetPublicationMode.java
  • core/src/main/java/com/orgmemory/core/assetregistry/SkillDistributionService.java
  • core/src/main/java/com/orgmemory/core/assetregistry/AssetRelease.java
  • core/src/test/java/com/orgmemory/core/assetregistry/PromptExecutionServiceTests.java
  • core/src/main/java/com/orgmemory/core/assetregistry/SkillInstallManifest.java
  • core/src/test/java/com/orgmemory/core/assetregistry/CapabilityPackServiceTests.java
  • apps/api/src/test/java/com/orgmemory/api/assetregistry/SkillDistributionControllerTests.java
  • core/src/test/java/com/orgmemory/core/assetregistry/SkillDistributionServiceTests.java
  • apps/api/src/test/java/com/orgmemory/api/assetregistry/AssetConsumptionControllerTests.java
  • core/src/test/java/com/orgmemory/core/assetregistry/AssetRegistryServiceTests.java
  • core/src/main/java/com/orgmemory/core/assetregistry/AssetView.java
  • apps/api/src/main/java/com/orgmemory/api/assetregistry/AssetRegistryController.java
  • integrations/authorization-openfga/src/test/openfga/store.fga.yaml
  • apps/api/src/test/java/com/orgmemory/api/assetregistry/AssetRegistryIntegrationTests.java
  • core/src/main/java/com/orgmemory/core/assetregistry/AssetConsumptionRelease.java
  • core/src/main/java/com/orgmemory/core/assetregistry/AssetRegistryService.java
  • core/src/main/java/com/orgmemory/core/assetregistry/AssetDeliveryRelease.java
  • core/src/main/java/com/orgmemory/core/assetregistry/AssetRegistryCoordinator.java
**/*.{java,sql}

📄 CodeRabbit inference engine (CLAUDE.md)

Keep ddl-auto=validate and pair every persisted-model change with a Flyway migration.

Files:

  • core/src/main/java/com/orgmemory/core/assetregistry/AssetAuthorizationTarget.java
  • core/src/main/resources/db/migration/V15__record_asset_publication_mode.sql
  • core/src/test/java/com/orgmemory/core/assetregistry/AssetValidationTests.java
  • core/src/main/java/com/orgmemory/core/assetregistry/AssetGovernanceActions.java
  • core/src/main/java/com/orgmemory/core/assetregistry/AssetPublicationMode.java
  • core/src/main/java/com/orgmemory/core/assetregistry/SkillDistributionService.java
  • core/src/main/java/com/orgmemory/core/assetregistry/AssetRelease.java
  • core/src/test/java/com/orgmemory/core/assetregistry/PromptExecutionServiceTests.java
  • core/src/main/java/com/orgmemory/core/assetregistry/SkillInstallManifest.java
  • core/src/test/java/com/orgmemory/core/assetregistry/CapabilityPackServiceTests.java
  • apps/api/src/test/java/com/orgmemory/api/assetregistry/SkillDistributionControllerTests.java
  • core/src/test/java/com/orgmemory/core/assetregistry/SkillDistributionServiceTests.java
  • apps/api/src/test/java/com/orgmemory/api/assetregistry/AssetConsumptionControllerTests.java
  • core/src/test/java/com/orgmemory/core/assetregistry/AssetRegistryServiceTests.java
  • core/src/main/java/com/orgmemory/core/assetregistry/AssetView.java
  • apps/api/src/main/java/com/orgmemory/api/assetregistry/AssetRegistryController.java
  • apps/api/src/test/java/com/orgmemory/api/assetregistry/AssetRegistryIntegrationTests.java
  • core/src/main/java/com/orgmemory/core/assetregistry/AssetConsumptionRelease.java
  • core/src/main/java/com/orgmemory/core/assetregistry/AssetRegistryService.java
  • core/src/main/java/com/orgmemory/core/assetregistry/AssetDeliveryRelease.java
  • core/src/main/java/com/orgmemory/core/assetregistry/AssetRegistryCoordinator.java
**/*.{java,gradle,gradle.kts}

📄 CodeRabbit inference engine (CLAUDE.md)

Use the testing harness; a terminating clean test is the JVM context gate, and bootRun is not verification. IDE inspection applies only to edited backend Java.

Files:

  • core/src/main/java/com/orgmemory/core/assetregistry/AssetAuthorizationTarget.java
  • core/src/test/java/com/orgmemory/core/assetregistry/AssetValidationTests.java
  • core/src/main/java/com/orgmemory/core/assetregistry/AssetGovernanceActions.java
  • core/src/main/java/com/orgmemory/core/assetregistry/AssetPublicationMode.java
  • core/src/main/java/com/orgmemory/core/assetregistry/SkillDistributionService.java
  • core/src/main/java/com/orgmemory/core/assetregistry/AssetRelease.java
  • core/src/test/java/com/orgmemory/core/assetregistry/PromptExecutionServiceTests.java
  • core/src/main/java/com/orgmemory/core/assetregistry/SkillInstallManifest.java
  • core/src/test/java/com/orgmemory/core/assetregistry/CapabilityPackServiceTests.java
  • apps/api/src/test/java/com/orgmemory/api/assetregistry/SkillDistributionControllerTests.java
  • core/src/test/java/com/orgmemory/core/assetregistry/SkillDistributionServiceTests.java
  • apps/api/src/test/java/com/orgmemory/api/assetregistry/AssetConsumptionControllerTests.java
  • core/src/test/java/com/orgmemory/core/assetregistry/AssetRegistryServiceTests.java
  • core/src/main/java/com/orgmemory/core/assetregistry/AssetView.java
  • apps/api/src/main/java/com/orgmemory/api/assetregistry/AssetRegistryController.java
  • apps/api/src/test/java/com/orgmemory/api/assetregistry/AssetRegistryIntegrationTests.java
  • core/src/main/java/com/orgmemory/core/assetregistry/AssetConsumptionRelease.java
  • core/src/main/java/com/orgmemory/core/assetregistry/AssetRegistryService.java
  • core/src/main/java/com/orgmemory/core/assetregistry/AssetDeliveryRelease.java
  • core/src/main/java/com/orgmemory/core/assetregistry/AssetRegistryCoordinator.java
integrations/authorization-openfga/**/*

⚙️ CodeRabbit configuration file

integrations/authorization-openfga/**/*: Source-native ACL is a hard ceiling. Flag any parent, organization, role,
or wildcard relation that can broaden source access. Require negative
Check and ListObjects coverage for every new permission path.

Files:

  • integrations/authorization-openfga/src/main/openfga/model.fga
  • integrations/authorization-openfga/src/test/openfga/store.fga.yaml
core/src/main/resources/db/migration/*.sql

⚙️ CodeRabbit configuration file

core/src/main/resources/db/migration/*.sql: The repository is pre-release: V1 is the intentionally resettable clean
baseline and development data carries no migration cost. Once a release
baseline is frozen, later Flyway migrations are immutable. Check tenant
isolation, foreign keys, uniqueness, indexes, append-only evidence
semantics, safe defaults, and PostgreSQL 18 plus pgvector compatibility.

Files:

  • core/src/main/resources/db/migration/V15__record_asset_publication_mode.sql
**/*.{js,jsx,ts,tsx}

📄 CodeRabbit inference engine (CLAUDE.md)

**/*.{js,jsx,ts,tsx}: Frontend verification must include lint, typecheck, tests, production build, and browser verification when the flow matters.
Before using unfamiliar React, Vite, Tailwind, TypeScript, Next.js, or Fumadocs APIs, consult current official documentation, Context7, and the relevant project verification skill.

Files:

  • apps/web/src/features/assets/components/asset-detail-page.tsx
  • apps/web/src/features/assets/components/governance-workspace-page.tsx
  • apps/web/src/features/assets/components/governance-draft-workspace.tsx
  • apps/web/src/features/assets/governance-policy.test.ts
  • apps/web/src/features/assets/governance-policy.ts
  • apps/web/test/e2e/asset-registry-golden-poc.spec.ts
apps/web/**/*.{ts,tsx}

📄 CodeRabbit inference engine (apps/web/CLAUDE.md)

apps/web/**/*.{ts,tsx}: Extend the established OrgMemory product shell, design tokens, shadcn/Radix primitives, and existing layout patterns; do not introduce a separate visual system in the web application.
Generate ordinary REST clients from contracts/openapi.json using Hey API.
Use TanStack Query for server state, TanStack Router for navigation, and limit Zustand to durable or high-frequency UI state.
Preserve keyboard accessibility, light/dark theme support, loading and error states, and responsive behavior in the web application.

Files:

  • apps/web/src/features/assets/components/asset-detail-page.tsx
  • apps/web/src/features/assets/components/governance-workspace-page.tsx
  • apps/web/src/features/assets/components/governance-draft-workspace.tsx
  • apps/web/src/features/assets/governance-policy.test.ts
  • apps/web/src/features/assets/governance-policy.ts
  • apps/web/test/e2e/asset-registry-golden-poc.spec.ts
apps/web/src/**/*.{ts,tsx}

⚙️ CodeRabbit configuration file

apps/web/src/**/*.{ts,tsx}: OAuth access and refresh tokens must never enter browser JavaScript or
browser storage. Use the HttpOnly BFF session, CSRF-protected mutations,
generated Hey API data clients, accessible states, and both light and
dark themes. Handwritten transport is reserved for documented protocol
flows such as navigation redirects and streaming.

Files:

  • apps/web/src/features/assets/components/asset-detail-page.tsx
  • apps/web/src/features/assets/components/governance-workspace-page.tsx
  • apps/web/src/features/assets/components/governance-draft-workspace.tsx
  • apps/web/src/features/assets/governance-policy.test.ts
  • apps/web/src/features/assets/governance-policy.ts
ARCHITECTURE.md

📄 CodeRabbit inference engine (CLAUDE.md)

Keep ARCHITECTURE.md limited to implemented facts, current project-wide facts, and commands; do not use it for intended or unimplemented behavior.

Files:

  • ARCHITECTURE.md
apps/docs/content/docs/**/*.{md,mdx}

📄 CodeRabbit inference engine (apps/docs/CLAUDE.md)

apps/docs/content/docs/**/*.{md,mdx}: Public prose must live only in apps/docs/content/docs; internal engineering documents are source evidence, not publication input.
sourceRefs is build-time traceability metadata and must never be rendered in published content.
Draft pages must remain excluded unless DOCS_INCLUDE_DRAFTS=true is set for a local or controlled preview.

Files:

  • apps/docs/content/docs/reference/api-reference/assets.mdx
apps/docs/content/docs/**/*.mdx

📄 CodeRabbit inference engine (apps/docs/CLAUDE.md)

Use index.mdx for a section root and <slug>.mdx for a named English page; add Vietnamese pages individually as adjacent index.vi.mdx or <slug>.vi.mdx files, using the /vi/docs/... route.

Files:

  • apps/docs/content/docs/reference/api-reference/assets.mdx
apps/api/src/main/java/**/*.java

⚙️ CodeRabbit configuration file

apps/api/src/main/java/**/*.java: Enforce the browser-BFF and resource-server boundaries. Authentication
must resolve an active internal actor through the explicit issuer and
subject binding. Reject identity, tenant, roles, or permissions supplied
by request payloads, JWT email, or untrusted JWT role claims.

Files:

  • apps/api/src/main/java/com/orgmemory/api/assetregistry/AssetRegistryController.java
apps/web/**/*.{test,spec}.{ts,tsx}

📄 CodeRabbit inference engine (apps/web/CLAUDE.md)

Preserve the existing browser test suite when changing the web application.

Files:

  • apps/web/src/features/assets/governance-policy.test.ts
  • apps/web/test/e2e/asset-registry-golden-poc.spec.ts
🧠 Learnings (5)
📚 Learning: 2026-07-23T23:30:44.585Z
Learnt from: kl3inIT
Repo: kl3inIT/OrgMemory PR: 30
File: core/src/main/resources/db/migration/V32__evidence_scoped_graph_semantics.sql:0-0
Timestamp: 2026-07-23T23:30:44.585Z
Learning: For OrgMemory PostgreSQL Flyway migrations under core/src/main/resources/db/migration, do not recommend using `CREATE INDEX CONCURRENTLY` or `DROP INDEX CONCURRENTLY` inside application-owned Flyway migration SQL. Flyway’s schema-history connection may hold a transaction that can cause concurrent index operations to wait indefinitely (e.g., on a `virtualxid`), and docs/conventions.md forbids this pattern. If you need large production-table index replacement, pre-stage online index operations via the deployment pipeline (outside Flyway) rather than inside the migration; “ordinary” index replacement is acceptable for unreleased projections before production traffic.

Applied to files:

  • core/src/main/resources/db/migration/V15__record_asset_publication_mode.sql
📚 Learning: 2026-07-28T20:06:14.930Z
Learnt from: kl3inIT
Repo: kl3inIT/OrgMemory PR: 112
File: apps/docs/content/docs/developers/api-reference/administration.mdx:11-11
Timestamp: 2026-07-28T20:06:14.930Z
Learning: In OrgMemory public documentation MDX files, ensure any `lastReviewed` dates are set using the repository project timezone `Asia/Bangkok`, not the reviewer’s local timezone or the runtime/build timezone. When generating or updating API-reference pages, intentionally use the exact same `lastReviewed` date convention as the authored public documentation pages to keep timestamps consistent across both sources.

Applied to files:

  • apps/docs/content/docs/reference/api-reference/assets.mdx
📚 Learning: 2026-07-28T20:06:15.064Z
Learnt from: kl3inIT
Repo: kl3inIT/OrgMemory PR: 112
File: apps/docs/content/docs/developers/api-reference/authentication.mdx:12-12
Timestamp: 2026-07-28T20:06:15.064Z
Learning: In OrgMemory docs/tests that describe date-based review checks, treat the project timezone as Asia/Bangkok for all “date” comparisons/validations. Do not assume UTC when interpreting or validating fields like `lastReviewed`. For example, `lastReviewed: '2026-07-29'` should be considered valid when the effective “current date” in Asia/Bangkok is July 29, 2026 (not merely when the UTC date matches).

Applied to files:

  • apps/docs/content/docs/reference/api-reference/assets.mdx
📚 Learning: 2026-07-30T06:46:08.031Z
Learnt from: kl3inIT
Repo: kl3inIT/OrgMemory PR: 144
File: apps/docs/public-content.manifest.json:13-67
Timestamp: 2026-07-30T06:46:08.031Z
Learning: For the Fumadocs docs portal under apps/docs, follow the expected MDX filename conventions that drive section-root vs named-page routing. Use `index.mdx` for English section-root pages and `<slug>.mdx` for named pages. For Vietnamese, use adjacent locale-suffixed files: `index.vi.mdx` for section roots and `<slug>.vi.mdx` for named pages. Do not require or enforce a `page.mdx` filename; doing so would change/break the intended section-root route structure.

Applied to files:

  • apps/docs/content/docs/reference/api-reference/assets.mdx
📚 Learning: 2026-07-26T05:46:47.443Z
Learnt from: kl3inIT
Repo: kl3inIT/OrgMemory PR: 61
File: apps/mcp/src/main/java/com/orgmemory/mcp/McpSecurityConfiguration.java:50-52
Timestamp: 2026-07-26T05:46:47.443Z
Learning: In OrgMemory, treat the `apps/mcp` and `apps/api` as independent protocol adapter modules. When adjusting OAuth/wire-level scopes, do not introduce a shared Java constant or create a code dependency from `apps/mcp` to `apps/api` solely to deduplicate scope values. Instead, keep OAuth/scope constants adapter-local (e.g., in the relevant adapter/security configuration classes) and ensure cross-adapter consistency via automated realm/OAuth/authorization tests, rather than via shared wiring-level constants or cross-module references.

Applied to files:

  • apps/api/src/main/java/com/orgmemory/api/assetregistry/AssetRegistryController.java
🪛 Squawk (2.61.0)
core/src/main/resources/db/migration/V15__record_asset_publication_mode.sql

[warning] 2-2: Changing the size of a varchar field requires an ACCESS EXCLUSIVE lock, that will prevent all reads and writes to the table. Use a TEXT field with a CHECK constraint.

(prefer-text-field)


[warning] 6-7: By default new constraints require a table scan and block writes to the table while that scan occurs. Use NOT VALID with a later VALIDATE CONSTRAINT call.

(constraint-missing-not-valid)

🔇 Additional comments (30)
core/src/main/java/com/orgmemory/core/assetregistry/AssetPublicationMode.java (1)

1-11: LGTM!

core/src/main/java/com/orgmemory/core/assetregistry/AssetRelease.java (1)

6-7: LGTM!

Also applies to: 37-40, 72-72, 84-85, 116-119

core/src/main/java/com/orgmemory/core/assetregistry/AssetConsumptionRelease.java (1)

6-22: LGTM!

core/src/main/java/com/orgmemory/core/assetregistry/AssetDeliveryRelease.java (1)

10-25: LGTM!

Also applies to: 27-45

core/src/main/java/com/orgmemory/core/assetregistry/AssetView.java (1)

78-98: LGTM!

core/src/main/java/com/orgmemory/core/assetregistry/SkillInstallManifest.java (1)

13-39: LGTM!

core/src/main/java/com/orgmemory/core/assetregistry/AssetRegistryCoordinator.java (2)

211-211: LGTM!

Also applies to: 351-351, 518-518, 546-561, 634-683, 893-893, 1001-1016


563-632: 🔒 Security & Privacy

No change needed. AssetRegistryService.publishSkillDraft() calls require(actor, assetId, CAN_PUBLISH_SKILL) before delegating to coordinator.publishSkillDraft(), so the direct Skill publication path is guarded by can_publish_skill.

core/src/test/java/com/orgmemory/core/assetregistry/AssetValidationTests.java (1)

55-64: LGTM!

core/src/test/java/com/orgmemory/core/assetregistry/CapabilityPackServiceTests.java (1)

84-102: LGTM!

Also applies to: 104-122

apps/web/test/e2e/asset-registry-golden-poc.spec.ts (1)

39-54: LGTM!

Also applies to: 328-352, 554-554, 578-578, 591-636, 663-663, 694-694

core/src/main/java/com/orgmemory/core/assetregistry/SkillDistributionService.java (1)

139-139: LGTM!

core/src/test/java/com/orgmemory/core/assetregistry/SkillDistributionServiceTests.java (1)

45-45: LGTM!

Also applies to: 171-171

core/src/test/java/com/orgmemory/core/assetregistry/PromptExecutionServiceTests.java (1)

138-138: LGTM!

apps/api/src/test/java/com/orgmemory/api/assetregistry/AssetConsumptionControllerTests.java (1)

12-12: LGTM!

Also applies to: 125-125

apps/api/src/test/java/com/orgmemory/api/assetregistry/SkillDistributionControllerTests.java (1)

13-13: LGTM!

Also applies to: 127-127

apps/web/src/features/assets/governance-policy.ts (1)

20-30: LGTM!

apps/web/src/features/assets/governance-policy.test.ts (1)

3-7: LGTM!

Also applies to: 40-64

apps/web/src/features/assets/components/governance-workspace-page.tsx (1)

91-95: LGTM!

Also applies to: 129-129, 140-140, 467-469

apps/web/src/features/assets/components/asset-detail-page.tsx (1)

880-887: LGTM!

core/src/main/java/com/orgmemory/core/assetregistry/AssetAuthorizationTarget.java (1)

5-10: LGTM!

core/src/main/java/com/orgmemory/core/assetregistry/AssetGovernanceActions.java (1)

10-15: LGTM!

integrations/authorization-openfga/src/main/openfga/model.fga (1)

88-88: LGTM!

integrations/authorization-openfga/src/test/openfga/store.fga.yaml (1)

342-342: LGTM!

Also applies to: 353-369, 379-379, 390-390, 418-430

core/src/main/java/com/orgmemory/core/assetregistry/AssetRegistryService.java (1)

32-33: LGTM!

Also applies to: 188-197, 291-297, 360-376

core/src/test/java/com/orgmemory/core/assetregistry/AssetRegistryServiceTests.java (1)

33-64: LGTM!

Also applies to: 80-86

apps/api/src/main/java/com/orgmemory/api/assetregistry/AssetRegistryController.java (1)

106-108: LGTM!

Also applies to: 246-260

apps/api/src/test/java/com/orgmemory/api/assetregistry/AssetRegistryIntegrationTests.java (1)

37-37: LGTM!

Also applies to: 53-53, 977-1049, 1063-1105

apps/docs/content/docs/reference/api-reference/assets.mdx (1)

40-42: LGTM!

Also applies to: 154-155, 231-231

ARCHITECTURE.md (1)

118-121: LGTM!

Comment thread core/src/main/resources/db/migration/V15__record_asset_publication_mode.sql Outdated
@kl3inIT
kl3inIT merged commit 5099c48 into main Jul 31, 2026
14 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant