Skip to main content

Metadata-Driven Architecture — Technical Design Document

Version: 1.0.0 | Date: May 11, 2026
Author: System Architecture Audit
Status: Current Production State


Table of Contents

  1. Executive Summary
  2. Architecture Document: Registry-Driven Entity Routes
  3. Navigation Sync Report
  4. Studio-Renderer Parity Map
  5. Recommendations

1. Executive Summary

Axiom Genesis employs a metadata-driven architecture where UI behavior, entity CRUD operations, and navigation are controlled by database configuration rather than hardcoded logic. This document audits three core subsystems:

SubsystemPurposeHealth Status
Registry LayerEntity metadata & field-level security✅ Healthy (30 registries)
Navigation LayerMenu structure & routing⚠️ Minor gaps identified
Studio-Renderer LayerDesign-time vs runtime parity✅ High parity

Key Findings

  • 22 navigation items configured across 5 target types
  • 30 object registries defining entity metadata
  • 20 dataview configs available for DATAVIEW navigation
  • 3 document projects with full renderer configuration
  • 2 potential zombie menu items identified (no frontend handler)
  • 1 hardcoded route without navigation config

2. Architecture Document: Registry-Driven Entity Routes

2.1 Overview

The entity routing system uses a three-layer resolution pattern:

┌─────────────────────────────────────────────────────────────────┐
│ API Request │
│ GET /api/v1/entity/:entity_code/get │
└─────────────────────────────────────────────────────────────────┘


┌─────────────────────────────────────────────────────────────────┐
│ Layer 1: Route Resolution (entity.routes.js) │
│ ├── verifyToken.validate_token (JWT validation) │
│ ├── resolveEntityInfo (→ EntityHelper.getEntityInfo) │
│ └── ProfileLoader.middleware() (policy loading) │
└─────────────────────────────────────────────────────────────────┘


┌─────────────────────────────────────────────────────────────────┐
│ Layer 2: Registry Resolution (redis-entity.helper.js) │
│ ├── Redis Cache Lookup (key: obj_registry:{entityCode}) │
│ │ └── TTL: 24 hours │
│ └── DB Fallback → app_object_registries │
│ └── Auto-cache result in Redis │
└─────────────────────────────────────────────────────────────────┘


┌─────────────────────────────────────────────────────────────────┐
│ Layer 3: Profile Resolution (profile-loader.util.js) │
│ ├── app_object_profiles lookup │
│ ├── Policy application: │
│ │ ├── projection (include/exclude fields) │
│ │ ├── masking (email, phone, SSN obfuscation) │
│ │ └── rowFilters (tenant isolation) │
│ └── Returns enriched request context │
└─────────────────────────────────────────────────────────────────┘

2.2 Registry Schema: app_object_registries

Current Registry Count: 30 entities

ColumnTypePurpose
obj_codeVARCHAR(100)Entity identifier (e.g., users, projects)
obj_descriptionVARCHAR(500)Human-readable name
obj_type_codeVARCHAR(50)TABLE | VIEW | FUNCTION
obj_connection_codeVARCHAR(100)FK to app_connections
obj_payloadJSONField definitions, relationships, validation rules
obj_payload_object_nameVARCHAR(200)Actual database table/view name
obj_payload_identifierVARCHAR(100)Primary key field name
obj_payload_column_prefixVARCHAR(10)Column naming prefix (e.g., usr_, prj_)

Registry Inventory (as of May 11, 2026):

