Liking cljdoc? Tell your friends :D

com.blockether.vis.internal.foundation.harness.discovery

Cross-HARNESS discovery of agents + skills — the sibling of the shell layer's POSIX compat, for the agent/skill definitions vis' OWN project dir and OTHER AI coding harnesses (Claude Code, pi, opencode, the agents standard, …) leave on disk.

An AGENT is a markdown file with YAML-ish --- frontmatter (name, description, model, tools) + a body that IS a system prompt. A SKILL is a SKILL.md (same frontmatter, name+description) in its own directory, alongside bundled resource files.

Discovery is PURE except for the directory scan: parse-frontmatter, parse-agent, parse-skill-meta, and dedup-by-name take strings and are unit-tested without the filesystem; the discover-* fns walk the known source roots. Precedence is source ORDER, first-name-wins (vis project-local > other harnesses' project > user > plugin; Vis and Claude before pi/agents/opencode).

Cross-HARNESS discovery of agents + skills — the sibling of the shell
layer's POSIX compat, for the agent/skill definitions vis' OWN project dir
and OTHER AI coding harnesses (Claude Code, pi, opencode, the agents
standard, …) leave on disk.

An AGENT is a markdown file with YAML-ish `---` frontmatter
(`name`, `description`, `model`, `tools`) + a body that IS a system
prompt. A SKILL is a `SKILL.md` (same frontmatter, name+description) in
its own directory, alongside bundled resource files.

Discovery is PURE except for the directory scan: `parse-frontmatter`,
`parse-agent`, `parse-skill-meta`, and `dedup-by-name` take strings and
are unit-tested without the filesystem; the `discover-*` fns walk the
known source roots. Precedence is source ORDER, first-name-wins
(vis project-local > other harnesses' project > user > plugin; Vis and
Claude before pi/agents/opencode).
raw docstring

agent-dirsclj

(agent-dirs)

Ordered [tool ^File dir] pairs for agents (existing dirs only).

Ordered `[tool ^File dir]` pairs for agents (existing dirs only).
raw docstring

agent-sourcesclj


agentsclj

(agents)

all-skillsclj

(all-skills)

Discovered skills before availability filtering, for human settings only. Registers the settings switch of each skill that has one.

Discovered skills before availability filtering, for human settings only. Registers
the settings switch of each skill that has one.
raw docstring

command-dirsclj

(command-dirs)

Ordered [tool ^File dir] pairs for commands (existing dirs only).

Ordered `[tool ^File dir]` pairs for commands (existing dirs only).
raw docstring

command-sourcesclj

Cross-HARNESS COMMAND (prompt-template) dirs — markdown prompts a user invokes as /<name> [args], $ARGUMENTS-substituted. Vis' OWN commands are the .vis/prompts FILE templates (prompt-templates ns, highest precedence); these rows add the OTHER harnesses' command dirs. Precedence = ORDER.

Cross-HARNESS COMMAND (prompt-template) dirs — markdown prompts a user
invokes as `/<name> [args]`, `$ARGUMENTS`-substituted. Vis' OWN commands are
the `.vis/prompts` FILE templates (prompt-templates ns, highest precedence);
these rows add the OTHER harnesses' command dirs. Precedence = ORDER.
raw docstring

commandsclj

(commands)

dedup-by-nameclj

(dedup-by-name entries)

First occurrence of each :name wins (precedence = input order).

First occurrence of each `:name` wins (precedence = input order).
raw docstring

discover-agentsclj

(discover-agents)

Parse every agent file across agent-dirs, first-name-wins, tagged by tool.

Parse every agent file across `agent-dirs`, first-name-wins, tagged by tool.
raw docstring

discover-commandsclj

(discover-commands)

Parse every command markdown across command-dirs, first-name-wins, tagged by tool. Each entry's :body IS the prompt template ($ARGUMENTS-aware at expand time); :model/:tools frontmatter is carried through but currently unused.

Parse every command markdown across `command-dirs`, first-name-wins, tagged by
tool. Each entry's `:body` IS the prompt template (`$ARGUMENTS`-aware at expand
time); `:model`/`:tools` frontmatter is carried through but currently unused.
raw docstring

discover-skillsclj

(discover-skills)

Parse every project, nested-project, user, and plugin SKILL.md in precedence order, then registered package skills. First name wins, including explicit local overrides of qualified package/skill names. Repository-local skills carry :project-root, which makes their slash-expanded turn execute from the project that owns the skill.

Parse every project, nested-project, user, and plugin SKILL.md in precedence
order, then registered package skills. First name wins, including explicit
local overrides of qualified package/skill names. Repository-local skills carry
`:project-root`, which
makes their slash-expanded turn execute from the project that owns the skill.
raw docstring

