x-ipe 1.0.24__py3-none-any.whl → 1.0.25__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.
- x_ipe/app.py +25 -3
- x_ipe/handlers/terminal_handlers.py +6 -0
- x_ipe/handlers/voice_handlers.py +5 -0
- x_ipe/resources/copilot-instructions.md +19 -6
- x_ipe/resources/skills/lesson-learned/SKILL.md +208 -0
- x_ipe/resources/skills/lesson-learned/references/examples.md +238 -0
- x_ipe/resources/skills/project-quality-board-management/SKILL.md +135 -298
- x_ipe/resources/skills/project-quality-board-management/references/evaluation-principles.md +213 -0
- x_ipe/resources/skills/project-quality-board-management/references/evaluation-procedures.md +214 -0
- x_ipe/resources/skills/project-quality-board-management/templates/quality-report.md +70 -18
- x_ipe/resources/skills/task-execution-guideline/SKILL.md +2 -2
- x_ipe/resources/skills/task-execution-guideline/templates/task-record.yaml +1 -1
- x_ipe/resources/skills/task-type-code-implementation/SKILL.md +72 -270
- x_ipe/resources/skills/task-type-code-implementation/references/implementation-guidelines.md +432 -0
- x_ipe/resources/skills/task-type-code-refactor-v2/SKILL.md +127 -353
- x_ipe/resources/skills/task-type-code-refactor-v2/references/refactoring-techniques.md +373 -0
- x_ipe/resources/skills/task-type-feature-breakdown/SKILL.md +31 -243
- x_ipe/resources/skills/task-type-feature-breakdown/references/breakdown-guidelines.md +330 -0
- x_ipe/resources/skills/task-type-feature-refinement/SKILL.md +27 -180
- x_ipe/resources/skills/task-type-feature-refinement/references/specification-writing-guide.md +267 -0
- x_ipe/resources/skills/task-type-idea-mockup/SKILL.md +38 -276
- x_ipe/resources/skills/task-type-idea-mockup/references/mockup-guidelines.md +299 -0
- x_ipe/resources/skills/task-type-idea-to-architecture/SKILL.md +20 -218
- x_ipe/resources/skills/task-type-idea-to-architecture/references/architecture-patterns.md +342 -0
- x_ipe/resources/skills/task-type-ideation/SKILL.md +10 -266
- x_ipe/resources/skills/task-type-ideation/references/folder-naming-guide.md +55 -0
- x_ipe/resources/skills/task-type-ideation/references/tool-usage-guide.md +236 -0
- x_ipe/resources/skills/task-type-ideation-v2/SKILL.md +488 -0
- x_ipe/resources/skills/task-type-ideation-v2/references/examples.md +377 -0
- x_ipe/resources/skills/task-type-ideation-v2/references/folder-naming-guide.md +74 -0
- x_ipe/resources/skills/task-type-ideation-v2/references/tool-usage-guide.md +145 -0
- x_ipe/resources/skills/task-type-ideation-v2/references/visualization-guide.md +160 -0
- x_ipe/resources/skills/task-type-ideation-v2/templates/idea-summary.md +86 -0
- x_ipe/resources/skills/task-type-refactoring-analysis/SKILL.md +83 -145
- x_ipe/resources/skills/task-type-refactoring-analysis/references/output-schema.md +172 -0
- x_ipe/resources/skills/task-type-technical-design/SKILL.md +28 -214
- x_ipe/resources/skills/task-type-technical-design/references/design-templates.md +422 -0
- x_ipe/resources/skills/task-type-test-generation/SKILL.md +47 -332
- x_ipe/resources/skills/task-type-test-generation/references/test-patterns.md +368 -0
- x_ipe/resources/skills/tool-tracing-creator/SKILL.md +312 -0
- x_ipe/resources/skills/tool-tracing-creator/references/examples.md +324 -0
- x_ipe/resources/skills/tool-tracing-instrumentation/SKILL.md +373 -0
- x_ipe/resources/skills/tool-tracing-instrumentation/references/examples.md +264 -0
- x_ipe/resources/skills/x-ipe-skill-creator-v3/SKILL.md +486 -0
- x_ipe/resources/skills/x-ipe-skill-creator-v3/references/10. example-gate-conditions.md +73 -0
- x_ipe/resources/skills/x-ipe-skill-creator-v3/references/11. reference-quality-standards.md +127 -0
- x_ipe/resources/skills/x-ipe-skill-creator-v3/references/2. reference-section-order.md +127 -0
- x_ipe/resources/skills/x-ipe-skill-creator-v3/references/3. example-step-based-code-review.md +84 -0
- x_ipe/resources/skills/x-ipe-skill-creator-v3/references/4. example-step-based-feature-implementation.md +113 -0
- x_ipe/resources/skills/x-ipe-skill-creator-v3/references/5. example-function-based-validation.md +73 -0
- x_ipe/resources/skills/x-ipe-skill-creator-v3/references/6. example-function-based-analysis.md +94 -0
- x_ipe/resources/skills/x-ipe-skill-creator-v3/references/7. example-task-io-code-implementation.md +36 -0
- x_ipe/resources/skills/x-ipe-skill-creator-v3/references/8. example-structured-summary.md +43 -0
- x_ipe/resources/skills/x-ipe-skill-creator-v3/references/9. example-dor-dod.md +77 -0
- x_ipe/resources/skills/x-ipe-skill-creator-v3/references/examples.md +429 -0
- x_ipe/resources/skills/x-ipe-skill-creator-v3/references/skill-general-guidelines-v2.md +611 -0
- x_ipe/resources/skills/x-ipe-skill-creator-v3/templates/skill-meta-x-ipe-meta.md +153 -0
- x_ipe/resources/skills/x-ipe-skill-creator-v3/templates/skill-meta-x-ipe-task-based.md +324 -0
- x_ipe/resources/skills/x-ipe-skill-creator-v3/templates/skill-meta-x-ipe-task-category.md +109 -0
- x_ipe/resources/skills/x-ipe-skill-creator-v3/templates/skill-meta-x-ipe-tool.md +205 -0
- x_ipe/resources/skills/x-ipe-skill-creator-v3/templates/x-ipe-meta.md +334 -0
- x_ipe/resources/skills/x-ipe-skill-creator-v3/templates/x-ipe-task-based.md +279 -0
- x_ipe/resources/skills/x-ipe-skill-creator-v3/templates/x-ipe-tool.md +175 -0
- x_ipe/resources/skills/x-ipe-skill-creator-v3/templates/x-ipe-workflow-orchestration.md +329 -0
- x_ipe/resources/skills/x-ipe-task-based-ideation/SKILL.md +487 -0
- x_ipe/resources/skills/x-ipe-task-based-ideation/references/examples.md +377 -0
- x_ipe/resources/skills/x-ipe-task-based-ideation/references/folder-naming-guide.md +74 -0
- x_ipe/resources/skills/x-ipe-task-based-ideation/references/tool-usage-guide.md +145 -0
- x_ipe/resources/skills/x-ipe-task-based-ideation/references/visualization-guide.md +160 -0
- x_ipe/resources/skills/x-ipe-task-based-ideation/templates/idea-summary.md +86 -0
- x_ipe/routes/__init__.py +2 -0
- x_ipe/routes/ideas_routes.py +17 -0
- x_ipe/routes/kb_routes.py +80 -0
- x_ipe/routes/main_routes.py +18 -0
- x_ipe/routes/project_routes.py +7 -0
- x_ipe/routes/proxy_routes.py +2 -0
- x_ipe/routes/quality_evaluation_routes.py +193 -0
- x_ipe/routes/settings_routes.py +6 -0
- x_ipe/routes/tools_routes.py +6 -0
- x_ipe/routes/tracing_routes.py +232 -0
- x_ipe/routes/uiux_feedback_routes.py +30 -0
- x_ipe/services/__init__.py +5 -0
- x_ipe/services/config_service.py +6 -0
- x_ipe/services/file_service.py +20 -0
- x_ipe/services/homepage_service.py +160 -0
- x_ipe/services/ideas_service.py +19 -0
- x_ipe/services/kb_service.py +378 -0
- x_ipe/services/proxy_service.py +4 -0
- x_ipe/services/settings_service.py +13 -0
- x_ipe/services/skills_service.py +4 -0
- x_ipe/services/terminal_service.py +24 -0
- x_ipe/services/themes_service.py +4 -0
- x_ipe/services/tools_config_service.py +4 -0
- x_ipe/services/tracing_service.py +333 -0
- x_ipe/services/uiux_feedback_service.py +32 -0
- x_ipe/services/voice_input_service_v2.py +11 -0
- x_ipe/static/css/base.css +7 -0
- x_ipe/static/css/homepage-infinity.css +330 -0
- x_ipe/static/css/kb-core.css +301 -0
- x_ipe/static/css/quality-evaluation.css +345 -0
- x_ipe/static/css/sidebar.css +14 -4
- x_ipe/static/css/terminal.css +1 -0
- x_ipe/static/css/tracing-dashboard.css +796 -0
- x_ipe/static/css/workplace.css +20 -0
- x_ipe/static/img/homepage-infinity-loop.png +0 -0
- x_ipe/static/js/features/homepage-infinity.js +314 -0
- x_ipe/static/js/features/kb-core.js +371 -0
- x_ipe/static/js/features/quality-evaluation.js +387 -0
- x_ipe/static/js/features/sidebar.js +255 -12
- x_ipe/static/js/features/tracing-dashboard.js +855 -0
- x_ipe/static/js/features/tracing-graph.js +1031 -0
- x_ipe/static/js/features/tree-search.js +6 -2
- x_ipe/static/js/features/workplace.js +200 -6
- x_ipe/static/js/init.js +76 -0
- x_ipe/static/js/uiux-feedback.js +18 -2
- x_ipe/templates/base.html +19 -0
- x_ipe/templates/index.html +7 -1
- x_ipe/templates/knowledge-base.html +110 -0
- x_ipe/templates/workplace.html +4 -0
- x_ipe/tracing/__init__.py +37 -0
- x_ipe/tracing/buffer.py +135 -0
- x_ipe/tracing/context.py +125 -0
- x_ipe/tracing/decorator.py +288 -0
- x_ipe/tracing/middleware.py +197 -0
- x_ipe/tracing/parser.py +235 -0
- x_ipe/tracing/redactor.py +111 -0
- x_ipe/tracing/writer.py +122 -0
- {x_ipe-1.0.24.dist-info → x_ipe-1.0.25.dist-info}/METADATA +2 -2
- {x_ipe-1.0.24.dist-info → x_ipe-1.0.25.dist-info}/RECORD +132 -62
- x_ipe/resources/skills/x-ipe-skill-creator/SKILL.md +0 -329
- x_ipe/resources/skills/x-ipe-skill-creator/references/output-patterns.md +0 -169
- x_ipe/resources/skills/x-ipe-skill-creator/references/skill-structure.md +0 -162
- x_ipe/resources/skills/x-ipe-skill-creator/references/workflows.md +0 -110
- x_ipe/resources/skills/x-ipe-skill-creator/templates/references/examples.md +0 -113
- x_ipe/resources/skills/x-ipe-skill-creator/templates/skill-category-skill.md +0 -296
- x_ipe/resources/skills/x-ipe-skill-creator/templates/task-type-skill.md +0 -269
- {x_ipe-1.0.24.dist-info → x_ipe-1.0.25.dist-info}/WHEEL +0 -0
- {x_ipe-1.0.24.dist-info → x_ipe-1.0.25.dist-info}/entry_points.txt +0 -0
- {x_ipe-1.0.24.dist-info → x_ipe-1.0.25.dist-info}/licenses/LICENSE +0 -0
|
@@ -0,0 +1,160 @@
|
|
|
1
|
+
# Visualization Guide
|
|
2
|
+
|
|
3
|
+
This reference document describes how to use visualization tools in idea summaries.
|
|
4
|
+
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
## Config-Driven Visualization
|
|
8
|
+
|
|
9
|
+
Check `x-ipe-docs/config/tools.json` before choosing visualization method:
|
|
10
|
+
|
|
11
|
+
```yaml
|
|
12
|
+
decision_tree:
|
|
13
|
+
- check: "config.stages.ideation.ideation.antv-infographic"
|
|
14
|
+
if_true: "Use infographic DSL"
|
|
15
|
+
use_for: "Feature lists, roadmaps, comparisons"
|
|
16
|
+
|
|
17
|
+
- check: "config.stages.ideation.ideation.mermaid"
|
|
18
|
+
if_true: "Use mermaid diagrams"
|
|
19
|
+
use_for: "Flowcharts, sequences, state diagrams"
|
|
20
|
+
|
|
21
|
+
- check: "config.stages.ideation.ideation.tool-architecture-dsl"
|
|
22
|
+
if_true: "Use architecture DSL"
|
|
23
|
+
use_for: "Layered architecture, module views"
|
|
24
|
+
|
|
25
|
+
- fallback: "Use standard markdown"
|
|
26
|
+
use_for: "Bullet lists, tables"
|
|
27
|
+
```
|
|
28
|
+
|
|
29
|
+
---
|
|
30
|
+
|
|
31
|
+
## Infographic Templates
|
|
32
|
+
|
|
33
|
+
| Use Case | Template | When to Use |
|
|
34
|
+
|----------|----------|-------------|
|
|
35
|
+
| Feature List | `list-grid-badge-card` | Listing key features with icons |
|
|
36
|
+
| Roadmap | `sequence-roadmap-vertical-simple` | Implementation phases |
|
|
37
|
+
| Comparison | `compare-binary-horizontal-badge-card-arrow` | Comparing options |
|
|
38
|
+
|
|
39
|
+
### Feature List Example
|
|
40
|
+
|
|
41
|
+
```infographic
|
|
42
|
+
infographic list-grid-badge-card
|
|
43
|
+
data
|
|
44
|
+
title Key Features
|
|
45
|
+
lists
|
|
46
|
+
- label Feature 1
|
|
47
|
+
desc Description of feature 1
|
|
48
|
+
icon flash
|
|
49
|
+
- label Feature 2
|
|
50
|
+
desc Description of feature 2
|
|
51
|
+
icon shield
|
|
52
|
+
```
|
|
53
|
+
|
|
54
|
+
### Roadmap Example
|
|
55
|
+
|
|
56
|
+
```infographic
|
|
57
|
+
infographic sequence-roadmap-vertical-simple
|
|
58
|
+
data
|
|
59
|
+
title Implementation Phases
|
|
60
|
+
lists
|
|
61
|
+
- label Phase 1
|
|
62
|
+
desc MVP with core features
|
|
63
|
+
- label Phase 2
|
|
64
|
+
desc User feedback integration
|
|
65
|
+
- label Phase 3
|
|
66
|
+
desc Scale and optimize
|
|
67
|
+
```
|
|
68
|
+
|
|
69
|
+
---
|
|
70
|
+
|
|
71
|
+
## Mermaid Diagrams
|
|
72
|
+
|
|
73
|
+
| Use Case | Diagram Type | When to Use |
|
|
74
|
+
|----------|--------------|-------------|
|
|
75
|
+
| User Flow | flowchart | Step-by-step user journey |
|
|
76
|
+
| Process | sequenceDiagram | System interactions |
|
|
77
|
+
| States | stateDiagram | State transitions |
|
|
78
|
+
|
|
79
|
+
### Flowchart Example
|
|
80
|
+
|
|
81
|
+
```mermaid
|
|
82
|
+
flowchart TD
|
|
83
|
+
A[User Action] --> B[Feature 1]
|
|
84
|
+
B --> C[Feature 2]
|
|
85
|
+
C --> D[Result]
|
|
86
|
+
```
|
|
87
|
+
|
|
88
|
+
### Sequence Example
|
|
89
|
+
|
|
90
|
+
```mermaid
|
|
91
|
+
sequenceDiagram
|
|
92
|
+
User->>App: Request
|
|
93
|
+
App->>API: Process
|
|
94
|
+
API-->>App: Response
|
|
95
|
+
App-->>User: Display
|
|
96
|
+
```
|
|
97
|
+
|
|
98
|
+
---
|
|
99
|
+
|
|
100
|
+
## Architecture DSL
|
|
101
|
+
|
|
102
|
+
Use for layered architecture when `tool-architecture-dsl` is enabled:
|
|
103
|
+
|
|
104
|
+
```architecture-dsl
|
|
105
|
+
@startuml module-view
|
|
106
|
+
title "System Architecture"
|
|
107
|
+
theme "theme-default"
|
|
108
|
+
direction top-to-bottom
|
|
109
|
+
grid 12 x 6
|
|
110
|
+
|
|
111
|
+
layer "Frontend" {
|
|
112
|
+
color "#fce7f3"
|
|
113
|
+
border-color "#ec4899"
|
|
114
|
+
rows 2
|
|
115
|
+
module "Web" { cols 12, rows 2, grid 1 x 1, component "React App" { cols 1, rows 1 } }
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
layer "Backend" {
|
|
119
|
+
color "#dbeafe"
|
|
120
|
+
border-color "#3b82f6"
|
|
121
|
+
rows 2
|
|
122
|
+
module "Services" { cols 12, rows 2, grid 2 x 1, component "API" { cols 1, rows 1 }, component "Workers" { cols 1, rows 1 } }
|
|
123
|
+
}
|
|
124
|
+
|
|
125
|
+
@enduml
|
|
126
|
+
```
|
|
127
|
+
|
|
128
|
+
---
|
|
129
|
+
|
|
130
|
+
## Fallback (No Tools Enabled)
|
|
131
|
+
|
|
132
|
+
When all visualization tools are disabled, use standard markdown:
|
|
133
|
+
|
|
134
|
+
### Feature List (Fallback)
|
|
135
|
+
```markdown
|
|
136
|
+
## Key Features
|
|
137
|
+
|
|
138
|
+
- **Feature 1:** Description of feature 1
|
|
139
|
+
- **Feature 2:** Description of feature 2
|
|
140
|
+
- **Feature 3:** Description of feature 3
|
|
141
|
+
```
|
|
142
|
+
|
|
143
|
+
### Comparison (Fallback)
|
|
144
|
+
```markdown
|
|
145
|
+
| Option | Pros | Cons |
|
|
146
|
+
|--------|------|------|
|
|
147
|
+
| Option A | Fast, cheap | Limited features |
|
|
148
|
+
| Option B | Full features | Slower, expensive |
|
|
149
|
+
```
|
|
150
|
+
|
|
151
|
+
### Process (Fallback)
|
|
152
|
+
```markdown
|
|
153
|
+
## Process Flow
|
|
154
|
+
|
|
155
|
+
1. User logs in
|
|
156
|
+
2. Dashboard loads
|
|
157
|
+
3. User selects action
|
|
158
|
+
4. System processes
|
|
159
|
+
5. Result displayed
|
|
160
|
+
```
|
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
# Idea Summary Template
|
|
2
|
+
|
|
3
|
+
> Use this template when creating `idea-summary-vN.md` files.
|
|
4
|
+
|
|
5
|
+
```markdown
|
|
6
|
+
# Idea Summary
|
|
7
|
+
|
|
8
|
+
> Idea ID: IDEA-XXX
|
|
9
|
+
> Folder: {folder_name}
|
|
10
|
+
> Version: vN
|
|
11
|
+
> Created: {date}
|
|
12
|
+
> Status: Refined
|
|
13
|
+
|
|
14
|
+
## Overview
|
|
15
|
+
{Brief description of the refined idea}
|
|
16
|
+
|
|
17
|
+
## Problem Statement
|
|
18
|
+
{What problem does this idea solve?}
|
|
19
|
+
|
|
20
|
+
## Target Users
|
|
21
|
+
{Who will benefit?}
|
|
22
|
+
|
|
23
|
+
## Proposed Solution
|
|
24
|
+
{High-level description of the solution}
|
|
25
|
+
|
|
26
|
+
## Key Features
|
|
27
|
+
|
|
28
|
+
{IF antv-infographic enabled → use infographic DSL}
|
|
29
|
+
{IF mermaid enabled → use mermaid for flow}
|
|
30
|
+
{IF both disabled → use bullet list}
|
|
31
|
+
|
|
32
|
+
<!-- Example if antv-infographic: true -->
|
|
33
|
+
```infographic
|
|
34
|
+
infographic list-grid-badge-card
|
|
35
|
+
data
|
|
36
|
+
title Key Features
|
|
37
|
+
lists
|
|
38
|
+
- label Feature 1
|
|
39
|
+
desc Description of feature 1
|
|
40
|
+
icon flash
|
|
41
|
+
- label Feature 2
|
|
42
|
+
desc Description of feature 2
|
|
43
|
+
icon shield
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
<!-- Example if mermaid: true (for user flow) -->
|
|
47
|
+
```mermaid
|
|
48
|
+
flowchart TD
|
|
49
|
+
A[User Action] --> B[Feature 1]
|
|
50
|
+
B --> C[Feature 2]
|
|
51
|
+
```
|
|
52
|
+
|
|
53
|
+
## Success Criteria
|
|
54
|
+
- [ ] Criterion 1
|
|
55
|
+
- [ ] Criterion 2
|
|
56
|
+
|
|
57
|
+
## Constraints & Considerations
|
|
58
|
+
- Constraint 1
|
|
59
|
+
- Constraint 2
|
|
60
|
+
|
|
61
|
+
## Brainstorming Notes
|
|
62
|
+
{Key insights from brainstorming session}
|
|
63
|
+
|
|
64
|
+
## Ideation Artifacts (If Tools Used)
|
|
65
|
+
{Link to any mockups, prototypes, or visual artifacts created during brainstorming}
|
|
66
|
+
- Mockup: {path or description}
|
|
67
|
+
- Prototype: {path or URL}
|
|
68
|
+
|
|
69
|
+
## Source Files
|
|
70
|
+
- file1.md
|
|
71
|
+
- file2.txt
|
|
72
|
+
|
|
73
|
+
## Next Steps
|
|
74
|
+
- [ ] Proceed to Idea Mockup / Idea to Architecture / Requirement Gathering
|
|
75
|
+
|
|
76
|
+
## References & Common Principles
|
|
77
|
+
{Include if the idea involves common/established topics}
|
|
78
|
+
|
|
79
|
+
### Applied Principles
|
|
80
|
+
- **Principle 1:** {Description} - [Source](URL)
|
|
81
|
+
- **Principle 2:** {Description} - [Source](URL)
|
|
82
|
+
|
|
83
|
+
### Further Reading
|
|
84
|
+
- [Resource 1](URL) - {Brief description}
|
|
85
|
+
- [Resource 2](URL) - {Brief description}
|
|
86
|
+
```
|
|
@@ -56,138 +56,18 @@ initial_refactoring_scope:
|
|
|
56
56
|
|
|
57
57
|
## Skill/Task Completion Output Attributes
|
|
58
58
|
|
|
59
|
-
This skill MUST return these attributes to the Task Data Model upon task completion
|
|
59
|
+
This skill MUST return these attributes to the Task Data Model upon task completion.
|
|
60
60
|
|
|
61
|
-
|
|
62
|
-
Output:
|
|
63
|
-
category: code-refactoring-stage
|
|
64
|
-
status: completed | blocked
|
|
65
|
-
next_task_type: Improve Code Quality Before Refactoring
|
|
66
|
-
require_human_review: Yes
|
|
67
|
-
auto_proceed: {from input Auto Proceed}
|
|
68
|
-
task_output_links: [<path to analysis report>]
|
|
69
|
-
|
|
70
|
-
# Dynamic attributes - MUST be passed to next task
|
|
71
|
-
quality_baseline:
|
|
72
|
-
exists: true | false
|
|
73
|
-
evaluated_date: <date from report if exists>
|
|
74
|
-
overall_score: <1-10 if exists>
|
|
75
|
-
code_violations:
|
|
76
|
-
file_size: [<files exceeding 800 lines>]
|
|
77
|
-
approaching_threshold: [<files 500-800 lines>]
|
|
78
|
-
feature_gaps: [<features with violations>]
|
|
79
|
-
test_coverage: <percentage if available>
|
|
80
|
-
|
|
81
|
-
refactoring_scope:
|
|
82
|
-
files: [<expanded list of files>]
|
|
83
|
-
modules: [<expanded list of modules>]
|
|
84
|
-
dependencies: [<identified dependencies>]
|
|
85
|
-
scope_expansion_log: [<log of scope expansions>]
|
|
86
|
-
|
|
87
|
-
code_quality_evaluated:
|
|
88
|
-
requirements_alignment:
|
|
89
|
-
status: aligned | needs_update | not_found
|
|
90
|
-
gaps: [<list of gaps>]
|
|
91
|
-
related_docs: [<paths to requirement docs>]
|
|
92
|
-
|
|
93
|
-
specification_alignment:
|
|
94
|
-
status: aligned | needs_update | not_found
|
|
95
|
-
gaps: [<list of gaps>]
|
|
96
|
-
feature_ids: [<FEATURE-XXX>]
|
|
97
|
-
spec_docs: [<paths to tech design docs>]
|
|
98
|
-
|
|
99
|
-
test_coverage:
|
|
100
|
-
status: sufficient | insufficient | no_tests
|
|
101
|
-
line_coverage: <XX%>
|
|
102
|
-
branch_coverage: <XX%>
|
|
103
|
-
target_percentage: 80
|
|
104
|
-
critical_gaps: [<untested areas>]
|
|
105
|
-
external_api_mocked: true | false
|
|
106
|
-
|
|
107
|
-
code_alignment:
|
|
108
|
-
status: aligned | needs_attention | critical
|
|
109
|
-
|
|
110
|
-
# File Size Analysis (threshold: ≤800 lines)
|
|
111
|
-
file_size_violations:
|
|
112
|
-
- file: <path>
|
|
113
|
-
lines: <count>
|
|
114
|
-
severity: high | medium
|
|
115
|
-
recommendation: "<split suggestion>"
|
|
116
|
-
files_approaching_threshold:
|
|
117
|
-
- file: <path>
|
|
118
|
-
lines: <count>
|
|
119
|
-
buffer: <lines remaining>
|
|
120
|
-
|
|
121
|
-
# SOLID Principles Assessment
|
|
122
|
-
solid_assessment:
|
|
123
|
-
srp: { status: good | partial | violation, notes: "<details>" }
|
|
124
|
-
ocp: { status: good | partial | violation, notes: "<details>" }
|
|
125
|
-
lsp: { status: good | partial | violation, notes: "<details>" }
|
|
126
|
-
isp: { status: good | partial | violation, notes: "<details>" }
|
|
127
|
-
dip: { status: good | partial | violation, notes: "<details>" }
|
|
128
|
-
|
|
129
|
-
# KISS Principle Assessment
|
|
130
|
-
kiss_assessment:
|
|
131
|
-
over_engineering: { status: good | violation, notes: "<details>" }
|
|
132
|
-
straightforward_logic: { status: good | violation, notes: "<details>" }
|
|
133
|
-
minimal_dependencies: { status: good | violation, notes: "<details>" }
|
|
134
|
-
clear_intent: { status: good | violation, notes: "<details>" }
|
|
135
|
-
|
|
136
|
-
# Modular Design Assessment
|
|
137
|
-
modular_design_assessment:
|
|
138
|
-
module_cohesion: { status: good | partial | violation, notes: "<details>" }
|
|
139
|
-
module_coupling: { status: good | partial | violation, notes: "<details>" }
|
|
140
|
-
single_entry_point: { status: good | partial | violation, notes: "<details>" }
|
|
141
|
-
folder_structure: { status: good | partial | violation, notes: "<details>" }
|
|
142
|
-
reusability: { status: good | partial | violation, notes: "<details>" }
|
|
143
|
-
testability: { status: good | partial | violation, notes: "<details>" }
|
|
144
|
-
|
|
145
|
-
# Code Smell Detection
|
|
146
|
-
code_smells:
|
|
147
|
-
- smell: god_class | long_method | large_file | deep_nesting | too_many_params | duplicate_code
|
|
148
|
-
file: <path>
|
|
149
|
-
severity: high | medium | low
|
|
150
|
-
details: "<description>"
|
|
151
|
-
|
|
152
|
-
overall_quality_score: <1-10>
|
|
153
|
-
|
|
154
|
-
refactoring_suggestion:
|
|
155
|
-
summary: "<high-level description of suggested refactoring>"
|
|
156
|
-
goals:
|
|
157
|
-
- goal: "<specific improvement goal>"
|
|
158
|
-
priority: high | medium | low
|
|
159
|
-
rationale: "<why this goal matters>"
|
|
160
|
-
principle: "<SOLID | DRY | KISS | YAGNI | Modular Design | etc.>"
|
|
161
|
-
target_structure: "<description of desired structure after refactoring>"
|
|
162
|
-
|
|
163
|
-
refactoring_principle:
|
|
164
|
-
primary_principles:
|
|
165
|
-
- principle: <SOLID | DRY | KISS | YAGNI | SoC | Modular Design | etc.>
|
|
166
|
-
rationale: "<why this principle applies>"
|
|
167
|
-
applications:
|
|
168
|
-
- area: "<code area>"
|
|
169
|
-
action: "<specific application>"
|
|
170
|
-
secondary_principles:
|
|
171
|
-
- principle: <name>
|
|
172
|
-
rationale: "<supporting rationale>"
|
|
173
|
-
constraints:
|
|
174
|
-
- constraint: "<what to avoid or preserve>"
|
|
175
|
-
reason: "<why this constraint exists>"
|
|
176
|
-
```
|
|
177
|
-
|
|
178
|
-
### Evaluation Thresholds Reference
|
|
61
|
+
See [references/output-schema.md](references/output-schema.md) for the complete output data model schema.
|
|
179
62
|
|
|
180
|
-
|
|
63
|
+
**Key Output Data Models:**
|
|
64
|
+
- `quality_baseline` - Existing quality report data if available
|
|
65
|
+
- `refactoring_scope` - Expanded file/module scope with dependencies
|
|
66
|
+
- `code_quality_evaluated` - Evaluation across all perspectives
|
|
67
|
+
- `refactoring_suggestion` - Goals and target structure
|
|
68
|
+
- `refactoring_principle` - Primary/secondary principles with applications
|
|
181
69
|
|
|
182
|
-
|
|
183
|
-
|----------|-----------|-----------|
|
|
184
|
-
| Test | Line Coverage | ≥ 80% |
|
|
185
|
-
| Test | Branch Coverage | ≥ 70% |
|
|
186
|
-
| Test | Mock External APIs | Required |
|
|
187
|
-
| Code | File Size | ≤ 800 lines |
|
|
188
|
-
| Code | Function Size | ≤ 50 lines |
|
|
189
|
-
| Code | Class Size | ≤ 500 lines |
|
|
190
|
-
| Code | Cyclomatic Complexity | ≤ 10 |
|
|
70
|
+
**Evaluation Thresholds:** Line Coverage ≥80%, File Size ≤800 lines, Function Size ≤50 lines
|
|
191
71
|
|
|
192
72
|
---
|
|
193
73
|
|
|
@@ -357,7 +237,7 @@ IF iteration > 10:
|
|
|
357
237
|
|
|
358
238
|
### Steps 3-6: Evaluate Quality Perspectives
|
|
359
239
|
|
|
360
|
-
**Action:** Evaluate code quality across
|
|
240
|
+
**Action:** Evaluate code quality across 5 perspectives
|
|
361
241
|
|
|
362
242
|
**Step 3 - Requirements Alignment:**
|
|
363
243
|
```
|
|
@@ -388,11 +268,35 @@ IF iteration > 10:
|
|
|
388
268
|
4. COMPILE test_coverage: {status, current_percentage, critical_gaps[]}
|
|
389
269
|
```
|
|
390
270
|
|
|
271
|
+
**Step 6b - Tracing Coverage (FEATURE-023-D):**
|
|
272
|
+
```
|
|
273
|
+
1. SCAN code files for @x_ipe_tracing decorator usage:
|
|
274
|
+
- grep -r "@x_ipe_tracing" src/
|
|
275
|
+
- Count decorated vs total public functions
|
|
276
|
+
|
|
277
|
+
2. FOR EACH file in scope:
|
|
278
|
+
- List public functions (def/async def at module level, class methods)
|
|
279
|
+
- Check if decorated with @x_ipe_tracing
|
|
280
|
+
- Flag missing decorators
|
|
281
|
+
|
|
282
|
+
3. CHECK sensitive parameter redaction:
|
|
283
|
+
- Search for password, token, secret, key, auth parameters
|
|
284
|
+
- Verify redact=[] is specified for these
|
|
285
|
+
|
|
286
|
+
4. COMPILE tracing_coverage: {
|
|
287
|
+
status: passed|warning|failed,
|
|
288
|
+
coverage_percentage: X%,
|
|
289
|
+
untraced_functions: [],
|
|
290
|
+
unredacted_params: []
|
|
291
|
+
}
|
|
292
|
+
```
|
|
293
|
+
|
|
391
294
|
**Gap Types by Perspective:**
|
|
392
295
|
- Requirements: undocumented | unimplemented | deviated
|
|
393
296
|
- Features: missing | extra | deviated
|
|
394
297
|
- Tech Spec: structure | interface | data_model | pattern
|
|
395
298
|
- Test Coverage: business_logic | error_handling | edge_case
|
|
299
|
+
- Tracing Coverage: untraced | unredacted | wrong_level
|
|
396
300
|
|
|
397
301
|
---
|
|
398
302
|
|
|
@@ -470,14 +374,31 @@ IF iteration > 10:
|
|
|
470
374
|
**Action:** Compile final analysis and request human review
|
|
471
375
|
|
|
472
376
|
```
|
|
473
|
-
1. CALCULATE
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
377
|
+
1. CALCULATE dimension scores (1-10 each):
|
|
378
|
+
FOR EACH dimension (requirements, features, tech_spec, test_coverage, tracing):
|
|
379
|
+
score = 10 - SUM(violations × importance_weights)
|
|
380
|
+
score = MAX(1, MIN(10, score)) # Clamp to 1-10
|
|
381
|
+
|
|
382
|
+
# Derive status from score
|
|
383
|
+
IF score >= 8: status = "aligned"
|
|
384
|
+
ELSE IF score >= 6: status = "needs_attention"
|
|
385
|
+
ELSE: status = "critical"
|
|
479
386
|
|
|
480
|
-
|
|
387
|
+
Importance weights:
|
|
388
|
+
- Critical (no tests, hardcoded secrets): 3
|
|
389
|
+
- High (missing coverage, SRP/DRY violations): 2
|
|
390
|
+
- Medium (outdated specs, missing docs): 1
|
|
391
|
+
- Low (minor style issues): 0.5
|
|
392
|
+
|
|
393
|
+
2. CALCULATE overall_quality_score:
|
|
394
|
+
overall_quality_score = weighted_average(
|
|
395
|
+
requirements_score × 0.20,
|
|
396
|
+
features_score × 0.20,
|
|
397
|
+
tech_spec_score × 0.20,
|
|
398
|
+
test_coverage_score × 0.20,
|
|
399
|
+
tracing_score × 0.10,
|
|
400
|
+
code_alignment_score × 0.10
|
|
401
|
+
)
|
|
481
402
|
|
|
482
403
|
2. GENERATE analysis report:
|
|
483
404
|
- Save to x-ipe-docs/refactoring/analysis-{task_id}.md
|
|
@@ -486,17 +407,33 @@ IF iteration > 10:
|
|
|
486
407
|
- Include full refactoring_suggestion
|
|
487
408
|
- Include full refactoring_principle
|
|
488
409
|
|
|
489
|
-
3.
|
|
410
|
+
3. SELF-REVIEW report:
|
|
411
|
+
a. READ the generated report completely
|
|
412
|
+
b. CHECK for:
|
|
413
|
+
- Missing content or sections
|
|
414
|
+
- Inconsistencies between summary and details
|
|
415
|
+
- Scope items not evaluated
|
|
416
|
+
- Gaps without proper severity assignment
|
|
417
|
+
- Suggestions that don't match identified gaps
|
|
418
|
+
- Principles without clear applications
|
|
419
|
+
c. IF problems found:
|
|
420
|
+
- FIX the issues in the report
|
|
421
|
+
- Note corrections made
|
|
422
|
+
|
|
423
|
+
4. PRESENT to human:
|
|
490
424
|
"Refactoring Analysis Complete
|
|
491
425
|
|
|
492
426
|
Scope: {file_count} files, {module_count} modules
|
|
493
427
|
Expansions: {expansion_count} iterations
|
|
494
428
|
|
|
495
|
-
Quality Assessment:
|
|
496
|
-
- Requirements: {status}
|
|
497
|
-
- Features: {status}
|
|
498
|
-
- Tech Spec: {status}
|
|
499
|
-
- Test Coverage: {
|
|
429
|
+
Quality Assessment (Score → Status):
|
|
430
|
+
- Requirements: {req_score}/10 → {status}
|
|
431
|
+
- Features: {feature_score}/10 → {status}
|
|
432
|
+
- Tech Spec: {tech_score}/10 → {status}
|
|
433
|
+
- Test Coverage: {test_score}/10 ({current}%)
|
|
434
|
+
- Tracing: {tracing_score}/10
|
|
435
|
+
|
|
436
|
+
Score-to-Status: 8-10 aligned, 6-7 needs_attention, 1-5 critical
|
|
500
437
|
|
|
501
438
|
Overall Score: {score}/10
|
|
502
439
|
|
|
@@ -507,7 +444,7 @@ IF iteration > 10:
|
|
|
507
444
|
|
|
508
445
|
Approve to proceed to Improve Code Quality Before Refactoring?"
|
|
509
446
|
|
|
510
|
-
|
|
447
|
+
5. WAIT for human approval
|
|
511
448
|
```
|
|
512
449
|
|
|
513
450
|
---
|
|
@@ -525,7 +462,8 @@ IF iteration > 10:
|
|
|
525
462
|
| 7 | Refactoring suggestions generated | Yes |
|
|
526
463
|
| 8 | Refactoring principles identified | Yes |
|
|
527
464
|
| 9 | Analysis report generated | Yes |
|
|
528
|
-
| 10 |
|
|
465
|
+
| 10 | Report self-review completed (check for problems or missing content) | Yes |
|
|
466
|
+
| 11 | Human review approved | Yes |
|
|
529
467
|
|
|
530
468
|
**Important:** After completing this skill, always return to `task-execution-guideline` skill to continue the task execution flow and validate the DoD defined there.
|
|
531
469
|
|
|
@@ -0,0 +1,172 @@
|
|
|
1
|
+
# Output Schema Reference
|
|
2
|
+
|
|
3
|
+
This document contains the complete output data model schema for the Refactoring Analysis task type.
|
|
4
|
+
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
## Complete Output Attributes
|
|
8
|
+
|
|
9
|
+
```yaml
|
|
10
|
+
Output:
|
|
11
|
+
category: code-refactoring-stage
|
|
12
|
+
status: completed | blocked
|
|
13
|
+
next_task_type: Improve Code Quality Before Refactoring
|
|
14
|
+
require_human_review: Yes
|
|
15
|
+
auto_proceed: {from input Auto Proceed}
|
|
16
|
+
task_output_links: [<path to analysis report>]
|
|
17
|
+
|
|
18
|
+
# Dynamic attributes - MUST be passed to next task
|
|
19
|
+
quality_baseline:
|
|
20
|
+
exists: true | false
|
|
21
|
+
evaluated_date: <date from report if exists>
|
|
22
|
+
overall_score: <1-10 if exists>
|
|
23
|
+
code_violations:
|
|
24
|
+
file_size: [<files exceeding 800 lines>]
|
|
25
|
+
approaching_threshold: [<files 500-800 lines>]
|
|
26
|
+
feature_gaps: [<features with violations>]
|
|
27
|
+
test_coverage: <percentage if available>
|
|
28
|
+
|
|
29
|
+
refactoring_scope:
|
|
30
|
+
files: [<expanded list of files>]
|
|
31
|
+
modules: [<expanded list of modules>]
|
|
32
|
+
dependencies: [<identified dependencies>]
|
|
33
|
+
scope_expansion_log: [<log of scope expansions>]
|
|
34
|
+
|
|
35
|
+
code_quality_evaluated:
|
|
36
|
+
# Each dimension uses score grid: 8-10 aligned, 6-7 needs_attention, 1-5 critical
|
|
37
|
+
# Score = 10 - SUM(violations × importance_weight)
|
|
38
|
+
# Importance weights: critical=3, high=2, medium=1, low=0.5
|
|
39
|
+
|
|
40
|
+
requirements_alignment:
|
|
41
|
+
score: <1-10> # Calculated from violations × importance
|
|
42
|
+
status: aligned | needs_attention | critical # Derived: 8-10=aligned, 6-7=needs_attention, 1-5=critical
|
|
43
|
+
gaps: [<list of gaps>]
|
|
44
|
+
related_docs: [<paths to requirement docs>]
|
|
45
|
+
violations:
|
|
46
|
+
- type: <undocumented | unimplemented | deviated>
|
|
47
|
+
importance: critical | high | medium | low
|
|
48
|
+
weight: <3 | 2 | 1 | 0.5>
|
|
49
|
+
|
|
50
|
+
specification_alignment:
|
|
51
|
+
score: <1-10>
|
|
52
|
+
status: aligned | needs_attention | critical
|
|
53
|
+
gaps: [<list of gaps>]
|
|
54
|
+
feature_ids: [<FEATURE-XXX>]
|
|
55
|
+
spec_docs: [<paths to tech design docs>]
|
|
56
|
+
violations:
|
|
57
|
+
- type: <missing | outdated | incorrect>
|
|
58
|
+
importance: critical | high | medium | low
|
|
59
|
+
weight: <3 | 2 | 1 | 0.5>
|
|
60
|
+
|
|
61
|
+
test_coverage:
|
|
62
|
+
score: <1-10>
|
|
63
|
+
status: aligned | needs_attention | critical
|
|
64
|
+
line_coverage: <XX%>
|
|
65
|
+
branch_coverage: <XX%>
|
|
66
|
+
target_percentage: 80
|
|
67
|
+
critical_gaps: [<untested areas>]
|
|
68
|
+
external_api_mocked: true | false
|
|
69
|
+
violations:
|
|
70
|
+
- type: <no_tests | low_coverage | critical_untested>
|
|
71
|
+
importance: critical | high | medium | low
|
|
72
|
+
weight: <3 | 2 | 1 | 0.5>
|
|
73
|
+
|
|
74
|
+
code_alignment:
|
|
75
|
+
score: <1-10>
|
|
76
|
+
status: aligned | needs_attention | critical
|
|
77
|
+
|
|
78
|
+
# File Size Analysis (threshold: ≤800 lines)
|
|
79
|
+
file_size_violations:
|
|
80
|
+
- file: <path>
|
|
81
|
+
lines: <count>
|
|
82
|
+
severity: high | medium
|
|
83
|
+
recommendation: "<split suggestion>"
|
|
84
|
+
files_approaching_threshold:
|
|
85
|
+
- file: <path>
|
|
86
|
+
lines: <count>
|
|
87
|
+
buffer: <lines remaining>
|
|
88
|
+
|
|
89
|
+
# SOLID Principles Assessment
|
|
90
|
+
solid_assessment:
|
|
91
|
+
srp: { status: good | partial | violation, notes: "<details>" }
|
|
92
|
+
ocp: { status: good | partial | violation, notes: "<details>" }
|
|
93
|
+
lsp: { status: good | partial | violation, notes: "<details>" }
|
|
94
|
+
isp: { status: good | partial | violation, notes: "<details>" }
|
|
95
|
+
dip: { status: good | partial | violation, notes: "<details>" }
|
|
96
|
+
|
|
97
|
+
# KISS Principle Assessment
|
|
98
|
+
kiss_assessment:
|
|
99
|
+
over_engineering: { status: good | violation, notes: "<details>" }
|
|
100
|
+
straightforward_logic: { status: good | violation, notes: "<details>" }
|
|
101
|
+
minimal_dependencies: { status: good | violation, notes: "<details>" }
|
|
102
|
+
clear_intent: { status: good | violation, notes: "<details>" }
|
|
103
|
+
|
|
104
|
+
# Modular Design Assessment
|
|
105
|
+
modular_design_assessment:
|
|
106
|
+
module_cohesion: { status: good | partial | violation, notes: "<details>" }
|
|
107
|
+
module_coupling: { status: good | partial | violation, notes: "<details>" }
|
|
108
|
+
single_entry_point: { status: good | partial | violation, notes: "<details>" }
|
|
109
|
+
folder_structure: { status: good | partial | violation, notes: "<details>" }
|
|
110
|
+
reusability: { status: good | partial | violation, notes: "<details>" }
|
|
111
|
+
testability: { status: good | partial | violation, notes: "<details>" }
|
|
112
|
+
|
|
113
|
+
# Code Smell Detection
|
|
114
|
+
code_smells:
|
|
115
|
+
- smell: god_class | long_method | large_file | deep_nesting | too_many_params | duplicate_code
|
|
116
|
+
file: <path>
|
|
117
|
+
severity: high | medium | low
|
|
118
|
+
details: "<description>"
|
|
119
|
+
|
|
120
|
+
overall_quality_score: <1-10>
|
|
121
|
+
|
|
122
|
+
refactoring_suggestion:
|
|
123
|
+
summary: "<high-level description of suggested refactoring>"
|
|
124
|
+
goals:
|
|
125
|
+
- goal: "<specific improvement goal>"
|
|
126
|
+
priority: high | medium | low
|
|
127
|
+
rationale: "<why this goal matters>"
|
|
128
|
+
principle: "<SOLID | DRY | KISS | YAGNI | Modular Design | etc.>"
|
|
129
|
+
target_structure: "<description of desired structure after refactoring>"
|
|
130
|
+
|
|
131
|
+
refactoring_principle:
|
|
132
|
+
primary_principles:
|
|
133
|
+
- principle: <SOLID | DRY | KISS | YAGNI | SoC | Modular Design | etc.>
|
|
134
|
+
rationale: "<why this principle applies>"
|
|
135
|
+
applications:
|
|
136
|
+
- area: "<code area>"
|
|
137
|
+
action: "<specific application>"
|
|
138
|
+
secondary_principles:
|
|
139
|
+
- principle: <name>
|
|
140
|
+
rationale: "<supporting rationale>"
|
|
141
|
+
constraints:
|
|
142
|
+
- constraint: "<what to avoid or preserve>"
|
|
143
|
+
reason: "<why this constraint exists>"
|
|
144
|
+
```
|
|
145
|
+
|
|
146
|
+
---
|
|
147
|
+
|
|
148
|
+
## Evaluation Thresholds
|
|
149
|
+
|
|
150
|
+
> These thresholds align with `project-quality-board-management` skill.
|
|
151
|
+
|
|
152
|
+
| Category | Principle | Threshold |
|
|
153
|
+
|----------|-----------|-----------|
|
|
154
|
+
| Test | Line Coverage | ≥ 80% |
|
|
155
|
+
| Test | Branch Coverage | ≥ 70% |
|
|
156
|
+
| Test | Mock External APIs | Required |
|
|
157
|
+
| Code | File Size | ≤ 800 lines |
|
|
158
|
+
| Code | Function Size | ≤ 50 lines |
|
|
159
|
+
| Code | Class Size | ≤ 500 lines |
|
|
160
|
+
| Code | Cyclomatic Complexity | ≤ 10 |
|
|
161
|
+
|
|
162
|
+
---
|
|
163
|
+
|
|
164
|
+
## Gap Types by Perspective
|
|
165
|
+
|
|
166
|
+
| Perspective | Gap Types |
|
|
167
|
+
|-------------|-----------|
|
|
168
|
+
| Requirements | undocumented, unimplemented, deviated |
|
|
169
|
+
| Features | missing, extra, deviated |
|
|
170
|
+
| Tech Spec | structure, interface, data_model, pattern |
|
|
171
|
+
| Test Coverage | business_logic, error_handling, edge_case |
|
|
172
|
+
| Tracing Coverage | untraced, unredacted, wrong_level |
|