mirror of
https://github.com/aljazceru/Auto-GPT.git
synced 2025-12-19 23:14:25 +01:00
Do not load disabled commands (faster exec & benchmark runs) (#5078)
* Use modern material theme for docs * Do not load disabled commands * black . --------- Co-authored-by: lc0rp <2609411+lc0rp@users.noreply.github.com>
This commit is contained in:
@@ -22,7 +22,7 @@ def bootstrap_agent(task):
|
||||
config.continuous_mode = False
|
||||
config.temperature = 0
|
||||
config.plain_output = True
|
||||
command_registry = get_command_registry(config)
|
||||
command_registry = CommandRegistry.with_command_modules(COMMAND_CATEGORIES, config)
|
||||
config.memory_backend = "no_memory"
|
||||
config.workspace_path = Workspace.init_workspace_directory(config)
|
||||
config.file_logger_path = Workspace.build_file_logger_path(config.workspace_path)
|
||||
@@ -39,13 +39,3 @@ def bootstrap_agent(task):
|
||||
config=config,
|
||||
triggering_prompt=DEFAULT_TRIGGERING_PROMPT,
|
||||
)
|
||||
|
||||
|
||||
def get_command_registry(config: Config):
|
||||
command_registry = CommandRegistry()
|
||||
enabled_command_categories = [
|
||||
x for x in COMMAND_CATEGORIES if x not in config.disabled_command_categories
|
||||
]
|
||||
for command_category in enabled_command_categories:
|
||||
command_registry.import_commands(command_category)
|
||||
return command_registry
|
||||
|
||||
Reference in New Issue
Block a user