pyegeria 5.3.10__py3-none-any.whl → 5.4.0.dev3__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- commands/cat/debug_log.2025-06-05_20-24-18_123924.log.zip +0 -0
- commands/cat/debug_log.2025-06-10_08-45-03_929921.log.zip +0 -0
- commands/cat/debug_log.2025-06-11_09-57-21_247890.log.zip +0 -0
- commands/cat/debug_log.2025-06-12_16-14-31_212042.log.zip +0 -0
- commands/cat/debug_log.log +1267 -0
- commands/cat/dr_egeria_md.py +32 -5
- commands/cat/list_collections.py +10 -4
- commands/cat/list_data_designer.py +172 -0
- commands/cat/solution_architect_log.log +0 -0
- md_processing/__init__.py +7 -2
- md_processing/data/commands.json +4666 -848
- md_processing/dr_egeria_inbox/data_designer_search_test.md +11 -0
- md_processing/dr_egeria_inbox/data_test.md +106 -13
- md_processing/dr_egeria_inbox/data_test2.md +376 -0
- md_processing/dr_egeria_inbox/{search_test.md → glossary_search_test.md} +1 -0
- md_processing/dr_egeria_inbox/solution-components.md +66 -91
- md_processing/md_commands/data_designer_commands.py +840 -557
- md_processing/md_commands/solution_architect_commands.py +985 -0
- md_processing/md_processing_utils/common_md_proc_utils.py +262 -89
- md_processing/md_processing_utils/common_md_utils.py +11 -4
- md_processing/md_processing_utils/md_processing_constants.py +18 -16
- pyegeria/_client.py +39 -0
- pyegeria/classification_manager_omvs.py +1 -1
- pyegeria/collection_manager_omvs.py +248 -188
- pyegeria/data_designer_omvs.py +217 -9
- pyegeria/governance_officer_omvs.py +2349 -0
- pyegeria/output_formatter.py +24 -12
- pyegeria/solution_architect_omvs.py +4219 -1084
- pyegeria/utils.py +15 -2
- {pyegeria-5.3.10.dist-info → pyegeria-5.4.0.dev3.dist-info}/METADATA +2 -1
- {pyegeria-5.3.10.dist-info → pyegeria-5.4.0.dev3.dist-info}/RECORD +35 -36
- {pyegeria-5.3.10.dist-info → pyegeria-5.4.0.dev3.dist-info}/entry_points.txt +4 -0
- md_processing/dr_egeria_outbox/processed-2025-05-15 19:52-data_test.md +0 -94
- md_processing/dr_egeria_outbox/processed-2025-05-16 07:39-data_test.md +0 -88
- md_processing/dr_egeria_outbox/processed-2025-05-17 16:01-data_field.md +0 -56
- md_processing/dr_egeria_outbox/processed-2025-05-18 15:51-data_test.md +0 -103
- md_processing/dr_egeria_outbox/processed-2025-05-18 16:47-data_test.md +0 -94
- md_processing/dr_egeria_outbox/processed-2025-05-19 07:14-data_test.md +0 -96
- md_processing/dr_egeria_outbox/processed-2025-05-19 07:20-data_test.md +0 -100
- md_processing/dr_egeria_outbox/processed-2025-05-19 07:22-data_test.md +0 -88
- md_processing/dr_egeria_outbox/processed-2025-05-19 09:26-data_test.md +0 -91
- md_processing/dr_egeria_outbox/processed-2025-05-19 10:27-data_test.md +0 -91
- md_processing/dr_egeria_outbox/processed-2025-05-19 14:04-data_test.md +0 -91
- md_processing/md_commands/blueprint_commands.py +0 -303
- /commands/cat/{list_data_structures.py → list_data_structures_full.py} +0 -0
- {pyegeria-5.3.10.dist-info → pyegeria-5.4.0.dev3.dist-info}/LICENSE +0 -0
- {pyegeria-5.3.10.dist-info → pyegeria-5.4.0.dev3.dist-info}/WHEEL +0 -0
pyegeria/output_formatter.py
CHANGED
@@ -26,11 +26,12 @@ def make_preamble(obj_type: str, search_string: str, output_format: str = 'MD')
|
|
26
26
|
- A string or None indicating the action description for the elements,
|
27
27
|
depending on the output format.
|
28
28
|
"""
|
29
|
-
search_string = search_string if search_string else "All Elements"
|
29
|
+
# search_string = search_string if search_string else "All Elements"
|
30
30
|
elements_action = "Update " + obj_type
|
31
31
|
if output_format == "FORM":
|
32
|
-
preamble =
|
33
|
-
|
32
|
+
preamble = f"\n# Update {obj_type} Form - created at {datetime.now().strftime('%Y-%m-%d %H:%M')}\n"
|
33
|
+
if search_string:
|
34
|
+
preamble += f"\t {obj_type} found from the search string: `{search_string}`\n\n"
|
34
35
|
return preamble, elements_action
|
35
36
|
elif output_format == "REPORT":
|
36
37
|
elements_md = (f"# {obj_type} Report - created at {datetime.now().strftime('%Y-%m-%d %H:%M')}\n"
|
@@ -53,12 +54,15 @@ def make_md_attribute(attribute_name: str, attribute_value: str, output_type: st
|
|
53
54
|
str: Formatted markdown for the attribute
|
54
55
|
"""
|
55
56
|
output = ""
|
56
|
-
|
57
|
+
if isinstance(attribute_value,str):
|
58
|
+
attribute_value = attribute_value.strip() if attribute_value else ""
|
57
59
|
attribute_title = attribute_name.title() if attribute_name else ""
|
58
60
|
if output_type in ["FORM", "MD"]:
|
59
61
|
output = f"## {attribute_title}\n{attribute_value}\n\n"
|
60
62
|
elif output_type == "REPORT":
|
61
|
-
if
|
63
|
+
if attribute_title == 'Mermaid Graph':
|
64
|
+
output = f"## Mermaid Graph\n```mermaid\n{attribute_value}\n```\n"
|
65
|
+
elif attribute_value:
|
62
66
|
output = f"## {attribute_title}\n{attribute_value}\n\n"
|
63
67
|
return output
|
64
68
|
|
@@ -101,6 +105,8 @@ def generate_entity_md(elements: List[Dict],
|
|
101
105
|
elements_md = ""
|
102
106
|
|
103
107
|
for element in elements:
|
108
|
+
if element is None:
|
109
|
+
continue
|
104
110
|
props = extract_properties_func(element)
|
105
111
|
|
106
112
|
# Get additional properties if function is provided
|
@@ -227,6 +233,8 @@ def generate_entity_dict(elements: List[Dict],
|
|
227
233
|
result = []
|
228
234
|
|
229
235
|
for element in elements:
|
236
|
+
if element is None:
|
237
|
+
continue
|
230
238
|
props = extract_properties_func(element)
|
231
239
|
|
232
240
|
# Get additional properties if function is provided
|
@@ -289,10 +297,12 @@ def extract_basic_dict(elements: Union[Dict, List[Dict]]) -> Union[Dict, List[Di
|
|
289
297
|
# Add classifications if present
|
290
298
|
classifications = elements['elementHeader'].get('classifications', [])
|
291
299
|
if classifications:
|
292
|
-
classification_names = ""
|
300
|
+
classification_names = "["
|
293
301
|
for classification in classifications:
|
294
|
-
classification_names
|
295
|
-
|
302
|
+
if len(classification_names) > 1:
|
303
|
+
classification_names += ", "
|
304
|
+
classification_names += f"{classification['classificationName']}"
|
305
|
+
body['classification_names'] = classification_names + ']'
|
296
306
|
|
297
307
|
return body
|
298
308
|
|
@@ -305,10 +315,12 @@ def extract_basic_dict(elements: Union[Dict, List[Dict]]) -> Union[Dict, List[Di
|
|
305
315
|
# Add classifications if present
|
306
316
|
classifications = element['elementHeader'].get('classifications', [])
|
307
317
|
if classifications:
|
308
|
-
classification_names = ""
|
318
|
+
classification_names = "["
|
309
319
|
for classification in classifications:
|
310
|
-
classification_names
|
311
|
-
|
320
|
+
if len(classification_names) > 1:
|
321
|
+
classification_names += ", "
|
322
|
+
classification_names += f"{classification['classificationName']}"
|
323
|
+
body['classifications'] = classification_names + ']'
|
312
324
|
|
313
325
|
result.append(body)
|
314
326
|
return result
|
@@ -370,7 +382,7 @@ def generate_output(elements: Union[Dict, List[Dict]],
|
|
370
382
|
output_format=output_format
|
371
383
|
)
|
372
384
|
|
373
|
-
else: #
|
385
|
+
else: # MD, FORM, REPORT
|
374
386
|
elements_md, elements_action = make_preamble(
|
375
387
|
obj_type=entity_type,
|
376
388
|
search_string=search_string,
|