Base未来分类器(Classifier)
Java-friendly base for implementing a Classifier: a Java subclass overrides classifyAsync to return a CompletableFuture, which classify awaits. Canceling the calling coroutine cancels the future from classifyAsync; fail the future rather than cancel it when classification fails, since a canceled future raises CancellationException in classify.