obj_codeTypeConnection
applicationsTABLERADICS_CFG_DB
connectionsTABLERADICS_CFG_DB
dashboard_configsTABLERADICS_CFG_DB
dataview_configsTABLERADICS_CFG_DB
filesTABLERADICS_CFG_DB
load_role_based_menusFUNCTIONRADICS_CFG_DB
navigation_configsTABLERADICS_CFG_DB
object_profilesTABLERADICS_CFG_DB
object_registriesTABLERADICS_CFG_DB
page_configsTABLERADICS_CFG_DB
projectsTABLERADICS_CFG_DB
rolesTABLERADICS_CFG_DB
scrumboard_configsTABLERADICS_CFG_DB
tenantsTABLERADICS_CFG_DB
usersTABLERADICS_CFG_DB
value_setTABLERADICS_CFG_DB
workflow_configsTABLERADICS_CFG_DB
wft_instancesTABLERADICS_CFG_DB
wft_logsTABLERADICS_CFG_DB
wft_nodesTABLERADICS_CFG_DB
wft_approvalsTABLERADICS_CFG_DB
.........

2.3 Profile Schema: app_object_profiles

ColumnTypePurpose
prf_codeVARCHAR(100)Profile identifier
prf_object_codeVARCHAR(100)FK to app_object_registries.obj_code
prf_mode_codeVARCHAR(50)FULL | READ | WRITE | EXECUTE
prf_policyJSONSecurity policy (projection, masking, rowFilters)

Policy Structure Example:

{
"projection": {
"type": "exclude",
"fields": ["usr_password_hash", "usr_salt"]
},
"masking": {
"usr_email_id": "email_mask",
"usr_phone": "phone_mask"
},
"rowFilters": {
"usr_tenant_id": "@tenant_id"
}
}

2.4 Data Flow: prj_doc_config → DocumentRenderer

The Document Management System uses a dedicated data flow:

┌─────────────────────────────────────────────────────────────────┐
│ 1. Navigation Click │
│ nvc_target_type = 'document_renderer' │
│ nvc_target_code = 'KNOWLEDGE_BASE' │
│ nvc_config.renderer.projectSlug = 'knowledge-base' │
└─────────────────────────────────────────────────────────────────┘


┌─────────────────────────────────────────────────────────────────┐
│ 2. useNavigationHandler.ts │
│ Detects: navItem.targetType === 'document_renderer' │
│ Calls: handleDocumentRendererNavigation(action) │
└─────────────────────────────────────────────────────────────────┘


┌─────────────────────────────────────────────────────────────────┐
│ 3. useDocumentRendererNavigation.ts │
│ Builds: DocumentRendererConfig │
│ Opens: DocumentRendererDialog │
└─────────────────────────────────────────────────────────────────┘


┌─────────────────────────────────────────────────────────────────┐
│ 4. DocumentRenderer.tsx │
│ Props: projectSlug, projectId, navConfig │
│ Fetches: apt_projects.prj_doc_config via DocumentService │
│ Renders: Navigation tree, content, sidebars │
└─────────────────────────────────────────────────────────────────┘


┌─────────────────────────────────────────────────────────────────┐
│ 5. Content Resolution │
│ prj_doc_config.navigation.tree[] → DocSidebar │
│ Node.fileType → MarkdownRenderer / PdfViewer / FormRenderer │
│ Features from nvc_config → showSidebar, showTOC, etc. │
└─────────────────────────────────────────────────────────────────┘

Project Data (as of May 11, 2026):

prj_idprj_codeprj_slugStatus
1KNOWLEDGE_BASEknowledge-base✅ Active
2DEVELOPER_DOCSdeveloper-docs✅ Active
3HR_POLICIEShr-policies✅ Active

3. Navigation Sync Report

3.1 Database Navigation Configuration

Total Items: 22 navigation configurations
Target Type Distribution:

Target TypeCountHandler Status
DATAVIEW13✅ Fully handled
SECTION4✅ Expand-only (no navigation)
document_renderer3✅ Fully handled
CATEGORY1⚠️ No dedicated handler
DASHBOARD1⚠️ Partial handler

3.2 Frontend Route Inventory

Route PatternComponentHandles Target Type
/workspaceWorkspacePageLanding page
/workspace/dataviewerDataViewerPageDATAVIEW
/workspace/dataviewer/[code]DataViewerDynamicPageDATAVIEW (encrypted)
/workspace/viewerViewerPageFORM, PAGE
/workspace/viewer/[code]ViewerDynamicPageFORM (encrypted)
/workspace/documents/[slug]DocumentsBySlugPagedocument_renderer
/workspace/docsDocsLandingPageProject listing
/workspace/docs/[...slug]DocsPagePublic document reader
/workspace/dashboard/[key]DashboardPageDASHBOARD
/workspace/studio/formsDesignerStudioPagePage designer
/workspace/studio/workflow-designerWorkflowStudioPageWorkflow designer
/workspace/studio/scrumboard-designerScrumboardStudioPageSCRUMBOARD
/workspace/studio/document-studioDocumentStudioPageDocument designer
/workspace/app-assistantAppAssistantPageAI assistant

3.3 Sync Analysis

✅ Fully Synced (Config → Frontend Handler Exists)

nvc_codenvc_target_typenvc_target_codeFrontend Handler
nvc_usersDATAVIEWdvc_usersUnifiedDataViewer
nvc_rolesDATAVIEWdvc_rolesUnifiedDataViewer
nvc_tenantsDATAVIEWdvc_tenantsUnifiedDataViewer
nvc_connectionsDATAVIEWdvc_connectionsUnifiedDataViewer
nvc_applicationsDATAVIEWdvc_applicationsUnifiedDataViewer
nvc_object_registriesDATAVIEWdvc_object_registriesUnifiedDataViewer
nvc_page_configsDATAVIEWdvc_page_configsUnifiedDataViewer
nvc_dataview_configsDATAVIEWdvc_dataview_configsUnifiedDataViewer
nvc_navigation_configsDATAVIEWdvc_navigation_configsUnifiedDataViewer
nvc_workflow_configsDATAVIEWdvc_workflow_configsUnifiedDataViewer
nvc_scrumboard_configsDATAVIEWdvc_scrumboard_configsUnifiedDataViewer
nvc_value_setDATAVIEWdvc_value_setUnifiedDataViewer
nvc_document_studioDATAVIEWdvc_projectsUnifiedDataViewer + Studio action
nvc_doc_knowledge_basedocument_rendererKNOWLEDGE_BASEDocumentRenderer
nvc_doc_developer_docsdocument_rendererDEVELOPER_DOCSDocumentRenderer
nvc_doc_hr_policiesdocument_rendererHR_POLICIESDocumentRenderer
nvc_app_settingsSECTIONNULLExpand-only (sidebar)
nvc_configurationsSECTIONNULLExpand-only (sidebar)
nvc_setupSECTIONNULLExpand-only (sidebar)
nvc_user_role_mgmtSECTIONNULLExpand-only (sidebar)

⚠️ Zombie Menu Items (Config Exists → No Frontend Handler)

nvc_codenvc_target_typenvc_target_codeIssue
nvc_documentsCATEGORYNULLCATEGORY not in TargetType enum
nvc_admin_dashboardDASHBOARDdsh_adminHandler exists but dsh_admin config may be missing

Zombie Analysis:

  1. nvc_documents (CATEGORY): The CATEGORY target type is not defined in navigation-handler.ts TargetType enum. This item appears to be a parent container for document_renderer items but has no click handler.

  2. nvc_admin_dashboard (DASHBOARD): The DASHBOARD route exists at /workspace/dashboard/[key], but dsh_admin does not exist in app_dashboard_configs (table has 0 rows). This is a confirmed zombie item.

⚠️ Hardcoded Routes (Frontend Exists → No Navigation Config)

RouteComponentMissing Config
/workspace/app-assistantAppAssistantPageNo nvc_* entry for AI Assistant
/workspace/studio/formsDesignerStudioPageAccessed via row action, not menu
/workspace/studio/workflow-designerWorkflowStudioPageAccessed via row action, not menu

