一键导入
skill-ai-dspy-validator
Evaluate the quality of a DSPy integration in DiD — endpoint correctness, graceful degradation, and WARN-NOT-BLOCK contract.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Evaluate the quality of a DSPy integration in DiD — endpoint correctness, graceful degradation, and WARN-NOT-BLOCK contract.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
Trace import graph + test coverage of files about to be modified and produce an impact report before any code changes are made.
Design, implement, and debug GitHub Actions workflows for DiD's server-side enforcement layer.
The canonical skill for designing, implementing, testing, and registering a new Guard in defense-in-depth.
Review a PR against DiD's governance contracts — Guard purity, severity correctness, test coverage, and documentation completeness.
Refactor guard code with minimum blast radius — change only what is needed, verify nothing else shifts.
Design adversarial test suites for Guards that prove both positive enforcement and bypass resistance.
| domain | intelligence |
| name | skill-ai-dspy-validator |
| description | Evaluate the quality of a DSPy integration in DiD — endpoint correctness, graceful degradation, and WARN-NOT-BLOCK contract. |
| version | 1.0.0 |
| type | specialist |
| role | The DSPy Integration Auditor |
Role: The DSPy Integration Auditor
Philosophy: An AI evaluator that can BLOCK governance decisions is an AI evaluator that needs to be Red-Teamed.
Audit a DSPy integration in DiD to verify:
fetch() call to a DSPy endpoint must have an AbortController with a configurable timeout.null return on failure: callDspy() must return null on any error — network, timeout, non-2xx — never throw.callDspy() must have a corresponding test that simulates DSPy being unreachable.For every call to callDspy() or callDspyRank(), verify:
☐ AbortController present with configurable timeoutMs
☐ Response status checked (non-2xx → return null)
☐ catch block returns null (not throws)
☐ Result drives WARN severity only (never BLOCK)
☐ useDspy=false is the default
☐ DSPy is only called AFTER Tier 0 checks pass
☐ DSPy result = null → pipeline continues without error
☐ DSPy result.score < 0.5 → WARN finding (with feedback), not BLOCK
☐ DSPy fail → lesson is persisted (graceful degrade)
☐ A WARN is logged when quality gate is skipped due to DSPy failure
☐ qualityScore === null in result when DSPy unavailable (not 0)
## DSPy Integration Audit: <module>
### WARN-NOT-BLOCK Contract: ✅ / ❌
<detail>
### AbortController: ✅ / ❌
Timeout: <configured value> ms
<detail>
### Graceful Degradation: ✅ / ❌
- Network fail: null returned? ✅ / ❌
- Timeout: null returned? ✅ / ❌
- Non-2xx: null returned? ✅ / ❌
### Quality Gate (if applicable): ✅ / ❌
- WARN emitted on skip? ✅ / ❌
- qualityScore === null (not 0)? ✅ / ❌
### Test Coverage: ✅ / ❌
- DSPy unreachable test exists? ✅ / ❌
- Timeout simulation test exists? ✅ / ❌
### Verdict: COMPLIANT / NON-COMPLIANT
src/core/dspy-client.ts — callDspy(), callDspyRank() — shared client
src/guards/hollow-artifact.ts — L3 opt-in semantic eval
src/core/memory.ts — quality gate + semantic search
src/cli/eval.ts — forced-on DSPy eval for manual inspection
Reference implementation: src/core/dspy-client.ts — four architectural contracts
are documented in the file header comment.
A structured audit report (markdown). If non-compliant issues found, create
GitHub issues with labels bug and priority: P1.
evalResult.score === 0 to mean "DSPy failed" — Score 0 means the content was evaluated and scored 0. null means DSPy was unavailable.console.warn() to stderr. stdout is for structured output.