Warning: session_start(): open(/var/lib/php/sessions/sess_3u6miqrlm984gmgkr75md45pg3, O_RDWR) failed: No space left on device (28) in /var/www/tb-usercake/models/config.php on line 51
Warning: session_start(): Failed to read session data: files (path: /var/lib/php/sessions) in /var/www/tb-usercake/models/config.php on line 51
sbool nlLogic_matchRandomFact(NLLogicChecker_v2 c, S pat, NLLogicChecker_v2.Matching m) {
LS patterns = tok_splitAtVerticalBar(pat);
LinkedHashMap m2 = null;
new L> choices;
for (S fact : c.facts) {
if (m2 == null) m2 = cloneLinkedHashMap(m.matches);
bool result = nlLogic_matchMultiplePatterns(c, patterns, fact, m2);
if (m.verbose) print("matched " + quote(pat) + " with " + quote(fact) + " & " + sfu(m.matches) + " => " + result);
if (result) {
choices.add(m2);
m2 = null;
}
}
if (empty(choices)) false;
m.matches = random(choices);
true;
}