/*
 * Copyright 2025 KylinSoft Co., Ltd.
 *
 * This program is free software: you can redistribute it and/or modify it under
 * the terms of the GNU General Public License as published by the Free Software
 * Foundation, either version 3 of the License, or (at your option) any later
 * version.
 *
 * This program is distributed in the hope that it will be useful, but WITHOUT
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
 * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
 * details.
 *
 * You should have received a copy of the GNU General Public License along with
 * this program. If not, see <https://www.gnu.org/licenses/>.
 */

#ifndef MODELCALLPRIORITY_H
#define MODELCALLPRIORITY_H

#include <aiconfig/modelconfig.h>
#include <kysdk/applications/klabel.h>

#include <QComboBox>
#include <QLabel>
#include <QMap>
#include <QObject>
#include <QWidget>


class ModelCallPriority : public QWidget {
    Q_OBJECT
public:
    ModelCallPriority(bool hasLocalModel, QWidget *parent = nullptr);
    void setModelCallPriority(kyai::config::model::DeployType deployType);

signals:
    void topModelPriorityChanged(kyai::config::model::DeployType topPriorityModelType);

public Q_SLOTS:
    void modelPriorityChanged(int index);

private:
    void initConnections();

private:
    bool m_hasLocalModel;

    kdk::KLabel *m_modelCallPriorityLabel = nullptr;    // 模型调用优先级排序标签
    QComboBox *m_modelPriorityComboBox = nullptr;  // 模型调用优先级下拉列表
};

#endif  // MODELCALLPRIORITY_H
