@laitszkin/apollo-toolkit 2.11.2 → 2.11.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.
@@ -15,9 +15,9 @@ description: "Guide the agent to submit local changes with commit and push only
15
15
  ## Standards
16
16
 
17
17
  - Evidence: Inspect git state and classify the change set before deciding which quality gates apply.
18
- - Execution: Run the required quality-gate skills when applicable, convert completed spec sets into categorized project docs during submission, normalize non-standard project docs when needed, preserve staging intent, then commit and push without release steps.
19
- - Quality: Re-run relevant validation for runtime changes and keep project docs plus agent constraints synchronized before committing; treat `archive-specs` outputs as the canonical project-doc structure when normalization is required.
20
- - Output: Produce a concise Conventional Commit and push it to the current branch only.
18
+ - Execution: Run the required quality-gate skills when applicable, convert completed spec sets into categorized project docs during submission, normalize non-standard project docs when needed, preserve staging intent, honor any explicit user-specified target branch, then commit and push without release steps.
19
+ - Quality: Re-run relevant validation for runtime changes, keep project docs plus agent constraints synchronized before committing, and preserve unrelated local work safely when branch switching or post-push local sync is required; treat `archive-specs` outputs as the canonical project-doc structure when normalization is required.
20
+ - Output: Produce a concise Conventional Commit, push it to the intended branch, and report any temporary stash/restore or local branch sync that was required.
21
21
 
22
22
  ## Overview
23
23
 
@@ -43,29 +43,36 @@ Load only when needed:
43
43
  - `repo-specs-ready-for-conversion`: the relevant `spec.md`, `tasks.md`, and `checklist.md` have been updated to reflect the actual outcome of the work, and any unchecked task/decision checkbox that is clearly not selected, replaced, deferred, or `N/A` (for example, E2E intentionally not created) does not by itself mean the spec set is unfinished.
44
44
  - `project-doc-structure-mismatch`: existing `README.md` and project docs do not match the categorized structure required by `archive-specs`.
45
45
  - Treat a spec set as still active when it documents remaining implementation gaps, follow-up integration work, undecided design work, or deferred tasks that still belong to the same in-flight change.
46
- 3. Run code-affecting dependency skills (when applicable)
46
+ 3. Resolve branch target before mutating history
47
+ - Treat an explicit user-specified destination such as `main`, `origin/main`, or another named branch as authoritative over the current branch.
48
+ - If the current branch does not match the requested destination, inspect `git status --short` for unrelated local changes before switching branches.
49
+ - Preserve unrelated uncommitted work safely before branch operations, for example with `git stash push`, and restore it after the target branch has been updated.
50
+ - If the fix was committed on the wrong branch, move it to the requested branch with safe history-preserving operations such as `cherry-pick`, `merge --ff-only`, or a clean replay; do not force-push unless the user explicitly asks for it.
51
+ - If the user asks to sync the local target branch after pushing, fast-forward or pull that branch locally and then restore any preserved worktree changes.
52
+ 4. Run code-affecting dependency skills (when applicable)
47
53
  - Run `review-change-set`, `discover-edge-cases`, and `harden-app-security` for the same code-affecting scope when their coverage is needed.
48
54
  - Consolidate and resolve all confirmed findings before continuing.
49
55
  - Re-run relevant tests when runtime logic changes.
50
- 4. Standardize project docs when specs or doc normalization is needed
56
+ 5. Standardize project docs when specs or doc normalization is needed
51
57
  - During submission, execute `archive-specs` when `repo-specs-ready-for-conversion` is true or when `project-doc-structure-mismatch` is true.
52
58
  - Let `archive-specs` convert the relevant specs into categorized project docs such as `docs/README.md`, `docs/getting-started.md`, `docs/configuration.md`, `docs/architecture.md`, `docs/features.md`, and `docs/developer-guide.md`.
53
59
  - Let the skill normalize any existing project docs to the same structure and archive superseded source spec files.
