docs: rename OACP to Harness Protocol and revamp protocol.org with verbose literate text

This commit is contained in:
2026-04-12 18:54:00 -04:00
parent 5c7a925e4d
commit 117f3143d3
16 changed files with 111 additions and 82 deletions

View File

@@ -20,7 +20,7 @@ The *Chaos Gauntlet* is an adversarial testing skill designed to ensure the syst
Verify the system's stability and error-handling capabilities under stress.
** 2. User Needs
- *Failure Simulation:* Ability to inject artificial delays or errors into the OACP bus.
- *Failure Simulation:* Ability to inject artificial delays or errors into the Harness Protocol bus.
- *Byzantine Response Testing:* Test how System 2 handles nonsensical or malicious System 1 proposals.
- *Network Resilience:* Simulate Gitea or LLM provider timeouts.
- *Recovery Verification:* Ensure the harness can recover from a "skip-event" restart.

View File

@@ -1,13 +1,13 @@
:PROPERTIES:
:ID: org-skill-oacp-validator
:ID: org-skill-harness-protocol-validator
:CREATED: [2026-04-12 Sun 14:35]
:END:
#+TITLE: SKILL: OACP Schema Validator (Universal Literate Note)
#+TITLE: SKILL: Harness Protocol Schema Validator (Universal Literate Note)
#+STARTUP: content
#+FILETAGS: :protocol:oacp:security:validation:psf:
#+FILETAGS: :protocol:harness-protocol:security:validation:psf:
* Overview
The *OACP Schema Validator* skill provides deep structural validation for all messages entering the org-agent kernel. It ensures that every property list adheres to a strict schema, preventing malformed data from causing harness-level errors.
The *Harness Protocol Schema Validator* skill provides deep structural validation for all messages entering the org-agent kernel. It ensures that every property list adheres to a strict schema, preventing malformed data from causing harness-level errors.
* Phase A: Demand (PRD)
:PROPERTIES:
@@ -15,7 +15,7 @@ The *OACP Schema Validator* skill provides deep structural validation for all me
:END:
** 1. Purpose
Enforce a formal grammar for the Org-Agent Control Protocol (OACP).
Enforce a formal grammar for the Org-Agent Control Protocol (Harness Protocol).
** 2. User Needs
- *Type Safety:* Ensure mandatory keys (e.g., `:type`, `:payload`) are present.
@@ -38,7 +38,7 @@ Decouple protocol parsing (framing/unframing) from semantic validation.
** 2. Semantic Interfaces
#+begin_src lisp
(defun validate-oacp-schema (msg)
(defun validate-harness-protocol-schema (msg)
"Returns T if the message is valid, NIL (and signals error) otherwise.")
#+end_src
@@ -48,44 +48,44 @@ Decouple protocol parsing (framing/unframing) from semantic validation.
#+begin_src lisp :tangle ../src/protocol-validator.lisp
(in-package :org-agent)
(defun validate-oacp-schema (msg)
"Strict structural validation for incoming OACP messages."
(defun validate-harness-protocol-schema (msg)
"Strict structural validation for incoming Harness Protocol messages."
(unless (listp msg)
(error "OACP Schema Error: Message must be a property list (got ~s)" (type-of msg)))
(error "Harness Protocol Schema Error: Message must be a property list (got ~s)" (type-of msg)))
(let ((type (getf msg :type)))
(unless (member type '(:REQUEST :EVENT :RESPONSE :LOG))
(error "OACP Schema Error: Invalid message type '~a'" type))
(error "Harness Protocol Schema Error: Invalid message type '~a'" type))
(case type
(:REQUEST
(unless (getf msg :target)
(error "OACP Schema Error: REQUEST missing mandatory :target"))
(error "Harness Protocol Schema Error: REQUEST missing mandatory :target"))
(unless (getf msg :payload)
(error "OACP Schema Error: REQUEST missing mandatory :payload")))
(error "Harness Protocol Schema Error: REQUEST missing mandatory :payload")))
(:EVENT
(let ((payload (getf msg :payload)))
(unless (and payload (listp payload))
(error "OACP Schema Error: EVENT missing or invalid :payload"))
(error "Harness Protocol Schema Error: EVENT missing or invalid :payload"))
(unless (or (getf payload :action) (getf payload :sensor))
(error "OACP Schema Error: EVENT payload must contain :action or :sensor"))))
(error "Harness Protocol Schema Error: EVENT payload must contain :action or :sensor"))))
(:RESPONSE
(unless (getf msg :payload)
(error "OACP Schema Error: RESPONSE missing mandatory :payload"))))
(error "Harness Protocol Schema Error: RESPONSE missing mandatory :payload"))))
t))
#+end_src
* Registration
#+begin_src lisp :tangle ../src/protocol-validator.lisp
(defskill :skill-oacp-validator
(defskill :skill-harness-protocol-validator
:priority 95
:trigger (lambda (ctx) (member (getf (getf ctx :payload) :sensor) '(:protocol-received)))
:neuro nil
:symbolic (lambda (action ctx)
(declare (ignore ctx))
(validate-oacp-schema action)
(validate-harness-protocol-schema action)
action))
#+end_src

View File

@@ -54,7 +54,7 @@ Define the core functional and security requirements for the neurosymbolic harne
** 3. Success Criteria
*** TODO Harness Lisp stability (Heartbeat consistency)
*** TODO OACP communication reliability
*** TODO Harness Protocol communication reliability
*** TODO Org AST-to-Lisp conversion fidelity
*** TODO Deliberate Safety Gating (The Harness) enforcement
@@ -64,7 +64,7 @@ Define the core functional and security requirements for the neurosymbolic harne
:END:
** 1. Architectural Intent
The harness is transport-agnostic and business-logic-agnostic. It communicates with external actuators (Emacs, Web, Signal) via the Org-Agent Communication Protocol (OACP).
The harness is transport-agnostic and business-logic-agnostic. It communicates with external actuators (Emacs, Web, Signal) via the Org-Agent Communication Protocol (Harness Protocol).
** 2. Semantic Interfaces
#+begin_src lisp