prompt

package
v0.6.2 Latest Latest
Warning

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

Go to latest
Published: Mar 21, 2026 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Build

func Build(opts BuildOptions) string

Build assembles a system prompt by reading workspace bootstrap files.

Types

type BuildOptions

type BuildOptions struct {
	WorkspaceDir         string // path to workspace root
	SubAgent             bool   // if true, only inject AGENTS.md and TOOLS.md
	Query                string
	ProjectID            string
	SessionID            string
	MemorySearcher       memory.Searcher
	ForceRelevantMemory  bool
	StaticBudgetTokens   int
	RelevantBudgetTokens int
	TotalBudgetTokens    int
}

BuildOptions configures system prompt generation.

type BuildResult

type BuildResult struct {
	Prompt              string
	StaticTokens        int
	RelevantTokens      int
	RelevantMemoryCount int
	TotalTokens         int
}

BuildResult captures prompt assembly output and budget usage.

func BuildResultFor

func BuildResultFor(opts BuildOptions) BuildResult

BuildResultFor assembles a system prompt and returns budget usage details.

Jump to

Keyboard shortcuts

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