Skip to content

db

RDBMS CLI handler

Attributes

Classes

DBCLI

DBCLI(config: str | None = None)

Bases: BaseCLI

Eleanor framework RDBMS and data utilities

CLI base class

Warning

An odd behavior with Fire has been observed where subclasses of BaseCLI take override __init__ and take parameters caus Fire to incorrectly identify self as a required CLI argument.

Parameters:

  • config (str, default: None ) –

    Path to configuration file

Functions

init
init(script: str) -> None

Executes an Eleanor RDBMS initialization script that sets the database state

init_script_schema
init_script_schema() -> None

Dump the Eleanor RDBMS initialization script JSON schema

name classmethod
name() -> str

InitAgent

Bases: InitParticipant

RDBMS agent initialization record

Attributes

create_episodic_memory_collection class-attribute instance-attribute
create_episodic_memory_collection: bool = Field(
    default=False
)
episodic_memory_collection_config class-attribute instance-attribute
episodic_memory_collection_config: Dict = Field(
    default_factory=dict
)
settings class-attribute instance-attribute
settings: AgentResourceSettings = Field(
    default_factory=AgentResourceSettings
)
vectordb_name class-attribute instance-attribute
vectordb_name: Optional[str] = Field(
    default="default",
    description="Name of the vector database connection. When null/None no episodic memory collection will be created for the agent",
)

Functions

set_default_episodic_memory_collection_config
set_default_episodic_memory_collection_config(v)

InitCollection

Bases: BaseDataModel

RDBMS collection initialization record

Attributes

agent_names class-attribute instance-attribute
agent_names: List[str] = Field(default_factory=list)
collection_type class-attribute instance-attribute
collection_type: MemoryCollectionType = Field(
    default="semantic"
)
config class-attribute instance-attribute
config: Optional[Union[str, Dict]] = Field(default=None)
description class-attribute instance-attribute
description: str = Field(default='')
enabled class-attribute instance-attribute
enabled: bool = Field(default=True)
name instance-attribute
name: str
read_only class-attribute instance-attribute
read_only: bool = Field(default=False)
vectordb_name class-attribute instance-attribute
vectordb_name: str = Field(default='default')

InitNamespace

Bases: BaseDataModel

RDBMS namespace initialization record

Attributes

agents class-attribute instance-attribute
agents: List[InitAgent] = Field(default_factory=list)
collections class-attribute instance-attribute
collections: List[InitCollection] = Field(
    default_factory=list
)
description class-attribute instance-attribute
description: str = Field(default='')
enabled class-attribute instance-attribute
enabled: bool = Field(default=True)
name instance-attribute
name: str
sessions class-attribute instance-attribute
sessions: List[InitSession] = Field(default_factory=list)
settings class-attribute instance-attribute
settings: NamespaceResourceSettings = Field(
    default_factory=NamespaceResourceSettings
)
users class-attribute instance-attribute
users: List[InitUser] = Field(default_factory=list)

InitParticipant

Bases: BaseDataModel

RDBMS user/agent initialization record

Attributes

description class-attribute instance-attribute
description: str = Field(default='')
enabled class-attribute instance-attribute
enabled: bool = Field(default=True)
name instance-attribute
name: str

InitScript

Bases: BaseDataModel

RDBMS initialization script

Attributes

namespaces class-attribute instance-attribute
namespaces: List[InitNamespace] = Field(
    default_factory=list
)

InitSession

Bases: BaseDataModel

RDBMS session initialization record

Attributes

description class-attribute instance-attribute
description: str = Field(default='')
enabled class-attribute instance-attribute
enabled: bool = Field(default=True)
name instance-attribute
name: str
participant_names class-attribute instance-attribute
participant_names: List[str] = Field(default_factory=list)
settings class-attribute instance-attribute
settings: SessionResourceSettings = Field(
    default_factory=SessionResourceSettings
)

InitUser

Bases: InitParticipant

RDBMS user initialization record

Attributes

settings class-attribute instance-attribute
settings: UserResourceSettings = Field(
    default_factory=UserResourceSettings
)