Skip to content

armgit / E2B

Public Imported from GitHub
0

Open-source, secure environment with real-world tools for enterprise-grade agents.

Merge branch 'master' of https://github.com/devbookhq/ai-api

Tomas Valentad67001fff606
diff --cc api-service/app.py
index 70b92fd60,d85af650d..c28f41cd6
--- a/api-service/app.py
+++ b/api-service/app.py
@@@ -47,14 -48,13 +47,13 @@@ async def generate()
method = body["method"]
route = body["route"]
-
await db.create_deployment(run_id=run_id, project_id=project_id, route_id=route_id)
playground = None
+
try:
# Create playground for the LLM
- envs = await db.get_env_vars(project_id)
playground_tools, playground = create_playground_tools(
- envs=envs,
+ get_envs=lambda:db.get_env_vars(project_id),
route=route,
method=method,
request_body_template=get_request_body_template(blocks),