generator

package
v0.1.0-beta.2 Latest Latest
Warning

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

Go to latest
Published: Aug 14, 2025 License: MIT Imports: 16 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

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DependencyManager

type DependencyManager interface {
	AddDependencies(ctx context.Context, projectPath, language string, operationsData *types.OperationsData, req types.GenerationRequest) error
	ValidateProjectStructure(projectPath, language string) error
	GetRequiredDependencies(language string, operationsData *types.OperationsData) ([]dependencyTypes.Dependency, error)
}

OrchestratedTemplateStrategy composes the template strategy with dependency management and entry-point injection. It enables unit testing the template strategy separately.

type EntryPointInjector

type EntryPointInjector interface {
	DetectEntryPoints(projectPath string, language string) ([]domain.EntryPoint, error)
	InjectOtelInitialization(ctx context.Context, entryPoint *domain.EntryPoint, operationsData *types.OperationsData, req types.GenerationRequest) ([]string, error)
}

type Generator

type Generator struct {
	// contains filtered or unexported fields
}

Generator extends the detector system for code generation

func NewGenerator

func NewGenerator(codebaseAnalyzer *detector.CodebaseAnalyzer, logger logger.Logger) (*Generator, error)

NewGenerator creates a new code generator

func (*Generator) Generate

func (g *Generator) Generate(ctx context.Context, req types.GenerationRequest) error

GenerateInstrumentation analyzes and generates code

func (*Generator) GetDefaultStrategy

func (g *Generator) GetDefaultStrategy() types.GenerationMode

GetDefaultStrategy returns the default generation strategy

func (*Generator) ListAvailableAgents

func (g *Generator) ListAvailableAgents() []agents.Agent

ListAvailableAgents returns all detected coding agents

func (*Generator) ListAvailableStrategies

func (g *Generator) ListAvailableStrategies() map[types.GenerationMode]bool

ListAvailableStrategies returns all available generation strategies

func (*Generator) ListAvailableTemplates

func (g *Generator) ListAvailableTemplates() []string

ListAvailableTemplates returns all available templates

type OrchestratedTemplateStrategy

type OrchestratedTemplateStrategy struct {
	// contains filtered or unexported fields
}

func (*OrchestratedTemplateStrategy) GenerateCode

func (s *OrchestratedTemplateStrategy) GenerateCode(ctx context.Context, opportunities []domain.Opportunity, req types.GenerationRequest) error

func (*OrchestratedTemplateStrategy) GetName

func (s *OrchestratedTemplateStrategy) GetName() string

func (*OrchestratedTemplateStrategy) GetRequiredFlags

func (s *OrchestratedTemplateStrategy) GetRequiredFlags() []string

func (*OrchestratedTemplateStrategy) IsAvailable

func (s *OrchestratedTemplateStrategy) IsAvailable() bool

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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