54
60
  - Do not treat unchecked task or decision checkboxes alone as blocking unfinished work; read the surrounding notes and requirement status semantically.
55
61
  - If the docs still show unresolved implementation scope that is neither completed, intentionally deferred, nor explicitly `N/A`, do not convert them yet; report that the spec files remain active and should not be deleted.
56
62
  - If the current change intentionally ships a partial phase while the same plan set still tracks remaining work, keep that plan set live and skip archival for that scope.
57
- 5. Run pre-commit sync dependencies
63
+ 6. Run pre-commit sync dependencies
58
64
  - Execute `align-project-documents` after spec conversion and code/doc scans are complete.
59
65
  - Execute `maintain-project-constraints` immediately before the commit.
60
- 6. Keep docs synchronized when needed
66
+ 7. Keep docs synchronized when needed
61
67
  - Apply the output from `archive-specs` when repository specs were converted or existing project docs were normalized into categorized project docs.
62
68
  - Apply the output from `align-project-documents` when behavior or usage changed.
63
69
  - Apply the output from `maintain-project-constraints` when agent workflow/rules changed.
64
- 7. Commit
70
+ 8. Commit
65
71
  - Preserve user staging intent where possible.
66
72
  - Write a concise Conventional Commit message using `references/commit-messages.md`.
67
- 8. Push
68
- - Push commit(s) to the current branch.
73
+ 9. Push
74
+ - Push commit(s) to the intended branch.
75
+ - Confirm the local branch state matches the user's requested destination when post-push synchronization was requested.
69
76
 
70
77
  ## Notes
71
78
 
@@ -16,7 +16,7 @@ description: Audit and maintain a repository of installable skills so the catalo
16
16
 
17
17
  - Evidence: Read the actual skill folders, validation scripts, repository docs, and local installed skill names before changing dependency classifications or catalog docs.
18
18
  - Execution: Audit first, classify findings, make focused catalog updates, then run the repo validators before finishing.
19
- - Quality: Avoid duplicate skills, avoid rewording behavior without checking the implementation, and distinguish aliases or local unpublished skills from true external dependencies.
19
+ - Quality: Avoid duplicate skills, avoid rewording behavior without checking the implementation, distinguish aliases or local unpublished skills from true external dependencies, and enforce the repository's current metadata constraints such as `SKILL.md` frontmatter validity, description-length limits, and synchronized agent configs.
20
20
  - Output: Leave the catalog with synchronized skill metadata, dependency documentation, and validation status.
21
21
 
22
22
  ## Goal
@@ -35,6 +35,7 @@ Keep a skill repository coherent when many top-level skills evolve together.
35
35
  ### 2) Audit dependency declarations and shared conventions
36
36
 
37
37
  - Use the standardized `## Dependencies` section as the source of truth for skill-to-skill relationships.
38
+ - Read the current validator scripts before changing frontmatter-heavy files so metadata limits come from implementation rather than memory.
38
39
  - Classify each dependency as:
39
40
  - vendored in this repository
40
41
  - local/private skill that should not be documented as external
@@ -49,6 +50,7 @@ Keep a skill repository coherent when many top-level skills evolve together.
49
50
  - Update `README.md` skill lists and external dependency sections when the catalog actually changes.
50
51
  - Update `AGENTS.md` when the repository gains or loses a user-visible capability or a standing convention changes.
51
52
  - When creating a new shared skill, align naming, frontmatter, `agents/openai.yaml`, and any lightweight README with neighboring skills.
53
+ - When a failure comes from validator drift or a metadata constraint that was not caught early, tighten the validator or CI path in the same change instead of only fixing the offending skill text.
52
54
  - Do not treat unpublished local skills as external dependencies just because they are not yet installed elsewhere.
53
55
 
54
56
  ### 4) Validate the catalog after changes
@@ -1,15 +1,15 @@
1
1
  # Open GitHub Issue
2
2
 