Note: Studio routes are intentionally accessed via DataViewer row actions rather than direct menu navigation. This is by design.

3.4 DataView Target Code Verification

All DATAVIEW navigation items reference valid dvc_* codes:

Navigation TargetDataView ConfigStatus
dvc_users✅ ExistsActive
dvc_roles✅ ExistsActive
dvc_tenants✅ ExistsActive
dvc_connections✅ ExistsActive
dvc_applications✅ ExistsActive
dvc_object_registries✅ ExistsActive
dvc_page_configs✅ ExistsActive
dvc_dataview_configs✅ ExistsActive
dvc_navigation_configs✅ ExistsActive
dvc_workflow_configs✅ ExistsActive
dvc_scrumboard_configs✅ ExistsActive
dvc_value_set✅ ExistsActive
dvc_projects✅ ExistsActive

4. Studio-Renderer Parity Map

4.1 Document Studio → Document Renderer

Studio FeatureConfig LocationRenderer ComponentParity
Navigation Treeprj_doc_config.navigation.tree[]DocSidebar✅ Full
Node SelectionStudio stateDocSidebar active state✅ Full
Folder ExpansionexpandedNodeIdsDocSidebar expand state✅ Full
Content EditingDocumentPropertiesPanelMarkdownRenderer (read-only)✅ Expected
File UploaduseDocumentStudioDraft.uploadFiles()apt_files → Blob Storage✅ Full
Drag-Drop ReorderDroppableNavigationTreeN/A (read-only)✅ Expected
Project PropertiesProjectManagementPanelHeader display✅ Full
Access ControlAccessControlDialogPermission enforcement✅ Full

Content Type Support

Studio InputNode PropertyRenderer Output
Markdown filefileType: 'markdown'MarkdownRenderer.tsx
HTML filefileType: 'html'Raw HTML render
PDF filefileType: 'pdf'PdfViewer.tsx
Image filefileType: 'image'<img> tag
Page ConfigpageId / pageCodeFormRenderer.tsx

Feature Flags (nvc_config.features)

Feature FlagStudio ConfigRenderer Implementation
showSidebar✅ ConfigurableDocSidebar conditional
showTOC✅ ConfigurableSectionSidebar (right)
showBreadcrumbs✅ ConfigurableRendererLayout header
allowDownload✅ Configurable✅ Download menu
allowShare✅ Configurable✅ Share button
allowPrint✅ Configurable✅ Print handler
showVersionInfo✅ Configurable✅ Footer metadata
enableSearch✅ Configurable⚠️ Partial (planned)
showReadingTime✅ Configurable✅ Footer display
showWordCount✅ Configurable✅ Footer display

4.2 Page Designer → Form Renderer

Studio FeatureConfig LocationRenderer ComponentParity
Field PaletteFieldPalette.tsxFormRenderer.tsx✅ Full
Canvas LayoutPageCanvas.tsxFormRenderer grid✅ Full
Field PropertiesFieldEditor.tsxField props✅ Full
Validation Rulespgc_page_schema.validation_rulesuseFormRendererFrameworks✅ Full
Calculated Fieldspgc_page_schema.calculateduseCalculatedFields✅ Full
Cascade Selectspgc_page_schema.dependsOnuseCascadeSelects✅ Full
Data SourcesDataSourceManagerFormRenderer fetch✅ Full
ActionsActionsManagerSubmit handlers✅ Full
Preview ModePageViewer (in studio)FormRenderer✅ Full

4.3 Workflow Designer → Workflow Engine

Studio FeatureConfig LocationRuntime ComponentParity
Node CanvasReactFlow canvasworkflow.service.js✅ Full
Node Propertieswfc_config.nodes[]Node execution✅ Full
Edge Connectionswfc_config.edges[]Flow routing✅ Full
Triggerswfc_config.triggersworkflow_schedulers✅ Full
Variableswfc_config.variablesContext injection✅ Full

