Codumentor logo Codumentor

Goals Plugin

The Goals plugin provides long-lived intents: a goal is a knowledge-base tree on disk plus one or more workers that fire on a cron task, share that knowledge base, and pursue the intent over time. You (or the agent, through tools) set up a goal once; the Task Tools runs its workers after that.

Ask the agent to create a goal, list yours, pause one, or inspect what a worker last wrote — or use the Goals page in the web UI (/plugins/goals, also reachable from a chat-header chip and a welcome-page widget). You do not talk to a worker directly: input goes through the goal tools, or through a message left in the workers' inboxes from the Goals page.

Configuration

plugins:
  - module: codumentor.plugins.goals
    class: GoalsPlugin
    priority: 10
    args:
      enabled: true
      default_timezone: UTC
      # storage_repo: my-repo   # optional; see Storage below
ParameterTypeDefaultDescription
enabledbooltrueEnable or disable the plugin.
default_timezonestring"UTC"IANA timezone for interpreting worker cron expressions.
storage_repostringunsetName of a configured repo (a key under repos) where goal trees are stored. When unset, falls back to the Agentic Memory plugin's repo, then to single-repo mode.
storage_pathstring"goals"Path under the resolved repo root for goal trees.
setup_agent.enabledboolfalseWhen true, setup_goal can draft the goal via a goal-role sub-agent and validate it before writing.
setup_agent.max_iterationsint12Re-prompt budget for that proposal.
commit_enabledbooltrueCommit each goal's knowledge-base subtree into git so state is never only an uncommitted working tree. Set to false for a non-git workspace — otherwise the plugin warns once that it cannot commit.
push_enabledbooltruePush after committing, through the Agentic Memory plugin's shared push path. Ignored when commit_enabled is false.
push_timeoutint30Push timeout in seconds.
push_max_consecutive_failuresint5Consecutive push failures before the circuit breaker opens.
commit_signaturestring"Made with Codumentor"Trailer appended to every goal commit.
flush_after_minutesint30Commit a running worker's subtree once its state has gone this long uncommitted, so a long tick does not hold everything until it ends. 0 disables the flush.
worker_denied_toolslistunsetReplaces the built-in list of general file tools hidden from goal workers. Omit to keep the built-in list; set [] to stop stripping file tools. Lifecycle tools and the allowed-subagents gate still apply.
target_agentsstring"main"Which agents get the goal tools: "main", "subagent", or "all". Default keeps create/delete/write off subagents.

Tools

The Goals tools are discovered on demand (they are not in the default tool list), so they do not clutter every turn.

ToolDescription
setup_goalCreate a goal: validate, write the knowledge-base tree, and register its cron workers
list_goalsList the caller's goals with status and worker summaries
get_goalRead a goal's definition, state, and live worker tasks
delete_goalCancel all worker tasks (optionally delete the knowledge base)
pause_goal / resume_goalHalt or restart every worker's cron ticks without deleting the goal
import_goalRe-register a goal tree copied into the storage root (restore/portability)
add_workerAdd a cron worker to an existing goal
remove_workerRemove one worker (task and its subtree)
run_worker_nowFire one worker immediately as a one-off
update_workerChange a worker's cron, instructions, role, allowed sub-agents, timeout_seconds, token_budget, or model_role
goal_kb_readRead a file from the goal knowledge base by goal-relative path
goal_kb_writeWrite a file in the goal knowledge base by goal-relative path
goal_kb_append_entryAppend one item to a YAML list in a knowledge-base file (for growing logs that are too large to rewrite whole)
goal_kb_listList files/directories under a goal knowledge-base sub-path

Web UI and HTTP API

The plugin ships a web bundle (ui/plugins/goals) and an API mounted at /ui/plugins/goals: a fleet view with a "needs you" queue, per-goal activity, workers, knowledge-base browser and setup tabs, a per-worker history page, a run drawer showing each tick's commit diff, and a new-goal wizard. The API calls the same operations as the tools, with the same ownership rule (a goal you do not own answers 404). It is repository-scoped: a user whose access profile lacks full repository access gets neither the page's data nor the header chip. Alert acknowledgments are per user and kept in the app data dir (goal_alert_acks.sqlite3; override with CODUMENTOR_GOALS_ACK_DB_PATH), never in the goal's knowledge base.

Storage

Goal trees must live inside a configured repo so that workers running under Workspace Isolation can see them. The location is resolved in order: explicit storage_repo → Agentic Memory's repo → single-repo mode. If none apply, the plugin errors rather than writing outside the configured repos.

Under workspace isolation, workers should use the goal_kb_* tools to read and write the goal's files. Those tools write the shared tree on disk; ordinary file tools in a sandboxed worker would not persist for the next tick.

Notes