Fresh history cut from cynarAI/evoo antigravity-handoff/project-timeline (Voice First + project timeline). Brand docs/titles as evOo; keep @rakazo/* packages as tech debt. Excludes node_modules, caches, secrets, voice blobs.
14 lines
507 B
TypeScript
14 lines
507 B
TypeScript
/**
|
|
* Owner text commands, parsed only in the owner's verified 1:1 conversation.
|
|
* Everything that is not an exact command is a normal message to the bot.
|
|
*/
|
|
export type MessagingCommand = "approve" | "decline" | "leave";
|
|
|
|
export function parseMessagingCommand(text: string): MessagingCommand | null {
|
|
const normalized = text.trim().toUpperCase();
|
|
if (normalized === "YES") return "approve";
|
|
if (normalized === "NO") return "decline";
|
|
if (normalized === "LEAVE") return "leave";
|
|
return null;
|
|
}
|