4.4 Parity Gaps Identified

GapStudioRendererPriority
Search functionalityNot configurablePlannedMedium
Font size controlNot in StudioAvailable in RendererLow
Zoom controlNot in StudioAvailable in RendererLow
Edit mode toggleNot in StudioAvailable (allowEdit flag)Low

5. Recommendations

5.1 Immediate Actions

  1. Add CATEGORY to TargetType enum

    • File: src/lib/navigation-handler.ts
    • Add: CATEGORY = "category" to enum
    • Behavior: Treat as SECTION (expand children, no navigation)
  2. Verify Dashboard Config

    • Query: SELECT * FROM app_dashboard_configs WHERE dsc_code = 'dsh_admin'
    • If missing: Create dashboard configuration for admin dashboard
  3. Add AI Assistant Navigation Config

    • Optional: Create nvc_app_assistant navigation entry
    • Target type: PAGE or new AI_ASSISTANT type

5.2 Architecture Improvements

  1. Implement Search in DocumentRenderer

    • Add search index for document content
    • Connect to enableSearch feature flag
  2. Standardize Target Type Casing

    • Current: Mix of DATAVIEW, document_renderer, SECTION
    • Recommendation: Uppercase all (DOCUMENT_RENDERER)
  3. Add Navigation Config Validation

    • Validate nvc_target_code references exist in target tables
    • Add foreign key or trigger validation

5.3 Monitoring Recommendations

-- Find orphaned navigation configs (target code doesn't exist)
SELECT n.nvc_code, n.nvc_target_type, n.nvc_target_code
FROM app_navigation_configs n
LEFT JOIN app_dataview_configs d ON n.nvc_target_code = d.dvc_code
LEFT JOIN apt_projects p ON n.nvc_target_code = p.prj_code
WHERE n.nvc_target_type IN ('DATAVIEW', 'document_renderer')
AND n.nvc_is_deleted = 0
AND d.dvc_code IS NULL
AND p.prj_code IS NULL;

Appendix A: File References

Document SectionKey Files
Entity Routesaxiom-genesis-middleware/routes/v1/entity.routes.js
Entity Resolutionaxiom-genesis-middleware/helpers/redis-entity.helper.js
Profile Loadingaxiom-genesis-middleware/utils/profile-loader.util.js
Navigation Handleraxiom-genesis-frontend/src/lib/navigation-handler.ts
Navigation Hookaxiom-genesis-frontend/src/hooks/useNavigationHandler.ts
Document Rendereraxiom-genesis-frontend/src/components/workspace/viewer/document-viewer/DocumentRenderer.tsx
Document Studioaxiom-genesis-frontend/src/components/workspace/studio/document-studio/DocumentStudio.tsx
Page Designeraxiom-genesis-frontend/src/components/workspace/studio/page-designer/PageDesigner.tsx

Appendix B: Database Queries Used

-- Navigation configs
SELECT nvc_code, nvc_description, nvc_target_type, nvc_target_code, nvc_parent_code, nvc_status
FROM app_navigation_configs
WHERE ISNULL(nvc_is_deleted, 0) = 0;

-- Target type distribution
SELECT DISTINCT nvc_target_type, COUNT(*) as count
FROM app_navigation_configs
WHERE ISNULL(nvc_is_deleted, 0) = 0
GROUP BY nvc_target_type;

-- Object registries
SELECT obj_code, obj_description, obj_type_code, obj_connection_code
FROM app_object_registries
WHERE ISNULL(obj_is_deleted, 0) = 0;

-- DataView configs
SELECT dvc_code, dvc_description
FROM app_dataview_configs
WHERE ISNULL(dvc_is_deleted, 0) = 0;

-- Projects
SELECT prj_id, prj_code, prj_name, prj_slug
FROM apt_projects
WHERE ISNULL(prj_is_deleted, 0) = 0;

Document End | Generated: May 11, 2026