pyrit.prompt_converter.ConverterResult#

class ConverterResult(output_text: str, output_type: Literal['text', 'image_path', 'audio_path', 'video_path', 'url', 'error'])[source]#

Bases: object

The result of a prompt conversion, containing the converted output and its type.

__init__(output_text: str, output_type: Literal['text', 'image_path', 'audio_path', 'video_path', 'url', 'error']) None#

Methods

__init__(output_text, output_type)

Attributes

output_text

The converted text output.

output_type

The data type of the converted output.

output_text: str#

The converted text output. This is the main result of the conversion.

output_type: Literal['text', 'image_path', 'audio_path', 'video_path', 'url', 'error']#

The data type of the converted output. Indicates the format/type of the output_text.