environment
Class info¶
Classes¶
Name | Children | Inherits |
---|---|---|
FileEnvironment llmling_agent.models.environment File-based environment configuration. |
||
InlineEnvironment llmling_agent.models.environment Direct environment configuration without external files. |
🛈 DocStrings¶
FileEnvironment
¶
Bases: BaseModel
File-based environment configuration.
Loads environment settings from external YAML files, supporting: - Reusable environment configurations - Separation of concerns - Environment sharing between agents - Version control of environment settings
Source code in src/llmling_agent/models/environment.py
9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 |
|
config_file_path
class-attribute
instance-attribute
¶
config_file_path: str | None = None
Path to agent config file for resolving relative paths
type
class-attribute
instance-attribute
¶
type: Literal['file'] = Field('file', init=False)
File-based runtime config.
get_config
¶
get_config() -> Config
Get runtime configuration.
Source code in src/llmling_agent/models/environment.py
42 43 44 |
|
get_file_path
¶
get_file_path() -> str
Get resolved file path.
Source code in src/llmling_agent/models/environment.py
33 34 35 36 37 38 39 40 |
|
InlineEnvironment
¶
Bases: Config
Direct environment configuration without external files.
Allows embedding complete environment settings directly in the agent configuration instead of referencing external files. Useful for: - Self-contained configurations - Testing and development - Simple agent setups
Source code in src/llmling_agent/models/environment.py
48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 |
|
config_file_path
class-attribute
instance-attribute
¶
config_file_path: str | None = None
Path to agent config file for resolving relative paths
type
class-attribute
instance-attribute
¶
type: Literal['inline'] = Field('inline', init=False)
Inline-defined runtime config.
uri
class-attribute
instance-attribute
¶
uri: str | None = None
Optional identifier for this configuration
from_config
classmethod
¶
from_config(
config: Config, uri: str | None = None, config_file_path: str | None = None
) -> InlineEnvironment
Create inline environment from config.
Source code in src/llmling_agent/models/environment.py
80 81 82 83 84 85 86 87 88 |
|
get_config
¶
get_config() -> Config
Get runtime configuration.
Source code in src/llmling_agent/models/environment.py
76 77 78 |
|