DeepchecksLLMClient#
- class DeepchecksLLMClient#
DeepchecksLLMClient is the class through which you can interact with the Deepchecks LLM API.
- __init__(host: str = None, api_token: str = None, log_level: int = 30, silent_mode: bool = False)#
Init Deepchecks LLM Client. Connect to the server and perform a simple handshake with the API.
- Parameters:
- hoststr
The URL of the Deepchecks server to communicate with. By default, it’s set to the Deepchecks LLM host (https://app.llm.deepchecks.com), but you can override it by providing a custom URL. If not provided, the value is read from the environment variable DEEPCHECKS_LLM_HOST.
- api_tokenstr
Deepchecks API Token (can be generated from the UI). If not provided, the value is read from the environment variable DEEPCHECKS_LLM_API_TOKEN.
- silent_mode: bool, default=False
If True, the SDK will print logs upon encountering errors rather than raising them
- log_level: int, default=logging.WARNING
Set SDK loggers logging level
- Returns:
- None
- __new__(*args, **kwargs)#
Attributes
Get the API object for the client. |
Methods
|
Annotate a specific interaction by its user_interaction_id. |
Create a new application. |
|
Create a new application. |
|
Define a custom property for the current application. |
|
|
Fetch all interactions from the specified environment type (PROD/EVAL) as an iterable. |
Delete a custom property for the current application. |
|
Delete specific interactions by their user_interaction_ids. |
|
Write the auto-annotation YAML configuration file to the specified path. |
|
Get all applications as Application objects. |
|
Get the custom properties defined for the current application. |
|
|
Fetch all the interactions from the specified environment (PROD/EVAL) as a pandas DataFrame. |
Check if calculations for specified events are completed by calling get_interactions_complete_status. |
|
|
Get a specific interaction by its user_interaction_id. |
Get the completion status of interactions for specified events and user interaction IDs. |
|
|
Get pentest prompts for the application. |
|
Get all versions of an application as Version objects. |
Log multiple interactions at once. |
|
|
Log a single interaction. |
Update the auto-annotation YAML configuration file for the current application. |
|
Update a custom property for the current application. |
|
Update a specific interaction by its user_interaction_id. |