blun-king-cli 3.0.1 → 3.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bin/blun.js +6 -2
- package/package.json +1 -1
package/bin/blun.js
CHANGED
|
@@ -2855,8 +2855,12 @@ async function main() {
|
|
|
2855
2855
|
runHook("post", detected.split(/\s+/)[0].slice(1));
|
|
2856
2856
|
} else if (sessionMode === "agent") {
|
|
2857
2857
|
// Agent mode: detect if question or task
|
|
2858
|
-
var
|
|
2859
|
-
|
|
2858
|
+
var trimmed = input.trim();
|
|
2859
|
+
var isChat = trimmed.length < 15 || // short messages = chat
|
|
2860
|
+
/^(hi|hallo|hey|moin|servus|yo|sup|ok|ja|nein|danke|thanks|bye|tschüss|ciao)/i.test(trimmed) ||
|
|
2861
|
+
/^(wo |was |wie |wer |wann |warum |kannst|hast|ist |sind |where|what|how|who|when|why|can you|do you|is |are )/i.test(trimmed) ||
|
|
2862
|
+
/\?$/.test(trimmed);
|
|
2863
|
+
if (isChat) {
|
|
2860
2864
|
await sendChat(input);
|
|
2861
2865
|
} else {
|
|
2862
2866
|
await cmdAgent(input);
|