Base
Argilla
¶
Bases: Step
, ABC
Abstract step that provides a class to subclass from, that contains the boilerplate code required to interact with Argilla, as well as some extra validations on top of it. It also defines the abstract methods that need to be implemented in order to add a new dataset type as a step.
Note
This class is not intended to be instanced directly, but via subclass.
Attributes:
Name | Type | Description |
---|---|---|
dataset_name |
RuntimeParameter[str]
|
The name of the dataset in Argilla where the records will be added. |
dataset_workspace |
Optional[RuntimeParameter[str]]
|
The workspace where the dataset will be created in Argilla. Defaults to
|
api_url |
Optional[RuntimeParameter[str]]
|
The URL of the Argilla API. Defaults to |
api_key |
Optional[RuntimeParameter[SecretStr]]
|
The API key to authenticate with Argilla. Defaults to |
Runtime parameters
dataset_name
: The name of the dataset in Argilla where the records will be added.dataset_workspace
: The workspace where the dataset will be created in Argilla. Defaults toNone
, which means it will be created in the default workspace.api_url
: The base URL to use for the Argilla API requests.api_key
: The API key to authenticate the requests to the Argilla API.
Input columns
- dynamic, based on the
inputs
value provided
Source code in src/distilabel/steps/argilla/base.py
39 40 41 42 43 44 45 46 47 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 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 |
|
outputs: List[str]
property
¶
The outputs of the step is an empty list, since the steps subclassing from this one, will always be leaf nodes and won't propagate the inputs neither generate any outputs.
load()
¶
Method to perform any initialization logic before the process
method is
called. For example, to load an LLM, stablish a connection to a database, etc.
model_post_init(__context)
¶
Checks that the Argilla Python SDK is installed, and then filters the Argilla warnings.