Documentation
¶
Overview ¶
Package discovery starts one read-only agent session in the repo that names the sources a map should be built from, each with a kind and a reason. It has no appetite and no circuit breaker: init is never bounded (design 10 Q6). The session may read and search the repo's files and never writes. Checking what it names is gather's job, not this package's.
Index ¶
Constants ¶
const MaxNamed = 200
MaxNamed is how many sources a session may name; gather refuses the rest.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Result ¶
type Result struct {
Sources []Source
Model string
Tokens adapter.Tokens
// Malformed counts the entries, or the whole reply, that could not be
// read as a source; they are dropped.
Malformed int
}
Result is what a session ended with.
type Session ¶
type Session struct {
// Agent resolves the agent to run.
Agent func() (adapter.Adapter, error)
// Root is the repo's root, where the session runs.
Root string
// Progress, when set, receives one line before the session starts.
Progress io.Writer
}
Session is how a discovery session is run.