mirror of
https://github.com/aljazceru/Auto-GPT.git
synced 2026-02-10 08:44:27 +01:00
init backend, fix frontend module (#307)
This commit is contained in:
4
.github/workflows/ci.yml
vendored
4
.github/workflows/ci.yml
vendored
@@ -278,10 +278,10 @@ jobs:
|
||||
poetry run python send_to_googledrive.py || echo "Failed to upload to Google Drive"
|
||||
echo "Adding skill_tree submodule to update website"
|
||||
poetry run agbenchmark start --mock
|
||||
cd agbenchmark/challenges/frontend
|
||||
cd frontend
|
||||
git add .
|
||||
git commit -m "Update website with new skill tree"
|
||||
cd ../../..
|
||||
cd ..
|
||||
exit 0
|
||||
else
|
||||
echo "Attempt $(($attempts + 1)) failed. Retrying..."
|
||||
|
||||
3
.gitmodules
vendored
3
.gitmodules
vendored
@@ -33,3 +33,6 @@
|
||||
[submodule "agbenchmark/challenges"]
|
||||
path = agbenchmark/challenges
|
||||
url = https://github.com/agbenchmark/agent-evals.git
|
||||
[submodule "frontend"]
|
||||
path = frontend
|
||||
url = https://github.com/agbenchmark/agbenchmark-frontend.git
|
||||
|
||||
Submodule agbenchmark/challenges updated: 9c9a35e0de...2ebe45f9c7
@@ -277,9 +277,7 @@ def graph_interactive_network(
|
||||
json_graph = json.dumps(graph_data)
|
||||
|
||||
# Optionally, save to a file
|
||||
with open(
|
||||
Path("agbenchmark/challenges/frontend/public/graph.json").resolve(), "w"
|
||||
) as f:
|
||||
with open(Path("frontend/public/graph.json").resolve(), "w") as f:
|
||||
f.write(json_graph)
|
||||
|
||||
if html_graph_path:
|
||||
|
||||
17
backend/main.py
Normal file
17
backend/main.py
Normal file
@@ -0,0 +1,17 @@
|
||||
from fastapi import FastAPI
|
||||
from fastapi.middleware.cors import CORSMiddleware
|
||||
|
||||
app = FastAPI()
|
||||
|
||||
app.add_middleware(
|
||||
CORSMiddleware,
|
||||
allow_origins=["*"],
|
||||
allow_credentials=True,
|
||||
allow_methods=["*"],
|
||||
allow_headers=["*"],
|
||||
)
|
||||
|
||||
|
||||
@app.get("/data")
|
||||
async def read_data() -> dict[str, str]:
|
||||
return {"data": "Hello, World!"}
|
||||
1
backend/requirements.txt
Normal file
1
backend/requirements.txt
Normal file
@@ -0,0 +1 @@
|
||||
fastapi
|
||||
1
frontend
Submodule
1
frontend
Submodule
Submodule frontend added at 7e468e488a
Reference in New Issue
Block a user