Skip to main content

Module subagents

Module subagents 

Source
Expand description

Subagent profiles: named, user-defined agent personas that the orchestrating agent can delegate self-contained tasks to via the delegate_task tool (see crate::tools::delegate).

A profile is a Markdown file in ~/.openheim/agents/{name}.md, discovered the same way crate::rag::SkillsManager discovers skill files. The file may start with a +++-delimited TOML frontmatter block describing the profile; the rest of the file is used verbatim as the subagent’s system prompt.

+++
description = "Reviews code changes for correctness, security, and style."
model = "claude-haiku-4-5"
tools = ["read_file"]
max_iterations = 6
+++
You are a meticulous code reviewer focused on correctness and idiomatic style.

All frontmatter fields are optional. A file with no frontmatter is treated as a profile with an empty description whose entire contents form the system prompt.

Structs§

AgentProfile
A user-defined subagent persona loaded from ~/.openheim/agents/{name}.md.
SubagentLoader
Discovers and loads AgentProfiles from ~/.openheim/agents/.