Skip to content

Commit

Permalink
Set /render huggingface to not use model cache (#102)
Browse files Browse the repository at this point in the history
  • Loading branch information
Kardbord authored Apr 29, 2023
1 parent c219542 commit fddd8b4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion kardbot/render.go
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ func handleHfSubCmd(s *discordgo.Session, i *discordgo.InteractionCreate, opts [

img, imgFmt, err := hfapigo.SendTextToImageRequest(model, &hfapigo.TextToImageRequest{
Inputs: fmt.Sprintf("%s%s", modelKeyWords[rand.Intn(len(modelKeyWords))], prompt),
Options: *hfapigo.NewOptions().SetWaitForModel(true),
Options: *hfapigo.NewOptions().SetWaitForModel(true).SetUseCache(false),
})
if err != nil {
// TODO: detect if error is invalid model, and report to user instead of owner.
Expand Down

0 comments on commit fddd8b4

Please sign in to comment.