Documentation
¶
Overview ¶
Package embed handles embedding generation for repository chunks.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RunEmbedPipeline ¶
func RunEmbedPipeline(ctx context.Context, opts EmbedOptions) <-chan EmbedEvent
RunEmbedPipeline embeds all un-embedded chunks. Skips repos where embedded_hash == pushed_at_hash. Events are sent to the returned channel.
Types ¶
type EmbedEvent ¶
type EmbedEvent struct {
Type string // "batch", "repo_skip", "error", "done"
RepoFullName string // for repo_skip
BatchIndex int
BatchTotal int
ChunksEmbedded int
ChunksSkipped int
ChunksErrored int
TotalChunks int
Errors []string // error messages from the current batch
}
EmbedEvent represents a progress event from the embedding pipeline.
type EmbedOptions ¶
type EmbedOptions struct {
IncludeFileTree bool
BatchSize int // default 20, max 100
DB *sql.DB
EmbeddingProvider provider.EmbeddingProvider
}
EmbedOptions configures the embedding pipeline.
Click to show internal directories.
Click to hide internal directories.