3
- Structured GitHub issue and feature-proposal publishing with deterministic authentication fallback and repository-language-aware issue bodies.
3
+ Structured GitHub issue publishing across multiple issue categories with deterministic authentication fallback and repository-language-aware issue bodies.
4
4
 
5
- This skill helps agents publish confirmed findings or accepted feature proposals as GitHub issues without embedding repository resolution, auth handling, and language detection logic into every other workflow.
5
+ This skill helps agents publish confirmed findings, accepted proposals, documentation gaps, security risks, observability gaps, and performance issues as GitHub issues without embedding repository resolution, auth handling, and language detection logic into every other workflow.
6
6
 
7
7
  ## What this skill provides
8
8
 
9
9
  - Target repository resolution from `--repo` or current git `origin`.
10
10
  - Strict auth fallback order: `gh` login -> `GITHUB_TOKEN`/`GH_TOKEN` -> draft only.
11
11
  - Issue body language detection based on the target repository README.
12
- - Consistent structured issue bodies for both problem issues and feature proposal issues.
12
+ - Consistent structured issue bodies for `problem`, `feature`, `performance`, `security`, `docs`, and `observability` issues.
13
13
  - Machine-readable JSON output so parent skills can report publication status consistently.
14
14
 
15
15
  ## Repository structure
@@ -33,7 +33,7 @@ cp -R open-github-issue "$CODEX_HOME/skills/open-github-issue"
33
33
  Invoke the skill in your prompt:
34
34
 
35
35
  ```text
36
- Use $open-github-issue to publish this confirmed finding or accepted feature proposal to GitHub.
36
+ Use $open-github-issue to publish this confirmed finding or accepted proposal to GitHub.
37
37
  ```
38
38
 
39
39
  The bundled script can also be called directly:
@@ -58,6 +58,19 @@ python scripts/open_github_issue.py \
58
58
  --repo owner/repo
