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
|
||||
environ["MODEL"] = args.model
|
||||
# Import api server
|
||||
from llama_cpp.server import __main__ as server
|
||||
from llama_cpp.server.app import create_app
|
||||
# Run
|
||||
uvicorn.run(server.app, host=args.host, port=args.port)
|
||||
app = create_app()
|
||||
uvicorn.run(app, host=args.host, port=args.port)
|
||||
|
|
Reference in a new issue