mirror of
https://github.com/ParisNeo/lollms.git
synced 2025-02-28 20:05:51 +00:00
changed custom function calls folder
This commit is contained in:
parent
d13e7f8070
commit
3fa30ab47e
@ -82,7 +82,6 @@ class LollmsPaths:
|
|||||||
self.personal_ttm_services_path = self.personal_services_path / "ttm"
|
self.personal_ttm_services_path = self.personal_services_path / "ttm"
|
||||||
|
|
||||||
self.apps_zoo_path = self.personal_path / "apps_zoo"
|
self.apps_zoo_path = self.personal_path / "apps_zoo"
|
||||||
self.custom_functions_zoo_path = self.personal_path / "functions_zoo"
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@ -90,7 +89,7 @@ class LollmsPaths:
|
|||||||
self.gptqlora_path = self.personal_trainers_path / "gptqlora"
|
self.gptqlora_path = self.personal_trainers_path / "gptqlora"
|
||||||
|
|
||||||
self.custom_personalities_path = self.personal_path / "custom_personalities"
|
self.custom_personalities_path = self.personal_path / "custom_personalities"
|
||||||
self.custom_function_calls_path = self.personal_path / "custom_function_calls"
|
self.custom_function_calls_path = self.personal_path / "custom_function_calls"
|
||||||
self.custom_voices_path = self.personal_path / "custom_voices"
|
self.custom_voices_path = self.personal_path / "custom_voices"
|
||||||
|
|
||||||
self.binding_models_paths = []
|
self.binding_models_paths = []
|
||||||
@ -273,7 +272,7 @@ class LollmsPaths:
|
|||||||
self.custom_voices_path.mkdir(parents=True, exist_ok=True)
|
self.custom_voices_path.mkdir(parents=True, exist_ok=True)
|
||||||
|
|
||||||
self.apps_zoo_path.mkdir(parents=True, exist_ok=True)
|
self.apps_zoo_path.mkdir(parents=True, exist_ok=True)
|
||||||
self.custom_functions_zoo_path.mkdir(parents=True, exist_ok=True)
|
self.custom_function_calls_path.mkdir(parents=True, exist_ok=True)
|
||||||
|
|
||||||
|
|
||||||
if not self.bindings_zoo_path.exists():
|
if not self.bindings_zoo_path.exists():
|
||||||
|
@ -47,7 +47,7 @@ from pathlib import Path
|
|||||||
async def list_function_calls():
|
async def list_function_calls():
|
||||||
"""List all available function calls in the functions zoo and custom functions zoo"""
|
"""List all available function calls in the functions zoo and custom functions zoo"""
|
||||||
functions_zoo_path = lollmsElfServer.lollms_paths.functions_zoo_path
|
functions_zoo_path = lollmsElfServer.lollms_paths.functions_zoo_path
|
||||||
custom_functions_zoo_path = lollmsElfServer.lollms_paths.custom_functions_zoo_path
|
custom_function_calls_path = lollmsElfServer.lollms_paths.custom_function_calls_path
|
||||||
function_calls = []
|
function_calls = []
|
||||||
|
|
||||||
# Helper function to process a directory and append function calls
|
# Helper function to process a directory and append function calls
|
||||||
@ -109,8 +109,8 @@ async def list_function_calls():
|
|||||||
process_directory(category_dir, category_dir.name)
|
process_directory(category_dir, category_dir.name)
|
||||||
|
|
||||||
# Process the custom functions zoo under the "custom" category
|
# Process the custom functions zoo under the "custom" category
|
||||||
if custom_functions_zoo_path.exists():
|
if custom_function_calls_path.exists():
|
||||||
process_directory(custom_functions_zoo_path, "custom")
|
process_directory(custom_function_calls_path, "custom")
|
||||||
|
|
||||||
return {"function_calls": function_calls}
|
return {"function_calls": function_calls}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user