Directories
¶
| Path | Synopsis |
|---|---|
|
Package agent is the public, embeddable SDK for driving a golder agent from your own Go program.
|
Package agent is the public, embeddable SDK for driving a golder agent from your own Go program. |
|
cmd
|
|
|
golder
command
Command golder is the CLI entry point for the golder agent.
|
Command golder is the CLI entry point for the golder agent. |
|
examples
|
|
|
extensions/demo-mcp
command
A pure-Go MCP fixture: no Node, no business service and no credentials.
|
A pure-Go MCP fixture: no Node, no business service and no credentials. |
|
extensions/demo-plugin
command
A minimal legacy-v1 plugin.
|
A minimal legacy-v1 plugin. |
|
sdk/01-minimal
command
Command 01-minimal is the smallest possible golder SDK program: create a session, send one prompt, print the reply.
|
Command 01-minimal is the smallest possible golder SDK program: create a session, send one prompt, print the reply. |
|
sdk/02-streaming
command
Command 02-streaming prints the assistant's reply incrementally as it is generated, instead of waiting for the whole message.
|
Command 02-streaming prints the assistant's reply incrementally as it is generated, instead of waiting for the whole message. |
|
sdk/03-model-thinking
command
Command 03-model-thinking shows how to pick a model and set the reasoning-effort ("thinking") level.
|
Command 03-model-thinking shows how to pick a model and set the reasoning-effort ("thinking") level. |
|
sdk/04-system-prompt
command
Command 04-system-prompt customizes the agent's behavior with a system prompt.
|
Command 04-system-prompt customizes the agent's behavior with a system prompt. |
|
sdk/05-tools
command
Command 05-tools demonstrates the tool policy: restrict the agent to an allowlist, remove specific tools with a denylist (deny always wins), and inspect the resulting tool set with ToolNames.
|
Command 05-tools demonstrates the tool policy: restrict the agent to an allowlist, remove specific tools with a denylist (deny always wins), and inspect the resulting tool set with ToolNames. |
|
sdk/06-conversation
command
Command 06-conversation shows multi-turn state: a single session remembers the earlier exchange, so a follow-up prompt can refer back to it.
|
Command 06-conversation shows multi-turn state: a single session remembers the earlier exchange, so a follow-up prompt can refer back to it. |
|
sdk/07-provider
command
Command 07-provider points the SDK at a non-default provider.
|
Command 07-provider points the SDK at a non-default provider. |
|
Package extension defines the stable, protocol-independent vocabulary of a golder extension.
|
Package extension defines the stable, protocol-independent vocabulary of a golder extension. |
|
plugin
Package plugin provides a Go server for golder's existing stdio plugin v1 protocol.
|
Package plugin provides a Go server for golder's existing stdio plugin v1 protocol. |
|
setup
Package setup defines the small operator-only setup event stream.
|
Package setup defines the small operator-only setup event stream. |
|
internal
|
|
|
agentcore
Package agentcore defines the core "leaf" data types and control flow for the golder agent harness, a Go reimplementation of the pi agent loop.
|
Package agentcore defines the core "leaf" data types and control flow for the golder agent harness, a Go reimplementation of the pi agent loop. |
|
agenttool
This file implements the apply_patch tool: one call carries a whole patch (add / update / move / delete, any number of files) in the codex apply_patch format.
|
This file implements the apply_patch tool: one call carries a whole patch (add / update / move / delete, any number of files) in the codex apply_patch format. |
|
browserctl
Package browserctl talks to a running browser over its owner-only Unix-domain control socket.
|
Package browserctl talks to a running browser over its owner-only Unix-domain control socket. |
|
browserstartup
Package browserstartup carries bounded startup diagnostics between a browser pane and its launcher.
|
Package browserstartup carries bounded startup diagnostics between a browser pane and its launcher. |
|
cli
Package cli is the contract and shared-type layer for golder's command-line surface.
|
Package cli is the contract and shared-type layer for golder's command-line surface. |
|
cli/btw
This file implements the /btw command (mirrors Claude Code's /btw and the pi agent extension @narumitw/pi-btw): a throwaway "side thread" for asking the model a quick side question that must NOT pollute the main conversation.
|
This file implements the /btw command (mirrors Claude Code's /btw and the pi agent extension @narumitw/pi-btw): a throwaway "side thread" for asking the model a quick side question that must NOT pollute the main conversation. |
|
cli/config
Package config implements golder's optional user config file at $GOLDER_HOME/config.toml (~/.golder/config.toml by default) plus the provider-agnostic base-url env-var name derivation.
|
Package config implements golder's optional user config file at $GOLDER_HOME/config.toml (~/.golder/config.toml by default) plus the provider-agnostic base-url env-var name derivation. |
|
cli/dreamcmd
Package dreamcmd holds the CLI-side plumbing shared by the REPL and the TUI for the /dream memory-consolidation command: spawning the process-isolated `golder --dream` child, detecting a live consolidation lock, parsing the dry-run flag, and rendering the returned Report.
|
Package dreamcmd holds the CLI-side plumbing shared by the REPL and the TUI for the /dream memory-consolidation command: spawning the process-isolated `golder --dream` child, detecting a live consolidation lock, parsing the dry-run flag, and rendering the returned Report. |
|
cli/extensioncmd
Package extensioncmd is the shared text command surface for the CLI, REPL and TUI.
|
Package extensioncmd is the shared text command surface for the CLI, REPL and TUI. |
|
cli/goal
This file implements the /goal command (mirrors pi-goal / Claude Code's goal mode): given a high-level objective, golder runs the agent autonomously — re-prompting it turn after turn from the loop's follow-up seam — until the model declares the goal done (goal_complete), reports a true impasse (goal_blocked), or a safety guard (max turns / no-progress) or the token budget stops it.
|
This file implements the /goal command (mirrors pi-goal / Claude Code's goal mode): given a high-level objective, golder runs the agent autonomously — re-prompting it turn after turn from the loop's follow-up seam — until the model declares the goal done (goal_complete), reports a true impasse (goal_blocked), or a safety guard (max turns / no-progress) or the token budget stops it. |
|
cli/headless
This file is the headless run driver: the print / stream-json run path (US-020) extracted from the CLI dispatch seam (#363).
|
This file is the headless run driver: the print / stream-json run path (US-020) extracted from the CLI dispatch seam (#363). |
|
cli/hostcmd
Package hostcmd implements the `golder host-compat` subcommand family: what the terminal multiplexer around this process sees, and the one file that makes tuios recognise a golder pane at all.
|
Package hostcmd implements the `golder host-compat` subcommand family: what the terminal multiplexer around this process sees, and the one file that makes tuios recognise a golder pane at all. |
|
cli/memstatus
This file implements the /memory slash command (US-011, FR-20, #484) that prints a colored report describing the persistent memory store and the infinite-context state: entry counts by scope, the current context window and auto-compaction trigger point, current context usage, and checkpoint status.
|
This file implements the /memory slash command (US-011, FR-20, #484) that prints a colored report describing the persistent memory store and the infinite-context state: entry counts by scope, the current context window and auto-compaction trigger point, current context usage, and checkpoint status. |
|
cli/prompts
Package prompts holds the slash-command registry assembly shared by the REPL (internal/cli/repl) and the forthcoming TUI (internal/cli/tui).
|
Package prompts holds the slash-command registry assembly shared by the REPL (internal/cli/repl) and the forthcoming TUI (internal/cli/tui). |
|
cli/repl
This file implements the manual `/dream` REPL command (SPEC §4.1, US-007): it spawns the process-isolated memory-consolidation subprocess (`golder --dream [--dream-dry-run] -C <projectDir>`) and renders the returned Report as a full-table change report.
|
This file implements the manual `/dream` REPL command (SPEC §4.1, US-007): it spawns the process-isolated memory-consolidation subprocess (`golder --dream [--dream-dry-run] -C <projectDir>`) and renders the returned Report as a full-table change report. |
|
cli/run
This file is the single assembly point for a session's tool gates: the trust gate, the workspace-boundary gate and the permission gate, composed once and installed on every run of the session — the main run, a /goal or /btw side run, and any sub-agent they dispatch.
|
This file is the single assembly point for a session's tool gates: the trust gate, the workspace-boundary gate and the permission gate, composed once and installed on every run of the session — the main run, a /goal or /btw side run, and any sub-agent they dispatch. |
|
cli/sessioncmd
Package sessioncmd implements the `golder session` subcommand family (issue #570): sharing persisted sessions from the command line, without entering the REPL.
|
Package sessioncmd implements the `golder session` subcommand family (issue #570): sharing persisted sessions from the command line, without entering the REPL. |
|
cli/status
This file implements the /status slash command (US-002, #292) that prints a colored multi-section status report with runtime config, context usage, and more.
|
This file implements the /status slash command (US-002, #292) that prints a colored multi-section status report with runtime config, context usage, and more. |
|
cli/testutil
Package testutil holds test helpers shared across the internal/cli subpackages.
|
Package testutil holds test helpers shared across the internal/cli subpackages. |
|
cli/tui
Package tui hosts the full-screen terminal UI for golder's interactive mode (US-001).
|
Package tui hosts the full-screen terminal UI for golder's interactive mode (US-001). |
|
cli/ui
Package ui holds the leaf terminal-UI helpers shared across the cmd/golder and internal/cli subpackages: ANSI color gating (color.go), turn-end Markdown rendering (markdown.go), and prompt image-reference parsing (imageref.go).
|
Package ui holds the leaf terminal-UI helpers shared across the cmd/golder and internal/cli subpackages: ANSI color gating (color.go), turn-end Markdown rendering (markdown.go), and prompt image-reference parsing (imageref.go). |
|
cli/workspacecmd
Package workspacecmd implements `golder workspace`: the command line that manages global named terminal sessions, each with an independent daemon.
|
Package workspacecmd implements `golder workspace`: the command line that manages global named terminal sessions, each with an independent daemon. |
|
compaction
This file (US-003) ties the compaction pieces together: given a message list and settings, it finds the cut point, extracts file operations from the summarized range, generates the structured summary, and returns a CompactionResult ready to be persisted as a session compaction entry and used to rebuild the agent context.
|
This file (US-003) ties the compaction pieces together: given a message list and settings, it finds the cut point, extracts file operations from the summarized range, generates the structured summary, and returns a CompactionResult ready to be persisted as a session compaction entry and used to rebuild the agent context. |
|
compactionlog
Package compactionlog persists auto-compaction attempts for diagnosis.
|
Package compactionlog persists auto-compaction attempts for diagnosis. |
|
contextbudget
Package contextbudget is a leaf package (standard library only) holding the live context-window budget of one run: how many tokens the conversation has used against the model's window, whether a low-budget reminder has been delivered, and whether the model has asked to continue in a fresh window.
|
Package contextbudget is a leaf package (standard library only) holding the live context-window budget of one run: how many tokens the conversation has used against the model's window, whether a low-budget reminder has been delivered, and whether the model has asked to continue in a fresh window. |
|
controlcap
Package controlcap describes the effects of the terminal and browser facades.
|
Package controlcap describes the effects of the terminal and browser facades. |
|
diagtrace
Package diagtrace is golder's one opt-in diagnostic log, shared by the process-start path and the full-screen TUI.
|
Package diagtrace is golder's one opt-in diagnostic log, shared by the process-start path and the full-screen TUI. |
|
dream
Package dream implements the /dream memory-consolidation feature's foundation layer: the resolved dream configuration, on-disk run state, and the deterministic due-check that decides whether an auto-trigger is warranted.
|
Package dream implements the /dream memory-consolidation feature's foundation layer: the resolved dream configuration, on-disk run state, and the deterministic due-check that decides whether an auto-trigger is warranted. |
|
execsess
Package execsess manages shell sessions: OS processes that outlive a single tool call so their output can be polled and their process group controlled (interrupt / kill).
|
Package execsess manages shell sessions: OS processes that outlive a single tool call so their output can be polled and their process group controlled (interrupt / kill). |
|
extensions
Package extensions owns the host-side extension boundary.
|
Package extensions owns the host-side extension boundary. |
|
golderhome
Package golderhome resolves golder's state root, in one place.
|
Package golderhome resolves golder's state root, in one place. |
|
grants
Package grants is the single authorization table: which paths golder may read, write, and run side-effect tools in — and for how long.
|
Package grants is the single authorization table: which paths golder may read, write, and run side-effect tools in — and for how long. |
|
grants/grantstest
Package grantstest installs an empty authorization table for a test.
|
Package grantstest installs an empty authorization table for a test. |
|
history
Package history persists the global, append-only prompt history shared by golder's interactive front-ends (the TUI for now).
|
Package history persists the global, append-only prompt history shared by golder's interactive front-ends (the TUI for now). |
|
hooks
Package hooks implements golder's user-extensible lifecycle hook system: a config-driven way to run shell commands at agent lifecycle points (tool calls, prompt submission, session start/end, etc.) without writing Go or compiling a plugin.
|
Package hooks implements golder's user-extensible lifecycle hook system: a config-driven way to run shell commands at agent lifecycle points (tool calls, prompt submission, session start/end, etc.) without writing Go or compiling a plugin. |
|
hostcompat
Package hostcompat reports golder's state to a terminal multiplexer that tracks coding agents — golder's own workspace, tuios and herdr — so golder shows up beside claude, codex and the rest without any of them shipping an integration for it.
|
Package hostcompat reports golder's state to a terminal multiplexer that tracks coding agents — golder's own workspace, tuios and herdr — so golder shows up beside claude, codex and the rest without any of them shipping an integration for it. |
|
jev
Package jev calls TypeSafe's System One model — a decision model that answers typed questions with calibrated probabilities instead of generating text.
|
Package jev calls TypeSafe's System One model — a decision model that answers typed questions with calibrated probabilities instead of generating text. |
|
jsonrpc
Package jsonrpc implements a minimal JSON-RPC 2.0 client over a subprocess's stdio (US-014/#116).
|
Package jsonrpc implements a minimal JSON-RPC 2.0 client over a subprocess's stdio (US-014/#116). |
|
memory
Package memory implements the persistent memory storage layer for golder.
|
Package memory implements the persistent memory storage layer for golder. |
|
patch
Package patch implements the apply_patch DSL: a stripped-down, file-oriented diff format carried by one tool call, so a single invocation can add, update, move, and delete files.
|
Package patch implements the apply_patch DSL: a stripped-down, file-oriented diff format carried by one tool call, so a single invocation can add, update, move, and delete files. |
|
permissions
Package permissions defines golder's approval modes and the live, mutable state that tracks the active one.
|
Package permissions defines golder's approval modes and the live, mutable state that tracks the active one. |
|
plugin
This file bridges the agent's event stream to subscribed plugins (US-017, #133).
|
This file bridges the agent's event stream to subscribed plugins (US-017, #133). |
|
privatepath
Package privatepath creates and checks the directories and files golder keeps one person's state in, and refuses to use anything that is not theirs.
|
Package privatepath creates and checks the directories and files golder keeps one person's state in, and refuses to use anything that is not theirs. |
|
provider
This file implements the Anthropic Messages API streaming decoder (US-008).
|
This file implements the Anthropic Messages API streaming decoder (US-008). |
|
redact
Package redact implements golder's embedded data-loss-prevention layer: it finds credential-shaped values in text that is about to enter the model's context (tool output, prompts, compaction summaries, memory) and replaces them with stable placeholders before the provider ever sees them.
|
Package redact implements golder's embedded data-loss-prevention layer: it finds credential-shaped values in text that is about to enter the model's context (tool output, prompts, compaction summaries, memory) and replaces them with stable placeholders before the provider ever sees them. |
|
remotecontrol
Package remotecontrol implements the /remote-control feature: an in-process web server that lets a phone on the same LAN mirror the CLI session, inject prompts, and approve risky tool calls (see tasks/spec-remote-control.md).
|
Package remotecontrol implements the /remote-control feature: an in-process web server that lets a phone on the same LAN mirror the CLI session, inject prompts, and approve risky tool calls (see tasks/spec-remote-control.md). |
|
reviewpolicy
Package reviewpolicy decides HOW a tool call is reviewed, not whether it is safe.
|
Package reviewpolicy decides HOW a tool call is reviewed, not whether it is safe. |
|
runtime
This file implements shell-style argument tokenization for prompt templates (US-001, #331).
|
This file implements shell-style argument tokenization for prompt templates (US-001, #331). |
|
seatbelt
Package seatbelt confines bash execution with the OS sandbox: macOS sandbox-exec, Linux bubblewrap (bwrap); platforms without a runner compile to an unavailable stub.
|
Package seatbelt confines bash execution with the OS sandbox: macOS sandbox-exec, Linux bubblewrap (bwrap); platforms without a runner compile to an unavailable stub. |
|
selfupdate
This file caches the latest-release check so golder's startup banner can show "update available" without a network call on every launch (US-004, FR-10).
|
This file caches the latest-release check so golder's startup banner can show "update available" without a network call on every launch (US-004, FR-10). |
|
session
This file implements session export/import (US-008, #124): a session can be exported to a self-contained JSONL or HTML file, and a JSONL export can be imported back as a fresh, resumable session.
|
This file implements session export/import (US-008, #124): a session can be exported to a self-contained JSONL or HTML file, and a JSONL export can be imported back as a fresh, resumable session. |
|
shellfacts
Package shellfacts describes what a shell command will do, parsed rather than guessed at.
|
Package shellfacts describes what a shell command will do, parsed rather than guessed at. |
|
terminalstate
Package terminalstate preserves the host's kernel TTY state across an embedded terminal UI, including failures before its event loop starts.
|
Package terminalstate preserves the host's kernel TTY state across an embedded terminal UI, including failures before its event loop starts. |
|
toolworker
Package toolworker runs file tools in a fresh, per-call OS sandbox.
|
Package toolworker runs file tools in a fresh, per-call OS sandbox. |
|
trust
This file holds the interactive pieces of project trust (US-018, #134).
|
This file holds the interactive pieces of project trust (US-018, #134). |
|
tuiosctl
Package tuiosctl is golder's narrow Go client for the tuios daemon's line-delimited JSON protocol.
|
Package tuiosctl is golder's narrow Go client for the tuios daemon's line-delimited JSON protocol. |
|
webhook
This file implements the GitHub ready-for-review webhook (issue #567, ported from dsh's GitHub review sessions): an opt-in, isolated HTTP endpoint that turns a PR's draft→ready transition into a read-only review session.
|
This file implements the GitHub ready-for-review webhook (issue #567, ported from dsh's GitHub review sessions): an opt-in, isolated HTTP endpoint that turns a PR's draft→ready transition into a read-only review session. |
|
workspace
Package workspace owns golder's integrated terminal workspace.
|
Package workspace owns golder's integrated terminal workspace. |
|
plugins
|
|
|
lark
Package lark contains the static instruction assets distributed with the plugin.
|
Package lark contains the static instruction assets distributed with the plugin. |
|
lark/cmd/golder-lark
command
|
|
|
lark/internal/larkmcp
Package larkmcp is the host-independent Lark/Project MCP adapter.
|
Package larkmcp is the host-independent Lark/Project MCP adapter. |
Click to show internal directories.
Click to hide internal directories.

