INNER CODE UNIT · Go
configOpts
teilomillet/gollm · cmd/gollm/main.go:123
configOpts = append(configOpts, gollm.SetMaxRetries(*maxRetries))
configOpts = append(configOpts, gollm.SetRetryDelay(*retryDelay))
configOpts = append(configOpts, gollm.SetLogLevel(gollm.LogLevel(getLogLevel(*debugLevel))))
return configOpts
}
func printResponse(verbose bool, promptType, fullPrompt, rawPrompt, response, outputFormat string) {
if verbose {
if fullPrompt == "" {
fullPrompt = rawPrompt // For qa, cot, and summarize, we don't have access to the full prompt
}
fmt.Printf("Prompt Type: %s\nFull Prompt:\n%s\n\nResponse:\n---------\n", promptType, fullPrompt)
}
if outputFormat == "json" {
var jsonResponse interface{}
err := json.Unmarshal([]byte(response), &jsonResponse)