Fixed #1 by changing import statement, using factory function, and pinning the llama-cpp-python to 0.1.48
This commit is contained in:
parent
b1da9fb0e9
commit
7154fc276d
2 changed files with 4 additions and 3 deletions
|
@ -16,6 +16,7 @@ if __name__ == "__main__":
|
||||||
# Set environment variable before importing api server
|
# Set environment variable before importing api server
|
||||||
environ["MODEL"] = args.model
|
environ["MODEL"] = args.model
|
||||||
# Import api server
|
# Import api server
|
||||||
from llama_cpp.server import __main__ as server
|
from llama_cpp.server.app import create_app
|
||||||
# Run
|
# Run
|
||||||
uvicorn.run(server.app, host=args.host, port=args.port)
|
app = create_app()
|
||||||
|
uvicorn.run(app, host=args.host, port=args.port)
|
||||||
|
|
|
@ -1,3 +1,3 @@
|
||||||
llama-cpp-python[server]~=0.1.39
|
llama-cpp-python[server]==0.1.48
|
||||||
uvicorn~=0.22.0
|
uvicorn~=0.22.0
|
||||||
sanic~=23.3.0
|
sanic~=23.3.0
|
Reference in a new issue