Add RAG configuration options and enhance parameter configurability
- Add top-k and cosine-threshold parms for api server - Update .env and cli parms handling with new parameters - Improve splash screen display - Update bash and storage classes to read new parameters from .env file.
This commit is contained in:
@@ -1,3 +1,4 @@
|
||||
import os
|
||||
from dataclasses import dataclass, field
|
||||
from typing import (
|
||||
TypedDict,
|
||||
@@ -32,7 +33,7 @@ class QueryParam:
|
||||
response_type: str = "Multiple Paragraphs"
|
||||
stream: bool = False
|
||||
# Number of top-k items to retrieve; corresponds to entities in "local" mode and relationships in "global" mode.
|
||||
top_k: int = 60
|
||||
top_k: int = int(os.getenv("TOP_K", "60"))
|
||||
# Number of document chunks to retrieve.
|
||||
# top_n: int = 10
|
||||
# Number of tokens for the original chunks.
|
||||
|
Reference in New Issue
Block a user