toloka.client.pool.Pool
| Source code
Pool( self, *, project_id: Optional[str] = None, private_name: Optional[str] = None, may_contain_adult_content: Optional[bool] = None, reward_per_assignment: Optional[float] = None, assignment_max_duration_seconds: Optional[int] = None, defaults: Optional[Defaults] = ..., will_expire: Optional[datetime] = None, private_comment: Optional[str] = None, public_description: Optional[str] = None, public_instructions: Optional[str] = None, auto_close_after_complete_delay_seconds: Optional[int] = None, dynamic_pricing_config: Optional[DynamicPricingConfig] = None, auto_accept_solutions: Optional[bool] = None, auto_accept_period_day: Optional[int] = None, assignments_issuing_config: Optional[AssignmentsIssuingConfig] = None, priority: Optional[int] = None, filter: Optional[FilterCondition] = None, quality_control: Optional[QualityControl] = ..., speed_quality_balance: Optional[SpeedQualityBalanceConfig] = None, dynamic_overlap_config: Optional[DynamicOverlapConfig] = None, mixer_config: Optional[MixerConfig] = None, training_config: Optional[TrainingConfig] = None, metadata: Optional[Dict[str, List[str]]] = None, owner: Optional[Owner] = None, id: Optional[str] = None, status: Optional[Status] = None, last_close_reason: Optional[CloseReason] = None, created: Optional[datetime] = None, last_started: Optional[datetime] = None, last_stopped: Optional[datetime] = None, type: Optional[Type] = None)
A set of tasks that share the same properties.
In the pool properties, you set the task price, overlap, Toloker selection filters, quality control rules, and so on.
Pool tasks are grouped into task suites. Whole task suites are assigned to Tolokers.
Learn more about:
Parameters | Type | Description |
---|---|---|
project_id | Optional[str] | The ID of the project containing the pool. |
private_name | Optional[str] | The pool name. It is visible to the requester and is not visible to Tolokers. |
may_contain_adult_content | Optional[bool] | The presence of adult content. |
reward_per_assignment | Optional[float] | Payment in US dollars for a Toloker for completing a task suite. For cents, use the dot as a separator. If the pool |
assignment_max_duration_seconds | Optional[int] | Time limit to complete one task suite. Take into account loading a page with a task suite and sending responses to the server. It is recommended that you set at least 60 seconds. Tasks not completed within the limit are reassigned to other Tolokers. |
defaults | Optional[Defaults] | Default settings that are applied to new tasks in the pool. |
will_expire | Optional[datetime] | The UTC date and time when the pool is closed automatically, even if not all tasks are completed. |
private_comment | Optional[str] | A comment about the pool. It is visible to the requester and is not visible to Tolokers. |
public_description | Optional[str] | The pool description. If pool's |
public_instructions | Optional[str] | The pool instructions for Tolokers. If pool's |
auto_close_after_complete_delay_seconds | Optional[int] | The pool remains open after all tasks are completed during the specified time in seconds. Use non zero value if:
Allowed range: from 0 to 259200 seconds (3 days). The default value is 0. |
dynamic_pricing_config | Optional[DynamicPricingConfig] | The dynamic pricing settings. |
auto_accept_solutions | Optional[bool] |
|
auto_accept_period_day | Optional[int] | The number of days reserved for checking responses if the |
assignments_issuing_config | Optional[AssignmentsIssuingConfig] | Settings for assigning tasks in the pool. |
priority | Optional[int] | The priority of the pool in relation to other pools in the project with the same task price and set of filters. Tolokers are assigned tasks with a higher priority first. Allowed range: from 0 to 100. The default value is 0. |
filter | Optional[FilterCondition] | Settings for Toloker selection filters. |
quality_control | Optional[QualityControl] | Settings for quality control rules and the ID of the pool with training tasks. |
speed_quality_balance | Optional[SpeedQualityBalanceConfig] | Settings for choosing Tolokers for your tasks. |
dynamic_overlap_config | Optional[DynamicOverlapConfig] | Dynamic overlap settings. |
mixer_config | Optional[MixerConfig] | Parameters for automatically creating task suites. |
training_config | Optional[TrainingConfig] | Additional settings for linked training. |
metadata | Optional[Dict[str, List[str]]] | A dictionary with metadata. |
owner | Optional[Owner] | The pool owner. |
id | Optional[str] | The ID of the pool. Read-only field. |
status | Optional[Status] | The status of the pool. Read-only field. |
last_close_reason | Optional[CloseReason] | A reason why the pool was closed last time. Read-only field. |
created | Optional[datetime] | The UTC date and time when the pool was created. Read-only field. |
last_started | Optional[datetime] | The UTC date and time when the pool was started last time. Read-only field. |
last_stopped | Optional[datetime] | The UTC date and time when the pool was stopped last time. Read-only field. |
type | Optional[Type] | The type of the pool. Deprecated. |
Examples:
Creating a new pool.
new_pool = toloka.client.Pool( project_id='1', private_name='Experimental pool', may_contain_adult_content=False, will_expire=datetime.datetime.now(datetime.timezone.utc) + datetime.timedelta(days=365), reward_per_assignment=0.01, assignment_max_duration_seconds=60*20, defaults=toloka.client.Pool.Defaults(default_overlap_for_new_task_suites=3), filter=toloka.client.filter.Languages.in_('EN'),)new_pool.set_mixer_config(real_tasks_count=10)new_pool = toloka_client.create_pool(new_pool)print(new_pool.id)
Method | Description |
---|---|
is_archived | None |
is_closed | None |
is_locked | None |
is_open | None |
set_assignments_issuing_config | A shortcut setter for assignments_issuing_config |
set_captcha_frequency | A shortcut setter for quality_control.captcha_frequency |
set_checkpoints_config | A shortcut setter for quality_control.checkpoints_config |
set_defaults | A shortcut setter for defaults |
set_dynamic_overlap_config | A shortcut setter for dynamic_overlap_config |
set_dynamic_pricing_config | A shortcut setter for dynamic_pricing_config |
set_filter | A shortcut setter for filter |
set_mixer_config | A shortcut setter for mixer_config |
set_owner | A shortcut setter for owner |
set_quality_control | A shortcut setter for quality_control |
set_quality_control_configs | A shortcut method for setting |
set_speed_quality_balance | A shortcut setter for speed_quality_balance |
set_training_config | A shortcut setter for training_config |
set_training_requirement | A shortcut setter for quality_control.training_requirement |