59
59
  ```
60
60
 
61
+ ```bash
62
+ python scripts/open_github_issue.py \
63
+ --issue-type security \
64
+ --title "[Security] Missing authorization check on admin export" \
65
+ --problem-description "The admin export endpoint can be reached without verifying the caller's admin role." \
66
+ --severity high \
67
+ --affected-scope "/admin/export endpoint and exported customer data" \
68
+ --impact "Unauthorized users may access privileged exports containing sensitive business data." \
69
+ --evidence "Code path review and reproduced requests show the handler validates session presence but not the admin permission gate." \
70
+ --suggested-action "Add explicit authorization enforcement, regression tests, and audit logging for denied access attempts." \
71
+ --repo owner/repo
72
+ ```
73
+
61
74
  ## Publication behavior
62
75
 
63
76
  For each issue:
@@ -66,7 +79,7 @@ For each issue:
66
79
  2. Otherwise, if `GITHUB_TOKEN` or `GH_TOKEN` exists, publish via GitHub REST API.
67
80
  3. Otherwise, return draft issue content without blocking the caller.
68
81
 
69
- Problem issues always include exactly three sections:
82
+ `problem` issues always include exactly three sections:
70
83
 
71
84
  - `Problem Description`
72
85
  - `Suspected Cause`
@@ -80,7 +93,7 @@ Within `Problem Description`, include:
80
93
 
81
94
  For Chinese-language repositories, use translated section titles with the same meaning.
82
95
 
83
- Feature proposal issues always include:
96
+ `feature` issues always include:
84
97
 
85
98
  - `Feature Proposal`
86
99
  - `Why This Is Needed`
@@ -88,6 +101,35 @@ Feature proposal issues always include:
88
101
 
89
102
  For Chinese-language repositories, use translated section titles with the same meaning.
90
103
 
104
+ `performance` issues include:
105
+
106
+ - `Performance Problem`
107
+ - `Impact`
108
+ - `Evidence`
109
+ - `Suggested Action`
110
+
111
+ `security` issues include:
112
+
113
+ - `Security Risk`
114
+ - `Severity`
115
+ - `Affected Scope`
116
+ - `Impact`
117
+ - `Evidence`
118
+ - `Suggested Mitigation`
119
+
120
+ `docs` issues include:
121
+
122
+ - `Documentation Gap`
123
+ - `Evidence`
124
+ - `Suggested Update`
125
+
126
+ `observability` issues include:
127
+
128
+ - `Observability Gap`
129
+ - `Impact`
130
+ - `Evidence`
131
+ - `Suggested Instrumentation`
132
+
91
133
  ## Output
92
134
 
93
135
  The script prints JSON including:
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: open-github-issue
3
- description: Publish structured GitHub issues and feature proposals with deterministic auth fallback, target-repo resolution, README-based language detection, and draft-only fallback when authentication is unavailable. Use when users ask to open GitHub issues from confirmed findings, accepted feature proposals, or prepared issue content.
3
+ description: Publish structured GitHub issues across multiple issue categories with deterministic auth fallback, target-repo resolution, README-based language detection, and draft-only fallback when authentication is unavailable. Use when users ask to open GitHub issues from confirmed findings, accepted proposals, documentation gaps, security risks, observability gaps, or prepared issue content.
4
4
  ---
5
5
 
6
6
  # Open GitHub Issue
@@ -14,14 +14,14 @@ description: Publish structured GitHub issues and feature proposals with determi
14
14
 
15
15
  ## Standards
16
16
 
17
- - Evidence: Require structured issue inputs, detect repository language from the target README instead of guessing, and for `problem` issues capture BDD-style expected vs current behavior with an explicit delta.
17
+ - Evidence: Require structured issue inputs, detect repository language from the target README instead of guessing, and enforce category-specific required fields so each issue type matches the situation being reported.
18
18
  - Execution: Resolve the repo, normalize the issue body, publish with strict auth order, then return the publication result.
19
19
  - Quality: Preserve upstream evidence, localize only the structural parts, keep publication deterministic and reproducible, and make behavioral mismatches easy for maintainers to verify.
20
20
  - Output: Return publication mode, issue URL when created, rendered body, and any publish error in the standardized JSON contract.
21
21
 
22
22
  ## Overview
23
23
 
24
- Use this skill to publish a structured GitHub issue or feature proposal deterministically.
24
+ Use this skill to publish structured GitHub issues deterministically across several common issue situations.
25
25
 
26
26
  It is designed to be reusable by other skills that already know the issue title and evidence, but need a consistent way to:
27
27
 
@@ -36,7 +36,7 @@ It is designed to be reusable by other skills that already know the issue title
36
36
  - Prefer authenticated `gh` CLI first, then GitHub token, then draft-only fallback.
37
37
  - Detect repository issue language from the target remote README instead of guessing.
38
38
  - Preserve upstream evidence content; only localize section headers and default fallback text.
39
- - Make the issue type explicit: `problem` for defects/incidents, `feature` for proposals.
39
+ - Make the issue type explicit: `problem`, `feature`, `performance`, `security`, `docs`, or `observability`.
40
40
  - For `problem` issues, describe the expected behavior and current behavior with BDD-style `Given / When / Then`, then state the behavioral difference explicitly.
41
41
 
42
42
  ## Workflow
@@ -59,6 +59,27 @@ It is designed to be reusable by other skills that already know the issue title
59
59
  - `proposal` (optional; defaults to title when omitted)
60
60
  - `reason`
61
61
  - `suggested-architecture`
62
+ - For `performance` issues, require:
63
+ - `problem-description`
64
+ - `impact`
65
+ - `evidence`
66
+ - `suggested-action`
67
+ - For `security` issues, require:
68
+ - `problem-description`
69
+ - `severity`
70
+ - `affected-scope`
71
+ - `impact`
72
+ - `evidence`
73
+ - `suggested-action`
74
+ - For `docs` issues, require:
75
+ - `problem-description`
76
+ - `evidence`
77
+ - `suggested-action`
78
+ - For `observability` issues, require:
79
+ - `problem-description`
80
+ - `impact`
81
+ - `evidence`
82
+ - `suggested-action`
62
83
  - If reproduction is missing for a `problem` issue, insert the default non-reproducible note in the target issue language.
63
84
  3. Detect issue language
64
85
  - Read the target repository README from GitHub.
@@ -98,6 +119,59 @@ python scripts/open_github_issue.py \
98
119
  --repo <owner/repo>
99
120
  ```
100
121
 
122
+ Performance issue:
123
+
124
+ ```bash
125
+ python scripts/open_github_issue.py \
126
+ --issue-type performance \
127
+ --title "[Performance] Slow dashboard query under large tenants" \
128
+ --problem-description "Dashboard loading time degrades sharply once tenant data exceeds current pagination assumptions." \
129
+ --impact "Users wait 8-12 seconds before the page becomes interactive; this blocks support workflows." \
130
+ --evidence "Profiler output, slow-query logs, and production timings all point to repeated full-table scans in the summary query path." \
131
+ --suggested-action "Add bounded pagination, pre-aggregated summaries, and an index review for the offending query path." \
132
+ --repo <owner/repo>
133
+ ```
134
+
135
+ Security issue:
136
+
137
+ ```bash
138
+ python scripts/open_github_issue.py \
139
+ --issue-type security \
140
+ --title "[Security] Missing authorization check on admin export" \
141
+ --problem-description "The admin export endpoint can be reached without verifying the caller's admin role." \
142
+ --severity high \
143
+ --affected-scope "/admin/export endpoint and exported customer data" \
144
+ --impact "Unauthorized users may access privileged exports containing sensitive business data." \
145
+ --evidence "Code path review and reproduced requests show the handler validates session presence but not the admin permission gate." \
146
+ --suggested-action "Add explicit authorization enforcement, regression tests, and audit logging for denied access attempts." \
147
+ --repo <owner/repo>
148
+ ```
149
+
150
+ Docs issue:
151
+
152
+ ```bash
153
+ python scripts/open_github_issue.py \
154
+ --issue-type docs \
155
+ --title "[Docs] Deployment guide omits required Redis configuration" \
156
+ --problem-description "The deployment guide does not mention the required Redis URL and worker startup order." \
157
+ --evidence "README deploy steps differ from the actual compose file and runtime startup checks." \
158
+ --suggested-action "Update deployment docs with required env vars, startup order, and a minimal validation checklist." \
159
+ --repo <owner/repo>
160
+ ```
161
+
162
+ Observability issue:
163
+
164
+ ```bash
165
+ python scripts/open_github_issue.py \
166
+ --issue-type observability \
167
+ --title "[Observability] Missing request identifiers in payment retry logs" \
168
+ --problem-description "Retry logs do not include stable request or trace identifiers, so multi-line failures cannot be correlated quickly." \
169
+ --impact "On-call engineers cannot isolate a single failing payment flow without manual log stitching." \
170
+ --evidence "Current retry log lines include endpoint and error text only; incident review required manual timestamp matching." \
171
+ --suggested-action "Add request_id, trace_id, upstream target, and retry attempt fields to retry logs and dashboard facets." \
172
+ --repo <owner/repo>
173
+ ```
174
+
101
175
  ## Output contract
102
176
 
103
177
  The script prints JSON with these fields:
@@ -115,11 +189,12 @@ The script prints JSON with these fields:
115
189
 
116
190
  When another skill depends on `open-github-issue`:
117
191
 
118
- - Pass exactly one confirmed problem or one accepted feature proposal per invocation.
192
+ - Pass exactly one confirmed issue or one accepted proposal per invocation.
119
193
  - Prepare evidence or proposal details before calling this skill; do not ask this skill to infer root cause or architecture.
120
194
  - For `problem` issues, pass a `problem-description` that contains `Expected Behavior (BDD)`, `Current Behavior (BDD)`, and `Behavior Gap`; the difference must be explicit, not implied.
121
195
  - Reuse the returned `mode`, `issue_url`, and `publish_error` in the parent skill response.
