-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
e1a8760
commit 6fd4426
Showing
5 changed files
with
9 additions
and
24 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
16 changes: 3 additions & 13 deletions
16
packages/mediapipe-task-text/lib/src/tasks/text_classification/text_classifier.dart
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,26 +1,16 @@ | ||
import 'package:mediapipe_text/mediapipe_text.dart'; | ||
|
||
export 'universal_text_classifier.dart' | ||
if (dart.library.html) 'web_text_classifier.dart' | ||
if (dart.library.io) 'ffi_text_classifier.dart'; | ||
if (dart.library.html) 'text_classifier_web.dart' | ||
if (dart.library.io) 'text_classifier_io.dart'; | ||
|
||
/// Channel to analyze text via MediaPipe's text classification task. | ||
abstract class BaseTextClassifier { | ||
BaseTextClassifier({required this.options}); | ||
|
||
/// Configuration object passed into C or JavaScript to influence how | ||
/// MediaPipe completes the requested operation. | ||
/// Configuration object for tasks completed by this classifier. | ||
final TextClassifierOptions options; | ||
|
||
/// Location for where to find the means to communicate with the MediaPipe SDK. | ||
/// | ||
/// For mobile and desktop targets, this should be the location on the local | ||
/// filesystem of the C wrappers. | ||
/// | ||
/// For web builds, this should be the namespace off the global `window` | ||
/// object where the JavaScript wrapper can be found. | ||
// final String sdkPath; | ||
|
||
/// Sends a `String` value to MediaPipe for classification. | ||
TextClassifierResult classify(String text); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters