chromium/services/on_device_model/ml/ts_model.cc

// Copyright 2024 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#include "services/on_device_model/ml/ts_model.h"

#include <memory>
#include <string>
#include <utility>

#include "base/check_op.h"
#include "base/compiler_specific.h"
#include "base/files/memory_mapped_file.h"
#include "base/memory/ptr_util.h"
#include "base/memory/scoped_refptr.h"
#include "base/strings/utf_string_conversions.h"
#include "base/task/thread_pool.h"
#include "components/language_detection/core/language_detection_provider.h"
#include "components/translate/core/language_detection/language_detection_model.h"
#include "services/on_device_model/ml/chrome_ml.h"
#include "services/on_device_model/ml/chrome_ml_api.h"
#include "services/on_device_model/public/mojom/on_device_model.mojom.h"
#include "services/on_device_model/public/mojom/on_device_model_service.mojom.h"

LoadModelResult;

namespace ml {

TsModel::TsModel(
    const ChromeML& chrome_ml,
    std::unique_ptr<translate::LanguageDetectionModel> language_detector)
    :{}

DISABLE_CFI_DLSYM
TsModel::~TsModel() {}

// static
base::SequenceBound<std::unique_ptr<TsModel>> TsModel::Create(
    const ChromeML& chrome_ml,
    on_device_model::mojom::ModelAssetsPtr ts_assets,
    base::File language_detection_file) {}

DISABLE_CFI_DLSYM
void TsModel::InitTextSafetyModel() {}

DISABLE_CFI_DLSYM
on_device_model::mojom::SafetyInfoPtr TsModel::ClassifyTextSafety(
    const std::string& text) {}

on_device_model::mojom::LanguageDetectionResultPtr TsModel::DetectLanguage(
    std::string_view text) {}

}  // namespace ml