package com.kexue.skills.config;

import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.stereotype.Component;

/**
 * GLM API配置类
 *
 * @author 维哥
 * @since 2026-02-27
 */
@Component
@ConfigurationProperties(prefix = "spring.ai.glm")
public class GlmConfig {

    private String baseUrl;
    private String apiKey;
    private ChatOptions chat;

    public static class ChatOptions {
        private String model;
        private Double temperature;
        private Integer maxTokens;

        public String getModel() {
            return model;
        }

        public void setModel(String model) {
            this.model = model;
        }

        public Double getTemperature() {
            return temperature;
        }

        public void setTemperature(Double temperature) {
            this.temperature = temperature;
        }

        public Integer getMaxTokens() {
            return maxTokens;
        }

        public void setMaxTokens(Integer maxTokens) {
            this.maxTokens = maxTokens;
        }
    }

    public String getBaseUrl() {
        return baseUrl;
    }

    public void setBaseUrl(String baseUrl) {
        this.baseUrl = baseUrl;
    }

    public String getApiKey() {
        return apiKey;
    }

    public void setApiKey(String apiKey) {
        this.apiKey = apiKey;
    }

    public ChatOptions getChat() {
        return chat;
    }

    public void setChat(ChatOptions chat) {
        this.chat = chat;
    }
}