Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

top_p/check_hybrid #43

Merged
merged 1 commit into from
Nov 15, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 7 additions & 7 deletions app/src/modules/metadata.py
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ def ll_models():
"openai_compat": False,
"context_length": 127072,
"temperature": [0.3, 0.3, 0.0, 2.0],
"top_p": [0.75, 0.75, 0.0, 1.0],
"top_p": [1.0, 1.0, 0.0, 1.0],
"max_tokens": [100, 100, 1, 4096],
"frequency_penalty": [0.0, 0.0, -1.0, 1.0],
"presence_penalty": [0.0, 0.0, -2.0, 2.0],
Expand All @@ -108,7 +108,7 @@ def ll_models():
"openai_compat": True,
"context_length": 4191,
"temperature": [1.0, 1.0, 0.0, 2.0],
"top_p": [0.9, 0.9, 0.0, 1.0],
"top_p": [1.0, 1.0, 0.0, 1.0],
"max_tokens": [256, 256, 1, 4096],
"frequency_penalty": [0.0, 0.0, -1.0, 1.0],
"presence_penalty": [0.0, 0.0, -2.0, 2.0],
Expand All @@ -121,7 +121,7 @@ def ll_models():
"openai_compat": True,
"context_length": 127072,
"temperature": [1.0, 1.0, 0.0, 2.0],
"top_p": [0.9, 0.9, 0.0, 1.0],
"top_p": [1.0, 1.0, 0.0, 1.0],
"max_tokens": [256, 256, 1, 4096],
"frequency_penalty": [0.0, 0.0, -1.0, 1.0],
"presence_penalty": [0.0, 0.0, -2.0, 2.0],
Expand All @@ -134,7 +134,7 @@ def ll_models():
"openai_compat": True,
"context_length": 127072,
"temperature": [1.0, 1.0, 0.0, 2.0],
"top_p": [0.9, 0.9, 0.0, 1.0],
"top_p": [1.0, 1.0, 0.0, 1.0],
"max_tokens": [256, 256, 1, 8191],
"frequency_penalty": [0.0, 0.0, -1.0, 1.0],
"presence_penalty": [0.0, 0.0, -2.0, 2.0],
Expand All @@ -147,7 +147,7 @@ def ll_models():
"openai_compat": True,
"context_length": 127072,
"temperature": [1.0, 1.0, 0.0, 2.0],
"top_p": [0.9, 0.9, 0.0, 1.0],
"top_p": [1.0, 1.0, 0.0, 1.0],
"max_tokens": [256, 256, 1, 4095],
"frequency_penalty": [0.0, 0.0, -1.0, 1.0],
"presence_penalty": [0.0, 0.0, -2.0, 2.0],
Expand All @@ -160,7 +160,7 @@ def ll_models():
"openai_compat": False,
"context_length": 127072,
"temperature": [0.2, 0.2, 0.0, 2.0],
"top_p": [0.9, 0.9, 0.0, 1.0],
"top_p": [1.0, 1.0, 0.0, 1.0],
"max_tokens": [256, 256, 1, 28000],
"frequency_penalty": [0.0, 0.0, -1.0, 1.0],
"presence_penalty": [0.0, 0.0, -2.0, 2.0],
Expand All @@ -173,7 +173,7 @@ def ll_models():
"openai_compat": False,
"context_length": 127072,
"temperature": [0.2, 0.2, 0.0, 2.0],
"top_p": [0.9, 0.9, 0.0, 1.0],
"top_p": [1.0, 1.0, 0.0, 1.0],
"max_tokens": [256, 256, 1, 28000],
"frequency_penalty": [0.0, 0.0, -1.0, 1.0],
"presence_penalty": [0.0, 0.0, -2.0, 2.0],
Expand Down
8 changes: 3 additions & 5 deletions app/src/modules/st_common.py
Original file line number Diff line number Diff line change
Expand Up @@ -436,11 +436,9 @@ def create_zip(state_dict_filt, provider):
# Check if the conf is full ollama or openai, currently supported for springai export
def check_hybrid_conf(session_state_json):

embedding_models = meta.embedding_models()
chat_models = meta.ll_models()

embModel = embedding_models.get(session_state_json["rag_params"].get("model"))
chatModel = chat_models.get(session_state_json["ll_model"])
chatModel = state.ll_model_config.get(session_state_json["ll_model"])
embModel = state.embed_model_config.get(state.rag_params["model"])

logger.info("Model: %s",session_state_json["ll_model"])
logger.info("Embedding Model embModel: %s",embModel)
logger.info("Chat Model: %s",chatModel)
Expand Down