home/writing/canonical-prompt-standard

CANONICAL PROMPT STANDARD

GPTClaudeGemini··1,069 copies·updated 2026-07-14
canonical-prompt-standard.prompt
<!--
  ARCHIVE — historical, not current project guidance.
  Archived: 2026-06-23 via Issue #165.
  Reason: Document found safe (no secrets, no private paths, no stale claims)
  but had consistency gaps with the authoritative AGENTS.md:
    - Local-CI-First policy missing
    - Human Approval Gate incomplete vs AGENTS.md §7
    - Evidence Format diverges (STDOUT/STDERR merged)
    - Source of Truth ordering differs
    - Workflow lacks "Local" CI qualifier
  Now superseded by AGENTS.md as the single source of truth for agent rules.
  Preserved for historical traceability of the project's agent-prompt design work.
-->

# Canonical Prompt Standard — Agent Run Prompts

> Wiederverwendbarer Standard fuer alle zukuenftigen Agenten-/Projekt-Prompts.
> OpenCode-spezifisch ausgerichtet. Projektunabhaengig formuliert.

**Version:** 1.0.0
**Last updated:** 2026-06-19
**Validated with:** OpenCode 1.15.0, Windows 10, PowerShell 5.1

---

## 1. Kontextfenster-Empfehlung

Starte jeden groesseren Agentenlauf in einem **frischen/leeren Kontextfenster**.

Behandle alle Informationen aus:

- ChatGPT-Memory
- alten Projektchats
- frueheren Agent-Reports
- manuell kopierten Projektstaenden

ausdruecklich als **potenziell veraltet** (`STALE_SOURCE`).

Der aktuelle Projektzustand darf nur durch echte Evidence im aktuellen Lauf bestaetigt werden.

---

## 2. Ziel-Agent: OpenCode

Der Standard-Agent fuer alle Runs ist **OpenCode**.

OpenCode-spezifische Regeln:

- Pruefe zuerst Version, Arbeitsverzeichnis, Modell-/Agent-Kontext
- Erfinde keine OpenCode-Kommandos
- Nutze nur tatsaechlich verfuegbare Tools und Permissions
- Kein Auto-Merge, kein Approval-Bypass, kein YOLO-Modus

---

## 3. Aktualitaetsregel (Reality Refresh)

### 3.1 Information Classification

Jede Annahme muss vor Nutzung klassifiziert werden:

| Classification      | Meaning                                     |
| ------------------- | ------------------------------------------- |
| `CONFIRMED_CURRENT` | Im aktuellen Lauf durch Evidence bestaetigt |
| `CONFIRMED_STALE`   | Belegt, aber offensichtlich alt             |
| `ASSUMPTION`        | Plausibel, aber nicht belegt                |
| `UNKNOWN`           | Nicht pruefbar                              |
| `NEEDS_VALIDATION`  | Muss vor Umsetzung geprueft werden          |
| `CONFLICT`          | Widerspruechliche Evidence gefunden         |

### 3.2 Reality Refresh Checkliste

Vor jeder Planung mindestens pruefen:

- [ ] aktueller Branch (`git branch --show-current`)
- [ ] Git-Status (`git status --short`)
- [ ] letzte Commits (`git log --oneline -n 10`)
- [ ] offene/geschlossene Issues (`gh issue list`)
- [ ] offene/geschlossene PRs (`gh pr list`)
- [ ] CI-Status (`gh run list`)
- [ ] Releases/Tags (`gh release list`)
- [ ] README, docs/, AGENTS.md
- [ ] `.opencode/` Konfiguration
- [ ] Runtime-Versionen (Node, Rust, pnpm, Git)
- [ ] OpenCode-Version und Betriebsart

---

## 4. OS-/Shell-Erkundung (Pre-Flight)

### 4.1 Zuerst OS und Shell erkennen

**NIEMALS** blind Linux-Befehle auf Windows oder PowerShell-Befehle auf Linux ausfuehren.

Plattformneutrale Erstpruefung:

when to use it

Community prompt sourced from the open-source GitHub repo xxammaxx/promptvault-lite (MIT). A "CANONICAL PROMPT STANDARD" style prompt — adapt the placeholders and specifics to your task. Imported as-is and not independently retested here, so check the output before relying on it.

tags

writingcommunitygeneral

source

xxammaxx/promptvault-lite · MIT