generationclj

(generation)

How many times THIS workspace's agents, skills and commands have actually been re-read. A cheap freshness token — it costs the stat pass ensure! already pays and changes exactly when the discovered set would, which is what lets the doc corpus memoize entries built from skills.

How many times THIS workspace's agents, skills and commands have actually
been re-read. A cheap freshness token — it costs the stat pass `ensure!`
already pays and changes exactly when the discovered set would, which is
what lets the doc corpus memoize entries built from `skills`.
raw docstring

known-toolsclj

Every harness tag a source row can carry. A skill an installed extension package ships is tagged :vis-package instead, outside this set.

Every harness tag a source row can carry. A skill an installed extension
package ships is tagged `:vis-package` instead, outside this set.
raw docstring

own-setting?clj

(own-setting? skill)

True when skill has its own availability switch in settings. A packaged skill declared with settings = false has none: its extension's Auto/On/Off decides.

True when `skill` has its own availability switch in settings. A packaged skill
declared with `settings = false` has none: its extension's Auto/On/Off decides.
raw docstring

parse-agentclj

(parse-agent content {:keys [name-default tool path]})

Build an agent entry from raw markdown content. name-default (the filename stem) backs a missing frontmatter name. Returns nil when there is no usable name. tool/path are provenance, carried through verbatim.

Build an agent entry from raw markdown `content`. `name-default` (the
filename stem) backs a missing frontmatter `name`. Returns nil when there
is no usable name. `tool`/`path` are provenance, carried through verbatim.
raw docstring

parse-frontmatterclj

(parse-frontmatter content)

Split a markdown doc into {:meta {kw str} :body str}. A leading ----fenced block is parsed as key: value lines; a line with no key: head CONTINUES the previous value (folded multi-line description). Values pass through fold-value. No frontmatter → {:meta {} :body <whole>}. Keys are lower-cased keywords.

Split a markdown doc into `{:meta {kw str} :body str}`. A leading
`---`-fenced block is parsed as `key: value` lines; a line with no
`key:` head CONTINUES the previous value (folded multi-line description).
Values pass through `fold-value`. No frontmatter → `{:meta {} :body
<whole>}`. Keys are lower-cased keywords.
raw docstring

parse-skill-metaclj

(parse-skill-meta content {:keys [name-default tool dir path]})

Build a skill entry (sans :resources) from a SKILL.md content. name-default is the skill directory name. dir/tool/path are provenance. Returns nil when there is no usable name.

Build a skill entry (sans `:resources`) from a SKILL.md `content`.
`name-default` is the skill directory name. `dir`/`tool`/`path` are
provenance. Returns nil when there is no usable name.
raw docstring

read-package-skillsclj

(read-package-skills snapshot metadata)

Read the explicitly declared skills from an admitted package snapshot. Names are package/skill; duplicate names fail the entire load. Resource files remain beside SKILL.md. No project-root: a procedure never changes the workspace. An entry declared with settings = false gets :settings? false: it has no switch of its own and follows its extension instead.

Read the explicitly declared skills from an admitted package snapshot.
Names are package/skill; duplicate names fail the entire load. Resource files
remain beside SKILL.md. No project-root: a procedure never changes the workspace.
An entry declared with `settings = false` gets `:settings? false`: it has no
switch of its own and follows its extension instead.
raw docstring

reload!clj

(reload!)

Rescan every workspace-root cache on its next access, then return the active workspace's {:agents :skills :commands} discovery result.

Rescan every workspace-root cache on its next access, then return the active
workspace's `{:agents :skills :commands}` discovery result.
raw docstring

skill-enabled?clj

(skill-enabled? env skill)
(skill-enabled? env skill live)

Live gate for one discovered skill. A skill from a configuration tier that the session does not read is off. A skill without its own switch follows its extension: Off removes it, Auto and On keep it. Pass a delay of [[scoped/live-values]] when checking several skills.

Live gate for one discovered skill. A skill from a configuration tier that the
session does not read is off. A skill without its own switch follows its
extension: Off removes it, Auto and On keep it. Pass a delay of
[[scoped/live-values]] when checking several skills.
raw docstring

skill-sourcesclj


skillsclj

(skills)

Only skills available to this callback's session, including exact-name doc reads.

Only skills available to this callback's session, including exact-name doc reads.
raw docstring

cljdoc builds & hosts documentation for Clojure/Script libraries

Keyboard shortcuts
Ctrl+kJump to recent docs
←Move to previous article
→Move to next article
Ctrl+/Jump to the search field
× close