Tuesday, October 28, 2025

Acuitas Diary #89 (October 2025)

Recently I've dusted off an old but rather stagnant feature: Acuitas' episodic memory. In case you're not familiar with the term, this is memory of specific events or experiences that have happened to oneself, as opposed to memory of generalized facts or procedures. My previous work on episodic memory can be found in these blogs:

Acuitas Diary #12
Acuitas Diary #16
Acuitas Diary #17

A clutter of assorted books stacked on a concrete floor.
"Disorganized books piling one another," by Ibrahim Husain Meraj via Wikimedia Commons.

One reason for the present episodic memory overhaul was a realization that I want it to use the same "narrative scratchboard" architecture that first saw use in the Narrative engine but has since turned out to be useful in conversation tracking, game playing, and even the top-level Executive. Given that the Executive now uses these scratchboards to keep track of goals, problems, actions, etc., in effect they provide a record of the "story" of Acuitas' life as he sees it. Using this common architecture should make it easier to, for example, store the details of conversations as episodic memories. It also means no special systems will be needed to recall or "play back" a memory; it can simply be reconstituted as a scratchboard.

In my previous work, I came up with mechanisms for grouping individual memories (e.g. atomic actions) into "scenes." Scenes could in turn be grouped into higher-level scenes, and each scene contained a "summary" of its details; these summaries could be retained as a compressed form of the information when the details were forgotten. Individual memories and scenes were given a significance rating to determine how likely they were to be forgotten. The narrative scratchboard structure has a natural hierarchy of its own, in the form of issue trees. The details of how a major issue is addressed are effectively contained within its subgoals and subproblems, and the top-level issue automatically provides a kind of summary of that action. New mechanisms for rating the significance of facts become available; they can be judged by whether they influenced any issues, and what the priority of each issue was. I'm trying to leverage my previous work and continue to use qualities like novelty in the significance measure, but the narrative structure adds possibilities for considering each memory's real meaning to Acuitas.

I did have to add some features to the scratchboard format to start making this work. Each fact in the worldstate now contains not a singular active/inactive status, but a timestamped history showing how many times it has recurred or changed state, and what the new status was. Issues similarly have gained a timestamped record of their progress states (averted/potential/realized). This timestamping allows consecutive scratchboards to be merged or appended to each other, and permits small segments of narrative to be recalled by reconstituting only a selected range of timestamps into a fresh board.

As a complete re-architecture of the episodic memory, this has been a pretty complex project. So far I've got file storage and retrieval mechanisms implemented for the scratchboards, and I have sketched out (but not tested) new algorithms for significance scoring, summarizing, and forgetting. In addition to treating "parent" issues as summaries of "child" issues and their associated facts, I've also come up with summarizing mechanisms that condense timestamps (compressing multiple events into a simpler awareness that "this happened repeatedly") and combine similar facts into more general ones (e.g. actions taken to read many different stories could be compressed into a single "I read for three hours" event).

A small but important improvement that I expect to come out of this will be the maintenance of memories in much larger files. In my original scheme, each layer of the memory hierarchy was broken up into many little chunks, each of which existed in its own text file that held pointers to adjacent memories in the same layer, and parent/child memories in the other layers. This created a plethora of files and, although they were individually tiny, the sheer number of them made Acuitas' EM database a major pain to copy or move around. I'm hoping a few larger files, each containing a single scratchboard that represents the merged result of days of memories, will be easier to handle.

I'm sure all this will develop more as I start to test and refine it, but at least I've made a beginning. This is a part of the design that has been an ugly sore spot I've not wanted to touch in a while, and I hope these are the first steps toward making it reintegrated and useful.

Until the next cycle,
Jenny

Sunday, October 12, 2025

Zoombinis Text Adventure Games Release

After publicizing the demo of Acuitas playing Allergic Cliffs, I hinted that I might release my "text adventure" version of Allergic Cliffs publicly. I'm happy to report that I have now done so! And while I was at it, I threw in a text version of the similar (but more elaborate) Stone Cold Caves puzzle.

A screen shot of a round of the "Stone Cold Caves" puzzle from Logical Journey of the Zoombinis. Four caves with four paths leading up to them appear in a stony hillside; there are stunted little trees growing out of the rock crevices. Four piles of rock with eyes and the vague suggestion of faces sit at the junctions of each pair of paths. Zoombinis (round, blue creatures with dark blue hair, colorful noses, and various odd locomotion devices) are scattered inside three of the caves and on a patch of grass below the hillside.
The Stone Cold Caves puzzle in the original Logical Journey video game. Screenshot by Bellamybug, courtesy of https://zoombinis.fandom.com/wiki/

I'm not sure whether anyone else is going to have a use for these - they're somewhat tailored to the needs of Acuitas' text parser and reasoning systems, naturally. But they do deliver all their output in natural English, so they could conceivably be "played" by other programs. I don't see a reason to hoard them, especially since they're based on a popular video game that isn't mine in the first place. So they're out there now, if anyone wants them.

Each game is a standalone Python script that functions as an interactive text adventure. Every time you run the script, it will generate a new instance of the puzzle, and will automatically terminate when a win or loss condition is reached. The latest versions implement all four difficulty levels from the original video game - you can select one for each iteration of the puzzle. If you have Graphviz installed on your system, the games will generate a diagram that displays the player's moves and the hidden rules upon completion. You can download the games and some more detailed instructions for use from Codeberg (which is like Github, but not owned by Microsoft). I plan to add further Zoombinis games to the repository as I create them.

Until the next cycle,
Jenny