(in-package :opencortex.skills.org-skill-architect) (defun architect-scan-all-notes () (let* ((notes-dir (or (uiop:getenv "MEMEX_NOTES") "/home/user/memex/notes/")) (files (uiop:directory-files (uiop:ensure-directory-pathname notes-dir))) (ready-notes '())) (opencortex:kernel-log "ARCHITECT - Scanning ~a files in ~a" (length files) notes-dir) (dolist (file files) (let ((name (pathname-name file)) (type (pathname-type file))) (when (and name type (uiop:string-prefix-p "org-skill-" name) (string-equal type "org")) (let ((status (architect-perceive-frozen-prd file))) (when status (push status ready-notes)))))) (opencortex:kernel-log "ARCHITECT - Found ~a ready notes." (length ready-notes)) ready-notes))