Co-authored-by: Andy Li <55300002+cliandy@users.noreply.github.com> Co-authored-by: Kevin Lin <klin5061@gmail.com> Co-authored-by: Sarah Wooders <sarahwooders@gmail.com> Co-authored-by: jnjpng <jin@letta.com> Co-authored-by: Matthew Zhou <mattzh1314@gmail.com>
28 lines
899 B
Python
28 lines
899 B
Python
from typing import Literal
|
|
|
|
|
|
async def web_search(query: str) -> str:
|
|
"""
|
|
Search the web for information.
|
|
Args:
|
|
query (str): The query to search the web for.
|
|
Returns:
|
|
str: The search results.
|
|
"""
|
|
|
|
raise NotImplementedError("This is only available on the latest agent architecture. Please contact the Letta team.")
|
|
|
|
|
|
def run_code(code: str, language: Literal["python", "js", "ts", "r", "java"]) -> str:
|
|
"""
|
|
Run code in a sandbox. Supports Python, Javascript, Typescript, R, and Java.
|
|
|
|
Args:
|
|
code (str): The code to run.
|
|
language (Literal["python", "js", "ts", "r", "java"]): The language of the code.
|
|
Returns:
|
|
str: The output of the code, the stdout, the stderr, and error traces (if any).
|
|
"""
|
|
|
|
raise NotImplementedError("This is only available on the latest agent architecture. Please contact the Letta team.")
|