systemlink-cli 1.3.1__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 (74) hide show
  1. slcli/__init__.py +1 -0
  2. slcli/__main__.py +23 -0
  3. slcli/_version.py +4 -0
  4. slcli/asset_click.py +1289 -0
  5. slcli/cli_formatters.py +218 -0
  6. slcli/cli_utils.py +504 -0
  7. slcli/comment_click.py +602 -0
  8. slcli/completion_click.py +418 -0
  9. slcli/config.py +81 -0
  10. slcli/config_click.py +498 -0
  11. slcli/dff_click.py +979 -0
  12. slcli/dff_decorators.py +24 -0
  13. slcli/example_click.py +404 -0
  14. slcli/example_loader.py +274 -0
  15. slcli/example_provisioner.py +2777 -0
  16. slcli/examples/README.md +134 -0
  17. slcli/examples/_schema/schema-v1.0.json +169 -0
  18. slcli/examples/demo-complete-workflow/README.md +323 -0
  19. slcli/examples/demo-complete-workflow/config.yaml +638 -0
  20. slcli/examples/demo-test-plans/README.md +132 -0
  21. slcli/examples/demo-test-plans/config.yaml +154 -0
  22. slcli/examples/exercise-5-1-parametric-insights/README.md +101 -0
  23. slcli/examples/exercise-5-1-parametric-insights/config.yaml +1589 -0
  24. slcli/examples/exercise-7-1-test-plans/README.md +93 -0
  25. slcli/examples/exercise-7-1-test-plans/config.yaml +323 -0
  26. slcli/examples/spec-compliance-notebooks/README.md +140 -0
  27. slcli/examples/spec-compliance-notebooks/config.yaml +112 -0
  28. slcli/examples/spec-compliance-notebooks/notebooks/SpecAnalysis_ComplianceCalculation.ipynb +1553 -0
  29. slcli/examples/spec-compliance-notebooks/notebooks/SpecComplianceCalculation.ipynb +1577 -0
  30. slcli/examples/spec-compliance-notebooks/notebooks/SpecfileExtractionAndIngestion.ipynb +912 -0
  31. slcli/examples/spec-compliance-notebooks/spec_template.xlsx +0 -0
  32. slcli/feed_click.py +892 -0
  33. slcli/file_click.py +932 -0
  34. slcli/function_click.py +1400 -0
  35. slcli/function_templates.py +85 -0
  36. slcli/main.py +406 -0
  37. slcli/mcp_click.py +269 -0
  38. slcli/mcp_server.py +748 -0
  39. slcli/notebook_click.py +1770 -0
  40. slcli/platform.py +345 -0
  41. slcli/policy_click.py +679 -0
  42. slcli/policy_utils.py +411 -0
  43. slcli/profiles.py +411 -0
  44. slcli/response_handlers.py +359 -0
  45. slcli/routine_click.py +763 -0
  46. slcli/skill_click.py +253 -0
  47. slcli/skills/slcli/SKILL.md +713 -0
  48. slcli/skills/slcli/references/analysis-recipes.md +474 -0
  49. slcli/skills/slcli/references/filtering.md +236 -0
  50. slcli/skills/systemlink-webapp/SKILL.md +744 -0
  51. slcli/skills/systemlink-webapp/references/deployment.md +123 -0
  52. slcli/skills/systemlink-webapp/references/nimble-angular.md +380 -0
  53. slcli/skills/systemlink-webapp/references/systemlink-services.md +192 -0
  54. slcli/ssl_trust.py +93 -0
  55. slcli/system_click.py +2216 -0
  56. slcli/table_utils.py +124 -0
  57. slcli/tag_click.py +794 -0
  58. slcli/templates_click.py +599 -0
  59. slcli/testmonitor_click.py +1667 -0
  60. slcli/universal_handlers.py +305 -0
  61. slcli/user_click.py +1218 -0
  62. slcli/utils.py +832 -0
  63. slcli/web_editor.py +295 -0
  64. slcli/webapp_click.py +981 -0
  65. slcli/workflow_preview.py +287 -0
  66. slcli/workflows_click.py +988 -0
  67. slcli/workitem_click.py +2258 -0
  68. slcli/workspace_click.py +576 -0
  69. slcli/workspace_utils.py +206 -0
  70. systemlink_cli-1.3.1.dist-info/METADATA +20 -0
  71. systemlink_cli-1.3.1.dist-info/RECORD +74 -0
  72. systemlink_cli-1.3.1.dist-info/WHEEL +4 -0
  73. systemlink_cli-1.3.1.dist-info/entry_points.txt +7 -0
  74. systemlink_cli-1.3.1.dist-info/licenses/LICENSE +21 -0
