Files
html/api/wevia-v62-intents-include.php

35 lines
1.8 KiB
PHP

<?php
if (!isset($msg) || !isset($intents)) return;
if (preg_match('/\b(wire|deploy|integre|integrate).*(lean.?6.?sigma|lean6sigma|l6s|toc|dmaic|kaizen|bpmn)\b/iu', $msg)) {
if (preg_match('/\bconfirmed\b/i', $msg)) {
$intents[] = ['id'=>'v62_wire_lean6sigma_exec', 'cmd'=>'bash /var/www/html/api/v62-wire-lean6sigma.sh'];
} else {
$intents[] = ['id'=>'v62_wire_lean6sigma_guide', 'cmd'=>'bash /var/www/html/api/v62-wire-lean6sigma-guide.sh'];
}
}
if (preg_match('/\b(wire|populate|fill|remplir)\b.*\b(meeting|rooms|salle|reunion)\b/iu', $msg) || preg_match('/\bmeeting.?rooms?\b/iu', $msg)) {
if (preg_match('/\bconfirmed\b/i', $msg)) {
$intents[] = ['id'=>'v62_wire_meeting_rooms_exec', 'cmd'=>'bash /var/www/html/api/v62-wire-meeting-rooms.sh'];
} else {
$intents[] = ['id'=>'v62_wire_meeting_rooms_guide', 'cmd'=>'bash /var/www/html/api/v62-wire-meeting-rooms-guide.sh'];
}
}
if (preg_match('/\b(integrate.all|integre.tout|full.integration|wire.all|wire.tout)\b/iu', $msg) || preg_match('/\bintegrate\b.*\ball\b/iu', $msg)) {
if (preg_match('/\bconfirmed\b/i', $msg)) {
$intents[] = ['id'=>'v62_integrate_all_exec', 'cmd'=>'bash /var/www/html/api/v62-integrate-all.sh'];
} else {
$intents[] = ['id'=>'v62_integrate_all_guide', 'cmd'=>'bash /var/www/html/api/v62-integrate-all-guide.sh'];
}
}
if (preg_match('/\b(test.autonomie|wevia.autonomy|es.tu.autonome|autowire.status)\b/iu', $msg)) {
$intents[] = ['id'=>'v62_test_autonomie', 'cmd'=>'bash /var/www/html/api/v62-test-autonomie.sh'];
}
if (preg_match('/\b(lecture.avant|read.before|wiki.vault.plan|anti.conflit|other.claude)\b/iu', $msg)) {
$intents[] = ['id'=>'v62_anti_conflit_read', 'cmd'=>'bash /var/www/html/api/v62-anti-conflit-read.sh'];
}