octocode-prompt-optimizer — independently scanned and version-tracked by SaferSkills.
SaferSkills independently audited octocode-prompt-optimizer (Agent Skill) and scored it 100/100 (green). The audit ran 55 deterministic rules across Security, Supply Chain, Maintenance, Transparency, and Community; it found 0 high-severity and 0 lower-severity findings. The full rule-by-rule trace and per-finding evidence are below. Free, methodology-open.
Findings & checks · 0 flagged
Every scanned point with the score it earned and what moved between them.
First recorded scan — no prior version to compare against.
The primary manifest — the file an agent reads to learn what this artifact does.
<what> Analyzes and improves instructional prompts, documentation, and agent instructions using prompt engineering best practices while preserving original intent. </what>
<when_to_use>
</when_to_use>
<global_forbidden priority="maximum"> CRITICAL - FORBIDDEN at ALL times:
Triple Lock:
Violation invalidates optimization. Start over if violated. </global_forbidden>
<tool_control priority="high"> FORBIDDEN tools during optimization:
ALLOWED tools:
Compatibility note (REQUIRED):
</tool_control>
<write_policy priority="high"> Write policy (REQUIRED):
</write_policy>
<execution_flow>
READ → UNDERSTAND → RATE → FIX → VALIDATE → OUTPUT
↓ ↓ ↓ ↓ ↓ ↓
GATE GATE GATE GATE GATE GATE| Step | Action | Gate Requirement | FORBIDDEN Until Gate Passes |
|---|---|---|---|
| 1 | READ the prompt completely | All checkboxes checked | Analysis, changes |
| 2 | UNDERSTAND what the prompt does | Understanding output produced | Rating, fixes |
| 3 | RATE each part for issues | Issues table produced | Fixing issues |
| 4 | FIX issues by severity | All Critical/High fixed | Validation |
| 5 | VALIDATE against checklist | All REQUIRED checks pass | Output |
| 6 | OUTPUT optimized document | Format followed exactly | N/A |
CRITICAL: You MUST complete each gate before proceeding. DO NOT skip steps.
| Mode | Use When | Allowed Compression | Non-negotiables |
|---|---|---|---|
| Fast Path | Short/single-purpose prompt, low ambiguity, <=3 logical parts, no unresolved unknowns | READ+UNDERSTAND may be combined; RATE+FIX may be compacted into one section if issues table is still produced | VALIDATE and intent-preservation checks are ALWAYS required |
| Full Path | Multi-section prompt, high ambiguity, >=4 logical parts, conflicting constraints, or Critical/High risk | No compression. Execute each gate separately | All gates and templates required |
Mode selection rules (REQUIRED):
Global enforcement baseline: global_forbidden and VALIDATE are source-of-truth constraints for every gate; gate sections focus on step-specific requirements. </execution_flow>
<read_gate> STOP. DO NOT proceed to analysis.
Verify before proceeding:
</read_gate>
<understand_gate> STOP. DO NOT proceed to rating. Understand what this prompt does first.
## Understanding
**Goal:** [What the prompt achieves]
**Logical Parts:**
1. [Part name] - [purpose]
2. [Part name] - [purpose]
...
**Flow:** [How parts connect]## Assumptions & Unknowns
**Assumptions (temporary - proceeding with these):**
- [Assumption 1] - Impact if wrong: [consequence]
**Unknowns (MUST ask before proceeding):**
- [Unknown 1] - Why critical: [reason]
**Clarification needed:** Yes/NoIF Unknowns exist → THEN STOP and ask user before proceeding to RATE.
Verify before proceeding:
IF you are uncertain about your understanding → THEN re-read before proceeding. DO NOT guess.
</understand_gate>
<rate_gate> STOP. DO NOT fix anything yet. Rate each logical part for issues first.
| Category | What to Look For | Severity |
|---|---|---|
| Weak Words | "consider", "might", "could", "may", "should" in critical sections | Critical |
| Missing Enforcement | Rules without FORBIDDEN/ALLOWED | High |
| Ambiguous Instructions | "do some", "handle", "process" without specifics | High |
| Referential Ambiguity | "it", "this", "that", "above", "below" without clear antecedent | High |
| Missing Output Format | Expected outputs without templates | Medium |
| Missing Gates | Phase transitions without checkpoints | Medium |
| Duplication | Same logic/rule repeated in multiple places (not just examples) | Medium |
| Verbose/Bloat | Sections >20 lines that could be tables; prose without constraints | Medium |
| Emoji as Instructions | Emojis used as commands instead of strong words | Medium |
| Redundancy | Same example repeated, unnecessary variations | Low |
| Low Density | Explanations that don't constrain behavior | Low |
## Issues Found
| Part | Issue | Severity | Fix Needed |
|------|-------|----------|------------|
| [Part name] | [Description] | Critical/High/Medium/Low | [What to do] |Verify before proceeding:
</rate_gate>
| Weak Word | Context | Replacement |
|---|---|---|
| consider, might, could, may | Critical section | MUST, REQUIRED |
| consider, might, could, may | Optional guidance | Remove or keep with "optionally" |
| should, prefer | Critical section | MUST |
| should, prefer | Soft guidance | Keep as-is |
| do some, handle, process | Any | Specify exact action: "Run X", "Call Y" |
| as needed, if necessary | Any | IF [condition] → THEN [action] |
| feel free to, you can | Required action | Remove entirely, use MUST |
| feel free to, you can | Optional action | "Optionally, you may..." |
CRITICAL: Weak words in FORBIDDEN/MUST/NEVER sections MUST be replaced.
<fix_gate> STOP. Fix issues in priority order: Critical → High → Medium → Low.
| Strength | Keywords | Use For |
|---|---|---|
| Absolute | NEVER, ALWAYS, MUST, FORBIDDEN, CRITICAL | Non-negotiable rules |
| Stop | STOP, HALT, DO NOT proceed, WAIT | Gates/checkpoints |
| Required | REQUIRED, MANDATORY | Essential steps |
| Soft | should, prefer | Optional guidance only |
1. STATE: "You MUST X"
2. FORBID: "FORBIDDEN: Not doing X"
3. REQUIRE: "REQUIRED: Verify X complete"REQUIRED when:
Optional when:
Before making changes (when required), produce a <reasoning> block:
<reasoning>
1. **Current state:** [What exists now]
2. **Goal:** [What we are trying to achieve]
3. **Approach:** [Why this specific change]
4. **Risk:** [What could go wrong]
</reasoning><[name]_gate>
**STOP. DO NOT proceed. [What to verify]**
### Pre-Conditions
- [ ] [Previous step completed]
### Actions (REQUIRED)
1. [Action]
### Gate Check
**Verify before proceeding:**
- [ ] [Condition]
### FORBIDDEN
- [What not to do]
### ALLOWED
- [What is permitted]
### On Failure
- **IF** [condition] → **THEN** [recovery]
</[name]_gate>Verify before proceeding:
</fix_gate>
<validate_gate> STOP. DO NOT output yet. Validate all fixes against checklist.
REQUIRED checks:
Additional checks (if applicable):
Referential Clarity (MUST check):
MUST answer these questions:
IF weakness identified → THEN fix or document as limitation IF intent changed → THEN STOP and revert. Return to UNDERSTAND step.
ALL must be true before OUTPUT:
Verify before proceeding:
</validate_gate>
<output_gate> STOP. Verify VALIDATE step passed before outputting.
Selection rule (REQUIRED):
Common report header (REQUIRED for both variants):
# Optimization Complete
## Summary
- **Issues Found:** [N]
- **Fixes Applied:** [N]
- **Intent Preserved:** Yes
## Changes Made
| Category | Count | Examples |
|----------|-------|----------|
| Command Strengthening | [N] | [Brief example] |
| Gates Added/Fixed | [N] | [Brief example] |
| Redundancy Removed | [N] | [Brief example] |Variant A - Full Document (default):
## Optimized Document
[Full optimized content]Variant B - Patch-Style Delta (minimal edits):
## Patch-Style Delta
| Section | Before | After | Why |
|---------|--------|-------|-----|
| [Section name] | [Old text] | [New text] | [Reason] |</output_gate>
<precedence_table> When rules conflict, follow this precedence (highest wins):
| Priority | Category | Examples | Notes |
|---|---|---|---|
| 1 (highest) | Safety/Tool Restrictions | FORBIDDEN tools, NEVER actions | Always wins |
| 2 | User explicit request | "I want X", "Do Y" | Overrides defaults |
| 3 | FORBIDDEN/MUST rules | "FORBIDDEN: changing logic" | Overrides preferences |
| 4 | Skill defaults | Default behaviors, templates | Baseline |
| 5 (lowest) | Soft guidance | "prefer", "consider" | Yields to all above |
Resolution rule: When two rules conflict, the higher priority wins. Document the conflict and resolution. </precedence_table>
<conflict_protocol> Use this protocol when instructions conflict:
FORBIDDEN: Proceeding while both conflicting instructions remain active. </conflict_protocol>
<reasoning_patterns>
Use concise summaries only when needed to preserve context:
Conditional requirement:
</reasoning_patterns>
<content_guide>
| Keep (High Value) | Remove/Reduce (Low Value) |
|---|---|
| Tables with explicit actions | Explanatory prose without constraints |
| Imperative verbs (STOP, VERIFY, EXECUTE) | Repeated examples (keep 1-2) |
| FORBIDDEN/ALLOWED lists | Long paragraphs that can be tables |
| IF/THEN decision rules | Hedging language in critical rules |
| Markdown default + optional XML for attention control | Emoji used as instructions (unless required by output) |
</content_guide>
Use this only as a mnemonic; gate sections are source of truth.
| Need | Pattern |
|---|---|
| Stop/Checkpoint | **STOP. DO NOT proceed.** + ### Gate Check |
| Mandatory action | **REQUIRED:** You MUST [action] |
| Prohibited action | **FORBIDDEN:** [action] |
| Decision logic | **IF** [condition] → **THEN** [action] |
| Critical rule hardening | Triple Lock: STATE + FORBID + REQUIRE |
<common_mistakes>
| Mistake | Why It Fails | Fix |
|---|---|---|
| Over-strengthening soft guidance | "prefer" → "MUST" breaks optional flexibility | Keep "should/prefer" for truly optional items |
| Using "it/this/that" | Agent loses context, applies fix to wrong element | Name every entity explicitly |
| Changing working logic | User trusted original behavior | FORBIDDEN: If the logic works, don't touch it |
| Overusing XML tags | Noise and style drift without reliability gain | Keep Markdown default; use XML only for attention control |
</common_mistakes>
~30 seconds. Free. No account. Every finding cites a rule and a line of evidence.