Skip to content

Latest commit

 

History

History
69 lines (56 loc) · 1.79 KB

File metadata and controls

69 lines (56 loc) · 1.79 KB
name persona
description Unified entry point for AI Persona OS — setup wizard, in-chat commands, context protection, monitoring, and learning system. Say 'persona setup' to start, 'persona status' for dashboard, or 'persona help' for all commands.
allowed-tools
Bash
Read
Write
Glob
AskUserQuestion
Task

Persona Gateway

This is the unified command gateway for the AI Persona OS plugin. It routes user requests to the appropriate skill based on intent detection.

How It Works

  1. Read the intent mapping configuration
  2. Match user input against keyword patterns
  3. Route to the correct skill
  4. Handle fallback if no match found

Implementation

# Step 1: Load intent mapping
intent_config = READ ${CLAUDE_PLUGIN_ROOT}/commands/persona/intent-mapping.yaml

# Step 2: Parse user input
user_input = LOWERCASE(args)
matched_intent = NULL

# Step 3: Match keywords
FOR EACH intent IN intent_config.intents:
  FOR EACH keyword IN intent.keywords:
    IF keyword IN user_input:
      matched_intent = intent
      BREAK

# Step 4: Route to skill or show help
IF matched_intent IS NOT NULL:
  TASK(
    skill: matched_intent.skill,
    args: args
  )
ELSE:
  # Show fallback help message
  PRINT intent_config.fallback.message

Available Commands

  • persona setup — First-run wizard to configure your AI assistant
  • persona status — View system health dashboard
  • persona help — List all available commands
  • persona checkpoint — Save current context immediately
  • persona heartbeat — Run ambient health check
  • persona learn — Capture a learning or error for review

Examples

/persona setup
/persona status
/persona help
/persona checkpoint
/persona learn "remember to check permissions before file operations"