fix(chaos): finalized absolute tangle paths via concat and INSTALL_DIR

This commit is contained in:
2026-04-28 18:22:49 -04:00
parent a2d6c5ae38
commit 357efbdb59
35 changed files with 641 additions and 641 deletions

View File

@@ -1,4 +1,4 @@
#+PROPERTY: header-args:lisp :tangle (expand-file-name "harness/perceive.lisp" (expand-file-name "harness/"))
#+PROPERTY: header-args:lisp :tangle (concat (identity (getenv "INSTALL_DIR")) "/harness/perceive.lisp")" )
#+TITLE: Stage 1: Perceive (perceive.lisp)
#+AUTHOR: Amr
#+FILETAGS: :harness:perceive:
@@ -70,7 +70,7 @@ Other sensors (heartbeats, interrupts) are processed synchronously to maintain o
so they run in separate threads to avoid blocking the main pipeline.
Other sensors (:heartbeat, :interrupt, :buffer-update) are processed
synchronously to maintain temporal ordering.")
synchronously to maintain temporal ordering.
#+end_src
** Foveal Focus State
@@ -83,7 +83,7 @@ Other sensors (heartbeats, interrupts) are processed synchronously to maintain o
responses. When editing a specific note, the agent knows which
note you're referring to without needing explicit ID references.
Updated on :point-update events from Emacs.")
Updated on :point-update events from Emacs.
#+end_src
* Stimulus Injection
@@ -113,7 +113,7 @@ Other sensors (heartbeats, interrupts) are processed synchronously to maintain o
;; Ensure metadata exists
(unless meta
(setf meta (list :SOURCE :SYSTEM :SESSION-ID "internal")))
(setf meta (list :SOURCE :SYSTEM :SESSION-ID "internal))
;; Attach reply stream if provided
(when stream
@@ -131,7 +131,7 @@ Other sensors (heartbeats, interrupts) are processed synchronously to maintain o
(invoke-restart 'skip-event))))
(process-signal raw-message))
(skip-event () nil)))
:name "opencortex-async-task")
:name "opencortex-async-task
;; Sync: process in main thread with recovery
(restart-case
@@ -140,7 +140,7 @@ Other sensors (heartbeats, interrupts) are processed synchronously to maintain o
(invoke-restart 'skip-event))))
(process-signal raw-message))
(skip-event ()
(harness-log "SYSTEM RECOVERY: Stimulus dropped."))))))
(harness-log "SYSTEM RECOVERY: Stimulus dropped.)))))
#+end_src
* The Perceive Gate
@@ -170,7 +170,7 @@ Other sensors (heartbeats, interrupts) are processed synchronously to maintain o
;; Log the incoming signal for debugging
(harness-log "GATE [Perceive]: ~a (~a) [Source: ~s]"
type (or sensor "no-sensor") (getf meta :source))
type (or sensor "no-sensor (getf meta :source))
;; Handle EVENT type sensors
(cond ((eq type :EVENT)
@@ -227,7 +227,7 @@ Other sensors (heartbeats, interrupts) are processed synchronously to maintain o
These tests verify the Perceive pipeline. Run with:
~(fiveam:run! 'pipeline-perceive-suite)~
#+begin_src lisp :tangle (expand-file-name "harness/pipeline-perceive-tests.lisp" (concat (concat (or (getenv "INSTALL_DIR") ".") "/harness") "/tests"))
#+begin_src lisp :tangle pipeline-perceive-tests.lisp" (concat (concat (or (getenv "INSTALL_DIR ". "/harness "/tests)
(defpackage :opencortex-pipeline-perceive-tests
(:use :cl :fiveam :opencortex)
(:export #:pipeline-perceive-suite))
@@ -235,14 +235,14 @@ These tests verify the Perceive pipeline. Run with:
(in-package :opencortex-pipeline-perceive-tests)
(def-suite pipeline-perceive-suite
:description "Test suite for Perceive pipeline")
:description "Test suite for Perceive pipeline
(in-suite pipeline-perceive-suite)
(test test-perceive-gate
"Perceive gate should update the object store and normalize signal."
(clrhash opencortex::*memory*)
(let* ((signal (list :type :EVENT :payload (list :sensor :buffer-update :ast (list :type :HEADLINE :properties (list :ID "test-node" :TITLE "Test") :contents nil))))
(let* ((signal (list :type :EVENT :payload (list :sensor :buffer-update :ast (list :type :HEADLINE :properties (list :ID "test-node" :TITLE "Test :contents nil))))
(result (perceive-gate signal)))
(is (eq :perceived (getf result :status)))
(is (not (null (gethash "test-node" opencortex::*memory*))))))