SimpCfg:Dbug why bool is not setting properly
This commit is contained in:
parent
5aa1072aac
commit
ef5a2cf391
2 changed files with 7 additions and 3 deletions
|
@ -65,6 +65,7 @@ std::string str_trim_single(std::string sin, std::string trimChars=" \t\n") {
|
||||||
std::string str_tolower(const std::string &sin) {
|
std::string str_tolower(const std::string &sin) {
|
||||||
std::string sout;
|
std::string sout;
|
||||||
std::transform(sin.begin(), sin.end(),sout.begin(), [](char c)->char {return std::tolower(c);});
|
std::transform(sin.begin(), sin.end(),sout.begin(), [](char c)->char {return std::tolower(c);});
|
||||||
|
LDBUG_LN("DBUG:%s:%s:%s", __func__, sin.c_str(), sout.c_str());
|
||||||
return sout;
|
return sout;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -107,7 +108,10 @@ public:
|
||||||
}
|
}
|
||||||
|
|
||||||
void set_bool(const std::string &group, const std::string &key, const std::string &value) {
|
void set_bool(const std::string &group, const std::string &key, const std::string &value) {
|
||||||
set_bool(group, key, str_tolower(value) == "true" ? true : false);
|
std::string sValue = str_tolower(value);
|
||||||
|
bool bValue = sValue == "true" ? true : false;
|
||||||
|
LDBUG_LN("DBUG:%s:%s:%s:%d", __func__, value.c_str(), sValue.c_str(), bValue);
|
||||||
|
set_bool(group, key, bValue);
|
||||||
}
|
}
|
||||||
|
|
||||||
void set_int64(const std::string &group, const std::string &key, int64_t value) {
|
void set_int64(const std::string &group, const std::string &key, int64_t value) {
|
||||||
|
|
|
@ -18,8 +18,8 @@
|
||||||
"assistant-end": "</s>"
|
"assistant-end": "</s>"
|
||||||
|
|
||||||
"reverse-prompt": "</s>",
|
"reverse-prompt": "</s>",
|
||||||
"systemuser-system-has-suffix": true,
|
"systemuser-system-has-suffix": tRUe,
|
||||||
"systemuser-system-has-end": false,
|
"systemuser-system-has-end": faLSe,
|
||||||
"systemuser-1st-user-has-begin": false,
|
"systemuser-1st-user-has-begin": false,
|
||||||
"systemuser-1st-user-has-prefix": false
|
"systemuser-1st-user-has-prefix": false
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue