algomancy-quickstart 0.7.0__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.
Files changed (42) hide show
  1. algomancy_quickstart/__init__.py +2 -0
  2. algomancy_quickstart/asset_manager.py +202 -0
  3. algomancy_quickstart/data_inference.py +517 -0
  4. algomancy_quickstart/main.py +62 -0
  5. algomancy_quickstart/quickstart.py +683 -0
  6. algomancy_quickstart/styling_wizard.py +347 -0
  7. algomancy_quickstart/templates/__init__.py +0 -0
  8. algomancy_quickstart/templates/algorithm.py.jinja +104 -0
  9. algomancy_quickstart/templates/assets/CQM-logo-white.png +0 -0
  10. algomancy_quickstart/templates/assets/cqm-button-white.png +0 -0
  11. algomancy_quickstart/templates/assets/cqm-button.png +0 -0
  12. algomancy_quickstart/templates/assets/cqm-logo.png +0 -0
  13. algomancy_quickstart/templates/assets/css/button_colors.css +285 -0
  14. algomancy_quickstart/templates/assets/css/cqm_loader.css +47 -0
  15. algomancy_quickstart/templates/assets/css/sidebar_layout.css +189 -0
  16. algomancy_quickstart/templates/assets/css/theme_colors.css +90 -0
  17. algomancy_quickstart/templates/assets/letter-c.svg +4 -0
  18. algomancy_quickstart/templates/assets/letter-m.svg +4 -0
  19. algomancy_quickstart/templates/assets/letter-q.svg +4 -0
  20. algomancy_quickstart/templates/assets/letters/letter-c.png +0 -0
  21. algomancy_quickstart/templates/assets/letters/letter-m.png +0 -0
  22. algomancy_quickstart/templates/assets/letters/letter-q.png +0 -0
  23. algomancy_quickstart/templates/assets/pepsi_girl.jpeg +0 -0
  24. algomancy_quickstart/templates/assets/style.css +421 -0
  25. algomancy_quickstart/templates/compare_page.py.jinja +133 -0
  26. algomancy_quickstart/templates/data_page.py.jinja +94 -0
  27. algomancy_quickstart/templates/etl_factory.py.jinja +108 -0
  28. algomancy_quickstart/templates/etl_factory_generated.py.jinja +82 -0
  29. algomancy_quickstart/templates/generated_schemas.py.jinja +55 -0
  30. algomancy_quickstart/templates/home_page.py.jinja +65 -0
  31. algomancy_quickstart/templates/kpi.py.jinja +76 -0
  32. algomancy_quickstart/templates/main.py.jinja +42 -0
  33. algomancy_quickstart/templates/main_custom.py.jinja +55 -0
  34. algomancy_quickstart/templates/main_generated_etl.py.jinja +72 -0
  35. algomancy_quickstart/templates/main_with_styling.py.jinja +83 -0
  36. algomancy_quickstart/templates/overview_page.py.jinja +98 -0
  37. algomancy_quickstart/templates/scenario_page.py.jinja +77 -0
  38. algomancy_quickstart/templates/schema.py.jinja +58 -0
  39. algomancy_quickstart/templates/styling_config.py.jinja +53 -0
  40. algomancy_quickstart-0.7.0.dist-info/METADATA +29 -0
  41. algomancy_quickstart-0.7.0.dist-info/RECORD +42 -0
  42. algomancy_quickstart-0.7.0.dist-info/WHEEL +4 -0
@@ -0,0 +1,98 @@
1
+ """
2
+ Custom overview page template for {{ project_name }}.
3
+
4
+ This module defines a custom overview page for high-level dashboards and summaries.
5
+ """
6
+
7
+ from typing import List
8
+ from dash import html
9
+ from algomancy_content import BaseOverviewPage
10
+ from algomancy_scenario import Scenario
11
+
12
+
13
+ class {{ class_name }}OverviewPage(BaseOverviewPage):
14
+ """
15
+ Custom overview page implementation for {{ project_name }}.
16
+
17
+ TODO: Customize the overview page layout and behavior.
18
+ """
19
+
20
+ @staticmethod
21
+ def create_content(scenarios: List[Scenario]) -> html.Div:
22
+ """
23
+ Define the layout and content of the overview page displaying multiple scenarios.
24
+
25
+ Args:
26
+ scenarios: A list of Scenario objects to display in the overview.
27
+
28
+ Returns:
29
+ A Dash html.Div containing the page content.
30
+
31
+ TODO: Implement your custom overview page layout.
32
+ """
33
+ # Get completed scenarios for display
34
+ completed_scenarios = [s for s in scenarios if s.is_completed()]
35
+
36
+ return html.Div(
37
+ [
38
+ html.H1("{{ project_name }} Overview Dashboard"),
39
+ html.P(
40
+ f"Total scenarios: {len(scenarios)} | Completed: {len(completed_scenarios)}"
41
+ ),
42
+ html.Hr(),
43
+ html.Div(
44
+ [
45
+ html.H3("Scenarios Summary"),
46
+ html.Div(
47
+ [
48
+ html.Div(
49
+ [
50
+ html.H5(scenario.tag),
51
+ html.P(f"Status: {scenario.status}"),
52
+ html.P(f"Algorithm: {scenario.algorithm_description}"),
53
+ ],
54
+ style={
55
+ "border": "1px solid #ddd",
56
+ "padding": "10px",
57
+ "marginBottom": "10px",
58
+ "borderRadius": "5px",
59
+ },
60
+ )
61
+ for scenario in scenarios
62
+ ]
63
+ )
64
+ if scenarios
65
+ else html.P("No scenarios found. Create your first scenario to get started."),
66
+ ]
67
+ ),
68
+ html.Hr(),
69
+ html.Div(
70
+ [
71
+ html.H3("Dashboard Features"),
72
+ html.Ul(
73
+ [
74
+ html.Li("Display key performance indicators across scenarios"),
75
+ html.Li("Show summary statistics and trends"),
76
+ html.Li("Compare scenario outcomes at a glance"),
77
+ html.Li("Customize this page in src/pages/overview_page.py"),
78
+ ]
79
+ ),
80
+ ]
81
+ ),
82
+ # TODO: Add KPI comparison table, summary charts, executive dashboard components
83
+ ],
84
+ style={"padding": "20px"},
85
+ )
86
+
87
+ @staticmethod
88
+ def register_callbacks() -> None:
89
+ """
90
+ Register Dash callbacks for this page if needed.
91
+
92
+ TODO: Add any interactive behavior for the overview page.
93
+ """
94
+ # Example:
95
+ # @app.callback(...)
96
+ # def filter_scenarios(...):
97
+ # pass
98
+ pass
@@ -0,0 +1,77 @@
1
+ """
2
+ Custom scenario page template for {{ project_name }}.
3
+
4
+ This module defines a custom scenario page for managing and comparing scenarios.
5
+ """
6
+
7
+ from dash import html
8
+ from algomancy_content import BaseScenarioPage
9
+ from algomancy_scenario import Scenario
10
+
11
+
12
+ class {{ class_name }}ScenarioPage(BaseScenarioPage):
13
+ """
14
+ Custom scenario page implementation for {{ project_name }}.
15
+
16
+ TODO: Customize the scenario page layout and behavior.
17
+ """
18
+
19
+ @staticmethod
20
+ def create_content(scenario: Scenario) -> html.Div:
21
+ """
22
+ Define the layout and content of the scenario page for the given scenario.
23
+
24
+ Args:
25
+ scenario: The Scenario object to display.
26
+
27
+ Returns:
28
+ A Dash html.Div containing the page content.
29
+
30
+ TODO: Implement your custom scenario page layout.
31
+ """
32
+ return html.Div(
33
+ [
34
+ html.H1("{{ project_name }} Scenario Details"),
35
+ html.Hr(),
36
+ html.Div(
37
+ [
38
+ html.H3("Scenario Information"),
39
+ html.P(f"Tag: {scenario.tag}"),
40
+ html.P(f"ID: {scenario.id}"),
41
+ html.P(f"Status: {scenario.status}"),
42
+ html.P(f"Algorithm: {scenario.algorithm_description}"),
43
+ html.P(f"Dataset: {scenario.input_data_key}"),
44
+ ],
45
+ style={"marginBottom": "20px"},
46
+ ),
47
+ html.Hr(),
48
+ html.Div(
49
+ [
50
+ html.H3("Scenario Features"),
51
+ html.Ul(
52
+ [
53
+ html.Li("View scenario configuration and parameters"),
54
+ html.Li("Display scenario execution results"),
55
+ html.Li("Visualize scenario outcomes and KPIs"),
56
+ html.Li("Customize this page in src/pages/scenario_page.py"),
57
+ ]
58
+ ),
59
+ ]
60
+ ),
61
+ # TODO: Add scenario-specific visualizations, results tables, charts
62
+ ],
63
+ style={"padding": "20px"},
64
+ )
65
+
66
+ @staticmethod
67
+ def register_callbacks() -> None:
68
+ """
69
+ Register Dash callbacks for this page if needed.
70
+
71
+ TODO: Add any interactive behavior for the scenario page.
72
+ """
73
+ # Example:
74
+ # @app.callback(...)
75
+ # def update_scenario_view(...):
76
+ # pass
77
+ pass
@@ -0,0 +1,58 @@
1
+ """
2
+ Schema definition for {{ project_name }} data.
3
+
4
+ This module defines the data structure and types for your application's data.
5
+ """
6
+
7
+ from algomancy_data import (
8
+ Column,
9
+ ColumnGroup, # noqa: F401 # used for MULTI (multi-sheet) schemas
10
+ DataType,
11
+ FileExtension,
12
+ Schema,
13
+ )
14
+ from algomancy_data.schema import SchemaType
15
+
16
+
17
+ class {{ class_name }}Schema(Schema):
18
+ """
19
+ Schema for {{ project_name }} data.
20
+
21
+ Declare each column as a class-level :class:`Column` attribute. Useful
22
+ keyword arguments:
23
+
24
+ * ``dtype`` — required, one of :class:`DataType`.
25
+ * ``primary_key=True`` — marks the column as part of the PK.
26
+ * ``optional=True`` — column may be absent in the source file.
27
+ * ``nullable=True`` — column may contain null values.
28
+ * ``unique=True`` — values must be unique across rows.
29
+ * ``foreign_key=("table", "col")`` — relate to another schema's column.
30
+ * ``parent_requires_child=True`` — drop parent rows that have no
31
+ matching child (used together with ``foreign_key``).
32
+
33
+ For multi-sheet workbooks set ``_SCHEMA_TYPE = SchemaType.MULTI`` and
34
+ declare one :class:`ColumnGroup` per sheet instead of bare ``Column``s.
35
+
36
+ TODO: Customize the schema according to your data structure.
37
+ """
38
+
39
+ # TODO: Set the base filename (without extension) for your data files
40
+ _FILENAME = "{{ filename }}"
41
+
42
+ # TODO: Set the file extension (CSV, XLSX, JSON)
43
+ _EXTENSION = FileExtension.CSV
44
+
45
+ # TODO: Set schema type (SINGLE for one file/sheet, MULTI for multi-sheet)
46
+ _SCHEMA_TYPE = SchemaType.SINGLE
47
+
48
+ # TODO: Replace these example columns with your own.
49
+ ID = Column("id", dtype=DataType.INTEGER, primary_key=True)
50
+ NAME = Column("name", dtype=DataType.STRING)
51
+ # Add more columns here, e.g.:
52
+ # CREATED_AT = Column("created_at", dtype=DataType.DATETIME, nullable=True)
53
+
54
+
55
+ # Collect all schemas exported by this module — imported by main.py.
56
+ all_schemas = [
57
+ {{ class_name }}Schema,
58
+ ]
@@ -0,0 +1,53 @@
1
+ """
2
+ Styling configuration for {{ project_name }}.
3
+
4
+ This file defines the visual styling for your Algomancy application.
5
+ You can customize colors, button modes, and other visual elements here.
6
+ """
7
+
8
+ from algomancy_gui.configuration.stylingconfig import (
9
+ StylingConfig,
10
+ LayoutSelection,
11
+ )
12
+ from algomancy_gui.configuration.colorconfig import (
13
+ ColorConfig,
14
+ CardHighlightMode,
15
+ ButtonColorMode,
16
+ )
17
+
18
+
19
+ def get_styling_config() -> StylingConfig:
20
+ """
21
+ Create and return the styling configuration for this application.
22
+
23
+ Returns:
24
+ StylingConfig instance with custom colors and settings.
25
+ """
26
+
27
+ # Color configuration
28
+ color_config = ColorConfig(
29
+ background_color="{{ background }}",
30
+ theme_color_primary="{{ primary }}",
31
+ theme_color_secondary="{{ secondary }}",
32
+ theme_color_tertiary="{{ primary }}", # Using primary as tertiary
33
+ text_color="{{ text }}",
34
+ text_color_highlight="{{ text_highlight }}",
35
+ text_color_selected="{{ text_selected }}",
36
+ button_color_mode=ButtonColorMode.{{ button_mode }},
37
+ )
38
+
39
+ # Create styling configuration
40
+ styling = StylingConfig(
41
+ assets_path="assets",
42
+ layout_selection=LayoutSelection.SIDEBAR,
43
+ color_configuration=color_config,
44
+ {% if logo_path %}logo_path="{{ logo_path }}",{% endif %}
45
+ {% if button_path %}button_path="{{ button_path }}",{% endif %}
46
+ card_highlight_mode=CardHighlightMode.{{ card_mode }},
47
+ )
48
+
49
+ return styling
50
+
51
+
52
+ # Create the default styling instance
53
+ app_styling = get_styling_config()
@@ -0,0 +1,29 @@
1
+ Metadata-Version: 2.3
2
+ Name: algomancy-quickstart
3
+ Version: 0.7.0
4
+ Summary: Interactive CLI wizard for setting up Algomancy applications.
5
+ Requires-Dist: algomancy-utils
6
+ Requires-Dist: algomancy-content
7
+ Requires-Dist: algomancy-data
8
+ Requires-Dist: algomancy-gui
9
+ Requires-Dist: click>=8.0.0
10
+ Requires-Dist: jinja2>=3.0.0
11
+ Requires-Dist: rich>=13.0.0
12
+ Requires-Python: >=3.14
13
+ Description-Content-Type: text/markdown
14
+
15
+ # Algomancy Quickstart
16
+
17
+ Interactive CLI wizard for bootstrapping Algomancy applications.
18
+
19
+ ## Usage
20
+ ```bash
21
+ algomancy-quickstart [options]
22
+ ```
23
+
24
+ This will guide you through setting up:
25
+ 1. Folder structure and basic main method
26
+ 2. Custom implementation shells for placeholders
27
+ 3. ETL pipeline generation from data
28
+ 4. Assets import from GitHub
29
+ 5. Styling configuration
@@ -0,0 +1,42 @@
1
+ algomancy_quickstart/__init__.py,sha256=vZnBKoDyjEDjUfRM2hrqLraeGfDAeoZjXlTS8Wx2Oi0,66
2
+ algomancy_quickstart/asset_manager.py,sha256=XuKUtOikoc3PNxNnr-zQHNHzTEtds-djDvkJIrVydRg,6841
3
+ algomancy_quickstart/data_inference.py,sha256=TdpwR8AWwnpQ6q_yoLkcMEv_LU8dzpjWzCMdzj9ByPw,17402
4
+ algomancy_quickstart/main.py,sha256=HE_xsQCQk6XoxMHZwlOoHZpFOM0x8XQU2wfKAHTbm8Q,1745
5
+ algomancy_quickstart/quickstart.py,sha256=H6wpewNGzmlu0iXMEdyWXA-7uzGmcDEc0TFqr8D_V5g,24769
6
+ algomancy_quickstart/styling_wizard.py,sha256=XLaz2IdSCAyYOJGucLVH0cv0s37Ac2XDWjw707PrSSY,11033
7
+ algomancy_quickstart/templates/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
8
+ algomancy_quickstart/templates/algorithm.py.jinja,sha256=MzCdi7Ad0wjlptCRrg2EvXa7CI3PUwLc8erlZR9qIn0,2939
9
+ algomancy_quickstart/templates/assets/CQM-logo-white.png,sha256=3gQOJO-2NZXFDciBpUuRqyIBILaPCrPkwmQ0OvVDB3A,4272
10
+ algomancy_quickstart/templates/assets/cqm-button-white.png,sha256=1w0v0Dxdf4zWu__dnUurTnCoYQxkHwcTitnstNx_sGI,2568
11
+ algomancy_quickstart/templates/assets/cqm-button.png,sha256=qydn5osgNQt6VQZzSRkITAtz4RVe9FD2SOTzNIljhbE,4624
12
+ algomancy_quickstart/templates/assets/cqm-logo.png,sha256=wstnl0oDmLd92FB_hUTOYz7VNlDoeSWccBUKaqzHUV4,16635
13
+ algomancy_quickstart/templates/assets/css/button_colors.css,sha256=kMPAC34vA81pOwnzUq03Q6SRdagM7fofMkJ7ueGNbDA,9958
14
+ algomancy_quickstart/templates/assets/css/cqm_loader.css,sha256=Waw7DqwbCZRsLOsojO8jHGg89JTQV9j3G4wBRHk--dM,1083
15
+ algomancy_quickstart/templates/assets/css/sidebar_layout.css,sha256=60ABlc3WWAJFBaC0fz33yNa153xjffc15aYI-m-LM0o,4633
16
+ algomancy_quickstart/templates/assets/css/theme_colors.css,sha256=SoC4GI_gDRbj0BTHNSpwPP3Z2StITndyY3NRLMiuTfY,3837
17
+ algomancy_quickstart/templates/assets/letter-c.svg,sha256=UU7rgZv5NF_bua40UVuR44vXmcdNkDNmhFmeEHTTNqI,1517
18
+ algomancy_quickstart/templates/assets/letter-m.svg,sha256=f8KBaGB7xYKzbphLzZ6pRQPP9YLYCRMKAa56_WwPrwQ,1088
19
+ algomancy_quickstart/templates/assets/letter-q.svg,sha256=CeblGH9pBFVBeNbAF-yIUCasT82aLLRobWnQjTksqWc,2537
20
+ algomancy_quickstart/templates/assets/letters/letter-c.png,sha256=ilVzEhwie96GCof3ZUGeJgXBiOy_mvZ9EQUj0yOSqVo,885
21
+ algomancy_quickstart/templates/assets/letters/letter-m.png,sha256=Ykgp3dSskUZ73LcpC4-7eB0IKR6UzuO919sb4ZsMLUc,816
22
+ algomancy_quickstart/templates/assets/letters/letter-q.png,sha256=d18O-OM6W1kBa018sLDO4vePLiEyyfCv_FNz-48zawo,1182
23
+ algomancy_quickstart/templates/assets/pepsi_girl.jpeg,sha256=NcyYHrJqOzE71kCCC-je1UW2N27TE9tiGc2U9sWj3v0,120365
24
+ algomancy_quickstart/templates/assets/style.css,sha256=DT3XG1_Y_ixHclKEHeLlPIRowE38ZeAXwImzDG5p-Ic,10437
25
+ algomancy_quickstart/templates/compare_page.py.jinja,sha256=KkB2BNceWTA-5Bv47lGfFKKnHRzMF7y4O2Spa_DUC7A,4257
26
+ algomancy_quickstart/templates/data_page.py.jinja,sha256=v-fMVxbJGrmUPZ6Onfvv0Vk_yz0roWg0IZK82ALY2MQ,3222
27
+ algomancy_quickstart/templates/etl_factory.py.jinja,sha256=9WsjfTgku3JCnclOULFvGQGjDrOsUxlQELSPw6IwRFU,3995
28
+ algomancy_quickstart/templates/etl_factory_generated.py.jinja,sha256=04aehW46U2H29EeAdOLaWHA7Tl7cilruD7t_h9eqNaI,2980
29
+ algomancy_quickstart/templates/generated_schemas.py.jinja,sha256=jnQNy3AC5bNrZ4pm-CxrcODrDR37zUquKnRCf6NVh7k,2210
30
+ algomancy_quickstart/templates/home_page.py.jinja,sha256=MrXX_npwmpckg5x0tQc3XQOM_fMLHbyYL9iNTRjYz0c,2065
31
+ algomancy_quickstart/templates/kpi.py.jinja,sha256=bjZYXUDr3s5aG11dwGOY-KiELqn8Fq0YWIhjIda_hs8,2172
32
+ algomancy_quickstart/templates/main.py.jinja,sha256=gwTGiI4JT9rVCDMdw8-d-cgCLFxQi2U36HLvpS7mlbM,1536
33
+ algomancy_quickstart/templates/main_custom.py.jinja,sha256=A_aM7IOx9MrJryT6UkXism1EsGyZwU8DSOeFneDSSn4,2425
34
+ algomancy_quickstart/templates/main_generated_etl.py.jinja,sha256=eF87zojh9J6qvY9I7Lzph32Hg0hF5kIRmB-fiYPPnkY,3049
35
+ algomancy_quickstart/templates/main_with_styling.py.jinja,sha256=boizDi88pCpRtPKtdcdYcZIuKR3yzxWgYTjD1_pbbYo,3298
36
+ algomancy_quickstart/templates/overview_page.py.jinja,sha256=vRxMPhg_I0evArizCRrI33oI6rx9ffpnkyS2o6DivBg,3604
37
+ algomancy_quickstart/templates/scenario_page.py.jinja,sha256=_s9BvCa0oRSKX0BfjlERisQ_h8oE0sUu_X0T7avf9_8,2592
38
+ algomancy_quickstart/templates/schema.py.jinja,sha256=8Q4SJ3VTzuY1LdKgV_W1QghmthYxDSJqpaoG0jAF32Y,2031
39
+ algomancy_quickstart/templates/styling_config.py.jinja,sha256=BUv9iXSO_asS5aHtb-vNb75U1WUiCVHPi6jpRzQIhpc,1587
40
+ algomancy_quickstart-0.7.0.dist-info/WHEEL,sha256=Q9FtwzuR2QE37l-JIkuyklGnJJiCBHKnsPVQ9vzCMzQ,81
41
+ algomancy_quickstart-0.7.0.dist-info/METADATA,sha256=kkViyrshXu_lBEtN07LkMpi30hVundQro0RMF5Awm6g,772
42
+ algomancy_quickstart-0.7.0.dist-info/RECORD,,
@@ -0,0 +1,4 @@
1
+ Wheel-Version: 1.0
2
+ Generator: uv 0.11.17
3
+ Root-Is-Purelib: true
4
+ Tag: py3-none-any