Skip to content

armgit / camel

Public Imported from GitHub
0

🐫 CAMEL: The first and the best multi-agent framework. Finding the Scaling Law of Agents. https://www.camel-ai.org

Auto-update documentation after merge [skip ci]

camel-docs-bot2e749e1982b6
diff --git a/docs/mintlify/reference/camel.toolkits.excel_toolkit.mdx b/docs/mintlify/reference/camel.toolkits.excel_toolkit.mdx
index f0daefd20..e70c1ca64 100644
--- a/docs/mintlify/reference/camel.toolkits.excel_toolkit.mdx
+++ b/docs/mintlify/reference/camel.toolkits.excel_toolkit.mdx
@@ -23,7 +23,7 @@ Markdown formatted table.
def __init__(
self,
timeout: Optional[float] = None,
- file_path: Optional[str] = None
+ working_directory: Optional[str] = None
):
```
@@ -32,7 +32,7 @@ Initializes a new instance of the ExcelToolkit class.
**Parameters:**
- **timeout** (Optional[float]): The timeout value for API requests in seconds. If None, no timeout is applied. (default: :obj:`None`)
-- **file_path** (Optional[str]): Path to an existing Excel file to load. (default: :obj:`None`)
+- **working_directory** (str, optional): The default directory for output files. If not provided, it will be determined by the `CAMEL_WORKDIR` environment variable (if set). If the environment variable is not set, it defaults to `camel_working_dir`.
<a id="camel.toolkits.excel_toolkit.ExcelToolkit._validate_file_path"></a>
@@ -102,19 +102,37 @@ positions
### _save_workbook
```python
-def _save_workbook(self, file_path: Optional[str] = None):
+def _save_workbook(self, file_path: str):
```
Save the current workbook to file.
**Parameters:**
-- **file_path** (Optional[str]): The path to save the workbook. If None, uses self.file_path.
+- **file_path** (str): The path to save the workbook.
**Returns:**
str: Success or error message.
+<a id="camel.toolkits.excel_toolkit.ExcelToolkit.save_workbook"></a>
+
+### save_workbook
+
+```python
+def save_workbook(self, filename: str):
+```
+
+Save the current in-memory workbook to a file.
+
+**Parameters:**
+
+- **filename** (str): The filename to save the workbook. Must end with .xlsx extension. The file will be saved in self. working_directory.
+
+**Returns:**
+
+ str: Success message or error details.
+
<a id="camel.toolkits.excel_toolkit.ExcelToolkit.create_workbook"></a>
### create_workbook
@@ -122,7 +140,7 @@ Save the current workbook to file.
```python
def create_workbook(
self,
- file_path: str,
+ filename: Optional[str] = None,
sheet_name: Optional[str] = None,
data: Optional[List[List[Union[str, int, float, None]]]] = None
):
@@ -135,7 +153,7 @@ toolkit to work with the new file and optionally adds initial data.
**Parameters:**
-- **file_path** (str): Where to save the new Excel file. Must end with . xlsx.
+- **filename** (Optional[str]): The filename for the workbook. Must end with .xlsx extension. The file will be saved in self.working_directory. (default: :obj:`None`)
- **sheet_name** (Optional[str]): Name for the first sheet. If None, creates "Sheet1". (default: :obj:`None`)
- **data** (Optional[List[List[Union[str, int, float, None]]]]): Initial data as rows. Each inner list is one row. (default: :obj:`None`)
@@ -148,18 +166,18 @@ toolkit to work with the new file and optionally adds initial data.
### delete_workbook
```python
-def delete_workbook(self, file_path: Optional[str] = None):
+def delete_workbook(self, filename: str):
```
-Delete a spreadsheet file.
+Delete a spreadsheet file from the working directory.
**Parameters:**
-- **file_path** (Optional[str]): The path of the file to delete. If None, uses self.file_path.
+- **filename** (str): The filename to delete. Must end with .xlsx extension. The file will be deleted from self. working_directory.
**Returns:**
- str: Success message.
+ str: Success message or error details.
<a id="camel.toolkits.excel_toolkit.ExcelToolkit.create_sheet"></a>
@@ -432,7 +450,7 @@ Use this to update multiple cells at once with a 2D array of data.
### export_sheet_to_csv
```python
-def export_sheet_to_csv(self, sheet_name: str, csv_path: str):
+def export_sheet_to_csv(self, sheet_name: str, csv_filename: str):
```
Export a specific sheet to CSV format.
@@ -443,7 +461,7 @@ data exchange.
**Parameters:**
- **sheet_name** (str): Name of the sheet to export.
-- **csv_path** (str): File path where CSV will be saved.
+- **csv_filename** (str): Filename for the CSV file. Must end with .csv extension. The file will be saved in self.working_directory.
**Returns:**
diff --git a/docs/mintlify/reference/camel.toolkits.message_integration.mdx b/docs/mintlify/reference/camel.toolkits.message_integration.mdx
index b570835b4..7cd348a45 100644
--- a/docs/mintlify/reference/camel.toolkits.message_integration.mdx
+++ b/docs/mintlify/reference/camel.toolkits.message_integration.mdx
@@ -77,12 +77,12 @@ def get_message_tool(self):
FunctionTool: The message sending tool.
-<a id="camel.toolkits.message_integration.ToolkitMessageIntegration.add_messaging_to_toolkit"></a>
+<a id="camel.toolkits.message_integration.ToolkitMessageIntegration.register_toolkits"></a>
-### add_messaging_to_toolkit
+### register_toolkits
```python
-def add_messaging_to_toolkit(
+def register_toolkits(
self,
toolkit: BaseToolkit,
tool_names: Optional[List[str]] = None
@@ -107,12 +107,25 @@ The tools will accept optional messaging parameters:
The toolkit with messaging capabilities added
-<a id="camel.toolkits.message_integration.ToolkitMessageIntegration.add_messaging_to_functions"></a>
+<a id="camel.toolkits.message_integration.ToolkitMessageIntegration._create_bound_method_wrapper"></a>
-### add_messaging_to_functions
+### _create_bound_method_wrapper
```python
-def add_messaging_to_functions(
+def _create_bound_method_wrapper(self, enhanced_func: Callable, toolkit_instance):
+```
+
+Create a wrapper that mimics a bound method for _clone_tools.
+
+This wrapper preserves the toolkit instance reference while maintaining
+the enhanced messaging functionality.
+
+<a id="camel.toolkits.message_integration.ToolkitMessageIntegration.register_functions"></a>
+
+### register_functions
+
+```python
+def register_functions(
self,
functions: Union[List[FunctionTool], List[Callable]],
function_names: Optional[List[str]] = None