Skip to content

Commit

Permalink
improve docs
Browse files Browse the repository at this point in the history
  • Loading branch information
Josh-XT committed Jun 27, 2024
1 parent 55b66c5 commit 169a178
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 10 deletions.
1 change: 1 addition & 0 deletions docs/1-Getting started/0-Quick Start.md
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,7 @@ The script supports setting any of the environment variables via command-line ar
37. `--log-format`: Set the log format (default: `%(asctime)s | %(levelname)s | %(message)s`)
38. `--uvicorn-workers`: Set the number of Uvicorn workers (default: `10`)
39. `--agixt-auto-update`: Enable or disable auto-updates (default: `true`)
40. `--with-streamlit`: Enable or disable the Streamlit UI (default: `true`)

Options specific to ezLocalai:

Expand Down
15 changes: 5 additions & 10 deletions start.py
Original file line number Diff line number Diff line change
Expand Up @@ -244,6 +244,9 @@ def set_environment(env_updates=None):
)
with open(".env", "w") as file:
file.write(env_file_content)
if str(env_vars["WITH_EZLOCALAI"]).lower() == "true":
print("Starting ezLocalai, this can take several minutes...")
start_ezlocalai()
dockerfile = "docker-compose.yml"
if env_vars["AGIXT_BRANCH"] != "stable":
dockerfile = "docker-compose-dev.yml"
Expand Down Expand Up @@ -400,12 +403,6 @@ def start_ezlocalai():
if __name__ == "__main__":
check_prerequisites()
parser = argparse.ArgumentParser(description="AGiXT Environment Setup")
parser.add_argument(
"--with-ezlocalai",
help="Start EZLocalAI",
action="store_true",
required=False,
)
# Add arguments for each environment variable
for key, value in get_default_env_vars().items():
parser.add_argument(
Expand All @@ -423,16 +420,14 @@ def start_ezlocalai():
# Check if .env file exists and if AGIXT_AUTO_UPDATE is not set via command line
if not os.path.exists(".env") and "AGIXT_AUTO_UPDATE" not in env_updates:
auto_update = prompt_user(
"Would you like AGiXT to auto update? (Y for yes, N for no)", "y"
"Would you like AGiXT to auto update when this script is run in the future? (Y for yes, N for no)",
"y",
)
if auto_update.lower() == "y" or auto_update.lower() == "yes":
auto_update = "true"
else:
auto_update = "false"
env_updates["AGIXT_AUTO_UPDATE"] = auto_update
if args.with_ezlocalai == True:
print("Starting ezLocalai, this can take several minutes...")
start_ezlocalai()
# Apply updates and restart server
print("Please wait while AGiXT is starting, this can take several minutes...")
set_environment(env_updates=env_updates)

0 comments on commit 169a178

Please sign in to comment.