Iodine98 / dora-back

A Python backend for Document Retrieval and Analysis (DoRA).
MIT License
0 stars 1 forks source link

Add sanitize_tool_name function to chatbot.py #7

Closed Iodine98 closed 7 months ago

Iodine98 commented 7 months ago

This pull request adds a new function called sanitize_tool_name to the chatbot.py file. The function sanitizes the tool name by replacing any characters that are not alphanumeric, underscore, or hyphen with a hyphen. This function is used in the create_tool function to ensure that the tool name is valid and follows the required format.