BertQuestionAnswerer class

Task API for BertQA models. */

Implemented types

Properties

base Pointer<TfLiteBertQuestionAnswerer>
no setter
hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

answer(String context, String question) List<QaAnswer>
Answers question based on context, and returns a list of possible QaAnswers. Could be empty if no answer was found from the given context.
override
delete() → void
Deletes BertQuestionAnswerer native instance.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited

Static Methods

create(String modelPath) BertQuestionAnswerer
Generic API to create the QuestionAnswerer for bert models with metadata populated. The API expects a Bert based TFLite model with metadata containing the following information:
createFromAsset(String assetPath) Future<BertQuestionAnswerer>
Create BertQuestionAnswerer directly from assetPath.
createFromFile(File modelFile) BertQuestionAnswerer
Generic API to create the QuestionAnswerer for bert models with metadata populated. The API expects a Bert based TFLite model with metadata containing the following information: