View source on GitHub |
The export module for the question answering task.
Inherits From: ExportModule
tfm.nlp.serving_modules.QuestionAnswering(
params, model: tf.keras.Model, inference_step=None
)
Child Classes
Methods
get_inference_signatures
get_inference_signatures(
function_keys: Dict[Text, Text]
)
Get defined function signatures.
serve
@tf.function
serve( input_word_ids, input_mask=None, input_type_ids=None ) -> Dict[str, tf.Tensor]
serve_examples
@tf.function
serve_examples( inputs ) -> Dict[str, tf.Tensor]