Skip to content

AutoGPT is the vision of accessible AI for everyone, to use and to build on. Our mission is to provide the tools, so that you can focus on what matters.

Merge branch 'master' into fix-prompt-path

Toran Bruce Richardsc3288dcca8fa
diff --cc scripts/data.py
index bb4b296e4d,0a72cbbfc8..7969d69c30
--- a/scripts/data.py
+++ b/scripts/data.py
@@@ -1,12 -1,15 +1,17 @@@
+ import os
from pathlib import Path
--
+SRC_DIR = Path(__file__).parent
-
def load_prompt():
try:
+ # get directory of this file:
+ file_dir = Path(os.path.dirname(os.path.realpath(__file__)))
+ data_dir = file_dir / "data"
+ prompt_file = data_dir / "prompt.txt"
# Load the promt from data/prompt.txt
- with open(prompt_file, "r") as prompt_file:
++
+ with open(SRC_DIR/ "data/prompt.txt", "r") as prompt_file:
++
prompt = prompt_file.read()
return prompt