Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Switch from pypi to github for auto-gpt-plugin-template #4402

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
57 changes: 57 additions & 0 deletions autogpt/models/base_open_ai_plugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -197,3 +197,60 @@ def handle_chat_completion(
str: The resulting response.
"""
pass

def can_handle_text_embedding(self, text: str) -> bool:
"""This method is called to check that the plugin can
handle the text_embedding method.
Args:
text (str): The text to be convert to embedding.
Returns:
bool: True if the plugin can handle the text_embedding method."""
return False

def handle_text_embedding(self, text: str) -> list:
"""This method is called when the chat completion is done.
Args:
text (str): The text to be convert to embedding.
Returns:
list: The text embedding.
"""
pass

def can_handle_user_input(self, user_input: str) -> bool:
"""This method is called to check that the plugin can
handle the user_input method.

Args:
user_input (str): The user input.

Returns:
bool: True if the plugin can handle the user_input method."""
return False

def user_input(self, user_input: str) -> str:
"""This method is called to request user input to the user.

Args:
user_input (str): The question or prompt to ask the user.

Returns:
str: The user input.
"""

pass

def can_handle_report(self) -> bool:
"""This method is called to check that the plugin can
handle the report method.

Returns:
bool: True if the plugin can handle the report method."""
return False

def report(self, message: str) -> None:
"""This method is called to report a message to the user.

Args:
message (str): The message to report.
"""
pass
2 changes: 1 addition & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ pre-commit
black
isort
gitpython==3.1.31
auto-gpt-plugin-template
auto-gpt-plugin-template @ git+https://github.com/Significant-Gravitas/[email protected]
mkdocs
pymdown-extensions
mypy
Expand Down
Binary file modified tests/unit/data/test_plugins/Auto-GPT-Plugin-Test-master.zip
Binary file not shown.