Ensure all OLLIE_* path env vars (OLLIE, OLLIE_TOOLS_PATH,
OLLIE_SKILLS_PATH, OLLIE_PLAN_PATH, OLLIE_MEMORY_PATH) are set
to their default values via os.Setenv before the server or any
session is created. This guarantees they are visible to tool
subprocesses without requiring explicit external configuration.
makeStat was reporting Length=0 for /s/new, /s/idx, /backends, /help,
and all store-backed files (/a/*, /p/*, /sk/*, /t/*). Clients that
check stat before reading (cat, 9pfuse) saw an empty file and never
issued Tread.
Also adds debug logging (OLLIE_9P_DEBUG=1) across all 9P operations,
tagged with "9p:" prefix.
rm -r first unlinks each synthetic file in s/{id}/ before removing the
directory. The remove handler was passing the file basename to
SessionStore.Delete, which failed with "session not found".
Treat /s/{id}/{file} removes as no-ops so rm -r can proceed to the
directory removal, which triggers the actual session kill.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
All /s/ directory operations now route through SessionStore:
- pathType uses sessionStore.Stat for /s/{name} entries
- readDir uses sessionStore.List for /s/ listing
- wstat uses sessionStore.Rename for session renames
- read/write/remove for /s/new and /s/{id} already updated
README.md changes excluded (unrelated to store work).
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Add ReadableStore, WritableStore, ReadWriteStore, BlobStore, and Store
interfaces with FlatDirStore as the default filesystem-backed implementation.
Each 9P directory endpoint is now backed by a named store:
/a/ agentStore (Store - FlatDirStore)
/p/ promptStore (ReadableStore - FlatDirStore)
/m/ memStore (Store - FlatDirStore)
/pl/ planStore (Store - FlatDirStore)
/t/ toolStore (Store - ToolStore, synthetic idx)
/sk/ skillStore (Store - SkillStore, wraps skills package)
/s/{id}/ per-session (ReadWriteStore - SessionFileStore, in-memory)
Swapping a backend (e.g. /m/ to a vector store, /pl/ to beads) now requires
only a new Store implementation — no changes to the 9P server logic.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Create handler initializes an empty file in memDir; write handler
(called from clunk) writes the full content to disk. Removes
temporary debug logging.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Add explicit idx check in pathType() before the os.Stat fallback,
add idx entry to /t directory listing with mode 0444, and set
/t/idx stat mode to 0444. The read handler already generated live
content from tool headers — only the routing was broken.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- Remove file.Decl and reasoning.Decl from dispatcher
- go mod tidy: drop go-udiff dependency
- Initialize /tmp/ollie/$sessID on session create (rm -rf + mkdir)
- Rename /tmp/ollie/$oldID -> $newID on session rename
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Both are generated on read from current state — no physical files.
t/idx scans ToolsPath() headers; sk/idx uses skills.List().
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
sk/idx is written by rebuildSkillsIdx() at session start but was
invisible via 9P since sk/ reads go through skills.Read() which only
knows skill directories. Add explicit handling in pathType, read, stat,
and directory listing — same pattern as s/idx.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Synthetic read-only file at ollie/s/idx. Each line is tab-separated:
{id} {state} {cwd} {backend} {model}
Generated on demand from live session state so it's always current.
Enables agents to discover peers by cwd or name without polling
individual session files.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
OLLIE_MEMORY_PATH and OLLIE_PLAN_PATH are now configured via sandbox
yaml overlays rather than injected at session creation. Remove the
SetEnv calls so the sandbox can pick them up from the environment if
the user has set them.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Wire /m as a read-write directory that maps to s.memDir
(OLLIE_MEMORY_PATH or ~/.local/share/ollie/memory). Handles
fileType, create, read, write, rename, remove, stat, and directory
listing — mirrors /pl exactly. Inject OLLIE_MEMORY_PATH into the
execute server env alongside OLLIE_PLAN_PATH.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Register memory.Decl() and task.Decl(planDir) in the dispatcher.
Remove filePlanBackend (plan logic now lives in core/pkg/tools/task).
Drop WithFallbackPlanBackend now that BuildAgentEnv takes no options.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
ctl now validates the first word of input against a closed set of
known commands. Unrecognized input returns an error instead of being
silently forwarded as a prompt to the agent.
- Support mv on session directories (wstat rename)
- Track connections globally for fid path rewriting on rename
- Add kill and rn <name> to ctl handler
- Append rename notification to chat log
- Update README with rename and ctl docs
ctl is no longer in the async bucket. stop is always instant.
Slash commands forwarded via Submit are synchronous for recognized
commands. Unrecognized input is rejected with Rerror when the
agent is running to prevent accidentally starting an agent turn.
prompt, enqueue, ctl writes run async — they may block for an
entire agent turn and don't benefit from Rerror. Everything else
(disk I/O, state mutations, s/new) runs synchronously so errors
surface as Rerror without holding the connection.
handleWrite returns error; clunk runs it synchronously and
returns Rerror on failure. Writes to backend, agent, model
reject with Rerror when the agent is running. Prompt writes
remain async (they block for the full agent turn). Disk I/O
errors now surface as Rerror instead of stderr logging.
stop is the only out-of-band signal. Everything else is forwarded
as a slash command (/ prepended automatically), so 'echo compact > ctl'
works directly.
Allows rm on files under the prompts, skills, and tools directories.
Skills remove the entire skill directory (including SKILL.md).
Other paths still return 'remove not supported'.
- Replace {sid} with YYYYMMDDThhmmss_{uid8} in plan filenames for
uniqueness independent of session identity
- Initial status is __todo (was __wip)
- Instruct bot to transition __todo → __wip → __done
- Remove sid field from filePlanBackend