Help us shape the future of Go! Take the 2026 Go Developer Survey

prompt

package
v0.0.4 Latest Latest
Warning

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

Go to latest
Published: Mar 22, 2025 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Completion

type Completion openai.ChatCompletion

func PromptExecSummary

func PromptExecSummary(ctx context.Context, params *ExecSummaryPromptParams) (*Completion, error)

func PromptSummary

func PromptSummary(ctx context.Context, params *SummaryPromptParams) (*Completion, error)

func PromptUser

func PromptUser(ctx context.Context, params *UserPromptParams) (*Completion, error)

func (*Completion) Content

func (c *Completion) Content() (string, error)

func (*Completion) Message

func (c *Completion) Message() (openai.ChatCompletionMessage, error)

func (*Completion) RequestToks

func (c *Completion) RequestToks() int

func (*Completion) ResponseToks

func (c *Completion) ResponseToks() int

func (*Completion) TotalToks

func (c *Completion) TotalToks() int

type ExecSummaryPromptParams

type ExecSummaryPromptParams struct {
	Client      *client.Ref
	CommandLine string
	ExitCode    int
	Output      execx.ProcessOutput
}

type SummaryPromptParams

type SummaryPromptParams struct {
	Messages []openai.ChatCompletionMessageParamUnion
}

type UserPromptParams

type UserPromptParams struct {
	Client   *client.Ref
	Messages []openai.ChatCompletionMessageParamUnion
	Tools    []openai.ChatCompletionToolParam
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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