#include "components/optimization_guide/core/page_visibility_model_executor.h"
#include "base/trace_event/trace_event.h"
#include "base/types/expected.h"
#include "components/optimization_guide/core/model_util.h"
#include "components/optimization_guide/core/optimization_guide_features.h"
#include "components/optimization_guide/core/page_visibility_op_resolver.h"
#include "components/optimization_guide/core/tflite_op_resolver.h"
#include "third_party/tflite_support/src/tensorflow_lite_support/cc/task/text/nlclassifier/nl_classifier.h"
#include "third_party/tflite_support/src/tensorflow_lite_support/cc/task/text/proto/nl_classifier_options.pb.h"
namespace optimization_guide {
PageVisibilityModelExecutor::PageVisibilityModelExecutor()
: … { … }
PageVisibilityModelExecutor::~PageVisibilityModelExecutor() = default;
std::optional<std::vector<tflite::task::core::Category>>
PageVisibilityModelExecutor::Execute(ModelExecutionTask* execution_task,
ExecutionStatus* out_status,
const std::string& input) { … }
base::expected<std::unique_ptr<PageVisibilityModelExecutor::ModelExecutionTask>,
ExecutionStatus>
PageVisibilityModelExecutor::BuildModelExecutionTask(
base::MemoryMappedFile* model_file) { … }
}