122
196
  - For accepted feature proposals, pass `--issue-type feature` plus `--proposal`, `--reason`, and `--suggested-architecture`.
197
+ - For security, performance, docs, or observability findings, choose the matching `issue-type` instead of overloading `problem`.
123
198
 
124
199
  ## Resources
125
200
 
@@ -1,4 +1,4 @@
1
1
  interface:
2
2
  display_name: "Open GitHub Issue"
3
- short_description: "Publish structured issues and feature proposals"
4
- default_prompt: "Use $open-github-issue to publish a structured GitHub issue or feature proposal from prepared content, resolve the target repo, detect README language for issue sections, and fall back deterministically from gh CLI to GitHub token to draft-only output."
3
+ short_description: "Publish structured issues across multiple categories"
4
+ default_prompt: "Use $open-github-issue to publish a structured GitHub issue from prepared content, choose the correct issue category such as problem, feature, performance, security, docs, or observability, resolve the target repo, detect README language for issue sections, and fall back deterministically from gh CLI to GitHub token to draft-only output."
@@ -19,6 +19,18 @@ DEFAULT_REPRO_ZH = "尚未穩定重現;需補充更多執行期資料。"
19
19
  DEFAULT_REPRO_EN = "Not yet reliably reproducible; more runtime evidence is required."
20
20
  ISSUE_TYPE_PROBLEM = "problem"
21
21
  ISSUE_TYPE_FEATURE = "feature"
