Skip to content

Commit

Permalink
feat: add Plugin-Dev flag
Browse files Browse the repository at this point in the history
  • Loading branch information
soulteary committed May 14, 2023
1 parent 7120dc9 commit 44b4cf4
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
9 changes: 6 additions & 3 deletions internal/api/account/account.go
Original file line number Diff line number Diff line change
Expand Up @@ -101,13 +101,16 @@ func GetFeatures() []string {
features = append(features, GetModelSwitcherFeatures()...)
features = append(features, GetPluginFeatures()...)

if define.DEV_MODE {
if define.DEV_MODE || define.ENABLE_PLUGIN_PLUGIN_DEV {
features = append(features, datatypes.FEATURE_DEBUG)
features = append(features, datatypes.FEATURE_PLIGIN_PLUGIN_ADMIN)
features = append(features, datatypes.FEATURE_PLIGIN_PLUGIN_DEV)
}

if define.DEV_MODE {
features = append(features, datatypes.FEATURE_SHAREABLE_LINKS)
// OpenAI internal debugging interface
// features = append(features, datatypes.FEATURE_SYSTEM_MESSAGE2)
features = append(features, datatypes.FEATURE_PLIGIN_PLUGIN_ADMIN)
features = append(features, datatypes.FEATURE_PLIGIN_PLUGIN_DEV)
}
return features
}
Expand Down
1 change: 1 addition & 0 deletions internal/define/define.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ var (
NEW_TOOLS_USER = GetBool("NEW_TOOLS_USER", false) // New tools user

ENABLE_PLUGIN = GetBool("ENABLE_PLUGIN", false) // Enable the plugin
ENABLE_PLUGIN_PLUGIN_DEV = GetBool("ENABLE_PLUGIN_PLUGIN_DEV", false) // Enable the plugin
ENABLE_PLUGIN_BROWSING = GetBool("ENABLE_PLUGIN_BROWSING", false) // Enable the plugin, Browsing
ENABLE_PLUGIN_CODE_INTERPRETER = GetBool("ENABLE_PLUGIN_CODE_INTERPRETER", false) // Enable the plugin, CodeInterpreter
)
Expand Down

0 comments on commit 44b4cf4

Please sign in to comment.