Skip to content
This repository has been archived by the owner on Dec 6, 2023. It is now read-only.

Commit

Permalink
--model-path and --port
Browse files Browse the repository at this point in the history
  • Loading branch information
casperdcl committed Oct 24, 2023
1 parent a70a83b commit 821c16d
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions cht-llama-cpp/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,8 @@
MODEL_PATH = f"./ml/models/{os.getenv('MODEL_ID', 'mistral-7b-instruct-v0.1.Q5_0')}.gguf"
if __name__ == "__main__":
parser = argparse.ArgumentParser()
parser.add_argument("--model_path", help="Path to GGUF", default=MODEL_PATH)
parser.add_argument("--model-path", help="Path to GGUF", default=MODEL_PATH)
parser.add_argument("--port", help="Port to run model server on", type=int, default=8000)
args = parser.parse_args()
MODEL_PATH = args.model_path

Expand Down Expand Up @@ -51,4 +52,4 @@ def get_application() -> FastAPI:


if __name__ == "__main__":
uvicorn.run(app, host="0.0.0.0", port=8000)
uvicorn.run(app, host="0.0.0.0", port=args.port)

0 comments on commit 821c16d

Please sign in to comment.