feat: stabilized org-agent two-way communication and UX
- Fixed kernel-to-Emacs communication bridge. - Resolved boot-time crashes in multiple skeletal skills. - Refined Chat skill prompt to eliminate conversational filler. - Updated Emacs UI to automatically clean up status markers. - Synchronized all fixes via Literate Org-mode documents. - Verified physical two-way interaction via simulation.
This commit is contained in:
24
test-chat-wait.lisp
Normal file
24
test-chat-wait.lisp
Normal file
@@ -0,0 +1,24 @@
|
||||
(require :usocket)
|
||||
|
||||
(defun test-chat-and-wait ()
|
||||
(let* ((socket (usocket:socket-connect "127.0.0.1" 9105))
|
||||
(stream (usocket:socket-stream socket))
|
||||
(msg "(:type :event :payload (:sensor :chat-message :text \"ping\"))")
|
||||
(len (length msg))
|
||||
(framed (format nil "~6,'0x~a" len msg)))
|
||||
(format t "Sending: ~a~%" framed)
|
||||
(write-string framed stream)
|
||||
(finish-output stream)
|
||||
(handler-case
|
||||
(loop
|
||||
(let* ((len-prefix (make-string 6)))
|
||||
(read-sequence len-prefix stream)
|
||||
(let* ((msg-len (parse-integer len-prefix :radix 16))
|
||||
(payload (make-string msg-len)))
|
||||
(read-sequence payload stream)
|
||||
(format t "AGENT RESPONSE: ~a~%" payload)
|
||||
(when (search ":insert-at-end" payload) (return)))))
|
||||
(error (c) (format t "ERROR: ~a~%" c)))
|
||||
(usocket:socket-close socket)))
|
||||
|
||||
(test-chat-and-wait)
|
||||
Reference in New Issue
Block a user