autofix

package
v2.29.0 Latest Latest
Warning

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

Go to latest
Published: Aug 25, 2026 License: Apache-2.0 Imports: 13 Imported by: 1

Documentation

Index

Constants

View Source
const (
	AIProviderFlagHelp = `` /* 466-byte string literal not displayed */

	AIPrompt = `` /* 175-byte string literal not displayed */

)
View Source
const (
	ModelClaudeOpus4_7   = anthropic.ModelClaudeOpus4_7
	ModelClaudeOpus4_6   = anthropic.ModelClaudeOpus4_6
	ModelClaudeSonnet4_6 = anthropic.ModelClaudeSonnet4_6
	ModelClaudeOpus4_5   = anthropic.ModelClaudeOpus4_5_20251101
	ModelClaudeSonnet4_5 = anthropic.ModelClaudeSonnet4_5_20250929
	ModelClaudeHaiku4_5  = anthropic.ModelClaudeHaiku4_5_20251001
)
View Source
const (
	ModelGPT5_4          = openai.ChatModelGPT5_4
	ModelGPT5_4Mini      = openai.ChatModelGPT5_4Mini
	ModelGPT5_4Nano      = openai.ChatModelGPT5_4Nano
	DefaultOpenAIBaseURL = "https://api.openai.com/v1"
)

Variables

This section is empty.

Functions

func GenerateSolution

func GenerateSolution(model, aiAPIKey, baseURL string, skipSSL bool, issues []*issue.Issue) (err error)

GenerateSolution generates a solution for the given issues using the specified AI provider

Types

type GenAIClient

type GenAIClient interface {
	GenerateSolution(ctx context.Context, prompt string) (string, error)
}

func NewClaudeClient added in v2.22.9

func NewClaudeClient(model, apiKey string) (GenAIClient, error)

func NewGeminiClient added in v2.22.9

func NewGeminiClient(model, apiKey string) (GenAIClient, error)

func NewOpenAIClient added in v2.22.11

func NewOpenAIClient(config OpenAIConfig) (GenAIClient, error)

type GenAIModel added in v2.22.9

type GenAIModel string

https://ai.google.dev/gemini-api/docs/models

const (
	ModelGeminiPro3         GenAIModel = "gemini-3-pro-preview"
	ModelGeminiPro2_5       GenAIModel = "gemini-2.5-pro"
	ModelGeminiFlash2_5     GenAIModel = "gemini-2.5-flash"
	ModelGeminiFlash2_5Lite GenAIModel = "gemini-2.5-flash-lite"
)

type OpenAIConfig added in v2.22.11

type OpenAIConfig struct {
	Model       string
	APIKey      string `json:"-"`
	BaseURL     string
	MaxTokens   int
	Temperature float64
	SkipSSL     bool
}

Jump to

Keyboard shortcuts

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