forked from phoenix-oss/llama-stack-mirror
Fix sqlite_vec config defaults
This commit is contained in:
parent
832c535aaf
commit
35ae0e16a1
2 changed files with 2 additions and 15 deletions
|
@ -4,26 +4,16 @@
|
||||||
# This source code is licensed under the terms described in the LICENSE file in
|
# This source code is licensed under the terms described in the LICENSE file in
|
||||||
# the root directory of this source tree.
|
# the root directory of this source tree.
|
||||||
|
|
||||||
# config.py
|
|
||||||
from typing import Any, Dict
|
from typing import Any, Dict
|
||||||
|
|
||||||
from pydantic import BaseModel
|
from pydantic import BaseModel
|
||||||
|
|
||||||
from llama_stack.providers.utils.kvstore.config import (
|
|
||||||
KVStoreConfig,
|
|
||||||
SqliteKVStoreConfig,
|
|
||||||
)
|
|
||||||
|
|
||||||
|
|
||||||
class SQLiteVectorIOConfig(BaseModel):
|
class SQLiteVectorIOConfig(BaseModel):
|
||||||
db_path: str
|
db_path: str
|
||||||
kvstore: KVStoreConfig
|
|
||||||
|
|
||||||
@classmethod
|
@classmethod
|
||||||
def sample_run_config(cls, __distro_dir__: str) -> Dict[str, Any]:
|
def sample_run_config(cls, __distro_dir__: str) -> Dict[str, Any]:
|
||||||
return {
|
return {
|
||||||
"kvstore": SqliteKVStoreConfig.sample_run_config(
|
"db_path": "${env.SQLITE_STORE_DIR:~/.llama/" + __distro_dir__ + "}/" + "sqlite_vec.db",
|
||||||
__distro_dir__=__distro_dir__,
|
|
||||||
db_name="sqlite_vec.db",
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -30,10 +30,7 @@ providers:
|
||||||
- provider_id: sqlite_vec
|
- provider_id: sqlite_vec
|
||||||
provider_type: inline::sqlite_vec
|
provider_type: inline::sqlite_vec
|
||||||
config:
|
config:
|
||||||
kvstore:
|
db_path: ${env.SQLITE_STORE_DIR:~/.llama/distributions/ollama}/sqlite_vec.db
|
||||||
type: sqlite
|
|
||||||
namespace: null
|
|
||||||
db_path: ${env.SQLITE_STORE_DIR:~/.llama/distributions/ollama}/sqlite_vec.db
|
|
||||||
safety:
|
safety:
|
||||||
- provider_id: llama-guard
|
- provider_id: llama-guard
|
||||||
provider_type: inline::llama-guard
|
provider_type: inline::llama-guard
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue