<!-- # hard line break macro for HTML -->

# fiftyone.operators.sse

FiftyOne SSE operators.

Copyright 2017-2026, Voxel51, Inc.
<br/>
[voxel51.com](https://voxel51.com/)
<br/>
<br/>

**Classes:**

| [`SseOperatorConfig`](#fiftyone.operators.sse.SseOperatorConfig)(name, label, store_name[, ...])   |    |
|----------------------------------------------------------------------------------------------------|----|
| [`SseOperator`](#fiftyone.operators.sse.SseOperator)([_builtin])                                   |    |

### *class* fiftyone.operators.sse.SseOperatorConfig(name, label, store_name, description=None, icon=None, light_icon=None, dark_icon=None)

Bases: [`OperatorConfig`](fiftyone.operators.operator.md#fiftyone.operators.operator.OperatorConfig)

**Attributes:**

| [`risk_level`](#fiftyone.operators.sse.SseOperatorConfig.risk_level)   | The declared `RiskLevel` for this operator.   |
|------------------------------------------------------------------------|-----------------------------------------------|

**Methods:**

| [`to_json`](#fiftyone.operators.sse.SseOperatorConfig.to_json)()   |    |
|--------------------------------------------------------------------|----|

#### *property* risk_level

The declared `RiskLevel` for this operator.

#### to_json()

### *class* fiftyone.operators.sse.SseOperator(\_builtin=False)

Bases: [`Operator`](fiftyone.operators.operator.md#fiftyone.operators.operator.Operator)

**Attributes:**

| [`IS_SSE_OPERATOR`](#fiftyone.operators.sse.SseOperator.IS_SSE_OPERATOR)         |                                                                                                                  |
|----------------------------------------------------------------------------------|------------------------------------------------------------------------------------------------------------------|
| [`subscription_config`](#fiftyone.operators.sse.SseOperator.subscription_config) |                                                                                                                  |
| [`config`](#fiftyone.operators.sse.SseOperator.config)                           | The `OperatorConfig` for the operator.                                                                           |
| [`builtin`](#fiftyone.operators.sse.SseOperator.builtin)                         | Whether the operator is builtin.                                                                                 |
| [`name`](#fiftyone.operators.sse.SseOperator.name)                               |                                                                                                                  |
| [`risk_level`](#fiftyone.operators.sse.SseOperator.risk_level)                   | The effective risk level of the operator, which is used by guardrail systems of an agent to classify tool calls. |
| [`uri`](#fiftyone.operators.sse.SseOperator.uri)                                 | The unique identifier of the operator: `plugin_name/operator_name`.                                              |

**Methods:**

| [`execute`](#fiftyone.operators.sse.SseOperator.execute)(ctx)                                     | Executes the operator.                          |
|---------------------------------------------------------------------------------------------------|-------------------------------------------------|
| [`add_secrets`](#fiftyone.operators.sse.SseOperator.add_secrets)(secrets)                         | Adds secrets to the operator.                   |
| [`method_to_uri`](#fiftyone.operators.sse.SseOperator.method_to_uri)(method_name)                 | Converts a method name to a URI.                |
| [`resolve_delegation`](#fiftyone.operators.sse.SseOperator.resolve_delegation)(ctx)               | Returns the resolved *forced* delegation flag.  |
| [`resolve_execution_options`](#fiftyone.operators.sse.SseOperator.resolve_execution_options)(ctx) | Returns the resolved execution options.         |
| [`resolve_input`](#fiftyone.operators.sse.SseOperator.resolve_input)(ctx)                         | Returns the resolved input property.            |
| [`resolve_output`](#fiftyone.operators.sse.SseOperator.resolve_output)(ctx)                       | Returns the resolved output property.           |
| [`resolve_placement`](#fiftyone.operators.sse.SseOperator.resolve_placement)(ctx)                 | Returns the resolved placement of the operator. |
| [`resolve_run_name`](#fiftyone.operators.sse.SseOperator.resolve_run_name)(ctx)                   | Returns the resolved run name of the operator.  |
| [`resolve_type`](#fiftyone.operators.sse.SseOperator.resolve_type)(ctx, type)                     | Returns the resolved input or output property.  |
| [`to_json`](#fiftyone.operators.sse.SseOperator.to_json)()                                        | Returns a JSON representation of the operator.  |

#### IS_SSE_OPERATOR *= True*

#### *property* subscription_config

#### *property* config

The `OperatorConfig` for the operator.

#### *async* execute(ctx: [ExecutionContext](fiftyone.operators.executor.md#fiftyone.operators.executor.ExecutionContext))

Executes the operator.

Subclasses must implement this method.

* **Parameters:**
  **ctx** – the [`fiftyone.operators.executor.ExecutionContext`](fiftyone.operators.executor.md#fiftyone.operators.executor.ExecutionContext)
* **Returns:**
  JSON serializable data, or None

#### add_secrets(secrets)

Adds secrets to the operator.

* **Parameters:**
  **secrets** – a list of secrets

#### *property* builtin

Whether the operator is builtin.

#### method_to_uri(method_name)

Converts a method name to a URI.

* **Parameters:**
  **method_name** – the method name
* **Returns:**
  a URI

#### *property* name

#### resolve_delegation(ctx) → [bool](fiftyone.core.stages.md#fiftyone.core.stages.Exists.bool) | None

Returns the resolved *forced* delegation flag.

Subclasses can implement this method to decide if delegated execution
should be *forced* for the given operation.

* **Parameters:**
  **ctx** – the [`fiftyone.operators.executor.ExecutionContext`](fiftyone.operators.executor.md#fiftyone.operators.executor.ExecutionContext)
* **Returns:**
  whether the operation should be delegated (True), run immediately
  (False), or None to defer to [`resolve_execution_options()`](#fiftyone.operators.sse.SseOperator.resolve_execution_options) to
  specify the available options

#### resolve_execution_options(ctx)

Returns the resolved execution options.

Subclasses can implement this method to define the execution options
available for the operation.

* **Parameters:**
  **ctx** – the [`fiftyone.operators.executor.ExecutionContext`](fiftyone.operators.executor.md#fiftyone.operators.executor.ExecutionContext)
* **Returns:**
  a [`fiftyone.operators.executor.ExecutionOptions`](fiftyone.operators.executor.md#fiftyone.operators.executor.ExecutionOptions) instance

#### resolve_input(ctx) → [Property](fiftyone.operators.types.md#fiftyone.operators.types.Property) | None

Returns the resolved input property.

Subclasses can implement this method to define the inputs to the
operator. This method should never be called directly. Instead
use [`resolve_type()`](#fiftyone.operators.sse.SseOperator.resolve_type).

By default, this method is called once when the operator is created.
If the operator is dynamic, this method is called each time the input
changes.

* **Parameters:**
  **ctx** – the [`fiftyone.operators.executor.ExecutionContext`](fiftyone.operators.executor.md#fiftyone.operators.executor.ExecutionContext)
* **Returns:**
  a [`fiftyone.operators.types.Property`](fiftyone.operators.types.md#fiftyone.operators.types.Property), or None

#### resolve_output(ctx)

Returns the resolved output property.

Subclasses can implement this method to define the outputs of the
operator.

By default, this method is called once when the operator is created.
If the operator is dynamic, this method is called after the operator is
executed.

* **Parameters:**
  **ctx** – the [`fiftyone.operators.executor.ExecutionContext`](fiftyone.operators.executor.md#fiftyone.operators.executor.ExecutionContext)
* **Returns:**
  a [`fiftyone.operators.types.Property`](fiftyone.operators.types.md#fiftyone.operators.types.Property), or None

#### resolve_placement(ctx)

Returns the resolved placement of the operator.

Subclasses can implement this method to define the placement of the
operator.

* **Parameters:**
  **ctx** – the [`fiftyone.operators.executor.ExecutionContext`](fiftyone.operators.executor.md#fiftyone.operators.executor.ExecutionContext)
* **Returns:**
  a [`fiftyone.operators.types.Placement`](fiftyone.operators.types.md#fiftyone.operators.types.Placement), or None

#### resolve_run_name(ctx)

Returns the resolved run name of the operator.

Subclasses can implement this method to define the run name of the
operator.

* **Parameters:**
  **ctx** – the [`fiftyone.operators.executor.ExecutionContext`](fiftyone.operators.executor.md#fiftyone.operators.executor.ExecutionContext)
* **Returns:**
  a string, or None

#### resolve_type(ctx, type)

Returns the resolved input or output property.

* **Parameters:**
  * **ctx** – the [`fiftyone.operators.executor.ExecutionContext`](fiftyone.operators.executor.md#fiftyone.operators.executor.ExecutionContext)
  * **type** – the type of property to resolve, either `"inputs"` or
    `"outputs"`
* **Returns:**
  a [`fiftyone.operators.types.Property`](fiftyone.operators.types.md#fiftyone.operators.types.Property), or None

#### *property* risk_level

The effective risk level of the operator, which is used by guardrail
systems of an agent to classify tool calls.

#### to_json()

Returns a JSON representation of the operator.

* **Returns:**
  a JSON dict

#### *property* uri

The unique identifier of the operator:
`plugin_name/operator_name`.
