"...composable_kernel_rocm.git" did not exist on "3696fe1c76f50b2d16742632128c41f7869bc119"
Commit 8aa47ea6 authored by Timothy J. Baek's avatar Timothy J. Baek
Browse files

fix

parent 704f7e36
...@@ -7,6 +7,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ...@@ -7,6 +7,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
## [0.1.122] - 2024-04-27 ## [0.1.122] - 2024-04-27
### Added
- **🌟 Enhanced RAG Pipeline**: Now with hybrid searching via 'BM25', reranking powered by 'CrossEncoder', and configurable relevance score thresholds. - **🌟 Enhanced RAG Pipeline**: Now with hybrid searching via 'BM25', reranking powered by 'CrossEncoder', and configurable relevance score thresholds.
- **🛢️ External Database Support**: Seamlessly connect to custom SQLite or Postgres databases using the 'DATABASE_URL' environment variable. - **🛢️ External Database Support**: Seamlessly connect to custom SQLite or Postgres databases using the 'DATABASE_URL' environment variable.
- **🌐 Remote ChromaDB Support**: Introducing the capability to connect to remote ChromaDB servers. - **🌐 Remote ChromaDB Support**: Introducing the capability to connect to remote ChromaDB servers.
......
...@@ -28,6 +28,7 @@ log.setLevel(SRC_LOG_LEVELS["LITELLM"]) ...@@ -28,6 +28,7 @@ log.setLevel(SRC_LOG_LEVELS["LITELLM"])
from config import ( from config import (
ENABLE_LITELLM,
ENABLE_MODEL_FILTER, ENABLE_MODEL_FILTER,
MODEL_FILTER_LIST, MODEL_FILTER_LIST,
DATA_DIR, DATA_DIR,
...@@ -59,6 +60,8 @@ LITELLM_CONFIG_DIR = f"{DATA_DIR}/litellm/config.yaml" ...@@ -59,6 +60,8 @@ LITELLM_CONFIG_DIR = f"{DATA_DIR}/litellm/config.yaml"
with open(LITELLM_CONFIG_DIR, "r") as file: with open(LITELLM_CONFIG_DIR, "r") as file:
litellm_config = yaml.safe_load(file) litellm_config = yaml.safe_load(file)
app.state.ENABLE = ENABLE_LITELLM
app.state.CONFIG = litellm_config app.state.CONFIG = litellm_config
# Global variable to store the subprocess reference # Global variable to store the subprocess reference
...@@ -209,6 +212,8 @@ async def update_config(form_data: LiteLLMConfigForm, user=Depends(get_admin_use ...@@ -209,6 +212,8 @@ async def update_config(form_data: LiteLLMConfigForm, user=Depends(get_admin_use
@app.get("/models") @app.get("/models")
@app.get("/v1/models") @app.get("/v1/models")
async def get_models(user=Depends(get_current_user)): async def get_models(user=Depends(get_current_user)):
if app.state.ENABLE:
while not background_process: while not background_process:
await asyncio.sleep(0.1) await asyncio.sleep(0.1)
...@@ -254,6 +259,11 @@ async def get_models(user=Depends(get_current_user)): ...@@ -254,6 +259,11 @@ async def get_models(user=Depends(get_current_user)):
], ],
"object": "list", "object": "list",
} }
else:
return {
"data": [],
"object": "list",
}
@app.get("/model/info") @app.get("/model/info")
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment