From 88067e283f6b562a1443b172d759d379b12feb4c Mon Sep 17 00:00:00 2001 From: Agent IX Date: Sat, 20 Jun 2026 22:52:34 -0700 Subject: [PATCH] FR-040: per-object roles + typed allowed_links Add capability roles and typed allowed_links (verb -> [type|role|"*"]) to every object type in the business domain. Lateral + cross-domain edges resolve cleanly against the merged edge_types/roles registries. Co-Authored-By: Claude Opus 4.8 (1M context) --- spec_objects_business/manifest.yaml | 42 +++++++++++++++++++++++++++++ 1 file changed, 42 insertions(+) diff --git a/spec_objects_business/manifest.yaml b/spec_objects_business/manifest.yaml index 07be076..078e2d3 100644 --- a/spec_objects_business/manifest.yaml +++ b/spec_objects_business/manifest.yaml @@ -14,6 +14,8 @@ artifact_types: [] lint_rules: [] object_types: - name: domain + allowed_links: + contains: [entity, aggregate_root, value_object, repository, event, state_machine, process, enumeration] data_schema: type: object body_extraction: @@ -58,6 +60,11 @@ object_types: after_heading: Ubiquitous Language required: false - name: entity + roles: [domain-object, persistable] + allowed_links: + contains: [nested_entity, value_object] + owns: [state_machine] + references: [entity, aggregate_root, enumeration] data_schema: type: object body_extraction: @@ -71,6 +78,10 @@ object_types: after_heading: Properties required: true - name: value_object + roles: [domain-object] + allowed_links: + composes: [value_object, enumeration] + references: [enumeration] data_schema: type: object body_extraction: @@ -88,6 +99,12 @@ object_types: after_heading: Fields required: false - name: aggregate_root + roles: [domain-object, persistable] + allowed_links: + aggregates: [entity, nested_entity] + contains: [value_object] + emits: [event] + references: [aggregate_root, enumeration] data_schema: type: object body_extraction: @@ -101,6 +118,10 @@ object_types: after_heading: Members required: true - name: nested_entity + roles: [domain-object] + allowed_links: + contains: [value_object] + references: [enumeration] data_schema: type: object body_extraction: @@ -114,6 +135,9 @@ object_types: after_heading: Parent required: true - name: repository + allowed_links: + persists: [aggregate_root, entity] + references: [data_schema] data_schema: type: object body_extraction: @@ -127,6 +151,10 @@ object_types: after_heading: Operations required: true - name: event + roles: [event-like] + allowed_links: + carries: [value_object, entity] + references: [aggregate_root, enumeration] data_schema: type: object body_extraction: @@ -141,6 +169,10 @@ object_types: required: true language: json - name: state_machine + allowed_links: + transitions_to: [state_machine] + raises: [event] + references: [enumeration] data_schema: type: object body_extraction: @@ -155,6 +187,14 @@ object_types: required: true language: mermaid - name: process + roles: [measurable] + allowed_links: + triggers: [process, action] + consumes: [event] + emits: [event] + reads: [aggregate_root, entity] + writes: [aggregate_root, entity] + operates_on: [domain-object] data_schema: type: object body_extraction: @@ -188,6 +228,8 @@ object_types: after_heading: Algorithm required: false - name: enumeration + allowed_links: + references: [enumeration] data_schema: type: object body_extraction: