Agent Skills › harumiWeb/exstruct

harumiWeb/exstruct

GitHub

用于根据Issue、PR或代码变更起草新的架构决策记录(ADR)或更新现有ADR。该技能提取政策背景、决策及证据,生成结构化草案,明确区分‘为何’与‘如何做’,并判断是否真的需要ADR。

8 skills 185

Install All Skills

npx skills add harumiWeb/exstruct --all -g -y
More Options

List skills in collection

npx skills add harumiWeb/exstruct --list

Skills in Collection (8)

用于根据Issue、PR或代码变更起草新的架构决策记录(ADR)或更新现有ADR。该技能提取政策背景、决策及证据,生成结构化草案,明确区分‘为何’与‘如何做’,并判断是否真的需要ADR。
需要创建新的架构决策记录时 需要对现有架构决策记录进行更新时
.agents/skills/adr-drafter/SKILL.md
npx skills add harumiWeb/exstruct --skill adr-drafter -g -y
SKILL.md
Frontmatter
{
    "name": "adr-drafter",
    "description": "Draft a new ExStruct ADR or propose an update to an existing ADR from an issue, PR, diff, tests, and specs. Use when an ADR is required or recommended and you need a structured draft with context, decision, consequences, and evidence."
}

ADR Drafter

Draft a policy record, not an implementation memo.

Read

  1. dev-docs/agents/adr-governance.md
  2. dev-docs/agents/adr-criteria.md
  3. dev-docs/agents/adr-workflow.md
  4. dev-docs/adr/template.md
  5. Related ADRs under dev-docs/adr/

Workflow

  1. Confirm whether the target is a new ADR or an update to an existing ADR.
  2. Read the issue, diff, relevant specs, tests, and implementation files.
  3. Extract:
    • policy-level context
    • chosen decision
    • positive and negative consequences
    • concrete evidence from tests, code, and related specs
  4. Produce one of these outputs:
    • a new ADR draft
    • an update proposal for an existing ADR
    • ADR not needed with rationale

Draft Rules

  • Keep why in the ADR and leave detailed how in code or specs.
  • Fill Tests, Code, and Related specs whenever possible.
  • If the policy replaces an old one, state the supersede relation explicitly.
  • If evidence is missing, say so instead of inventing support.
扫描ADR文件并同步生成README、index.yaml和decision-map.md索引制品。当ADR新增、更新或状态变更时,自动刷新元数据映射,确保人工与AI代理获取一致的架构决策视图。
ADR文件被添加或修改 ADR状态或分类发生变更 需要刷新架构决策索引
.agents/skills/adr-indexer/SKILL.md
npx skills add harumiWeb/exstruct --skill adr-indexer -g -y
SKILL.md
Frontmatter
{
    "name": "adr-indexer",
    "description": "Maintain ExStruct ADR index artifacts by scanning ADR files and synchronizing README, index.yaml, and decision-map.md metadata. Use when ADRs are added, updated, superseded, or reclassified and the repository needs a refreshed ADR map for humans and AI agents."
}

ADR Indexer

Refresh the derived ADR map after the source ADRs change.

Read

  1. dev-docs/agents/adr-governance.md
  2. dev-docs/agents/adr-workflow.md
  3. dev-docs/specs/adr-index.md
  4. All ADR files under dev-docs/adr/
  5. Existing dev-docs/adr/README.md, dev-docs/adr/index.yaml, dev-docs/adr/decision-map.md

Workflow

  1. Scan the ADR files and collect normalized metadata:
    • id
    • title
    • status
    • primary_domain
    • domains
    • supersedes
    • superseded_by
    • related_specs
  2. Compare the normalized metadata with README.md, index.yaml, and decision-map.md.
  3. Update the derived artifacts so that status, primary domain, domain grouping, and supersede relationships match the ADR source files.
  4. Report any ambiguity that cannot be derived from the ADR text alone.

Output Contract

Return a concise summary with:

  • updated artifacts
  • added or changed ADR entries
  • consistency findings

Treat ADR-xxxx-*.md as the source of truth. Do not invent domains, statuses, or supersede links that the ADR text cannot justify.

