package com.ch.jedge.jbot;

import com.changhong.qlib.util.file.FileUtils;
public class JEJBotLLMConst {

    public static final String sval_sub_dir_cfg = "cfg";
    public static final String sval_sub_dir_glm = "glm";
    public static final String sval_sub_dir_field_cfg = "cols";

    // public static final String sval_panel_class_base_path = (new File(ConfigUtil.class.getResource("/").getFile())).getPath();
    public static final String sval_panel_class_base_path = "/storage/emulated/0/Android/data/com.ch.jedge.demo.glm/cache/";//"./";
    public static final String sval_server_db_cfg_filename = FileUtils.contactPath(sval_panel_class_base_path, sval_sub_dir_cfg, "db.json");

    public static final String sval_milvus_col_def_filename = FileUtils.contactPath(sval_panel_class_base_path, sval_sub_dir_cfg,"_col_def.json");
    public static final String sval_milvus_msg_def_filename = FileUtils.contactPath(sval_panel_class_base_path, sval_sub_dir_cfg,"_msg_add.json");
    public static final String sval_glm_config_filename = FileUtils.contactPath(sval_panel_class_base_path, sval_sub_dir_glm,"glm.json");

    public static final String sval_milvus_cfg_path = FileUtils.contactPath(sval_panel_class_base_path, sval_sub_dir_cfg);

    public static final String sval_corpus_cache_path_debug_ = FileUtils.contactPath(sval_panel_class_base_path, "jbot/unit/jbot/cache/corpus");

    public static final String sval_module_llm = "llm";

    public static final String sval_modual_word_cut = "wcut";

    public static final String sval_modual_vec_db = "vdb";
    public static final String sval_default_vector_service = "gv";
    public static final String sval_modual_glm_llm = "llm";

    public static final String sval_default_jbot_jedge = "jbot";
    public static final String sval_default_gpt_service = "gpt";
    public static final String sval_default_llm_call_service = "lmc";
    public static final String sval_default_gpt_voice_service = "gptv";
    public static final String sval_default_glm6b_service = "glm6b";

    public static final String default_vs_domain_ = "_knDefault";
    public static final String default_vs_domain_local = "tc";


    public static final long ival_timeout_session_ = 3 * 60 * 1000 * 10;
    public static final int  max_history_size = 25;
    public static final int  ival_mufis_text_message_gap_time_ = 100;
    public static final int  ival_max_timeout_count = 180;

    public static final String sval_prompt_intentJudge =
            "意图领域范围:%s,根据对话内容，提取问题的意图范围和知识关键字、意图领域只能在上述意图领域范围内、用如下json格式输出%s";
    public static final String sval_prompt_kn_build = "就如下内容用提出总共%d个咨询类的问题和答案。每个问题聚焦不超过12字，答案尽可能丰富。问答对的输出格式: Q:这是一个问题A:这是答案";
    public static final String sval_prompt_kn_talk = "用户希望:%s, 回答内容全部在 %s 中，你需要扮演角色:%s,回答从上述内容中回答下面的问题(只输出答案)：%s";
    public static final String sval_prompt_kn_explain = "用如下内容生成精简的一句话回答:%s";


    public static final boolean old_vdb_mode_ = true;
    public static final boolean local_corpus_ = true;

    public static final int  ival_max_kn_items = 80;

    public static final String sval_verb_type_user_defined_relation_noun = "nur";
    public static final String sval_verb_type_user_defined_join_noun = "nuj";
    public static final String val_verb_type_user_defined_noun = "nud";
    public static final String val_verb_type_user_defined_verb = "vud";
    public static final String sval_verb_type_user_defined_inference = "nugr";      //需要推理预测结果的词,不是直接命中答案。
    public static final int lval_min_time_gap = 5000; //每5S添加一条向量数据,防止添加过快导致milvus崩溃

    public static final String sval_predict_split = "$$$";
    public static final String sval_predict_sign = "@@@";
    public static final int sval_predict_sign_size = sval_predict_sign.length();
}