22
+ ISSUE_TYPE_PERFORMANCE = "performance"
23
+ ISSUE_TYPE_SECURITY = "security"
24
+ ISSUE_TYPE_DOCS = "docs"
25
+ ISSUE_TYPE_OBSERVABILITY = "observability"
26
+ ISSUE_TYPES = [
27
+ ISSUE_TYPE_PROBLEM,
28
+ ISSUE_TYPE_FEATURE,
29
+ ISSUE_TYPE_PERFORMANCE,
30
+ ISSUE_TYPE_SECURITY,
31
+ ISSUE_TYPE_DOCS,
32
+ ISSUE_TYPE_OBSERVABILITY,
33
+ ]
22
34
  PROBLEM_BDD_MARKER_GROUPS = (
23
35
  (
24
36
  r"Expected Behavior\s*\(BDD\)",
@@ -43,7 +55,7 @@ def parse_args() -> argparse.Namespace:
43
55
  parser.add_argument("--title", required=True, help="Issue title")
44
56
  parser.add_argument(
45
57
  "--issue-type",
46
- choices=[ISSUE_TYPE_PROBLEM, ISSUE_TYPE_FEATURE],
58
+ choices=ISSUE_TYPES,
47
59
  default=ISSUE_TYPE_PROBLEM,
48
60
  help="Structured issue type to publish.",
49
61
  )
@@ -71,6 +83,27 @@ def parse_args() -> argparse.Namespace:
71
83
  "--suggested-architecture",
72
84
  help="Issue section content: suggested architecture for the feature",
73
85
  )
86
+ parser.add_argument(
87
+ "--impact",
88
+ help="Issue section content: concrete user, system, or business impact",
89
+ )
90
+ parser.add_argument(
91
+ "--evidence",
92
+ help="Issue section content: concrete evidence, metrics, logs, or repository facts",
93
+ )
94
+ parser.add_argument(
95
+ "--suggested-action",
96
+ help="Issue section content: suggested remediation, mitigation, or next action",
97
+ )
98
+ parser.add_argument(
99
+ "--severity",
100
+ choices=["critical", "high", "medium", "low"],
101
+ help="Issue section content: severity level for security-oriented issues",
102
+ )
103
+ parser.add_argument(
104
+ "--affected-scope",
105
+ help="Issue section content: affected endpoint, module, user cohort, or system surface",
106
+ )
74
107
  parser.add_argument(
75
108
  "--repo",
76
109
  help="Target repository in owner/repo format. Defaults to origin remote.",
@@ -91,6 +124,35 @@ def validate_issue_content_args(args: argparse.Namespace) -> None:
91
124
  raise SystemExit("Feature issues require --suggested-architecture.")
92
125
  return
93
126
 
127
+ if args.issue_type == ISSUE_TYPE_PERFORMANCE:
128
+ require_non_empty(args.problem_description, "Performance issues require --problem-description.")
129
+ require_non_empty(args.impact, "Performance issues require --impact.")
130
+ require_non_empty(args.evidence, "Performance issues require --evidence.")
131
+ require_non_empty(args.suggested_action, "Performance issues require --suggested-action.")
132
+ return
133
+
134
+ if args.issue_type == ISSUE_TYPE_SECURITY:
135
+ require_non_empty(args.problem_description, "Security issues require --problem-description.")
136
+ require_non_empty(args.affected_scope, "Security issues require --affected-scope.")
137
+ require_non_empty(args.impact, "Security issues require --impact.")
138
+ require_non_empty(args.evidence, "Security issues require --evidence.")
139
+ require_non_empty(args.suggested_action, "Security issues require --suggested-action.")
140
+ require_non_empty(args.severity, "Security issues require --severity.")
141
+ return
142
+
143
+ if args.issue_type == ISSUE_TYPE_DOCS:
144
+ require_non_empty(args.problem_description, "Docs issues require --problem-description.")
145
+ require_non_empty(args.evidence, "Docs issues require --evidence.")
146
+ require_non_empty(args.suggested_action, "Docs issues require --suggested-action.")
147
+ return
148
+
149
+ if args.issue_type == ISSUE_TYPE_OBSERVABILITY:
150
+ require_non_empty(args.problem_description, "Observability issues require --problem-description.")
151
+ require_non_empty(args.impact, "Observability issues require --impact.")
152
+ require_non_empty(args.evidence, "Observability issues require --evidence.")
153
+ require_non_empty(args.suggested_action, "Observability issues require --suggested-action.")
154
+ return
155
+
94
156
  if not (args.problem_description or "").strip():
95
157
  raise SystemExit("Problem issues require --problem-description.")
96
158
  if not (args.suspected_cause or "").strip():
@@ -102,6 +164,11 @@ def validate_issue_content_args(args: argparse.Namespace) -> None:
102
164
  )
103
165
 
104
166
 
167
+ def require_non_empty(value: str | None, message: str) -> None:
168
+ if not (value or "").strip():
169
+ raise SystemExit(message)
170
+
171
+
105
172
  def has_required_problem_bdd_sections(problem_description: str) -> bool:
106
173
  normalized = problem_description.strip()
107
174
  return any(
@@ -236,6 +303,11 @@ def build_issue_body(
236
303
  proposal: str | None,
237
304
  reason: str | None,
238
305
  suggested_architecture: str | None,
306
+ impact: str | None = None,
307
+ evidence: str | None = None,
308
+ suggested_action: str | None = None,
309
+ severity: str | None = None,
310
+ affected_scope: str | None = None,
239
311
  ) -> str:
240
312
  if issue_type == ISSUE_TYPE_FEATURE:
241
313
  proposal_text = (proposal or title).strip()
@@ -261,6 +333,102 @@ def build_issue_body(
261
333
  f"{architecture_text}\n"
262
334
  )
263
335
 
336
+ if issue_type == ISSUE_TYPE_PERFORMANCE:
337
+ if language == "zh":
338
+ return (
339
+ "### 效能問題\n"
340
+ f"{(problem_description or '').strip()}\n\n"
341
+ "### 影響\n"
342
+ f"{(impact or '').strip()}\n\n"
343
+ "### 證據\n"
344
+ f"{(evidence or '').strip()}\n\n"
345
+ "### 建議行動\n"
346
+ f"{(suggested_action or '').strip()}\n"
347
+ )
348
+ return (
349
+ "### Performance Problem\n"
350
+ f"{(problem_description or '').strip()}\n\n"
351
+ "### Impact\n"
352
+ f"{(impact or '').strip()}\n\n"
353
+ "### Evidence\n"
354
+ f"{(evidence or '').strip()}\n\n"
355
+ "### Suggested Action\n"
356
+ f"{(suggested_action or '').strip()}\n"
357
+ )
358
+
359
+ if issue_type == ISSUE_TYPE_SECURITY:
360
+ if language == "zh":
361
+ return (
362
+ "### 安全風險\n"
363
+ f"{(problem_description or '').strip()}\n\n"
364
+ "### 嚴重程度\n"
365
+ f"{(severity or '').strip()}\n\n"
366
+ "### 受影響範圍\n"
367
+ f"{(affected_scope or '').strip()}\n\n"
368
+ "### 影響\n"
369
+ f"{(impact or '').strip()}\n\n"
370
+ "### 證據\n"
371
+ f"{(evidence or '').strip()}\n\n"
372
+ "### 建議緩解\n"
373
+ f"{(suggested_action or '').strip()}\n"
374
+ )
375
+ return (
376
+ "### Security Risk\n"
377
+ f"{(problem_description or '').strip()}\n\n"
378
+ "### Severity\n"
379
+ f"{(severity or '').strip()}\n\n"
380
+ "### Affected Scope\n"
381
+ f"{(affected_scope or '').strip()}\n\n"
382
+ "### Impact\n"
383
+ f"{(impact or '').strip()}\n\n"
384
+ "### Evidence\n"
385
+ f"{(evidence or '').strip()}\n\n"
386
+ "### Suggested Mitigation\n"
387
+ f"{(suggested_action or '').strip()}\n"
388
+ )
389
+
390
+ if issue_type == ISSUE_TYPE_DOCS:
391
+ if language == "zh":
392
+ return (
393
+ "### 文件缺口\n"
394
+ f"{(problem_description or '').strip()}\n\n"
395
+ "### 證據\n"
396
+ f"{(evidence or '').strip()}\n\n"
397
+ "### 建議更新\n"
398
+ f"{(suggested_action or '').strip()}\n"
399
+ )
400
+ return (
401
+ "### Documentation Gap\n"
402
+ f"{(problem_description or '').strip()}\n\n"
403
+ "### Evidence\n"
404
+ f"{(evidence or '').strip()}\n\n"
405
+ "### Suggested Update\n"
406
+ f"{(suggested_action or '').strip()}\n"
407
+ )
408
+
409
+ if issue_type == ISSUE_TYPE_OBSERVABILITY:
410
+ if language == "zh":
411
+ return (
412
+ "### 可觀測性缺口\n"
413
+ f"{(problem_description or '').strip()}\n\n"
414
+ "### 影響\n"
415
+ f"{(impact or '').strip()}\n\n"
416
+ "### 證據\n"
417
+ f"{(evidence or '').strip()}\n\n"
418
+ "### 建議儀表化\n"
419
+ f"{(suggested_action or '').strip()}\n"
420
+ )
421
+ return (
422
+ "### Observability Gap\n"
423
+ f"{(problem_description or '').strip()}\n\n"
424
+ "### Impact\n"
425
+ f"{(impact or '').strip()}\n\n"
426
+ "### Evidence\n"
427
+ f"{(evidence or '').strip()}\n\n"
428
+ "### Suggested Instrumentation\n"
429
+ f"{(suggested_action or '').strip()}\n"
430
+ )
431
+
264
432
  if language == "zh":
265
433
  repro_text = (reproduction or DEFAULT_REPRO_ZH).strip()
266
434
  return (
@@ -349,6 +517,11 @@ def main() -> int:
349
517
  proposal=args.proposal,
350
518
  reason=args.reason,
351
519
  suggested_architecture=args.suggested_architecture,
520
+ impact=args.impact,
521
+ evidence=args.evidence,
522
+ suggested_action=args.suggested_action,
523
+ severity=args.severity,
524
+ affected_scope=args.affected_scope,
352
525
  )
353
526
 
354
527
  mode = "draft-only"