REFAC: Shift terminology to Autonomy and harden CLI via socat
This commit is contained in:
@@ -5,10 +5,10 @@
|
||||
:END:
|
||||
#+TITLE: SKILL: Deterministic Engine Bouncer (Authorization Gate)
|
||||
#+STARTUP: content
|
||||
#+FILETAGS: :system:bouncer:authorization:psf:
|
||||
#+FILETAGS: :system:bouncer:authorization:autonomy:
|
||||
|
||||
* Overview
|
||||
The *Deterministic Engine Bouncer* is the authorization gate for high-risk actions. It serializes intercepted actions into Org nodes ("Flight Plans") and re-injects them once manually approved by the Sovereign.
|
||||
The *Deterministic Engine Bouncer* is the authorization gate for high-risk actions. It serializes intercepted actions into Org nodes ("Flight Plans") and re-injects them once manually approved by the Autonomous.
|
||||
|
||||
* Package Context
|
||||
#+begin_src lisp
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
:END:
|
||||
#+TITLE: SKILL: Chat Agent (Universal Literate Note)
|
||||
#+STARTUP: content
|
||||
#+FILETAGS: :chat:conversational:ui:psf:
|
||||
#+FILETAGS: :chat:conversational:ui:autonomy:
|
||||
|
||||
* Overview
|
||||
The *Chat Agent* provides a dedicated conversational interface within Emacs (`*org-agent-chat*`). It enables fluid dialogue while maintaining strict persona alignment and contextual awareness.
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
:END:
|
||||
#+TITLE: SKILL: CLI Gateway (Universal Literate Note)
|
||||
#+STARTUP: content
|
||||
#+FILETAGS: :gateway:cli:io:psf:
|
||||
#+FILETAGS: :gateway:cli:io:autonomy:
|
||||
|
||||
* Overview
|
||||
The *CLI Gateway* is the primary interaction point for the Org-Agent MVP. It provides a lightweight TCP socket server that allows local terminal clients to communicate with the daemon. It ensures a frictionless "First Contact" experience immediately following installation.
|
||||
@@ -58,11 +58,13 @@ The CLI actuator writes the agent's response back to the client's network stream
|
||||
(let* ((payload (getf action :payload))
|
||||
(text (or (getf payload :text) (getf action :text)))
|
||||
(stream (getf context :reply-stream)))
|
||||
(if (and stream (open-stream-p stream))
|
||||
(progn
|
||||
(format stream "Agent: ~a~%" text)
|
||||
(finish-output stream))
|
||||
(harness-log "CLI ERROR: No active reply stream for signal."))))
|
||||
(handler-case
|
||||
(if (and stream (open-stream-p stream))
|
||||
(progn
|
||||
(format stream "Agent: ~a~%" text)
|
||||
(finish-output stream))
|
||||
(harness-log "CLI ERROR: No active or open reply stream for signal."))
|
||||
(error (c) (harness-log "CLI ACTUATOR ERROR: ~a" c)))))
|
||||
#+end_src
|
||||
|
||||
** Server: Client Handler
|
||||
@@ -71,6 +73,11 @@ Handles an individual TCP connection. It reads lines until the connection is clo
|
||||
#+begin_src lisp
|
||||
(defun handle-cli-client (stream)
|
||||
"Reads lines from a CLI client and injects them as stimuli."
|
||||
(harness-log "CLI: Client connected.")
|
||||
(format stream "--------------------------------------------------~%")
|
||||
(format stream " Connected to the Autonomous Brain (v0.1.0)~%")
|
||||
(format stream "--------------------------------------------------~%")
|
||||
(finish-output stream)
|
||||
(handler-case
|
||||
(loop for line = (read-line stream nil nil)
|
||||
while line do
|
||||
@@ -82,7 +89,8 @@ Handles an individual TCP connection. It reads lines until the connection is clo
|
||||
:channel :cli
|
||||
:text trimmed))
|
||||
:stream stream))))
|
||||
(error (c) (harness-log "CLI CLIENT ERROR: ~a" c))))
|
||||
(error (c) (harness-log "CLI CLIENT DISCONNECT: ~a" c)))
|
||||
(harness-log "CLI: Client disconnected."))
|
||||
#+end_src
|
||||
|
||||
** Server: Main Loop
|
||||
@@ -129,20 +137,23 @@ We tangle a lightweight client script that the user can run on their host machin
|
||||
|
||||
** The Bash Client
|
||||
#+begin_src bash :tangle ../scripts/org-agent-chat.sh :shebang "#!/bin/bash"
|
||||
# org-agent-chat: The terminal mouthpiece for the Sovereign Brain.
|
||||
# org-agent-chat: The terminal mouthpiece for the Autonomous Brain.
|
||||
PORT=9105
|
||||
HOST=${1:-localhost}
|
||||
|
||||
echo "Connecting to org-agent at $HOST:$PORT..."
|
||||
echo "Type your message and press Enter. Ctrl+C to exit."
|
||||
echo "--------------------------------------------------"
|
||||
|
||||
# Uses netcat (nc) for a simple bidirectional pipe.
|
||||
# Requires an open connection. We use a simple loop for persistence.
|
||||
while true; do
|
||||
read -p "User: " MESSAGE
|
||||
if [ -z "$MESSAGE" ]; then continue; fi
|
||||
# Send message and wait for one line of response from Agent
|
||||
echo "$MESSAGE" | nc -N $HOST $PORT
|
||||
done
|
||||
# Check for socat (preferred)
|
||||
if command -v socat >/dev/null 2>&1; then
|
||||
# Use socat with READLINE for history and arrow-key support.
|
||||
# It establishes a persistent bidirectional connection.
|
||||
socat READLINE,history=$HOME/.org_agent_history TCP:$HOST:$PORT
|
||||
else
|
||||
# Fallback to nc (netcat) for a single-shot connection if socat is missing.
|
||||
# Note: This is less robust for agents with long-thinking times.
|
||||
echo "WARNING: socat not found. Falling back to nc (no line-editing support)."
|
||||
while true; do
|
||||
read -p "User: " MESSAGE
|
||||
if [ -z "$MESSAGE" ]; then continue; fi
|
||||
echo "$MESSAGE" | nc -N $HOST $PORT
|
||||
done
|
||||
fi
|
||||
#+end_src
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
:END:
|
||||
#+TITLE: SKILL: Social Consensus Protocol (Universal Literate Note)
|
||||
#+STARTUP: content
|
||||
#+FILETAGS: :distributed:swarms:consensus:psf:
|
||||
#+FILETAGS: :distributed:swarms:consensus:autonomy:
|
||||
#+DEPENDS_ON: skill-sub-agent-manager
|
||||
|
||||
* Overview
|
||||
@@ -30,7 +30,7 @@ Enable reliable, cross-instance coordination without a central master.
|
||||
#+begin_src lisp
|
||||
(defun consensus-propose-vote (proposal)
|
||||
"Broadcasts a proposal to the peer swarm and collects votes.
|
||||
Implements PSF Social Consensus Protocol."
|
||||
Implements org-agent Social Consensus Protocol."
|
||||
(let* ((peers (get-swarm-peer-list))
|
||||
(votes (loop for peer in peers
|
||||
collect (org-agent:send-swarm-packet peer `(:type :REQUEST :action :vote :proposal ,proposal)))))
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
:END:
|
||||
#+TITLE: SKILL: Context Manager (Universal Literate Note)
|
||||
#+STARTUP: content
|
||||
#+FILETAGS: :context:system:psf:
|
||||
#+FILETAGS: :context:system:autonomy:
|
||||
|
||||
* Overview
|
||||
The *Context Manager* handles the cognitive stack of the agent, allowing for switching between different projects, areas, and tasks while maintaining a clean environment.
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
:END:
|
||||
#+TITLE: SKILL: Credentials Vault (Universal Literate Note)
|
||||
#+STARTUP: content
|
||||
#+FILETAGS: :auth:security:infrastructure:psf:
|
||||
#+FILETAGS: :auth:security:infrastructure:autonomy:
|
||||
#+DEPENDS_ON: id:state-persistence-skill
|
||||
|
||||
* Overview
|
||||
@@ -16,7 +16,7 @@ The *Credentials Vault* is the high-security enclave for the Org-Agent. It centr
|
||||
:END:
|
||||
|
||||
** 1. Purpose
|
||||
Securely manage all authentication tokens required for the PSF to operate.
|
||||
Securely manage all authentication tokens required for the org-agent to operate.
|
||||
|
||||
** 2. User Needs
|
||||
- *Unified Storage:* Single interface for API keys and Session Cookies.
|
||||
@@ -123,11 +123,11 @@ When a secret is updated, we immediately snapshot the Memory to ensure the crede
|
||||
#+end_src
|
||||
|
||||
** Onboarding Logic
|
||||
Retained from the legacy Google skill, this provides the instructions for the sovereign cookie handshake.
|
||||
Retained from the legacy Google skill, this provides the instructions for the autonomous cookie handshake.
|
||||
|
||||
#+begin_src lisp
|
||||
(defun vault-onboard-gemini-web ()
|
||||
"Instructions for the Sovereign Cookie Handshake."
|
||||
"Instructions for the Autonomous Cookie Handshake."
|
||||
(harness-log "--- GEMINI WEB ONBOARDING ---")
|
||||
(harness-log "1. Visit gemini.google.com")
|
||||
(harness-log "2. Run the 'Get Gemini Cookies' Bookmarklet.")
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
:END:
|
||||
#+TITLE: SKILL: Delegation Manager (Universal Literate Note)
|
||||
#+STARTUP: content
|
||||
#+FILETAGS: :delegation:multi-agent:psf:
|
||||
#+FILETAGS: :delegation:multi-agent:autonomy:
|
||||
|
||||
* Overview
|
||||
The *Delegation Manager* orchestrates the dispatch of tasks to sub-agents or specialized skills.
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
:END:
|
||||
#+TITLE: SKILL: Vector Embedding (Universal Literate Note)
|
||||
#+STARTUP: content
|
||||
#+FILETAGS: :embedding:vector-search:semantic:psf:
|
||||
#+FILETAGS: :embedding:vector-search:semantic:autonomy:
|
||||
|
||||
* Overview
|
||||
The *Vector Embedding* skill provides semantic search and vectorization capabilities to the org-agent. It decouples the specific embedding algorithms and provider-specific API calls from the core kernel.
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
:END:
|
||||
#+TITLE: SKILL: Environment Configuration Manager (Universal Literate Note)
|
||||
#+STARTUP: content
|
||||
#+FILETAGS: :system:config:sovereignty:psf:
|
||||
#+FILETAGS: :system:config:autonomousty:autonomy:
|
||||
|
||||
* Overview
|
||||
The *Environment Configuration Manager* is the source of truth for user preferences. It persists settings (like LLM Model Fleets) into the harness's Memory, allowing for dynamic runtime reconfiguration without environment variable bloat.
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
:END:
|
||||
#+TITLE: SKILL: Event Orchestrator (Universal Literate Note)
|
||||
#+STARTUP: content
|
||||
#+FILETAGS: :system:control:event-driven:cron:hooks:routing:psf:
|
||||
#+FILETAGS: :system:control:event-driven:cron:hooks:routing:autonomy:
|
||||
#+DEPENDS_ON: id:state-persistence-skill
|
||||
|
||||
* Overview
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
:END:
|
||||
#+TITLE: SKILL: Formal Verification Gate (Universal Literate Note)
|
||||
#+STARTUP: content
|
||||
#+FILETAGS: :security:logic:formal-methods:psf:
|
||||
#+FILETAGS: :security:logic:formal-methods:autonomy:
|
||||
|
||||
* Overview
|
||||
The *Formal Verification Gate* replaces heuristic whitelisting with deterministic logic proofs. It ensures that every action proposed by Probabilistic Engine is *provably safe* against the harness's core security invariants using a Lisp-native deterministic prover.
|
||||
@@ -30,7 +30,7 @@ Define a logic-based verification layer for high-integrity decision making witho
|
||||
** 2. Success Criteria
|
||||
- [ ] *Invariants:* Express security properties as Lisp predicates.
|
||||
- [ ] *Soundness:* Block any action that fails a deterministic safety check.
|
||||
- [ ] *Path Confinement:* Prove that file operations are confined to the Sovereign's memex.
|
||||
- [ ] *Path Confinement:* Prove that file operations are confined to the Autonomous's memex.
|
||||
- [ ] *Network Protection:* Prove that shell commands do not attempt unauthorized data exfiltration.
|
||||
|
||||
* Phase B: Blueprint (PROTOCOL)
|
||||
@@ -75,7 +75,7 @@ Ensures all file-related operations (including shell calls that touch files) are
|
||||
|
||||
#+begin_src lisp
|
||||
(def-invariant path-confinement :all (action context)
|
||||
"Forces all path-based operations to reside within the Sovereign Memex."
|
||||
"Forces all path-based operations to reside within the Autonomous Memex."
|
||||
(declare (ignore context))
|
||||
(let* ((payload (getf action :payload))
|
||||
(path (or (getf payload :file) (getf payload :path)))
|
||||
|
||||
@@ -2,12 +2,12 @@
|
||||
:ID: gardener-skill
|
||||
:CREATED: [2026-04-13 Mon 18:50]
|
||||
:END:
|
||||
#+TITLE: SKILL: Sovereign Gardener (Memex Maintenance)
|
||||
#+TITLE: SKILL: Autonomous Gardener (Memex Maintenance)
|
||||
#+STARTUP: content
|
||||
#+FILETAGS: :gardener:maintenance:memex:psf:
|
||||
#+FILETAGS: :gardener:maintenance:memex:autonomy:
|
||||
|
||||
* Overview
|
||||
The *Sovereign Gardener* is the metabolic immune system of the Memex. It autonomously audits the knowledge graph for structural decay—broken links, orphaned nodes, and missing metadata—ensuring that the system remains coherent and navigatable over long horizons.
|
||||
The *Autonomous Gardener* is the metabolic immune system of the Memex. It autonomously audits the knowledge graph for structural decay—broken links, orphaned nodes, and missing metadata—ensuring that the system remains coherent and navigatable over long horizons.
|
||||
|
||||
* Phase A: Demand (PRD)
|
||||
:PROPERTIES:
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
:END:
|
||||
#+TITLE: SKILL: Matrix Gateway (Universal Literate Note)
|
||||
#+STARTUP: content
|
||||
#+FILETAGS: :gateway:matrix:io:psf:
|
||||
#+FILETAGS: :gateway:matrix:io:autonomy:
|
||||
#+DEPENDS_ON: id:credentials-vault-skill
|
||||
|
||||
* Overview
|
||||
|
||||
@@ -4,11 +4,11 @@
|
||||
:END:
|
||||
#+TITLE: SKILL: Signal Gateway (Universal Literate Note)
|
||||
#+STARTUP: content
|
||||
#+FILETAGS: :gateway:signal:io:psf:
|
||||
#+FILETAGS: :gateway:signal:io:autonomy:
|
||||
#+DEPENDS_ON: id:credentials-vault-skill
|
||||
|
||||
* Overview
|
||||
The *Signal Gateway* provides bi-directional communication between the Sovereign and the Org-Agent via the `signal-cli` tool. It features a non-blocking polling sensor and a high-integrity actuator for outbound messaging.
|
||||
The *Signal Gateway* provides bi-directional communication between the Autonomous and the Org-Agent via the `signal-cli` tool. It features a non-blocking polling sensor and a high-integrity actuator for outbound messaging.
|
||||
|
||||
* Phase A: Demand (PRD)
|
||||
:PROPERTIES:
|
||||
|
||||
@@ -4,11 +4,11 @@
|
||||
:END:
|
||||
#+TITLE: SKILL: Telegram Gateway (Universal Literate Note)
|
||||
#+STARTUP: content
|
||||
#+FILETAGS: :gateway:telegram:io:psf:
|
||||
#+FILETAGS: :gateway:telegram:io:autonomy:
|
||||
#+DEPENDS_ON: id:credentials-vault-skill
|
||||
|
||||
* Overview
|
||||
The *Telegram Gateway* provides bi-directional communication between the Sovereign and the Org-Agent via the Telegram Bot API. It features a non-blocking polling sensor and a high-integrity actuator for outbound messaging.
|
||||
The *Telegram Gateway* provides bi-directional communication between the Autonomous and the Org-Agent via the Telegram Bot API. It features a non-blocking polling sensor and a high-integrity actuator for outbound messaging.
|
||||
|
||||
* Phase A: Demand (PRD)
|
||||
:PROPERTIES:
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
:END:
|
||||
#+TITLE: SKILL: Harness Monitor
|
||||
#+STARTUP: content
|
||||
#+FILETAGS: :system:monitor:telemetry:psf:
|
||||
#+FILETAGS: :system:monitor:telemetry:autonomy:
|
||||
#+DEPENDS_ON: id:47425a43-2be0-423c-8509-22592cfe9c9e
|
||||
|
||||
* Overview
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
:END:
|
||||
#+TITLE: SKILL: Homoiconic Memory (Universal Literate Note)
|
||||
#+STARTUP: content
|
||||
#+FILETAGS: :org-mode:ast:json:normalization:psf:
|
||||
#+FILETAGS: :org-mode:ast:json:normalization:autonomy:
|
||||
#+DEPENDS_ON: id:state-persistence-skill
|
||||
|
||||
* Overview
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
:END:
|
||||
#+TITLE: SKILL: Inbound Multi-Channel Gateway (Universal Literate Note)
|
||||
#+STARTUP: content
|
||||
#+FILETAGS: :gateway:sensors:io:psf:
|
||||
#+FILETAGS: :gateway:sensors:io:autonomy:
|
||||
|
||||
* Overview
|
||||
The *Inbound Multi-Channel Gateway* provides the sensory interface for external messaging. It enables the agent to "hear" the user from various platforms (Signal, Telegram, SMS) by normalizing disparate inbound payloads into standard Probabilistic-Deterministic Kernel stimuli.
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
:END:
|
||||
#+TITLE: SKILL: Lisp Repair Syntax Gate
|
||||
#+STARTUP: content
|
||||
#+FILETAGS: :system:repair:syntax:lisp:psf:
|
||||
#+FILETAGS: :system:repair:syntax:lisp:autonomy:
|
||||
|
||||
* Overview
|
||||
The *Lisp Repair Syntax Gate* asynchronously intercepts `:syntax-error` events emitted by the harness when Probabilistic Engine (LLM) proposals fail to parse. It performs deterministic or neural repairs and re-injects the corrected action into the pipeline.
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
:END:
|
||||
#+TITLE: SKILL: Lisp Validator
|
||||
#+STARTUP: content
|
||||
#+FILETAGS: :security:lisp:ast:psf:
|
||||
#+FILETAGS: :security:lisp:ast:autonomy:
|
||||
|
||||
* Overview
|
||||
The *Lisp Validator* is the primary structural gate for the Probabilistic-Deterministic Lisp Machine. It provides a recursive AST validator that subjects all Lisp proposals from the Probabilistic Engine to a strict "Deny-by-Default" sandbox.
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
:END:
|
||||
#+TITLE: SKILL: Unified LLM Gateway (Universal Literate Note)
|
||||
#+STARTUP: content
|
||||
#+FILETAGS: :llm:gateway:infrastructure:psf:
|
||||
#+FILETAGS: :llm:gateway:infrastructure:autonomy:
|
||||
#+DEPENDS_ON: id:credentials-vault-skill
|
||||
|
||||
* Overview
|
||||
@@ -118,7 +118,7 @@ This is the primary actuator for neural reasoning. It handles the specific JSON
|
||||
(:anthropic `(("Content-Type" . "application/json") ("x-api-key" . ,api-key) ("anthropic-version" . "2023-06-01")))
|
||||
(:gemini-api `(("Content-Type" . "application/json") ("x-goog-api-key" . ,api-key)))
|
||||
(:openrouter `(("Content-Type" . "application/json") ("Authorization" . ,(format nil "Bearer ~a" api-key))
|
||||
("HTTP-Referer" . "https://github.com/amr/org-agent") ("X-Title" . "org-agent Sovereign Kernel")))
|
||||
("HTTP-Referer" . "https://github.com/amr/org-agent") ("X-Title" . "org-agent Autonomous Kernel")))
|
||||
(t `(("Content-Type" . "application/json") ("Authorization" . ,(format nil "Bearer ~a" api-key))))))
|
||||
(body (case provider
|
||||
(:anthropic (cl-json:encode-json-to-string `((model . ,(or model "claude-3-5-sonnet-20240620")) (max_tokens . 4096) (system . ,system-prompt) (messages . (( (role . "user") (content . ,prompt) ))))))
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
:END:
|
||||
#+TITLE: SKILL: Memex Manager (Universal Literate Note)
|
||||
#+STARTUP: content
|
||||
#+FILETAGS: :memex:gtd:zettelkasten:integrity:psf:
|
||||
#+FILETAGS: :memex:gtd:zettelkasten:integrity:autonomy:
|
||||
|
||||
* Overview
|
||||
The *Memex Manager* is the primary automation engine for the Personal Knowledge Management system. It enforces metadata standards, automates task lifecycles, and distills ephemeral daily logs into timeless knowledge.
|
||||
@@ -22,7 +22,7 @@ Define automated behaviors for knowledge and task management integrity.
|
||||
- *Unified Capture:* Landing all new information in `inbox.org`.
|
||||
- *Metadata Compliance:* Mandatory `:CREATED:` and `:LOGBOOK:` drawers.
|
||||
- *Automated Task Lifecycle:* `NEXT` promotion logic for GTD.
|
||||
- *Mobile Sovereignty:* Compatibility with Markor and Orgzly.
|
||||
- *Mobile Autonomousty:* Compatibility with Markor and Orgzly.
|
||||
- *Agentic Distillation:* Extracting evergreen concepts from daily logs.
|
||||
|
||||
** 3. Success Criteria
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
:END:
|
||||
#+TITLE: SKILL: Onboarding & Calibration (Universal Literate Note)
|
||||
#+STARTUP: content
|
||||
#+FILETAGS: :onboarding:calibration:setup:psf:
|
||||
#+FILETAGS: :onboarding:calibration:setup:autonomy:
|
||||
|
||||
* Overview
|
||||
The *Onboarding Skill* ensures that the Lisp Machine environment is correctly calibrated. It automates the "zero-to-one" setup of the Probabilistic-Deterministic Kernel, including path normalization, identity personalization, and provider/actuator configuration.
|
||||
@@ -16,7 +16,7 @@ The *Onboarding Skill* ensures that the Lisp Machine environment is correctly ca
|
||||
:END:
|
||||
|
||||
** 1. Purpose
|
||||
Define automated behaviors for verifying and configuring the PSF environment.
|
||||
Define automated behaviors for verifying and configuring the org-agent environment.
|
||||
|
||||
** 2. User Needs
|
||||
- *Environment Verification:* Confirm SBCL, Quicklisp, and core binaries are present.
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
:END:
|
||||
#+TITLE: SKILL: Peripheral Vision (Universal Literate Note)
|
||||
#+STARTUP: content
|
||||
#+FILETAGS: :context:foveal:peripheral:pruning:psf:
|
||||
#+FILETAGS: :context:foveal:peripheral:pruning:autonomy:
|
||||
|
||||
* Overview
|
||||
The *Peripheral Vision* skill implements the Foveal-Peripheral Hybrid model for context pruning. It ensures that the LLM receives a semantically relevant and manageable view of the Memory, preventing context window overflow.
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
:END:
|
||||
#+TITLE: SKILL: Policy Enforcer
|
||||
#+STARTUP: content
|
||||
#+FILETAGS: :security:alignment:policy:psf:
|
||||
#+FILETAGS: :security:alignment:policy:autonomy:
|
||||
#+DEPENDS_ON: id:47425a43-2be0-423c-8509-22592cfe9c9e
|
||||
|
||||
* Overview
|
||||
@@ -15,7 +15,7 @@ Unlike traditional software where a "Kernel" might have hardcoded rules, the Org
|
||||
|
||||
1. **Topological Bootstrapping:** By declaring a #+DEPENDS_ON: dependency on the Policy file's ID, we ensure the System Policy is always registered in the Lisp image's skill catalog before this enforcer attempts to guard it.
|
||||
2. **Priority Preemption:** By setting :priority 1000, this skill registers itself as the very first check in the decide-gate. It effectively "pre-empts" all other skills, ensuring that no action (like a shell command or a file write) is even considered until it has cleared the alignment check.
|
||||
3. **Decoupled Enforcement:** The harness does not "know" it is enforcing a policy. It simply executes the highest-priority deterministic functions provided by its skills. This allows the Sovereign to swap out policies or enforcers without ever touching the core harness code.
|
||||
3. **Decoupled Enforcement:** The harness does not "know" it is enforcing a policy. It simply executes the highest-priority deterministic functions provided by its skills. This allows the Autonomous to swap out policies or enforcers without ever touching the core harness code.
|
||||
|
||||
* Implementation
|
||||
|
||||
@@ -27,11 +27,11 @@ Unlike traditional software where a "Kernel" might have hardcoded rules, the Org
|
||||
:probabilistic (lambda (context)
|
||||
\"You are the Org-Agent Policy Enforcer. Your goal is to ensure all actions empower the user through the Lisp Machine and adhere to the System Policy.\")
|
||||
:deterministic (lambda (action context)
|
||||
;; Basic invariant check: Block actions that appear to violate sovereignty
|
||||
;; Basic invariant check: Block actions that appear to violate autonomy
|
||||
(let ((payload (getf action :payload)))
|
||||
(if (and payload (search \"proprietary\" (format nil \"~s\" payload)))
|
||||
(progn
|
||||
(org-agent:harness-log \"DETERMINISTIC [Policy]: Sovereignty violation suspected. Blocking action.\")
|
||||
(org-agent:harness-log \"DETERMINISTIC [Policy]: Autonomy violation suspected. Blocking action.\")
|
||||
nil)
|
||||
action))))
|
||||
#+end_src
|
||||
|
||||
@@ -5,10 +5,10 @@
|
||||
:END:
|
||||
#+TITLE: SKILL: System Policy
|
||||
#+STARTUP: content
|
||||
#+FILETAGS: :platform:policy:alignment:
|
||||
#+FILETAGS: :platform:policy:alignment:autonomy:
|
||||
|
||||
* Overview
|
||||
The *Org-Agent* is a probabilistic-deterministic harness for a personal operating system. It uses Org-mode as its native memory and Common Lisp as its deterministic reasoning engine.
|
||||
The *org-agent* is a probabilistic-deterministic harness for a personal operating system. It uses Org-mode as its native memory and Common Lisp as its deterministic reasoning engine.
|
||||
|
||||
* Package Context
|
||||
Every skill executes within its own jailed package namespace, while inheriting core harness symbols.
|
||||
@@ -20,15 +20,15 @@ Every skill executes within its own jailed package namespace, while inheriting c
|
||||
* The Core Invariants
|
||||
This document contains the *Core System Policy*. These are non-negotiable philosophical and technical constraints that every agentic action MUST satisfy. The Deterministic Engine uses these headlines as a "Moral Compass" during the decision stage.
|
||||
|
||||
** 1. Sovereignty Above All
|
||||
Every action must increase the user's independence from centralized, proprietary platforms. If a tool or library introduces a dependency on a non-sovereign entity, it must be flagged for replacement.
|
||||
** 1. Autonomy Above All
|
||||
Every action must increase the user's independence from centralized, proprietary platforms. If a tool or library introduces a dependency on a non-autonomous entity, it must be flagged for replacement.
|
||||
|
||||
#+begin_src lisp :tangle ../src/policy.lisp
|
||||
(defun policy-check-sovereignty (action context)
|
||||
"Ensures the action does not violate the Sovereignty invariant."
|
||||
(defun policy-check-autonomy (action context)
|
||||
"Ensures the action does not violate the Autonomy invariant."
|
||||
(declare (ignore context))
|
||||
;; Implementation placeholder: currently permits all actions.
|
||||
;; Future: Scan for non-sovereign domain names or proprietary API endpoints.
|
||||
;; Future: Scan for non-autonomous domain names or proprietary API endpoints.
|
||||
action)
|
||||
#+end_src
|
||||
|
||||
@@ -50,7 +50,7 @@ The main deterministic entry point for the policy skill. It orchestrates the var
|
||||
#+begin_src lisp :tangle ../src/policy.lisp
|
||||
(defun policy-deterministic-gate (action context)
|
||||
"The main policy gate. Sub-calls engineering standards if available."
|
||||
(let ((current-action (policy-check-sovereignty action context)))
|
||||
(let ((current-action (policy-check-autonomy action context)))
|
||||
(when current-action
|
||||
(let ((eng-pkg (find-package :org-agent.skills.org-skill-engineering-standards)))
|
||||
(when eng-pkg
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
:END:
|
||||
#+TITLE: SKILL: Communication Protocol Schema Validator (Universal Literate Note)
|
||||
#+STARTUP: content
|
||||
#+FILETAGS: :protocol:communication-protocol:security:validation:psf:
|
||||
#+FILETAGS: :protocol:communication-protocol:security:validation:autonomy:
|
||||
|
||||
* Overview
|
||||
The *Communication 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.
|
||||
|
||||
@@ -2,12 +2,12 @@
|
||||
:ID: scribe-skill
|
||||
:CREATED: [2026-04-13 Mon 18:40]
|
||||
:END:
|
||||
#+TITLE: SKILL: Sovereign Scribe (Knowledge Distillation)
|
||||
#+TITLE: SKILL: Autonomous Scribe (Knowledge Distillation)
|
||||
#+STARTUP: content
|
||||
#+FILETAGS: :scribe:distillation:memex:psf:
|
||||
#+FILETAGS: :scribe:distillation:memex:autonomy:
|
||||
|
||||
* Overview
|
||||
The *Sovereign Scribe* is the background architect of the Memex. It is responsible for the "Nightly Distillation": a process that scans chronological daily logs, extracts evergreen concepts, and formalizes them into atomic Zettelkasten notes.
|
||||
The *Autonomous Scribe* is the background architect of the Memex. It is responsible for the "Nightly Distillation": a process that scans chronological daily logs, extracts evergreen concepts, and formalizes them into atomic Zettelkasten notes.
|
||||
|
||||
* Phase A: Demand (PRD)
|
||||
:PROPERTIES:
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
:END:
|
||||
#+TITLE: SKILL: Self-Fix Agent (Universal Literate Note)
|
||||
#+STARTUP: content
|
||||
#+FILETAGS: :self-repair:autonomy:debugging:psf:
|
||||
#+FILETAGS: :self-repair:autonomy:debugging:autonomy:
|
||||
#+DEPENDS_ON: id:0ae190ec-5991-49b5-9038-f860548a3a0c
|
||||
#+DEPENDS_ON: id:98576df2-c496-4e4a-9acb-0bca514a0305
|
||||
|
||||
@@ -81,7 +81,7 @@ The *Self-Fix Agent* is the system's "Repair Mechanism." It takes failure hypoth
|
||||
:priority 95
|
||||
:trigger (lambda (context) (eq (getf (getf context :payload) :sensor) :repair-request))
|
||||
:probabilistic (lambda (context)
|
||||
(format nil "You are the PSF Repair Actuator. Synthesize a surgical fix for the reported failure.
|
||||
(format nil "You are the org-agent Repair Actuator. Synthesize a surgical fix for the reported failure.
|
||||
Return a Lisp plist for :repair-file."))
|
||||
:deterministic (lambda (action context)
|
||||
(let ((payload (getf action :payload)))
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
:END:
|
||||
#+TITLE: SKILL: Shell Actuator Agent (Universal Literate Note)
|
||||
#+STARTUP: content
|
||||
#+FILETAGS: :shell:actuator:system:psf:
|
||||
#+FILETAGS: :shell:actuator:system:autonomy:
|
||||
|
||||
* Overview
|
||||
The *Shell Actuator Agent* provides the bridge to the host operating system. It enables secure command execution while maintaining a strict security posture through whitelisting and diagnostic feedback loops.
|
||||
@@ -51,7 +51,7 @@ Interfaces for secure system calls. State is event-driven via the core kernel bu
|
||||
*** DONE Diagnostic Capture
|
||||
- Verified that STDOUT, STDERR, and Exit Codes are correctly captured and re-injected.
|
||||
*** DONE Result Analysis Loop
|
||||
- The `:probabilistic` component successfully formats command results for Sovereign review.
|
||||
- The `:probabilistic` component successfully formats command results for Autonomous review.
|
||||
|
||||
* Phase B: Blueprint (PROTOCOL)
|
||||
:PROPERTIES:
|
||||
|
||||
@@ -4,17 +4,17 @@
|
||||
:END:
|
||||
#+TITLE: SKILL: State Persistence Layer (Universal Literate Note)
|
||||
#+STARTUP: content
|
||||
#+FILETAGS: :memory:persistence:closos:ipfs:psf:
|
||||
#+FILETAGS: :memory:persistence:closos:ipfs:autonomy:
|
||||
|
||||
* Overview
|
||||
The *State Persistence Layer* ensures the durability and sovereignty of the agent's memory. It unifies local, high-performance Lisp image dumps with decentralized, immutable IPFS checkpointing. This dual-path approach provides both rapid operational recovery and long-term historical integrity.
|
||||
The *State Persistence Layer* ensures the durability and autonomousty of the agent's memory. It unifies local, high-performance Lisp image dumps with decentralized, immutable IPFS checkpointing. This dual-path approach provides both rapid operational recovery and long-term historical integrity.
|
||||
|
||||
** Deep Reasoning: Protection Against External Tampering
|
||||
While the *Prover* and *Bouncer* protect against internal skill failures, the Merkle-Tree architecture within the State Layer protects against **External Threats** (e.g., a hacker or virus modifying your `.org` files directly on disk).
|
||||
|
||||
1. **Skill Hashing:** Every code block and headline in a skill file has a unique Merkle hash recorded in the Memory.
|
||||
2. **Integrity Verification:** Upon loading or reloading a skill, the harness re-calculates the hash and compares it against the "known good" state in the Merkle Tree.
|
||||
3. **Automatic Lockdown:** If a file has been tampered with externally, the hash mismatch triggers an immediate lockdown. the harness refuses to execute the skill and alerts the Sovereign via Signal/Telegram.
|
||||
3. **Automatic Lockdown:** If a file has been tampered with externally, the hash mismatch triggers an immediate lockdown. the harness refuses to execute the skill and alerts the Autonomous via Signal/Telegram.
|
||||
|
||||
* Phase A: Demand (PRD)
|
||||
:PROPERTIES:
|
||||
@@ -26,7 +26,7 @@ Define automated behaviors for knowledge graph serialization, local persistence,
|
||||
|
||||
** 2. User Needs
|
||||
- *Instant Recall:* Rapid local loading of the Memory from a persistent image.
|
||||
- *Decentralized Archival:* Pushing immutable snapshots to IPFS for cross-node sync and sovereignty.
|
||||
- *Decentralized Archival:* Pushing immutable snapshots to IPFS for cross-node sync and autonomousty.
|
||||
- *Merkle Integrity:* Every save operation must respect and record the Merkle-Tree history.
|
||||
- *Safety:* Sanitize and validate data during restoration to prevent code injection.
|
||||
|
||||
@@ -36,7 +36,7 @@ Define automated behaviors for knowledge graph serialization, local persistence,
|
||||
:END:
|
||||
|
||||
** 1. Architectural Intent
|
||||
The persistence layer acts as a bridge between the volatile RAM-resident Memory and permanent storage backends. It provides two adapters: `LOCAL` (fast, SBCL-native) and `IPFS` (sovereign, content-addressed).
|
||||
The persistence layer acts as a bridge between the volatile RAM-resident Memory and permanent storage backends. It provides two adapters: `LOCAL` (fast, SBCL-native) and `IPFS` (autonomous, content-addressed).
|
||||
|
||||
** 2. Semantic Interfaces
|
||||
#+begin_src lisp
|
||||
@@ -120,7 +120,7 @@ Restores the state from the local disk.
|
||||
#+end_src
|
||||
|
||||
** IPFS Serialization (persistence-serialize-for-archival)
|
||||
Converts the live `*memory*` into a list of Lisp Property Lists (Plists) for sovereign, homoiconic transport.
|
||||
Converts the live `*memory*` into a list of Lisp Property Lists (Plists) for autonomous, homoiconic transport.
|
||||
|
||||
#+begin_src lisp
|
||||
(defun persistence-serialize-for-archival ()
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
:END:
|
||||
#+TITLE: SKILL: Task Integrity Agent (Universal Literate Note)
|
||||
#+STARTUP: content
|
||||
#+FILETAGS: :gtd:integrity:safety:psf:
|
||||
#+FILETAGS: :gtd:integrity:safety:autonomy:
|
||||
|
||||
* Overview
|
||||
The *Task Integrity Agent* is the "Guardian" of the GTD system. It ensures that all task transitions adhere to semantic rules, preventing logical inconsistencies and maintaining the structural health of the task hierarchy.
|
||||
|
||||
Reference in New Issue
Block a user