agents

package
v0.15.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 31, 2026 License: MIT Imports: 14 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package agents renders the five dispatched role definitions `orch render-agents` writes for every enabled host. Each file starts from the canonical definition embedded directly from its shipped adapter; rendering substitutes only the routing fields that host supports.

Index

Constants

View Source
const (
	ClaudeDir   = ".claude/agents"
	CodexDir    = ".codex/agents"
	OpenCodeDir = ".opencode/agents"
)

Project-local generated-agent destinations. Initialization and configuration add both to .gitignore whether or not both hosts are currently enabled, so enabling the other host later stays safe.

Variables

This section is empty.

Functions

func CodexInstructions added in v0.11.1

func CodexInstructions(role string) (string, error)

CodexInstructions returns the shipped role prose, without its default routing fields. The caller must already have an engine-approved execution selection. Architect has no dispatched definition and is deliberately unsupported.

func Destination added in v0.6.3

func Destination(host string) (string, error)

Destination returns host's repo-relative generated-agent directory.

func Stale added in v0.6.0

func Stale(repoRoot, host string, h *config.Host) ([]string, error)

Stale reports every definition for host that is absent, unreadable, or byte-different from Render's current output. Read errors are joined after every expected path has been checked so callers can name all of them at once.

func Write

func Write(repoRoot string, files []File) error

Write atomically writes files into their project directories, creating those directories if absent and overwriting existing files.

Types

type File

type File struct {
	Path    string
	Content []byte
}

File is one rendered project agent definition. Path is repo-relative and slash-form; Content is the fully substituted canonical body.

func Render

func Render(host string, h *config.Host) ([]File, error)

Render produces host's five project agent definitions in roleFiles order. h must be the enabled host's effective configuration.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL