Liking cljdoc? Tell your friends :D

com.blockether.vis.internal.foundation.environment.core

vis-foundation — the agent's environment-awareness layer.

Owns the environment facts: cwd, user, platform, shell, plus:

  • git repository facts via the git binary (root, branch, dirty status, submodules, worktree),
  • a bounded language scan over the working tree (top languages by total bytes, primary language),
  • monorepo / multi-package shape detection (polylith, workspace, submodules) by counting per-ecosystem manifests.

Model-facing VCS/workspace truth lives in :session/workspace CTX. Remaining helpers cover coarse project shape (languages, monorepo, repositories) and cache invalidation (refresh!).

Runtime facts are computed lazily on first access and cached per working-directory. The cache is invalidated automatically when cwd changes between calls and explicitly by (refresh!).

vis-foundation — the agent's environment-awareness layer.

Owns the environment facts: cwd, user, platform, shell, plus:

  * git repository facts via the git binary (root, branch, dirty status,
    submodules, worktree),
  * a bounded language scan over the working tree (top languages
    by total bytes, primary language),
  * monorepo / multi-package shape detection (polylith, workspace,
    submodules) by counting per-ecosystem manifests.

Model-facing VCS/workspace truth lives in `:session/workspace` CTX.
Remaining helpers cover coarse project shape (`languages`,
`monorepo`, `repositories`) and cache invalidation (`refresh!`).

Runtime facts are computed lazily on first access and cached per
working-directory. The cache is invalidated automatically when
`cwd` changes between calls and explicitly by `(refresh!)`.
raw docstring

environment-ctxclj

(environment-ctx _environment)

Foundation-owned structured ctx contribution. Runtime facts, project guidance, and extension-load warnings live under (:project ctx).

Foundation-owned structured ctx contribution. Runtime facts, project
guidance, and extension-load warnings live under `(:project ctx)`.
sourceraw docstring

environment-promptclj

(environment-prompt _environment)
source

environment-symbolsclj

source

gitclj

(git)

await git() Returns {"root", "branch", "detached": bool, "submodules": bool, "worktree": bool, "stash_count", "upstream", "ahead", "behind", "stale", "dirty", "clean", "modified", "untracked", "added", "changed", "removed", "missing", "conflicting"}, or None outside a repo.

await git()
Returns {"root", "branch", "detached": bool, "submodules": bool, "worktree": bool, "stash_count", "upstream", "ahead", "behind", "stale", "dirty", "clean", "modified", "untracked", "added", "changed", "removed", "missing", "conflicting"}, or None outside a repo.
sourceraw docstring

languagesclj

(languages)

await languages() Returns {"total_files": N, "total_bytes": N, "primary": "clojure", "languages": [{"language", "files": N, "bytes": N, "files_pct", "bytes_pct"}, ...], "truncated": bool, "elapsed_ms": N}. List sorted by files desc.

await languages()
Returns {"total_files": N, "total_bytes": N, "primary": "clojure", "languages": [{"language", "files": N, "bytes": N, "files_pct", "bytes_pct"}, ...], "truncated": bool, "elapsed_ms": N}. List sorted by files desc.
sourceraw docstring

languages-symbolclj

source

main-agent-instructionsclj

(main-agent-instructions)

await main_agent_instructions() Returns {"found": True, "source", "path", "bytes": N, "content"} from AGENTS.md/CLAUDE.md, else {"found": False}. Check found first.

await main_agent_instructions()
Returns {"found": True, "source", "path", "bytes": N, "content"} from AGENTS.md/CLAUDE.md, else {"found": False}. Check found first.
sourceraw docstring

main-agent-instructions-symbolclj

source

monorepoclj

(monorepo)

await monorepo() Returns {"shape": "polylith"|"workspace"|"submodules"|None, "totals": {"clojure": N, ...}, "files": {"clojure": ["path/deps.edn", ...], ...}, "truncated": bool}. "shape" is None for single-package repos.

await monorepo()
Returns {"shape": "polylith"|"workspace"|"submodules"|None, "totals": {"clojure": N, ...}, "files": {"clojure": ["path/deps.edn", ...], ...}, "truncated": bool}. "shape" is None for single-package repos.
sourceraw docstring

monorepo-symbolclj

source

refresh!clj

(refresh!)

await refresh() Drop the cached env snapshot and recompute. Returns the fresh snapshot. Use after large tree/branch changes.

await refresh()
Drop the cached env snapshot and recompute. Returns the fresh snapshot. Use after large tree/branch changes.
sourceraw docstring

refresh!-symbolclj

source

repositoriesclj

(repositories)

await repositories() Returns {"count": N, "repositories": [{"path", "branch", "dirty": bool, "changes": bool, "stale": bool, "stash_count": N, ...}], "truncated": bool}.

await repositories()
Returns {"count": N, "repositories": [{"path", "branch", "dirty": bool, "changes": bool, "stale": bool, "stash_count": N, ...}], "truncated": bool}.
sourceraw docstring

repositories-symbolclj

source

snapshotclj

(snapshot)

Full environment snapshot map {:host :git :languages :monorepo :repositories}. Cached per cwd; host helper, not a model tool.

Full environment snapshot map {:host :git :languages :monorepo :repositories}. Cached per cwd; host helper, not a model tool.
sourceraw 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