用于审查 ExStruct ADR 草稿,检查必填字段、状态值、证据质量、替代链接及后果平衡性。适用于合并或正式评审前的发现收集阶段。
收到 ADR 草稿需要合规性审查 准备合并前需验证决策记录完整性
.agents/skills/adr-linter/SKILL.md
npx skills add harumiWeb/exstruct --skill adr-linter -g -y
SKILL.md
Frontmatter
{
    "name": "adr-linter",
    "description": "Review an ExStruct ADR draft for required sections, status values, evidence quality, supersede links, and balanced consequences. Use when an ADR already exists in draft form and you need findings before review or merge."
}

ADR Linter

Review the ADR as a decision record, not as prose polish.

Read

  1. dev-docs/agents/adr-governance.md
  2. dev-docs/agents/adr-workflow.md
  3. dev-docs/adr/template.md
  4. Related ADRs if the draft mentions supersede or overlap

Workflow

  1. Validate the status value.
  2. Check that the ADR has 状態, 背景, 決定, 影響, 根拠, Supersedes, and Superseded by.
  3. Verify that 根拠 contains concrete Tests, Code, or Related specs.
  4. Check that consequences include tradeoffs, not only benefits.
  5. If supersede or replacement is claimed, verify the referenced ADR links are present and consistent.

Output Contract

Return findings first, ordered by severity.

  • high: contract hole, missing decision, invalid status, missing supersede linkage
  • medium: weak context, weak evidence, one-sided consequences
  • low: clarity or consistency issues

If no findings exist, say that explicitly and mention any residual review risk.

审计ADR与当前规范、测试及源码的一致性,检测策略漂移、缺失更新及证据缺口。适用于合并后或定期审计,通过构建证据矩阵分类问题并推荐操作,不直接改写文本。
代码合并后验证一致性 执行周期性ADR审计 怀疑实现与ADR存在偏差
.agents/skills/adr-reconciler/SKILL.md
npx skills add harumiWeb/exstruct --skill adr-reconciler -g -y
SKILL.md
Frontmatter
{
    "name": "adr-reconciler",
    "description": "Audit ExStruct ADRs against current specs, tests, and source code to detect policy drift, missing ADR updates, stale references, and evidence gaps. Use after merges, during periodic ADR audits, or when a review suspects that implementation and ADRs have diverged."
}

ADR Reconciler

Audit the current decision records before proposing new text.

Read

  1. dev-docs/agents/adr-governance.md
  2. dev-docs/agents/adr-workflow.md
  3. dev-docs/specs/adr-index.md
  4. Target ADRs under dev-docs/adr/
  5. Related files under dev-docs/specs/, tests/, and src/

Workflow

  1. Select the target ADRs from changed domains, explicit ADR IDs, or related index entries.
  2. Read each ADR claim and the linked specs, tests, and implementation paths.
  3. Build an evidence matrix for every finding:
    • adr
    • specs
    • src
    • tests
  4. Classify findings as one of:
    • policy-drift
    • missing-adr-update
    • missing-evidence
    • stale-reference
  5. Recommend the next action:
    • update-adr
    • new-adr
    • update-specs
    • add-tests
    • no-action

Output Contract

Return a concise audit result with:

  • scope
    • adrs
    • specs
    • src
    • tests
  • findings

Each finding should include:

  • type
  • severity
  • claim
  • affected ADRs
  • evidence matrix
    • adr
    • specs
    • src
    • tests
  • recommended action

Do not silently rewrite ADR text. If the finding implies a new or changed policy, route back through adr-suggester and adr-drafter.

审查ADR草案的决策质量、重叠性、证据强度及回滚风险。需在adr-linter无未解决高/中优先级问题时执行,识别需人工介入的决策并输出分级结论与详细发现。
ADR草稿已通过adr-linter检查且无未解决的高/中优先级问题 需要在合并或交接前获取设计审查结果
.agents/skills/adr-reviewer/SKILL.md
npx skills add harumiWeb/exstruct --skill adr-reviewer -g -y
SKILL.md
Frontmatter
{
    "name": "adr-reviewer",
    "description": "Review an ExStruct ADR draft for decision quality, overlap with existing ADRs and specs, evidence strength, rollout risk, and human-ownership escalations. Use only after adr-linter reports no unresolved high\/medium findings on the current draft, and when you need design-review findings before merge or handoff."
}

ADR Reviewer

Review the policy decision, not just the document shape.

Read

  1. dev-docs/agents/adr-governance.md
  2. dev-docs/agents/adr-criteria.md
  3. dev-docs/agents/adr-workflow.md
  4. dev-docs/specs/adr-review.md
  5. The target ADR draft
  6. Related ADRs, relevant public docs under docs/ when public API / CLI / MCP contracts are in scope, internal specs, tests, src paths, and issue / PR context
  7. Existing adr-linter findings for the current draft

Workflow

  1. Confirm the current draft has no unresolved adr-linter high / medium findings. Only proceed with design review after that precondition is met.
  2. Read the ADR draft and identify the single policy question it is trying to resolve.
  3. Check whether the draft overlaps with, contradicts, or should supersede an existing ADR or spec.
  4. Verify that the cited Tests, Code, and Related specs actually support the claims being made, and include relevant public docs/ pages in scope when the ADR touches public API / CLI / MCP contracts.
  5. Review whether compatibility, rollout, fallback, migration, or safety consequences are covered when relevant.
  6. Detect human-owned decisions that AI should not settle, including public API break judgment, security or license calls, major directory reorganization, or unresolved product/spec direction.
  7. Return one verdict:
    • ready
    • revise
    • escalate

Output Contract

Return findings first, ordered by severity, and include:

  • verdict
  • scope
    • draft
    • related ADRs
    • public docs
    • specs
    • src
    • tests
    • issue / PR context
  • findings

Each finding should include:

  • type
    • decision-gap
    • scope-conflict
    • evidence-risk
    • rollout-gap
    • ownership-escalation
  • severity
  • summary
  • why it matters
  • suggested revision
  • evidence
    • draft
    • related sources

Also include top-level:

  • open questions
  • residual risks

Do not silently rewrite the ADR text. If the review hits a human-owned decision, return escalate instead of inventing a final policy.

用于判断代码变更是否需要架构决策记录(ADR)。通过读取治理文档、规范和现有ADR,分析变更影响并给出required/recommended/not-needed结论,同时提供候选标题和后续行动建议。
阅读Issue或PR时需要判定是否需记录ADR 代码审查中评估变更的架构影响 查看Diff或Review评论以确定归档需求
.agents/skills/adr-suggester/SKILL.md
npx skills add harumiWeb/exstruct --skill adr-suggester -g -y
SKILL.md
Frontmatter
{
    "name": "adr-suggester",
    "description": "Determine whether a change in ExStruct needs an ADR, using repository-specific governance and criteria. Use when reading an issue, PR, review thread, or diff and you need a verdict of required, recommended, or not-needed, plus candidate ADR titles and related existing ADRs."
}

ADR Suggester

Classify the change before drafting anything.

Read

  1. dev-docs/agents/adr-criteria.md
  2. dev-docs/agents/adr-governance.md
  3. Relevant files under dev-docs/adr/

Workflow

  1. Read the issue, PR, diff, or review comment that introduced the change.
  2. Read the relevant specs, implementation path, tests, and existing ADRs needed to justify the verdict.
  3. Map the change to one or more ExStruct design domains.
  4. Assemble an evidence triad:
    • specs contract
    • src symbol or execution path
    • tests that fix the current behavior, or an explicit note that evidence is missing
  5. Return one verdict:
    • required
    • recommended
    • not-needed
  6. If verdict is not not-needed, propose:
    • a candidate ADR title
    • existing ADRs to inspect or update
    • whether the next step is new-adr or update-existing-adr

Output Contract

Return a concise result with:

  • verdict
  • rationale
  • affected domains
  • existing ADR candidates
  • suggested next action
  • evidence triad
    • specs
    • src
    • tests

Do not draft the ADR body.

通过执行脚本获取并格式化 Codacy 代码分析缺陷,支持按仓库或 PR 筛选严重级别。输出结构化问题摘要以辅助修复规划,具备完善的错误处理与结果呈现策略。
用户请求检查代码库的 Codacy 问题 用户希望查看特定 Pull Request 的代码缺陷 需要按严重级别过滤并生成结构化缺陷报告
.agents/skills/codacy-issues-fetcher/SKILL.md
npx skills add harumiWeb/exstruct --skill codacy-issues-fetcher -g -y
SKILL.md
Frontmatter
{
    "name": "codacy-issues-fetcher",
    "description": "Retrieve and format Codacy analysis issues by running `scripts\/codacy_issues.py` in the ExStruct workspace. Use when users ask to inspect repository or pull-request Codacy findings, filter by severity, or produce structured issue output for review and fix planning."
}

Codacy Issues Fetcher

Run scripts/codacy_issues.py as the primary interface to Codacy issue retrieval. Avoid reimplementing API calls unless the script itself must be changed.

Workflow

  1. Confirm prerequisites.
  • Run from repository root so scripts/codacy_issues.py is reachable.
  • Ensure CODACY_API_TOKEN is set and valid.
  • Prefer explicit org and repo if user provides them; otherwise rely on Git origin auto-detection.
  1. Choose scope and severity.
  • Repository scope: omit --pr.
  • Pull request scope: pass --pr <number>.
  • Severity filter (--min-level): Error, High, Warning, Info.
  • Provider (--provider): gh, gl, bb (default is effectively gh).
  1. Run one of the command patterns.
# Repository issues (explicit target)
python scripts/codacy_issues.py <org> <repo> --provider gh --min-level Warning

# Pull request issues (explicit target)
python scripts/codacy_issues.py <org> <repo> --pr <number> --provider gh --min-level Warning

# Pull request issues (auto-detect org/repo from git origin)
python scripts/codacy_issues.py --pr <number> --min-level Warning
  1. Parse output JSON and respond with actionable summary.
  • Trust payload fields: scope, organization, repository, pullRequest, minLevel, total, issues.
  • issues entries are formatted as: <level> | <file_path>:<line_no> | <rule> | <category> | <message>
  • Report high-severity findings first, then summarize counts.

Error Handling

  • HTTP 401 / Unauthorized: token invalid or missing permissions. Ask user to set or refresh CODACY_API_TOKEN.
  • CODACY_API_TOKEN is not set: export the environment variable before retrying.
  • Invalid --provider: use only gh, gl, or bb.
  • Segment validation errors (Invalid org/repo/pr): sanitize input and rerun.

Output Policy

  • Return concise triage-ready results, not raw command logs.
  • Include the exact command you used when reproducibility matters.
  • If no issues match the selected --min-level, state that explicitly.
指导Agent使用ExStruct CLI安全处理Excel工作簿的创建、编辑与验证。涵盖命令选择、安全规则及干跑流程,适用于新建、修改或校验场景,复杂任务移交MCP。
需要创建新的Excel工作簿 需要编辑现有Excel文件 不确定文件可读性或需验证格式 查询操作列表或具体约束 涉及Excel处理的决策咨询
.agents/skills/exstruct-cli/SKILL.md
npx skills add harumiWeb/exstruct --skill exstruct-cli -g -y
SKILL.md
Frontmatter
{
    "name": "exstruct-cli",
    "description": "Use ExStruct CLI to validate, inspect, create, and edit Excel workbooks safely. Trigger when an agent needs `exstruct patch`, `exstruct make`, `exstruct validate`, `exstruct ops list`, or `exstruct ops describe`, especially for create-vs-edit decisions, dry-run workflows, backend constraints, or safe workbook-edit guidance."
}

ExStruct CLI

Use the existing editing CLI as the default local operational interface for ExStruct workbook create/edit requests.

Select a command

  • Use exstruct make when the user wants a new workbook created and populated.
  • Use exstruct patch when the user wants an existing workbook edited.
  • Use exstruct validate when workbook readability is uncertain or before a risky edit on an unfamiliar file.
  • Use exstruct ops list when the required operation is still unclear.
  • Use exstruct ops describe <op> when you know the likely op name but need the exact schema or constraints.
  • Hand the workflow off to MCP when the user needs host-owned path policy, transport mapping, artifact mirroring, or other server-managed behavior.

Safety rules

  • Do not invent unsupported patch ops.
  • Do not apply destructive edits immediately when the request is ambiguous.
  • Prefer --dry-run before risky edits.
  • Pin --backend openpyxl when the dry run and the real apply must use the same engine.
  • Explain backend-specific failures directly instead of hiding them behind a generic retry.

Workflow

  1. Decide whether the request is create, edit, or actually an MCP-hosted task.
  2. Identify the needed op or inspect the public op schema.
  3. Validate the workbook when the file, backend, or request is uncertain.
  4. Run --dry-run for risky edits and inspect PatchResult.
  5. Apply the real edit only after the planned change is acceptable.
  6. Verify the result with the lightest step that still matches the user's risk.

References

  • references/command-selection.md
  • references/safe-editing.md
  • references/ops-guidance.md
  • references/verify-workflows.md
  • references/backend-constraints.md

ホーム - Wiki
Copyright © 2011-2026 iteam. Current version is 2.155.2. UTC+08:00, 2026-07-21 04:21
浙ICP备14020137号-1 $お客様$