mirror of
https://git.mirrors.martin98.com/https://github.com/langgenius/dify.git
synced 2025-05-13 00:58:17 +08:00
22 lines
353 B
Python
22 lines
353 B
Python
from pydantic import BaseModel
|
|
|
|
|
|
class VectorSetting(BaseModel):
|
|
vector_weight: float
|
|
|
|
embedding_provider_name: str
|
|
|
|
embedding_model_name: str
|
|
|
|
|
|
class KeywordSetting(BaseModel):
|
|
keyword_weight: float
|
|
|
|
|
|
class Weights(BaseModel):
|
|
"""Model for weighted rerank."""
|
|
|
|
vector_setting: VectorSetting
|
|
|
|
keyword_setting: KeywordSetting
|