@laitszkin/apollo-toolkit 3.1.2 → 3.1.3
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.
- package/CHANGELOG.md +5 -0
- package/analyse-app-logs/scripts/__pycache__/filter_logs_by_time.cpython-312.pyc +0 -0
- package/analyse-app-logs/scripts/__pycache__/log_cli_utils.cpython-312.pyc +0 -0
- package/analyse-app-logs/scripts/__pycache__/search_logs.cpython-312.pyc +0 -0
- package/docs-to-voice/scripts/__pycache__/docs_to_voice.cpython-312.pyc +0 -0
- package/generate-spec/scripts/__pycache__/create-specscpython-312.pyc +0 -0
- package/iterative-code-quality/README.md +2 -1
- package/iterative-code-quality/SKILL.md +13 -7
- package/iterative-code-quality/agents/openai.yaml +1 -1
- package/iterative-code-quality/references/iteration-gates.md +12 -4
- package/iterative-code-quality/references/naming-and-simplification.md +2 -0
- package/iterative-code-quality/references/testing-strategy.md +3 -0
- package/katex/scripts/__pycache__/render_katex.cpython-312.pyc +0 -0
- package/open-github-issue/scripts/__pycache__/open_github_issue.cpython-312.pyc +0 -0
- package/package.json +1 -1
- package/read-github-issue/scripts/__pycache__/find_issues.cpython-312.pyc +0 -0
- package/read-github-issue/scripts/__pycache__/read_issue.cpython-312.pyc +0 -0
- package/resolve-review-comments/scripts/__pycache__/review_threads.cpython-312.pyc +0 -0
- package/text-to-short-video/scripts/__pycache__/enforce_video_aspect_ratio.cpython-312.pyc +0 -0
package/CHANGELOG.md
CHANGED
|
@@ -7,6 +7,11 @@ All notable changes to this repository are documented in this file.
|
|
|
7
7
|
### Changed
|
|
8
8
|
- None yet.
|
|
9
9
|
|
|
10
|
+
## [v3.1.3] - 2026-04-23
|
|
11
|
+
|
|
12
|
+
### Changed
|
|
13
|
+
- Tighten `iterative-code-quality` so agents must keep iterating while any known in-scope actionable quality issue remains, must not produce a completion report until the latest scan is clear or remaining candidates are explicitly classified as blocked, unsafe, low-value, speculative, or approval-dependent, and should use tests or equivalent guardrails to support more aggressive refactors instead of deferring them for subjective confidence reasons.
|
|
14
|
+
|
|
10
15
|
## [v3.1.2] - 2026-04-23
|
|
11
16
|
|
|
12
17
|
### Changed
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -10,7 +10,8 @@ Improve an existing repository through repeated, evidence-backed code-quality pa
|
|
|
10
10
|
- Splits mixed-responsibility code into narrower modules without changing macro architecture.
|
|
11
11
|
- Repairs stale or missing logs and adds tests for important observability contracts.
|
|
12
12
|
- Adds high-value unit, property-based, integration, or E2E tests based on risk.
|
|
13
|
-
-
|
|
13
|
+
- Uses those tests and other guardrails to justify more aggressive refactors, instead of leaving known issues in place for subjective confidence reasons.
|
|
14
|
+
- Repeats the pass cycle while any known in-scope actionable quality issue remains, and forbids a completion report until the latest scan is clear or remaining items are explicitly deferred with a valid reason.
|
|
14
15
|
- Synchronizes project docs and `AGENTS.md` through `align-project-documents` and `maintain-project-constraints` after implementation.
|
|
15
16
|
|
|
16
17
|
## Repository structure
|
|
@@ -22,15 +22,15 @@ description: >-
|
|
|
22
22
|
## Standards
|
|
23
23
|
|
|
24
24
|
- Evidence: Read repository docs, project constraints, source, tests, logs, and entrypoints before editing; every rename, extraction, split, log update, or test must be backed by code context.
|
|
25
|
-
- Execution: Work in bounded passes, prioritize behavior-neutral improvements with the highest maintainability and test value, validate after each pass, and
|
|
26
|
-
- Quality: Preserve business behavior and macro architecture unless tests expose an existing logic defect; avoid style-only churn, compatibility theater, broad rewrites, and unverified "cleanup".
|
|
27
|
-
- Output: Deliver a concise pass-by-pass summary, changed behavior-neutral surfaces, test coverage added, validation results,
|
|
25
|
+
- Execution: Work in bounded passes, prioritize behavior-neutral improvements with the highest maintainability and test value, validate after each pass, and keep iterating while any known in-scope codebase quality issue remains unresolved; when tests or other reliable guardrails can prove equivalence, prefer taking the refactor instead of deferring it for subjective confidence reasons; do not produce the completion report while the scan still contains actionable gaps.
|
|
26
|
+
- Quality: Preserve business behavior and macro architecture unless tests expose an existing logic defect; avoid style-only churn, compatibility theater, broad rewrites, and unverified "cleanup", but do not reject a worthwhile refactor purely because it feels risky when existing or newly added guardrails can verify it safely.
|
|
27
|
+
- Output: Deliver a concise pass-by-pass summary, changed behavior-neutral surfaces, test coverage added, validation results, and documentation/`AGENTS.md` sync status only after every known in-scope quality issue is resolved or explicitly classified as blocked, unsafe, low-value, speculative, or requiring user approval.
|
|
28
28
|
|
|
29
29
|
## Goal
|
|
30
30
|
|
|
31
31
|
Raise code quality across an existing repository without changing intended product behavior or the system's macro architecture.
|
|
32
32
|
|
|
33
|
-
This skill is intentionally implementation-oriented, not report-only. It should identify high-value improvements, apply them, test them, and keep iterating until
|
|
33
|
+
This skill is intentionally implementation-oriented, not report-only. It should identify high-value improvements, apply them, test them, and keep iterating across the codebase until there are no unresolved known in-scope quality issues. If a post-pass scan finds remaining actionable gaps, continue the next pass instead of writing a completion report.
|
|
34
34
|
|
|
35
35
|
## Required Reference Loading
|
|
36
36
|
|
|
@@ -71,6 +71,7 @@ For each pass:
|
|
|
71
71
|
- Prefer repository-native abstractions over new parallel frameworks.
|
|
72
72
|
- Preserve public behavior, data contracts, side effects, error classes, and macro architecture.
|
|
73
73
|
- Add or update tests in the same pass when the change touches non-trivial logic, observability contracts, or extracted helpers.
|
|
74
|
+
- If strong guardrails exist or can be added cheaply, prefer the clearer or more maintainable refactor instead of leaving a known issue in place due to subjective caution alone.
|
|
74
75
|
- Validate the touched scope before starting another pass.
|
|
75
76
|
|
|
76
77
|
### 3) Rename for clarity without churn
|
|
@@ -87,6 +88,7 @@ For each pass:
|
|
|
87
88
|
- Extract helpers only when they reduce duplication, centralize one business rule, clarify caller intent, or make a behavior testable.
|
|
88
89
|
- Keep helper placement aligned with current module ownership.
|
|
89
90
|
- Do not create abstractions for one-off code unless they isolate a meaningful domain rule or external contract.
|
|
91
|
+
- If tests or equivalent guardrails can prove behavior preservation, do not let moderate implementation uncertainty block an otherwise valuable simplification or extraction.
|
|
90
92
|
- Preserve observable behavior unless a test proves the current behavior is a defect.
|
|
91
93
|
|
|
92
94
|
### 5) Split modules by responsibility
|
|
@@ -95,6 +97,7 @@ For each pass:
|
|
|
95
97
|
- Define the new module's responsibility before moving code.
|
|
96
98
|
- Keep interfaces narrow, explicit, and consistent with existing project style.
|
|
97
99
|
- Avoid macro-architecture changes such as new layers, new service boundaries, new persistence strategies, or framework swaps unless the user explicitly expands scope.
|
|
100
|
+
- When module boundaries are currently poor but can be protected by focused tests or other guardrails, choose the cleaner split instead of preserving a mixed-responsibility file out of caution alone.
|
|
98
101
|
- Use `references/module-boundaries.md` for extraction rules and anti-patterns.
|
|
99
102
|
|
|
100
103
|
### 6) Repair logging and observability drift
|
|
@@ -118,9 +121,10 @@ For each pass:
|
|
|
118
121
|
### 8) Iterate until quality gates pass
|
|
119
122
|
|
|
120
123
|
- After each pass, run the narrowest relevant tests first, then broaden validation when confidence increases.
|
|
121
|
-
- Re-scan touched areas for new naming drift, duplicated helper candidates, module-boundary cracks, logging drift, and missing tests.
|
|
122
|
-
- Repeat the full pass cycle
|
|
123
|
-
-
|
|
124
|
+
- Re-scan both touched areas and the known quality backlog for new naming drift, duplicated helper candidates, module-boundary cracks, logging drift, and missing tests.
|
|
125
|
+
- Repeat the full pass cycle whenever any known in-scope actionable gap remains and can be fixed safely without changing business behavior or macro architecture.
|
|
126
|
+
- Do not write the completion report, summarize the task as done, or hand back as complete while the latest scan still contains known actionable quality issues.
|
|
127
|
+
- Stop only when every known in-scope issue has been resolved, or each remaining candidate is explicitly classified as low-value, speculative, blocked, unsafe, or requiring product/architecture approval.
|
|
124
128
|
- Use `references/iteration-gates.md` for stopping criteria.
|
|
125
129
|
|
|
126
130
|
### 9) Synchronize docs and constraints
|
|
@@ -142,6 +146,8 @@ After code and tests are complete:
|
|
|
142
146
|
|
|
143
147
|
## Completion Report
|
|
144
148
|
|
|
149
|
+
Only write this report after the latest scan confirms there are no known actionable in-scope quality issues remaining. If any such issue remains, continue iterating instead of reporting completion.
|
|
150
|
+
|
|
145
151
|
Return:
|
|
146
152
|
|
|
147
153
|
1. Passes completed and why they were ordered that way.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
interface:
|
|
2
2
|
display_name: "Iterative Code Quality"
|
|
3
3
|
short_description: "Refactor names, functions, modules, logs, and tests in repeated behavior-safe passes"
|
|
4
|
-
default_prompt: "Use $iterative-code-quality to scan this repository, build an evidence-backed quality backlog, then iteratively clarify variable names, simplify or extract reusable functions, split code into single-responsibility modules, repair stale or missing logs, and add high-value unit/property/integration/E2E tests while preserving business behavior and macro architecture;
|
|
4
|
+
default_prompt: "Use $iterative-code-quality to scan this repository, build an evidence-backed quality backlog, then iteratively clarify variable names, simplify or extract reusable functions, split code into single-responsibility modules, repair stale or missing logs, and add high-value unit/property/integration/E2E tests while preserving business behavior and macro architecture; when tests or other reliable guardrails exist or can be added cheaply, use them to justify a more aggressive refactor instead of deferring worthwhile cleanup for subjective confidence reasons; if the latest scan still contains any known in-scope actionable quality issue, do not write a completion report and continue the next bounded iteration instead; after all known actionable issues are resolved or explicitly classified as blocked, unsafe, low-value, speculative, or requiring approval, run $align-project-documents and $maintain-project-constraints to synchronize docs and AGENTS.md."
|
|
@@ -10,7 +10,7 @@ Each pass must have:
|
|
|
10
10
|
- validation plan,
|
|
11
11
|
- rollback point if evidence contradicts the change.
|
|
12
12
|
|
|
13
|
-
Avoid starting a broad second pass before validating the first.
|
|
13
|
+
Avoid starting a broad second pass before validating the first, but do not stop after a validated pass if known actionable quality issues remain anywhere in the in-scope codebase.
|
|
14
14
|
|
|
15
15
|
## Validation cadence
|
|
16
16
|
|
|
@@ -28,9 +28,11 @@ If validation fails:
|
|
|
28
28
|
- keep regression coverage for real defects,
|
|
29
29
|
- do not mask failures by weakening assertions.
|
|
30
30
|
|
|
31
|
+
If validation passes and the guardrails meaningfully cover the changed behavior, do not keep a known quality issue in place purely because of subjective confidence concerns.
|
|
32
|
+
|
|
31
33
|
## Re-scan after each pass
|
|
32
34
|
|
|
33
|
-
Inspect touched areas for:
|
|
35
|
+
Inspect touched areas and the full known quality backlog for:
|
|
34
36
|
|
|
35
37
|
- new naming drift from moved or extracted concepts,
|
|
36
38
|
- duplicated logic that remains after extraction,
|
|
@@ -43,15 +45,18 @@ Inspect touched areas for:
|
|
|
43
45
|
|
|
44
46
|
Repeat the cycle when:
|
|
45
47
|
|
|
48
|
+
- any known in-scope actionable quality issue remains unresolved,
|
|
46
49
|
- high-impact unclear names remain,
|
|
47
50
|
- duplicated or hard-coded workflows still have safe extraction paths,
|
|
48
51
|
- a module still mixes distinct responsibilities and can be split locally,
|
|
49
52
|
- logs are still misleading or missing at critical decisions,
|
|
50
53
|
- high-value business logic remains untested and is testable.
|
|
51
54
|
|
|
55
|
+
Do not produce a final completion report while any item in this section is true. Continue with the next bounded pass instead.
|
|
56
|
+
|
|
52
57
|
## Stop when
|
|
53
58
|
|
|
54
|
-
Stop when remaining candidates
|
|
59
|
+
Stop only when there are no unresolved known in-scope actionable issues. Any remaining candidates must be explicitly classified as one of:
|
|
55
60
|
|
|
56
61
|
- low-value style preference,
|
|
57
62
|
- speculative without concrete evidence,
|
|
@@ -61,6 +66,8 @@ Stop when remaining candidates are:
|
|
|
61
66
|
- blocked by unavailable credentials, unstable external systems, or missing documentation,
|
|
62
67
|
- untestable with the current repository tooling and too risky to change safely.
|
|
63
68
|
|
|
69
|
+
If a remaining candidate cannot be placed in one of these categories, it is still an actionable gap and the agent must continue iterating rather than complete the task.
|
|
70
|
+
|
|
64
71
|
## Completion evidence
|
|
65
72
|
|
|
66
73
|
The final report should make the stopping point auditable:
|
|
@@ -70,4 +77,5 @@ The final report should make the stopping point auditable:
|
|
|
70
77
|
- tests added by risk category,
|
|
71
78
|
- behavior-preservation evidence,
|
|
72
79
|
- docs and constraints sync status,
|
|
73
|
-
-
|
|
80
|
+
- proof that the latest scan found no known actionable in-scope quality issues,
|
|
81
|
+
- deferred items with reason and required approval, dependency, or safety constraint.
|
|
@@ -69,3 +69,5 @@ Before and after simplification, verify:
|
|
|
69
69
|
- public API and CLI behavior remain stable,
|
|
70
70
|
- log fields remain compatible unless stale names were intentionally corrected,
|
|
71
71
|
- existing tests still pass and new tests cover extracted rules.
|
|
72
|
+
|
|
73
|
+
If these checks can be enforced by existing or newly added tests, do not treat subjective confidence alone as a reason to avoid the simplification.
|
|
@@ -6,6 +6,8 @@ Choose tests from the risk inventory, not from a generic coverage target.
|
|
|
6
6
|
|
|
7
7
|
For every non-trivial pass, ask what could regress silently if the cleanup were wrong.
|
|
8
8
|
|
|
9
|
+
Use the resulting guardrails aggressively: when tests or equivalent verification can prove behavior preservation, they should unlock bolder refactors rather than merely justify small cosmetic edits.
|
|
10
|
+
|
|
9
11
|
## Unit tests
|
|
10
12
|
|
|
11
13
|
Use for:
|
|
@@ -76,3 +78,4 @@ Consider:
|
|
|
76
78
|
- Preserve failing seeds or examples from property-based tests.
|
|
77
79
|
- Do not weaken existing tests to fit the refactor.
|
|
78
80
|
- If old tests asserted implementation details, rewrite them around stable behavior while preserving the business invariant.
|
|
81
|
+
- Once stable guardrails exist, do not refuse a maintainability-improving refactor purely because confidence feels lower than ideal; let the guardrails decide.
|
|
Binary file
|
|
Binary file
|
package/package.json
CHANGED
|
Binary file
|
|
Binary file
|
|
Binary file
|