iii-directory
v1.2.21Engine introspection, workers registry proxy, filesystem-backed skills, system prompts, and agent profiles, plus lexical function search with a conditional pre-generate hint.
- macOS: arm64
- Linux: arm64 · armv7 · x64
- Windows: arm64 · x64
exact versions are immutable; binary and bundle artifacts are digest-pinned.
skill doc
iii-directory
The directory worker is how an agent finds its way around the engine. It exposes
five surfaces: function search (directory::search_functions), installed-worker
docs (directory::skills::*), chat identity prompts
(directory::system-prompts::*), reusable agent profiles
(directory::agents::*), and the public worker catalogue
(directory::registry::*). A download pulls a bundle
onto disk, and each filesystem-backed family also takes direct create /
update / delete calls — those are this worker's only writes. Everything
else here is read-only.
Two kinds of id flow through this worker and they must not be mixed up. A
callable id uses :: (directory::skills::get) and goes in the function:
field of agent_trigger. A skill id uses / (iii-sandbox,
agent-memory/observe) and names a document — pass it as the id argument to
directory::skills::get. The ids that list and index print are skill ids; a
worker's overview is the bare worker name (iii-sandbox, not iii-sandbox/index,
and the iii- prefix is never dropped). Use the id you were given — do not
invent one.
Only installed workers are visible. index, list, and get show on-disk
skills for installed workers, plus this worker and the iii engine which are
always present. A skill you know exists stays invisible until its worker is
downloaded, so when one is missing, install it and look again. With
auto_download enabled the worker subscribes to the engine worker add event
and pulls a newly added worker's skills automatically, so freshly installed
workers can appear without a manual download. System-installed agent skills
under the read-only agents_skills_folder (.agents/skills under
III_COMPOSE_DIR, or the process current directory when standalone) are
also always visible in list/get — they are skills, not workers, so they
never appear in index and update/delete refuse them.
When to Use
- You need functions for a step's unmet capabilities (usually one to six, at most eighteen) —
directory::search_functions. - You need to see which workers are installed —
directory::skills::index(token-light; start here). - You need to read a worker's overview or a deeper doc it linked to —
directory::skills::get. - You need to find a skill across the repo with filters —
directory::skills::list. - You need the system prompts the chat picker offers as an identity override —
directory::system-prompts::list/get. - You need a reusable agent profile (display name, emoji logo, skill selection, and its system prompt) —
directory::agents::list/get. - You are deciding whether to install a worker —
directory::registry::workers::infois the pre-install card: public function/trigger names with descriptions, config, dependencies, skill paths (no schemas;readme: trueadds the README). Contracts come fromengine::functions::infoafter install. - You need to install a published worker's skills —
directory::skills::download_from_registry. - You can only reach the
directory::namespace but need one engine function's exact schema —directory::engine::functions::info.
Boundaries
- Only installed workers are visible. If the engine daemon is unreachable at boot, filtering is skipped and everything on disk is shown instead.
- Writes are downloads plus the per-family
create/update/deletecalls; every read function leaves disk untouched. - Skills under
agents_skills_folderare read-only:update/deleterefuse them (D116), andcreaterefuses ids in their namespaces (D115). Edit them with their owning tool, or copy one intoskills_folderon disk to fork it. - Not the live-connection view.
directory::*reflects what is on disk or in the registry, not what is connected right now. For that, call the engine directly (engine::functions::list,engine::workers::list, …); daemon-managed providers (http,cron,state) open no WebSocket, so mergeworker::listbyname. - Do not put a skill id (
/) inagent_trigger'sfunction:field, and do not pass a function id (::) todirectory::skills::get. - System prompt files without a
description:in frontmatter are silently skipped bydirectory::system-prompts::list. - Skills and system prompts share
skills_folder; asystem-prompts/path component selects the prompt family, otherprompts/paths are ignored, andagents/is reserved. Agent profiles are directfiles./ .md - An agent profile's
skills:list is its PRELOADED skills, the twin offunctions:: the harness freezes each skill's body into the prompt of every session running as the profile (parents' lists included, root-first). It grants no access and never narrows the skills index; unknown ids are reported bygetasunknown_skillswarnings rather than errors and rendered as unavailable.agents_folderprofiles are unrelated to the read-onlyagents_skills_folder(~/.agents/skills), which holds external tools' skills. - Registry answers (
registry::workers::list/info) are cached ~60 s per unique input by default (registry_cache_ttl_ms) — change a parameter to refresh.
Functions
directory::search_functions— find compact installed and installable function candidates for the required capabilities (usually one to six, at most eighteen per call).directory::skills::index— token-light per-worker overview, one block per installed worker; truncates and tells you to calllistwhen large.directory::skills::list— enumerate every visible skill with id/title/type/description/bytes/modified_at; narrow withsearch,prefix,type, orinclude_description.directory::skills::get— read one skill doc by its skill id; forgiving about short names, a trailing.md, aniii://prefix, andSKILL.mdfilenames. The response'spathis the absolute on-disk file; its parent directory is the skill's base directory, where payload the body references by relative path (scripts/,reference/) lives.directory::skills::download_from_registry— install a published worker's skills from the registry;workerrequired, pin withversionXORtag(defaulttag: latest).directory::skills::download_from_repo— pull one skill folder from a GitHub repo;repo+skillrequired,branchdefaults tomain.directory::skills::download— flexible alias accepting either source set; prefer the two explicit forms so the source is unambiguous.directory::skills::update— overwrite one EXISTING skill with new full-file markdown (frontmatter included); never creates — author withdirectory::skills::createor materialize a bundle with a download first.directory::skills::create— create a NEW skill atfrom full-file content; refuses an id that already resolves in the visible set, an existing target path, and ids the visibility filter (or a system-installed agents namespace) would hide./ .md directory::skills::delete— permanently remove one EXISTING skill by id (same forgiving id forms asget); cleans up parent directories left empty.directory::system-prompts::list— list the system prompts the chat picker offers; the response array is namedprompts.directory::system-prompts::get— read one system prompt's body by name;raw: truealso returns the full on-disk file for round-tripping.directory::system-prompts::create— create a NEW system prompt at; refuses an existing name or target path./system-prompts/ .md directory::system-prompts::update— overwrite one EXISTING system prompt; the frontmatter must keep a non-emptydescription(a declarednamerenames it).directory::system-prompts::delete— permanently remove one EXISTING system prompt by name.directory::agents::list— list agent profiles (id, display name, description, emoji logo,extends,skill_countwhere null means every skill,function_countof preloaded functions;model/reasoning_effortare resolved throughextends;skill_count/function_countcount the additive union of the chain's lists). The bundled basesiii(the harness default identity) andiii-minimal(the compact directory-first identity) are always listed withbuiltin: true; a row withinheritance_errorhas a brokenextendschain.directory::agents::get— read one agent profile by id: its RESOLVED system prompt (ancestors' bodies root-first viaextends, then its own; blank bodies are skipped, so a prompt-less profile serves its parent chain, or""when it has no parent), preloadedskills(skill ids whose bodies the harness pre-loads into the session prompt) +unknown_skills, preloadedfunctions(engine function ids whose contracts the harness pre-loads into the system prompt of every session running as this profile) +unknown_functions(ids the engine does not know right now — a warning), andmodel(the profile's default model id — use it when spawning/sending with this profile;null= caller decides);raw: truereturns the profile's OWN file for editing.inheritance_errorset = fixextendsbefore running it.directory::agents::create— create a NEW agent profile atfrom full-file content; frontmatter needs a non-empty/ .md name,logois emoji-only,skills:andfunctions:(preloaded function ids, e.g.coder::tree) are optional lists, and the body — the system prompt — may be empty; anextends:that does not resolve is not a write error —getreports it asinheritance_error.directory::agents::update— overwrite one EXISTING agent profile (same scanner rules; the id stays the file stem, frontmatternameis display-only). Updating the bundlediiicreates the local file that shadows it.directory::agents::delete— permanently remove one EXISTING agent profile by id; running sessions are unaffected, profiles extending it stop resolving until fixed. Deleting a localiiifalls back to the bundled copy.directory::agents::functions::add/directory::agents::functions::remove—{ id, functions: ["coder::tree", …] }: add ids to / drop ids from one EXISTING profile's OWNfunctions:list without a raw round-trip; the rest of the file stays byte-identical, ids already present (or already absent) are ignored,unchanged: truemeans nothing was written. Editing a bundled profile creates the local shadow. Ids inherited throughextendsare not touched: the resolved list is the union of the chain (root first), so an inherited id is removed on the parent that declares it.directory::registry::workers::list— page through published workers in the public registry (pagination.next_cursorfeeds the next page'scursor).directory::registry::workers::info— pre-install card for one worker, including ones not installed: envelope,api_reference(public functions + triggers, names and descriptions only) andskills_tree;readme: trueadds the README.directory::engine::functions::info— thin proxy to the engine'sengine::functions::info; returns request/response schema, metadata, and registered triggers for one function id.
A failed call returns one plain sentence carrying a Did you mean: suggestion and a Next: function to call (codes D110/D112/D210/D310/D311, D410 for a missing agent profile, D416 for an agent functions::add/remove request with no valid function ids, D320 when the registry is unreachable, and on the write paths D213 for content the next scan would skip, D214/D114/D414 for a create whose name/id or target path is already taken, D115 for a skill id the visibility filter or an agents namespace reserves, and D116 for a write to a read-only system-installed skill) — follow it instead of retrying the same input. Downloads overwrite file-by-file, so hand-edited extra files survive a re-pull.
Reactive triggers
The worker publishes three custom trigger types, one per kind —
directory::skills::on-change,
directory::system-prompts::on-change, and directory::agents::on-change. Each fires for its own kind only, on any
of: a download that wrote at least one file of that kind (op: "download"), that
family's update, create, or delete (op: "update" / "create" /
"delete"), or a change made to
that kind's files directly on disk, outside this worker (op: "external" — a
file pasted in, edited in an external editor, deleted, or renamed). Bind one when
a different worker must react to the on-disk set changing; the mcp worker uses
this to emit notifications/*_list_changed to its clients without re-polling.
Direct profile edits under agents_folder fire
directory::agents::on-change; nested files there are ignored.
Reach for it when:
- A worker caches the skill, system-prompt, or agent-profile list and must invalidate it on change.
- You want a push the moment new bundles install, instead of polling
directory::skills::list.
Do not bind when:
- You ran the download yourself — its return payload already lists
skills_written/system_prompts_written/agents_written. - Your own reaction writes
.mdfiles underskills_folderthrough some path OTHER than this worker'supdate/create(a shell or coder worker, say). Writes made through this worker are suppressed, but outside writes are not: your handler would re-trigger itself.
How to bind
- Register a handler:
registerFunction('my-worker::on-skills-changed', handler). - Register the trigger:
iii.registerTrigger({
type: 'directory::skills::on-change',
function_id: 'my-worker::on-skills-changed',
})Delivery is fire-and-forget (best-effort, at-most-once): a slow or failing
subscriber is logged and skipped so it cannot block the write path. Direct edits
under skills_folder DO fire it now, as op: "external" — a filesystem watch
supplies that, coalescing a burst into one event per kind. Read calls never fire
it, and neither does this worker's own writing twice (a create or update
sends its precise op, not an extra external). The watch is a doorbell, not a
ledger: every read re-scans disk, so a missed event costs a stale open view until
the next call, never data. For the event payload shape, call get function info
on the trigger type.