This reverts commit d7cfa7f0b2.
This commit is contained in:
committed by
GitHub
parent
1e5b3f501f
commit
d54abc3ed0
@@ -9,7 +9,6 @@ import (
|
||||
"os"
|
||||
"strings"
|
||||
|
||||
"github.com/mudler/LocalAgent/pkg/metaform"
|
||||
"github.com/mudler/LocalAgent/pkg/xlog"
|
||||
"github.com/mudler/LocalAgent/services/actions"
|
||||
"github.com/sashabaranov/go-openai"
|
||||
@@ -53,44 +52,6 @@ func (t *Slack) AgentReasoningCallback() func(state agent.ActionCurrentState) bo
|
||||
}
|
||||
}
|
||||
|
||||
func (t *Slack) ConfigForm() metaform.Form {
|
||||
return metaform.Form{
|
||||
Fields: []metaform.Field{
|
||||
{
|
||||
Kind: metaform.FieldString,
|
||||
Name: "appToken",
|
||||
Label: "App Token",
|
||||
Required: true,
|
||||
Placeholder: "xapp-...",
|
||||
},
|
||||
{
|
||||
Kind: metaform.FieldString,
|
||||
Name: "botToken",
|
||||
Label: "Bot Token",
|
||||
Required: true,
|
||||
Placeholder: "xoxb-...",
|
||||
},
|
||||
{
|
||||
Kind: metaform.FieldString,
|
||||
Name: "channelID",
|
||||
Label: "Channel ID",
|
||||
Required: false,
|
||||
Placeholder: "C12345678",
|
||||
},
|
||||
{
|
||||
Kind: metaform.FieldOptions,
|
||||
Name: "alwaysReply",
|
||||
Label: "Always Reply",
|
||||
Required: false,
|
||||
Options: []metaform.Option{
|
||||
{Value: "false", Label: "Only when mentioned"},
|
||||
{Value: "true", Label: "Reply to all messages"},
|
||||
},
|
||||
},
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
func cleanUpUsernameFromMessage(message string, b *slack.AuthTestResponse) string {
|
||||
cleaned := strings.ReplaceAll(message, "<@"+b.UserID+">", "")
|
||||
cleaned = strings.ReplaceAll(cleaned, "<@"+b.BotID+">", "")
|
||||
|
||||
Reference in New Issue
Block a user