diff --git a/docs/architecture/README.md b/docs/architecture/README.md index dbd0a76..17ea39e 100644 --- a/docs/architecture/README.md +++ b/docs/architecture/README.md @@ -1,7 +1,7 @@ -# Application +# Application **Architecture Documentation** -Generated 2025-10-27 22:07:22 +Generated 2026-03-01 15:37:40 ## Overview @@ -13,7 +13,7 @@ Main application container The system context diagram shows how Application fits into its environment, including external systems and users. -![System Context Diagram](./diagrams/structurizr-SystemContext.png) +System Context Diagram --- @@ -21,26 +21,11 @@ The system context diagram shows how Application fits into its environment, incl The container diagram shows the high-level technology choices and how containers communicate. -![Container Diagram](./diagrams/structurizr-Containers.png) - - - - - - - - - - - - - - - - - - -
ContainerTypeDescriptionDetails
ApplicationApplicationMain application containerView →
+Container Diagram + +| Container | Type | Description | Details | +| --- | --- | --- | --- | +| **Application** | `Application` | Main application container | [View](./default-container.md) | --- @@ -48,3 +33,4 @@ The container diagram shows the high-level technology choices and how containers
Generated with Archlette Architecture-as-Code toolkit
+ diff --git a/docs/architecture/aac-ir.json b/docs/architecture/aac-ir.json index 3667886..75f2df0 100644 --- a/docs/architecture/aac-ir.json +++ b/docs/architecture/aac-ir.json @@ -98,7 +98,7 @@ "type": "module" }, { - "description": "Render stage of the AAC pipeline | PlantUML image renderer | Structurizr DSL export renderer", + "description": "Render stage of the AAC pipeline | Mermaid image renderer | PlantUML image renderer | Structurizr DSL export renderer | Structurizr direct image renderer", "id": "default_container__renderers", "containerId": "default-container", "name": "renderers", @@ -1196,7 +1196,7 @@ "visibility": "public", "isAsync": false, "filePath": "C:/Users/chris/git/archlette/src/core/tool-manager.ts", - "lineNumber": 64 + "lineNumber": 66 }, { "description": "Ensure cache directory exists", @@ -1212,16 +1212,16 @@ "visibility": "private", "isAsync": false, "filePath": "C:/Users/chris/git/archlette/src/core/tool-manager.ts", - "lineNumber": 72 + "lineNumber": 74 }, { - "description": "Check if a command exists in PATH", + "description": "Check if a command exists in PATH\nReturns the full path if found, null otherwise", "id": "default_container__core__commandexistsinpath", "componentId": "default_container__core", "name": "commandExistsInPath", "type": "function", "documentation": { - "summary": "Check if a command exists in PATH" + "summary": "Check if a command exists in PATH\nReturns the full path if found, null otherwise" }, "returnType": "string", "parameters": [ @@ -1231,10 +1231,10 @@ "optional": false } ], - "visibility": "private", + "visibility": "public", "isAsync": false, "filePath": "C:/Users/chris/git/archlette/src/core/tool-manager.ts", - "lineNumber": 83 + "lineNumber": 86 }, { "description": "Download a file from URL to destination", @@ -1266,7 +1266,7 @@ "visibility": "private", "isAsync": true, "filePath": "C:/Users/chris/git/archlette/src/core/tool-manager.ts", - "lineNumber": 102 + "lineNumber": 105 }, { "description": "Extract a ZIP file (simple extraction for Structurizr CLI)", @@ -1298,7 +1298,7 @@ "visibility": "private", "isAsync": true, "filePath": "C:/Users/chris/git/archlette/src/core/tool-manager.ts", - "lineNumber": 144 + "lineNumber": 147 }, { "description": "Make file executable (Unix only)", @@ -1320,7 +1320,7 @@ "visibility": "private", "isAsync": false, "filePath": "C:/Users/chris/git/archlette/src/core/tool-manager.ts", - "lineNumber": 171 + "lineNumber": 174 }, { "description": "Download and install Structurizr CLI to cache", @@ -1347,7 +1347,7 @@ "visibility": "private", "isAsync": true, "filePath": "C:/Users/chris/git/archlette/src/core/tool-manager.ts", - "lineNumber": 180 + "lineNumber": 183 }, { "description": "Download and install PlantUML to cache", @@ -1374,7 +1374,7 @@ "visibility": "private", "isAsync": true, "filePath": "C:/Users/chris/git/archlette/src/core/tool-manager.ts", - "lineNumber": 218 + "lineNumber": 221 }, { "description": "Find or download Structurizr CLI", @@ -1398,7 +1398,58 @@ "visibility": "public", "isAsync": true, "filePath": "C:/Users/chris/git/archlette/src/core/tool-manager.ts", - "lineNumber": 244 + "lineNumber": 247 + }, + { + "description": "Download and install Structurizr Lite to cache", + "id": "default_container__core__downloadstructurizrlite", + "componentId": "default_container__core", + "name": "downloadStructurizrLite", + "type": "function", + "documentation": { + "summary": "Download and install Structurizr Lite to cache" + }, + "returnType": "Promise", + "parameters": [ + { + "name": "cacheDir", + "type": "string", + "optional": false + }, + { + "name": "log", + "type": "import(\"C:/Users/chris/git/archlette/src/core/logger\").Logger", + "optional": true + } + ], + "visibility": "private", + "isAsync": true, + "filePath": "C:/Users/chris/git/archlette/src/core/tool-manager.ts", + "lineNumber": 284 + }, + { + "description": "Find or download Structurizr Lite WAR file", + "id": "default_container__core__findstructurizrlite", + "componentId": "default_container__core", + "name": "findStructurizrLite", + "type": "function", + "documentation": { + "summary": "Find or download Structurizr Lite WAR file" + }, + "returnType": "Promise", + "returnDescription": "Path to structurizr-lite.war file", + "parameters": [ + { + "name": "log", + "type": "import(\"C:/Users/chris/git/archlette/src/core/logger\").Logger", + "description": "- Optional logger", + "optional": true + } + ], + "visibility": "public", + "isAsync": true, + "filePath": "C:/Users/chris/git/archlette/src/core/tool-manager.ts", + "lineNumber": 316 }, { "description": "Find or download PlantUML JAR", @@ -1422,7 +1473,7 @@ "visibility": "public", "isAsync": true, "filePath": "C:/Users/chris/git/archlette/src/core/tool-manager.ts", - "lineNumber": 284 + "lineNumber": 342 }, { "description": "Verify Java is available", @@ -1439,7 +1490,7 @@ "visibility": "public", "isAsync": false, "filePath": "C:/Users/chris/git/archlette/src/core/tool-manager.ts", - "lineNumber": 313 + "lineNumber": 371 }, { "description": "Validate Java is installed (throw if not)", @@ -1455,7 +1506,31 @@ "visibility": "public", "isAsync": false, "filePath": "C:/Users/chris/git/archlette/src/core/tool-manager.ts", - "lineNumber": 334 + "lineNumber": 392 + }, + { + "description": "Find Mermaid CLI in system PATH\n\nNote: Mermaid CLI is not auto-downloaded. Users should install it via npm:\n- Global: npm install -g", + "id": "default_container__core__findmermaidcli", + "componentId": "default_container__core", + "name": "findMermaidCLI", + "type": "function", + "documentation": { + "summary": "Find Mermaid CLI in system PATH\n\nNote: Mermaid CLI is not auto-downloaded. Users should install it via npm:\n- Global: npm install -g" + }, + "returnType": "string", + "returnDescription": "Path to mmdc executable", + "parameters": [ + { + "name": "log", + "type": "import(\"C:/Users/chris/git/archlette/src/core/logger\").Logger", + "description": "- Optional logger", + "optional": true + } + ], + "visibility": "public", + "isAsync": false, + "filePath": "C:/Users/chris/git/archlette/src/core/tool-manager.ts", + "lineNumber": 421 }, { "description": "For each stage, resolve includes/excludes for each node:\n - If node omits includes/excludes, inherit from defaults.\n - Add configBaseDir for resolving config-relative paths", @@ -1546,7 +1621,7 @@ "visibility": "private", "isAsync": false, "filePath": "C:/Users/chris/git/archlette/src/docs/builtin/markdown-docs.ts", - "lineNumber": 244 + "lineNumber": 262 }, { "description": "Find component diagrams for a specific container", @@ -1583,7 +1658,7 @@ "visibility": "private", "isAsync": false, "filePath": "C:/Users/chris/git/archlette/src/docs/builtin/markdown-docs.ts", - "lineNumber": 276 + "lineNumber": 295 }, { "description": "Find class diagrams for a specific component", @@ -1620,7 +1695,7 @@ "visibility": "private", "isAsync": false, "filePath": "C:/Users/chris/git/archlette/src/docs/builtin/markdown-docs.ts", - "lineNumber": 314 + "lineNumber": 334 }, { "id": "default_container__docs__sanitizefilename", @@ -1638,7 +1713,7 @@ "visibility": "private", "isAsync": false, "filePath": "C:/Users/chris/git/archlette/src/docs/builtin/markdown-docs.ts", - "lineNumber": 348 + "lineNumber": 369 }, { "description": "Extract architecture information from an Astro codebase", @@ -1800,7 +1875,7 @@ "visibility": "private", "isAsync": false, "filePath": "C:/Users/chris/git/archlette/src/generators/builtin/structurizr.ts", - "lineNumber": 57 + "lineNumber": 59 }, { "description": "Generate Structurizr DSL from ArchletteIR", @@ -1826,7 +1901,7 @@ "visibility": "public", "isAsync": false, "filePath": "C:/Users/chris/git/archlette/src/generators/builtin/structurizr.ts", - "lineNumber": 73 + "lineNumber": 75 }, { "description": "Prepare container data with components, code, and relationships for template", @@ -1853,7 +1928,7 @@ "visibility": "private", "isAsync": false, "filePath": "C:/Users/chris/git/archlette/src/generators/builtin/structurizr.ts", - "lineNumber": 148 + "lineNumber": 154 }, { "description": "Prepare component view data for template", @@ -1880,7 +1955,7 @@ "visibility": "private", "isAsync": false, "filePath": "C:/Users/chris/git/archlette/src/generators/builtin/structurizr.ts", - "lineNumber": 198 + "lineNumber": 204 }, { "description": "Prepare class view data for template", @@ -1907,7 +1982,7 @@ "visibility": "private", "isAsync": false, "filePath": "C:/Users/chris/git/archlette/src/generators/builtin/structurizr.ts", - "lineNumber": 235 + "lineNumber": 241 }, { "description": "Generate all actor-related relationships", @@ -1929,7 +2004,7 @@ "visibility": "private", "isAsync": false, "filePath": "C:/Users/chris/git/archlette/src/generators/builtin/structurizr.ts", - "lineNumber": 250 + "lineNumber": 256 }, { "description": "Generate a unique name for a code item to avoid naming collisions", @@ -1951,7 +2026,7 @@ "visibility": "private", "isAsync": false, "filePath": "C:/Users/chris/git/archlette/src/generators/builtin/structurizr.ts", - "lineNumber": 297 + "lineNumber": 303 }, { "description": "Build technology string from relationship metadata", @@ -1973,7 +2048,7 @@ "visibility": "private", "isAsync": false, "filePath": "C:/Users/chris/git/archlette/src/generators/builtin/structurizr.ts", - "lineNumber": 335 + "lineNumber": 341 }, { "description": "Sanitize ID for DSL (remove special characters, convert to valid identifier)", @@ -1995,7 +2070,7 @@ "visibility": "private", "isAsync": false, "filePath": "C:/Users/chris/git/archlette/src/generators/builtin/structurizr.ts", - "lineNumber": 351 + "lineNumber": 357 }, { "description": "Escape special characters in strings for DSL\n\nStructurizr DSL doesn't support \\n escape sequences in strings,\nso we replace newlines with spaces for cleaner output.", @@ -2017,7 +2092,33 @@ "visibility": "private", "isAsync": false, "filePath": "C:/Users/chris/git/archlette/src/generators/builtin/structurizr.ts", - "lineNumber": 361 + "lineNumber": 367 + }, + { + "description": "Render Mermaid files to images", + "id": "default_container__renderers__mermaidrender", + "componentId": "default_container__renderers", + "name": "mermaidRender", + "type": "function", + "documentation": { + "summary": "Render Mermaid files to images" + }, + "returnType": "Promise", + "parameters": [ + { + "name": "ctx", + "type": "import(\"C:/Users/chris/git/archlette/src/core/types\").PipelineContext", + "optional": false + }, + { + "name": "node", + "optional": false + } + ], + "visibility": "public", + "isAsync": true, + "filePath": "C:/Users/chris/git/archlette/src/renderers/builtin/mermaid-render.ts", + "lineNumber": 41 }, { "description": "Render PlantUML files to PNG images", @@ -2042,13 +2143,13 @@ "lineNumber": 28 }, { - "description": "Export Structurizr DSL to PlantUML and Mermaid formats", + "description": "Export Structurizr DSL to PlantUML and/or Mermaid formats", "id": "default_container__renderers__structurizrexport", "componentId": "default_container__renderers", "name": "structurizrExport", "type": "function", "documentation": { - "summary": "Export Structurizr DSL to PlantUML and Mermaid formats" + "summary": "Export Structurizr DSL to PlantUML and/or Mermaid formats" }, "returnType": "Promise", "parameters": [ @@ -2056,12 +2157,233 @@ "name": "ctx", "type": "import(\"C:/Users/chris/git/archlette/src/core/types\").PipelineContext", "optional": false + }, + { + "name": "node", + "optional": false } ], "visibility": "public", "isAsync": true, "filePath": "C:/Users/chris/git/archlette/src/renderers/builtin/structurizr-export.ts", - "lineNumber": 28 + "lineNumber": 36 + }, + { + "description": "Find Graphviz dot command in PATH", + "id": "default_container__renderers__findgraphviz", + "componentId": "default_container__renderers", + "name": "findGraphviz", + "type": "function", + "documentation": { + "summary": "Find Graphviz dot command in PATH" + }, + "returnType": "string", + "parameters": [ + { + "name": "log", + "type": "{ debug?: (msg: string) => void; warn?: (msg: string) => void; }", + "optional": true + } + ], + "visibility": "private", + "isAsync": false, + "filePath": "C:/Users/chris/git/archlette/src/renderers/builtin/structurizr-render.ts", + "lineNumber": 41 + }, + { + "description": "Render Structurizr DSL to images using CLI DOT export + Graphviz", + "id": "default_container__renderers__structurizrrender", + "componentId": "default_container__renderers", + "name": "structurizrRender", + "type": "function", + "documentation": { + "summary": "Render Structurizr DSL to images using CLI DOT export + Graphviz" + }, + "returnType": "Promise", + "parameters": [ + { + "name": "ctx", + "type": "import(\"C:/Users/chris/git/archlette/src/core/types\").PipelineContext", + "optional": false + }, + { + "name": "node", + "optional": false + } + ], + "visibility": "public", + "isAsync": true, + "filePath": "C:/Users/chris/git/archlette/src/renderers/builtin/structurizr-render.ts", + "lineNumber": 74 + }, + { + "description": "Extract styles block from theme content using brace counting", + "id": "default_container__renderers__extractstylesblock", + "componentId": "default_container__renderers", + "name": "extractStylesBlock", + "type": "function", + "documentation": { + "summary": "Extract styles block from theme content using brace counting" + }, + "returnType": "string", + "parameters": [ + { + "name": "content", + "type": "string", + "optional": false + } + ], + "visibility": "private", + "isAsync": false, + "filePath": "C:/Users/chris/git/archlette/src/renderers/builtin/structurizr-render.ts", + "lineNumber": 267 + }, + { + "description": "Remove a block from DSL content using brace counting", + "id": "default_container__renderers__removeblock", + "componentId": "default_container__renderers", + "name": "removeBlock", + "type": "function", + "documentation": { + "summary": "Remove a block from DSL content using brace counting" + }, + "returnType": "string", + "parameters": [ + { + "name": "content", + "type": "string", + "optional": false + }, + { + "name": "blockName", + "type": "string", + "optional": false + } + ], + "visibility": "private", + "isAsync": false, + "filePath": "C:/Users/chris/git/archlette/src/renderers/builtin/structurizr-render.ts", + "lineNumber": 293 + }, + { + "id": "default_container__renderers__removestylesblock", + "componentId": "default_container__renderers", + "name": "removeStylesBlock", + "type": "function", + "returnType": "string", + "parameters": [ + { + "name": "content", + "type": "string", + "optional": false + } + ], + "visibility": "private", + "isAsync": false, + "filePath": "C:/Users/chris/git/archlette/src/renderers/builtin/structurizr-render.ts", + "lineNumber": 319 + }, + { + "id": "default_container__renderers__removebrandingblock", + "componentId": "default_container__renderers", + "name": "removeBrandingBlock", + "type": "function", + "returnType": "string", + "parameters": [ + { + "name": "content", + "type": "string", + "optional": false + } + ], + "visibility": "private", + "isAsync": false, + "filePath": "C:/Users/chris/git/archlette/src/renderers/builtin/structurizr-render.ts", + "lineNumber": 323 + }, + { + "description": "Escape all angle brackets that aren't part of valid DOT HTML tags.\n\nHandles cases where Structurizr inserts
for word-wrapping inside\nother tag-like content (e.g., />\").\n\nStrategy:\n1. Find all valid HTML tags using regex\n2. Escape all < and > that are NOT part of those tags", + "id": "default_container__renderers__escapeinvalidhtmltags", + "componentId": "default_container__renderers", + "name": "escapeInvalidHtmlTags", + "type": "function", + "documentation": { + "summary": "Escape all angle brackets that aren't part of valid DOT HTML tags.\n\nHandles cases where Structurizr inserts
for word-wrapping inside\nother tag-like content (e.g., />\").\n\nStrategy:\n1. Find all valid HTML tags using regex\n2. Escape all < and > that are NOT part of those tags" + }, + "returnType": "string", + "parameters": [ + { + "name": "content", + "type": "string", + "optional": false + }, + { + "name": "debug", + "type": "boolean", + "optional": true, + "defaultValue": "false" + } + ], + "visibility": "private", + "isAsync": false, + "filePath": "C:/Users/chris/git/archlette/src/renderers/builtin/structurizr-render.ts", + "lineNumber": 359 + }, + { + "description": "Sanitize DOT file content for Graphviz compatibility\n\nApplies string replacements only within label=<<...>> content,\npreserving the DOT structural syntax.", + "id": "default_container__renderers__sanitizedotcontent", + "componentId": "default_container__renderers", + "name": "sanitizeDotContent", + "type": "function", + "documentation": { + "summary": "Sanitize DOT file content for Graphviz compatibility\n\nApplies string replacements only within label=<<...>> content,\npreserving the DOT structural syntax." + }, + "returnType": "string", + "parameters": [ + { + "name": "content", + "type": "string", + "optional": false + }, + { + "name": "debug", + "type": "boolean", + "optional": true, + "defaultValue": "false" + } + ], + "visibility": "private", + "isAsync": false, + "filePath": "C:/Users/chris/git/archlette/src/renderers/builtin/structurizr-render.ts", + "lineNumber": 410 + }, + { + "description": "Sanitize all DOT files in a directory", + "id": "default_container__renderers__sanitizedotfiles", + "componentId": "default_container__renderers", + "name": "sanitizeDotFiles", + "type": "function", + "documentation": { + "summary": "Sanitize all DOT files in a directory" + }, + "returnType": "void", + "parameters": [ + { + "name": "dotDir", + "type": "string", + "optional": false + }, + { + "name": "debug", + "type": "boolean", + "optional": true, + "defaultValue": "false" + } + ], + "visibility": "private", + "isAsync": false, + "filePath": "C:/Users/chris/git/archlette/src/renderers/builtin/structurizr-render.ts", + "lineNumber": 501 }, { "description": "Validates the IR against the Zod schema. Throws if invalid.", @@ -4602,7 +4924,7 @@ "visibility": "private", "isAsync": false, "filePath": "C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/to-ir-mapper.ts", - "lineNumber": 77 + "lineNumber": 78 }, { "description": "Derive container type from wrangler configuration\n\nLogic:\n- If 'main' field exists → Cloudflare Worker\n- Otherwise → Cloudflare Service (generic)", @@ -4626,7 +4948,7 @@ "visibility": "private", "isAsync": false, "filePath": "C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/to-ir-mapper.ts", - "lineNumber": 110 + "lineNumber": 111 }, { "description": "Extract deployments and container instances\n\nCreates:\n- One deployment per environment\n- Container instances for each container in each environment", @@ -4656,16 +4978,46 @@ "visibility": "private", "isAsync": false, "filePath": "C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/to-ir-mapper.ts", - "lineNumber": 131 + "lineNumber": 132 + }, + { + "description": "Smart lookup to find matching container for a service name\n\nTries exact match first, then fuzzy matching with common environment suffix removal.", + "id": "default_container__basic_wrangler__findmatchingcontainer", + "componentId": "default_container__basic_wrangler", + "name": "findMatchingContainer", + "type": "function", + "documentation": { + "summary": "Smart lookup to find matching container for a service name\n\nTries exact match first, then fuzzy matching with common environment suffix removal." + }, + "returnType": "string", + "returnDescription": "Matching container ID or null", + "parameters": [ + { + "name": "serviceName", + "type": "string", + "description": "- Service name from binding (e.g., \"content-service-preview\")", + "optional": false + }, + { + "name": "containers", + "type": "{ id: string; name: string; }[]", + "description": "- Available containers", + "optional": false + } + ], + "visibility": "private", + "isAsync": false, + "filePath": "C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/to-ir-mapper.ts", + "lineNumber": 276 }, { - "description": "Extract container relationships from service bindings\n\nCreates logical dependencies between containers based on service bindings.\nDeduplicates relationships across all environments.", + "description": "Extract container relationships from service bindings\n\nCreates logical dependencies between containers based on service bindings.\nUses smart lookup to match service names to actual containers.\nDeduplicates relationships across all environments.", "id": "default_container__basic_wrangler__extractcontainerrelationships", "componentId": "default_container__basic_wrangler", "name": "extractContainerRelationships", "type": "function", "documentation": { - "summary": "Extract container relationships from service bindings\n\nCreates logical dependencies between containers based on service bindings.\nDeduplicates relationships across all environments." + "summary": "Extract container relationships from service bindings\n\nCreates logical dependencies between containers based on service bindings.\nUses smart lookup to match service names to actual containers.\nDeduplicates relationships across all environments." }, "returnType": "z.infer[]", "returnDescription": "Array of container relationships", @@ -4675,12 +5027,18 @@ "type": "import(\"C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/types\").WranglerConfig[]", "description": "- Parsed wrangler configurations", "optional": false + }, + { + "name": "containers", + "type": "{ id: string; name: string; }[]", + "description": "- Available containers for matching", + "optional": false } ], "visibility": "private", "isAsync": false, "filePath": "C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/to-ir-mapper.ts", - "lineNumber": 275 + "lineNumber": 325 }, { "description": "Extract deployment relationships from container instances\n\nCreates physical instance-to-instance relationships based on service bindings.\nEach relationship represents an actual runtime dependency in a specific environment.", @@ -4704,7 +5062,7 @@ "visibility": "private", "isAsync": false, "filePath": "C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/to-ir-mapper.ts", - "lineNumber": 321 + "lineNumber": 381 }, { "description": "Extract description from", @@ -4728,7 +5086,7 @@ "visibility": "private", "isAsync": false, "filePath": "C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/wrangler-parser.ts", - "lineNumber": 27 + "lineNumber": 28 }, { "description": "Parse a wrangler.toml file", @@ -4752,7 +5110,7 @@ "visibility": "public", "isAsync": true, "filePath": "C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/wrangler-parser.ts", - "lineNumber": 48 + "lineNumber": 49 }, { "description": "Normalize service bindings from various formats\n\nWrangler supports multiple binding formats:\n- [[services]] array (TOML array of tables)\n- services = [{ binding = \"...\", service = \"...\" }]", @@ -4774,7 +5132,7 @@ "visibility": "public", "isAsync": false, "filePath": "C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/wrangler-parser.ts", - "lineNumber": 108 + "lineNumber": 109 }, { "description": "Get all environments from a wrangler config\n\nReturns a list of environment names, including:\n- \"production\" (from root-level config if it has deployable content)\n- All keys from env.* sections", @@ -4796,7 +5154,7 @@ "visibility": "public", "isAsync": false, "filePath": "C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/wrangler-parser.ts", - "lineNumber": 129 + "lineNumber": 130 }, { "description": "Get configuration for a specific environment\n\nMerges root-level config with environment-specific overrides.\nEnvironment config takes precedence.", @@ -4807,7 +5165,7 @@ "documentation": { "summary": "Get configuration for a specific environment\n\nMerges root-level config with environment-specific overrides.\nEnvironment config takes precedence." }, - "returnType": "{ name: string; vars?: Record; services?: import(\"C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/types\").ServiceBinding[]; kv_namespaces?: import(\"C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/types\").KVBinding[]; r2_buckets?: import(\"C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/types\").R2Binding[]; d1_databases?: import(\"C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/types\").D1Binding[]; durable_objects?: { bindings: import(\"C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/types\").DurableObjectBinding[]; }; queues?: { producers?: import(\"C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/types\").QueueBinding[]; consumers?: import(\"C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/types\").QueueBinding[]; }; routes?: string[]; triggers?: { crons?: string[]; }; observability?: Record; }", + "returnType": "{ name: string; vars?: Record; services?: import(\"C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/types\").ServiceBinding[]; kv_namespaces?: import(\"C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/types\").KVBinding[]; r2_buckets?: import(\"C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/types\").R2Binding[]; d1_databases?: import(\"C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/types\").D1Binding[]; durable_objects?: { bindings: import(\"C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/types\").DurableObjectBinding[]; }; queues?: { producers?: import(\"C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/types\").QueueBinding[]; consumers?: import(\"C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/types\").QueueBinding[]; }; routes?: import(\"C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/types\").Route[]; triggers?: { crons?: string[]; }; observability?: Record; }", "returnDescription": "Merged environment configuration", "parameters": [ { @@ -4826,7 +5184,7 @@ "visibility": "public", "isAsync": false, "filePath": "C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/wrangler-parser.ts", - "lineNumber": 170 + "lineNumber": 171 }, { "description": "Deduplicate relationships by source+destination combination\n- Excludes self-referential relationships (source === destination)\n- Merges descriptions and stereotypes with \" | \" separator when duplicates are found\n- Extracts imported names from descriptions (removes \"imports \" prefix) and keeps only unique names\n- Returns one relationship per unique source+destination pair", @@ -5043,11 +5401,11 @@ "stereotype": "import" }, { - "description": "Provides types, module loading, and tool management | PipelineContext | findPlantUML | requireJava | resolveArchlettePath | findStructurizrCLI", + "description": "Provides types, module loading, and tool management | PipelineContext | ResolvedStageNode | findMermaidCLI | resolveArchlettePath | findPlantUML | requireJava | findStructurizrCLI | commandExistsInPath", "tags": [], "source": "default_container__renderers", "destination": "default_container__core", - "stereotype": "type-import | import | import | import | type-import | import | import | import" + "stereotype": "type-import | import | import | type-import | import | import | import | type-import | type-import | import | import | import | type-import | type-import | import | import | import | import" }, { "description": "imports PipelineContext", @@ -6504,6 +6862,48 @@ "destination": "node:fs:readFileSync", "stereotype": "import" }, + { + "description": "imports * as fs", + "source": "C:/Users/chris/git/archlette/src/renderers/builtin/mermaid-render.ts", + "destination": "node:fs:* as fs", + "stereotype": "import" + }, + { + "description": "imports * as path", + "source": "C:/Users/chris/git/archlette/src/renderers/builtin/mermaid-render.ts", + "destination": "node:path:* as path", + "stereotype": "import" + }, + { + "description": "imports execSync", + "source": "C:/Users/chris/git/archlette/src/renderers/builtin/mermaid-render.ts", + "destination": "node:child_process:execSync", + "stereotype": "import" + }, + { + "description": "imports PipelineContext", + "source": "C:/Users/chris/git/archlette/src/renderers/builtin/mermaid-render.ts", + "destination": "../../core/types.js:PipelineContext", + "stereotype": "type-import" + }, + { + "description": "imports ResolvedStageNode", + "source": "C:/Users/chris/git/archlette/src/renderers/builtin/mermaid-render.ts", + "destination": "../../core/types-aac.js:ResolvedStageNode", + "stereotype": "type-import" + }, + { + "description": "imports findMermaidCLI", + "source": "C:/Users/chris/git/archlette/src/renderers/builtin/mermaid-render.ts", + "destination": "../../core/tool-manager.js:findMermaidCLI", + "stereotype": "import" + }, + { + "description": "imports resolveArchlettePath", + "source": "C:/Users/chris/git/archlette/src/renderers/builtin/mermaid-render.ts", + "destination": "../../core/path-resolver.js:resolveArchlettePath", + "stereotype": "import" + }, { "description": "imports * as fs", "source": "C:/Users/chris/git/archlette/src/renderers/builtin/plantuml-render.ts", @@ -6570,6 +6970,12 @@ "destination": "../../core/types.js:PipelineContext", "stereotype": "type-import" }, + { + "description": "imports ResolvedStageNode", + "source": "C:/Users/chris/git/archlette/src/renderers/builtin/structurizr-export.ts", + "destination": "../../core/types-aac.js:ResolvedStageNode", + "stereotype": "type-import" + }, { "description": "imports findStructurizrCLI", "source": "C:/Users/chris/git/archlette/src/renderers/builtin/structurizr-export.ts", @@ -6588,6 +6994,60 @@ "destination": "../../core/path-resolver.js:resolveArchlettePath", "stereotype": "import" }, + { + "description": "imports * as fs", + "source": "C:/Users/chris/git/archlette/src/renderers/builtin/structurizr-render.ts", + "destination": "node:fs:* as fs", + "stereotype": "import" + }, + { + "description": "imports * as path", + "source": "C:/Users/chris/git/archlette/src/renderers/builtin/structurizr-render.ts", + "destination": "node:path:* as path", + "stereotype": "import" + }, + { + "description": "imports execSync", + "source": "C:/Users/chris/git/archlette/src/renderers/builtin/structurizr-render.ts", + "destination": "node:child_process:execSync", + "stereotype": "import" + }, + { + "description": "imports PipelineContext", + "source": "C:/Users/chris/git/archlette/src/renderers/builtin/structurizr-render.ts", + "destination": "../../core/types.js:PipelineContext", + "stereotype": "type-import" + }, + { + "description": "imports ResolvedStageNode", + "source": "C:/Users/chris/git/archlette/src/renderers/builtin/structurizr-render.ts", + "destination": "../../core/types-aac.js:ResolvedStageNode", + "stereotype": "type-import" + }, + { + "description": "imports findStructurizrCLI", + "source": "C:/Users/chris/git/archlette/src/renderers/builtin/structurizr-render.ts", + "destination": "../../core/tool-manager.js:findStructurizrCLI", + "stereotype": "import" + }, + { + "description": "imports commandExistsInPath", + "source": "C:/Users/chris/git/archlette/src/renderers/builtin/structurizr-render.ts", + "destination": "../../core/tool-manager.js:commandExistsInPath", + "stereotype": "import" + }, + { + "description": "imports requireJava", + "source": "C:/Users/chris/git/archlette/src/renderers/builtin/structurizr-render.ts", + "destination": "../../core/tool-manager.js:requireJava", + "stereotype": "import" + }, + { + "description": "imports resolveArchlettePath", + "source": "C:/Users/chris/git/archlette/src/renderers/builtin/structurizr-render.ts", + "destination": "../../core/path-resolver.js:resolveArchlettePath", + "stereotype": "import" + }, { "description": "imports zArchletteIR", "source": "C:/Users/chris/git/archlette/src/validators/builtin/base-validator.ts", @@ -7866,6 +8326,12 @@ "destination": "./types.js:QueueBinding", "stereotype": "type-import" }, + { + "description": "imports Route", + "source": "C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/wrangler-parser.ts", + "destination": "./types.js:Route", + "stereotype": "type-import" + }, { "description": "imports Relationship", "source": "C:/Users/chris/git/archlette/src/extractors/builtin/shared/relationship-utils.ts", diff --git a/docs/architecture/aac.dsl b/docs/architecture/aac.dsl index 2229e9e..508f0e0 100644 --- a/docs/architecture/aac.dsl +++ b/docs/architecture/aac.dsl @@ -39,7 +39,7 @@ workspace "Application" "Main application container" { technology "module" } default_container__renderers = component "renderers" { - description "Render stage of the AAC pipeline | PlantUML image renderer | Structurizr DSL export renderer" + description "Render stage of the AAC pipeline | Mermaid image renderer | PlantUML image renderer | Structurizr DSL export renderer | Structurizr direct image renderer" technology "module" } default_container__docs = component "docs" { @@ -279,7 +279,7 @@ workspace "Application" "Main application container" { tags "Code" } default_container__core__commandexistsinpath = component "core.commandExistsInPath" { - description "Check if a command exists in PATH" + description "Check if a command exists in PATH Returns the full path if found, null otherwise" technology "function" tags "Code" } @@ -313,6 +313,16 @@ workspace "Application" "Main application container" { technology "function" tags "Code" } + default_container__core__downloadstructurizrlite = component "core.downloadStructurizrLite" { + description "Download and install Structurizr Lite to cache" + technology "function" + tags "Code" + } + default_container__core__findstructurizrlite = component "core.findStructurizrLite" { + description "Find or download Structurizr Lite WAR file" + technology "function" + tags "Code" + } default_container__core__findplantuml = component "core.findPlantUML" { description "Find or download PlantUML JAR" technology "function" @@ -328,6 +338,11 @@ workspace "Application" "Main application container" { technology "function" tags "Code" } + default_container__core__findmermaidcli = component "core.findMermaidCLI" { + description "Find Mermaid CLI in system PATH Note: Mermaid CLI is not auto-downloaded. Users should install it via npm: - Global: npm install -g" + technology "function" + tags "Code" + } default_container__core__resolveconfig = component "core.resolveConfig" { description "For each stage, resolve includes/excludes for each node: - If node omits includes/excludes, inherit from defaults. - Add configBaseDir for resolving config-relative paths" technology "function" @@ -432,13 +447,61 @@ workspace "Application" "Main application container" { technology "function" tags "Code" } + default_container__renderers__mermaidrender = component "renderers.mermaidRender" { + description "Render Mermaid files to images" + technology "function" + tags "Code" + } default_container__renderers__plantumlrender = component "renderers.plantumlRender" { description "Render PlantUML files to PNG images" technology "function" tags "Code" } default_container__renderers__structurizrexport = component "renderers.structurizrExport" { - description "Export Structurizr DSL to PlantUML and Mermaid formats" + description "Export Structurizr DSL to PlantUML and/or Mermaid formats" + technology "function" + tags "Code" + } + default_container__renderers__findgraphviz = component "renderers.findGraphviz" { + description "Find Graphviz dot command in PATH" + technology "function" + tags "Code" + } + default_container__renderers__structurizrrender = component "renderers.structurizrRender" { + description "Render Structurizr DSL to images using CLI DOT export + Graphviz" + technology "function" + tags "Code" + } + default_container__renderers__extractstylesblock = component "renderers.extractStylesBlock" { + description "Extract styles block from theme content using brace counting" + technology "function" + tags "Code" + } + default_container__renderers__removeblock = component "renderers.removeBlock" { + description "Remove a block from DSL content using brace counting" + technology "function" + tags "Code" + } + default_container__renderers__removestylesblock = component "renderers.removeStylesBlock" { + technology "function" + tags "Code" + } + default_container__renderers__removebrandingblock = component "renderers.removeBrandingBlock" { + technology "function" + tags "Code" + } + default_container__renderers__escapeinvalidhtmltags = component "renderers.escapeInvalidHtmlTags" { + description "Escape all angle brackets that aren't part of valid DOT HTML tags. Handles cases where Structurizr inserts
for word-wrapping inside other tag-like content (e.g., />\"). Strategy: 1. Find all valid HTML tags using regex 2. Escape all < and > that are NOT part of those tags" + technology "function" + tags "Code" + } + default_container__renderers__sanitizedotcontent = component "renderers.sanitizeDotContent" { + description "Sanitize DOT file content for Graphviz compatibility Applies string replacements only within label=<<...>> content, preserving the DOT structural syntax." + technology "function" + tags "Code" + } + default_container__renderers__sanitizedotfiles = component "renderers.sanitizeDotFiles" { + description "Sanitize all DOT files in a directory" technology "function" tags "Code" } @@ -937,8 +1000,13 @@ workspace "Application" "Main application container" { technology "function" tags "Code" } + default_container__basic_wrangler__findmatchingcontainer = component "basic_wrangler.findMatchingContainer" { + description "Smart lookup to find matching container for a service name Tries exact match first, then fuzzy matching with common environment suffix removal." + technology "function" + tags "Code" + } default_container__basic_wrangler__extractcontainerrelationships = component "basic_wrangler.extractContainerRelationships" { - description "Extract container relationships from service bindings Creates logical dependencies between containers based on service bindings. Deduplicates relationships across all environments." + description "Extract container relationships from service bindings Creates logical dependencies between containers based on service bindings. Uses smart lookup to match service names to actual containers. Deduplicates relationships across all environments." technology "function" tags "Code" } @@ -991,7 +1059,7 @@ workspace "Application" "Main application container" { default_container__extractors -> default_container__basic_wrangler "composed of cloudflare wrangler extractor" default_container__validators -> default_container__core "Provides IR types, validation schemas, and module loading | zArchletteIR | ArchletteValidator" default_container__generators -> default_container__core "Provides IR types, path resolution, and module loading | ArchletteIR | Container | Component | CodeItem | Relationship | ResolvedStageNode | VIEW_NAMES | resolveUserContentPath" - default_container__renderers -> default_container__core "Provides types, module loading, and tool management | PipelineContext | findPlantUML | requireJava | resolveArchlettePath | findStructurizrCLI" + default_container__renderers -> default_container__core "Provides types, module loading, and tool management | PipelineContext | ResolvedStageNode | findMermaidCLI | resolveArchlettePath | findPlantUML | requireJava | findStructurizrCLI | commandExistsInPath" default_container__docs -> default_container__core "Provides types, module loading, and path resolution | PipelineContext | Logger | RendererOutput | Component | resolveArchlettePath" default_container__basic_astro -> default_container__core "ResolvedStageNode | ArchletteIR | PipelineContext | IR_VERSION | resolveSecurePath | createLogger | sanitizeId | CodeItem | System | Relationship | Component | Actor | Container | TAGS | DEFAULT_CONTAINER_ID | nameToId" default_container__basic_node -> default_container__core "ResolvedStageNode | ArchletteIR | PipelineContext | resolveSecurePath | createLogger | sanitizeId | CodeItem | System | Relationship | Component | Actor | TAGS | DEFAULT_CONTAINER_ID | IR_VERSION | nameToId" @@ -1011,188 +1079,6 @@ workspace "Application" "Main application container" { } views { -/** - * Default Structurizr theme for Archlette - * - * This theme provides a modern, professional color scheme for architecture diagrams - * with clear visual hierarchy and accessibility considerations. - */ - -theme default - -// Element styles -styles { - // Person/Actor styles - element "Person" { - background #08427b - color #ffffff - shape Person - fontSize 22 - } - - // External System styles - element "External System" { - background #999999 - color #ffffff - shape RoundedBox - fontSize 22 - } - - element "External" { - background #999999 - color #ffffff - shape RoundedBox - fontSize 22 - } - - // System styles - element "Software System" { - background #1168bd - color #ffffff - shape RoundedBox - fontSize 24 - } - - // Container styles - element "Container" { - background #438dd5 - color #ffffff - shape RoundedBox - fontSize 20 - } - - element "Database" { - background #438dd5 - color #ffffff - shape Cylinder - fontSize 20 - } - - element "Web Browser" { - background #438dd5 - color #ffffff - shape WebBrowser - fontSize 20 - } - - element "Mobile App" { - background #438dd5 - color #ffffff - shape MobileDevicePortrait - fontSize 20 - } - - // Component styles - element "Component" { - background #85bbf0 - color #000000 - shape RoundedBox - fontSize 18 - } - - // Technology-specific styles - element "Cloudflare Worker" { - background #f6821f - color #ffffff - shape RoundedBox - fontSize 18 - } - - element "Service" { - background #438dd5 - color #ffffff - shape RoundedBox - fontSize 18 - } - - element "API" { - background #85bbf0 - color #000000 - shape Hexagon - fontSize 18 - } - - element "Queue" { - background #85bbf0 - color #000000 - shape Pipe - fontSize 18 - } - - // Tag-based styles - element "Internal System" { - background #1168bd - color #ffffff - } - - element "Deprecated" { - background #cc0000 - color #ffffff - opacity 60 - } - - element "Future" { - background #dddddd - color #000000 - opacity 50 - stroke #999999 - strokeWidth 2 - } - - element "Auto Generated" { - stroke #999999 - strokeWidth 1 - } - - // Infrastructure styles - element "Infrastructure" { - background #92278f - color #ffffff - shape RoundedBox - } - - element "Message Bus" { - background #85bbf0 - color #000000 - shape Pipe - } - - // Relationship styles - relationship "Relationship" { - color #707070 - dashed false - routing Curved - fontSize 12 - thickness 2 - } - - relationship "Async" { - dashed true - color #707070 - } - - relationship "Sync" { - dashed false - color #707070 - } - - relationship "Uses" { - color #707070 - dashed false - } - - relationship "Depends On" { - color #707070 - dashed true - } -} - -// Diagram customization -branding { - font "Arial" -} - - systemContext Application "SystemContext" { include user include filesystem @@ -1201,7 +1087,7 @@ branding { include local_system_s_unzip_utility include file_system include Application - autoLayout + autoLayout lr 100 100 } container Application "Containers" { @@ -1212,7 +1098,7 @@ branding { include local_system_s_unzip_utility include file_system include default_container - autoLayout + autoLayout lr 100 100 } @@ -1236,7 +1122,7 @@ branding { include default_container__basic_wrangler include default_container__shared exclude "element.tag==Code" - autoLayout + autoLayout lr 100 100 } @@ -1245,7 +1131,7 @@ branding { include default_container__cli__parseargs include default_container__cli__stagelistfromarg include default_container__cli__run - autoLayout + autoLayout lr 100 100 } @@ -1255,14 +1141,14 @@ branding { include default_container__extractors__deduplicatebyname include default_container__extractors__deduplicaterelationships include default_container__extractors__run - autoLayout + autoLayout lr 100 100 } component default_container "Classes_default_container__validators" { include default_container__validators__run include default_container__validators__basevalidator - autoLayout + autoLayout lr 100 100 } @@ -1278,15 +1164,25 @@ branding { include default_container__generators__buildtechnologystring include default_container__generators__sanitizeid include default_container__generators__escapestring - autoLayout + autoLayout lr 100 100 } component default_container "Classes_default_container__renderers" { include default_container__renderers__run + include default_container__renderers__mermaidrender include default_container__renderers__plantumlrender include default_container__renderers__structurizrexport - autoLayout + include default_container__renderers__findgraphviz + include default_container__renderers__structurizrrender + include default_container__renderers__extractstylesblock + include default_container__renderers__removeblock + include default_container__renderers__removestylesblock + include default_container__renderers__removebrandingblock + include default_container__renderers__escapeinvalidhtmltags + include default_container__renderers__sanitizedotcontent + include default_container__renderers__sanitizedotfiles + autoLayout lr 100 100 } @@ -1297,7 +1193,7 @@ branding { include default_container__docs__finddiagramsforcontainer include default_container__docs__findclassdiagramsforcomponent include default_container__docs__sanitizefilename - autoLayout + autoLayout lr 100 100 } @@ -1340,11 +1236,14 @@ branding { include default_container__core__downloadstructurizr include default_container__core__downloadplantuml include default_container__core__findstructurizrcli + include default_container__core__downloadstructurizrlite + include default_container__core__findstructurizrlite include default_container__core__findplantuml include default_container__core__checkjava include default_container__core__requirejava + include default_container__core__findmermaidcli include default_container__core__resolveconfig - autoLayout + autoLayout lr 100 100 } @@ -1374,7 +1273,7 @@ branding { include default_container__basic_astro__maptoir include default_container__basic_astro__mapclasstocodeitems include default_container__basic_astro__mapfunctiontocodeitem - autoLayout + autoLayout lr 100 100 } @@ -1423,7 +1322,7 @@ branding { include default_container__basic_node__getdefaultsystem include default_container__basic_node__extracttypealiases include default_container__basic_node__extractinterfaces - autoLayout + autoLayout lr 100 100 } @@ -1456,7 +1355,7 @@ branding { include default_container__basic_python__mapmethodtocodeitem include default_container__basic_python__mapfunctiontocodeitem include default_container__basic_python__maptypetocodeitem - autoLayout + autoLayout lr 100 100 } @@ -1467,6 +1366,7 @@ branding { include default_container__basic_wrangler__extractcontainers include default_container__basic_wrangler__derivecontainertype include default_container__basic_wrangler__extractdeploymentsandinstances + include default_container__basic_wrangler__findmatchingcontainer include default_container__basic_wrangler__extractcontainerrelationships include default_container__basic_wrangler__extractdeploymentrelationships include default_container__basic_wrangler__extractdescription @@ -1474,15 +1374,239 @@ branding { include default_container__basic_wrangler__normalizeservicebindings include default_container__basic_wrangler__getenvironments include default_container__basic_wrangler__getenvironmentconfig - autoLayout + autoLayout lr 100 100 } component default_container "Classes_default_container__shared" { include default_container__shared__deduplicaterelationships - autoLayout + autoLayout lr 100 100 } + +/** + * Default Structurizr theme for Archlette + * + * This theme provides a modern, professional color scheme for architecture diagrams + * with clear visual hierarchy and accessibility considerations. + */ + +theme default + +// Element styles +styles { + // Person/Actor styles + element "Person" { + background #08427b + color #ffffff + shape Person + width 200 + height 120 + fontSize 14 + } + + // External System styles + element "External System" { + background #999999 + color #ffffff + shape RoundedBox + width 240 + height 140 + fontSize 14 + } + + element "External" { + background #999999 + color #ffffff + shape RoundedBox + width 240 + height 140 + fontSize 14 + } + + // System styles + element "Software System" { + background #1168bd + color #ffffff + shape RoundedBox + width 280 + height 160 + fontSize 16 + } + + // Container styles + element "Container" { + background #438dd5 + color #ffffff + shape RoundedBox + width 260 + height 150 + fontSize 14 + } + + element "Database" { + background #438dd5 + color #ffffff + shape Cylinder + width 200 + height 140 + fontSize 14 + } + + element "Web Browser" { + background #438dd5 + color #ffffff + shape WebBrowser + width 240 + height 150 + fontSize 14 + } + + element "Mobile App" { + background #438dd5 + color #ffffff + shape MobileDevicePortrait + width 180 + height 200 + fontSize 14 + } + + // Component styles + element "Component" { + background #85bbf0 + color #000000 + shape RoundedBox + width 220 + height 130 + fontSize 12 + } + + // Code element styles (classes, functions, etc.) + element "Code" { + background #d4e8fc + color #000000 + shape RoundedBox + width 200 + height 100 + fontSize 11 + } + + // Technology-specific styles + element "Cloudflare Worker" { + background #f6821f + color #ffffff + shape RoundedBox + width 220 + height 130 + fontSize 12 + } + + element "Service" { + background #438dd5 + color #ffffff + shape RoundedBox + width 220 + height 130 + fontSize 12 + } + + element "API" { + background #85bbf0 + color #000000 + shape Hexagon + width 180 + height 120 + fontSize 12 + } + + element "Queue" { + background #85bbf0 + color #000000 + shape Pipe + width 200 + height 100 + fontSize 12 + } + + // Tag-based styles + element "Internal System" { + background #1168bd + color #ffffff + } + + element "Deprecated" { + background #cc0000 + color #ffffff + opacity 60 + } + + element "Future" { + background #dddddd + color #000000 + opacity 50 + stroke #999999 + strokeWidth 2 + } + + element "Auto Generated" { + stroke #999999 + strokeWidth 1 + } + + // Infrastructure styles + element "Infrastructure" { + background #92278f + color #ffffff + shape RoundedBox + width 220 + height 130 + fontSize 12 + } + + element "Message Bus" { + background #85bbf0 + color #000000 + shape Pipe + width 200 + height 100 + fontSize 12 + } + + // Relationship styles + relationship "Relationship" { + color #707070 + dashed false + routing Curved + fontSize 12 + thickness 2 + } + + relationship "Async" { + dashed true + color #707070 + } + + relationship "Sync" { + dashed false + color #707070 + } + + relationship "Uses" { + color #707070 + dashed false + } + + relationship "Depends On" { + color #707070 + dashed true + } +} + +// Diagram customization +branding { + font "Arial" +} + } } diff --git a/docs/architecture/default-container.md b/docs/architecture/default-container.md index bd53a7a..48684b0 100644 --- a/docs/architecture/default-container.md +++ b/docs/architecture/default-container.md @@ -6,33 +6,17 @@ ## Container Context -![Container Diagram](./diagrams/structurizr-Containers.png) +Container Diagram --- ## Container Information - - - - - - - - - - - - - - - - - - - -
NameApplication
TypeApplication
DescriptionMain application container
TagsAuto-generated
- +| Field | Value | +| --- | --- | +| **Name** | Application | +| **Type** | `Application` | +| **Description** | Main application container || **Tags** | `Auto-generated` | --- ## Components @@ -40,95 +24,24 @@ ### Component View -![Component Diagram](./diagrams/structurizr-Components_Application.png) +Component Diagram ### Component Details - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
ComponentTypeDescriptionCode
CLImoduleArchlette CLI - Architecture-as-Code toolkitView →
extractorsmoduleArchletteIR aggregation utilities | Extraction stage of the AAC pipelineView →
validatorsmoduleValidation stage of the AAC pipeline | Base IR validator for Archlette pipelineView →
generatorsmoduleGeneration stage of the AAC pipeline | Structurizr DSL Generator (Template-based)View →
renderersmoduleRender stage of the AAC pipeline | PlantUML image renderer | Structurizr DSL export rendererView →
docsmoduleDocumentation stage of the AAC pipeline | Markdown documentation generatorView →
coremoduleDynamic ESM module loader | Component inferred from directory: core | Stage module interfaces for the AAC pipeline | Stage module loaders | Tool management for external rendering tools | Architecture-as-Code (AAC) configuration types and schemas | Archlette Intermediate Representation (IR) types and schemas | Core pipeline typesView →
basic-astromoduleAstro component extractorView →
basic_nodemoduleTypeScript/JavaScript code extractorView →
basic-pythonmoduleBasic Python Extractor for Archlette -Extracts architecture information from Python source codeView →
basic_wranglermoduleCloudflare Wrangler deployment extractorView →
sharedmoduleView →
+| Component | Type | Description | Code | +| --- | --- | --- | --- | +| **CLI** | `module` | Archlette CLI - Architecture-as-Code toolkit | [View](./default_container__cli.md) | +| **extractors** | `module` | ArchletteIR aggregation utilities \| Extraction stage of the AAC pipeline | [View](./default_container__extractors.md) | +| **validators** | `module` | Validation stage of the AAC pipeline \| Base IR validator for Archlette pipeline | [View](./default_container__validators.md) | +| **generators** | `module` | Generation stage of the AAC pipeline \| Structurizr DSL Generator (Template-based) | [View](./default_container__generators.md) | +| **renderers** | `module` | Render stage of the AAC pipeline \| Mermaid image renderer \| PlantUML image renderer \| Structurizr DSL export renderer \| Structurizr direct image renderer | [View](./default_container__renderers.md) | +| **docs** | `module` | Documentation stage of the AAC pipeline \| Markdown documentation generator | [View](./default_container__docs.md) | +| **core** | `module` | Dynamic ESM module loader \| Component inferred from directory: core \| Stage module interfaces for the AAC pipeline \| Stage module loaders \| Tool management for external rendering tools \| Architecture-as-Code (AAC) configuration types and schemas \| Archlette Intermediate Representation (IR) types and schemas \| Core pipeline types | [View](./default_container__core.md) | +| **basic-astro** | `module` | Astro component extractor | [View](./default_container__basic_astro.md) | +| **basic_node** | `module` | TypeScript/JavaScript code extractor | [View](./default_container__basic_node.md) | +| **basic-python** | `module` | Basic Python Extractor for Archlette
Extracts architecture information from Python source code | [View](./default_container__basic_python.md) | +| **basic_wrangler** | `module` | Cloudflare Wrangler deployment extractor | [View](./default_container__basic_wrangler.md) | +| **shared** | `module` | - | [View](./default_container__shared.md) | --- @@ -136,3 +49,4 @@ Extracts architecture information from Python source code + diff --git a/docs/architecture/default_container__basic_astro.md b/docs/architecture/default_container__basic_astro.md index d4497ff..bf20e86 100644 --- a/docs/architecture/default_container__basic_astro.md +++ b/docs/architecture/default_container__basic_astro.md @@ -6,27 +6,12 @@ ## Component Information - - - - - - - - - - - - - - - - - - - -
Componentbasic-astro
ContainerApplication
Typemodule
DescriptionAstro component extractor
- +| Field | Value | +| --- | --- | +| **Component** | basic-astro | +| **Container** | Application | +| **Type** | `module` | +| **Description** | Astro component extractor | --- ## Code Structure @@ -48,30 +33,11 @@ Extract architecture information from an Astro codebase - - - - - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
AsyncYes
ReturnsPromise> — Promise resolving to ArchletteIR with components, code, and relationships
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-astro.ts:71
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Async** | Yes || **Returns** | `Promise>` - Promise resolving to ArchletteIR with components, code, and relationships || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-astro.ts:71` | **Parameters:** @@ -96,26 +62,11 @@ and extracts code elements using the basic-node AST extractors: Returns empty result if frontmatter is empty or parsing fails (errors are logged). Graceful error handling ensures one malformed Astro file doesn't break the extraction pipeline. - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsimport("C:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/code-extractor").CodeExtractionResult — CodeExtractionResult with extracted classes, functions, types, and interfaces
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/code-extractor.ts:61
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/code-extractor").CodeExtractionResult` - CodeExtractionResult with extracted classes, functions, types, and interfaces || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/code-extractor.ts:61` | **Parameters:** @@ -144,26 +95,11 @@ The function is named after the file (without .astro extension): - index.astro → function index() - settings/Profile.astro → function Profile() - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsimport("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/types").ExtractedFunction — Synthetic ExtractedFunction representing the component's render behavior
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/code-extractor.ts:153
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/types").ExtractedFunction` - Synthetic ExtractedFunction representing the component's render behavior || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/code-extractor.ts:153` | **Parameters:** @@ -179,26 +115,11 @@ The function is named after the file (without .astro extension): Extract all JSDoc comment blocks from source code Matches /** ... *\/ style comments and parses their tags - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
ReturnsJSDocBlock[]
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/component-detector.ts:27
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `JSDocBlock[]` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/component-detector.ts:27` | **Parameters:** @@ -209,26 +130,11 @@ Matches /** ... *\/ style comments and parses their tags Parse a single JSDoc comment block into description and tags - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
ReturnsJSDocBlock
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/component-detector.ts:49
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `JSDocBlock` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/component-detector.ts:49` | **Parameters:** @@ -242,26 +148,11 @@ Extract component information from frontmatter JSDoc Attempts to identify the component in this file using JSDoc tags: 1. Checks for - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsimport("C:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/types").ComponentInfo — ComponentInfo with id, name, and optional description, or undefined
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/component-detector.ts:118
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/types").ComponentInfo` - ComponentInfo with id, name, and optional description, or undefined || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/component-detector.ts:118` | **Parameters:** @@ -285,26 +176,11 @@ Parses the tag value to extract the component name, handling various formats: For module paths like "utils/helpers", extracts "utils" (the last directory before the filename) to enable component grouping. - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsstring — Extracted component name, or undefined if value is empty
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/component-detector.ts:191
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `string` - Extracted component name, or undefined if value is empty || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/component-detector.ts:191` | **Parameters:** @@ -322,26 +198,11 @@ Extract actors from frontmatter JSDoc Identifies external actors (users, systems) that interact with the component. Actors are specified using - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsimport("C:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/types").ActorInfo[] — Array of identified actors, or empty array if none found
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/component-detector.ts:250
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/types").ActorInfo[]` - Array of identified actors, or empty array if none found || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/component-detector.ts:250` | **Parameters:** @@ -356,26 +217,11 @@ Actors are specified using Parse an - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsimport("C:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/types").ActorInfo
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/component-detector.ts:277
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/types").ActorInfo` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/component-detector.ts:277` | **Parameters:** @@ -388,26 +234,11 @@ Extract relationships from frontmatter JSDoc Identifies component dependencies using - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsimport("C:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/types").RelationshipInfo[] — Array of identified relationships, or empty array if none found
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/component-detector.ts:333
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/types").RelationshipInfo[]` - Array of identified relationships, or empty array if none found || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/component-detector.ts:333` | **Parameters:** @@ -422,26 +253,11 @@ Identifies component dependencies using Parse a - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsimport("C:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/types").RelationshipInfo
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/component-detector.ts:357
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/types").RelationshipInfo` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/component-detector.ts:357` | **Parameters:** @@ -454,26 +270,11 @@ Infer component name from file path When no explicit - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsimport("C:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/types").ComponentInfo — ComponentInfo with inferred component name
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/component-detector.ts:400
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/types").ComponentInfo` - ComponentInfo with inferred component name || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/component-detector.ts:400` | **Parameters:** @@ -493,30 +294,11 @@ Returns absolute paths to enable downstream processing. Default patterns include src directory and exclude node_modules, dist, build, and .astro. - - - - - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
AsyncYes
ReturnsPromise — Promise resolving to array of absolute file paths
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/file-finder.ts:39
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Async** | Yes || **Returns** | `Promise` - Promise resolving to array of absolute file paths || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/file-finder.ts:39` | **Parameters:** @@ -535,30 +317,11 @@ Extracts base directories from include patterns and searches multiple directory to locate all package.json files. Useful for identifying container boundaries and package metadata (name, version, description). - - - - - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
AsyncYes
ReturnsPromise — Promise resolving to array of absolute paths to package.json files
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/file-finder.ts:73
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Async** | Yes || **Returns** | `Promise` - Promise resolving to array of absolute paths to package.json files || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/file-finder.ts:73` | **Parameters:** @@ -576,30 +339,11 @@ Read package.json and extract metadata Parses a package.json file and extracts key metadata fields: name, version, and description. Returns null on read or parse errors (logged as warnings). - - - - - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
AsyncYes
ReturnsPromise — Promise resolving to PackageInfo object or null on error
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/file-finder.ts:134
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Async** | Yes || **Returns** | `Promise` - Promise resolving to PackageInfo object or null on error || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/file-finder.ts:134` | **Parameters:** @@ -618,26 +362,11 @@ Searches through all known packages and finds the one whose directory is the clo parent of the given file. Packages are sorted by depth (deepest first) to prioritize monorepo sub-packages over workspace root packages. - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsimport("C:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/types").PackageInfo — The closest parent package, or null if file is not within any package
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/file-finder.ts:172
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/types").PackageInfo` - The closest parent package, or null if file is not within any package || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/file-finder.ts:172` | **Parameters:** @@ -652,30 +381,11 @@ monorepo sub-packages over workspace root packages. Parse Astro files using - - - - - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
AsyncYes
ReturnsPromise — Promise resolving to FileExtraction array (one per file)
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/file-parser.ts:48
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Async** | Yes || **Returns** | `Promise` - Promise resolving to FileExtraction array (one per file) || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/file-parser.ts:48` | **Parameters:** @@ -697,26 +407,11 @@ Astro files have two sections separated by --- markers: This function extracts only the frontmatter section. Returns empty string if no frontmatter. Handles both Unix and Windows line endings for cross-platform compatibility. - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsstring — Frontmatter code between the --- markers, or empty string
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/file-parser.ts:157
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `string` - Frontmatter code between the --- markers, or empty string || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/file-parser.ts:157` | **Parameters:** @@ -738,26 +433,11 @@ Parses all import declarations using regex and categorizes them: Also handles aliased imports like: import { Foo as F } from 'bar' - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returns{ source: string; importedNames: string[]; isDefault: boolean; isNamespace: boolean; }[] — Array of import declarations with categorization
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/file-parser.ts:183
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `{ source: string; importedNames: string[]; isDefault: boolean; isNamespace: boolean; }[]` - Array of import declarations with categorization || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/file-parser.ts:183` | **Parameters:** @@ -778,26 +458,11 @@ Astro components can define slots to allow content projection: Returns location information (line number) for each slot found. - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returns{ name: string; line: number; }[] — Array of slots with names and line numbers
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/file-parser.ts:255
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `{ name: string; line: number; }[]` - Array of slots with names and line numbers || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/file-parser.ts:255` | **Parameters:** @@ -821,26 +486,11 @@ Astro allows hydration directives to run components on the client: Returns the first directive found. Used to indicate interactive components. - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsstring — The directive found (e.g., 'client:load'), or undefined
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/file-parser.ts:291
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `string` - The directive found (e.g., 'client:load'), or undefined || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/file-parser.ts:291` | **Parameters:** @@ -864,26 +514,11 @@ Only includes components that: Component names in Astro are PascalCase by convention (e.g., Header, Footer). This function uses the import list to avoid false positives from HTML elements. - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsimport("C:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/types").ExtractedComponent[] — Array of ExtractedComponent objects for used components
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/file-parser.ts:317
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/types").ExtractedComponent[]` - Array of ExtractedComponent objects for used components || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/file-parser.ts:317` | **Parameters:** @@ -908,26 +543,11 @@ Algorithm (4 main steps): - Detect and merge duplicates (same component in multiple files) - Build relationship graph from - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsz.infer — ArchletteIR ready for DSL generation
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/to-ir-mapper.ts:73
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `z.infer` - ArchletteIR ready for DSL generation || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/to-ir-mapper.ts:73` | **Parameters:** @@ -942,26 +562,11 @@ Algorithm (4 main steps): Map a class to code items (class + methods) - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsz.infer[]
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/to-ir-mapper.ts:508
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `z.infer[]` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/to-ir-mapper.ts:508` | **Parameters:** @@ -972,26 +577,11 @@ Map a class to code items (class + methods) Map a function to a code item - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsz.infer
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/to-ir-mapper.ts:555
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `z.infer` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-astro/to-ir-mapper.ts:555` | **Parameters:** @@ -1006,3 +596,4 @@ Map a function to a code item + diff --git a/docs/architecture/default_container__basic_node.md b/docs/architecture/default_container__basic_node.md index 044dc65..804c6b5 100644 --- a/docs/architecture/default_container__basic_node.md +++ b/docs/architecture/default_container__basic_node.md @@ -6,27 +6,12 @@ ## Component Information - - - - - - - - - - - - - - - - - - - -
Componentbasic_node
ContainerApplication
Typemodule
DescriptionTypeScript/JavaScript code extractor
- +| Field | Value | +| --- | --- | +| **Component** | basic_node | +| **Container** | Application | +| **Type** | `module` | +| **Description** | TypeScript/JavaScript code extractor | --- ## Code Structure @@ -48,30 +33,11 @@ Extract architecture information from a Node.js/TypeScript codebase - - - - - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
AsyncYes
ReturnsPromise> — Promise resolving to ArchletteIR with code, components, and relationships
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-node.ts:74
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Async** | Yes || **Returns** | `Promise>` - Promise resolving to ArchletteIR with code, components, and relationships || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-node.ts:74` | **Parameters:** @@ -86,26 +52,11 @@ Extract architecture information from a Node.js/TypeScript codebase Extract all class declarations from a source file - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsimport("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/types").ExtractedClass[]
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-node/class-extractor.ts:32
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/types").ExtractedClass[]` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/class-extractor.ts:32` | **Parameters:** @@ -116,26 +67,11 @@ Extract all class declarations from a source file Extract information from a single class declaration - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsimport("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/types").ExtractedClass
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-node/class-extractor.ts:53
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/types").ExtractedClass` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/class-extractor.ts:53` | **Parameters:** @@ -146,26 +82,11 @@ Extract information from a single class declaration Extract method information from a class - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsimport("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/types").ExtractedMethod
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-node/class-extractor.ts:92
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/types").ExtractedMethod` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/class-extractor.ts:92` | **Parameters:** @@ -176,26 +97,11 @@ Extract method information from a class Extract property information from a class - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsimport("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/types").ExtractedProperty
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-node/class-extractor.ts:121
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/types").ExtractedProperty` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/class-extractor.ts:121` | **Parameters:** @@ -206,26 +112,11 @@ Extract property information from a class Extract parameter information - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsimport("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/types").ParameterInfo
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-node/class-extractor.ts:147
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/types").ParameterInfo` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/class-extractor.ts:147` | **Parameters:** @@ -236,26 +127,11 @@ Extract parameter information Map ts-morph Scope to our visibility string - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returns"public" | "private" | "protected"
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-node/class-extractor.ts:168
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `"public" \| "private" \| "protected"` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/class-extractor.ts:168` | **Parameters:** @@ -267,26 +143,11 @@ Map ts-morph Scope to our visibility string Get JSDoc comments from a source file Checks both the first statement and module-level JSDoc - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
ReturnsNode[] — Array of JSDoc nodes (empty if none found)
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-node/component-detector.ts:38
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `Node[]` - Array of JSDoc nodes (empty if none found) || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/component-detector.ts:38` | **Parameters:** @@ -298,26 +159,11 @@ Checks both the first statement and module-level JSDoc Extract component information from file-level JSDoc Checks the first JSDoc comment in the file for - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsimport("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/component-detector").ComponentInfo
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-node/component-detector.ts:64
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/component-detector").ComponentInfo` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/component-detector.ts:64` | **Parameters:** @@ -329,26 +175,11 @@ Checks the first JSDoc comment in the file for Extract actors from file-level JSDoc Looks for - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsimport("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/component-detector").ActorInfo[]
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-node/component-detector.ts:90
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/component-detector").ActorInfo[]` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/component-detector.ts:90` | **Parameters:** @@ -360,26 +191,11 @@ Looks for Extract relationships from file-level JSDoc Looks for - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsimport("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/component-detector").RelationshipInfo[]
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-node/component-detector.ts:109
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/component-detector").RelationshipInfo[]` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/component-detector.ts:109` | **Parameters:** @@ -390,26 +206,11 @@ Looks for Extract component info from a JSDoc node - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsimport("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/component-detector").ComponentInfo
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-node/component-detector.ts:125
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/component-detector").ComponentInfo` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/component-detector.ts:125` | **Parameters:** @@ -421,26 +222,11 @@ Extract component info from a JSDoc node Extract actors from a JSDoc node Parses - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsimport("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/component-detector").ActorInfo[]
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-node/component-detector.ts:157
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/component-detector").ActorInfo[]` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/component-detector.ts:157` | **Parameters:** @@ -451,26 +237,11 @@ Parses Parse an - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsimport("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/component-detector").ActorInfo
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-node/component-detector.ts:188
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/component-detector").ActorInfo` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/component-detector.ts:188` | **Parameters:** @@ -482,26 +253,11 @@ Parse an Extract relationships from a JSDoc node Parses - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsimport("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/component-detector").RelationshipInfo[]
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-node/component-detector.ts:225
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/component-detector").RelationshipInfo[]` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/component-detector.ts:225` | **Parameters:** @@ -512,26 +268,11 @@ Parses Parse a - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsimport("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/component-detector").RelationshipInfo
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-node/component-detector.ts:252
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/component-detector").RelationshipInfo` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/component-detector.ts:252` | **Parameters:** @@ -544,26 +285,11 @@ Extract component name from a JSDoc tag Handles formats like: - - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsstring
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-node/component-detector.ts:285
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `string` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/component-detector.ts:285` | **Parameters:** @@ -581,26 +307,11 @@ Examples: - /path/to/project/src/index.ts -> ROOT_COMPONENT_MARKER - /path/to/project/services/api/client.ts -> 'api' - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsimport("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/component-detector").ComponentInfo
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-node/component-detector.ts:327
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/component-detector").ComponentInfo` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/component-detector.ts:327` | **Parameters:** @@ -611,26 +322,11 @@ Examples: Extract documentation information from JSDoc - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsimport("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/types").DocInfo
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-node/doc-extractor.ts:13
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/types").DocInfo` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/doc-extractor.ts:13` | **Parameters:** @@ -641,26 +337,11 @@ Extract documentation information from JSDoc Extract deprecation information from JSDoc - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsimport("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/types").DeprecationInfo
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-node/doc-extractor.ts:64
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/types").DeprecationInfo` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/doc-extractor.ts:64` | **Parameters:** @@ -671,26 +352,11 @@ Extract deprecation information from JSDoc Extract parameter descriptions from JSDoc - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
ReturnsMap
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-node/doc-extractor.ts:93
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `Map` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/doc-extractor.ts:93` | **Parameters:** @@ -701,26 +367,11 @@ Extract parameter descriptions from JSDoc Extract return description from JSDoc - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsstring
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-node/doc-extractor.ts:116
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `string` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/doc-extractor.ts:116` | **Parameters:** @@ -731,26 +382,11 @@ Extract return description from JSDoc Extract parameter name from - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsstring
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-node/doc-extractor.ts:131
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `string` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/doc-extractor.ts:131` | **Parameters:** @@ -761,30 +397,11 @@ Extract parameter name from Find source files matching include/exclude patterns - - - - - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
AsyncYes
ReturnsPromise
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-node/file-finder.ts:32
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Async** | Yes || **Returns** | `Promise` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/file-finder.ts:32` | **Parameters:** @@ -795,30 +412,11 @@ Find source files matching include/exclude patterns Find package.json files within the search paths - - - - - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
AsyncYes
ReturnsPromise
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-node/file-finder.ts:48
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Async** | Yes || **Returns** | `Promise` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/file-finder.ts:48` | **Parameters:** @@ -829,30 +427,11 @@ Find package.json files within the search paths Read and parse package.json file - - - - - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
AsyncYes
ReturnsPromise
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-node/file-finder.ts:98
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Async** | Yes || **Returns** | `Promise` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/file-finder.ts:98` | **Parameters:** @@ -863,26 +442,11 @@ Read and parse package.json file Find the nearest parent package.json for a given file - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsimport("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/types").PackageInfo
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-node/file-finder.ts:122
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/types").PackageInfo` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/file-finder.ts:122` | **Parameters:** @@ -893,30 +457,11 @@ Find the nearest parent package.json for a given file Parse and extract information from source files - - - - - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
AsyncYes
ReturnsPromise
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-node/file-parser.ts:24
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Async** | Yes || **Returns** | `Promise` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/file-parser.ts:24` | **Parameters:** @@ -927,26 +472,11 @@ Parse and extract information from source files Extract all function declarations from a source file - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsimport("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/types").ExtractedFunction[]
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-node/function-extractor.ts:21
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/types").ExtractedFunction[]` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/function-extractor.ts:21` | **Parameters:** @@ -957,26 +487,11 @@ Extract all function declarations from a source file Extract information from a single function declaration - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsimport("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/types").ExtractedFunction
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-node/function-extractor.ts:44
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/types").ExtractedFunction` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/function-extractor.ts:44` | **Parameters:** @@ -987,26 +502,11 @@ Extract information from a single function declaration Extract parameter information - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsimport("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/types").ParameterInfo
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-node/function-extractor.ts:80
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/types").ParameterInfo` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/function-extractor.ts:80` | **Parameters:** @@ -1020,26 +520,11 @@ Examples: const handleClick = () => {} export const createUser = async (data) => {} - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsimport("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/types").ExtractedFunction[]
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-node/function-extractor.ts:104
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/types").ExtractedFunction[]` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/function-extractor.ts:104` | **Parameters:** @@ -1050,26 +535,11 @@ Examples: Extract all import declarations from a source file - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsimport("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/types").ExtractedImport[]
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-node/import-extractor.ts:15
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/types").ExtractedImport[]` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/import-extractor.ts:15` | **Parameters:** @@ -1080,26 +550,11 @@ Extract all import declarations from a source file Map file extractions to ArchletteIR - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsz.infer
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-node/to-ir-mapper.ts:37
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `z.infer` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/to-ir-mapper.ts:37` | **Parameters:** @@ -1110,26 +565,11 @@ Map file extractions to ArchletteIR Map a function to a CodeItem - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsz.infer
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-node/to-ir-mapper.ts:425
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `z.infer` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/to-ir-mapper.ts:425` | **Parameters:** @@ -1140,26 +580,11 @@ Map a function to a CodeItem Map a class to a CodeItem - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsz.infer
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-node/to-ir-mapper.ts:453
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `z.infer` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/to-ir-mapper.ts:453` | **Parameters:** @@ -1170,26 +595,11 @@ Map a class to a CodeItem Map a class method to a CodeItem - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsz.infer
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-node/to-ir-mapper.ts:482
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `z.infer` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/to-ir-mapper.ts:482` | **Parameters:** @@ -1202,26 +612,11 @@ Resolve an import path to an absolute file path Handles relative imports (./file, ../file) and resolves to actual file paths Returns undefined for node_modules imports or unresolvable paths - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsstring
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-node/to-ir-mapper.ts:518
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `string` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/to-ir-mapper.ts:518` | **Parameters:** @@ -1232,26 +627,11 @@ Returns undefined for node_modules imports or unresolvable paths Map imports to component relationships (component-level dependencies) - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsz.infer[]
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-node/to-ir-mapper.ts:574
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `z.infer[]` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/to-ir-mapper.ts:574` | **Parameters:** @@ -1262,26 +642,11 @@ Map imports to component relationships (component-level dependencies) Map imports to relationships (original code-level format for backward compatibility) - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsz.infer[]
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-node/to-ir-mapper.ts:611
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `z.infer[]` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/to-ir-mapper.ts:611` | **Parameters:** @@ -1293,26 +658,11 @@ Map imports to relationships (original code-level format for backward compatibil Generate a unique ID for a code element Format: filePath:symbolName - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsstring
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-node/to-ir-mapper.ts:634
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `string` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/to-ir-mapper.ts:634` | **Parameters:** @@ -1323,26 +673,11 @@ Format: filePath:symbolName Get default system info from package.json if available - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsz.infer
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-node/to-ir-mapper.ts:644
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `z.infer` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/to-ir-mapper.ts:644` | @@ -1354,26 +689,11 @@ Examples: type UserRole = 'admin' | 'user' | 'guest' export type ApiResponse = { data: T; status: number } - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsimport("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/types").ExtractedType[]
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-node/type-extractor.ts:19
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/types").ExtractedType[]` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/type-extractor.ts:19` | **Parameters:** @@ -1387,26 +707,11 @@ Examples: interface User { id: string; name: string } export interface ApiClient { get(url: string): Promise } - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsimport("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/types").ExtractedInterface[]
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-node/type-extractor.ts:59
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/types").ExtractedInterface[]` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-node/type-extractor.ts:59` | **Parameters:** @@ -1421,3 +726,4 @@ Examples: + diff --git a/docs/architecture/default_container__basic_python.md b/docs/architecture/default_container__basic_python.md index cbd6c8c..7823c04 100644 --- a/docs/architecture/default_container__basic_python.md +++ b/docs/architecture/default_container__basic_python.md @@ -6,28 +6,12 @@ ## Component Information - - - - - - - - - - - - - - - - - - - -
Componentbasic-python
ContainerApplication
Typemodule
DescriptionBasic Python Extractor for Archlette -Extracts architecture information from Python source code
- +| Field | Value | +| --- | --- | +| **Component** | basic-python | +| **Container** | Application | +| **Type** | `module` | +| **Description** | Basic Python Extractor for Archlette
Extracts architecture information from Python source code | --- ## Code Structure @@ -49,26 +33,11 @@ Extracts architecture information from Python source code Create empty IR when no files found - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsz.infer
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-python.ts:150
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `z.infer` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-python.ts:150` | **Parameters:** @@ -80,30 +49,11 @@ Create empty IR when no files found Basic Python extractor Analyzes Python source code and extracts architectural components - - - - - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
AsyncYes
ReturnsPromise>
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-python.ts:26
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Async** | Yes || **Returns** | `Promise>` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-python.ts:26` | **Parameters:** @@ -114,30 +64,11 @@ Analyzes Python source code and extracts architectural components Find source files matching include/exclude patterns - - - - - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
AsyncYes
ReturnsPromise
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-python/file-finder.ts:26
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Async** | Yes || **Returns** | `Promise` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-python/file-finder.ts:26` | **Parameters:** @@ -148,30 +79,11 @@ Find source files matching include/exclude patterns Find pyproject.toml files within the search paths - - - - - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
AsyncYes
ReturnsPromise
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-python/file-finder.ts:42
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Async** | Yes || **Returns** | `Promise` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-python/file-finder.ts:42` | **Parameters:** @@ -182,30 +94,11 @@ Find pyproject.toml files within the search paths Read and parse pyproject.toml file - - - - - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
AsyncYes
ReturnsPromise
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-python/file-finder.ts:91
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Async** | Yes || **Returns** | `Promise` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-python/file-finder.ts:91` | **Parameters:** @@ -217,26 +110,11 @@ Read and parse pyproject.toml file Parse pyproject.toml using smol-toml library Handles full TOML spec including multiline strings, arrays, and nested tables - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
ReturnsPyProjectToml
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-python/file-finder.ts:142
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `PyProjectToml` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-python/file-finder.ts:142` | **Parameters:** @@ -247,26 +125,11 @@ Handles full TOML spec including multiline strings, arrays, and nested tables Find the nearest parent pyproject.toml for a given file - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsimport("C:/Users/chris/git/archlette/src/extractors/builtin/basic-python/file-finder").PyProjectInfo
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-python/file-finder.ts:156
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-python/file-finder").PyProjectInfo` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-python/file-finder.ts:156` | **Parameters:** @@ -277,30 +140,11 @@ Find the nearest parent pyproject.toml for a given file Parse Python files using Python AST parser script - - - - - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
AsyncYes
ReturnsPromise
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-python/file-parser.ts:29
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Async** | Yes || **Returns** | `Promise` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-python/file-parser.ts:29` | **Parameters:** @@ -311,26 +155,11 @@ Parse Python files using Python AST parser script Run Python parser script and return JSON output - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
ReturnsPromise
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-python/file-parser.ts:95
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `Promise` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-python/file-parser.ts:95` | **Parameters:** @@ -341,26 +170,11 @@ Run Python parser script and return JSON output Map Python parser output to FileExtraction format - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsimport("C:/Users/chris/git/archlette/src/extractors/builtin/basic-python/types").FileExtraction
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-python/file-parser.ts:187
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-python/types").FileExtraction` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-python/file-parser.ts:187` | **Parameters:** @@ -371,26 +185,11 @@ Map Python parser output to FileExtraction format Map Python class to ExtractedClass - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsimport("C:/Users/chris/git/archlette/src/extractors/builtin/basic-python/types").ExtractedClass
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-python/file-parser.ts:254
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-python/types").ExtractedClass` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-python/file-parser.ts:254` | **Parameters:** @@ -401,26 +200,11 @@ Map Python class to ExtractedClass Map Python method to ExtractedMethod - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsimport("C:/Users/chris/git/archlette/src/extractors/builtin/basic-python/types").ExtractedMethod
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-python/file-parser.ts:279
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-python/types").ExtractedMethod` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-python/file-parser.ts:279` | **Parameters:** @@ -431,26 +215,11 @@ Map Python method to ExtractedMethod Map Python property to ExtractedProperty - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsimport("C:/Users/chris/git/archlette/src/extractors/builtin/basic-python/types").ExtractedProperty
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-python/file-parser.ts:314
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-python/types").ExtractedProperty` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-python/file-parser.ts:314` | **Parameters:** @@ -461,26 +230,11 @@ Map Python property to ExtractedProperty Map Python function to ExtractedFunction - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsimport("C:/Users/chris/git/archlette/src/extractors/builtin/basic-python/types").ExtractedFunction
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-python/file-parser.ts:344
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-python/types").ExtractedFunction` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-python/file-parser.ts:344` | **Parameters:** @@ -491,26 +245,11 @@ Map Python function to ExtractedFunction Map Python type definition to ExtractedType - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsimport("C:/Users/chris/git/archlette/src/extractors/builtin/basic-python/types").ExtractedType
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-python/file-parser.ts:373
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-python/types").ExtractedType` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-python/file-parser.ts:373` | **Parameters:** @@ -521,26 +260,11 @@ Map Python type definition to ExtractedType Map Python parameter to ParameterInfo - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsimport("C:/Users/chris/git/archlette/src/extractors/builtin/basic-python/types").ParameterInfo
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-python/file-parser.ts:395
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-python/types").ParameterInfo` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-python/file-parser.ts:395` | **Parameters:** @@ -552,26 +276,11 @@ Map Python parameter to ParameterInfo Parse Python docstring into DocInfo Enhanced in Phase 2 to use parsed Google/NumPy/Sphinx docstrings - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsimport("C:/Users/chris/git/archlette/src/extractors/builtin/basic-python/types").DocInfo
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-python/file-parser.ts:412
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-python/types").DocInfo` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-python/file-parser.ts:412` | **Parameters:** @@ -582,26 +291,11 @@ Enhanced in Phase 2 to use parsed Google/NumPy/Sphinx docstrings Extract deprecation info from docstring - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returns{ reason?: string; alternative?: string; }
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-python/file-parser.ts:448
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `{ reason?: string; alternative?: string; }` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-python/file-parser.ts:448` | **Parameters:** @@ -612,26 +306,11 @@ Extract deprecation info from docstring Extract return description from docstring - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsstring
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-python/file-parser.ts:464
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `string` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-python/file-parser.ts:464` | **Parameters:** @@ -645,26 +324,11 @@ Determine visibility from Python name convention - _name: protected - name: public - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returns"public" | "private" | "protected"
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-python/file-parser.ts:477
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `"public" \| "private" \| "protected"` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-python/file-parser.ts:477` | **Parameters:** @@ -675,26 +339,11 @@ Determine visibility from Python name convention Map file extractions to ArchletteIR - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsz.infer
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-python/to-ir-mapper.ts:45
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `z.infer` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-python/to-ir-mapper.ts:45` | **Parameters:** @@ -705,26 +354,11 @@ Map file extractions to ArchletteIR Map ActorInfo to Actor - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsz.infer
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-python/to-ir-mapper.ts:332
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `z.infer` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-python/to-ir-mapper.ts:332` | **Parameters:** @@ -736,26 +370,11 @@ Map ActorInfo to Actor Map relationships to Relationship[] Creates bidirectional actor relationships - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsz.infer[]
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-python/to-ir-mapper.ts:346
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `z.infer[]` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-python/to-ir-mapper.ts:346` | **Parameters:** @@ -767,26 +386,11 @@ Creates bidirectional actor relationships Map Python imports to component relationships (component-level dependencies) Resolves local imports to component IDs when possible - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsz.infer[]
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-python/to-ir-mapper.ts:394
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `z.infer[]` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-python/to-ir-mapper.ts:394` | **Parameters:** @@ -797,26 +401,11 @@ Resolves local imports to component IDs when possible Map ExtractedClass to CodeItem - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsz.infer
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-python/to-ir-mapper.ts:498
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `z.infer` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-python/to-ir-mapper.ts:498` | **Parameters:** @@ -827,26 +416,11 @@ Map ExtractedClass to CodeItem Map ExtractedMethod to CodeItem - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsz.infer
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-python/to-ir-mapper.ts:523
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `z.infer` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-python/to-ir-mapper.ts:523` | **Parameters:** @@ -857,26 +431,11 @@ Map ExtractedMethod to CodeItem Map ExtractedFunction to CodeItem - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsz.infer
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-python/to-ir-mapper.ts:558
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `z.infer` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-python/to-ir-mapper.ts:558` | **Parameters:** @@ -887,26 +446,11 @@ Map ExtractedFunction to CodeItem Map ExtractedType to CodeItem - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsz.infer
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-python/to-ir-mapper.ts:589
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `z.infer` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-python/to-ir-mapper.ts:589` | **Parameters:** @@ -921,3 +465,4 @@ Map ExtractedType to CodeItem + diff --git a/docs/architecture/default_container__basic_wrangler.md b/docs/architecture/default_container__basic_wrangler.md index 1161ea2..869f035 100644 --- a/docs/architecture/default_container__basic_wrangler.md +++ b/docs/architecture/default_container__basic_wrangler.md @@ -6,27 +6,12 @@ ## Component Information - - - - - - - - - - - - - - - - - - - -
Componentbasic_wrangler
ContainerApplication
Typemodule
DescriptionCloudflare Wrangler deployment extractor
- +| Field | Value | +| --- | --- | +| **Component** | basic_wrangler | +| **Container** | Application | +| **Type** | `module` | +| **Description** | Cloudflare Wrangler deployment extractor | --- ## Code Structure @@ -38,7 +23,7 @@ ### Code Elements
-13 code element(s) +14 code element(s) @@ -48,30 +33,11 @@ Extract deployment topology from Cloudflare Wrangler configuration files - - - - - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
AsyncYes
ReturnsPromise> — Promise resolving to ArchletteIR with containers, deployments, and relationships
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler.ts:68
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Async** | Yes || **Returns** | `Promise>` - Promise resolving to ArchletteIR with containers, deployments, and relationships || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler.ts:68` | **Parameters:** @@ -86,30 +52,11 @@ Extract deployment topology from Cloudflare Wrangler configuration files Find wrangler.toml files based on include/exclude patterns - - - - - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
AsyncYes
ReturnsPromise — Array of absolute file paths to wrangler.toml files
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/file-finder.ts:15
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Async** | Yes || **Returns** | `Promise` - Array of absolute file paths to wrangler.toml files || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/file-finder.ts:15` | **Parameters:** @@ -127,26 +74,11 @@ This creates: - Container Relationships: Logical dependencies from service bindings - Deployment Relationships: Physical instance-to-instance connections - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsz.infer — Complete ArchletteIR
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/to-ir-mapper.ts:30
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `z.infer` - Complete ArchletteIR || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/to-ir-mapper.ts:30` | **Parameters:** @@ -160,26 +92,11 @@ Extract containers from wrangler configurations Creates one container per wrangler.toml file. Each container represents a Cloudflare Worker (if main exists) or other Cloudflare service. - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returns{ id: string; name: string; type: string; layer: string; description: string; tags: string[]; props: { technology: string; filePath: string; }; }[] — Array of Container objects
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/to-ir-mapper.ts:77
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `{ id: string; name: string; type: string; layer: string; description: string; tags: string[]; props: { technology: string; filePath: string; }; }[]` - Array of Container objects || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/to-ir-mapper.ts:78` | **Parameters:** @@ -194,26 +111,11 @@ Logic: - If 'main' field exists → Cloudflare Worker - Otherwise → Cloudflare Service (generic) - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsstring — Container type string
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/to-ir-mapper.ts:110
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `string` - Container type string || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/to-ir-mapper.ts:111` | **Parameters:** @@ -228,63 +130,51 @@ Creates: - One deployment per environment - Container instances for each container in each environment - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returns{ deployments: { name: string; environment: string; platform: string; instances: z.infer[]; }[]; instances: z.infer[]; } — Deployments and container instances
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/to-ir-mapper.ts:131
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `{ deployments: { name: string; environment: string; platform: string; instances: z.infer[]; }[]; instances: z.infer[]; }` - Deployments and container instances || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/to-ir-mapper.ts:132` | **Parameters:** - `configs`: import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/types").WranglerConfig[] — - Parsed wrangler configurations- `environments`: string[] — - Unique environment names +--- +##### `findMatchingContainer()` + +Smart lookup to find matching container for a service name + +Tries exact match first, then fuzzy matching with common environment suffix removal. + +| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `string` - Matching container ID or null || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/to-ir-mapper.ts:276` | + +**Parameters:** + +- `serviceName`: string — - Service name from binding (e.g., "content-service-preview")- `containers`: { id: string; name: string; }[] — - Available containers + --- ##### `extractContainerRelationships()` Extract container relationships from service bindings Creates logical dependencies between containers based on service bindings. +Uses smart lookup to match service names to actual containers. Deduplicates relationships across all environments. - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsz.infer[] — Array of container relationships
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/to-ir-mapper.ts:275
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `z.infer[]` - Array of container relationships || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/to-ir-mapper.ts:325` | **Parameters:** -- `configs`: import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/types").WranglerConfig[] — - Parsed wrangler configurations +- `configs`: import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/types").WranglerConfig[] — - Parsed wrangler configurations- `containers`: { id: string; name: string; }[] — - Available containers for matching --- ##### `extractDeploymentRelationships()` @@ -294,26 +184,11 @@ Extract deployment relationships from container instances Creates physical instance-to-instance relationships based on service bindings. Each relationship represents an actual runtime dependency in a specific environment. - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsz.infer[] — Array of deployment relationships
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/to-ir-mapper.ts:321
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `z.infer[]` - Array of deployment relationships || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/to-ir-mapper.ts:381` | **Parameters:** @@ -324,26 +199,11 @@ Each relationship represents an actual runtime dependency in a specific environm Extract description from - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsstring — Description string if found, undefined otherwise
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/wrangler-parser.ts:27
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `string` - Description string if found, undefined otherwise || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/wrangler-parser.ts:28` | **Parameters:** @@ -354,30 +214,11 @@ Extract description from Parse a wrangler.toml file - - - - - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
AsyncYes
ReturnsPromise — Parsed wrangler configuration
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/wrangler-parser.ts:48
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Async** | Yes || **Returns** | `Promise` - Parsed wrangler configuration || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/wrangler-parser.ts:49` | **Parameters:** @@ -392,26 +233,11 @@ Wrangler supports multiple binding formats: - [[services]] array (TOML array of tables) - services = [{ binding = "...", service = "..." }] - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsimport("C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/types").ServiceBinding[]
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/wrangler-parser.ts:108
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/types").ServiceBinding[]` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/wrangler-parser.ts:109` | **Parameters:** @@ -426,26 +252,11 @@ Returns a list of environment names, including: - "production" (from root-level config if it has deployable content) - All keys from env.* sections - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsstring[]
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/wrangler-parser.ts:129
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `string[]` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/wrangler-parser.ts:130` | **Parameters:** @@ -459,26 +270,11 @@ Get configuration for a specific environment Merges root-level config with environment-specific overrides. Environment config takes precedence. - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returns{ name: string; vars?: Record; services?: import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/types").ServiceBinding[]; kv_namespaces?: import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/types").KVBinding[]; r2_buckets?: import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/types").R2Binding[]; d1_databases?: import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/types").D1Binding[]; durable_objects?: { bindings: import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/types").DurableObjectBinding[]; }; queues?: { producers?: import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/types").QueueBinding[]; consumers?: import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/types").QueueBinding[]; }; routes?: string[]; triggers?: { crons?: string[]; }; observability?: Record; } — Merged environment configuration
LocationC:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/wrangler-parser.ts:170
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `{ name: string; vars?: Record; services?: import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/types").ServiceBinding[]; kv_namespaces?: import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/types").KVBinding[]; r2_buckets?: import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/types").R2Binding[]; d1_databases?: import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/types").D1Binding[]; durable_objects?: { bindings: import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/types").DurableObjectBinding[]; }; queues?: { producers?: import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/types").QueueBinding[]; consumers?: import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/types").QueueBinding[]; }; routes?: import("C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/types").Route[]; triggers?: { crons?: string[]; }; observability?: Record; }` - Merged environment configuration || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/basic-wrangler/wrangler-parser.ts:171` | **Parameters:** @@ -493,3 +289,4 @@ Environment config takes precedence. + diff --git a/docs/architecture/default_container__cli.md b/docs/architecture/default_container__cli.md index a1fdc90..7f4960f 100644 --- a/docs/architecture/default_container__cli.md +++ b/docs/architecture/default_container__cli.md @@ -6,27 +6,12 @@ ## Component Information - - - - - - - - - - - - - - - - - - - -
ComponentCLI
ContainerApplication
Typemodule
DescriptionArchlette CLI - Architecture-as-Code toolkit
- +| Field | Value | +| --- | --- | +| **Component** | CLI | +| **Container** | Application | +| **Type** | `module` | +| **Description** | Archlette CLI - Architecture-as-Code toolkit | --- ## Code Structure @@ -47,26 +32,11 @@ ##### `usageAndExit()` - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsvoid
LocationC:/Users/chris/git/archlette/src/cli.ts:62
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `void` || **Location** | `C:/Users/chris/git/archlette/src/cli.ts:62` | **Parameters:** @@ -76,26 +46,11 @@ ##### `parseArgs()` - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returns{ stageArg: string; yamlPathArg: string; }
LocationC:/Users/chris/git/archlette/src/cli.ts:86
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `{ stageArg: string; yamlPathArg: string; }` || **Location** | `C:/Users/chris/git/archlette/src/cli.ts:86` | **Parameters:** @@ -105,26 +60,11 @@ ##### `stageListFromArg()` - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsstring[]
LocationC:/Users/chris/git/archlette/src/cli.ts:121
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `string[]` || **Location** | `C:/Users/chris/git/archlette/src/cli.ts:121` | **Parameters:** @@ -134,30 +74,11 @@ ##### `run()` - - - - - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
AsyncYes
ReturnsPromise
LocationC:/Users/chris/git/archlette/src/cli.ts:127
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Async** | Yes || **Returns** | `Promise` || **Location** | `C:/Users/chris/git/archlette/src/cli.ts:127` | **Parameters:** @@ -172,3 +93,4 @@ + diff --git a/docs/architecture/default_container__core.md b/docs/architecture/default_container__core.md index 5943e0c..869f3c8 100644 --- a/docs/architecture/default_container__core.md +++ b/docs/architecture/default_container__core.md @@ -6,27 +6,12 @@ ## Component Information - - - - - - - - - - - - - - - - - - - -
Componentcore
ContainerApplication
Typemodule
DescriptionDynamic ESM module loader | Component inferred from directory: core | Stage module interfaces for the AAC pipeline | Stage module loaders | Tool management for external rendering tools | Architecture-as-Code (AAC) configuration types and schemas | Archlette Intermediate Representation (IR) types and schemas | Core pipeline types
- +| Field | Value | +| --- | --- | +| **Component** | core | +| **Container** | Application | +| **Type** | `module` | +| **Description** | Dynamic ESM module loader \| Component inferred from directory: core \| Stage module interfaces for the AAC pipeline \| Stage module loaders \| Tool management for external rendering tools \| Architecture-as-Code (AAC) configuration types and schemas \| Archlette Intermediate Representation (IR) types and schemas \| Core pipeline types | --- ## Code Structure @@ -38,7 +23,7 @@ ### Code Elements
-42 code element(s) +45 code element(s) @@ -48,26 +33,11 @@ Resolve config file path from CLI arguments - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsimport("C:/Users/chris/git/archlette/src/core/config-resolver").ResolvedConfigFile — Resolved config file information
LocationC:/Users/chris/git/archlette/src/core/config-resolver.ts:70
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/core/config-resolver").ResolvedConfigFile` - Resolved config file information || **Location** | `C:/Users/chris/git/archlette/src/core/config-resolver.ts:70` | **Parameters:** @@ -87,26 +57,11 @@ Logic: - If user provided config file: config file's directory - Fallback: CWD - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsstring — Base directory for config-relative path resolution
LocationC:/Users/chris/git/archlette/src/core/config-resolver.ts:117
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `string` - Base directory for config-relative path resolution || **Location** | `C:/Users/chris/git/archlette/src/core/config-resolver.ts:117` | **Parameters:** @@ -121,26 +76,11 @@ Logic: Load and parse YAML config file - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsunknown — Parsed config object or null if file doesn't exist/is invalid
LocationC:/Users/chris/git/archlette/src/core/config-resolver.ts:141
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `unknown` - Parsed config object or null if file doesn't exist/is invalid || **Location** | `C:/Users/chris/git/archlette/src/core/config-resolver.ts:141` | **Parameters:** @@ -151,26 +91,11 @@ Load and parse YAML config file Create minimal default configuration when no config file is found - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsimport("C:/Users/chris/git/archlette/src/core/types-aac").ResolvedAACConfig — Default configuration
LocationC:/Users/chris/git/archlette/src/core/config-resolver.ts:164
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/core/types-aac").ResolvedAACConfig` - Default configuration || **Location** | `C:/Users/chris/git/archlette/src/core/config-resolver.ts:164` | **Parameters:** @@ -188,26 +113,11 @@ This is the main entry point for config loading. It handles: 4. Config validation and resolution 5. Fallback to default config - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsimport("C:/Users/chris/git/archlette/src/core/config-resolver").LoadedConfig — Loaded configuration with all metadata
LocationC:/Users/chris/git/archlette/src/core/config-resolver.ts:210
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/core/config-resolver").LoadedConfig` - Loaded configuration with all metadata || **Location** | `C:/Users/chris/git/archlette/src/core/config-resolver.ts:210` | **Parameters:** @@ -223,26 +133,11 @@ This is the main entry point for config loading. It handles: Convert a name to a normalized ID Used for consistent ID generation across extractors and mappers - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsstring — Normalized ID (lowercase, hyphenated, alphanumeric)
LocationC:/Users/chris/git/archlette/src/core/constants.ts:56
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `string` - Normalized ID (lowercase, hyphenated, alphanumeric) || **Location** | `C:/Users/chris/git/archlette/src/core/constants.ts:56` | **Parameters:** @@ -258,26 +153,11 @@ Used for consistent ID generation across extractors and mappers Sanitize ID for DSL and code identifiers (preserves underscores) Used for Python code identifiers where underscores are significant - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsstring — Sanitized ID (lowercase alphanumeric and underscores only)
LocationC:/Users/chris/git/archlette/src/core/constants.ts:78
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `string` - Sanitized ID (lowercase alphanumeric and underscores only) || **Location** | `C:/Users/chris/git/archlette/src/core/constants.ts:78` | **Parameters:** @@ -292,26 +172,11 @@ Used for Python code identifiers where underscores are significant Determine if we're in a TTY environment (for pretty printing) - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsboolean
LocationC:/Users/chris/git/archlette/src/core/logger.ts:43
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `boolean` || **Location** | `C:/Users/chris/git/archlette/src/core/logger.ts:43` | @@ -320,26 +185,11 @@ Determine if we're in a TTY environment (for pretty printing) Get default log level from environment or fallback to 'info' - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsimport("C:/Users/chris/git/archlette/src/core/logger").LogLevel
LocationC:/Users/chris/git/archlette/src/core/logger.ts:50
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/core/logger").LogLevel` || **Location** | `C:/Users/chris/git/archlette/src/core/logger.ts:50` | @@ -348,26 +198,11 @@ Get default log level from environment or fallback to 'info' Create a Pino logger instance with optional pretty printing - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
ReturnsPinoLogger
LocationC:/Users/chris/git/archlette/src/core/logger.ts:66
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `PinoLogger` || **Location** | `C:/Users/chris/git/archlette/src/core/logger.ts:66` | **Parameters:** @@ -378,26 +213,11 @@ Create a Pino logger instance with optional pretty printing Create a logger instance - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsimport("C:/Users/chris/git/archlette/src/core/logger").Logger — Logger instance
LocationC:/Users/chris/git/archlette/src/core/logger.ts:131
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/core/logger").Logger` - Logger instance || **Location** | `C:/Users/chris/git/archlette/src/core/logger.ts:131` | **Parameters:** @@ -413,26 +233,11 @@ Create a logger instance Default base directory for user plugins: ~/.archlette/mods This provides a standard location for external plugins and custom modules - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsstring
LocationC:/Users/chris/git/archlette/src/core/module-loader.ts:59
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `string` || **Location** | `C:/Users/chris/git/archlette/src/core/module-loader.ts:59` | @@ -441,30 +246,11 @@ This provides a standard location for external plugins and custom modules Dynamically load an ESM module from a path or module specifier with security validation - - - - - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
AsyncYes
ReturnsPromise> — Promise resolving to loaded module with metadata
LocationC:/Users/chris/git/archlette/src/core/module-loader.ts:111
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Async** | Yes || **Returns** | `Promise>` - Promise resolving to loaded module with metadata || **Location** | `C:/Users/chris/git/archlette/src/core/module-loader.ts:111` | **Parameters:** @@ -479,26 +265,11 @@ Dynamically load an ESM module from a path or module specifier with security val ##### `getCliDir()` - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsstring
LocationC:/Users/chris/git/archlette/src/core/path-resolver.ts:17
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `string` || **Location** | `C:/Users/chris/git/archlette/src/core/path-resolver.ts:17` | @@ -506,26 +277,11 @@ Dynamically load an ESM module from a path or module specifier with security val ##### `expandTilde()` - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsstring
LocationC:/Users/chris/git/archlette/src/core/path-resolver.ts:24
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `string` || **Location** | `C:/Users/chris/git/archlette/src/core/path-resolver.ts:24` | **Parameters:** @@ -539,26 +295,11 @@ Core path resolver honoring Archlette rules (no file existence checks). - "/" -> absolute - else -> relative to CLI dir - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsstring
LocationC:/Users/chris/git/archlette/src/core/path-resolver.ts:42
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `string` || **Location** | `C:/Users/chris/git/archlette/src/core/path-resolver.ts:42` | **Parameters:** @@ -572,26 +313,11 @@ Resolve a module entry by probing: 2) With extensions: .ts then .js 3) If directory: index.ts then index.js - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsstring
LocationC:/Users/chris/git/archlette/src/core/path-resolver.ts:64
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `string` || **Location** | `C:/Users/chris/git/archlette/src/core/path-resolver.ts:64` | **Parameters:** @@ -601,26 +327,11 @@ Resolve a module entry by probing: ##### `toFileUrl()` - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsstring
LocationC:/Users/chris/git/archlette/src/core/path-resolver.ts:100
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `string` || **Location** | `C:/Users/chris/git/archlette/src/core/path-resolver.ts:100` | **Parameters:** @@ -631,26 +342,11 @@ Resolve a module entry by probing: Write content to a file, creating parent directories if needed. - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsvoid
LocationC:/Users/chris/git/archlette/src/core/path-resolver.ts:110
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `void` || **Location** | `C:/Users/chris/git/archlette/src/core/path-resolver.ts:110` | **Parameters:** @@ -661,26 +357,11 @@ Write content to a file, creating parent directories if needed. Validate path for security issues - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returns{ isSecure: boolean; warnings: string[]; }
LocationC:/Users/chris/git/archlette/src/core/path-security.ts:58
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `{ isSecure: boolean; warnings: string[]; }` || **Location** | `C:/Users/chris/git/archlette/src/core/path-security.ts:58` | **Parameters:** @@ -691,26 +372,11 @@ Validate path for security issues Securely resolve a user-provided path with validation - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsimport("C:/Users/chris/git/archlette/src/core/path-security").ResolvedSecurePath — Resolved path with security metadata
LocationC:/Users/chris/git/archlette/src/core/path-security.ts:203
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/core/path-security").ResolvedSecurePath` - Resolved path with security metadata || **Location** | `C:/Users/chris/git/archlette/src/core/path-security.ts:203` | **Parameters:** @@ -726,26 +392,11 @@ Securely resolve a user-provided path with validation Convenience function for resolving user content paths (themes, input files) Uses 'config-relative' strategy by default - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsimport("C:/Users/chris/git/archlette/src/core/path-security").ResolvedSecurePath
LocationC:/Users/chris/git/archlette/src/core/path-security.ts:289
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/core/path-security").ResolvedSecurePath` || **Location** | `C:/Users/chris/git/archlette/src/core/path-security.ts:289` | **Parameters:** @@ -757,26 +408,11 @@ Uses 'config-relative' strategy by default Convenience function for resolving plugin paths Uses 'cli-relative' strategy by default - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsimport("C:/Users/chris/git/archlette/src/core/path-security").ResolvedSecurePath
LocationC:/Users/chris/git/archlette/src/core/path-security.ts:308
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/core/path-security").ResolvedSecurePath` || **Location** | `C:/Users/chris/git/archlette/src/core/path-security.ts:308` | **Parameters:** @@ -786,26 +422,11 @@ Uses 'cli-relative' strategy by default ##### `getStageEntry()` - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsimport("C:/Users/chris/git/archlette/src/core/stage-entry").StageEntry
LocationC:/Users/chris/git/archlette/src/core/stage-entry.js:12
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/core/stage-entry").StageEntry` || **Location** | `C:/Users/chris/git/archlette/src/core/stage-entry.js:12` | **Parameters:** @@ -815,30 +436,11 @@ Uses 'cli-relative' strategy by default ##### `loadExtractorModule()` - - - - - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
AsyncYes
ReturnsPromise<{ entry: Function; resolved: string; }>
LocationC:/Users/chris/git/archlette/src/core/stage-module-loader.ts:13
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Async** | Yes || **Returns** | `Promise<{ entry: Function; resolved: string; }>` || **Location** | `C:/Users/chris/git/archlette/src/core/stage-module-loader.ts:13` | **Parameters:** @@ -848,30 +450,11 @@ Uses 'cli-relative' strategy by default ##### `loadValidatorModule()` - - - - - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
AsyncYes
ReturnsPromise<{ entry: Function; resolved: string; }>
LocationC:/Users/chris/git/archlette/src/core/stage-module-loader.ts:26
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Async** | Yes || **Returns** | `Promise<{ entry: Function; resolved: string; }>` || **Location** | `C:/Users/chris/git/archlette/src/core/stage-module-loader.ts:26` | **Parameters:** @@ -881,30 +464,11 @@ Uses 'cli-relative' strategy by default ##### `loadGeneratorModule()` - - - - - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
AsyncYes
ReturnsPromise<{ entry: Function; resolved: string; }>
LocationC:/Users/chris/git/archlette/src/core/stage-module-loader.ts:39
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Async** | Yes || **Returns** | `Promise<{ entry: Function; resolved: string; }>` || **Location** | `C:/Users/chris/git/archlette/src/core/stage-module-loader.ts:39` | **Parameters:** @@ -914,30 +478,11 @@ Uses 'cli-relative' strategy by default ##### `loadRendererModule()` - - - - - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
AsyncYes
ReturnsPromise<{ entry: Function; resolved: string; }>
LocationC:/Users/chris/git/archlette/src/core/stage-module-loader.ts:52
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Async** | Yes || **Returns** | `Promise<{ entry: Function; resolved: string; }>` || **Location** | `C:/Users/chris/git/archlette/src/core/stage-module-loader.ts:52` | **Parameters:** @@ -947,30 +492,11 @@ Uses 'cli-relative' strategy by default ##### `loadDocModule()` - - - - - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
AsyncYes
ReturnsPromise<{ entry: Function; resolved: string; }>
LocationC:/Users/chris/git/archlette/src/core/stage-module-loader.ts:65
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Async** | Yes || **Returns** | `Promise<{ entry: Function; resolved: string; }>` || **Location** | `C:/Users/chris/git/archlette/src/core/stage-module-loader.ts:65` | **Parameters:** @@ -981,26 +507,11 @@ Uses 'cli-relative' strategy by default Get the Archlette cache directory - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsstring
LocationC:/Users/chris/git/archlette/src/core/tool-manager.ts:64
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `string` || **Location** | `C:/Users/chris/git/archlette/src/core/tool-manager.ts:66` | @@ -1009,26 +520,11 @@ Get the Archlette cache directory Ensure cache directory exists - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsstring
LocationC:/Users/chris/git/archlette/src/core/tool-manager.ts:72
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `string` || **Location** | `C:/Users/chris/git/archlette/src/core/tool-manager.ts:74` | @@ -1036,27 +532,13 @@ Ensure cache directory exists ##### `commandExistsInPath()` Check if a command exists in PATH +Returns the full path if found, null otherwise - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsstring
LocationC:/Users/chris/git/archlette/src/core/tool-manager.ts:83
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `string` || **Location** | `C:/Users/chris/git/archlette/src/core/tool-manager.ts:86` | **Parameters:** @@ -1067,30 +549,11 @@ Check if a command exists in PATH Download a file from URL to destination - - - - - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
AsyncYes
ReturnsPromise
LocationC:/Users/chris/git/archlette/src/core/tool-manager.ts:102
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Async** | Yes || **Returns** | `Promise` || **Location** | `C:/Users/chris/git/archlette/src/core/tool-manager.ts:105` | **Parameters:** @@ -1101,30 +564,11 @@ Download a file from URL to destination Extract a ZIP file (simple extraction for Structurizr CLI) - - - - - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
AsyncYes
ReturnsPromise
LocationC:/Users/chris/git/archlette/src/core/tool-manager.ts:144
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Async** | Yes || **Returns** | `Promise` || **Location** | `C:/Users/chris/git/archlette/src/core/tool-manager.ts:147` | **Parameters:** @@ -1135,26 +579,11 @@ Extract a ZIP file (simple extraction for Structurizr CLI) Make file executable (Unix only) - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsvoid
LocationC:/Users/chris/git/archlette/src/core/tool-manager.ts:171
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `void` || **Location** | `C:/Users/chris/git/archlette/src/core/tool-manager.ts:174` | **Parameters:** @@ -1165,30 +594,11 @@ Make file executable (Unix only) Download and install Structurizr CLI to cache - - - - - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
AsyncYes
ReturnsPromise
LocationC:/Users/chris/git/archlette/src/core/tool-manager.ts:180
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Async** | Yes || **Returns** | `Promise` || **Location** | `C:/Users/chris/git/archlette/src/core/tool-manager.ts:183` | **Parameters:** @@ -1199,30 +609,11 @@ Download and install Structurizr CLI to cache Download and install PlantUML to cache - - - - - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
AsyncYes
ReturnsPromise
LocationC:/Users/chris/git/archlette/src/core/tool-manager.ts:218
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Async** | Yes || **Returns** | `Promise` || **Location** | `C:/Users/chris/git/archlette/src/core/tool-manager.ts:221` | **Parameters:** @@ -1233,30 +624,41 @@ Download and install PlantUML to cache Find or download Structurizr CLI - - - - - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
AsyncYes
ReturnsPromise — Path to structurizr executable/script
LocationC:/Users/chris/git/archlette/src/core/tool-manager.ts:244
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Async** | Yes || **Returns** | `Promise` - Path to structurizr executable/script || **Location** | `C:/Users/chris/git/archlette/src/core/tool-manager.ts:247` | + +**Parameters:** + +- `log`: import("C:/Users/chris/git/archlette/src/core/logger").Logger — - Optional logger + +--- +##### `downloadStructurizrLite()` + +Download and install Structurizr Lite to cache + +| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Async** | Yes || **Returns** | `Promise` || **Location** | `C:/Users/chris/git/archlette/src/core/tool-manager.ts:284` | + +**Parameters:** + +- `cacheDir`: string- `log`: import("C:/Users/chris/git/archlette/src/core/logger").Logger + +--- +##### `findStructurizrLite()` + +Find or download Structurizr Lite WAR file + +| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Async** | Yes || **Returns** | `Promise` - Path to structurizr-lite.war file || **Location** | `C:/Users/chris/git/archlette/src/core/tool-manager.ts:316` | **Parameters:** @@ -1267,30 +669,11 @@ Find or download Structurizr CLI Find or download PlantUML JAR - - - - - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
AsyncYes
ReturnsPromise — Path to plantuml.jar
LocationC:/Users/chris/git/archlette/src/core/tool-manager.ts:284
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Async** | Yes || **Returns** | `Promise` - Path to plantuml.jar || **Location** | `C:/Users/chris/git/archlette/src/core/tool-manager.ts:342` | **Parameters:** @@ -1301,26 +684,11 @@ Find or download PlantUML JAR Verify Java is available - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsstring — Java version string if available, null otherwise
LocationC:/Users/chris/git/archlette/src/core/tool-manager.ts:313
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `string` - Java version string if available, null otherwise || **Location** | `C:/Users/chris/git/archlette/src/core/tool-manager.ts:371` | @@ -1329,29 +697,32 @@ Verify Java is available Validate Java is installed (throw if not) - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsvoid
LocationC:/Users/chris/git/archlette/src/core/tool-manager.ts:334
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `void` || **Location** | `C:/Users/chris/git/archlette/src/core/tool-manager.ts:392` | +--- +##### `findMermaidCLI()` + +Find Mermaid CLI in system PATH + +Note: Mermaid CLI is not auto-downloaded. Users should install it via npm: +- Global: npm install -g + +| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `string` - Path to mmdc executable || **Location** | `C:/Users/chris/git/archlette/src/core/tool-manager.ts:421` | + +**Parameters:** + +- `log`: import("C:/Users/chris/git/archlette/src/core/logger").Logger — - Optional logger + --- ##### `resolveConfig()` @@ -1359,26 +730,11 @@ For each stage, resolve includes/excludes for each node: - If node omits includes/excludes, inherit from defaults. - Add configBaseDir for resolving config-relative paths - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsimport("C:/Users/chris/git/archlette/src/core/types-aac").ResolvedAACConfig
LocationC:/Users/chris/git/archlette/src/core/types-aac.ts:145
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `import("C:/Users/chris/git/archlette/src/core/types-aac").ResolvedAACConfig` || **Location** | `C:/Users/chris/git/archlette/src/core/types-aac.ts:145` | **Parameters:** @@ -1393,3 +749,4 @@ For each stage, resolve includes/excludes for each node: + diff --git a/docs/architecture/default_container__docs.md b/docs/architecture/default_container__docs.md index bdf4e43..57645aa 100644 --- a/docs/architecture/default_container__docs.md +++ b/docs/architecture/default_container__docs.md @@ -6,27 +6,12 @@ ## Component Information - - - - - - - - - - - - - - - - - - - -
Componentdocs
ContainerApplication
Typemodule
DescriptionDocumentation stage of the AAC pipeline | Markdown documentation generator
- +| Field | Value | +| --- | --- | +| **Component** | docs | +| **Container** | Application | +| **Type** | `module` | +| **Description** | Documentation stage of the AAC pipeline \| Markdown documentation generator | --- ## Code Structure @@ -48,30 +33,11 @@ Execute the documentation stage - - - - - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
AsyncYes
ReturnsPromise
LocationC:/Users/chris/git/archlette/src/5-docs/index.ts:35
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Async** | Yes || **Returns** | `Promise` || **Location** | `C:/Users/chris/git/archlette/src/5-docs/index.ts:35` | **Parameters:** @@ -82,30 +48,11 @@ Execute the documentation stage Generate markdown documentation - - - - - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
AsyncYes
ReturnsPromise
LocationC:/Users/chris/git/archlette/src/docs/builtin/markdown-docs.ts:33
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Async** | Yes || **Returns** | `Promise` || **Location** | `C:/Users/chris/git/archlette/src/docs/builtin/markdown-docs.ts:33` | **Parameters:** @@ -116,26 +63,11 @@ Generate markdown documentation Find diagram files for a specific view type - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsstring[]
LocationC:/Users/chris/git/archlette/src/docs/builtin/markdown-docs.ts:244
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `string[]` || **Location** | `C:/Users/chris/git/archlette/src/docs/builtin/markdown-docs.ts:262` | **Parameters:** @@ -146,26 +78,11 @@ Find diagram files for a specific view type Find component diagrams for a specific container - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsstring[]
LocationC:/Users/chris/git/archlette/src/docs/builtin/markdown-docs.ts:276
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `string[]` || **Location** | `C:/Users/chris/git/archlette/src/docs/builtin/markdown-docs.ts:295` | **Parameters:** @@ -176,26 +93,11 @@ Find component diagrams for a specific container Find class diagrams for a specific component - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsstring[]
LocationC:/Users/chris/git/archlette/src/docs/builtin/markdown-docs.ts:314
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `string[]` || **Location** | `C:/Users/chris/git/archlette/src/docs/builtin/markdown-docs.ts:334` | **Parameters:** @@ -205,26 +107,11 @@ Find class diagrams for a specific component ##### `sanitizeFileName()` - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsstring
LocationC:/Users/chris/git/archlette/src/docs/builtin/markdown-docs.ts:348
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `string` || **Location** | `C:/Users/chris/git/archlette/src/docs/builtin/markdown-docs.ts:369` | **Parameters:** @@ -239,3 +126,4 @@ Find class diagrams for a specific component + diff --git a/docs/architecture/default_container__extractors.md b/docs/architecture/default_container__extractors.md index 216e85b..929d86a 100644 --- a/docs/architecture/default_container__extractors.md +++ b/docs/architecture/default_container__extractors.md @@ -6,27 +6,12 @@ ## Component Information - - - - - - - - - - - - - - - - - - - -
Componentextractors
ContainerApplication
Typemodule
DescriptionArchletteIR aggregation utilities | Extraction stage of the AAC pipeline
- +| Field | Value | +| --- | --- | +| **Component** | extractors | +| **Container** | Application | +| **Type** | `module` | +| **Description** | ArchletteIR aggregation utilities \| Extraction stage of the AAC pipeline | --- ## Code Structure @@ -48,26 +33,11 @@ Aggregate multiple ArchletteIR objects into a single unified IR - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsz.infer — A single aggregated ArchletteIR with deduplicated elements
LocationC:/Users/chris/git/archlette/src/1-extract/aggregator.ts:47
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `z.infer` - A single aggregated ArchletteIR with deduplicated elements || **Location** | `C:/Users/chris/git/archlette/src/1-extract/aggregator.ts:47` | **Parameters:** @@ -82,26 +52,11 @@ Aggregate multiple ArchletteIR objects into a single unified IR Deduplicate array of entities by their ID field - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
ReturnsT[] — Array with duplicates removed (first occurrence preserved, descriptions merged)
LocationC:/Users/chris/git/archlette/src/1-extract/aggregator.ts:104
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `T[]` - Array with duplicates removed (first occurrence preserved, descriptions merged) || **Location** | `C:/Users/chris/git/archlette/src/1-extract/aggregator.ts:104` | **Parameters:** @@ -112,26 +67,11 @@ Deduplicate array of entities by their ID field Deduplicate array of entities by their name field - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
ReturnsT[] — Array with duplicates removed (first occurrence preserved, descriptions merged)
LocationC:/Users/chris/git/archlette/src/1-extract/aggregator.ts:142
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `T[]` - Array with duplicates removed (first occurrence preserved, descriptions merged) || **Location** | `C:/Users/chris/git/archlette/src/1-extract/aggregator.ts:142` | **Parameters:** @@ -142,26 +82,11 @@ Deduplicate array of entities by their name field Deduplicate relationships by source+destination+stereotype combination - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsz.infer[] — Array with duplicate relationships removed
LocationC:/Users/chris/git/archlette/src/1-extract/aggregator.ts:184
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `z.infer[]` - Array with duplicate relationships removed || **Location** | `C:/Users/chris/git/archlette/src/1-extract/aggregator.ts:184` | **Parameters:** @@ -172,30 +97,11 @@ Deduplicate relationships by source+destination+stereotype combination Execute the extraction stage - - - - - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
AsyncYes
ReturnsPromise
LocationC:/Users/chris/git/archlette/src/1-extract/index.ts:43
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Async** | Yes || **Returns** | `Promise` || **Location** | `C:/Users/chris/git/archlette/src/1-extract/index.ts:43` | **Parameters:** @@ -210,3 +116,4 @@ Execute the extraction stage + diff --git a/docs/architecture/default_container__generators.md b/docs/architecture/default_container__generators.md index 6ee573b..3a735d0 100644 --- a/docs/architecture/default_container__generators.md +++ b/docs/architecture/default_container__generators.md @@ -6,27 +6,12 @@ ## Component Information - - - - - - - - - - - - - - - - - - - -
Componentgenerators
ContainerApplication
Typemodule
DescriptionGeneration stage of the AAC pipeline | Structurizr DSL Generator (Template-based)
- +| Field | Value | +| --- | --- | +| **Component** | generators | +| **Container** | Application | +| **Type** | `module` | +| **Description** | Generation stage of the AAC pipeline \| Structurizr DSL Generator (Template-based) | --- ## Code Structure @@ -48,30 +33,11 @@ Execute the generation stage - - - - - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
AsyncYes
ReturnsPromise
LocationC:/Users/chris/git/archlette/src/3-generate/index.ts:36
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Async** | Yes || **Returns** | `Promise` || **Location** | `C:/Users/chris/git/archlette/src/3-generate/index.ts:36` | **Parameters:** @@ -82,26 +48,11 @@ Execute the generation stage Load the default Structurizr theme from templates directory - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsstring — Theme DSL content as string
LocationC:/Users/chris/git/archlette/src/generators/builtin/structurizr.ts:57
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `string` - Theme DSL content as string || **Location** | `C:/Users/chris/git/archlette/src/generators/builtin/structurizr.ts:59` | @@ -110,26 +61,11 @@ Load the default Structurizr theme from templates directory Generate Structurizr DSL from ArchletteIR - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsstring
LocationC:/Users/chris/git/archlette/src/generators/builtin/structurizr.ts:73
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `string` || **Location** | `C:/Users/chris/git/archlette/src/generators/builtin/structurizr.ts:75` | **Parameters:** @@ -140,26 +76,11 @@ Generate Structurizr DSL from ArchletteIR Prepare container data with components, code, and relationships for template - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsany
LocationC:/Users/chris/git/archlette/src/generators/builtin/structurizr.ts:148
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `any` || **Location** | `C:/Users/chris/git/archlette/src/generators/builtin/structurizr.ts:154` | **Parameters:** @@ -170,26 +91,11 @@ Prepare container data with components, code, and relationships for template Prepare component view data for template - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returns{ containerId: any; viewName: string; relevantActors: any; components: any; }
LocationC:/Users/chris/git/archlette/src/generators/builtin/structurizr.ts:198
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `{ containerId: any; viewName: string; relevantActors: any; components: any; }` || **Location** | `C:/Users/chris/git/archlette/src/generators/builtin/structurizr.ts:204` | **Parameters:** @@ -200,26 +106,11 @@ Prepare component view data for template Prepare class view data for template - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returns{ containerId: any; viewName: string; codeItems: any; }
LocationC:/Users/chris/git/archlette/src/generators/builtin/structurizr.ts:235
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `{ containerId: any; viewName: string; codeItems: any; }` || **Location** | `C:/Users/chris/git/archlette/src/generators/builtin/structurizr.ts:241` | **Parameters:** @@ -230,26 +121,11 @@ Prepare class view data for template Generate all actor-related relationships - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsz.infer[]
LocationC:/Users/chris/git/archlette/src/generators/builtin/structurizr.ts:250
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `z.infer[]` || **Location** | `C:/Users/chris/git/archlette/src/generators/builtin/structurizr.ts:256` | **Parameters:** @@ -260,26 +136,11 @@ Generate all actor-related relationships Generate a unique name for a code item to avoid naming collisions - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsstring
LocationC:/Users/chris/git/archlette/src/generators/builtin/structurizr.ts:297
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `string` || **Location** | `C:/Users/chris/git/archlette/src/generators/builtin/structurizr.ts:303` | **Parameters:** @@ -290,26 +151,11 @@ Generate a unique name for a code item to avoid naming collisions Build technology string from relationship metadata - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsstring
LocationC:/Users/chris/git/archlette/src/generators/builtin/structurizr.ts:335
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `string` || **Location** | `C:/Users/chris/git/archlette/src/generators/builtin/structurizr.ts:341` | **Parameters:** @@ -320,26 +166,11 @@ Build technology string from relationship metadata Sanitize ID for DSL (remove special characters, convert to valid identifier) - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsstring
LocationC:/Users/chris/git/archlette/src/generators/builtin/structurizr.ts:351
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `string` || **Location** | `C:/Users/chris/git/archlette/src/generators/builtin/structurizr.ts:357` | **Parameters:** @@ -353,26 +184,11 @@ Escape special characters in strings for DSL Structurizr DSL doesn't support \n escape sequences in strings, so we replace newlines with spaces for cleaner output. - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsstring
LocationC:/Users/chris/git/archlette/src/generators/builtin/structurizr.ts:361
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `string` || **Location** | `C:/Users/chris/git/archlette/src/generators/builtin/structurizr.ts:367` | **Parameters:** @@ -387,3 +203,4 @@ so we replace newlines with spaces for cleaner output. + diff --git a/docs/architecture/default_container__renderers.md b/docs/architecture/default_container__renderers.md index 2a52d7b..7ac0578 100644 --- a/docs/architecture/default_container__renderers.md +++ b/docs/architecture/default_container__renderers.md @@ -6,27 +6,12 @@ ## Component Information - - - - - - - - - - - - - - - - - - - -
Componentrenderers
ContainerApplication
Typemodule
DescriptionRender stage of the AAC pipeline | PlantUML image renderer | Structurizr DSL export renderer
- +| Field | Value | +| --- | --- | +| **Component** | renderers | +| **Container** | Application | +| **Type** | `module` | +| **Description** | Render stage of the AAC pipeline \| Mermaid image renderer \| PlantUML image renderer \| Structurizr DSL export renderer \| Structurizr direct image renderer | --- ## Code Structure @@ -38,7 +23,7 @@ ### Code Elements
-3 code element(s) +13 code element(s) @@ -48,64 +33,41 @@ Execute the rendering stage - - - - - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
AsyncYes
ReturnsPromise
LocationC:/Users/chris/git/archlette/src/4-render/index.ts:36
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Async** | Yes || **Returns** | `Promise` || **Location** | `C:/Users/chris/git/archlette/src/4-render/index.ts:36` | **Parameters:** - `ctx`: import("C:/Users/chris/git/archlette/src/core/types").PipelineContext — - Pipeline context with configuration, logging, and DSL file location +--- +##### `mermaidRender()` + +Render Mermaid files to images + +| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Async** | Yes || **Returns** | `Promise` || **Location** | `C:/Users/chris/git/archlette/src/renderers/builtin/mermaid-render.ts:41` | + +**Parameters:** + +- `ctx`: import("C:/Users/chris/git/archlette/src/core/types").PipelineContext- `node`: any + --- ##### `plantumlRender()` Render PlantUML files to PNG images - - - - - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
AsyncYes
ReturnsPromise
LocationC:/Users/chris/git/archlette/src/renderers/builtin/plantuml-render.ts:28
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Async** | Yes || **Returns** | `Promise` || **Location** | `C:/Users/chris/git/archlette/src/renderers/builtin/plantuml-render.ts:28` | **Parameters:** @@ -114,36 +76,160 @@ Render PlantUML files to PNG images --- ##### `structurizrExport()` -Export Structurizr DSL to PlantUML and Mermaid formats - - - - - - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
AsyncYes
ReturnsPromise
LocationC:/Users/chris/git/archlette/src/renderers/builtin/structurizr-export.ts:28
+Export Structurizr DSL to PlantUML and/or Mermaid formats + +| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Async** | Yes || **Returns** | `Promise` || **Location** | `C:/Users/chris/git/archlette/src/renderers/builtin/structurizr-export.ts:36` | **Parameters:** -- `ctx`: import("C:/Users/chris/git/archlette/src/core/types").PipelineContext +- `ctx`: import("C:/Users/chris/git/archlette/src/core/types").PipelineContext- `node`: any + +--- +##### `findGraphviz()` + +Find Graphviz dot command in PATH + +| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `string` || **Location** | `C:/Users/chris/git/archlette/src/renderers/builtin/structurizr-render.ts:41` | + +**Parameters:** + +- `log`: { debug?: (msg: string) => void; warn?: (msg: string) => void; } + +--- +##### `structurizrRender()` + +Render Structurizr DSL to images using CLI DOT export + Graphviz + +| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Async** | Yes || **Returns** | `Promise` || **Location** | `C:/Users/chris/git/archlette/src/renderers/builtin/structurizr-render.ts:74` | + +**Parameters:** + +- `ctx`: import("C:/Users/chris/git/archlette/src/core/types").PipelineContext- `node`: any + +--- +##### `extractStylesBlock()` + +Extract styles block from theme content using brace counting + +| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `string` || **Location** | `C:/Users/chris/git/archlette/src/renderers/builtin/structurizr-render.ts:267` | + +**Parameters:** + +- `content`: string + +--- +##### `removeBlock()` + +Remove a block from DSL content using brace counting + +| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `string` || **Location** | `C:/Users/chris/git/archlette/src/renderers/builtin/structurizr-render.ts:293` | + +**Parameters:** + +- `content`: string- `blockName`: string + +--- +##### `removeStylesBlock()` + + +| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `string` || **Location** | `C:/Users/chris/git/archlette/src/renderers/builtin/structurizr-render.ts:319` | + +**Parameters:** + +- `content`: string + +--- +##### `removeBrandingBlock()` + + +| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `string` || **Location** | `C:/Users/chris/git/archlette/src/renderers/builtin/structurizr-render.ts:323` | + +**Parameters:** + +- `content`: string + +--- +##### `escapeInvalidHtmlTags()` + +Escape all angle brackets that aren't part of valid DOT HTML tags. + +Handles cases where Structurizr inserts
for word-wrapping inside +other tag-like content (e.g., that are NOT part of those tags + +| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `string` || **Location** | `C:/Users/chris/git/archlette/src/renderers/builtin/structurizr-render.ts:359` | + +**Parameters:** + +- `content`: string- `debug`: boolean + +--- +##### `sanitizeDotContent()` + +Sanitize DOT file content for Graphviz compatibility + +Applies string replacements only within label=<<...>> content, +preserving the DOT structural syntax. + +| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `string` || **Location** | `C:/Users/chris/git/archlette/src/renderers/builtin/structurizr-render.ts:410` | + +**Parameters:** + +- `content`: string- `debug`: boolean + +--- +##### `sanitizeDotFiles()` + +Sanitize all DOT files in a directory + +| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `void` || **Location** | `C:/Users/chris/git/archlette/src/renderers/builtin/structurizr-render.ts:501` | + +**Parameters:** + +- `dotDir`: string- `debug`: boolean --- @@ -154,3 +240,4 @@ Export Structurizr DSL to PlantUML and Mermaid formats + diff --git a/docs/architecture/default_container__shared.md b/docs/architecture/default_container__shared.md index 7e78236..fb81350 100644 --- a/docs/architecture/default_container__shared.md +++ b/docs/architecture/default_container__shared.md @@ -6,22 +6,11 @@ ## Component Information - - - - - - - - - - - - - - - -
Componentshared
ContainerApplication
Typemodule
+| Field | Value | +| --- | --- | +| **Component** | shared | +| **Container** | Application | +| **Type** | `module` | --- @@ -48,26 +37,11 @@ Deduplicate relationships by source+destination combination - Extracts imported names from descriptions (removes "imports " prefix) and keeps only unique names - Returns one relationship per unique source+destination pair - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
Returnsz.infer[]
LocationC:/Users/chris/git/archlette/src/extractors/builtin/shared/relationship-utils.ts:15
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Returns** | `z.infer[]` || **Location** | `C:/Users/chris/git/archlette/src/extractors/builtin/shared/relationship-utils.ts:15` | **Parameters:** @@ -82,3 +56,4 @@ Deduplicate relationships by source+destination combination + diff --git a/docs/architecture/default_container__validators.md b/docs/architecture/default_container__validators.md index d2f040e..5cab266 100644 --- a/docs/architecture/default_container__validators.md +++ b/docs/architecture/default_container__validators.md @@ -6,27 +6,12 @@ ## Component Information - - - - - - - - - - - - - - - - - - - -
Componentvalidators
ContainerApplication
Typemodule
DescriptionValidation stage of the AAC pipeline | Base IR validator for Archlette pipeline
- +| Field | Value | +| --- | --- | +| **Component** | validators | +| **Container** | Application | +| **Type** | `module` | +| **Description** | Validation stage of the AAC pipeline \| Base IR validator for Archlette pipeline | --- ## Code Structure @@ -48,30 +33,11 @@ Execute the validation stage - - - - - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilitypublic
AsyncYes
ReturnsPromise
LocationC:/Users/chris/git/archlette/src/2-validate/index.ts:38
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `public` | +| **Async** | Yes || **Returns** | `Promise` || **Location** | `C:/Users/chris/git/archlette/src/2-validate/index.ts:38` | **Parameters:** @@ -82,26 +48,11 @@ Execute the validation stage Validates the IR against the Zod schema. Throws if invalid. - - - - - - - - - - - - - - - - - - - -
Typefunction
Visibilityprivate
Returnsz.infer — The same IR if valid
LocationC:/Users/chris/git/archlette/src/validators/builtin/base-validator.ts:26
+| Field | Value | +| --- | --- | +| **Type** | `function` | +| **Visibility** | `private` | +| **Returns** | `z.infer` - The same IR if valid || **Location** | `C:/Users/chris/git/archlette/src/validators/builtin/base-validator.ts:26` | **Parameters:** @@ -116,3 +67,4 @@ Validates the IR against the Zod schema. Throws if invalid. + diff --git a/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__basic_astro.mmd b/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__basic_astro.mmd index 60c02be..ba304dc 100644 --- a/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__basic_astro.mmd +++ b/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__basic_astro.mmd @@ -1,62 +1,62 @@ -graph TB +graph LR linkStyle default fill:#ffffff - subgraph diagram ["Application - Application - Components"] + subgraph diagram [" "] style diagram fill:#ffffff,stroke:#ffffff - subgraph 8 ["Application"] + subgraph 8 [" "] style 8 fill:#ffffff,stroke:#2e6295,color:#2e6295 - 100("
basic-astro.createSyntheticRenderFunction
[Component: function]
Create a synthetic render
function for an Astro
component Every Astro
component is fundamentally a
server-side render function
that: 1. Receives props (if
Props interface is defined)
2. Processes the component
logic (frontmatter code) 3.
Renders the template to HTML
4. Returns an HTML string
Since Astro's compiler
doesn't explicitly define
this, we create a synthetic
function to represent the
component's executable
behavior in the IR. The
function is named after the
file (without .astro
extension): - Button.astro →
function Button() -
index.astro → function
index() -
settings/Profile.astro →
function Profile()
") - style 100 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 101("
basic-astro.extractJSDocBlocks
[Component: function]
Extract all JSDoc comment
blocks from source code
Matches /** ... *\\/ style
comments and parses their
tags
") - style 101 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 102("
basic-astro.parseJSDocBlock
[Component: function]
Parse a single JSDoc comment
block into description and
tags
") - style 102 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 103("
basic-astro.extractFileComponent
[Component: function]
Extract component information
from frontmatter JSDoc
Attempts to identify the
component in this file using
JSDoc tags: 1. Checks for
") - style 103 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 104("
basic-astro.extractComponentName
[Component: function]
Extract component name from a
JSDoc tag value Parses the
tag value to extract the
component name, handling
various formats: - Simple
name: ComponentName - With
description: ComponentName -
Description - Module path:
path/to/module (extracts last
directory component) - Dashes
preserved: My-Component-Name
For module paths like
"utils/helpers", extracts
"utils" (the last directory
before the filename) to
enable component grouping.
") - style 104 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 105("
basic-astro.extractFileActors
[Component: function]
Extract actors from
frontmatter JSDoc Identifies
external actors (users,
systems) that interact with
the component. Actors are
specified using
") - style 105 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 106("
basic-astro.parseActorTag
[Component: function]
Parse an
") - style 106 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 107("
basic-astro.extractFileRelationships
[Component: function]
Extract relationships from
frontmatter JSDoc Identifies
component dependencies using
") - style 107 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 108("
basic-astro.parseUsesTag
[Component: function]
Parse a
") - style 108 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 109("
basic-astro.inferComponentFromPath
[Component: function]
Infer component name from
file path When no explicit
") - style 109 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 110("
basic-astro.findSourceFiles
[Component: function]
Find Astro source files
matching the given patterns
Locates all .astro files in
the workspace using glob
patterns. Returns absolute
paths to enable downstream
processing. Default patterns
include src directory and
exclude node_modules, dist,
build, and .astro.
") - style 110 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 111("
basic-astro.findPackageJsonFiles
[Component: function]
Find all package.json files
in the workspace Extracts
base directories from include
patterns and searches
multiple directory levels to
locate all package.json
files. Useful for identifying
container boundaries and
package metadata (name,
version, description).
") - style 111 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 112("
basic-astro.readPackageInfo
[Component: function]
Read package.json and extract
metadata Parses a
package.json file and
extracts key metadata fields:
name, version, and
description. Returns null on
read or parse errors (logged
as warnings).
") - style 112 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 113("
basic-astro.findNearestPackage
[Component: function]
Find the nearest package.json
for a given file Searches
through all known packages
and finds the one whose
directory is the closest
parent of the given file.
Packages are sorted by depth
(deepest first) to prioritize
monorepo sub-packages over
workspace root packages.
") - style 113 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 114("
basic-astro.parseFiles
[Component: function]
Parse Astro files using
") - style 114 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 115("
basic-astro.extractFrontmatter
[Component: function]
Extract frontmatter content
from Astro file Astro files
have two sections separated
by --- markers: -
Frontmatter:
TypeScript/JavaScript code at
the top (server-side) -
Template: HTML markup and
component usage (client-side)
This function extracts only
the frontmatter section.
Returns empty string if no
frontmatter. Handles both
Unix and Windows line endings
for cross-platform
compatibility.
") - style 115 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 116("
basic-astro.extractImports
[Component: function]
Extract import statements
from frontmatter Parses all
import declarations using
regex and categorizes them: -
Default imports: import Foo
from 'bar' - Named imports:
import { Foo, Bar } from
'baz' - Namespace imports:
import * as Foo from 'bar'
Also handles aliased imports
like: import { Foo as F }
from 'bar'
") - style 116 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 117("
basic-astro.findSlots
[Component: function]
Find slot tags in the
template Astro components can
define slots to allow content
projection: - Default slot:
(unnamed) - Named
slot:
Returns location information
(line number) for each slot
found.
") - style 117 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 118("
basic-astro.findClientDirective
[Component: function]
Find client directive in
component usage Astro allows
hydration directives to run
components on the client: -
client:load - Eager hydration
- client:idle - Hydrate when
browser is idle -
client:visible - Hydrate when
component enters viewport -
client:media - Hydrate when
media query matches -
client:only - Hydrate only on
client (no SSR) Returns the
first directive found. Used
to indicate interactive
components.
") - style 118 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 119("
basic-astro.extractComponentUsage
[Component: function]
Extract component usage from
template Identifies which
imported components are
actually used in the template
markup. Only includes
components that: 1. Start
with an uppercase letter (C4
naming convention) 2. Are
found in the import
statements 3. Appear in the
template markup Component
names in Astro are PascalCase
by convention (e.g., Header,
Footer). This function uses
the import list to avoid
false positives from HTML
elements.
") - style 119 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 120("
basic-astro.mapToIR
[Component: function]
Map file extractions to
ArchletteIR Transforms
extracted Astro component
data into standardized
ArchletteIR format. This is
the final step before DSL
generation and diagram
rendering. Algorithm (4 main
steps): 1. **Aggregation** -
Combine all file extractions:
- Register components,
actors, code items from all
files - Detect and merge
duplicates (same component in
multiple files) - Build
relationship graph from
") - style 120 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 121("
basic-astro.mapClassToCodeItems
[Component: function]
Map a class to code items
(class + methods)
") - style 121 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 122("
basic-astro.mapFunctionToCodeItem
[Component: function]
Map a function to a code item
") - style 122 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 81("
basic-astro.basicAstroExtractor
[Component: function]
Extract architecture
information from an Astro
codebase
") - style 81 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 99("
basic-astro.extractCodeFromFrontmatter
[Component: function]
Extract TypeScript/JavaScript
code from Astro frontmatter
Parses the frontmatter
section (code between ---
markers) as TypeScript and
extracts code elements using
the basic-node AST
extractors: - Classes and
their methods - Functions
(both regular and arrow
functions) - Type aliases
(type X = ...) - TypeScript
interfaces Returns empty
result if frontmatter is
empty or parsing fails
(errors are logged). Graceful
error handling ensures one
malformed Astro file doesn't
break the extraction
pipeline.
") - style 99 fill:#85bbf0,stroke:#5d82a8,color:#000000 + 112("
basic-astro.extractCodeFromFrontmatter
[Component: function]
Extract TypeScript/JavaScript
code from Astro frontmatter
Parses the frontmatter
section (code between ---
markers) as TypeScript and
extracts code elements using
the basic-node AST
extractors: - Classes and
their methods - Functions
(both regular and arrow
functions) - Type aliases
(type X = ...) - TypeScript
interfaces Returns empty
result if frontmatter is
empty or parsing fails
(errors are logged). Graceful
error handling ensures one
malformed Astro file doesn't
break the extraction
pipeline.
") + style 112 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 113("
basic-astro.createSyntheticRenderFunction
[Component: function]
Create a synthetic render
function for an Astro
component Every Astro
component is fundamentally a
server-side render function
that: 1. Receives props (if
Props interface is defined)
2. Processes the component
logic (frontmatter code) 3.
Renders the template to HTML
4. Returns an HTML string
Since Astro's compiler
doesn't explicitly define
this, we create a synthetic
function to represent the
component's executable
behavior in the IR. The
function is named after the
file (without .astro
extension): - Button.astro →
function Button() -
index.astro → function
index() -
settings/Profile.astro →
function Profile()
") + style 113 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 114("
basic-astro.extractJSDocBlocks
[Component: function]
Extract all JSDoc comment
blocks from source code
Matches /** ... *\\/ style
comments and parses their
tags
") + style 114 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 115("
basic-astro.parseJSDocBlock
[Component: function]
Parse a single JSDoc comment
block into description and
tags
") + style 115 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 116("
basic-astro.extractFileComponent
[Component: function]
Extract component information
from frontmatter JSDoc
Attempts to identify the
component in this file using
JSDoc tags: 1. Checks for
") + style 116 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 117("
basic-astro.extractComponentName
[Component: function]
Extract component name from a
JSDoc tag value Parses the
tag value to extract the
component name, handling
various formats: - Simple
name: ComponentName - With
description: ComponentName -
Description - Module path:
path/to/module (extracts last
directory component) - Dashes
preserved: My-Component-Name
For module paths like
"utils/helpers", extracts
"utils" (the last directory
before the filename) to
enable component grouping.
") + style 117 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 118("
basic-astro.extractFileActors
[Component: function]
Extract actors from
frontmatter JSDoc Identifies
external actors (users,
systems) that interact with
the component. Actors are
specified using
") + style 118 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 119("
basic-astro.parseActorTag
[Component: function]
Parse an
") + style 119 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 120("
basic-astro.extractFileRelationships
[Component: function]
Extract relationships from
frontmatter JSDoc Identifies
component dependencies using
") + style 120 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 121("
basic-astro.parseUsesTag
[Component: function]
Parse a
") + style 121 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 122("
basic-astro.inferComponentFromPath
[Component: function]
Infer component name from
file path When no explicit
") + style 122 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 123("
basic-astro.findSourceFiles
[Component: function]
Find Astro source files
matching the given patterns
Locates all .astro files in
the workspace using glob
patterns. Returns absolute
paths to enable downstream
processing. Default patterns
include src directory and
exclude node_modules, dist,
build, and .astro.
") + style 123 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 124("
basic-astro.findPackageJsonFiles
[Component: function]
Find all package.json files
in the workspace Extracts
base directories from include
patterns and searches
multiple directory levels to
locate all package.json
files. Useful for identifying
container boundaries and
package metadata (name,
version, description).
") + style 124 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 125("
basic-astro.readPackageInfo
[Component: function]
Read package.json and extract
metadata Parses a
package.json file and
extracts key metadata fields:
name, version, and
description. Returns null on
read or parse errors (logged
as warnings).
") + style 125 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 126("
basic-astro.findNearestPackage
[Component: function]
Find the nearest package.json
for a given file Searches
through all known packages
and finds the one whose
directory is the closest
parent of the given file.
Packages are sorted by depth
(deepest first) to prioritize
monorepo sub-packages over
workspace root packages.
") + style 126 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 127("
basic-astro.parseFiles
[Component: function]
Parse Astro files using
") + style 127 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 128("
basic-astro.extractFrontmatter
[Component: function]
Extract frontmatter content
from Astro file Astro files
have two sections separated
by --- markers: -
Frontmatter:
TypeScript/JavaScript code at
the top (server-side) -
Template: HTML markup and
component usage (client-side)
This function extracts only
the frontmatter section.
Returns empty string if no
frontmatter. Handles both
Unix and Windows line endings
for cross-platform
compatibility.
") + style 128 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 129("
basic-astro.extractImports
[Component: function]
Extract import statements
from frontmatter Parses all
import declarations using
regex and categorizes them: -
Default imports: import Foo
from 'bar' - Named imports:
import { Foo, Bar } from
'baz' - Namespace imports:
import * as Foo from 'bar'
Also handles aliased imports
like: import { Foo as F }
from 'bar'
") + style 129 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 130("
basic-astro.findSlots
[Component: function]
Find slot tags in the
template Astro components can
define slots to allow content
projection: - Default slot:
(unnamed) - Named
slot:
Returns location information
(line number) for each slot
found.
") + style 130 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 131("
basic-astro.findClientDirective
[Component: function]
Find client directive in
component usage Astro allows
hydration directives to run
components on the client: -
client:load - Eager hydration
- client:idle - Hydrate when
browser is idle -
client:visible - Hydrate when
component enters viewport -
client:media - Hydrate when
media query matches -
client:only - Hydrate only on
client (no SSR) Returns the
first directive found. Used
to indicate interactive
components.
") + style 131 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 132("
basic-astro.extractComponentUsage
[Component: function]
Extract component usage from
template Identifies which
imported components are
actually used in the template
markup. Only includes
components that: 1. Start
with an uppercase letter (C4
naming convention) 2. Are
found in the import
statements 3. Appear in the
template markup Component
names in Astro are PascalCase
by convention (e.g., Header,
Footer). This function uses
the import list to avoid
false positives from HTML
elements.
") + style 132 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 133("
basic-astro.mapToIR
[Component: function]
Map file extractions to
ArchletteIR Transforms
extracted Astro component
data into standardized
ArchletteIR format. This is
the final step before DSL
generation and diagram
rendering. Algorithm (4 main
steps): 1. **Aggregation** -
Combine all file extractions:
- Register components,
actors, code items from all
files - Detect and merge
duplicates (same component in
multiple files) - Build
relationship graph from
") + style 133 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 134("
basic-astro.mapClassToCodeItems
[Component: function]
Map a class to code items
(class + methods)
") + style 134 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 135("
basic-astro.mapFunctionToCodeItem
[Component: function]
Map a function to a code item
") + style 135 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 84("
basic-astro.basicAstroExtractor
[Component: function]
Extract architecture
information from an Astro
codebase
") + style 84 fill:#d4e8fc,stroke:#94a2b0,color:#000000 end end \ No newline at end of file diff --git a/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__basic_node.mmd b/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__basic_node.mmd index 561cc4c..b488b50 100644 --- a/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__basic_node.mmd +++ b/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__basic_node.mmd @@ -1,100 +1,100 @@ -graph TB +graph LR linkStyle default fill:#ffffff - subgraph diagram ["Application - Application - Components"] + subgraph diagram [" "] style diagram fill:#ffffff,stroke:#ffffff - subgraph 8 ["Application"] + subgraph 8 [" "] style 8 fill:#ffffff,stroke:#2e6295,color:#2e6295 - 123("
basic_node.extractClasses
[Component: function]
Extract all class
declarations from a source
file
") - style 123 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 124("
basic_node.extractClass
[Component: function]
Extract information from a
single class declaration
") - style 124 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 125("
basic_node.extractMethod
[Component: function]
Extract method information
from a class
") - style 125 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 126("
basic_node.extractProperty
[Component: function]
Extract property information
from a class
") - style 126 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 127("
basic_node.extractMethodParameter
[Component: function]
Extract parameter information
") - style 127 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 128("
basic_node.mapVisibility
[Component: function]
Map ts-morph Scope to our
visibility string
") - style 128 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 129("
basic_node.getFileJsDocs
[Component: function]
Get JSDoc comments from a
source file Checks both the
first statement and
module-level JSDoc
") - style 129 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 130("
basic_node.extractFileComponent
[Component: function]
Extract component information
from file-level JSDoc Checks
the first JSDoc comment in
the file for
") - style 130 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 131("
basic_node.extractFileActors
[Component: function]
Extract actors from
file-level JSDoc Looks for
") - style 131 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 132("
basic_node.extractFileRelationships
[Component: function]
Extract relationships from
file-level JSDoc Looks for
") - style 132 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 133("
basic_node.extractComponentFromJsDoc
[Component: function]
Extract component info from a
JSDoc node
") - style 133 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 134("
basic_node.extractActorsFromJsDoc
[Component: function]
Extract actors from a JSDoc
node Parses
") - style 134 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 135("
basic_node.parseActorTag
[Component: function]
Parse an
") - style 135 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 136("
basic_node.extractRelationshipsFromJsDoc
[Component: function]
Extract relationships from a
JSDoc node Parses
") - style 136 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 137("
basic_node.parseUsesTag
[Component: function]
Parse a
") - style 137 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 138("
basic_node.extractComponentName
[Component: function]
Extract component name from a
JSDoc tag Handles formats
like: -
") - style 138 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 139("
basic_node.inferComponentFromPath
[Component: function]
Infer component name from
file path - Files in
subdirectories use the
immediate parent folder name
- Files in root directory use
a special marker that will be
replaced with container name
Examples: -
/path/to/project/src/utils/helper.ts
-> 'utils' -
/path/to/project/src/index.ts
-> ROOT_COMPONENT_MARKER -
/path/to/project/services/api/client.ts
-> 'api'
") - style 139 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 140("
basic_node.extractDocumentation
[Component: function]
Extract documentation
information from JSDoc
") - style 140 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 141("
basic_node.extractDeprecation
[Component: function]
Extract deprecation
information from JSDoc
") - style 141 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 142("
basic_node.extractParameterDescriptions
[Component: function]
Extract parameter
descriptions from JSDoc
") - style 142 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 143("
basic_node.extractReturnDescription
[Component: function]
Extract return description
from JSDoc
") - style 143 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 144("
basic_node.extractParameterName
[Component: function]
Extract parameter name from
") - style 144 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 145("
basic_node.findSourceFiles
[Component: function]
Find source files matching
include/exclude patterns
") - style 145 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 146("
basic_node.findPackageJsonFiles
[Component: function]
Find package.json files
within the search paths
") - style 146 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 147("
basic_node.readPackageInfo
[Component: function]
Read and parse package.json
file
") - style 147 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 148("
basic_node.findNearestPackage
[Component: function]
Find the nearest parent
package.json for a given file
") - style 148 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 149("
basic_node.parseFiles
[Component: function]
Parse and extract information
from source files
") - style 149 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 150("
basic_node.extractFunctions
[Component: function]
Extract all function
declarations from a source
file
") - style 150 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 151("
basic_node.extractFunction
[Component: function]
Extract information from a
single function declaration
") - style 151 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 152("
basic_node.extractFunctionParameter
[Component: function]
Extract parameter information
") - style 152 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 153("
basic_node.extractArrowFunctions
[Component: function]
Extract arrow functions
assigned to const/let/var
Examples: const handleClick =
() => {} export const
createUser = async (data) =>
{}
") - style 153 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 154("
basic_node.extractImports
[Component: function]
Extract all import
declarations from a source
file
") - style 154 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 155("
basic_node.mapToIR
[Component: function]
Map file extractions to
ArchletteIR
") - style 155 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 156("
basic_node.mapFunction
[Component: function]
Map a function to a CodeItem
") - style 156 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 157("
basic_node.mapClass
[Component: function]
Map a class to a CodeItem
") - style 157 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 158("
basic_node.mapMethod
[Component: function]
Map a class method to a
CodeItem
") - style 158 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 159("
basic_node.resolveImportPath
[Component: function]
Resolve an import path to an
absolute file path Handles
relative imports (./file,
../file) and resolves to
actual file paths Returns
undefined for node_modules
imports or unresolvable paths
") - style 159 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 160("
basic_node.mapImportToComponentRelationships
[Component: function]
Map imports to component
relationships
(component-level
dependencies)
") - style 160 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 161("
basic_node.mapImportRelationships
[Component: function]
Map imports to relationships
(original code-level format
for backward compatibility)
") - style 161 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 162("
basic_node.generateId
[Component: function]
Generate a unique ID for a
code element Format:
filePath:symbolName
") - style 162 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 163("
basic_node.getDefaultSystem
[Component: function]
Get default system info from
package.json if available
") - style 163 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 164("
basic_node.extractTypeAliases
[Component: function]
Extract type aliases from a
source file Examples: type
UserRole = 'admin' | 'user' |
'guest' export type
ApiResponse = { data: T;
status: number }
") - style 164 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 165("
basic_node.extractInterfaces
[Component: function]
Extract interfaces from a
source file Examples:
interface User { id: string;
name: string } export
interface ApiClient {
get(url: string):
Promise }
") - style 165 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 82("
basic_node.basicNodeExtractor
[Component: function]
Extract architecture
information from a
Node.js/TypeScript codebase
") - style 82 fill:#85bbf0,stroke:#5d82a8,color:#000000 + 136("
basic_node.extractClasses
[Component: function]
Extract all class
declarations from a source
file
") + style 136 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 137("
basic_node.extractClass
[Component: function]
Extract information from a
single class declaration
") + style 137 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 138("
basic_node.extractMethod
[Component: function]
Extract method information
from a class
") + style 138 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 139("
basic_node.extractProperty
[Component: function]
Extract property information
from a class
") + style 139 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 140("
basic_node.extractMethodParameter
[Component: function]
Extract parameter information
") + style 140 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 141("
basic_node.mapVisibility
[Component: function]
Map ts-morph Scope to our
visibility string
") + style 141 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 142("
basic_node.getFileJsDocs
[Component: function]
Get JSDoc comments from a
source file Checks both the
first statement and
module-level JSDoc
") + style 142 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 143("
basic_node.extractFileComponent
[Component: function]
Extract component information
from file-level JSDoc Checks
the first JSDoc comment in
the file for
") + style 143 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 144("
basic_node.extractFileActors
[Component: function]
Extract actors from
file-level JSDoc Looks for
") + style 144 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 145("
basic_node.extractFileRelationships
[Component: function]
Extract relationships from
file-level JSDoc Looks for
") + style 145 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 146("
basic_node.extractComponentFromJsDoc
[Component: function]
Extract component info from a
JSDoc node
") + style 146 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 147("
basic_node.extractActorsFromJsDoc
[Component: function]
Extract actors from a JSDoc
node Parses
") + style 147 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 148("
basic_node.parseActorTag
[Component: function]
Parse an
") + style 148 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 149("
basic_node.extractRelationshipsFromJsDoc
[Component: function]
Extract relationships from a
JSDoc node Parses
") + style 149 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 150("
basic_node.parseUsesTag
[Component: function]
Parse a
") + style 150 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 151("
basic_node.extractComponentName
[Component: function]
Extract component name from a
JSDoc tag Handles formats
like: -
") + style 151 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 152("
basic_node.inferComponentFromPath
[Component: function]
Infer component name from
file path - Files in
subdirectories use the
immediate parent folder name
- Files in root directory use
a special marker that will be
replaced with container name
Examples: -
/path/to/project/src/utils/helper.ts
-> 'utils' -
/path/to/project/src/index.ts
-> ROOT_COMPONENT_MARKER -
/path/to/project/services/api/client.ts
-> 'api'
") + style 152 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 153("
basic_node.extractDocumentation
[Component: function]
Extract documentation
information from JSDoc
") + style 153 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 154("
basic_node.extractDeprecation
[Component: function]
Extract deprecation
information from JSDoc
") + style 154 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 155("
basic_node.extractParameterDescriptions
[Component: function]
Extract parameter
descriptions from JSDoc
") + style 155 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 156("
basic_node.extractReturnDescription
[Component: function]
Extract return description
from JSDoc
") + style 156 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 157("
basic_node.extractParameterName
[Component: function]
Extract parameter name from
") + style 157 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 158("
basic_node.findSourceFiles
[Component: function]
Find source files matching
include/exclude patterns
") + style 158 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 159("
basic_node.findPackageJsonFiles
[Component: function]
Find package.json files
within the search paths
") + style 159 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 160("
basic_node.readPackageInfo
[Component: function]
Read and parse package.json
file
") + style 160 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 161("
basic_node.findNearestPackage
[Component: function]
Find the nearest parent
package.json for a given file
") + style 161 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 162("
basic_node.parseFiles
[Component: function]
Parse and extract information
from source files
") + style 162 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 163("
basic_node.extractFunctions
[Component: function]
Extract all function
declarations from a source
file
") + style 163 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 164("
basic_node.extractFunction
[Component: function]
Extract information from a
single function declaration
") + style 164 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 165("
basic_node.extractFunctionParameter
[Component: function]
Extract parameter information
") + style 165 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 166("
basic_node.extractArrowFunctions
[Component: function]
Extract arrow functions
assigned to const/let/var
Examples: const handleClick =
() => {} export const
createUser = async (data) =>
{}
") + style 166 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 167("
basic_node.extractImports
[Component: function]
Extract all import
declarations from a source
file
") + style 167 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 168("
basic_node.mapToIR
[Component: function]
Map file extractions to
ArchletteIR
") + style 168 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 169("
basic_node.mapFunction
[Component: function]
Map a function to a CodeItem
") + style 169 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 170("
basic_node.mapClass
[Component: function]
Map a class to a CodeItem
") + style 170 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 171("
basic_node.mapMethod
[Component: function]
Map a class method to a
CodeItem
") + style 171 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 172("
basic_node.resolveImportPath
[Component: function]
Resolve an import path to an
absolute file path Handles
relative imports (./file,
../file) and resolves to
actual file paths Returns
undefined for node_modules
imports or unresolvable paths
") + style 172 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 173("
basic_node.mapImportToComponentRelationships
[Component: function]
Map imports to component
relationships
(component-level
dependencies)
") + style 173 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 174("
basic_node.mapImportRelationships
[Component: function]
Map imports to relationships
(original code-level format
for backward compatibility)
") + style 174 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 175("
basic_node.generateId
[Component: function]
Generate a unique ID for a
code element Format:
filePath:symbolName
") + style 175 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 176("
basic_node.getDefaultSystem
[Component: function]
Get default system info from
package.json if available
") + style 176 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 177("
basic_node.extractTypeAliases
[Component: function]
Extract type aliases from a
source file Examples: type
UserRole = 'admin' | 'user' |
'guest' export type
ApiResponse = { data: T;
status: number }
") + style 177 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 178("
basic_node.extractInterfaces
[Component: function]
Extract interfaces from a
source file Examples:
interface User { id: string;
name: string } export
interface ApiClient {
get(url: string):
Promise }
") + style 178 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 85("
basic_node.basicNodeExtractor
[Component: function]
Extract architecture
information from a
Node.js/TypeScript codebase
") + style 85 fill:#d4e8fc,stroke:#94a2b0,color:#000000 end end \ No newline at end of file diff --git a/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__basic_python.mmd b/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__basic_python.mmd index 3f8c24f..5df0813 100644 --- a/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__basic_python.mmd +++ b/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__basic_python.mmd @@ -1,68 +1,68 @@ -graph TB +graph LR linkStyle default fill:#ffffff - subgraph diagram ["Application - Application - Components"] + subgraph diagram [" "] style diagram fill:#ffffff,stroke:#ffffff - subgraph 8 ["Application"] + subgraph 8 [" "] style 8 fill:#ffffff,stroke:#2e6295,color:#2e6295 - 166("
basic-python.findSourceFiles
[Component: function]
Find source files matching
include/exclude patterns
") - style 166 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 167("
basic-python.findPyProjectFiles
[Component: function]
Find pyproject.toml files
within the search paths
") - style 167 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 168("
basic-python.readPyProjectInfo
[Component: function]
Read and parse pyproject.toml
file
") - style 168 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 169("
basic-python.parsePyProjectToml
[Component: function]
Parse pyproject.toml using
smol-toml library Handles
full TOML spec including
multiline strings, arrays,
and nested tables
") - style 169 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 170("
basic-python.findNearestPyProject
[Component: function]
Find the nearest parent
pyproject.toml for a given
file
") - style 170 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 171("
basic-python.parseFiles
[Component: function]
Parse Python files using
Python AST parser script
") - style 171 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 172("
basic-python.runPythonParser
[Component: function]
Run Python parser script and
return JSON output
") - style 172 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 173("
basic-python.mapToFileExtraction
[Component: function]
Map Python parser output to
FileExtraction format
") - style 173 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 174("
basic-python.mapClass
[Component: function]
Map Python class to
ExtractedClass
") - style 174 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 175("
basic-python.mapMethod
[Component: function]
Map Python method to
ExtractedMethod
") - style 175 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 176("
basic-python.mapProperty
[Component: function]
Map Python property to
ExtractedProperty
") - style 176 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 177("
basic-python.mapFunction
[Component: function]
Map Python function to
ExtractedFunction
") - style 177 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 178("
basic-python.mapType
[Component: function]
Map Python type definition to
ExtractedType
") - style 178 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 179("
basic-python.mapParameter
[Component: function]
Map Python parameter to
ParameterInfo
") - style 179 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 180("
basic-python.parseDocstring
[Component: function]
Parse Python docstring into
DocInfo Enhanced in Phase 2
to use parsed
Google/NumPy/Sphinx
docstrings
") - style 180 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 181("
basic-python.extractDeprecation
[Component: function]
Extract deprecation info from
docstring
") - style 181 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 182("
basic-python.extractReturnDescription
[Component: function]
Extract return description
from docstring
") - style 182 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 183("
basic-python.getVisibility
[Component: function]
Determine visibility from
Python name convention -
__name: private - _name:
protected - name: public
") - style 183 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 184("
basic-python.mapToIR
[Component: function]
Map file extractions to
ArchletteIR
") - style 184 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 185("
basic-python.mapActorToIR
[Component: function]
Map ActorInfo to Actor
") - style 185 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 186("
basic-python.mapRelationshipsToIR
[Component: function]
Map relationships to
Relationship[] Creates
bidirectional actor
relationships
") - style 186 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 187("
basic-python.mapImportToComponentRelationships
[Component: function]
Map Python imports to
component relationships
(component-level
dependencies) Resolves local
imports to component IDs when
possible
") - style 187 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 188("
basic-python.mapClassToCodeItem
[Component: function]
Map ExtractedClass to
CodeItem
") - style 188 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 189("
basic-python.mapMethodToCodeItem
[Component: function]
Map ExtractedMethod to
CodeItem
") - style 189 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 190("
basic-python.mapFunctionToCodeItem
[Component: function]
Map ExtractedFunction to
CodeItem
") - style 190 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 191("
basic-python.mapTypeToCodeItem
[Component: function]
Map ExtractedType to CodeItem
") - style 191 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 83("
basic-python.createEmptyIR
[Component: function]
Create empty IR when no files
found
") - style 83 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 84("
basic-python.basicPython
[Component: function]
Basic Python extractor
Analyzes Python source code
and extracts architectural
components
") - style 84 fill:#85bbf0,stroke:#5d82a8,color:#000000 + 179("
basic-python.findSourceFiles
[Component: function]
Find source files matching
include/exclude patterns
") + style 179 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 180("
basic-python.findPyProjectFiles
[Component: function]
Find pyproject.toml files
within the search paths
") + style 180 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 181("
basic-python.readPyProjectInfo
[Component: function]
Read and parse pyproject.toml
file
") + style 181 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 182("
basic-python.parsePyProjectToml
[Component: function]
Parse pyproject.toml using
smol-toml library Handles
full TOML spec including
multiline strings, arrays,
and nested tables
") + style 182 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 183("
basic-python.findNearestPyProject
[Component: function]
Find the nearest parent
pyproject.toml for a given
file
") + style 183 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 184("
basic-python.parseFiles
[Component: function]
Parse Python files using
Python AST parser script
") + style 184 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 185("
basic-python.runPythonParser
[Component: function]
Run Python parser script and
return JSON output
") + style 185 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 186("
basic-python.mapToFileExtraction
[Component: function]
Map Python parser output to
FileExtraction format
") + style 186 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 187("
basic-python.mapClass
[Component: function]
Map Python class to
ExtractedClass
") + style 187 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 188("
basic-python.mapMethod
[Component: function]
Map Python method to
ExtractedMethod
") + style 188 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 189("
basic-python.mapProperty
[Component: function]
Map Python property to
ExtractedProperty
") + style 189 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 190("
basic-python.mapFunction
[Component: function]
Map Python function to
ExtractedFunction
") + style 190 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 191("
basic-python.mapType
[Component: function]
Map Python type definition to
ExtractedType
") + style 191 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 192("
basic-python.mapParameter
[Component: function]
Map Python parameter to
ParameterInfo
") + style 192 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 193("
basic-python.parseDocstring
[Component: function]
Parse Python docstring into
DocInfo Enhanced in Phase 2
to use parsed
Google/NumPy/Sphinx
docstrings
") + style 193 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 194("
basic-python.extractDeprecation
[Component: function]
Extract deprecation info from
docstring
") + style 194 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 195("
basic-python.extractReturnDescription
[Component: function]
Extract return description
from docstring
") + style 195 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 196("
basic-python.getVisibility
[Component: function]
Determine visibility from
Python name convention -
__name: private - _name:
protected - name: public
") + style 196 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 197("
basic-python.mapToIR
[Component: function]
Map file extractions to
ArchletteIR
") + style 197 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 198("
basic-python.mapActorToIR
[Component: function]
Map ActorInfo to Actor
") + style 198 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 199("
basic-python.mapRelationshipsToIR
[Component: function]
Map relationships to
Relationship[] Creates
bidirectional actor
relationships
") + style 199 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 200("
basic-python.mapImportToComponentRelationships
[Component: function]
Map Python imports to
component relationships
(component-level
dependencies) Resolves local
imports to component IDs when
possible
") + style 200 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 201("
basic-python.mapClassToCodeItem
[Component: function]
Map ExtractedClass to
CodeItem
") + style 201 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 202("
basic-python.mapMethodToCodeItem
[Component: function]
Map ExtractedMethod to
CodeItem
") + style 202 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 203("
basic-python.mapFunctionToCodeItem
[Component: function]
Map ExtractedFunction to
CodeItem
") + style 203 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 204("
basic-python.mapTypeToCodeItem
[Component: function]
Map ExtractedType to CodeItem
") + style 204 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 86("
basic-python.createEmptyIR
[Component: function]
Create empty IR when no files
found
") + style 86 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 87("
basic-python.basicPython
[Component: function]
Basic Python extractor
Analyzes Python source code
and extracts architectural
components
") + style 87 fill:#d4e8fc,stroke:#94a2b0,color:#000000 end end \ No newline at end of file diff --git a/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__basic_wrangler.mmd b/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__basic_wrangler.mmd index 4650dc3..24e724d 100644 --- a/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__basic_wrangler.mmd +++ b/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__basic_wrangler.mmd @@ -1,38 +1,40 @@ -graph TB +graph LR linkStyle default fill:#ffffff - subgraph diagram ["Application - Application - Components"] + subgraph diagram [" "] style diagram fill:#ffffff,stroke:#ffffff - subgraph 8 ["Application"] + subgraph 8 [" "] style 8 fill:#ffffff,stroke:#2e6295,color:#2e6295 - 192("
basic_wrangler.findWranglerFiles
[Component: function]
Find wrangler.toml files
based on include/exclude
patterns
") - style 192 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 193("
basic_wrangler.mapToIR
[Component: function]
Map wrangler configurations
to ArchletteIR This creates:
- Containers: One per
wrangler.toml file -
Deployments: One per
environment (production, dev,
preview, etc.) - Container
Instances: One per container
per environment - Container
Relationships: Logical
dependencies from service
bindings - Deployment
Relationships: Physical
instance-to-instance
connections
") - style 193 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 194("
basic_wrangler.extractContainers
[Component: function]
Extract containers from
wrangler configurations
Creates one container per
wrangler.toml file. Each
container represents a
Cloudflare Worker (if main
exists) or other Cloudflare
service.
") - style 194 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 195("
basic_wrangler.deriveContainerType
[Component: function]
Derive container type from
wrangler configuration Logic:
- If 'main' field exists →
Cloudflare Worker - Otherwise
→ Cloudflare Service
(generic)
") - style 195 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 196("
basic_wrangler.extractDeploymentsAndInstances
[Component: function]
Extract deployments and
container instances Creates:
- One deployment per
environment - Container
instances for each container
in each environment
") - style 196 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 197("
basic_wrangler.extractContainerRelationships
[Component: function]
Extract container
relationships from service
bindings Creates logical
dependencies between
containers based on service
bindings. Deduplicates
relationships across all
environments.
") - style 197 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 198("
basic_wrangler.extractDeploymentRelationships
[Component: function]
Extract deployment
relationships from container
instances Creates physical
instance-to-instance
relationships based on
service bindings. Each
relationship represents an
actual runtime dependency in
a specific environment.
") - style 198 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 199("
basic_wrangler.extractDescription
[Component: function]
Extract description from
") - style 199 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 200("
basic_wrangler.parseWranglerFile
[Component: function]
Parse a wrangler.toml file
") - style 200 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 201("
basic_wrangler.normalizeServiceBindings
[Component: function]
Normalize service bindings
from various formats Wrangler
supports multiple binding
formats: - [[services]] array
(TOML array of tables) -
services = [{ binding =
"...", service = "..." }]
") - style 201 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 202("
basic_wrangler.getEnvironments
[Component: function]
Get all environments from a
wrangler config Returns a
list of environment names,
including: - "production"
(from root-level config if it
has deployable content) - All
keys from env.* sections
") - style 202 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 203("
basic_wrangler.getEnvironmentConfig
[Component: function]
Get configuration for a
specific environment Merges
root-level config with
environment-specific
overrides. Environment config
takes precedence.
") - style 203 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 85("
basic_wrangler.basicWranglerExtractor
[Component: function]
Extract deployment topology
from Cloudflare Wrangler
configuration files
") - style 85 fill:#85bbf0,stroke:#5d82a8,color:#000000 + 205("
basic_wrangler.findWranglerFiles
[Component: function]
Find wrangler.toml files
based on include/exclude
patterns
") + style 205 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 206("
basic_wrangler.mapToIR
[Component: function]
Map wrangler configurations
to ArchletteIR This creates:
- Containers: One per
wrangler.toml file -
Deployments: One per
environment (production, dev,
preview, etc.) - Container
Instances: One per container
per environment - Container
Relationships: Logical
dependencies from service
bindings - Deployment
Relationships: Physical
instance-to-instance
connections
") + style 206 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 207("
basic_wrangler.extractContainers
[Component: function]
Extract containers from
wrangler configurations
Creates one container per
wrangler.toml file. Each
container represents a
Cloudflare Worker (if main
exists) or other Cloudflare
service.
") + style 207 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 208("
basic_wrangler.deriveContainerType
[Component: function]
Derive container type from
wrangler configuration Logic:
- If 'main' field exists →
Cloudflare Worker - Otherwise
→ Cloudflare Service
(generic)
") + style 208 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 209("
basic_wrangler.extractDeploymentsAndInstances
[Component: function]
Extract deployments and
container instances Creates:
- One deployment per
environment - Container
instances for each container
in each environment
") + style 209 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 210("
basic_wrangler.findMatchingContainer
[Component: function]
Smart lookup to find matching
container for a service name
Tries exact match first, then
fuzzy matching with common
environment suffix removal.
") + style 210 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 211("
basic_wrangler.extractContainerRelationships
[Component: function]
Extract container
relationships from service
bindings Creates logical
dependencies between
containers based on service
bindings. Uses smart lookup
to match service names to
actual containers.
Deduplicates relationships
across all environments.
") + style 211 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 212("
basic_wrangler.extractDeploymentRelationships
[Component: function]
Extract deployment
relationships from container
instances Creates physical
instance-to-instance
relationships based on
service bindings. Each
relationship represents an
actual runtime dependency in
a specific environment.
") + style 212 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 213("
basic_wrangler.extractDescription
[Component: function]
Extract description from
") + style 213 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 214("
basic_wrangler.parseWranglerFile
[Component: function]
Parse a wrangler.toml file
") + style 214 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 215("
basic_wrangler.normalizeServiceBindings
[Component: function]
Normalize service bindings
from various formats Wrangler
supports multiple binding
formats: - [[services]] array
(TOML array of tables) -
services = [{ binding =
"...", service = "..." }]
") + style 215 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 216("
basic_wrangler.getEnvironments
[Component: function]
Get all environments from a
wrangler config Returns a
list of environment names,
including: - "production"
(from root-level config if it
has deployable content) - All
keys from env.* sections
") + style 216 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 217("
basic_wrangler.getEnvironmentConfig
[Component: function]
Get configuration for a
specific environment Merges
root-level config with
environment-specific
overrides. Environment config
takes precedence.
") + style 217 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 88("
basic_wrangler.basicWranglerExtractor
[Component: function]
Extract deployment topology
from Cloudflare Wrangler
configuration files
") + style 88 fill:#d4e8fc,stroke:#94a2b0,color:#000000 end end \ No newline at end of file diff --git a/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__cli.mmd b/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__cli.mmd index 9404a48..30c1b30 100644 --- a/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__cli.mmd +++ b/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__cli.mmd @@ -1,20 +1,20 @@ -graph TB +graph LR linkStyle default fill:#ffffff - subgraph diagram ["Application - Application - Components"] + subgraph diagram [" "] style diagram fill:#ffffff,stroke:#ffffff - subgraph 8 ["Application"] + subgraph 8 [" "] style 8 fill:#ffffff,stroke:#2e6295,color:#2e6295 21("
CLI.usageAndExit
[Component: function]
") - style 21 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 21 fill:#d4e8fc,stroke:#94a2b0,color:#000000 22("
CLI.parseArgs
[Component: function]
") - style 22 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 22 fill:#d4e8fc,stroke:#94a2b0,color:#000000 23("
CLI.stageListFromArg
[Component: function]
") - style 23 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 23 fill:#d4e8fc,stroke:#94a2b0,color:#000000 24("
CLI.run
[Component: function]
") - style 24 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 24 fill:#d4e8fc,stroke:#94a2b0,color:#000000 end end \ No newline at end of file diff --git a/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__core.mmd b/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__core.mmd index 87f0440..3e9bd25 100644 --- a/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__core.mmd +++ b/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__core.mmd @@ -1,96 +1,102 @@ -graph TB +graph LR linkStyle default fill:#ffffff - subgraph diagram ["Application - Application - Components"] + subgraph diagram [" "] style diagram fill:#ffffff,stroke:#ffffff - subgraph 8 ["Application"] + subgraph 8 [" "] style 8 fill:#ffffff,stroke:#2e6295,color:#2e6295 34("
core.resolveConfigFilePath
[Component: function]
Resolve config file path from
CLI arguments
") - style 34 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 34 fill:#d4e8fc,stroke:#94a2b0,color:#000000 35("
core.resolveConfigBaseDir
[Component: function]
Determine base directory for
resolving config-relative
paths Logic: - If using
default template: CWD (user's
project directory) - If user
provided config file: config
file's directory - Fallback:
CWD
") - style 35 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 35 fill:#d4e8fc,stroke:#94a2b0,color:#000000 36("
core.loadYamlFile
[Component: function]
Load and parse YAML config
file
") - style 36 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 36 fill:#d4e8fc,stroke:#94a2b0,color:#000000 37("
core.createDefaultConfig
[Component: function]
Create minimal default
configuration when no config
file is found
") - style 37 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 37 fill:#d4e8fc,stroke:#94a2b0,color:#000000 38("
core.loadConfig
[Component: function]
Load configuration from file
path (high-level API) This is
the main entry point for
config loading. It handles:
1. Config file path
resolution (default vs
user-provided) 2. Base
directory determination 3.
YAML parsing 4. Config
validation and resolution 5.
Fallback to default config
") - style 38 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 38 fill:#d4e8fc,stroke:#94a2b0,color:#000000 39("
core.nameToId
[Component: function]
Convert a name to a
normalized ID Used for
consistent ID generation
across extractors and mappers
") - style 39 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 39 fill:#d4e8fc,stroke:#94a2b0,color:#000000 40("
core.sanitizeId
[Component: function]
Sanitize ID for DSL and code
identifiers (preserves
underscores) Used for Python
code identifiers where
underscores are significant
") - style 40 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 40 fill:#d4e8fc,stroke:#94a2b0,color:#000000 41("
core.isTTY
[Component: function]
Determine if we're in a TTY
environment (for pretty
printing)
") - style 41 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 41 fill:#d4e8fc,stroke:#94a2b0,color:#000000 42("
core.getDefaultLogLevel
[Component: function]
Get default log level from
environment or fallback to
'info'
") - style 42 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 42 fill:#d4e8fc,stroke:#94a2b0,color:#000000 43("
core.createPinoLogger
[Component: function]
Create a Pino logger instance
with optional pretty printing
") - style 43 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 43 fill:#d4e8fc,stroke:#94a2b0,color:#000000 44("
core.createLogger
[Component: function]
Create a logger instance
") - style 44 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 44 fill:#d4e8fc,stroke:#94a2b0,color:#000000 45("
core.getDefaultUserPluginDir
[Component: function]
Default base directory for
user plugins:
~/.archlette/mods This
provides a standard location
for external plugins and
custom modules
") - style 45 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 45 fill:#d4e8fc,stroke:#94a2b0,color:#000000 46("
core.loadModuleFromPath
[Component: function]
Dynamically load an ESM
module from a path or module
specifier with security
validation
") - style 46 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 46 fill:#d4e8fc,stroke:#94a2b0,color:#000000 47("
core.getCliDir
[Component: function]
") - style 47 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 47 fill:#d4e8fc,stroke:#94a2b0,color:#000000 48("
core.expandTilde
[Component: function]
") - style 48 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 48 fill:#d4e8fc,stroke:#94a2b0,color:#000000 49("
core.resolveArchlettePath
[Component: function]
Core path resolver honoring
Archlette rules (no file
existence checks). - "~" ->
user home - "/" -> absolute -
else -> relative to CLI dir
") - style 49 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 49 fill:#d4e8fc,stroke:#94a2b0,color:#000000 50("
core.resolveModuleEntry
[Component: function]
Resolve a module entry by
probing: 1) Exact path 2)
With extensions: .ts then .js
3) If directory: index.ts
then index.js
") - style 50 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 50 fill:#d4e8fc,stroke:#94a2b0,color:#000000 51("
core.toFileUrl
[Component: function]
") - style 51 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 51 fill:#d4e8fc,stroke:#94a2b0,color:#000000 52("
core.writeFile
[Component: function]
Write content to a file,
creating parent directories
if needed.
") - style 52 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 52 fill:#d4e8fc,stroke:#94a2b0,color:#000000 53("
core.validatePathSecurity
[Component: function]
Validate path for security
issues
") - style 53 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 53 fill:#d4e8fc,stroke:#94a2b0,color:#000000 54("
core.resolveSecurePath
[Component: function]
Securely resolve a
user-provided path with
validation
") - style 54 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 54 fill:#d4e8fc,stroke:#94a2b0,color:#000000 55("
core.resolveUserContentPath
[Component: function]
Convenience function for
resolving user content paths
(themes, input files) Uses
'config-relative' strategy by
default
") - style 55 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 55 fill:#d4e8fc,stroke:#94a2b0,color:#000000 56("
core.resolvePluginPath
[Component: function]
Convenience function for
resolving plugin paths Uses
'cli-relative' strategy by
default
") - style 56 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 56 fill:#d4e8fc,stroke:#94a2b0,color:#000000 57("
core.getStageEntry
[Component: function]
") - style 57 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 57 fill:#d4e8fc,stroke:#94a2b0,color:#000000 58("
core.loadExtractorModule
[Component: function]
") - style 58 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 58 fill:#d4e8fc,stroke:#94a2b0,color:#000000 59("
core.loadValidatorModule
[Component: function]
") - style 59 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 59 fill:#d4e8fc,stroke:#94a2b0,color:#000000 60("
core.loadGeneratorModule
[Component: function]
") - style 60 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 60 fill:#d4e8fc,stroke:#94a2b0,color:#000000 61("
core.loadRendererModule
[Component: function]
") - style 61 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 61 fill:#d4e8fc,stroke:#94a2b0,color:#000000 62("
core.loadDocModule
[Component: function]
") - style 62 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 62 fill:#d4e8fc,stroke:#94a2b0,color:#000000 63("
core.getCacheDir
[Component: function]
Get the Archlette cache
directory
") - style 63 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 63 fill:#d4e8fc,stroke:#94a2b0,color:#000000 64("
core.ensureCacheDir
[Component: function]
Ensure cache directory exists
") - style 64 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 65("
core.commandExistsInPath
[Component: function]
Check if a command exists in
PATH
") - style 65 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 64 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 65("
core.commandExistsInPath
[Component: function]
Check if a command exists in
PATH Returns the full path if
found, null otherwise
") + style 65 fill:#d4e8fc,stroke:#94a2b0,color:#000000 66("
core.downloadFile
[Component: function]
Download a file from URL to
destination
") - style 66 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 66 fill:#d4e8fc,stroke:#94a2b0,color:#000000 67("
core.extractZip
[Component: function]
Extract a ZIP file (simple
extraction for Structurizr
CLI)
") - style 67 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 67 fill:#d4e8fc,stroke:#94a2b0,color:#000000 68("
core.makeExecutable
[Component: function]
Make file executable (Unix
only)
") - style 68 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 68 fill:#d4e8fc,stroke:#94a2b0,color:#000000 69("
core.downloadStructurizr
[Component: function]
Download and install
Structurizr CLI to cache
") - style 69 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 69 fill:#d4e8fc,stroke:#94a2b0,color:#000000 70("
core.downloadPlantUML
[Component: function]
Download and install PlantUML
to cache
") - style 70 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 70 fill:#d4e8fc,stroke:#94a2b0,color:#000000 71("
core.findStructurizrCLI
[Component: function]
Find or download Structurizr
CLI
") - style 71 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 72("
core.findPlantUML
[Component: function]
Find or download PlantUML JAR
") - style 72 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 73("
core.checkJava
[Component: function]
Verify Java is available
") - style 73 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 74("
core.requireJava
[Component: function]
Validate Java is installed
(throw if not)
") - style 74 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 75("
core.resolveConfig
[Component: function]
For each stage, resolve
includes/excludes for each
node: - If node omits
includes/excludes, inherit
from defaults. - Add
configBaseDir for resolving
config-relative paths
") - style 75 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 71 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 72("
core.downloadStructurizrLite
[Component: function]
Download and install
Structurizr Lite to cache
") + style 72 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 73("
core.findStructurizrLite
[Component: function]
Find or download Structurizr
Lite WAR file
") + style 73 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 74("
core.findPlantUML
[Component: function]
Find or download PlantUML JAR
") + style 74 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 75("
core.checkJava
[Component: function]
Verify Java is available
") + style 75 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 76("
core.requireJava
[Component: function]
Validate Java is installed
(throw if not)
") + style 76 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 77("
core.findMermaidCLI
[Component: function]
Find Mermaid CLI in system
PATH Note: Mermaid CLI is not
auto-downloaded. Users should
install it via npm: - Global:
npm install -g
") + style 77 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 78("
core.resolveConfig
[Component: function]
For each stage, resolve
includes/excludes for each
node: - If node omits
includes/excludes, inherit
from defaults. - Add
configBaseDir for resolving
config-relative paths
") + style 78 fill:#d4e8fc,stroke:#94a2b0,color:#000000 end end \ No newline at end of file diff --git a/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__docs.mmd b/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__docs.mmd index 558cebe..69f2cd3 100644 --- a/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__docs.mmd +++ b/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__docs.mmd @@ -1,24 +1,24 @@ -graph TB +graph LR linkStyle default fill:#ffffff - subgraph diagram ["Application - Application - Components"] + subgraph diagram [" "] style diagram fill:#ffffff,stroke:#ffffff - subgraph 8 ["Application"] + subgraph 8 [" "] style 8 fill:#ffffff,stroke:#2e6295,color:#2e6295 33("
docs.run
[Component: function]
Execute the documentation
stage
") - style 33 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 76("
docs.markdownDocs
[Component: function]
Generate markdown
documentation
") - style 76 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 77("
docs.findDiagramsForView
[Component: function]
Find diagram files for a
specific view type
") - style 77 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 78("
docs.findDiagramsForContainer
[Component: function]
Find component diagrams for a
specific container
") - style 78 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 79("
docs.findClassDiagramsForComponent
[Component: function]
Find class diagrams for a
specific component
") - style 79 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 80("
docs.sanitizeFileName
[Component: function]
") - style 80 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 33 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 79("
docs.markdownDocs
[Component: function]
Generate markdown
documentation
") + style 79 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 80("
docs.findDiagramsForView
[Component: function]
Find diagram files for a
specific view type
") + style 80 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 81("
docs.findDiagramsForContainer
[Component: function]
Find component diagrams for a
specific container
") + style 81 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 82("
docs.findClassDiagramsForComponent
[Component: function]
Find class diagrams for a
specific component
") + style 82 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 83("
docs.sanitizeFileName
[Component: function]
") + style 83 fill:#d4e8fc,stroke:#94a2b0,color:#000000 end end \ No newline at end of file diff --git a/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__extractors.mmd b/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__extractors.mmd index 7110363..beb1383 100644 --- a/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__extractors.mmd +++ b/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__extractors.mmd @@ -1,22 +1,22 @@ -graph TB +graph LR linkStyle default fill:#ffffff - subgraph diagram ["Application - Application - Components"] + subgraph diagram [" "] style diagram fill:#ffffff,stroke:#ffffff - subgraph 8 ["Application"] + subgraph 8 [" "] style 8 fill:#ffffff,stroke:#2e6295,color:#2e6295 25("
extractors.aggregateIRs
[Component: function]
Aggregate multiple
ArchletteIR objects into a
single unified IR
") - style 25 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 25 fill:#d4e8fc,stroke:#94a2b0,color:#000000 26("
extractors.deduplicateById
[Component: function]
Deduplicate array of entities
by their ID field
") - style 26 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 26 fill:#d4e8fc,stroke:#94a2b0,color:#000000 27("
extractors.deduplicateByName
[Component: function]
Deduplicate array of entities
by their name field
") - style 27 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 27 fill:#d4e8fc,stroke:#94a2b0,color:#000000 28("
extractors.deduplicateRelationships
[Component: function]
Deduplicate relationships by
source+destination+stereotype
combination
") - style 28 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 28 fill:#d4e8fc,stroke:#94a2b0,color:#000000 29("
extractors.run
[Component: function]
Execute the extraction stage
") - style 29 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 29 fill:#d4e8fc,stroke:#94a2b0,color:#000000 end end \ No newline at end of file diff --git a/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__generators.mmd b/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__generators.mmd index ced59eb..59de9f8 100644 --- a/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__generators.mmd +++ b/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__generators.mmd @@ -1,34 +1,34 @@ -graph TB +graph LR linkStyle default fill:#ffffff - subgraph diagram ["Application - Application - Components"] + subgraph diagram [" "] style diagram fill:#ffffff,stroke:#ffffff - subgraph 8 ["Application"] + subgraph 8 [" "] style 8 fill:#ffffff,stroke:#2e6295,color:#2e6295 31("
generators.run
[Component: function]
Execute the generation stage
") - style 31 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 86("
generators.loadDefaultTheme
[Component: function]
Load the default Structurizr
theme from templates
directory
") - style 86 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 87("
generators.structurizrGenerator
[Component: function]
Generate Structurizr DSL from
ArchletteIR
") - style 87 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 88("
generators.prepareContainerData
[Component: function]
Prepare container data with
components, code, and
relationships for template
") - style 88 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 89("
generators.prepareComponentView
[Component: function]
Prepare component view data
for template
") - style 89 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 90("
generators.prepareClassView
[Component: function]
Prepare class view data for
template
") - style 90 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 91("
generators.generateAllActorRelationships
[Component: function]
Generate all actor-related
relationships
") - style 91 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 92("
generators.generateUniqueCodeName
[Component: function]
Generate a unique name for a
code item to avoid naming
collisions
") - style 92 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 93("
generators.buildTechnologyString
[Component: function]
Build technology string from
relationship metadata
") - style 93 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 94("
generators.sanitizeId
[Component: function]
Sanitize ID for DSL (remove
special characters, convert
to valid identifier)
") - style 94 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 95("
generators.escapeString
[Component: function]
Escape special characters in
strings for DSL Structurizr
DSL doesn't support \ escape
sequences in strings, so we
replace newlines with spaces
for cleaner output.
") - style 95 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 31 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 89("
generators.loadDefaultTheme
[Component: function]
Load the default Structurizr
theme from templates
directory
") + style 89 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 90("
generators.structurizrGenerator
[Component: function]
Generate Structurizr DSL from
ArchletteIR
") + style 90 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 91("
generators.prepareContainerData
[Component: function]
Prepare container data with
components, code, and
relationships for template
") + style 91 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 92("
generators.prepareComponentView
[Component: function]
Prepare component view data
for template
") + style 92 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 93("
generators.prepareClassView
[Component: function]
Prepare class view data for
template
") + style 93 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 94("
generators.generateAllActorRelationships
[Component: function]
Generate all actor-related
relationships
") + style 94 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 95("
generators.generateUniqueCodeName
[Component: function]
Generate a unique name for a
code item to avoid naming
collisions
") + style 95 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 96("
generators.buildTechnologyString
[Component: function]
Build technology string from
relationship metadata
") + style 96 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 97("
generators.sanitizeId
[Component: function]
Sanitize ID for DSL (remove
special characters, convert
to valid identifier)
") + style 97 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 98("
generators.escapeString
[Component: function]
Escape special characters in
strings for DSL Structurizr
DSL doesn't support \ escape
sequences in strings, so we
replace newlines with spaces
for cleaner output.
") + style 98 fill:#d4e8fc,stroke:#94a2b0,color:#000000 end end \ No newline at end of file diff --git a/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__renderers.mmd b/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__renderers.mmd index eedb810..0d8e01e 100644 --- a/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__renderers.mmd +++ b/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__renderers.mmd @@ -1,18 +1,38 @@ -graph TB +graph LR linkStyle default fill:#ffffff - subgraph diagram ["Application - Application - Components"] + subgraph diagram [" "] style diagram fill:#ffffff,stroke:#ffffff - subgraph 8 ["Application"] + subgraph 8 [" "] style 8 fill:#ffffff,stroke:#2e6295,color:#2e6295 + 100("
renderers.plantumlRender
[Component: function]
Render PlantUML files to PNG
images
") + style 100 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 101("
renderers.structurizrExport
[Component: function]
Export Structurizr DSL to
PlantUML and/or Mermaid
formats
") + style 101 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 102("
renderers.findGraphviz
[Component: function]
Find Graphviz dot command in
PATH
") + style 102 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 103("
renderers.structurizrRender
[Component: function]
Render Structurizr DSL to
images using CLI DOT export +
Graphviz
") + style 103 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 104("
renderers.extractStylesBlock
[Component: function]
Extract styles block from
theme content using brace
counting
") + style 104 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 105("
renderers.removeBlock
[Component: function]
Remove a block from DSL
content using brace counting
") + style 105 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 106("
renderers.removeStylesBlock
[Component: function]
") + style 106 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 107("
renderers.removeBrandingBlock
[Component: function]
") + style 107 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 108("
renderers.escapeInvalidHtmlTags
[Component: function]
Escape all angle brackets
that aren't part of valid DOT
HTML tags. Handles cases
where Structurizr inserts /> for word-wrapping inside
other tag-like content (e.g.,
Strategy: 1. Find all valid
HTML tags using regex 2.
Escape all < and > that are
NOT part of those tags
") + style 108 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 109("
renderers.sanitizeDotContent
[Component: function]
Sanitize DOT file content for
Graphviz compatibility
Applies string replacements
only within label=<<...>>
content, preserving the DOT
structural syntax.
") + style 109 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 110("
renderers.sanitizeDotFiles
[Component: function]
Sanitize all DOT files in a
directory
") + style 110 fill:#d4e8fc,stroke:#94a2b0,color:#000000 32("
renderers.run
[Component: function]
Execute the rendering stage
") - style 32 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 96("
renderers.plantumlRender
[Component: function]
Render PlantUML files to PNG
images
") - style 96 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 97("
renderers.structurizrExport
[Component: function]
Export Structurizr DSL to
PlantUML and Mermaid formats
") - style 97 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 32 fill:#d4e8fc,stroke:#94a2b0,color:#000000 + 99("
renderers.mermaidRender
[Component: function]
Render Mermaid files to
images
") + style 99 fill:#d4e8fc,stroke:#94a2b0,color:#000000 end end \ No newline at end of file diff --git a/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__shared.mmd b/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__shared.mmd index 30509e0..df7ff87 100644 --- a/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__shared.mmd +++ b/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__shared.mmd @@ -1,14 +1,14 @@ -graph TB +graph LR linkStyle default fill:#ffffff - subgraph diagram ["Application - Application - Components"] + subgraph diagram [" "] style diagram fill:#ffffff,stroke:#ffffff - subgraph 8 ["Application"] + subgraph 8 [" "] style 8 fill:#ffffff,stroke:#2e6295,color:#2e6295 - 204("
shared.deduplicateRelationships
[Component: function]
Deduplicate relationships by
source+destination
combination - Excludes
self-referential
relationships (source ===
destination) - Merges
descriptions and stereotypes
with " | " separator when
duplicates are found -
Extracts imported names from
descriptions (removes
"imports " prefix) and keeps
only unique names - Returns
one relationship per unique
source+destination pair
") - style 204 fill:#85bbf0,stroke:#5d82a8,color:#000000 + 218("
shared.deduplicateRelationships
[Component: function]
Deduplicate relationships by
source+destination
combination - Excludes
self-referential
relationships (source ===
destination) - Merges
descriptions and stereotypes
with " | " separator when
duplicates are found -
Extracts imported names from
descriptions (removes
"imports " prefix) and keeps
only unique names - Returns
one relationship per unique
source+destination pair
") + style 218 fill:#d4e8fc,stroke:#94a2b0,color:#000000 end end \ No newline at end of file diff --git a/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__validators.mmd b/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__validators.mmd index 3d010d9..85909cc 100644 --- a/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__validators.mmd +++ b/docs/architecture/diagrams/mermaid/structurizr-Classes_default_container__validators.mmd @@ -1,16 +1,16 @@ -graph TB +graph LR linkStyle default fill:#ffffff - subgraph diagram ["Application - Application - Components"] + subgraph diagram [" "] style diagram fill:#ffffff,stroke:#ffffff - subgraph 8 ["Application"] + subgraph 8 [" "] style 8 fill:#ffffff,stroke:#2e6295,color:#2e6295 + 111("
validators.baseValidator
[Component: function]
Validates the IR against the
Zod schema. Throws if
invalid.
") + style 111 fill:#d4e8fc,stroke:#94a2b0,color:#000000 30("
validators.run
[Component: function]
Execute the validation stage
") - style 30 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 98("
validators.baseValidator
[Component: function]
Validates the IR against the
Zod schema. Throws if
invalid.
") - style 98 fill:#85bbf0,stroke:#5d82a8,color:#000000 + style 30 fill:#d4e8fc,stroke:#94a2b0,color:#000000 end end \ No newline at end of file diff --git a/docs/architecture/diagrams/mermaid/structurizr-Components_Application.mmd b/docs/architecture/diagrams/mermaid/structurizr-Components_Application.mmd index 96f1914..51946a7 100644 --- a/docs/architecture/diagrams/mermaid/structurizr-Components_Application.mmd +++ b/docs/architecture/diagrams/mermaid/structurizr-Components_Application.mmd @@ -1,7 +1,7 @@ -graph TB +graph LR linkStyle default fill:#ffffff - subgraph diagram ["Application - Application - Components"] + subgraph diagram [" "] style diagram fill:#ffffff,stroke:#ffffff 1["
User
[Person]
End user who runs archlette
commands
"] @@ -17,7 +17,7 @@ graph TB 6("
File System
[Software System]
The local file system for
caching downloaded tools.
") style 6 fill:#999999,stroke:#6b6b6b,color:#ffffff - subgraph 8 ["Application"] + subgraph 8 [" "] style 8 fill:#ffffff,stroke:#2e6295,color:#2e6295 10("
extractors
[Component: module]
ArchletteIR aggregation
utilities | Extraction stage
of the AAC pipeline
") @@ -26,7 +26,7 @@ graph TB style 11 fill:#85bbf0,stroke:#5d82a8,color:#000000 12("
generators
[Component: module]
Generation stage of the AAC
pipeline | Structurizr DSL
Generator (Template-based)
") style 12 fill:#85bbf0,stroke:#5d82a8,color:#000000 - 13("
renderers
[Component: module]
Render stage of the AAC
pipeline | PlantUML image
renderer | Structurizr DSL
export renderer
") + 13("
renderers
[Component: module]
Render stage of the AAC
pipeline | Mermaid image
renderer | PlantUML image
renderer | Structurizr DSL
export renderer | Structurizr
direct image renderer
") style 13 fill:#85bbf0,stroke:#5d82a8,color:#000000 14("
docs
[Component: module]
Documentation stage of the
AAC pipeline | Markdown
documentation generator
") style 14 fill:#85bbf0,stroke:#5d82a8,color:#000000 @@ -58,7 +58,7 @@ graph TB 10-- "
composed of cloudflare
wrangler extractor
" -->19 11-- "
Provides IR types, validation
schemas, and module loading |
zArchletteIR |
ArchletteValidator
" -->15 12-- "
Provides IR types, path
resolution, and module
loading | ArchletteIR |
Container | Component |
CodeItem | Relationship |
ResolvedStageNode |
VIEW_NAMES |
resolveUserContentPath
" -->15 - 13-- "
Provides types, module
loading, and tool management
| PipelineContext |
findPlantUML | requireJava |
resolveArchlettePath |
findStructurizrCLI
" -->15 + 13-- "
Provides types, module
loading, and tool management
| PipelineContext |
ResolvedStageNode |
findMermaidCLI |
resolveArchlettePath |
findPlantUML | requireJava |
findStructurizrCLI |
commandExistsInPath
" -->15 14-- "
Provides types, module
loading, and path resolution
| PipelineContext | Logger |
RendererOutput | Component |
resolveArchlettePath
" -->15 16-- "
ResolvedStageNode |
ArchletteIR | PipelineContext
| IR_VERSION |
resolveSecurePath |
createLogger | sanitizeId |
CodeItem | System |
Relationship | Component |
Actor | Container | TAGS |
DEFAULT_CONTAINER_ID |
nameToId
" -->15 17-- "
ResolvedStageNode |
ArchletteIR | PipelineContext
| resolveSecurePath |
createLogger | sanitizeId |
CodeItem | System |
Relationship | Component |
Actor | TAGS |
DEFAULT_CONTAINER_ID |
IR_VERSION | nameToId
" -->15 diff --git a/docs/architecture/diagrams/mermaid/structurizr-Containers.mmd b/docs/architecture/diagrams/mermaid/structurizr-Containers.mmd index 9bd0c1b..127c237 100644 --- a/docs/architecture/diagrams/mermaid/structurizr-Containers.mmd +++ b/docs/architecture/diagrams/mermaid/structurizr-Containers.mmd @@ -1,7 +1,7 @@ -graph TB +graph LR linkStyle default fill:#ffffff - subgraph diagram ["Application - Containers"] + subgraph diagram [" "] style diagram fill:#ffffff,stroke:#ffffff 1["
User
[Person]
End user who runs archlette
commands
"] @@ -17,7 +17,7 @@ graph TB 6("
File System
[Software System]
The local file system for
caching downloaded tools.
") style 6 fill:#999999,stroke:#6b6b6b,color:#ffffff - subgraph 7 ["Application"] + subgraph 7 [" "] style 7 fill:#ffffff,stroke:#0b4884,color:#0b4884 8("
Application
[Container: Application]
Main application container
") diff --git a/docs/architecture/diagrams/mermaid/structurizr-SystemContext.mmd b/docs/architecture/diagrams/mermaid/structurizr-SystemContext.mmd index 4179476..2c51573 100644 --- a/docs/architecture/diagrams/mermaid/structurizr-SystemContext.mmd +++ b/docs/architecture/diagrams/mermaid/structurizr-SystemContext.mmd @@ -1,7 +1,7 @@ -graph TB +graph LR linkStyle default fill:#ffffff - subgraph diagram ["Application - System Context"] + subgraph diagram [" "] style diagram fill:#ffffff,stroke:#ffffff 1["
User
[Person]
End user who runs archlette
commands
"] diff --git a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__basic_astro-key.puml b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__basic_astro-key.puml index da75bcd..d2ad682 100644 --- a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__basic_astro-key.puml +++ b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__basic_astro-key.puml @@ -18,12 +18,12 @@ skinparam rectangle<<_transparent>> { } skinparam rectangle<<1>> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 } -rectangle "==Component" <<1>> +rectangle "==Component, Code" <<1>> @enduml \ No newline at end of file diff --git a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__basic_astro.puml b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__basic_astro.puml index 36957a9..6e3503c 100644 --- a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__basic_astro.puml +++ b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__basic_astro.puml @@ -2,9 +2,9 @@ set separator none title Application - Application - Components -top to bottom direction -skinparam ranksep 60 -skinparam nodesep 30 +left to right direction +skinparam ranksep 20 +skinparam nodesep 10 skinparam { arrowFontSize 10 @@ -17,177 +17,177 @@ skinparam { hide stereotype skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } @@ -198,6 +198,7 @@ skinparam rectangle<> { } rectangle "Application\n[Container: Application]" <> { + rectangle "==basic-astro.extractCodeFromFrontmatter\n[Component: function]\n\nExtract TypeScript/JavaScript code from Astro frontmatter Parses the frontmatter section (code between --- markers) as TypeScript and extracts code elements using the basic-node AST extractors: - Classes and their methods - Functions (both regular and arrow functions) - Type aliases (type X = ...) - TypeScript interfaces Returns empty result if frontmatter is empty or parsing fails (errors are logged). Graceful error handling ensures one malformed Astro file doesn't break the extraction pipeline." <> as Application.Application.basicastroextractCodeFromFrontmatter rectangle "==basic-astro.createSyntheticRenderFunction\n[Component: function]\n\nCreate a synthetic render function for an Astro component Every Astro component is fundamentally a server-side render function that: 1. Receives props (if Props interface is defined) 2. Processes the component logic (frontmatter code) 3. Renders the template to HTML 4. Returns an HTML string Since Astro's compiler doesn't explicitly define this, we create a synthetic function to represent the component's executable behavior in the IR. The function is named after the file (without .astro extension): - Button.astro → function Button() - index.astro → function index() - settings/Profile.astro → function Profile()" <> as Application.Application.basicastrocreateSyntheticRenderFunction rectangle "==basic-astro.extractJSDocBlocks\n[Component: function]\n\nExtract all JSDoc comment blocks from source code Matches /** ... *\\/ style comments and parses their tags" <> as Application.Application.basicastroextractJSDocBlocks rectangle "==basic-astro.parseJSDocBlock\n[Component: function]\n\nParse a single JSDoc comment block into description and tags" <> as Application.Application.basicastroparseJSDocBlock @@ -222,7 +223,6 @@ rectangle "Application\n[Container: Application]" <[Component: function]\n\nMap a class to code items (class + methods)" <> as Application.Application.basicastromapClassToCodeItems rectangle "==basic-astro.mapFunctionToCodeItem\n[Component: function]\n\nMap a function to a code item" <> as Application.Application.basicastromapFunctionToCodeItem rectangle "==basic-astro.basicAstroExtractor\n[Component: function]\n\nExtract architecture information from an Astro codebase" <> as Application.Application.basicastrobasicAstroExtractor - rectangle "==basic-astro.extractCodeFromFrontmatter\n[Component: function]\n\nExtract TypeScript/JavaScript code from Astro frontmatter Parses the frontmatter section (code between --- markers) as TypeScript and extracts code elements using the basic-node AST extractors: - Classes and their methods - Functions (both regular and arrow functions) - Type aliases (type X = ...) - TypeScript interfaces Returns empty result if frontmatter is empty or parsing fails (errors are logged). Graceful error handling ensures one malformed Astro file doesn't break the extraction pipeline." <> as Application.Application.basicastroextractCodeFromFrontmatter } @enduml \ No newline at end of file diff --git a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__basic_node-key.puml b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__basic_node-key.puml index da75bcd..d2ad682 100644 --- a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__basic_node-key.puml +++ b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__basic_node-key.puml @@ -18,12 +18,12 @@ skinparam rectangle<<_transparent>> { } skinparam rectangle<<1>> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 } -rectangle "==Component" <<1>> +rectangle "==Component, Code" <<1>> @enduml \ No newline at end of file diff --git a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__basic_node.puml b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__basic_node.puml index d1420e7..d3021b9 100644 --- a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__basic_node.puml +++ b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__basic_node.puml @@ -2,9 +2,9 @@ set separator none title Application - Application - Components -top to bottom direction -skinparam ranksep 60 -skinparam nodesep 30 +left to right direction +skinparam ranksep 20 +skinparam nodesep 10 skinparam { arrowFontSize 10 @@ -17,310 +17,310 @@ skinparam { hide stereotype skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } diff --git a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__basic_python-key.puml b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__basic_python-key.puml index da75bcd..d2ad682 100644 --- a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__basic_python-key.puml +++ b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__basic_python-key.puml @@ -18,12 +18,12 @@ skinparam rectangle<<_transparent>> { } skinparam rectangle<<1>> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 } -rectangle "==Component" <<1>> +rectangle "==Component, Code" <<1>> @enduml \ No newline at end of file diff --git a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__basic_python.puml b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__basic_python.puml index 80d6cab..8cb4da3 100644 --- a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__basic_python.puml +++ b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__basic_python.puml @@ -2,9 +2,9 @@ set separator none title Application - Application - Components -top to bottom direction -skinparam ranksep 60 -skinparam nodesep 30 +left to right direction +skinparam ranksep 20 +skinparam nodesep 10 skinparam { arrowFontSize 10 @@ -17,198 +17,198 @@ skinparam { hide stereotype skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } diff --git a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__basic_wrangler-key.puml b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__basic_wrangler-key.puml index da75bcd..d2ad682 100644 --- a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__basic_wrangler-key.puml +++ b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__basic_wrangler-key.puml @@ -18,12 +18,12 @@ skinparam rectangle<<_transparent>> { } skinparam rectangle<<1>> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 } -rectangle "==Component" <<1>> +rectangle "==Component, Code" <<1>> @enduml \ No newline at end of file diff --git a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__basic_wrangler.puml b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__basic_wrangler.puml index 6cb2755..4d48d44 100644 --- a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__basic_wrangler.puml +++ b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__basic_wrangler.puml @@ -2,9 +2,9 @@ set separator none title Application - Application - Components -top to bottom direction -skinparam ranksep 60 -skinparam nodesep 30 +left to right direction +skinparam ranksep 20 +skinparam nodesep 10 skinparam { arrowFontSize 10 @@ -17,93 +17,100 @@ skinparam { hide stereotype skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 + roundCorner 20 + shadowing false +} +skinparam rectangle<> { + BackgroundColor #d4e8fc + FontColor #000000 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } @@ -119,7 +126,8 @@ rectangle "Application\n[Container: Application]" <[Component: function]\n\nExtract containers from wrangler configurations Creates one container per wrangler.toml file. Each container represents a Cloudflare Worker (if main exists) or other Cloudflare service." <> as Application.Application.basic_wranglerextractContainers rectangle "==basic_wrangler.deriveContainerType\n[Component: function]\n\nDerive container type from wrangler configuration Logic: - If 'main' field exists → Cloudflare Worker - Otherwise → Cloudflare Service (generic)" <> as Application.Application.basic_wranglerderiveContainerType rectangle "==basic_wrangler.extractDeploymentsAndInstances\n[Component: function]\n\nExtract deployments and container instances Creates: - One deployment per environment - Container instances for each container in each environment" <> as Application.Application.basic_wranglerextractDeploymentsAndInstances - rectangle "==basic_wrangler.extractContainerRelationships\n[Component: function]\n\nExtract container relationships from service bindings Creates logical dependencies between containers based on service bindings. Deduplicates relationships across all environments." <> as Application.Application.basic_wranglerextractContainerRelationships + rectangle "==basic_wrangler.findMatchingContainer\n[Component: function]\n\nSmart lookup to find matching container for a service name Tries exact match first, then fuzzy matching with common environment suffix removal." <> as Application.Application.basic_wranglerfindMatchingContainer + rectangle "==basic_wrangler.extractContainerRelationships\n[Component: function]\n\nExtract container relationships from service bindings Creates logical dependencies between containers based on service bindings. Uses smart lookup to match service names to actual containers. Deduplicates relationships across all environments." <> as Application.Application.basic_wranglerextractContainerRelationships rectangle "==basic_wrangler.extractDeploymentRelationships\n[Component: function]\n\nExtract deployment relationships from container instances Creates physical instance-to-instance relationships based on service bindings. Each relationship represents an actual runtime dependency in a specific environment." <> as Application.Application.basic_wranglerextractDeploymentRelationships rectangle "==basic_wrangler.extractDescription\n[Component: function]\n\nExtract description from" <> as Application.Application.basic_wranglerextractDescription rectangle "==basic_wrangler.parseWranglerFile\n[Component: function]\n\nParse a wrangler.toml file" <> as Application.Application.basic_wranglerparseWranglerFile diff --git a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__cli-key.puml b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__cli-key.puml index da75bcd..d2ad682 100644 --- a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__cli-key.puml +++ b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__cli-key.puml @@ -18,12 +18,12 @@ skinparam rectangle<<_transparent>> { } skinparam rectangle<<1>> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 } -rectangle "==Component" <<1>> +rectangle "==Component, Code" <<1>> @enduml \ No newline at end of file diff --git a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__cli.puml b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__cli.puml index d9ca253..f8c9b26 100644 --- a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__cli.puml +++ b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__cli.puml @@ -2,9 +2,9 @@ set separator none title Application - Application - Components -top to bottom direction -skinparam ranksep 60 -skinparam nodesep 30 +left to right direction +skinparam ranksep 20 +skinparam nodesep 10 skinparam { arrowFontSize 10 @@ -17,30 +17,30 @@ skinparam { hide stereotype skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } diff --git a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__core-key.puml b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__core-key.puml index da75bcd..d2ad682 100644 --- a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__core-key.puml +++ b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__core-key.puml @@ -18,12 +18,12 @@ skinparam rectangle<<_transparent>> { } skinparam rectangle<<1>> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 } -rectangle "==Component" <<1>> +rectangle "==Component, Code" <<1>> @enduml \ No newline at end of file diff --git a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__core.puml b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__core.puml index 0498458..7d7b3a3 100644 --- a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__core.puml +++ b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__core.puml @@ -2,9 +2,9 @@ set separator none title Application - Application - Components -top to bottom direction -skinparam ranksep 60 -skinparam nodesep 30 +left to right direction +skinparam ranksep 20 +skinparam nodesep 10 skinparam { arrowFontSize 10 @@ -17,296 +17,317 @@ skinparam { hide stereotype skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 + roundCorner 20 + shadowing false +} +skinparam rectangle<> { + BackgroundColor #d4e8fc + FontColor #000000 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc + FontColor #000000 + BorderColor #94a2b0 + roundCorner 20 + shadowing false +} +skinparam rectangle<> { + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc + FontColor #000000 + BorderColor #94a2b0 + roundCorner 20 + shadowing false +} +skinparam rectangle<> { + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } @@ -348,16 +369,19 @@ rectangle "Application\n[Container: Application]" <[Component: function]" <> as Application.Application.coreloadDocModule rectangle "==core.getCacheDir\n[Component: function]\n\nGet the Archlette cache directory" <> as Application.Application.coregetCacheDir rectangle "==core.ensureCacheDir\n[Component: function]\n\nEnsure cache directory exists" <> as Application.Application.coreensureCacheDir - rectangle "==core.commandExistsInPath\n[Component: function]\n\nCheck if a command exists in PATH" <> as Application.Application.corecommandExistsInPath + rectangle "==core.commandExistsInPath\n[Component: function]\n\nCheck if a command exists in PATH Returns the full path if found, null otherwise" <> as Application.Application.corecommandExistsInPath rectangle "==core.downloadFile\n[Component: function]\n\nDownload a file from URL to destination" <> as Application.Application.coredownloadFile rectangle "==core.extractZip\n[Component: function]\n\nExtract a ZIP file (simple extraction for Structurizr CLI)" <> as Application.Application.coreextractZip rectangle "==core.makeExecutable\n[Component: function]\n\nMake file executable (Unix only)" <> as Application.Application.coremakeExecutable rectangle "==core.downloadStructurizr\n[Component: function]\n\nDownload and install Structurizr CLI to cache" <> as Application.Application.coredownloadStructurizr rectangle "==core.downloadPlantUML\n[Component: function]\n\nDownload and install PlantUML to cache" <> as Application.Application.coredownloadPlantUML rectangle "==core.findStructurizrCLI\n[Component: function]\n\nFind or download Structurizr CLI" <> as Application.Application.corefindStructurizrCLI + rectangle "==core.downloadStructurizrLite\n[Component: function]\n\nDownload and install Structurizr Lite to cache" <> as Application.Application.coredownloadStructurizrLite + rectangle "==core.findStructurizrLite\n[Component: function]\n\nFind or download Structurizr Lite WAR file" <> as Application.Application.corefindStructurizrLite rectangle "==core.findPlantUML\n[Component: function]\n\nFind or download PlantUML JAR" <> as Application.Application.corefindPlantUML rectangle "==core.checkJava\n[Component: function]\n\nVerify Java is available" <> as Application.Application.corecheckJava rectangle "==core.requireJava\n[Component: function]\n\nValidate Java is installed (throw if not)" <> as Application.Application.corerequireJava + rectangle "==core.findMermaidCLI\n[Component: function]\n\nFind Mermaid CLI in system PATH Note: Mermaid CLI is not auto-downloaded. Users should install it via npm: - Global: npm install -g" <> as Application.Application.corefindMermaidCLI rectangle "==core.resolveConfig\n[Component: function]\n\nFor each stage, resolve includes/excludes for each node: - If node omits includes/excludes, inherit from defaults. - Add configBaseDir for resolving config-relative paths" <> as Application.Application.coreresolveConfig } diff --git a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__docs-key.puml b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__docs-key.puml index da75bcd..d2ad682 100644 --- a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__docs-key.puml +++ b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__docs-key.puml @@ -18,12 +18,12 @@ skinparam rectangle<<_transparent>> { } skinparam rectangle<<1>> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 } -rectangle "==Component" <<1>> +rectangle "==Component, Code" <<1>> @enduml \ No newline at end of file diff --git a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__docs.puml b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__docs.puml index b8a1756..7f6ed1c 100644 --- a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__docs.puml +++ b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__docs.puml @@ -2,9 +2,9 @@ set separator none title Application - Application - Components -top to bottom direction -skinparam ranksep 60 -skinparam nodesep 30 +left to right direction +skinparam ranksep 20 +skinparam nodesep 10 skinparam { arrowFontSize 10 @@ -17,44 +17,44 @@ skinparam { hide stereotype skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } diff --git a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__extractors-key.puml b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__extractors-key.puml index da75bcd..d2ad682 100644 --- a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__extractors-key.puml +++ b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__extractors-key.puml @@ -18,12 +18,12 @@ skinparam rectangle<<_transparent>> { } skinparam rectangle<<1>> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 } -rectangle "==Component" <<1>> +rectangle "==Component, Code" <<1>> @enduml \ No newline at end of file diff --git a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__extractors.puml b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__extractors.puml index 765091f..1d4d649 100644 --- a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__extractors.puml +++ b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__extractors.puml @@ -2,9 +2,9 @@ set separator none title Application - Application - Components -top to bottom direction -skinparam ranksep 60 -skinparam nodesep 30 +left to right direction +skinparam ranksep 20 +skinparam nodesep 10 skinparam { arrowFontSize 10 @@ -17,37 +17,37 @@ skinparam { hide stereotype skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } diff --git a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__generators-key.puml b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__generators-key.puml index da75bcd..d2ad682 100644 --- a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__generators-key.puml +++ b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__generators-key.puml @@ -18,12 +18,12 @@ skinparam rectangle<<_transparent>> { } skinparam rectangle<<1>> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 } -rectangle "==Component" <<1>> +rectangle "==Component, Code" <<1>> @enduml \ No newline at end of file diff --git a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__generators.puml b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__generators.puml index bf12306..786e51d 100644 --- a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__generators.puml +++ b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__generators.puml @@ -2,9 +2,9 @@ set separator none title Application - Application - Components -top to bottom direction -skinparam ranksep 60 -skinparam nodesep 30 +left to right direction +skinparam ranksep 20 +skinparam nodesep 10 skinparam { arrowFontSize 10 @@ -17,79 +17,79 @@ skinparam { hide stereotype skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } diff --git a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__renderers-key.puml b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__renderers-key.puml index da75bcd..d2ad682 100644 --- a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__renderers-key.puml +++ b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__renderers-key.puml @@ -18,12 +18,12 @@ skinparam rectangle<<_transparent>> { } skinparam rectangle<<1>> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 } -rectangle "==Component" <<1>> +rectangle "==Component, Code" <<1>> @enduml \ No newline at end of file diff --git a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__renderers.puml b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__renderers.puml index 1eb8eb7..4a3b932 100644 --- a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__renderers.puml +++ b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__renderers.puml @@ -2,9 +2,9 @@ set separator none title Application - Application - Components -top to bottom direction -skinparam ranksep 60 -skinparam nodesep 30 +left to right direction +skinparam ranksep 20 +skinparam nodesep 10 skinparam { arrowFontSize 10 @@ -16,24 +16,94 @@ skinparam { hide stereotype +skinparam rectangle<> { + BackgroundColor #d4e8fc + FontColor #000000 + BorderColor #94a2b0 + roundCorner 20 + shadowing false +} +skinparam rectangle<> { + BackgroundColor #d4e8fc + FontColor #000000 + BorderColor #94a2b0 + roundCorner 20 + shadowing false +} +skinparam rectangle<> { + BackgroundColor #d4e8fc + FontColor #000000 + BorderColor #94a2b0 + roundCorner 20 + shadowing false +} +skinparam rectangle<> { + BackgroundColor #d4e8fc + FontColor #000000 + BorderColor #94a2b0 + roundCorner 20 + shadowing false +} skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc + FontColor #000000 + BorderColor #94a2b0 + roundCorner 20 + shadowing false +} +skinparam rectangle<> { + BackgroundColor #d4e8fc + FontColor #000000 + BorderColor #94a2b0 + roundCorner 20 + shadowing false +} +skinparam rectangle<> { + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 + roundCorner 20 + shadowing false +} +skinparam rectangle<> { + BackgroundColor #d4e8fc + FontColor #000000 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc + FontColor #000000 + BorderColor #94a2b0 + roundCorner 20 + shadowing false +} +skinparam rectangle<> { + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 + roundCorner 20 + shadowing false +} +skinparam rectangle<> { + BackgroundColor #d4e8fc + FontColor #000000 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc + FontColor #000000 + BorderColor #94a2b0 + roundCorner 20 + shadowing false +} +skinparam rectangle<> { + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } @@ -44,9 +114,19 @@ skinparam rectangle<> { } rectangle "Application\n[Container: Application]" <> { - rectangle "==renderers.run\n[Component: function]\n\nExecute the rendering stage" <> as Application.Application.renderersrun rectangle "==renderers.plantumlRender\n[Component: function]\n\nRender PlantUML files to PNG images" <> as Application.Application.renderersplantumlRender - rectangle "==renderers.structurizrExport\n[Component: function]\n\nExport Structurizr DSL to PlantUML and Mermaid formats" <> as Application.Application.renderersstructurizrExport + rectangle "==renderers.structurizrExport\n[Component: function]\n\nExport Structurizr DSL to PlantUML and/or Mermaid formats" <> as Application.Application.renderersstructurizrExport + rectangle "==renderers.findGraphviz\n[Component: function]\n\nFind Graphviz dot command in PATH" <> as Application.Application.renderersfindGraphviz + rectangle "==renderers.structurizrRender\n[Component: function]\n\nRender Structurizr DSL to images using CLI DOT export + Graphviz" <> as Application.Application.renderersstructurizrRender + rectangle "==renderers.extractStylesBlock\n[Component: function]\n\nExtract styles block from theme content using brace counting" <> as Application.Application.renderersextractStylesBlock + rectangle "==renderers.removeBlock\n[Component: function]\n\nRemove a block from DSL content using brace counting" <> as Application.Application.renderersremoveBlock + rectangle "==renderers.removeStylesBlock\n[Component: function]" <> as Application.Application.renderersremoveStylesBlock + rectangle "==renderers.removeBrandingBlock\n[Component: function]" <> as Application.Application.renderersremoveBrandingBlock + rectangle "==renderers.escapeInvalidHtmlTags\n[Component: function]\n\nEscape all angle brackets that aren't part of valid DOT HTML tags. Handles cases where Structurizr inserts
for word-wrapping inside other tag-like content (e.g., that are NOT part of those tags" <> as Application.Application.renderersescapeInvalidHtmlTags + rectangle "==renderers.sanitizeDotContent\n[Component: function]\n\nSanitize DOT file content for Graphviz compatibility Applies string replacements only within label=<<...>> content, preserving the DOT structural syntax." <> as Application.Application.rendererssanitizeDotContent + rectangle "==renderers.sanitizeDotFiles\n[Component: function]\n\nSanitize all DOT files in a directory" <> as Application.Application.rendererssanitizeDotFiles + rectangle "==renderers.run\n[Component: function]\n\nExecute the rendering stage" <> as Application.Application.renderersrun + rectangle "==renderers.mermaidRender\n[Component: function]\n\nRender Mermaid files to images" <> as Application.Application.renderersmermaidRender } @enduml \ No newline at end of file diff --git a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__shared-key.puml b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__shared-key.puml index da75bcd..d2ad682 100644 --- a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__shared-key.puml +++ b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__shared-key.puml @@ -18,12 +18,12 @@ skinparam rectangle<<_transparent>> { } skinparam rectangle<<1>> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 } -rectangle "==Component" <<1>> +rectangle "==Component, Code" <<1>> @enduml \ No newline at end of file diff --git a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__shared.puml b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__shared.puml index ac7a8fc..efec7f4 100644 --- a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__shared.puml +++ b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__shared.puml @@ -2,9 +2,9 @@ set separator none title Application - Application - Components -top to bottom direction -skinparam ranksep 60 -skinparam nodesep 30 +left to right direction +skinparam ranksep 20 +skinparam nodesep 10 skinparam { arrowFontSize 10 @@ -17,9 +17,9 @@ skinparam { hide stereotype skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } diff --git a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__validators-key.puml b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__validators-key.puml index da75bcd..d2ad682 100644 --- a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__validators-key.puml +++ b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__validators-key.puml @@ -18,12 +18,12 @@ skinparam rectangle<<_transparent>> { } skinparam rectangle<<1>> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 } -rectangle "==Component" <<1>> +rectangle "==Component, Code" <<1>> @enduml \ No newline at end of file diff --git a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__validators.puml b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__validators.puml index 79a9d29..f484bbd 100644 --- a/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__validators.puml +++ b/docs/architecture/diagrams/plantuml/structurizr-Classes_default_container__validators.puml @@ -2,9 +2,9 @@ set separator none title Application - Application - Components -top to bottom direction -skinparam ranksep 60 -skinparam nodesep 30 +left to right direction +skinparam ranksep 20 +skinparam nodesep 10 skinparam { arrowFontSize 10 @@ -17,16 +17,16 @@ skinparam { hide stereotype skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } skinparam rectangle<> { - BackgroundColor #85bbf0 + BackgroundColor #d4e8fc FontColor #000000 - BorderColor #5d82a8 + BorderColor #94a2b0 roundCorner 20 shadowing false } @@ -37,8 +37,8 @@ skinparam rectangle<> { } rectangle "Application\n[Container: Application]" <> { - rectangle "==validators.run\n[Component: function]\n\nExecute the validation stage" <> as Application.Application.validatorsrun rectangle "==validators.baseValidator\n[Component: function]\n\nValidates the IR against the Zod schema. Throws if invalid." <> as Application.Application.validatorsbaseValidator + rectangle "==validators.run\n[Component: function]\n\nExecute the validation stage" <> as Application.Application.validatorsrun } @enduml \ No newline at end of file diff --git a/docs/architecture/diagrams/plantuml/structurizr-Components_Application.puml b/docs/architecture/diagrams/plantuml/structurizr-Components_Application.puml index c5bba08..bec8dcb 100644 --- a/docs/architecture/diagrams/plantuml/structurizr-Components_Application.puml +++ b/docs/architecture/diagrams/plantuml/structurizr-Components_Application.puml @@ -2,9 +2,9 @@ set separator none title Application - Application - Components -top to bottom direction -skinparam ranksep 60 -skinparam nodesep 30 +left to right direction +skinparam ranksep 20 +skinparam nodesep 10 skinparam { arrowFontSize 10 @@ -158,7 +158,7 @@ rectangle "Application\n[Container: Application]" <[Component: module]\n\nArchletteIR aggregation utilities | Extraction stage of the AAC pipeline" <> as Application.Application.extractors rectangle "==validators\n[Component: module]\n\nValidation stage of the AAC pipeline | Base IR validator for Archlette pipeline" <> as Application.Application.validators rectangle "==generators\n[Component: module]\n\nGeneration stage of the AAC pipeline | Structurizr DSL Generator (Template-based)" <> as Application.Application.generators - rectangle "==renderers\n[Component: module]\n\nRender stage of the AAC pipeline | PlantUML image renderer | Structurizr DSL export renderer" <> as Application.Application.renderers + rectangle "==renderers\n[Component: module]\n\nRender stage of the AAC pipeline | Mermaid image renderer | PlantUML image renderer | Structurizr DSL export renderer | Structurizr direct image renderer" <> as Application.Application.renderers rectangle "==docs\n[Component: module]\n\nDocumentation stage of the AAC pipeline | Markdown documentation generator" <> as Application.Application.docs rectangle "==core\n[Component: module]\n\nDynamic ESM module loader | Component inferred from directory: core | Stage module interfaces for the AAC pipeline | Stage module loaders | Tool management for external rendering tools | Architecture-as-Code (AAC) configuration types and schemas | Archlette Intermediate Representation (IR) types and schemas | Core pipeline types" <> as Application.Application.core rectangle "==basic-astro\n[Component: module]\n\nAstro component extractor" <> as Application.Application.basicastro @@ -181,7 +181,7 @@ Application.Application.extractors -[#707070,thickness=2]-> Application.Applicat Application.Application.extractors -[#707070,thickness=2]-> Application.Application.basic_wrangler : "composed of cloudflare wrangler extractor" Application.Application.validators -[#707070,thickness=2]-> Application.Application.core : "Provides IR types, validation schemas, and module loading | zArchletteIR | ArchletteValidator" Application.Application.generators -[#707070,thickness=2]-> Application.Application.core : "Provides IR types, path resolution, and module loading | ArchletteIR | Container | Component | CodeItem | Relationship | ResolvedStageNode | VIEW_NAMES | resolveUserContentPath" -Application.Application.renderers -[#707070,thickness=2]-> Application.Application.core : "Provides types, module loading, and tool management | PipelineContext | findPlantUML | requireJava | resolveArchlettePath | findStructurizrCLI" +Application.Application.renderers -[#707070,thickness=2]-> Application.Application.core : "Provides types, module loading, and tool management | PipelineContext | ResolvedStageNode | findMermaidCLI | resolveArchlettePath | findPlantUML | requireJava | findStructurizrCLI | commandExistsInPath" Application.Application.docs -[#707070,thickness=2]-> Application.Application.core : "Provides types, module loading, and path resolution | PipelineContext | Logger | RendererOutput | Component | resolveArchlettePath" Application.Application.basicastro -[#707070,thickness=2]-> Application.Application.core : "ResolvedStageNode | ArchletteIR | PipelineContext | IR_VERSION | resolveSecurePath | createLogger | sanitizeId | CodeItem | System | Relationship | Component | Actor | Container | TAGS | DEFAULT_CONTAINER_ID | nameToId" Application.Application.basic_node -[#707070,thickness=2]-> Application.Application.core : "ResolvedStageNode | ArchletteIR | PipelineContext | resolveSecurePath | createLogger | sanitizeId | CodeItem | System | Relationship | Component | Actor | TAGS | DEFAULT_CONTAINER_ID | IR_VERSION | nameToId" diff --git a/docs/architecture/diagrams/plantuml/structurizr-Containers.puml b/docs/architecture/diagrams/plantuml/structurizr-Containers.puml index 266f0f3..6d58608 100644 --- a/docs/architecture/diagrams/plantuml/structurizr-Containers.puml +++ b/docs/architecture/diagrams/plantuml/structurizr-Containers.puml @@ -2,9 +2,9 @@ set separator none title Application - Containers -top to bottom direction -skinparam ranksep 60 -skinparam nodesep 30 +left to right direction +skinparam ranksep 20 +skinparam nodesep 10 skinparam { arrowFontSize 10 diff --git a/docs/architecture/diagrams/plantuml/structurizr-SystemContext.puml b/docs/architecture/diagrams/plantuml/structurizr-SystemContext.puml index 413c9c1..929eab5 100644 --- a/docs/architecture/diagrams/plantuml/structurizr-SystemContext.puml +++ b/docs/architecture/diagrams/plantuml/structurizr-SystemContext.puml @@ -2,9 +2,9 @@ set separator none title Application - System Context -top to bottom direction -skinparam ranksep 60 -skinparam nodesep 30 +left to right direction +skinparam ranksep 20 +skinparam nodesep 10 skinparam { arrowFontSize 10 diff --git a/docs/architecture/diagrams/structurizr-Classes_default_container__basic_astro-key.png b/docs/architecture/diagrams/structurizr-Classes_default_container__basic_astro-key.png index d4d2249..5847cb9 100644 Binary files a/docs/architecture/diagrams/structurizr-Classes_default_container__basic_astro-key.png and b/docs/architecture/diagrams/structurizr-Classes_default_container__basic_astro-key.png differ diff --git a/docs/architecture/diagrams/structurizr-Classes_default_container__basic_astro.png b/docs/architecture/diagrams/structurizr-Classes_default_container__basic_astro.png index c68a764..1a718b3 100644 Binary files a/docs/architecture/diagrams/structurizr-Classes_default_container__basic_astro.png and b/docs/architecture/diagrams/structurizr-Classes_default_container__basic_astro.png differ diff --git a/docs/architecture/diagrams/structurizr-Classes_default_container__basic_node-key.png b/docs/architecture/diagrams/structurizr-Classes_default_container__basic_node-key.png index d4d2249..5847cb9 100644 Binary files a/docs/architecture/diagrams/structurizr-Classes_default_container__basic_node-key.png and b/docs/architecture/diagrams/structurizr-Classes_default_container__basic_node-key.png differ diff --git a/docs/architecture/diagrams/structurizr-Classes_default_container__basic_node.png b/docs/architecture/diagrams/structurizr-Classes_default_container__basic_node.png index 569cc69..492cbe2 100644 Binary files a/docs/architecture/diagrams/structurizr-Classes_default_container__basic_node.png and b/docs/architecture/diagrams/structurizr-Classes_default_container__basic_node.png differ diff --git a/docs/architecture/diagrams/structurizr-Classes_default_container__basic_python-key.png b/docs/architecture/diagrams/structurizr-Classes_default_container__basic_python-key.png index d4d2249..5847cb9 100644 Binary files a/docs/architecture/diagrams/structurizr-Classes_default_container__basic_python-key.png and b/docs/architecture/diagrams/structurizr-Classes_default_container__basic_python-key.png differ diff --git a/docs/architecture/diagrams/structurizr-Classes_default_container__basic_python.png b/docs/architecture/diagrams/structurizr-Classes_default_container__basic_python.png index 4cc88e6..fe12561 100644 Binary files a/docs/architecture/diagrams/structurizr-Classes_default_container__basic_python.png and b/docs/architecture/diagrams/structurizr-Classes_default_container__basic_python.png differ diff --git a/docs/architecture/diagrams/structurizr-Classes_default_container__basic_wrangler-key.png b/docs/architecture/diagrams/structurizr-Classes_default_container__basic_wrangler-key.png index d4d2249..5847cb9 100644 Binary files a/docs/architecture/diagrams/structurizr-Classes_default_container__basic_wrangler-key.png and b/docs/architecture/diagrams/structurizr-Classes_default_container__basic_wrangler-key.png differ diff --git a/docs/architecture/diagrams/structurizr-Classes_default_container__basic_wrangler.cmapx b/docs/architecture/diagrams/structurizr-Classes_default_container__basic_wrangler.cmapx index 8771c33..13d5c1a 100644 --- a/docs/architecture/diagrams/structurizr-Classes_default_container__basic_wrangler.cmapx +++ b/docs/architecture/diagrams/structurizr-Classes_default_container__basic_wrangler.cmapx @@ -1,3 +1,3 @@ - + diff --git a/docs/architecture/diagrams/structurizr-Classes_default_container__basic_wrangler.png b/docs/architecture/diagrams/structurizr-Classes_default_container__basic_wrangler.png index ed0d023..b4d530d 100644 Binary files a/docs/architecture/diagrams/structurizr-Classes_default_container__basic_wrangler.png and b/docs/architecture/diagrams/structurizr-Classes_default_container__basic_wrangler.png differ diff --git a/docs/architecture/diagrams/structurizr-Classes_default_container__cli-key.png b/docs/architecture/diagrams/structurizr-Classes_default_container__cli-key.png index d4d2249..5847cb9 100644 Binary files a/docs/architecture/diagrams/structurizr-Classes_default_container__cli-key.png and b/docs/architecture/diagrams/structurizr-Classes_default_container__cli-key.png differ diff --git a/docs/architecture/diagrams/structurizr-Classes_default_container__cli.png b/docs/architecture/diagrams/structurizr-Classes_default_container__cli.png index c390f39..bbcc506 100644 Binary files a/docs/architecture/diagrams/structurizr-Classes_default_container__cli.png and b/docs/architecture/diagrams/structurizr-Classes_default_container__cli.png differ diff --git a/docs/architecture/diagrams/structurizr-Classes_default_container__core-key.png b/docs/architecture/diagrams/structurizr-Classes_default_container__core-key.png index d4d2249..5847cb9 100644 Binary files a/docs/architecture/diagrams/structurizr-Classes_default_container__core-key.png and b/docs/architecture/diagrams/structurizr-Classes_default_container__core-key.png differ diff --git a/docs/architecture/diagrams/structurizr-Classes_default_container__core.png b/docs/architecture/diagrams/structurizr-Classes_default_container__core.png index c214110..1944896 100644 Binary files a/docs/architecture/diagrams/structurizr-Classes_default_container__core.png and b/docs/architecture/diagrams/structurizr-Classes_default_container__core.png differ diff --git a/docs/architecture/diagrams/structurizr-Classes_default_container__docs-key.png b/docs/architecture/diagrams/structurizr-Classes_default_container__docs-key.png index d4d2249..5847cb9 100644 Binary files a/docs/architecture/diagrams/structurizr-Classes_default_container__docs-key.png and b/docs/architecture/diagrams/structurizr-Classes_default_container__docs-key.png differ diff --git a/docs/architecture/diagrams/structurizr-Classes_default_container__docs.png b/docs/architecture/diagrams/structurizr-Classes_default_container__docs.png index df6221f..a25c1a7 100644 Binary files a/docs/architecture/diagrams/structurizr-Classes_default_container__docs.png and b/docs/architecture/diagrams/structurizr-Classes_default_container__docs.png differ diff --git a/docs/architecture/diagrams/structurizr-Classes_default_container__extractors-key.png b/docs/architecture/diagrams/structurizr-Classes_default_container__extractors-key.png index d4d2249..5847cb9 100644 Binary files a/docs/architecture/diagrams/structurizr-Classes_default_container__extractors-key.png and b/docs/architecture/diagrams/structurizr-Classes_default_container__extractors-key.png differ diff --git a/docs/architecture/diagrams/structurizr-Classes_default_container__extractors.png b/docs/architecture/diagrams/structurizr-Classes_default_container__extractors.png index 61b815b..c7a3c23 100644 Binary files a/docs/architecture/diagrams/structurizr-Classes_default_container__extractors.png and b/docs/architecture/diagrams/structurizr-Classes_default_container__extractors.png differ diff --git a/docs/architecture/diagrams/structurizr-Classes_default_container__generators-key.png b/docs/architecture/diagrams/structurizr-Classes_default_container__generators-key.png index d4d2249..5847cb9 100644 Binary files a/docs/architecture/diagrams/structurizr-Classes_default_container__generators-key.png and b/docs/architecture/diagrams/structurizr-Classes_default_container__generators-key.png differ diff --git a/docs/architecture/diagrams/structurizr-Classes_default_container__generators.png b/docs/architecture/diagrams/structurizr-Classes_default_container__generators.png index cb5ca18..2983cbe 100644 Binary files a/docs/architecture/diagrams/structurizr-Classes_default_container__generators.png and b/docs/architecture/diagrams/structurizr-Classes_default_container__generators.png differ diff --git a/docs/architecture/diagrams/structurizr-Classes_default_container__renderers-key.png b/docs/architecture/diagrams/structurizr-Classes_default_container__renderers-key.png index d4d2249..5847cb9 100644 Binary files a/docs/architecture/diagrams/structurizr-Classes_default_container__renderers-key.png and b/docs/architecture/diagrams/structurizr-Classes_default_container__renderers-key.png differ diff --git a/docs/architecture/diagrams/structurizr-Classes_default_container__renderers.png b/docs/architecture/diagrams/structurizr-Classes_default_container__renderers.png index 07a5848..c019074 100644 Binary files a/docs/architecture/diagrams/structurizr-Classes_default_container__renderers.png and b/docs/architecture/diagrams/structurizr-Classes_default_container__renderers.png differ diff --git a/docs/architecture/diagrams/structurizr-Classes_default_container__shared-key.png b/docs/architecture/diagrams/structurizr-Classes_default_container__shared-key.png index d4d2249..5847cb9 100644 Binary files a/docs/architecture/diagrams/structurizr-Classes_default_container__shared-key.png and b/docs/architecture/diagrams/structurizr-Classes_default_container__shared-key.png differ diff --git a/docs/architecture/diagrams/structurizr-Classes_default_container__shared.png b/docs/architecture/diagrams/structurizr-Classes_default_container__shared.png index aa04d99..dfa178d 100644 Binary files a/docs/architecture/diagrams/structurizr-Classes_default_container__shared.png and b/docs/architecture/diagrams/structurizr-Classes_default_container__shared.png differ diff --git a/docs/architecture/diagrams/structurizr-Classes_default_container__validators-key.png b/docs/architecture/diagrams/structurizr-Classes_default_container__validators-key.png index d4d2249..5847cb9 100644 Binary files a/docs/architecture/diagrams/structurizr-Classes_default_container__validators-key.png and b/docs/architecture/diagrams/structurizr-Classes_default_container__validators-key.png differ diff --git a/docs/architecture/diagrams/structurizr-Classes_default_container__validators.png b/docs/architecture/diagrams/structurizr-Classes_default_container__validators.png index 6a570d2..20e9e9b 100644 Binary files a/docs/architecture/diagrams/structurizr-Classes_default_container__validators.png and b/docs/architecture/diagrams/structurizr-Classes_default_container__validators.png differ diff --git a/docs/architecture/diagrams/structurizr-Components_Application.png b/docs/architecture/diagrams/structurizr-Components_Application.png index 921f75c..319a387 100644 Binary files a/docs/architecture/diagrams/structurizr-Components_Application.png and b/docs/architecture/diagrams/structurizr-Components_Application.png differ diff --git a/docs/architecture/diagrams/structurizr-Containers.png b/docs/architecture/diagrams/structurizr-Containers.png index eb86762..b6b9b14 100644 Binary files a/docs/architecture/diagrams/structurizr-Containers.png and b/docs/architecture/diagrams/structurizr-Containers.png differ diff --git a/docs/architecture/diagrams/structurizr-SystemContext.png b/docs/architecture/diagrams/structurizr-SystemContext.png index 2a42bb1..37acf1d 100644 Binary files a/docs/architecture/diagrams/structurizr-SystemContext.png and b/docs/architecture/diagrams/structurizr-SystemContext.png differ diff --git a/package.json b/package.json index ef48d4b..9d05298 100644 --- a/package.json +++ b/package.json @@ -49,7 +49,7 @@ "aac:render": "npx tsx src/cli.ts render", "aac:docs": "npx tsx src/cli.ts docs", "aac:all": "npx tsx src/cli.ts all", - "build": "rimraf dist && tsc --outDir dist && cp -r src/templates dist/ && cp -r src/scripts dist/ && cp -r src/generators/builtin/templates dist/generators/builtin/ && cp -r src/docs/builtin/templates dist/docs/builtin", + "build": "rimraf dist && tsc --outDir dist && cp -r src/templates dist/ && cp -r src/scripts dist/ && cp -r src/generators/builtin/templates dist/generators/builtin/ && cp -r src/docs/builtin/templates dist/docs/builtin && cp -r src/docs/builtin/images dist/docs/builtin/", "test": "vitest run --reporter=verbose", "test:integration": "node scripts/run-integration-tests.mjs", "licenses:generate": "node scripts/generate-licenses.mjs", @@ -65,7 +65,7 @@ "pack:test": "npm run build && npm pack --pack-destination ./dist && node scripts/inspect-pack.js", "updates": "npx npm-check-updates --deep --errorLevel 2", "updates:all": "npx npm-check-updates -u", - "check": "npm run format && npm run lint && npm run typecheck && npm run test && npm run readme:check && npm run licenses:generate" + "check": "npm run aac:all && npm run format && npm run lint && npm run typecheck && npm run test && npm run readme:check && npm run licenses:generate" }, "dependencies": { "@astrojs/compiler": "^2.13.0", diff --git a/src/docs/builtin/images/archlette-stainedglassA-dark.png b/src/docs/builtin/images/archlette-stainedglassA-dark.png new file mode 100644 index 0000000..e708215 Binary files /dev/null and b/src/docs/builtin/images/archlette-stainedglassA-dark.png differ diff --git a/src/docs/builtin/images/archlette-stainedglassA-dark.svg b/src/docs/builtin/images/archlette-stainedglassA-dark.svg new file mode 100644 index 0000000..9d8c0db --- /dev/null +++ b/src/docs/builtin/images/archlette-stainedglassA-dark.svg @@ -0,0 +1,34 @@ + + \n \n \n \n \n \n \n \n + + + + + + + + + + + + + + \n \n \n \n \n \n \n \n \n + + + \n \n \n \n \n \n + + + + + + \n \n \n + + + + + + \n \n \n \n \n \n + + + \ No newline at end of file diff --git a/src/docs/builtin/images/archlette-stainedglassA-light.png b/src/docs/builtin/images/archlette-stainedglassA-light.png new file mode 100644 index 0000000..a8aa74a Binary files /dev/null and b/src/docs/builtin/images/archlette-stainedglassA-light.png differ diff --git a/src/docs/builtin/images/archlette-stainedglassA-light.svg b/src/docs/builtin/images/archlette-stainedglassA-light.svg new file mode 100644 index 0000000..02ce4c8 --- /dev/null +++ b/src/docs/builtin/images/archlette-stainedglassA-light.svg @@ -0,0 +1,34 @@ + + \n \n \n \n \n \n \n \n + + + + + + + + + + + + + + \n \n \n \n \n \n \n \n \n + + + \n \n \n \n \n \n + + + + + + \n \n \n + + + + + + \n \n \n \n \n \n + + + \ No newline at end of file diff --git a/src/docs/builtin/markdown-docs.ts b/src/docs/builtin/markdown-docs.ts index 2370ff9..dbfe476 100644 --- a/src/docs/builtin/markdown-docs.ts +++ b/src/docs/builtin/markdown-docs.ts @@ -63,6 +63,17 @@ export default async function markdownDocs(ctx: PipelineContext): Promise // Configure Nunjucks const __filename = fileURLToPath(import.meta.url); const __dirname = path.dirname(__filename); + + // Copy brand images to output directory (one level up from docs_out) + const imagesSourceDir = path.join(__dirname, 'images'); + const imagesDestDir = path.join(docsDir, '..', 'images'); + if (fs.existsSync(imagesSourceDir)) { + fs.mkdirSync(imagesDestDir, { recursive: true }); + for (const file of fs.readdirSync(imagesSourceDir)) { + fs.copyFileSync(path.join(imagesSourceDir, file), path.join(imagesDestDir, file)); + } + ctx.log.debug(`Copied brand images to ${imagesDestDir}`); + } const templateDir = path.join(__dirname, 'templates'); const env = nunjucks.configure(templateDir, { autoescape: false, diff --git a/src/docs/builtin/templates/system.md.njk b/src/docs/builtin/templates/system.md.njk index 29723b9..c0abd10 100644 --- a/src/docs/builtin/templates/system.md.njk +++ b/src/docs/builtin/templates/system.md.njk @@ -1,4 +1,4 @@ -# {{ system.name }} +# {{ system.name }} **Architecture Documentation** Generated {{ "now" | date("YYYY-MM-DD HH:mm:ss") }} diff --git a/test/docs/builtin/markdown-docs.test.ts b/test/docs/builtin/markdown-docs.test.ts index d0fabbd..9d011d5 100644 --- a/test/docs/builtin/markdown-docs.test.ts +++ b/test/docs/builtin/markdown-docs.test.ts @@ -45,7 +45,9 @@ describe('markdown-docs generator', () => { // Setup default mock implementations mockFs.mkdirSync = vi.fn(); mockFs.writeFileSync = vi.fn(); + mockFs.copyFileSync = vi.fn(); mockFs.existsSync = vi.fn(() => true); + mockFs.readdirSync = vi.fn(() => []); mockPath.join = vi.fn((...args: string[]) => args.join('/')); mockPath.dirname = vi.fn((p: string) => p.split('/').slice(0, -1).join('/')); @@ -210,9 +212,6 @@ describe('markdown-docs generator', () => { expect(mockFs.mkdirSync).toHaveBeenCalledWith(expect.any(String), { recursive: true, }); - - // Verify it was called once - expect(mockFs.mkdirSync).toHaveBeenCalledTimes(1); }); it('configures nunjucks with template directory', async () => { @@ -636,6 +635,77 @@ describe('markdown-docs generator', () => { }); }); + describe('brand image copying', () => { + it('copies brand images (PNG and SVG) to /../images/ when source dir exists', async () => { + mockFs.readdirSync = vi.fn(() => [ + 'archlette-stainedglassA-light.png', + 'archlette-stainedglassA-dark.png', + 'archlette-stainedglassA-light.svg', + 'archlette-stainedglassA-dark.svg', + ]); + + await markdownDocs(mockContext); + + // images dir should be created one level above docs_out + expect(mockFs.mkdirSync).toHaveBeenCalledWith(expect.stringContaining('images'), { + recursive: true, + }); + + // all four files (2 PNG + 2 SVG) should be copied + expect(mockFs.copyFileSync).toHaveBeenCalledTimes(4); + expect(mockFs.copyFileSync).toHaveBeenCalledWith( + expect.stringContaining('archlette-stainedglassA-light.png'), + expect.stringContaining('archlette-stainedglassA-light.png'), + ); + expect(mockFs.copyFileSync).toHaveBeenCalledWith( + expect.stringContaining('archlette-stainedglassA-dark.png'), + expect.stringContaining('archlette-stainedglassA-dark.png'), + ); + expect(mockFs.copyFileSync).toHaveBeenCalledWith( + expect.stringContaining('archlette-stainedglassA-light.svg'), + expect.stringContaining('archlette-stainedglassA-light.svg'), + ); + expect(mockFs.copyFileSync).toHaveBeenCalledWith( + expect.stringContaining('archlette-stainedglassA-dark.svg'), + expect.stringContaining('archlette-stainedglassA-dark.svg'), + ); + }); + + it('copies images to a path one level above docs_out', async () => { + mockFs.readdirSync = vi.fn(() => ['archlette-stainedglassA-light.png']); + + await markdownDocs(mockContext); + + // destination should be /../images/ + const copyCall = vi.mocked(mockFs.copyFileSync).mock.calls[0]; + expect(copyCall).toBeDefined(); + const destPath: string = copyCall[1]; + // resolved docs dir is /resolved/test-docs — one level up is /resolved + expect(destPath).toContain('/resolved'); + expect(destPath).toContain('images'); + expect(destPath).toContain('archlette-stainedglassA-light.png'); + }); + + it('skips image copy when source images dir does not exist', async () => { + mockFs.existsSync = vi.fn((p: string) => !String(p).includes('images')); + + await markdownDocs(mockContext); + + expect(mockFs.copyFileSync).not.toHaveBeenCalled(); + }); + + it('generated README references images with correct relative path', async () => { + await markdownDocs(mockContext); + + const readmeContent: string = vi + .mocked(mockFs.writeFileSync) + .mock.calls.find((call) => String(call[0]).includes('README.md'))![1] as string; + + // template output contains the ../images/ reference + expect(readmeContent).toContain('Generated system.md.njk content'); + }); + }); + describe('edge cases', () => { it('handles components without container', async () => { mockContext.state.aggregatedIR!.components[0].containerId = 'non-existent';