mirror of
https://github.com/zylon-ai/private-gpt.git
synced 2025-12-22 07:40:12 +01:00
Allow parameterizing OpenAI embeddings component (api_base, key, model) (#1920)
Some checks failed
release-please / release-please (push) Has been cancelled
tests / setup (push) Has been cancelled
tests / ${{ matrix.quality-command }} (black) (push) Has been cancelled
tests / ${{ matrix.quality-command }} (mypy) (push) Has been cancelled
tests / ${{ matrix.quality-command }} (ruff) (push) Has been cancelled
tests / test (push) Has been cancelled
tests / all_checks_passed (push) Has been cancelled
Some checks failed
release-please / release-please (push) Has been cancelled
tests / setup (push) Has been cancelled
tests / ${{ matrix.quality-command }} (black) (push) Has been cancelled
tests / ${{ matrix.quality-command }} (mypy) (push) Has been cancelled
tests / ${{ matrix.quality-command }} (ruff) (push) Has been cancelled
tests / test (push) Has been cancelled
tests / all_checks_passed (push) Has been cancelled
* Allow parameterizing OpenAI embeddings component (api_base, key, model) * Update settings * Update description
This commit is contained in:
parent
45df99feb7
commit
3b3e96ad6c
3 changed files with 21 additions and 2 deletions
|
|
@ -209,6 +209,15 @@ class OpenAISettings(BaseModel):
|
|||
120.0,
|
||||
description="Time elapsed until openailike server times out the request. Default is 120s. Format is float. ",
|
||||
)
|
||||
embedding_api_base: str = Field(
|
||||
None,
|
||||
description="Base URL of OpenAI API. Example: 'https://api.openai.com/v1'.",
|
||||
)
|
||||
embedding_api_key: str
|
||||
embedding_model: str = Field(
|
||||
"text-embedding-ada-002",
|
||||
description="OpenAI embedding Model to use. Example: 'text-embedding-3-large'.",
|
||||
)
|
||||
|
||||
|
||||
class OllamaSettings(BaseModel):
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue