Spaces:
Running
on
Zero
Running
on
Zero
test
Browse files- Makefile +3 -0
- babyagi/babyagi.py +6 -0
- chat_history.db +0 -0
- controllers/gpt_enginner20240623182411 +1 -0
- controllers/gpt_enginner20240623182505 +1 -0
- mysite/routers/fastapi.py +15 -6
Makefile
CHANGED
@@ -47,6 +47,9 @@ run:
|
|
47 |
@echo -e "$(COLOR_CYAN)Running GPT Engineer on $(COLOR_GREEN)$(name)$(COLOR_CYAN) folder...$(COLOR_RESET)" && \
|
48 |
cd ./gpt-engineer && poetry run gpt-engineer /home/user/app/controllers/$(name) --model Llama3-70b-8192 --temperature 0.1
|
49 |
|
|
|
|
|
|
|
50 |
install:
|
51 |
@echo -e "$(COLOR_CYAN)Running GPT Engineer on $(COLOR_GREEN)$(name)$(COLOR_CYAN) folder...$(COLOR_RESET)" && \
|
52 |
cd ./gpt-engineer && pip install poetry && make install
|
|
|
47 |
@echo -e "$(COLOR_CYAN)Running GPT Engineer on $(COLOR_GREEN)$(name)$(COLOR_CYAN) folder...$(COLOR_RESET)" && \
|
48 |
cd ./gpt-engineer && poetry run gpt-engineer /home/user/app/controllers/$(name) --model Llama3-70b-8192 --temperature 0.1
|
49 |
|
50 |
+
runbabyagi:
|
51 |
+
cd ./babyagi && python babyagi $(name)
|
52 |
+
|
53 |
install:
|
54 |
@echo -e "$(COLOR_CYAN)Running GPT Engineer on $(COLOR_GREEN)$(name)$(COLOR_CYAN) folder...$(COLOR_RESET)" && \
|
55 |
cd ./gpt-engineer && pip install poetry && make install
|
babyagi/babyagi.py
CHANGED
@@ -35,6 +35,9 @@ import os
|
|
35 |
import pkgutil
|
36 |
import async_timeout
|
37 |
import asyncio
|
|
|
|
|
|
|
38 |
|
39 |
|
40 |
DESCRIPTION = """
|
@@ -159,6 +162,9 @@ JOIN_EXISTING_OBJECTIVE = False
|
|
159 |
OBJECTIVE = "ボットの性能をよくする方法 日本語で説明"
|
160 |
OBJECTIVE = f"""チャットボットでの広告展開"""
|
161 |
|
|
|
|
|
|
|
162 |
INITIAL_TASK = os.getenv("INITIAL_TASK", os.getenv("FIRST_TASK", ""))
|
163 |
|
164 |
# Model configuration
|
|
|
35 |
import pkgutil
|
36 |
import async_timeout
|
37 |
import asyncio
|
38 |
+
import sys
|
39 |
+
|
40 |
+
args = sys.argv
|
41 |
|
42 |
|
43 |
DESCRIPTION = """
|
|
|
162 |
OBJECTIVE = "ボットの性能をよくする方法 日本語で説明"
|
163 |
OBJECTIVE = f"""チャットボットでの広告展開"""
|
164 |
|
165 |
+
print(args[0])
|
166 |
+
OBJECTIVE = args[0]
|
167 |
+
|
168 |
INITIAL_TASK = os.getenv("INITIAL_TASK", os.getenv("FIRST_TASK", ""))
|
169 |
|
170 |
# Model configuration
|
chat_history.db
CHANGED
Binary files a/chat_history.db and b/chat_history.db differ
|
|
controllers/gpt_enginner20240623182411
ADDED
@@ -0,0 +1 @@
|
|
|
|
|
1 |
+
Subproject commit d852967a9cc1a8dcb1180475cc0e2d803733d6f7
|
controllers/gpt_enginner20240623182505
ADDED
@@ -0,0 +1 @@
|
|
|
|
|
1 |
+
Subproject commit 4bb2a563d93efe3547e2445b06bf02e9de0d93e9
|
mysite/routers/fastapi.py
CHANGED
@@ -252,12 +252,21 @@ def setup_webhook_routes(app: FastAPI):
|
|
252 |
send_google_chat_card(webhook_url, title, subtitle, link_text, link_url)
|
253 |
#########################################################################
|
254 |
from babyagi.babyagi import completion
|
255 |
-
|
256 |
-
|
257 |
-
|
258 |
-
|
259 |
-
|
260 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
261 |
|
262 |
#return
|
263 |
#return
|
|
|
252 |
send_google_chat_card(webhook_url, title, subtitle, link_text, link_url)
|
253 |
#########################################################################
|
254 |
from babyagi.babyagi import completion
|
255 |
+
proc = subprocess.Popen(
|
256 |
+
["make", "runbabyagi", res],
|
257 |
+
stdin=subprocess.PIPE,
|
258 |
+
stdout=subprocess.PIPE,
|
259 |
+
stderr=subprocess.PIPE,
|
260 |
+
text=True,
|
261 |
+
)
|
262 |
+
|
263 |
+
|
264 |
+
#prompt_res_agi = completion("日本語で下記のプランを考えて "+res)
|
265 |
+
#title = f""" タスク作成 再度考える {promps}"""
|
266 |
+
#subtitle = prompt_res_agi
|
267 |
+
#link_text = "データを確認する"
|
268 |
+
#link_url = "https://kenken999-php.hf.space/diamondprice_list.php"
|
269 |
+
#send_google_chat_card(webhook_url, title, subtitle, link_text, link_url)
|
270 |
|
271 |
#return
|
272 |
#return
|