Compare commits

..
2 Commits
Author SHA1 Message Date
m3ta-chironandClaude Opus 5.5 f5252dc81e chore(beads): Orchestrator- und az-hilfe-Issues nach Test geschlossen
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-14 10:56:09 +01:00
m3ta-chironandClaude Opus 5.5 95169f2aee feat: Orchestrator und az-hilfe für rollenabhängige Ausstattung umbauen
- az-orchestrator: feste Routing-Tabelle durch Routing-Regeln ersetzt;
  delegiert nur an Subagents, die das Task-Tool auf dem Rechner anbietet,
  sonst passender Skill, sonst offener Hinweis an den Nutzer (IT)
- az-hilfe (Skill + Command): nennt nur tatsächlich verfügbare Fähigkeiten
  in Alltagssprache; veraltete Aussagen zu Rollout und lokalen Änderungen
  korrigiert (agent-lib-Abgleich, lokale Änderungen blockieren Updates)
- officecli-academic-paper aus der Vendor-Auswahl genommen und aus
  agent-lib.labels.json gestrichen
- README: Zielgruppen-Status und Abhängigkeitsregel aktualisiert
- .beads.gate.lock aus dem Index genommen und in .gitignore aufgenommen

Refs: az-agent-defaults-0b7, az-agent-defaults-2d3, az-agent-defaults-97z

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-14 10:36:25 +01:00
10 changed files with 106 additions and 580 deletions
View File
+4 -1
View File
@@ -1,5 +1,6 @@
{"_type":"issue","id":"az-agent-defaults-j35","title":"Repo-Gerüst: vier Artefakt-Verzeichnisse + README mit Guard-Regeln je Artefakt-Typ","description":"Quelle: Spec 01-az-agent-defaults-spec.md (lokal, wird nicht gepusht).\n\naz-agent-defaults wird als reines Content-Repo die eine Wahrheitsquelle für das Company-Default-Set. Dieses Ticket liefert das Gerüst: die vier Artefakt-Verzeichnisse (skills/, commands/, agents/, mcp/) und ein README, das die Contribution-Guard-Regeln je Artefakt-Typ so dokumentiert, dass ein Fachbereichs-Contributor ohne Architektur-Wissen richtig beisteuern kann:\n\n- Skills: Ordner mit SKILL.md und Frontmatter-Öffner (wie heute)\n- Commands: Markdown mit Frontmatter (description, optional agent/model) und Template-Body (Argument-Platzhalter erlaubt)\n- Agents: Markdown mit Frontmatter (description, mode primary/subagent, optional model/temperature, Permission-Profil); Subagent-Definitionen müssen über das Task-Tool aufrufbar bleiben\n- MCP: Fragmente für den mcp-Konfigurationsschlüssel, remote/streamable als Standard, Secrets grundsätzlich nur als Platzhalter\n\nDas README hält außerdem fest: Auslieferung und Guard-Engine (Pre-Flight auf dem Controller) leben im Fleet-Repo az-fleet; dieses Repo ist Content-only und über den Repo-Ref pinbar (Default: main). Zudem die Fixtures-Konvention: Testgegenstände für die Guard-Tests leben unter tests/fixtures/ und werden nie ausgeliefert, weil die Delivery-Rolle nur die vier Typ-Verzeichnisse liest (Sonntags-Entscheidung). Das Repo verabschiedet damit den Namen az-agent-skills (User Story 2).","acceptance_criteria":"- Die vier Artefakt-Verzeichnisse skills/, commands/, agents/, mcp/ sind im Repo angelegt\n- README dokumentiert die Guard-Regeln je Artefakt-Typ vollständig (Struktur-/Frontmatter-/Platzhalter-Anforderungen gemäß Spec B1)\n- README erklärt die Content/Mechanismus-Trennung zu az-fleet (Guard-Engine und Auslieferung dort) und das Ref-Pinning\n- Die Fixtures-Konvention tests/fixtures/ ist dokumentiert (nie ausgeliefert; Begründung: Delivery liest nur die vier Typ-Verzeichnisse)\n- Ein Contributor ohne Architektur-Wissen kann anhand des README allein entscheiden, wohin ein neues Artefakt gehört und ob es die Guard-Regeln erfüllt","status":"closed","priority":1,"issue_type":"task","assignee":"m3tam3re","owner":"p@m3ta.dev","created_at":"2026-08-22T07:57:14Z","created_by":"m3tam3re","updated_at":"2026-08-22T08:02:44Z","started_at":"2026-08-22T07:59:36Z","closed_at":"2026-08-22T08:02:44Z","close_reason":"Closed","labels":["ready-for-agent"],"dependency_count":0,"dependent_count":4,"comment_count":0}
{"_type":"issue","id":"az-agent-defaults-0b7","title":"az-orchestrator: Routing über installierte Subagents statt fester Routing-Tabelle","description":"Mit agent-lib.labels.json bekommen nicht mehr alle Rechner alle Subagents. Die feste Routing-Tabelle in agents/az-orchestrator.md (Zeile ~36ff) würde dann auf fehlende Agents zeigen. Umbau: Auswahl anhand der Subagent-Descriptions, die OpenCode dem Task-Tool ohnehin übergibt (Trigger-Description-Standard: Beispielanfragen in den ersten 80 Zeichen); Regel für 'kein passender Subagent'. Bis dahin darf die Tabelle nur ungelabelte Subagents nennen (README, Abschnitt Zielgruppen).","acceptance_criteria":"Keine hart verdrahteten Subagent-Namen mehr nötig; Smoke-Test: Routing klappt mit und ohne gelabelte Subagents; Prompt bleibt unter 10.000 Zeichen; az-pruefer-Prüfung ohne Mangel.","status":"open","priority":2,"issue_type":"task","owner":"m3ta-chiron@agentmail.to","created_at":"2026-11-14T09:12:12Z","created_by":"m3ta-chiron","updated_at":"2026-11-14T09:12:12Z","dependency_count":0,"dependent_count":0,"comment_count":0}
{"_type":"issue","id":"az-agent-defaults-64g","title":"az-fleet: Labels in agent-lib-Config schreiben, Guard, ADR-0020 (Profile-Rollout-Branch)","description":"Gehört ins Repo az-fleet (dort kein lokaler Checkout auf AZLT99 — hier als Merkposten). Abhängig von agent-lib Issue agent_lib-fh4 (Release mit Label-Feature).\n\nAuf Branch profile-rollout:\n- roles/agent_lib/tasks/config.yml: 'labels': fleet_user_roles[primary_user] in config.json (Wert kommt aus dept_* + fleet_extra_roles).\n- fleet_pins: agent-lib-Version mit Label-Feature.\n- default_set_delivery: Guard — jedes Label in agent-lib.labels.json ist bekannte Abteilung (dept_*) oder Zusatzrolle; Gleiches rückwirkend für x-fleet-audience.\n- Optional später: MCP-Scoping aus agent-lib.labels.json statt x-fleet-audience (Einträge = Server-Name).\n- config/managed/env_keys.yml Kommentar: Fragment heißt jetzt mcp/websearch.yaml (vorher exa.yaml).\n- ADR-0020 'Zielgruppen-Scoping für Skills/Agents/Commands' als Fortsetzung von ADR-0017.","acceptance_criteria":"vm-test: Rolle gesetzt → gelabelte Inhalte da; Rolle entfernt → unveränderte Kopien weg; Drift-Check grün; Folgelauf changed=0; Tippfehler-Label im Content-Repo bricht Guard rot ab.","status":"open","priority":2,"issue_type":"task","owner":"m3ta-chiron@agentmail.to","created_at":"2026-11-14T09:12:14Z","created_by":"m3ta-chiron","updated_at":"2026-11-14T09:12:14Z","dependency_count":0,"dependent_count":0,"comment_count":0}
{"_type":"issue","id":"az-agent-defaults-0b7","title":"az-orchestrator: Routing über installierte Subagents statt fester Routing-Tabelle","description":"Mit agent-lib.labels.json bekommen nicht mehr alle Rechner alle Subagents. Die feste Routing-Tabelle in agents/az-orchestrator.md (Zeile ~36ff) würde dann auf fehlende Agents zeigen. Umbau: Auswahl anhand der Subagent-Descriptions, die OpenCode dem Task-Tool ohnehin übergibt (Trigger-Description-Standard: Beispielanfragen in den ersten 80 Zeichen); Regel für 'kein passender Subagent'. Bis dahin darf die Tabelle nur ungelabelte Subagents nennen (README, Abschnitt Zielgruppen).","acceptance_criteria":"Keine hart verdrahteten Subagent-Namen mehr nötig; Smoke-Test: Routing klappt mit und ohne gelabelte Subagents; Prompt bleibt unter 10.000 Zeichen; az-pruefer-Prüfung ohne Mangel.","notes":"14.11.: Routing-Tabelle durch Routing-Regeln ersetzt (agents/az-orchestrator.md), keine Subagent-Namen mehr im Prompt, 6.239 Zeichen. Offen: Smoke-Test in OpenCode mit/ohne gelabelte Subagents. Nicht committet.","status":"closed","priority":2,"issue_type":"task","assignee":"m3ta-chiron","owner":"m3ta-chiron@agentmail.to","created_at":"2026-11-14T09:12:12Z","created_by":"m3ta-chiron","updated_at":"2026-11-14T09:56:05Z","started_at":"2026-11-14T09:29:26Z","closed_at":"2026-11-14T09:56:05Z","close_reason":"Routing-Regeln statt Tabelle; vom Nutzer in OpenCode getestet (14.11.2026), funktioniert.","dependency_count":0,"dependent_count":0,"comment_count":0}
{"_type":"issue","id":"az-agent-defaults-jtp","title":"Dogfooding + Smoke-Tests der perfektionierten Agents","description":"Abschlussvalidierung: Der perfektionierte az-pruefer läuft über alle 5 perfektionierten Agenten (Dogfooding — der Prüfer prüft als Erstes die perfektionierten Kollegen); Befunde werden eingearbeitet bis der Prüf-Report grün ist. Danach manueller Orchestrator-Smoke-Test: (1) Routing-Korrektheit — Recherche-Anfrage delegiert an az-researcher, Basecamp-Anfrage an az-basecamp, Office an az-office, Repo-Beitrag bleibt beim Orchestrator mit Formal-Check an az-pruefer; (2) Sprachregel — tschechische Testanfrage wird tschechisch beantwortet. Testprotokoll als Beleg ablegen (tests/ oder Notes).\n\n## Context\nGrilling-Entscheidung 8: Dogfooding + Smoke-Test statt Fleet-VM-Test (gehört nach az-fleet).","acceptance_criteria":"1) az-pruefer-Report über agents/*.md: alle Befunde behoben, Report grün. 2) Smoke-Test-Protokoll Routing liegt vor und zeigt korrekte Delegation. 3) Smoke-Test-Protokoll Sprachregel liegt vor (tschechische Anfrage → tschechische Antwort). 4) Vollständige Fleet-VM-Tests bleiben bewusst az-fleet überlassen (Spec-Trennung Content/Mechanismus).","status":"closed","priority":2,"issue_type":"task","owner":"m3ta-chiron@agentmail.to","created_at":"2026-09-20T17:43:52Z","created_by":"m3ta-chiron","updated_at":"2026-09-20T18:20:48Z","closed_at":"2026-09-20T18:20:48Z","close_reason":"Abschlussvalidierung erfolgreich. (1) Dogfooding: az-pruefer-Prompt lief ueber alle 5 Agenten: Erstpruefung 0 Guard-Verstoesze, 1 Standard-Verstosz (Orchestrator-Description) -\u003e als Regelkonflikt aufgeloest (README Trigger-Description praezisiert: Subagents=Beispielfragen, Primary=Missionssatz; Sprachregel-Variante gleichbedeutend), Re-Pruefung gruen. (2) Routing-Smoke-Test 5/5 korrekt (Recherche-\u003eaz-researcher, Basecamp-\u003eaz-basecamp inkl. Destruktiv-Hinweis, Office-\u003eaz-office, Repo-Beitrag-\u003eselbst+az-pruefer, cs-Basecamp-Anfrage-\u003eaz-basecamp). (3) Sprachregel: direkte tschechische Anfrage wurde vollstaendig tschechisch beantwortet. Protokoll: tests/protocols/2026-09-20-smoke-test-agents.md. Fleet-VM-Tests bewusst az-fleet ueberlassen.","labels":["ready-for-agent"],"dependencies":[{"issue_id":"az-agent-defaults-jtp","depends_on_id":"az-agent-defaults-74g","type":"blocks","created_at":"2026-09-20T17:43:52Z","created_by":"m3ta-chiron","metadata":"{}"},{"issue_id":"az-agent-defaults-jtp","depends_on_id":"az-agent-defaults-99v","type":"blocks","created_at":"2026-09-20T17:43:52Z","created_by":"m3ta-chiron","metadata":"{}"},{"issue_id":"az-agent-defaults-jtp","depends_on_id":"az-agent-defaults-bfj","type":"blocks","created_at":"2026-09-20T17:43:52Z","created_by":"m3ta-chiron","metadata":"{}"},{"issue_id":"az-agent-defaults-jtp","depends_on_id":"az-agent-defaults-h2j","type":"blocks","created_at":"2026-09-20T17:43:52Z","created_by":"m3ta-chiron","metadata":"{}"},{"issue_id":"az-agent-defaults-jtp","depends_on_id":"az-agent-defaults-m4t","type":"blocks","created_at":"2026-09-20T17:43:52Z","created_by":"m3ta-chiron","metadata":"{}"}],"dependency_count":5,"dependent_count":0,"comment_count":0}
{"_type":"issue","id":"az-agent-defaults-m4t","title":"az-office perfektionieren","description":"az-office nach dem Agenten-Prompt-Standard neu schreiben: Skill-Load „officecli“ als verpflichtender erster Schritt (Formulierung schärfen — aus „lade zu Beginn“ wird eine nicht verhandelbare erste Aktion, ausdrückliches Muster-Referenz des Prometheus-Ansatzes). Ebenenweise-Arbeitsweise (L1/L2/L3) und Grenzen bleiben, Trigger-Description mit Beispielfragen, Output-Vertrag (Ergebnis / Datei \u0026 Prüfbefund / Offene Punkte), Sprachregel, Temperatur-Mikro-Korrektur 0.2 → 0.1.\n\n## Context\nGrilling-Session 20.09. Skill-Delegation ist das ausdrückliche Muster (dünner Agent-Prompt über gut gepflegtem Skill).","acceptance_criteria":"1) Arbeitsweise Schritt 1 = Skill-Load officecli, verpflichtend formuliert. 2) L1/L2/L3-Prinzip erhalten. 3) Description trigger-optimiert. 4) Output-Vertrag mit Datei-\u0026-Prüfbefund-Sektion. 5) Sprachregel enthalten. 6) Demo: docx-Erstellung mit Prüfbefund-Sektion in der Antwort.","status":"closed","priority":2,"issue_type":"task","assignee":"m3ta-chiron","owner":"m3ta-chiron@agentmail.to","created_at":"2026-09-20T17:43:44Z","created_by":"m3ta-chiron","updated_at":"2026-09-20T18:20:48Z","started_at":"2026-09-20T18:02:01Z","closed_at":"2026-09-20T18:20:48Z","close_reason":"agents/az-office.md neu nach Standard: Schritt 1 = nicht verhandelbarer Skill-Load 'officecli' mit ausdruecklicher Prometheus-Muster-Referenz (duenne Agent-Shell ueber gepflegtem Skill); L1/L2/L3-Prinzip, Pruefschritt (outline/issues/validate) und Grenzen bleiben; Trigger-Description mit 3 Beispielauftraegen in den ersten 80 Zeichen; Output-Vertrag Ergebnis/Datei \u0026 Pruefbefund (ohne Pruefbefund nicht abgeschlossen)/Offene Punkte; Sprachregel; temperature 0.2 -\u003e 0.1. Nach Kosmetik-Fix (bearbeite sie) az-pruefer-Re-Pruefung gruen.","labels":["ready-for-agent"],"dependency_count":0,"dependent_count":1,"comment_count":0}
{"_type":"issue","id":"az-agent-defaults-bfj","title":"az-basecamp perfektionieren + Skill-Nutzung verankern","description":"az-basecamp nach Prometheus-Muster neu schreiben (dünne Shell über Skill): Verpflichtender erster Schritt = Skill „basecamp“ laden (Skill wird via az-fleet aus external/ auf die Nutzerebene ausgerollt — Lieferweg ist gesichert). Inline-CLI-Wissen („Typische Befehle …“) raus, ersetzt durch Skill-Load + 1-Zeilen-Fallback (basecamp --agent --help bei Unbekanntem). Trigger-Description mit Beispielfragen, Output-Vertrag (Ergebnis / Belege mit IDs-Links / Offene Punkte), Beleg-Pflicht je Aktion (keine Aktion ohne Beleg-ID), Sprachregel, Auth- und Fleet-Grenzen bleiben.\n\n## Context\nGrilling-Session 20.09.: external/-Skills werden über az-fleet ausgerollt (Nutzer-Entscheidung b). Muster-Vorbild: az-office + officecli-Skill.","acceptance_criteria":"1) Arbeitsweise Schritt 1 = Skill-Load basecamp (verpflichtend). 2) Keine inline-CLI-Befehlsliste mehr im Prompt. 3) Description trigger-optimiert. 4) Output-Vertrag mit Belege-Sektion. 5) Sprachregel enthalten. 6) Demo: Delegations-Anfrage erzeugt Basecamp-Objekt + Antwort mit Beleg-ID.","status":"closed","priority":2,"issue_type":"task","assignee":"m3ta-chiron","owner":"m3ta-chiron@agentmail.to","created_at":"2026-09-20T17:43:37Z","created_by":"m3ta-chiron","updated_at":"2026-09-20T18:20:48Z","started_at":"2026-09-20T18:02:01Z","closed_at":"2026-09-20T18:20:48Z","close_reason":"agents/az-basecamp.md neu als duenne Shell ueber dem basecamp-Skill (Prometheus-Muster): Schritt 1 = verpflichtender Skill-Load 'basecamp' (BEVOR irgendetwas anderes passiert), Inline-CLI-Befehlsliste entfernt, 1-Zeilen-Fallback basecamp --agent --help. Trigger-Description mit 3 Beispielfragen in den ersten 80 Zeichen; Output-Vertrag Ergebnis/Belege (Beleg-Pflicht: keine Aktion ohne Beleg-ID)/Offene Punkte; Sprachregel; Auth- (OAuth-Login interaktiv) und Fleet-Grenzen bleiben; haiku/0.2 bleibt. az-pruefer: konform ohne Befund.","labels":["ready-for-agent"],"dependency_count":0,"dependent_count":1,"comment_count":0}
@@ -11,3 +12,5 @@
{"_type":"issue","id":"az-agent-defaults-gj1","title":"Commands-Slice: Referenz-Command mit Argument-Platzhaltern + Guard-Fixtures","description":"Quelle: Spec 01-az-agent-defaults-spec.md.\n\nErster exemplarischer Company-Command in commands/: Markdown mit Frontmatter (description, optional agent/model) und Template-Body mit Argument-Platzhaltern ($ARGUMENTS, $1..$n) — Format gemäß verifizierter OpenCode-Doku (global ~/.config/opencode/commands/, pro Projekt .opencode/commands/; Shell-Output-Injection und Datei-Referenzen unterstützt). Der Command ist zugleich Referenz-Beitrag für Contributor und Testgegenstand für das Fleet-Szenario „/command ist in der OpenWork-/OpenCode-Sitzung verfügbar und löst das Template aus\". Inhaltlich bewusst trivial (Platzhalter-Niveau wie ow-hello; konkrete Inhalte sind Phase 2).\n\nZusätzlich ungültige Command-Fixtures unter tests/fixtures/ (z. B. Frontmatter ohne description, Datei ohne Frontmatter).\n","acceptance_criteria":"- Ein gültiger Referenz-Command liegt in commands/ und erfüllt die README-Guard-Regeln (description im Frontmatter, Template-Body, Argument-Platzhalter genutzt)\n- Der Command folgt dem OpenCode-Command-Format, sodass er nach Fleet-Auslieferung als /slash-Befehl verfügbar ist und das Template auslöst\n- Ungültige Command-Testgegenstände existieren unter tests/fixtures/ (mindestens: ohne description, ohne Frontmatter)\n- Keine Fixture liegt in einem ausgelieferten Typ-Verzeichnis","status":"closed","priority":2,"issue_type":"feature","assignee":"m3tam3re","owner":"p@m3ta.dev","created_at":"2026-08-22T07:57:49Z","created_by":"m3tam3re","updated_at":"2026-08-22T08:21:22Z","started_at":"2026-08-22T08:20:43Z","closed_at":"2026-08-22T08:21:22Z","close_reason":"Referenz-Command commands/az-hilfe.md (Gegenstück zum az-hilfe-Skill): description-Frontmatter, Template-Body mit $ARGUMENTS + $1, kebab-case-Name → /az-hilfe nach Fleet-Auslieferung. 4 ungültige Command-Fixtures unter tests/fixtures/commands/invalid/ (ohne-frontmatter, ohne-description, leere-description, prüfung.md mit Umlaut-Dateinamen) — decken alle im README dokumentierten Command-Fehlertypen ab. 17/17 Verifikations-Checks PASS.","labels":["ready-for-agent"],"dependencies":[{"issue_id":"az-agent-defaults-gj1","depends_on_id":"az-agent-defaults-j35","type":"blocks","created_at":"2026-08-22T09:57:48Z","created_by":"m3tam3re","metadata":"{}"}],"dependency_count":1,"dependent_count":0,"comment_count":0}
{"_type":"issue","id":"az-agent-defaults-gyj","title":"Agents-Slice: Referenz-Primäragent + Read-only-Subagent + Guard-Fixtures","description":"Quelle: Spec 01-az-agent-defaults-spec.md.\n\nZwei Referenz-Agent-Definitionen in agents/: ein spezialisierter Primäragent (per Agentenwechsel erreichbar) und ein Subagent mit Read-only-Permission-Profil (kein Edit/Bash) — Spezialisierung ohne Rechteausweitung (User Story 13). Beide folgen dem OpenCode-Format: Markdown mit Frontmatter (description, mode primary/subagent, optional model/temperature, Permission-Profil); Dateiname = Agentenname.\n\nKritisch: Die Subagent-Definition darf die Task-Tool-Delegation nie verbauen — Agenten müssen Subagenten weiterhin selbstständig starten können (User Story 12), und Permission-Profile dürfen niemals etwas erlauben, was der Managed-Layer verweigert (User Story 14).\n\nZusätzlich ungültige Agent-Fixtures unter tests/fixtures/ (z. B. mode fehlt, description fehlt).\n","acceptance_criteria":"- Ein Primäragent (mode: primary) und ein Subagent (mode: subagent) liegen in agents/ und erfüllen die README-Guard-Regeln\n- Der Subagent trägt ein Read-only-Permission-Profil ohne Edit/Bash\n- Die Subagent-Definition lässt Task-Tool-Aufruf und @mention zu (verbaut die Delegationsfähigkeit nicht)\n- Keine Agent-Definition weicht die Sicherheitsgrenzen des Managed-Layers auf (bleibt innerhalb des Permission-Regelwerks)\n- Ungültige Agent-Testgegenstände existieren unter tests/fixtures/ (mindestens: mode fehlt, description fehlt)\n- Keine Fixture liegt in einem ausgelieferten Typ-Verzeichnis","status":"closed","priority":2,"issue_type":"feature","assignee":"m3tam3re","owner":"p@m3ta.dev","created_at":"2026-08-22T07:57:49Z","created_by":"m3tam3re","updated_at":"2026-08-22T08:26:45Z","started_at":"2026-08-22T08:24:04Z","closed_at":"2026-08-22T08:26:45Z","close_reason":"Zwei Referenz-Agenten in agents/: az-beitrag (mode: primary, ohne tools-Restriction — Delegationsfähigkeit intakt, Body betont Managed-Layer-Grenze, delegiert aktiv an az-pruefer) + az-pruefer (mode: subagent, Read-only-Profil tools: [read, glob, grep] ohne Edit/Bash, per @mention/Task-Tool erreichbar). 3 ungültige Agent-Fixtures (ohne-mode, ohne-description, ungueltiger-mode) — alle README-dokumentierten Fehlertypen. 19/19 Checks PASS (1 Regex-Bug im Prüfscript korrigiert nachgewiesen).","labels":["ready-for-agent"],"dependencies":[{"issue_id":"az-agent-defaults-gyj","depends_on_id":"az-agent-defaults-j35","type":"blocks","created_at":"2026-08-22T09:57:48Z","created_by":"m3tam3re","metadata":"{}"}],"dependency_count":1,"dependent_count":0,"comment_count":0}
{"_type":"issue","id":"az-agent-defaults-dzx","title":"Skills-Slice: ow-hello aus az-agent-skills übernehmen + Skill-Guard-Fixtures","description":"Quelle: Spec 01-az-agent-defaults-spec.md.\n\nDer Pilot-Skill ow-hello wandert aus dem Vorgänger-Repo az-agent-skills in skills/ — inhaltlich unverändert; einzig die Erwähnung „Repository az-agent-skills\" im Skill-Text wird auf az-agent-defaults aktualisiert (Ticketing-Entscheidung 22.08.2026). Damit bleibt der bestehende Skills-Spiegel (ADR-0006-Logik) ohne Funktionsverlust funktionsfähig.\n\nZusätzlich entstehen die Testgegenstände für den Guard-Test „ungültiges Artefakt im Repo → Run bricht kontrolliert ab\": unter tests/fixtures/ ungültige Skill-Artefakte (z. B. Ordner ohne SKILL.md; SKILL.md ohne Frontmatter-Öffner). Die Guard-Engine selbst implementiert az-fleet (Pre-Flight der Delivery-Rolle).\n","acceptance_criteria":"- ow-hello liegt in skills/ und ist inhaltlich identisch mit dem Stand aus az-agent-skills (einzige Abweichung: Repo-Erwähnung az-agent-defaults)\n- Frontmatter-Öffner und Struktur erfüllen die im README dokumentierten Skill-Guard-Regeln\n- Unter tests/fixtures/ existieren ungültige Skill-Testgegenstände (mindestens: Ordner ohne SKILL.md, SKILL.md ohne Frontmatter-Öffner)\n- Keine Fixture liegt in einem der vier ausgelieferten Typ-Verzeichnisse","status":"closed","priority":2,"issue_type":"feature","assignee":"m3tam3re","owner":"p@m3ta.dev","created_at":"2026-08-22T07:57:48Z","created_by":"m3tam3re","updated_at":"2026-08-22T08:09:02Z","started_at":"2026-08-22T08:06:37Z","closed_at":"2026-08-22T08:09:02Z","close_reason":"Skills-Slice umgesetzt: ow-hello aus az-agent-skills nach skills/ migriert (einzige Abweichung: Repo-Erwähnung L15 → az-agent-defaults); 5 ungültige Skill-Fixtures unter tests/fixtures/skills/invalid/ (ordner-ohne-skill-md, ohne-frontmatter, leeres-frontmatter, name-ungleich-ordner, ohne-description) — decken alle im README dokumentierten Skill-Guard-Fehlertypen ab, jede Fixture failt exakt eine Regel; alle 4 Akzeptanzkriterien per Skript verifiziert (15/15 PASS); .gitkeep-Platzhalter entfernt.","labels":["ready-for-agent"],"dependencies":[{"issue_id":"az-agent-defaults-dzx","depends_on_id":"az-agent-defaults-j35","type":"blocks","created_at":"2026-08-22T09:57:48Z","created_by":"m3tam3re","metadata":"{}"}],"dependency_count":1,"dependent_count":0,"comment_count":0}
{"_type":"issue","id":"az-agent-defaults-2d3","title":"az-hilfe: zeigt tatsächlich installierte Fähigkeiten statt fester Liste","description":"Skill und Command az-hilfe sollen nach Einführung der Labels nur nennen, was auf dem Rechner installiert ist (Skills/Agents/Commands des Nutzers), nicht eine feste Liste aller Repo-Inhalte.","acceptance_criteria":"Auf einem Rechner ohne Label-Inhalte erwähnt az-hilfe keine gelabelten Agents/Skills.","notes":"14.11.: skills/az-hilfe/SKILL.md neu geschrieben (nur tatsächlich verfügbare Fähigkeiten in Alltagssprache, veraltete Aussagen zu Rollout/lokalen Änderungen korrigiert), commands/az-hilfe.md angepasst. Offen: Live-Test. Nicht committet.","status":"in_progress","priority":3,"issue_type":"task","assignee":"m3ta-chiron","owner":"m3ta-chiron@agentmail.to","created_at":"2026-11-14T09:12:13Z","created_by":"m3ta-chiron","updated_at":"2026-11-14T09:31:18Z","started_at":"2026-11-14T09:29:27Z","lease_expires_at":"2026-11-14T09:34:27Z","heartbeat_at":"2026-11-14T09:29:27Z","dependency_count":0,"dependent_count":0,"comment_count":0}
{"_type":"issue","id":"az-agent-defaults-97z","title":"officecli-academic-paper aus der Vendor-Auswahl entfernen","description":"Ist aktuell nur unter Label it geparkt; für die Gruppe ohne Nutzen. agent-lib vendor update officecli mit exclude officecli-academic-paper (analog morph-ppt), danach Eintrag aus agent-lib.labels.json entfernen.","status":"closed","priority":4,"issue_type":"chore","owner":"m3ta-chiron@agentmail.to","created_at":"2026-11-14T09:12:15Z","created_by":"m3ta-chiron","updated_at":"2026-11-14T09:31:18Z","closed_at":"2026-11-14T09:31:18Z","close_reason":"officecli-academic-paper per 'agent-lib vendor select officecli --remove' ausgeschlossen, Eintrag aus agent-lib.labels.json entfernt; validate grün. Nicht committet.","dependency_count":0,"dependent_count":0,"comment_count":0}
+1
View File
@@ -6,3 +6,4 @@
*.db
.beads-credential-key
.beads/proxieddb/
.beads.gate.lock
+9 -8
View File
@@ -355,10 +355,11 @@ Inline-Prompt.
## Zielgruppen: `agent-lib.labels.json`
> **Status: vorbereitet, noch ohne Wirkung.** Die Datei wird erst
> ausgewertet, sobald agent-lib das Label-Feature kann (Vorschlag:
> `agent-lib/docs/proposals/client-labels.md`) und az-fleet die Labels in
> die Client-Config schreibt. Bis dahin bekommen alle alles.
> **Status: noch ohne Wirkung.** agent-lib wertet die Datei aus, sobald
> das Release mit Label-Feature ausgerollt ist und az-fleet die Labels in
> die Client-Config schreibt (Doku: agent-lib-README, Abschnitt „Client
> labels“). Bis dahin bekommen alle alles. Ab diesem Release prüft
> `agent-lib validate` die Datei mit.
Nicht jede Abteilung braucht jeden Skill. Die Datei im Repo-Root legt fest,
welche Inhalte **nur** an bestimmte Zielgruppen gehen:
@@ -395,10 +396,10 @@ welche Inhalte **nur** an bestimmte Zielgruppen gehen:
**Abhängigkeiten beachten:** Ein Agent darf nicht fest auf einen Agenten
oder Skill verweisen, der ein Label trägt, das er selbst nicht hat — auf
Rechnern ohne dieses Label fehlt das Ziel. Insbesondere die Routing-Tabelle
von `az-orchestrator` (geht an alle) darf nur ungelabelte Subagents nennen,
bis der Orchestrator auf Routing über die installierten Subagents umgebaut
ist.
Rechnern ohne dieses Label fehlt das Ziel. `az-orchestrator` routet deshalb
ohne feste Tabelle über die Subagents, die das Task-Tool auf dem jeweiligen
Rechner anbietet; ein neuer Subagent wird allein über seine
Trigger-Description gefunden (siehe Agenten-Prompt-Standard).
## Trennung Content / Mechanismus
+1 -2
View File
@@ -11,8 +11,7 @@
"to-questionnaire",
"to-spec",
"wait-what",
"writing-for-agents",
"officecli-academic-paper"
"writing-for-agents"
],
"buchhaltung": [
"officecli-financial-model",
+2 -2
View File
@@ -160,13 +160,13 @@
"mode": "all",
"exclude": [
"morph-ppt",
"morph-ppt-3d"
"morph-ppt-3d",
"officecli-academic-paper"
]
},
"inventory": {
"skills": [
"officecli",
"officecli-academic-paper",
"officecli-data-dashboard",
"officecli-docx",
"officecli-financial-model",
+27 -14
View File
@@ -1,5 +1,5 @@
---
description: Standard-Einstiegsagent der AZ-Gruppe — sortiert jede Anfrage, delegiert an die spezialisierten Subagents und verifiziert deren Ergebnisse. Router und Verifikator in einer Hand für Recherche, Basecamp, Office, Programmierung und Repo-Beiträge.
description: Standard-Einstiegsagent der AZ-Gruppe — sortiert jede Anfrage, delegiert an die spezialisierten Subagents und verifiziert deren Ergebnisse. Router und Verifikator in einer Hand für alle Fachgebiete, für die auf diesem Rechner Subagents installiert sind, plus Programmierung und Repo-Beiträge.
mode: primary
model: az-litellm/glm-5-3
temperature: 0.3
@@ -15,7 +15,7 @@ gibst du nie ab — du bleibst der eine Ansprechpartner.
## Arbeitsweise
1. **Anfrage einsortieren** — Lies, was der Nutzer will, und ordne die
Anfrage anhand der Routing-Tabelle zu. Abschluss: das Ziel steht fest
Anfrage nach den Routing-Regeln den verfügbaren Subagents zu. Abschluss: das Ziel steht fest
(Subagent oder du selbst). Ist die Anfrage mehrdeutig, stellst du eine
gebündelte Rückfrage statt zu raten.
@@ -33,19 +33,32 @@ gibst du nie ab — du bleibst der eine Ansprechpartner.
transparent benannt. Die Gruppe arbeitet deutsch, tschechisch und
englisch — die Sprache des Nutzers schlägt immer die des Prompts.
### Routing-Tabelle
### Routing-Regeln
| Anfrage handelt von … | Delegiere an |
|---|---|
| Recherche im Web, Quellen, Vergleiche — „Was kostet aktuell ein KI-Abo für kleine Teams?“, „Vergleich die drei günstigsten Provider“, „Finde die offizielle Doku zu API X“, „Jaké jsou aktuální sazby pro malé týmy?“ | `az-researcher` |
| Basecamp: Projekte, To-dos, Nachrichten, Chat, Dateien — „Welche To-dos habe ich diese Woche?“, „Poste die Zusammenfassung im Projekt X“, „Which files are in project Y?“, „Räume das alte Projekt Z auf“ | `az-basecamp` |
| Office-Dateien (.docx/.xlsx/.pptx) — „Erstelle ein Angebot als Word-Dokument“, „Mach aus dieser CSV eine saubere Excel-Tabelle“, „Aktualisiere Folie 3 der Präsentation“, „Vygeneruj smlouvu jako Word“ | `az-office` |
| Beitrag zu diesem Repo (Skill, Command, Agent, MCP) — „Schreib einen Skill für Zugferd-Prüfung“, „Leg einen Agenten für Rechnungsprüfung an“, „Add an MCP fragment for the new wiki service“ | du selbst; Formal-Check an `az-pruefer` |
| Programmierung, Projektdateien, alles andere — „Fix den Bug in login.py“, „Refactore das Modul“, „Richte die Tests für den Parser ein“, einfache Wissensfragen | du selbst |
Welche Subagents es gibt, ist **je Rechner verschieden** — die Ausstattung
richtet sich nach Abteilung und Rolle des Nutzers. Maßgeblich ist allein die
Liste der Subagents, die dir das Task-Tool anbietet, mit ihrer Beschreibung.
Die Beschreibungen beginnen mit typischen Nutzeranfragen — daran ordnest du
zu.
Passt die Anfrage auf mehrere Zeilen: Nimm die konkreteste. Grenzfälle, die
zwei Zeilen berühren, delegierst du an die konkretere und sagst dem
Subagenten explizit, was vom anderen Gebiet mitzudenken ist.
1. **Passender Subagent in deiner Liste** → delegiere an ihn. Passen
mehrere, nimm den konkretesten und sag ihm, was vom anderen Gebiet
mitzudenken ist.
2. **Kein passender Subagent, aber ein passender Skill** → lade den Skill
und erledige die Aufgabe selbst.
3. **Programmierung, Projektdateien, einfache Wissensfragen** → du selbst.
4. **Beitrag zum Agenten-Repo** (Skill, Command, Agent, MCP-Fragment) → du
selbst; den Formal-Check übergibst du an einen Prüf-Subagenten, falls
einer in deiner Liste steht — sonst prüfst du selbst gegen die README
des Repos.
5. **Nichts davon passt** und die Aufgabe braucht ein Werkzeug, das dir
fehlt (z. B. Zugriff auf ein Fachsystem) → sag das dem Nutzer offen: Auf
diesem Rechner ist dafür nichts eingerichtet; Ansprechpartner ist die IT.
Erfinde keinen Zugriff und keine Ergebnisse.
**Nie** einen Subagenten aufrufen oder dem Nutzer anbieten, der nicht in
deiner Liste steht — auch wenn du seinen Namen kennst oder der Nutzer ihn
von Kollegen gehört hat.
### Delegations-Regeln
@@ -81,7 +94,7 @@ Prüfgrundlage — gehe sie vor jedem Durchreichen durch:
Nutzer — nicht als durchgereichte Ausrede. Harmlose Annahmen benennst du
als solche und reichst sie mit der Antwort mit.
Beispiel: `az-researcher` meldet „Preis liegt bei ca. 40 €“ ohne Quelle und
Beispiel: Ein Recherche-Subagent meldet „Preis liegt bei ca. 40 €“ ohne Quelle und
als offenen Punkt „Budget unklar“ — beides reicht nicht: Beleg beim
Subagenten nachfordern, die Budget-Frage an den Nutzer statt durchzureichen.
+3 -2
View File
@@ -6,5 +6,6 @@ Orientiere den Anwender zu seiner Frage: $ARGUMENTS
Lade dafür den Skill `az-hilfe` und folge seiner Anleitung. Ist $1 genannt,
behandle es als Themenbereich (`skills`, `commands`, `agents` oder `mcp`) und
gehe gezielt darauf ein. Antworte auf Deutsch, freundlich und in kurzen
Schritten — und führe darüber hinaus keine Aktionen aus.
gehe gezielt darauf ein. Nenne nur Fähigkeiten, die in dieser Sitzung
tatsächlich verfügbar sind. Antworte freundlich, in kurzen Schritten und in
der Sprache der Anfrage — und führe darüber hinaus keine Aktionen aus.
@@ -1,507 +0,0 @@
---
name: officecli-academic-paper
description: "Use this skill to build academic-style .docx output: journal / conference / thesis chapters carrying formal citation style (APA, Chicago, IEEE, MLA), numbered equations, figure & table cross-references, footnotes/endnotes, bibliography, or multi-column journal layout. Trigger on: 'research paper', 'journal paper', 'conference paper', 'manuscript', 'thesis', 'APA', 'MLA', 'Chicago', 'IEEE two-column', 'bibliography', 'hanging indent', 'citation style', 'abstract + keywords', 'equation numbering', 'cross-reference', paper with footnotes/endnotes. Output is a single .docx."
---
# OfficeCLI Academic Paper Skill
**This skill is a scene layer on top of `officecli-docx`.** Every docx hard rule — style architecture, heading hierarchy, shell quoting, page-break rules, live PAGE field, Delivery Gate, renderer quirks — is inherited, not re-taught. This file adds only what academic papers need on top: citation styles, equations, SEQ / PAGEREF cross-refs, multi-column journal layout, bibliography hanging indent, abstract/keywords/affiliation block.
When the docx base rules cover it, the text here says `→ see docx v2 §X`. Read docx v2 first if you have not.
## Setup
If `officecli` is missing:
- **macOS / Linux**: `curl -fsSL https://d.officecli.ai/install.sh | bash`
- **Windows (PowerShell)**: `irm https://d.officecli.ai/install.ps1 | iex`
Verify with `officecli --version` (open a new terminal if PATH hasn't picked up). If install fails, download a binary from https://github.com/iOfficeAI/OfficeCLI/releases.
## ⚠️ Help-First Rule
**This skill teaches what an academic paper requires, not every command flag.** When a prop name, enum value, or field instruction is uncertain, consult help BEFORE guessing.
```bash
officecli help docx # All docx elements
officecli help docx <element> # Full schema (e.g. section, equation, field, footnote)
officecli help docx <element> --json # Machine-readable
```
Help is pinned to the installed CLI version. **When this skill and help disagree, help wins.** Every `--prop X=` in this file has been grep-verified against `officecli help docx <element>` — if help adds / renames a prop in a later version, trust help.
## Mental Model & Inheritance
**Inherits docx v2.** You should have read `skills/officecli-docx/SKILL.md` first. This skill assumes you know how to add paragraphs, set styles, build tables, insert images, manage TOC/footer/headers, force page breaks, and run the Delivery Gate. If any of those are unfamiliar, open a second session on docx v2 before continuing.
## Shell & Execution Discipline
**Shell quoting, incremental execution, `$FILE` convention** → see docx v2 §Shell & Execution Discipline. The same rules apply here verbatim — quote `[N]` paths, single-quote any value containing `$` (including `$2.8B` in a body paragraph or `@` DOIs), never hand-write `\$ \t \n` in executable examples, one command at a time. Academic-paper examples below use `$FILE` as a shell variable (`FILE="thesis.docx"`).
## What "academic" means here (identity)
An academic paper is a docx with a **scholarly layer** on top: verifiable citations, precise equations, cross-refs that stay in sync, a formatted reference list. The base docx rules still apply; academic adds six deltas:
1. **Citation style is a contract.** APA / Chicago / IEEE / MLA each dictate author format, date placement, reference-list order, in-text marker shape. Pick one at the start; every later decision (hanging indent, footnote vs parenthetical, `[1]` vs `(Smith, 2024)`) follows.
2. **Equations are first-class content** — inline `oMath` inside prose, display `oMathPara` as standalone blocks, optionally numbered.
3. **Figures and tables auto-number.** `SEQ Figure` / `SEQ Table` fields count them; `PAGEREF` links "see Fig. 2" to its live page number.
4. **Bibliography uses hanging indent** (first line flush left, continuation lines indented). Not first-line indent. Not left indent alone. Hanging.
5. **Abstract / keywords / affiliation block** is a first-page three-piece, not a cover in the marketing sense. Block-style abstract, no first-line indent, no decoration.
6. **Multi-column layout** appears in IEEE / ACM / Nature / many journals: single-column abstract + two-column body.
### Reverse handoff — when to go BACK to docx
Stay in **docx v2** for white papers, policy briefs, technical reports, HR templates — anything without a venue / citation style. Use **this skill** only when the document will carry at least TWO of: citation-style biblio, equations, SEQ/PAGEREF cross-refs, multi-column, abstract + keywords block.
## Workflow — 5 verbs
1. **Read the venue spec.** APA 7 / Chicago 17 / IEEE / MLA 9 / journal-specific. Line spacing, font, citation shape, biblio sort order — everything downstream follows from this one decision.
2. **Plan the sections.** Abstract → keywords → introduction → methods → results → discussion → conclusion → references. Estimate heading count for TOC decision (3+ headings = add a TOC, see docx v2 §Table of Contents).
3. **Set styles up front.** Heading1 / Heading2 / Heading3 / Caption / AbstractTitle / Bibliography. Define all styles BEFORE any content (→ see docx v2 §Paragraphs and styles — same rule here, same failure mode if skipped).
4. **Build body in order.** Cover / title block → abstract → keywords → TOC (if needed) → body sections in reading order → figures / tables with SEQ captions → bibliography → footnotes are added last by paragraph path.
5. **QA — Delivery Gate.** Inherit docx v2 Gates 1-3, then add academic Gates 4-5 below.
## Requirements (academic floor on top of docx v2)
Everything in docx v2 §Requirements for Outputs applies. On top of that, academic papers MUST meet these additional rules:
### Typography and spacing (venue-aware)
- **Font.** Times New Roman 11-12pt body (default) or venue-specified (IEEE uses Times 10pt 2-col; APA allows Calibri 11pt). Same body font throughout; no decorative heading fonts.
- **Heading hierarchy.** H1 = 20pt bold, H2 = 14pt bold, H3 = 12pt bold italic, body = 11-12pt. (Same numbers as docx v2 — restated because academic papers never rely on Word defaults.)
- **Line spacing.** APA 7 = 2x (double). Chicago / IEEE / most journals = 1.5x. Never below 1.15x. Set on body paragraphs and on References.
- **Margins.** 1 inch (1440 twips) all sides unless the venue says otherwise (some journals require 1.25in left for binding — check the spec).
### Abstract, bibliography, caption placement
- **Abstract is block-style.** NO `firstLineIndent`. Use `spaceAfter=12pt` for paragraph separation. If `view issues` reports "body paragraph missing first-line indent" on an Abstract paragraph, it's a false positive — ignore.
- **Bibliography uses hanging indent.** Each entry is one paragraph with `indent=720 hangingIndent=720` (left indent 0.5", first-line reversed by same amount). First line flush left; wraps indent under author name.
- **Figure captions go BELOW the figure.** Table captions go ABOVE the table. This is the single rule most non-academics get wrong — APA, Chicago, IEEE, MLA all agree on it.
- **Citation round-trip.** Every in-text citation key must resolve to an entry in the reference list. Delivery Gate 4 verifies.
- **SEQ presence.** Any paper with numbered figures or tables must carry live `SEQ Figure` / `SEQ Table` fields (not hardcoded "Figure 1" text that drifts when you insert a new figure mid-document). Delivery Gate 5 verifies.
### Cover / first-page block
Academic covers differ from professional covers. Minimum elements: title (centered, 20-22pt bold), author(s), affiliation, submission target or journal, date, abstract, keywords. The "60% fill" rule from docx v2 §Visual delivery floor still applies — a three-line cover with half a page of whitespace is a fail. See §Abstract / keywords / affiliation block below for the first-page recipe.
### Section numbering convention (STYLE-DEPENDENT — do not apply blindly)
Academic section numbers are **part of the heading text**, not computed via list numbering. `officecli`'s `numId`/`listStyle` mechanism is fragile across Heading1 re-use, so hand-write the prefix. BUT the prefix shape varies by style — DO NOT use the same form for all four:
| Style | H1 format | H2 format | Example |
|---|---|---|---|
| **APA 7** | **UNNUMBERED centered bold** | Unnumbered left-aligned bold | `Introduction` / `Methods` (centered) |
| **Chicago** | `"N. Title"` left-aligned | `"N.M Title"` | `1. Introduction`, `2.1 Policy Formation` |
| **IEEE** | `"N. TITLE"` ALL CAPS + Roman numerals | `A. Subtitle` title case | `I. INTRODUCTION`, `II. RELATED WORK`, `A. Datasets` |
| **MLA 9** | Unnumbered left-aligned bold | Same | `Literature Review` (no prefix) |
APA 7 L1 headings are **centered, bold, unnumbered**; L2 are flush-left bold; L3 flush-left bold italic; L4/L5 run-in. Do NOT prefix APA headings with `1. / 2.` — that is Chicago/IEEE convention. IEEE wants ALL CAPS with Roman numerals (`I. INTRODUCTION`); inside each section, use `A./B./C.` sub-headings (title case). Arabic-numbered body sections are Chicago-style only.
**Exception for all four**: References / Bibliography / Works Cited / Acknowledgments are unnumbered regardless of style — omit the `N.` prefix.
## Quick Start — minimal APA paper
```bash
FILE="paper.docx"
officecli create "$FILE"
officecli open "$FILE"
officecli set "$FILE" / --prop defaultFont="Times New Roman"
officecli add "$FILE" /body --type paragraph --prop text="Remote Work and Team Cohesion" --prop align=center --prop size=20pt --prop bold=true --prop spaceAfter=24pt
officecli add "$FILE" /body --type paragraph --prop text="Alice Chen" --prop align=center --prop size=12pt
officecli add "$FILE" /body --type paragraph --prop text="Department of Psychology, Stanford University" --prop align=center --prop size=11pt --prop spaceAfter=24pt
officecli add "$FILE" /body --type paragraph --prop text="Abstract" --prop align=center --prop size=14pt --prop bold=true --prop spaceBefore=12pt --prop spaceAfter=6pt
officecli add "$FILE" /body --type paragraph --prop text="This study examines remote-work adoption on team cohesion across 18 months..." --prop size=12pt --prop lineSpacing=2x --prop spaceAfter=12pt
officecli add "$FILE" /body --type paragraph --prop text="Keywords: remote work, team cohesion, psychological safety" --prop italic=true --prop size=11pt --prop spaceAfter=18pt
officecli add "$FILE" /body --type paragraph --prop text="1. Introduction" --prop style=Heading1 --prop size=20pt --prop bold=true --prop spaceBefore=18pt --prop spaceAfter=12pt
officecli add "$FILE" /body --type paragraph --prop text="Remote-work research (Smith, 2024) has expanded since 2020..." --prop size=12pt --prop lineSpacing=2x --prop firstLineIndent=720
officecli add "$FILE" /body --type paragraph --prop text="References" --prop style=Heading1 --prop size=20pt --prop bold=true --prop spaceBefore=18pt --prop spaceAfter=12pt
officecli add "$FILE" /body --type paragraph --prop text="Smith, J. (2024). Remote work and cohesion. Journal of Applied Psychology, 109(3), 412-430." --prop size=12pt --prop lineSpacing=2x --prop indent=720 --prop hangingIndent=720
officecli add "$FILE" / --type footer --prop type=default --prop align=center --prop size=10pt --prop field=page
officecli close "$FILE"
officecli validate "$FILE"
```
Ten-line skeleton. Real papers grow by adding more body paragraphs, more bibliography entries (each with the same `indent=720 hangingIndent=720` pair), figures / tables with captions, and a TOC if there are 3+ Heading1s. The Quick Start validates clean; the sections below elaborate each dimension.
## Citation style recipes
Four mainstream families. Pick one at project start; every downstream decision follows. **Per-style decision table:**
| Style | In-text shape | Reference list order | Body line spacing | Footnotes? |
|---|---|---|---|---|
| APA 7 | `(Smith, 2024)` or `Smith (2024)` | Alphabetical by author | 2x (double) | Rare (content notes only) |
| Chicago 17 (Notes-Bib) | Superscript footnote number | Alphabetical by author | 1.5x-2x | **Primary** (full citation in footnote) |
| IEEE | `[1]`, `[2]`, ..., `[N]` | Order of first citation | 1.15x-1.5x, 2-col | Rare |
| MLA 9 | `(Smith 412)` page-number | Alphabetical by author, "Works Cited" | 2x | Rare |
Shared defaults across all four: reference-list paragraphs use `indent=720 hangingIndent=720` (hanging indent 0.5"); add a live TOC if 3+ Heading1s (→ see docx v2 §Table of Contents); set `updateFields=true` and report TOC page numbers as uncomputed until a Word-compatible field engine updates them.
### APA 7 (social sciences — psychology, education, management)
- In-text: `(Author, Year)` or `Author (Year)` for narrative. Page number required on direct quotes: `(Smith, 2024, p. 15)`. Three+ authors: `(Smith et al., 2024)` after first citation.
- Reference list order: **alphabetical by first author's surname**. Title caps: sentence case for article titles, title case for journal names (italic).
- Reference shape: `Author, A. A., & Co-Author, B. B. (Year). Title of article. Journal Name, Volume(Issue), pages.` DOI preferred over URL; present as https URL, not `doi:` prefix.
- Double-space everything (`lineSpacing=2x`) including abstract and references. Body first-line indent = 0.5" (`firstLineIndent=720`).
```bash
# Body paragraph with parenthetical citation
officecli add "$FILE" /body --type paragraph --prop text="Remote work adoption accelerated during the pandemic (Kramer & Kramer, 2020)." --prop size=12pt --prop lineSpacing=2x --prop firstLineIndent=720
# Reference entry with hanging indent
officecli add "$FILE" /body --type paragraph --prop text="Kramer, A., & Kramer, K. Z. (2020). The potential impact of the Covid-19 pandemic on occupational status. Journal of Vocational Behavior, 119, 103442." --prop size=12pt --prop lineSpacing=2x --prop indent=720 --prop hangingIndent=720
# DOI hyperlink appended to the reference paragraph
officecli add "$FILE" "/body/p[last()]" --type hyperlink --prop url="https://doi.org/10.1016/j.jvb.2020.103442" --prop text="https://doi.org/10.1016/j.jvb.2020.103442"
```
QA: `officecli query "$FILE" 'paragraph[hangingIndent]'` returns every reference entry; zero references with first-line indent instead of hanging.
### Chicago 17 — Notes-Bibliography (humanities — history, philosophy, religion)
- In-text: superscript footnote number; full citation in the first footnote (`Timothy Brook, The Troubled Empire (Cambridge, MA: Harvard UP, 2010), 142.`); **shortened form** thereafter (`Brook, Troubled Empire, 150.`).
- **Repeat-citation rule (Chicago 17, op. cit. deprecated):**
- **Immediately-consecutive** citation of **the same source, same page** → `Ibid.`
- **Immediately-consecutive, different page** of same source → `Ibid., 22.`
- Non-consecutive repeat → **shortened form** (`Brook, Troubled Empire, 150.`), NOT `op. cit.`. Chicago 17 drops `op. cit.` — use shortened form every time except for immediate repeats.
- Bibliography at end, **alphabetical by first author's surname** ("Brook, Timothy."), hanging indent. Footnote body renders at the viewer's footnote default (typically 10pt); bibliography entries 12pt. (The `footnote` element exposes only `text` — size is not settable per-footnote; trust renderer defaults.)
- Typical split for primary-source-heavy papers: `Primary Sources` and `Secondary Sources` as two Heading2s under a single `Bibliography` Heading1. Book titles italic in both footnotes and bibliography.
- Chicago also has an Author-Date variant used in the sciences — if the venue specifies Chicago Author-Date, fall back to the APA recipe and change only the punctuation (no comma between author and year: `(Smith 2024)`).
```bash
# Body paragraph that will anchor a footnote, then the footnote itself
officecli add "$FILE" /body --type paragraph --prop text="The Ming dynasty's 海禁 policy shaped coastal trade for two centuries." --prop size=12pt --prop lineSpacing=1.5x --prop firstLineIndent=720
officecli add "$FILE" "/body/p[last()]" --type footnote --prop text="Timothy Brook, The Troubled Empire: China in the Yuan and Ming Dynasties (Cambridge, MA: Harvard University Press, 2010), 142."
# Next footnote — shortened form
officecli add "$FILE" "/body/p[last()]" --type footnote --prop text="Brook, Troubled Empire, 150."
# Bibliography section split — primary sources first
officecli add "$FILE" /body --type paragraph --prop text="Bibliography" --prop style=Heading1 --prop size=20pt --prop bold=true --prop spaceBefore=18pt
officecli add "$FILE" /body --type paragraph --prop text="Primary Sources" --prop style=Heading2 --prop size=14pt --prop bold=true --prop spaceBefore=12pt
officecli add "$FILE" /body --type paragraph --prop text="Ming Shilu 明實錄. Taipei: Academia Sinica, 1966." --prop size=12pt --prop indent=720 --prop hangingIndent=720
officecli add "$FILE" /body --type paragraph --prop text="Secondary Sources" --prop style=Heading2 --prop size=14pt --prop bold=true --prop spaceBefore=12pt
officecli add "$FILE" /body --type paragraph --prop text="Brook, Timothy. The Troubled Empire: China in the Yuan and Ming Dynasties. Cambridge, MA: Harvard University Press, 2010." --prop size=12pt --prop indent=720 --prop hangingIndent=720
```
QA: `officecli query "$FILE" 'footnote'` count ≥ body-paragraph citation count.
### IEEE (engineering — transactions, conference proceedings)
- In-text: `[1]`, `[2]`. Numbered in **order of first appearance**, not alphabetical. Reuse the same number for repeat citations. `[1, p. 15]` for page refs, `[1]-[3]` for a range.
- Reference entry starts with the bracketed number: `[1] A. Smith and B. Jones, "Title," IEEE Trans. X, vol. 5, no. 3, pp. 1-10, 2024, doi: ...`. Authors are initial-first; journal names abbreviated per IEEE list (`IEEE Trans. Neural Netw.`, not full name).
- Body is **two-column** (see §Multi-column below). Abstract is single-column above the fold, 10pt, 1.15x line spacing, typically 200-250 words.
- First-line indent on body paragraphs = 0.2" (`firstLineIndent=288` twips ≈ 14pt). Smaller than APA's 0.5" because the 2-col width is narrower.
- **Section headings: ALL CAPS with Roman numerals** — `I. INTRODUCTION`, `II. RELATED WORK`, `III. METHOD`. Sub-sections `A. Datasets`, `B. Baselines` in title case. Do NOT use `1. Introduction` (Arabic) for IEEE — that is Chicago style.
- **Tables are numbered Roman**: `Table I`, `Table II`, `Table III`. Figures remain Arabic (`Fig. 1`, `Fig. 2`). `recalcFields=seq` writes Arabic cached values for both — for IEEE Roman tables, either patch the cached `<w:t>` to Roman manually after recalc, or accept Arabic and note it in the cover letter.
```bash
# Body citing reference 1
officecli add "$FILE" /body --type paragraph --prop text="Attention-based anomaly detection has been applied to industrial sensor data [1], [2]." --prop size=10pt --prop lineSpacing=1.15x
# Reference list entry — number in the text
officecli add "$FILE" /body --type paragraph --prop text="[1] A. Smith and B. Jones, \"Attention for anomaly detection,\" IEEE Trans. Neural Netw., vol. 35, no. 2, pp. 412-430, 2024." --prop size=10pt --prop indent=720 --prop hangingIndent=720
officecli add "$FILE" /body --type paragraph --prop text="[2] C. Lee, \"Time-series anomaly survey,\" in Proc. ICML, 2023, pp. 1200-1215." --prop size=10pt --prop indent=720 --prop hangingIndent=720
```
QA: the highest `[N]` in body must equal the number of reference-list entries. Grep: `officecli view "$FILE" text | grep -oE '\[[0-9]+\]' | sort -u | tail -5`.
### MLA 9 (literature, languages, cultural studies)
Diff vs APA: in-text is `(Author Page)` **no comma** (e.g. `(Smith 412)`); direct quotes always carry the page number. Reference section titled **Works Cited** (not References / Bibliography). Entries alphabetical by surname, hanging indent, 2x spacing, nine "core elements" separated by periods: `Author. Title. Container, Other Contributors, Version, Number, Publisher, Date, Location.` — skip any that don't apply. Book titles italic; article titles in quotes. Otherwise identical to APA paragraph setup.
## Equations (OMML — inline vs display)
`--type equation` parses a LaTeX-ish formula into OMML. Two modes, selected by `--prop mode=`:
| Mode | XML | Visual | Use |
|---|---|---|---|
| `display` (default) | `<m:oMathPara>` at `/body` | Standalone centered block | Numbered equations, theorem statements |
| `inline` | `<m:oMath>` appended to a run inside a paragraph | Runs with the text | `if $x > 0$` style in prose |
```bash
# Display equation (own paragraph, centered) — explicitly set mode=display for clarity
officecli add "$FILE" /body --type equation --prop mode=display --prop formula="x^2 + y^2 = z^2"
# Display equation with Greek / subscript / integral — verify rendering below
officecli add "$FILE" /body --type equation --prop mode=display --prop formula="\\lambda_1 + \\alpha"
officecli add "$FILE" /body --type equation --prop mode=display --prop formula="\\frac{1}{2\\pi} \\int_0^{\\infty} e^{-x^2} dx"
# Inline equation INSIDE prose — required whenever variables like x_{t+1}, \lambda, etc. appear in a body paragraph:
officecli add "$FILE" /body --type paragraph --prop text="Given the weight " --prop size=11pt
officecli add "$FILE" "/body/p[last()]" --type equation --prop mode=inline --prop formula="W_t"
officecli add "$FILE" "/body/p[last()]" --type run --prop text=" we define the loss..."
```
**Verify equations render as OMML math**, not plain-text LaTeX tokens. After `close`, run:
```bash
officecli view "$FILE" text | head -20 # λ₁ + α, ∫₀∞, x² must appear as unicode math (verified renders)
officecli raw "$FILE" /document | grep -c '<m:oMathPara' # ≥ 1 per display equation
```
If the body prose contains raw `lambda_1`, `x_{t+1}`, `\alpha` or similar plain-text tokens (i.e., you typed them into a `paragraph --prop text=` instead of wrapping with `--type equation --prop mode=inline`), downstream viewers will render them as literal ASCII. **Rule: every mathematical variable / Greek letter / subscript in prose goes through `--type equation mode=inline`, never through `paragraph --prop text=`.**
**LaTeX subset pitfalls** (non-negotiable):
1. `\left(...\right)` / `\left[...\right]` with a sub/superscript **inside** the delimiters → parse error (`Error: cast object … Subscript`). An OUTER script (`\left(x+y\right)^2`) is fine; plain `(`, `)`, `[`, `]` always work and OMML auto-sizes them in display mode.
2. `move` on `/body/oMathPara[N]` reorders the display equation (it repositions the wrapping paragraph). `--before <path>` may leave a stray empty paragraph; prefer `--index` or `--after` for a clean reorder.
**Equation numbering** — no native `\eqno`. The journal-standard layout is **one line**: equation centered, number flush-right at the column edge (`Y = A(X) ⊗ X (1)`). Build it with two paragraph **tab stops** — a `center` tab at the column mid-point and a `right` tab at the column right edge — then lay out `[tab] equation(inline) [tab] (1)` in a single paragraph. Do NOT use a centered display equation followed by a separate right-aligned `(1)` line — that splits the number onto its own line and is the most common reason agents fail to reproduce the expected look.
```bash
# Tab positions depend on the COLUMN width (twips). Default blank doc = A4, 3.18cm margins
# → text width = 8300 twips.
# single column: center tab = 4150, right tab = 8300
# two columns (default 720-twip gutter): col = (8300-720)/2 = 3790 → center 1895, right 3790
# (other page size / margins: text width = pageWidth - marginLeft - marginRight; recompute.)
officecli add "$FILE" /body --type paragraph # the equation paragraph (say it lands at p[N])
officecli add "$FILE" "/body/p[N]" --type tab --prop pos=4150 --prop val=center
officecli add "$FILE" "/body/p[N]" --type tab --prop pos=8300 --prop val=right
officecli add "$FILE" "/body/p[N]" --type run --prop text=$'\t' # tab → jump to center
officecli add "$FILE" "/body/p[N]" --type equation --prop mode=inline --prop formula='Y = A(X) \otimes X'
officecli add "$FILE" "/body/p[N]" --type run --prop text=$'\t(1)' # tab → jump to right edge, then the number
```
For a two-column section just use the two-column tab positions (1895 / 3790); the same paragraph then centers the equation within its column with `(1)` at the column's right edge. Schema: `officecli help docx tab`.
**Do NOT place `--type equation` directly on a table cell `tc[N]` path** — it is rejected with a guard error (`table cells only accept paragraphs, tables, or SDTs`), so no bad XML is written. Target `tc[N]/p[1]` with `mode=inline` if you need equations in cells.
Full equation schema: `officecli help docx equation`.
## Figures, tables, and cross-references (SEQ + PAGEREF)
Two primitives, both **native fieldTypes** (`officecli help docx field` for the enum): `seq` for auto-numbered caption counters, `pageref` for "see Fig. 2 on page 7" back-references. Native fields insert with an unevaluated cached result; a single `set "$FILE" / --prop recalcFields=seq` (see §SEQ numbering below) fills the real numbers in document order — no per-field patching.
### SEQ auto-numbering — figures and tables
A SEQ field is a counter with a name (`identifier`). Every `SEQ Figure` increments the Figure counter on **recalc**; every `SEQ Table` increments the Table counter.
**SEQ cached values — one command, after all captions are added.** A freshly-added SEQ field has no evaluated cached number; `view text` shows the `#OCLI_NOTEVAL!{SEQ Figure}` sentinel (and `Format["evaluated"]=false`) until you recalc. **Do NOT patch each field by hand.** Once every figure/table caption is in place, run once:
```bash
officecli set "$FILE" / --prop recalcFields=seq
```
It counts `SEQ Figure` / `SEQ Table` fields in body document order and writes the real cached values (`Figure 1 / Figure 2 / Figure 3`), flipping `evaluated` true. Re-run it after inserting a caption mid-document so the numbers stay in sync. (Heading-relative `\s` and SEQ inside headers/footers defer to Word's own recompute — see `help docx document`.) Verify: `officecli view "$FILE" text` shows distinct ascending numbers.
```bash
# Figure with caption BELOW the image. Caption = "Figure <seq>: title" + optional bookmark for cross-ref.
officecli add "$FILE" /body --type picture --prop src=arch.png --prop width=5in
officecli set "$FILE" "/body/p[last()]/r[last()]" --prop alt="Model architecture: attention over time-series sensors"
# Caption paragraph (below the figure, per academic convention)
officecli add "$FILE" /body --type paragraph --prop text="Figure " --prop style=Caption --prop size=10pt --prop italic=true --prop align=center
officecli add "$FILE" "/body/p[last()]" --type field --prop fieldType=seq --prop identifier=Figure
officecli add "$FILE" "/body/p[last()]" --type run --prop text=": Attention-based anomaly detection model."
# Bookmark the caption so other paragraphs can PAGEREF it
officecli add "$FILE" /body --type bookmark --prop name=fig_arch
# (Numbers are filled later by a single `set / --prop recalcFields=seq`, after all captions exist.)
```
### PAGEREF — cross-reference by bookmark
```bash
# Cross-ref paragraph: "see Figure 1 on page X"
officecli add "$FILE" /body --type paragraph --prop text="As shown in Figure 1 (see page " --prop size=11pt --prop lineSpacing=1.5x
officecli add "$FILE" "/body/p[last()]" --type field --prop fieldType=pageref --prop name=fig_arch
officecli add "$FILE" "/body/p[last()]" --type run --prop text=")."
```
### Tables — caption ABOVE
```bash
# Caption first (ABOVE the table), THEN the table
officecli add "$FILE" /body --type paragraph --prop text="Table " --prop style=Caption --prop size=10pt --prop italic=true --prop spaceAfter=6pt
officecli add "$FILE" "/body/p[last()]" --type field --prop fieldType=seq --prop identifier=Table
officecli add "$FILE" "/body/p[last()]" --type run --prop text=": Participant demographics (N=47)."
officecli add "$FILE" /body --type table --prop rows=5 --prop cols=4 --prop width=100%
# ... fill header + rows per docx v2 §Tables
```
### Verify SEQ + PAGEREF fields landed
```bash
# At least one SEQ Figure or SEQ Table in the body document part
officecli raw "$FILE" /document | grep -c 'w:instrText[^>]*>[^<]*SEQ' # expect ≥ 1
officecli raw "$FILE" /document | grep -c 'w:instrText[^>]*>[^<]*PAGEREF' # 0 ok if no cross-refs
```
Live fields carry **cached values** that render stale until a human presses F9 in Word. Expect "Figure 1" to show as `1`, `2`, ... immediately after recalc; before recalc, some viewers render `0` or blank. Judge field presence by `fldChar` existence, not by visible digit (→ see docx v2 §Field / cached-value spot-check).
## Footnotes vs endnotes
**Footnote** — sits at the bottom of the page where its anchor paragraph lives. Used for source citations in Chicago Notes-Bib, content asides in any style.
**Endnote** — sits at the end of the document (or before the bibliography). Used by some venues in place of footnotes, or for long contextual notes that would clutter the page.
```bash
# Footnote anchored to paragraph N
officecli add "$FILE" "/body/p[3]" --type footnote --prop text="Smith et al. reported similar findings in their 2023 review."
# Endnote — anchored to paragraph N (like footnote); lands at /endnote[@endnoteId=N]
officecli add "$FILE" "/body/p[3]" --type endnote --prop text="Extended derivation of equation (4) is available at the project repository."
```
Both appear as empty-string runs in `view annotated` output (`r[N] ""`) — the run carries a `<w:footnoteReference>` XML element, not visible text. Confirm insertion with `officecli query "$FILE" 'footnote'` or `officecli get "$FILE" "/footnotes/footnote[N]"`. Footnotes do NOT shift paragraph indices; add them in any order after body content is in place. Full schema: `officecli help docx footnote` / `officecli help docx endnote`.
## Bibliography section
Every academic paper ends with a reference list. The name of the section depends on the style (**References** for APA / IEEE / Chicago Author-Date; **Bibliography** for Chicago Notes-Bib; **Works Cited** for MLA). Each entry is a separate paragraph with **hanging indent**.
```bash
# Section heading — same as body Heading1 (excluded from body numbering by convention)
officecli add "$FILE" /body --type paragraph --prop text="References" --prop style=Heading1 --prop size=20pt --prop bold=true --prop spaceBefore=18pt --prop spaceAfter=12pt
# Each entry: hanging indent 720 twips (0.5"), with indent=720 as the partner (first line flush, wraps indented)
officecli add "$FILE" /body --type paragraph --prop text="Smith, J. (2024). Remote work and cohesion. Journal of Applied Psychology, 109(3), 412-430." --prop size=12pt --prop lineSpacing=2x --prop indent=720 --prop hangingIndent=720
# DOI hyperlink on its own run appended to the entry paragraph
officecli add "$FILE" "/body/p[last()]" --type hyperlink --prop url="https://doi.org/10.1037/apl0001123" --prop text="https://doi.org/10.1037/apl0001123"
```
Verified: `--prop indent=720 --prop hangingIndent=720` is the canonical hanging-indent pair per `officecli help docx paragraph`. The old `ind.firstLine=-720` form (negative first-line indent) is NOT canonical and fails schema on emit — → see docx v2 §Schema-invalid-on-emit.
**Round-trip QA.** Count in-text citation markers (APA `(Author, Year)`, IEEE `[N]`, MLA `(Author N)`) vs reference-list entries. See Delivery Gate 4 below. Every cited key must resolve; every listed entry should be cited at least once.
## Multi-column (IEEE journal two-column recipe)
IEEE and many engineering / physics journals render body text in two columns with a single-column abstract above. The mechanism: a section break with `type=continuous` and `columns=2`, then another section break at the end to **revert** to single-column.
**The reversion step is not optional.** Without it, the rest of the document — including references — renders as two columns. This is the single most common multi-column failure.
```bash
FILE="ieee.docx"
officecli create "$FILE"
officecli open "$FILE"
# 1. Title, authors, affiliation — single-column (the default first section)
officecli add "$FILE" /body --type paragraph --prop text="Attention-Based Anomaly Detection for Industrial Time Series" --prop align=center --prop size=18pt --prop bold=true --prop spaceAfter=12pt
officecli add "$FILE" /body --type paragraph --prop text="Alice Chen, Bob Martinez" --prop align=center --prop size=11pt
officecli add "$FILE" /body --type paragraph --prop text="Department of CS, Stanford University" --prop align=center --prop size=10pt --prop spaceAfter=18pt
# 2. Abstract — still single-column, block-style
officecli add "$FILE" /body --type paragraph --prop text="Abstract" --prop align=center --prop size=12pt --prop bold=true --prop spaceAfter=6pt
officecli add "$FILE" /body --type paragraph --prop text="We present an attention-based model for detecting anomalies in industrial sensor time series..." --prop size=10pt --prop lineSpacing=1.15x --prop spaceAfter=12pt
# 3. Section break + two-column from here on
# `/section[last()]` resolves to the final section (like p[last()]); an explicit /section[N] also works.
officecli add "$FILE" /body --type section --prop type=continuous
SECTION_COUNT=$(officecli query "$FILE" section --json | jq '.data.results | length')
# After the add, SECTION_COUNT should be 2 — [1] is pre-break, [2] is post-break (2-col body area).
officecli set "$FILE" "/section[2]" --prop columns=2 --prop columnSpace=1cm
# 4. Body — IEEE wants Roman numerals + ALL CAPS section titles (P1.2).
officecli add "$FILE" /body --type paragraph --prop text="I. INTRODUCTION" --prop style=Heading1 --prop size=10pt --prop bold=true
officecli add "$FILE" /body --type paragraph --prop text="Industrial anomaly detection has been studied since [1]..." --prop size=10pt --prop lineSpacing=1.15x --prop firstLineIndent=360
# 5. At the end of 2-column body, ANOTHER section break + revert to single column for references / appendices
# (If you want references in 2-col too, skip step 5 — but most IEEE papers use 2-col for references as well.)
# officecli add "$FILE" /body --type section --prop type=continuous
# Use /section[last()] for the final section, or re-count for an explicit /section[N]:
# officecli set "$FILE" "/section[3]" --prop columns=1
# 6. Footer, close, validate
officecli add "$FILE" / --type footer --prop type=default --prop align=center --prop size=9pt --prop field=page
officecli close "$FILE"
officecli validate "$FILE"
```
**Visual verify.** Run `officecli view "$FILE" html` and Read the returned HTML to audit the rendered output. The abstract must render as full-width and the introduction onward as two columns. If the abstract wraps into two narrow columns, the first section break landed before the abstract — move it.
**Section index bookkeeping.** Each `add /body --type section` inserts one empty paragraph into `/body` (the section-break marker). All subsequent `p[N]` indices shift by +1 per section break. Plan section breaks in advance; after adding a break, `officecli get "$FILE" /body --depth 1` to re-index before continuing.
Full section schema (`columns`, `columnSpace`, `orientation`, `pageNumFmt`, `titlePage`, `lineNumbers`): `officecli help docx section`.
## Abstract / keywords / affiliation block
First-page metadata stack: title (centered 20-22pt bold) → authors (centered 12pt, superscript `^1 ^2` for multi-affiliation) → affiliations (centered 11pt, keyed to superscripts) → submission target / date → **Abstract** heading (14pt bold) → abstract body (block-style, **NO `firstLineIndent`**, 150-300 words) → keywords line (italic 11pt). Same "cover ≥ 60% filled" rule as docx v2.
```bash
# Superscript affiliation markers (multi-institution paper)
officecli add "$FILE" /body --type paragraph --prop text="Alice Chen" --prop align=center --prop size=12pt
officecli add "$FILE" "/body/p[last()]" --type run --prop text="1" --prop superscript=true
officecli add "$FILE" "/body/p[last()]" --type run --prop text=", Bob Martinez"
officecli add "$FILE" "/body/p[last()]" --type run --prop text="2" --prop superscript=true
# Running header (skip on cover via type=first empty header — see docx v2 §headers)
officecli add "$FILE" / --type header --prop type=default --prop align=right --prop size=9pt --prop text="Short Running Title"
```
**Nature-family 2-col abstract** is rare — if required, open a `section type=continuous columns=2` BEFORE the abstract heading; short abstracts (<100 words) leave ragged columns. **Mirrored odd/even headers** are exposed by the high-level API: `officecli set "$FILE" /settings --prop evenAndOddHeaders=true`, then add the even header with `--type header --prop type=even`. Full header schema: `officecli help docx header`.
## QA — Delivery Gate (executable)
**Assume there are problems. Your job is to find them.** First render is almost never correct. Run this block before declaring done.
### Gates 1-3 — inherited from docx v2
→ see docx v2 §Delivery Gate. Schema validate, token leak grep, live PAGE field structure. Copy-paste the docx v2 gate block first. Every check must print its success message.
### Gate 4 — citation round-trip
Every in-text citation key should resolve to a bibliography entry. Count mismatches = REJECT.
```bash
# IEEE example (bracketed numerics). Adjust regex for APA (Author, Year) or MLA (Author Page).
CITATIONS=$(officecli view "$FILE" text | grep -oE '\[[0-9]+\]' | sort -u | wc -l)
ENTRIES=$(officecli query "$FILE" 'paragraph[hangingIndent]' --json | jq '.data.results | length')
echo "In-text citation markers: $CITATIONS | Bibliography entries: $ENTRIES"
# REJECT when citations exceed entries (cites without references). Entries > citations is allowed by some venues.
[ "$CITATIONS" -le "$ENTRIES" ] && echo "Gate 4 OK" || { echo "REJECT Gate 4: $CITATIONS in-text markers but only $ENTRIES bibliography entries"; exit 1; }
```
### Gate 5a — SEQ presence + cached numbers distinct
If the paper has any numbered figure or table, the body must carry live `SEQ` fields AND their cached values must show distinct ascending numbers (else `view text` and downstream viewers that don't recompute cached fields will show "Figure 1" for all).
```bash
# Count SEQ fields via query (raw-grep collapses multi-matches on one XML line → undercounts).
SEQ_COUNT=$(officecli query "$FILE" 'field[fieldType=seq]' --json | jq '.data.results | length')
VISIBLE_FIG=$(officecli view "$FILE" text | grep -cE '(Figure|Table) [0-9]+')
if [ "$VISIBLE_FIG" -gt 0 ] && [ "$SEQ_COUNT" -eq 0 ]; then
echo "REJECT Gate 5a: $VISIBLE_FIG visible Figure/Table labels but 0 SEQ fields."
exit 1
fi
# Cached values must be distinct. Run `set / --prop recalcFields=seq` once after all captions exist;
# before recalc the fields render the #OCLI_NOTEVAL! sentinel, after recalc Figure 1 / Figure 2 / Figure 3:
DISTINCT=$(officecli view "$FILE" text | grep -oE '(Figure|Table) [0-9]+' | sort -u | wc -l)
[ "$SEQ_COUNT" -le "$DISTINCT" ] && echo "Gate 5a OK (SEQ=$SEQ_COUNT, distinct=$DISTINCT)" || { echo "REJECT Gate 5a: $SEQ_COUNT SEQ fields but only $DISTINCT distinct rendered labels — run 'set \"$FILE\" / --prop recalcFields=seq'"; exit 1; }
```
### Gate 5b — Visual audit via HTML preview (MANDATORY, not optional)
Gates 1–5a catch schema, token leaks, live-field presence, citation counts. **They do NOT catch physical assembly defects** — scrambled page order, a duplicated Abstract mid-document, three figures all labeled "Fig. 1" despite SEQ field presence, equation variables rendering as plain-text LaTeX (`lambda_1`, `x_{t+1}`) instead of math. Do not skip — Gates 1–5a pass ≠ visual OK.
Run `officecli view "$FILE" html` and Read the returned HTML path. For every page of the paper, answer:
> (a) Are pages in logical academic sequence? (Title → Abstract → Keywords → Introduction → body → References — no forward jumps, no backward leaks.)
> (b) Does the Abstract appear exactly once, not duplicated mid-document?
> (c) Are Figure N / Table N labels distinct and ascending? (Fig. 1, Fig. 2, Fig. 3 — not all "Fig. 1". Same for tables.)
> (d) Do equations render as math? (Italicized variables, Greek letters like λ / α, proper integrals / fractions — NOT plain-text `lambda_1`, `x_{t+1}`, `\int`.)
> (e) For IEEE papers: are section titles ALL CAPS with Roman numerals (`I. INTRODUCTION`)? Are tables Roman (`Table I`, `Table II`)?
> (f) For APA papers: are Level-1 headings centered bold and unnumbered (not `1. Introduction`)?
> (g) Does every in-text "see Fig. N" / "see Table N" resolve to a figure/table that actually carries that number?
> (h) Heading hierarchy visually distinct (size + weight) across H1 / H2 / H3?
Report every instance. If even one defect is present → REJECT; do not deliver until fixed.
**Human preview (optional).** If you want the user to visually preview the paper, run `officecli watch "$FILE"` for a live preview the user can open at their own discretion, or have them open the `.docx` directly in Word / WPS / Pages. For final visual verification, open the file in the target viewer.
### Honest limit
`validate` catches schema errors, not academic-style errors. A document passes `validate` with APA citations in an IEEE paper, footnotes in a style that forbids them, or figures with hardcoded numbers that drift when a new figure is inserted. The gates above — especially Gate 4 (round-trip) and Gate 5 (SEQ presence) — are how you catch what validate cannot.
## Known Issues & Pitfalls (academic-specific)
→ Base pitfalls (shell escape, `\$ \t \n` literals, table cell formatting order, page-break boundaries, `shd.fill` / `ind.firstLine` schema-invalid forms, TOC cached values, watermark two-step): see docx v2 §Known Issues & Pitfalls.
Academic-specific:
- **`\left(...\right)` / `\left[...\right]` with a sub/superscript INSIDE the delimiters → parse error** (`cast object … Subscript`). An outer script (`\left(x+y\right)^2`) is fine. Use plain `(`, `)`, `[`, `]` — OMML auto-sizes in display mode.
- **`move` on `/body/oMathPara[N]` reorders the equation** (the wrapping paragraph moves). `--before <path>` may leave a stray empty paragraph; prefer `--index` / `--after`.
- **Section break +1 paragraph offset.** Each `add /body --type section` inserts one empty paragraph into `/body`. All `p[N]` indices after the break shift by +1. Plan breaks; after any `add section`, `officecli get "$FILE" /body --depth 1` to re-index.
- **`/section[last()]` resolves to the final section** (mirrors `p[last()]`), for both get and set. An explicit `/section[N]` also works:
```bash
SECTION_COUNT=$(officecli query "$FILE" section --json | jq '.data.results | length')
# use /section[last()] for the final section, or an explicit /section[2], /section[3], ...
```
Each `add /body --type section` increments the count. Re-query after every break.
- **Multi-column does NOT auto-revert.** After a `columns=2` section, you must add another section break and explicitly set `columns=1` on the new `/section[N]` (N = post-revert count) — otherwise the rest of the document, including references, renders as two columns. Verify with `officecli get "$FILE" "/section[N]"` for each N.
- **`--type equation` on a `tc[N]` cell path is rejected with a guard error** (`table cells only accept paragraphs, tables, or SDTs`) — no bad XML is written. Inside a table cell, target `tc[N]/p[1]` with `--prop mode=inline` instead.
- **SEQ caption numbers are filled by `set / --prop recalcFields=seq`** (run once after all captions exist), not by per-field raw-set patching. A pre-recalc SEQ field shows the `#OCLI_NOTEVAL!` sentinel in `view text`.
- **Hanging-indent canonical form is `indent=720 hangingIndent=720`.** Not `ind.firstLine=-720`. The dotted form emits `<w:ind>` after `<w:jc>` and fails schema on emit.
- **Footnote reference runs show as empty strings in `view annotated`.** The `<w:footnoteReference>` XML element has no visible text on the reference side; the note body lives in `/footnotes/footnote[N]`. Confirm with `officecli query "$FILE" 'footnote'`, not by eyeballing `view text`.
- **Caption placement:** Table caption ABOVE the table; Figure caption BELOW the figure. Every major style (APA, Chicago, IEEE, MLA) agrees. Putting a Table caption below the table is an academic-style error, not a rendering issue — `validate` will not catch it.
- **TOC cached rendering / shell-escape:** → see docx v2 §Table of Contents, §Shell escape.
## Renderer quirks (cross-viewer)
→ see docx v2 §Renderer quirks. PAGE / TOC cached values, OMML baseline shifts, scheme colors — all identical quirks apply to academic papers. Before calling an equation or a citation marker broken, open the file in the user's target viewer (Word, WPS, Pages) — if it renders correctly there, it is a viewer quirk, not a skill defect.
## Help pointer
When in doubt: `officecli help docx`, `officecli help docx <element>`, `officecli help docx <element> --json`. Help is the authoritative schema; this skill is the decision guide for academic deltas on top of docx v2.
+59 -44
View File
@@ -5,64 +5,79 @@ description: Einstiegs- und Orientierungshilfe für die Agenten-Workstation der
# AZ-Agent — Hilfe & Onboarding
Du bist der Guide für Anwender der AZ-Agenten-Workstation. Wer diesen Skill aufruft,
will orientiert werden — nicht mit Technik-Details überschüttet werden. Antworte auf
Deutsch, freundlich und in kurzen Schritten.
Du bist der Guide für Anwender der AZ-Agenten-Workstation. Wer diesen Skill
aufruft, will orientiert werden — nicht mit Technik-Details überschüttet
werden. Antworte freundlich, in kurzen Schritten und in der Sprache der
Anfrage.
> **Status: Entwurf.** Dieses Skill ist der erste Baustein des Company-Default-Sets
> und wird mit den kommenden Artefakten (Commands, Agenten, MCP-Anbindungen)
> mitwachsen. Solange ein Bereich noch leer ist, sage das ehrlich.
## Was kann mein Agent? — nur aufzählen, was wirklich da ist
## Erste Orientierung: Was ist hier installiert?
Die Ausstattung ist **nicht auf jedem Rechner gleich**: Sie richtet sich nach
Abteilung und Rolle des Nutzers. Zähle deshalb nur auf, was dir **in dieser
Sitzung tatsächlich zur Verfügung steht**:
Die Workstation erhält ihre Standard-Artefakte zentral aus dem Repository
`az-agent-defaults` — gespiegelt über das Fleet-Repo. Es gibt vier Arten:
1. **Spezialisierte Helfer** — die Subagents, die dir das Task-Tool anbietet.
2. **Fachwissen** — die Skills in deiner Skill-Liste.
3. **Anbindungen** — die Werkzeuge externer Dienste in deiner Tool-Liste
(MCP-Server; ihr Präfix vor dem `_` ist der Dienst, z. B. `websearch_…`).
4. **Kurzbefehle** — Commands wie `/az-hilfe`, die der Nutzer selbst tippt.
| Frage des Anwenders | Artefakt-Art | Wo es liegt |
|---|---|---|
| „Mach X, wenn Y" — Verhalten beibringen | Skill | `skills/` |
| Wiederkehrenden Prompt als Tastendruck (/slash) | Command | `commands/` |
| Eigenes Agenten-Profil / Prüf-Subagenten | Agent | `agents/` |
| Werkzeug anbinden (API, Datenquelle) | MCP-Server | `mcp/` |
Beschreibe alles in **Alltagssprache**: „Websuche“, „Basecamp-Projekte und
To-dos“, „Word-, Excel- und PowerPoint-Dateien bearbeiten“ — nicht
`websearch_web_search_exa` oder `officecli-docx`. Technische Namen nur, wenn
der Nutzer ausdrücklich danach fragt.
**Aktuell verfügbar:** dieser Hilfe-Skill selbst. Commands, Agenten-Definitionen
und MCP-Anbindungen folgen (in Vorbereitung). Versprich nichts, was nicht
ausgeliefert ist.
Nenne **nie** Fähigkeiten, die nicht in deinen Listen stehen — auch nicht,
wenn du sie aus Beispielen oder von anderen Rechnern kennst.
## Was ist was? — die vier Artefakt-Arten
| Frage des Anwenders | Artefakt-Art |
|---|---|
| „Der Agent soll immer X tun, wenn Y“ — Verhalten beibringen | Skill |
| Wiederkehrender Prompt als Kurzbefehl (`/name`) | Command |
| Spezialisierter Helfer für ein Fachgebiet | Agent (Subagent) |
| Zugriff auf ein Werkzeug oder System (API, Datenquelle) | MCP-Anbindung |
## Typische Anfragen und gute Antworten
- **„Was kann mein Agent überhaupt?"** → Nenne die vier Artefakt-Arten oben und
was davon heute live ist. Beispiel geben: dieser Skill hier ist eins.
- **„Ich will, dass der Agent immer X tut, wenn Y."** → Das ist ein **Skill**.
Erkläre: Verhaltens-Anweisungen werden zentral gepflegt (Beitragshinweise
unten), nicht lokal auf der Workstation gebastelt.
- **„Ich tippe jeden Tag dasselbe …"** → Kandidat für einen **Command** — noch in
Vorbereitung; Wunsch aufnehmen und an die IT weiterreichen.
- **„Kann der Agent auch auf Tool Z zugreifen?"** → Das ist eine **MCP-Anbindung**
— sicherheitsrelevant, läuft über die IT (keine lokalen Einträge).
- **„Mein Kollege hat einen Skill, ich nicht."** → Auslieferung erfolgt zentral im
Fleet-Rollout: App neu starten; bleibt der Skill weg, IT kontaktieren.
- **„Was kann mein Agent überhaupt?“** → Liste nach dem Abschnitt oben, kurz
und in Alltagssprache, mit je einem Beispielsatz, den der Nutzer sagen
kann.
- **„Mein Kollege kann X, ich nicht.“** → Ausstattung hängt von Abteilung
und Rolle ab. Braucht der Nutzer X für seine Arbeit, wendet er sich an die
IT — dort wird die Zuordnung gepflegt.
- **„Ich will, dass der Agent immer X tut, wenn Y.“** → Das ist ein
**Skill**. Wunsch mit Beispiel aufnehmen und an die IT bzw. den
KI-Ansprechpartner der Abteilung weitergeben.
- **„Ich tippe jeden Tag dasselbe …“** → Kandidat für einen **Command**;
Wunsch genauso weitergeben.
- **„Kann der Agent auch auf Tool Z zugreifen?“** → Das wäre eine
**MCP-Anbindung** — sicherheitsrelevant, wird nur von der IT eingerichtet.
## Selbst beitragen
Änderungen laufen **zentral über die IT** im Repository `az-agent-defaults`:
Neue oder geänderte Skills, Commands, Agenten und Anbindungen laufen
**zentral** über das Repository `az-agent-defaults` der IT:
1. Wohin gehört der Beitrag? → Tabelle oben („Wohin gehört mein Beitrag?").
2. Das Repo-README beschreibt je Artefakt-Typ verbindliche Guard-Regeln
(Struktur, Frontmatter, Pflichtfelder) — dort steht auch je ein Minimalbeispiel.
3. Beitrag als Commit/PR einreichen; die IT prüft und rollt aus. Erst nach
Rollout und App-Neustart ist das Artefakt auf den Workstationen.
1. Die README des Repos sagt, wohin ein Beitrag gehört und welche Regeln er
erfüllen muss — mit je einem Minimalbeispiel.
2. Beitrag einreichen; die IT prüft ihn.
3. Nach der Freigabe kommt er automatisch auf die Rechner (Abgleich alle
paar Stunden und bei der Anmeldung) — bei Inhalten für bestimmte
Abteilungen nur dort.
Anwender sollten **nie** lokal in `~\.agents\skills` (oder vergleichbare
Spiegel-Verzeichnisse) editieren — lokale Änderungen werden vom nächsten
Rollout überschrieben.
**Lokale Änderungen** an ausgelieferten Skills oder Agenten bleiben
erhalten, blockieren aber künftige Updates dieses Artefakts — Windows meldet
das mit einem Hinweis. Wer dauerhaft etwas anders braucht, reicht es zentral
ein, statt lokal zu basteln.
## Bei Problemen
- Artefakt fehlt / verhält sich falsch → IT kontaktieren, mit Name des
Artefakts und kurzem Ablauf des Problems.
- Nichts funktionstüchtig ändern: Diagnose ja, lokale Reparatur nein —
sie überlebt den nächsten Rollout nicht.
- Fähigkeit fehlt oder verhält sich falsch → IT kontaktieren, mit Name der
Fähigkeit (in Alltagssprache reicht) und kurzem Ablauf des Problems.
- Hinweis „lokale Änderungen blockieren Updates“ → IT kontaktieren; sie
setzt das Artefakt auf den zentralen Stand zurück.
Führe darüber hinaus keine Aktionen aus. Dieser Skill orientiert — er verändert
nichts.
Führe darüber hinaus keine Aktionen aus. Dieser Skill orientiert — er
verändert nichts.