@@ -0,0 +1,132 @@
1
+ # Demo Test Plans Example
2
+
3
+ This example provides a complete, ready-to-use setup for demonstrating SystemLink test planning workflows.
4
+
5
+ ## What's Included
6
+
7
+ The example creates the following resources in your SystemLink workspace:
8
+
9
+ ### Infrastructure
10
+
11
+ - **Location**: Demo HQ (Austin, TX)
12
+ - **Product**: Demo Widget Pro (Industrial Equipment)
13
+
14
+ ### Test Infrastructure
15
+
16
+ - **Systems**:
17
+ - Test Stand 1 (Serial: TS-001)
18
+ - Test Stand 2 (Serial: TS-002)
19
+ - **Assets**:
20
+ - Asset 1 on Test Stand 1 (Serial: ASSET-001)
21
+ - Asset 2 on Test Stand 2 (Serial: ASSET-002)
22
+ - **DUTs**:
23
+ - DUT 1 - Model X1 (Serial: DUT-001) on Asset 1
24
+ - DUT 2 - Model X2 (Serial: DUT-002) on Asset 2
25
+
26
+ ### Test Planning
27
+
28
+ - **Test Template**: Demo Test Template
29
+ - Pre-configured for both test systems
30
+ - Ready to use in test creation workflow
31
+
32
+ ## Setup Time
33
+
34
+ Approximately **5 minutes** to provision all resources.
35
+
36
+ ## Installation Steps
37
+
38
+ ### 1. Preview the resources
39
+
40
+ ```bash
41
+ slcli example info demo-test-plans
42
+ ```
43
+
44
+ This shows all 9 resources that will be created.
45
+
46
+ ### 2. Dry-run (validate without creating)
47
+
48
+ ```bash
49
+ slcli example install demo-test-plans -w <workspace-id> --dry-run
50
+ ```
51
+
52
+ ### 3. Install to a workspace
53
+
54
+ ```bash
55
+ slcli example install demo-test-plans -w <workspace>
56
+ ```
57
+
58
+ Optionally write an audit log with JSON output:
59
+
60
+ ```bash
61
+ slcli example install demo-test-plans -w <workspace> --audit-log install-log.json --format json
62
+ ```
63
+
64
+ ### 4. Verify in SystemLink Web UI
65
+
66
+ 1. Open SystemLink web interface
67
+ 2. Navigate to **Assets & Test Planning**
68
+ 3. Verify that locations, products, systems, assets, and DUTs are visible
69
+
70
+ ## Using the Example
71
+
72
+ Once installed, you can:
73
+
74
+ 1. **Create a test** from the Demo Test Template
75
+ 2. **Schedule test execution** on Test Stand 1 or Test Stand 2
76
+ 3. **Run tests** against DUT 1 or DUT 2
77
+ 4. **Track results** in test history
78
+
79
+ ## Cleanup
80
+
81
+ To remove all example resources:
82
+
83
+ ```bash
84
+ # Preview what would be deleted
85
+ slcli example delete demo-test-plans -w <workspace-id> --dry-run
86
+
87
+ # Delete all demo-tagged resources in a workspace
88
+ slcli example delete demo-test-plans -w <workspace>
89
+
90
+ # Write an audit log of deletion results
91
+ slcli example delete demo-test-plans -w <workspace> --audit-log delete-log.json --format json
92
+ ```
93
+
94
+ **Important**: Cleanup only deletes resources tagged with "demo". Any resources you created or modified separately will not be deleted.
95
+
96
+ ## Troubleshooting
97
+
98
+ ### Example installation fails
99
+
100
+ Check that your workspace exists:
101
+
102
+ ```bash
103
+ slcli workspace list
104
+ ```
105
+
106
+ If no workspace exists, create one:
107
+
108
+ ```bash
109
+ slcli workspace create --name "Default workspace"
110
+ ```
111
+
112
+ ### Resources not visible in web UI
113
+
114
+ 1. Ensure you're viewing the correct workspace
115
+ 2. Refresh the web browser
116
+ 3. Check workspace settings: Assets & Test Planning > Settings
117
+
118
+ ### Can't delete resources
119
+
120
+ 1. Verify workspace permissions
121
+ 2. Confirm resources are tagged for deletion in the config
122
+
123
+ ## Next Steps
124
+
125
+ After installing this example, consider:
126
+
127
+ 1. Creating additional test templates for different product lines
128
+ 2. Adding more test systems or DUTs
129
+ 3. Creating workflows to automate test execution
130
+ 4. Setting up data logging to track results over time
131
+
132
+ For more information, see the [SystemLink documentation](https://docs.systemlink.local/).
@@ -0,0 +1,154 @@
1
+ ---
2
+ # SLE Example Configuration: Demo Test Plans
3
+ format_version: "1.0"
4
+ name: "demo-test-plans"
5
+ title: "Demo Test Plans"
6
+ description: |
7
+ A complete example demonstrating the end-to-end test planning workflow.
8
+ Includes systems, assets, DUTs, locations, products, and test templates.
9
+ Perfect for training and evaluation scenarios.
10
+
11
+ author: "NI"
12
+ created_date: "2025-12-17"
13
+ updated_date: "2025-12-17"
14
+ tags:
15
+ - "training"
16
+ - "beginner"
17
+ - "test-plans"
18
+
19
+ estimated_setup_time_minutes: 5
20
+ required_systemlink_version: "2024.1"
21
+ target_workspace: null
22
+
23
+ resources:
24
+ # Phase 1: Locations (no dependencies)
25
+ - type: "location"
26
+ name: "Demo HQ"
27
+ properties:
28
+ address: "123 Main St"
29
+ city: "Austin"
30
+ state: "TX"
31
+ country: "USA"
32
+ id_reference: "loc_hq"
33
+ tags: ["demo"]
34
+
35
+ # Phase 2: Products (no dependencies)
36
+ - type: "product"
37
+ name: "Demo Widget Pro"
38
+ properties:
39
+ description: "Professional widget for demonstration"
40
+ category: "Industrial Equipment"
41
+ manufacturer: "Demo Inc."
42
+ id_reference: "prod_widget"
43
+ tags: ["demo"]
44
+
45
+ # Phase 3: Systems (depends on location, product)
46
+ - type: "system"
47
+ name: "Test Stand 1"
48
+ properties:
49
+ description: "First test system for demo workflow"
50
+ location_id: "${loc_hq}"
51
+ product_id: "${prod_widget}"
52
+ serial_number: "TS-001"
53
+ status: "operational"
54
+ id_reference: "sys_ts1"
55
+ tags: ["demo"]
56
+
57
+ - type: "system"
58
+ name: "Test Stand 2"
59
+ properties:
60
+ description: "Second test system for demo workflow"
61
+ location_id: "${loc_hq}"
62
+ product_id: "${prod_widget}"
63
+ serial_number: "TS-002"
64
+ status: "operational"
65
+ id_reference: "sys_ts2"
66
+ tags: ["demo"]
67
+
68
+ # Phase 4: Assets (depends on system)
69
+ - type: "asset"
70
+ name: "Asset 1 - Stand 1"
71
+ properties:
72
+ system_id: "${sys_ts1}"
73
+ serial_number: "ASSET-001"
74
+ status: "active"
75
+ id_reference: "asset_1"
76
+ tags: ["demo"]
77
+
78
+ - type: "asset"
79
+ name: "Asset 2 - Stand 2"
80
+ properties:
81
+ system_id: "${sys_ts2}"
82
+ serial_number: "ASSET-002"
83
+ status: "active"
84
+ id_reference: "asset_2"
85
+ tags: ["demo"]
86
+
87
+ # Phase 5: DUTs (depends on asset)
88
+ - type: "dut"
89
+ name: "DUT 1 - Stand 1"
90
+ properties:
91
+ asset_id: "${asset_1}"
92
+ model: "Demo Model X1"
93
+ serial_number: "DUT-001"
94
+ status: "ready"
95
+ id_reference: "dut_1"
96
+ tags: ["demo"]
97
+
98
+ - type: "dut"
99
+ name: "DUT 2 - Stand 2"
100
+ properties:
101
+ asset_id: "${asset_2}"
102
+ model: "Demo Model X2"
103
+ serial_number: "DUT-002"
104
+ status: "ready"
105
+ id_reference: "dut_2"
106
+ tags: ["demo"]
107
+
108
+ # Phase 6: Templates (no direct dependencies)
109
+ - type: "testtemplate"
110
+ name: "Demo Test Template"
111
+ properties:
112
+ description: "Basic test template for demo workflow"
113
+ version: "1.0"
114
+ systems: ["${sys_ts1}", "${sys_ts2}"]
115
+ products: ["${prod_widget}"]
116
+ id_reference: "template_demo"
117
+ tags: ["demo"]
118
+
119
+ cleanup:
120
+ order:
121
+ - "testtemplate"
122
+ - "dut"
123
+ - "asset"
124
+ - "system"
125
+ - "product"
126
+ - "location"
127
+ filter_tags: ["demo"]
128
+ require_confirmation: true
129
+
130
+ validation:
131
+ require_workspace: true
132
+
133
+ post_install:
134
+ instructions: |
135
+ ✓ Example installed successfully!
136
+
137
+ Resources created:
138
+ - 1 location: Demo HQ
139
+ - 1 product: Demo Widget Pro
140
+ - 2 systems: Test Stand 1, Test Stand 2
141
+ - 2 assets: Asset 1, Asset 2
142
+ - 2 DUTs: DUT 1, DUT 2
143
+ - 1 test template: Demo Test Template
144
+
145
+ Next steps:
146
+ 1. Open SystemLink web interface
147
+ 2. Navigate to Assets & Test Planning
148
+ 3. Create a test by selecting:
149
+ - System: "Test Stand 1" or "Test Stand 2"
150
+ - Product: "Demo Widget Pro"
151
+ - Template: "Demo Test Template"
152
+ 4. Run a test to verify setup
153
+
154
+ Learn more: https://docs.systemlink.local/examples
@@ -0,0 +1,101 @@
1
+ # Exercise 5-1: Parametric Insights — Instructor Setup Guide
2
+
3
+ Supporting training data for **Exercise 5-1: Query and Visualize Parametric Test Data**.
4
+
5
+ ## Overview
6
+
7
+ This example provisions a realistic six-week dataset of thermal cycle test results for a
8
+ lithium-ion battery pack product (**Model ABC**) collected across three test stands.
9
+ Students use Test Insights to locate the product, group results by system, visualize
10
+ parametric measurements in a data space, and save their work.
11
+
12
+ ## Quick Start
13
+
14
+ ```bash
15
+ # Preview what will be created (recommended before running)
16
+ slcli example install exercise-5-1-parametric-insights -w <workspace> --dry-run
17
+
18
+ # Install into the target workspace
19
+ slcli example install exercise-5-1-parametric-insights -w <workspace>
20
+
21
+ # Remove all provisioned resources when the session ends
22
+ slcli example delete exercise-5-1-parametric-insights -w <workspace>
23
+ ```
24
+
25
+ ## Resources Provisioned
26
+
27
+ | Type | Count | Details |
28
+ | ------------------ | ----- | -------------------------------------------------- |
29
+ | Location | 1 | Battery Testing Lab (Austin, TX) |
30
+ | Products | 3 | Model ABC (primary), Model XYZ, Model ABC Rev B |
31
+ | Systems | 3 | Thermal Cycle Tester TC-01, TC-02, TC-03 |
32
+ | DUTs | 5 | One per system + XYZ and Rev B units |
33
+ | Test results | 18 | Model ABC: 6 cycles per stand, Jan 6 – Feb 13 2026 |
34
+ | Test results | 4 | Model XYZ acceptance tests (distractor) |
35
+ | Test results | 3 | Model ABC Rev B qualification (distractor) |
36
+ | Incomplete results | 3 | Aborted/skipped runs (realism) |
37
+
38
+ **Total: 28 test results across 3 products**
39
+
40
+ ## Measurements Recorded per Model ABC Result
41
+
42
+ Each of the 18 Model ABC results carries the following measurement properties:
43
+
44
+ | Field | Unit | Spec limit |
45
+ | ----------------------------------------------- | ---- | ------------- |
46
+ | `cycle_count` | — | informational |
47
+ | `cell_temperature_1_c` … `cell_temperature_4_c` | °C | max 42 °C |
48
+ | `ambient_temperature_c` | °C | informational |
49
+ | `terminal_voltage_v` | V | min 3.70 V |
50
+ | `charge_current_a` | A | 1.20 – 1.60 A |
51
+ | `capacity_ah` | Ah | min 50.0 Ah |
52
+ | `internal_resistance_mohm` | mΩ | max 20.0 mΩ |
53
+ | `state_of_charge_pct` | % | min 98.0 % |
54
+
55
+ ## Deliberate Data Patterns for Student Discovery
56
+
57
+ The dataset contains several anomalies that students should discover through the
58
+ visualization tasks in the exercise:
59
+
60
+ ### TC-03 Temperature Offset (Step 3.13 — Color by System)
61
+
62
+ TC-03 consistently runs **3–4 °C warmer** than TC-01 and TC-02 across all six cycles.
63
+ When students color a scatter plot by System, this offset becomes immediately visible.
64
+ Instructors can prompt: _"What might cause one stand to run consistently hotter?"_
65
+ (Suggested answer: chamber thermocouple calibration drift.)
66
+
67
+ ### TC-01 Cycle 5 — Internal Resistance Spike (Feb 4, FAIL)
68
+
69
+ `internal_resistance_mohm` spikes to **21.4 mΩ** (spec: ≤ 20.0 mΩ), causing the only
70
+ FAIL result on TC-01. The value returns to 15.8 mΩ in Cycle 6 after maintenance.
71
+ Visible in a line chart with Time on X-axis and `internal_resistance_mohm` on Y-axis.
72
+
73
+ ### TC-03 Cycle 4 — Cell Temperature Spike (Jan 30, FAIL)
74
+
75
+ `cell_temperature_3_c` spikes to **44.8 °C** (spec: ≤ 42 °C) while the other three
76
+ channels remain normal (~41 °C). This isolated channel spike, visible in a line chart,
77
+ suggests a faulty cell or mounting contact rather than an ambient condition.
78
+
79
+ ### Capacity and Voltage Aging Trend
80
+
81
+ Both `capacity_ah` and `terminal_voltage_v` show a slow monotonic decrease across all
82
+ three stands (approximately 1 Ah and 0.05 V over six cycles). This is consistent with
83
+ normal lithium-ion aging and is visible when plotting with Time on X-axis.
84
+
85
+ ### Distractor Products
86
+
87
+ The Products table will show **Model ABC**, **Model XYZ**, and **Model ABC Rev B**.
88
+ Students must identify the correct product by part number `BAT-MODEL-ABC-001`, not just
89
+ by name. Model XYZ uses different measurement fields (capacitor bank); Model ABC Rev B
90
+ uses the same fields but with noticeably lower internal resistance (~10 mΩ vs ~12–15 mΩ),
91
+ illustrating the design improvement.
92
+
93
+ ## Estimated Setup Time
94
+
95
+ ~5 minutes
96
+
97
+ ## Requirements
98
+
99
+ - SystemLink Enterprise 2024.1 or later
100
+ - Test Insights module with Data Spaces enabled
101
+ - Target workspace must exist before running install