gen_ai_hub.orchestration.models.content_filtering
index
/home/jenkins/agent/workspace/ation_generative-ai-hub-sdk_main/gen_ai_hub/orchestration/models/content_filtering.py

 
Classes
       
gen_ai_hub.orchestration.models.base.JSONSerializable(abc.ABC)
ContentFiltering
InputFiltering
OutputFiltering

 
class ContentFiltering(gen_ai_hub.orchestration.models.base.JSONSerializable)
    ContentFiltering(input_filtering: Optional[gen_ai_hub.orchestration.models.content_filtering.InputFiltering] = None, output_filtering: Optional[gen_ai_hub.orchestration.models.content_filtering.OutputFiltering] = None)
 
Module for managing and applying content filters.
 
 
Method resolution order:
ContentFiltering
gen_ai_hub.orchestration.models.base.JSONSerializable
abc.ABC
builtins.object

Methods defined here:
__init__(self, input_filtering: Optional[gen_ai_hub.orchestration.models.content_filtering.InputFiltering] = None, output_filtering: Optional[gen_ai_hub.orchestration.models.content_filtering.OutputFiltering] = None)
Initializes the ContentFiltering with optional input and output filtering configurations.
 
:param input_filtering: the configuration for input filtering, defaults to None
:type input_filtering: Optional[InputFiltering], optional
:param output_filtering: the configuration for output filtering, defaults to None
:type output_filtering: Optional[OutputFiltering], optional
to_dict(self)
to_dict method to convert the content filtering configuration to a dictionary.
 
:return: dictionary representation of the content filtering configuration.
:rtype: dict

Data and other attributes defined here:
__abstractmethods__ = frozenset()
__annotations__ = {}

Data descriptors inherited from gen_ai_hub.orchestration.models.base.JSONSerializable:
__dict__
dictionary for instance variables (if defined)
__weakref__
list of weak references to the object (if defined)

 
class InputFiltering(gen_ai_hub.orchestration.models.base.JSONSerializable)
    InputFiltering(filters: List[gen_ai_hub.orchestration.models.content_filter.ContentFilter])
 
Module for managing and applying input content filters.
 
 
Method resolution order:
InputFiltering
gen_ai_hub.orchestration.models.base.JSONSerializable
abc.ABC
builtins.object

Methods defined here:
__init__(self, filters: List[gen_ai_hub.orchestration.models.content_filter.ContentFilter])
Initializes the InputFiltering with specified filters.
 
:param filters: List of ContentFilter objects to be applied to input content.
:type filters: List[ContentFilter]
to_dict(self)
to_dict method to convert the input filtering configuration to a dictionary.
 
:return: dictionary representation of the input filtering configuration.
:rtype: dict

Data and other attributes defined here:
__abstractmethods__ = frozenset()
__annotations__ = {}

Data descriptors inherited from gen_ai_hub.orchestration.models.base.JSONSerializable:
__dict__
dictionary for instance variables (if defined)
__weakref__
list of weak references to the object (if defined)

 
class OutputFiltering(gen_ai_hub.orchestration.models.base.JSONSerializable)
    OutputFiltering(filters: List[gen_ai_hub.orchestration.models.content_filter.ContentFilter], stream_options: Optional[dict] = None)
 
Module for managing and applying output content filters.
 
 
Method resolution order:
OutputFiltering
gen_ai_hub.orchestration.models.base.JSONSerializable
abc.ABC
builtins.object

Methods defined here:
__init__(self, filters: List[gen_ai_hub.orchestration.models.content_filter.ContentFilter], stream_options: Optional[dict] = None)
Initializes the OutputFiltering with specified filters and optional streaming options.
 
:param filters: List of ContentFilter objects to be applied to output content.
:type filters: List[ContentFilter]
:param stream_options: Module-specific streaming options, defaults to None
:type stream_options: Optional[dict], optional
to_dict(self)
to_dict method to convert the output filtering configuration to a dictionary.
 
:return: dictionary representation of the output filtering configuration.
:rtype: dict

Data and other attributes defined here:
__abstractmethods__ = frozenset()
__annotations__ = {}

Data descriptors inherited from gen_ai_hub.orchestration.models.base.JSONSerializable:
__dict__
dictionary for instance variables (if defined)
__weakref__
list of weak references to the object (if defined)

 
Data
        List = typing.List
Optional = typing.Optional