Skip to content

๐ŸŽฎ Interaction Modes

Note

๐Ÿ‘‹ Hey there! Siyarix is a personal passion project built by a single developer that is growing and under active development. Some of the architectural components and features described on this page might currently be Planned, Work in Progress, or basic implementations. Stay tuned as it evolves! ๐Ÿš€

Siyarix is designed to adapt to your workflow. We support four distinct interaction modes: REGISTRY, AUTONOMOUS, HYBRID, and INTERACTIVE.

These modes are available across our two primary interfaces: - ๐Ÿ’ป CLI: A powerful command-line interface with intuitive subcommands. - ๐Ÿ’ฌ REPL: An interactive, conversational shell for dynamic engagement.

Note

Mode selection typically happens at invocation time, but if you're using the REPL, you can easily switch modes on the fly using natural language commands!


๐ŸŽ›๏ธ Mode Selection

๐Ÿ’ป CLI Mode

When invoking Siyarix from your terminal, the mode is seamlessly selected by the main_callback() function located in cli/main.py.

Here are a few examples of how you can invoke different modes:

# ๐ŸŽฏ Registry mode (default): Execute a single command from our template registry
siyarix scan 10.0.0.1
siyarix recon example.com

# ๐Ÿค– Autonomous mode: Let Siyarix achieve a goal autonomously
siyarix --mode autonomous "Enumerate all services on 10.0.0.0/24"

# ๐Ÿ’ฌ Interactive (REPL) mode: Jump into the conversational shell
siyarix --interactive
# or simply use the shorthand:
siyarix -i

# ๐Ÿ“ฆ Batch mode: Process a list of commands from stdin or a file
siyarix --batch commands.txt

# โ„น๏ธ Other useful commands
siyarix --version  # Check your current version
siyarix --help     # Display help and available options

๐Ÿ’ฌ REPL Mode Switching

Once inside the REPL, you don't need to memorize complex flags. You can seamlessly switch modes using natural language or simple slash commands:

โ•ญโ”€ Siyarix v2.0.0 โ”€ INTERACTIVE โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ•ฎ
โ”‚                                                          โ”‚
โ”‚  โ„น Type 'help' for commands, 'exit' to quit.             โ”‚
โ”‚  โ„น Use '/mode <mode>' or simply say: 'switch to autonomous'โ”‚
โ”‚                                                          โ”‚
โ•ฐโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ•ฏ

> switch to autonomous mode
  โœ“ Mode set to AUTONOMOUS โ€” I'll now operate autonomously.

> what mode am i in?
  You're in AUTONOMOUS mode.

Tip

Natural language parsing makes mode switching incredibly fast and intuitive. Just talk to Siyarix like a human teammate!


โš–๏ธ Mode Comparison

Wondering which mode is right for your current task? Here's a quick comparison to help you decide:

Aspect ๐ŸŽฏ REGISTRY ๐Ÿค– AUTONOMOUS ๐Ÿค HYBRID ๐Ÿ’ฌ INTERACTIVE
AI Required No Yes Yes Yes
User Approval No No No Yes (every step)
Planning Heuristic templates LLM-driven LLM + Registry Registry + Approval
Execution Deterministic Full Loop Auto + Guided Step-by-step
Best for Known operations Reconnaissance Complex goals Teaching & Auditing
Speed โšก Fastest ๐Ÿš€ Fast ๐Ÿšถ Moderate ๐Ÿข Slowest
Risk Profile Low Medium Medium Lowest
Autonomy Level None High Medium None

1๏ธโƒฃ REGISTRY Mode (Default)

REGISTRY Mode executes commands using predefined plan templates directly from our tool registry. It operates completely independently of AI.

โœจ Characteristics

  • No AI Dependency: Works perfectly in air-gapped, offline, or degraded network environments.
  • Deterministic: The same input will always produce the same plan. Reliability you can count on.
  • Lightning Fast: Zero LLM latency ensures instant execution.
  • Maximum Safety: No AI hallucination and zero unexpected behaviors.

๐Ÿ”„ Execution Flow

Input (e.g., scan 10.0.0.1)
  โ†’ IntentRouter classifies intent as "scan"
  โ†’ RegistryPlanner finds match: "scan" โ†’ ["nmap -sV 10.0.0.1", "nmap -sC 10.0.0.1"]
  โ†’ PermissionGate validates the action
  โ†’ RegistryExecutor safely runs the commands
  โ†’ Output is parsed, and findings are stored in the KnowledgeGraph

๐Ÿ—‚๏ธ Tool Hierarchy (RegistryPlanner)

To ensure robustness, templates are carefully organized with primary tools and built-in fallbacks (alternatives):

scan:
  primary: nmap
  alternatives: [masscan, rustscan]
  commands:
    - nmap -sV {target} -oX {output}
    - nmap -sC {target} -oX {output}

Note

If the primary tool isn't installed or fails, Siyarix automatically attempts to use the listed alternatives.


2๏ธโƒฃ AUTONOMOUS Mode

AUTONOMOUS Mode is our full-autonomy engine. You provide the goal, and the AI handles the planning and execution loop without needing per-step confirmation.

โœจ Characteristics

  • Goal-Driven: Give Siyarix an objective, sit back, and let it work.
  • LLM-Driven Planning: Plans are generated dynamically and adapt to real-time environmental feedback.
  • Observe-Reason-Act (ORA) Loop: Features a continuous feedback cycle with integrated reflection for smart decision-making.
  • Budget Enforcement: Strict token and cost limits are applied per session to prevent runaway tasks.
  • Multi-Wave Execution: The agent progressively refines its understanding across multiple execution waves.

Warning

Because AUTONOMOUS mode operates independently, it carries a medium risk profile. Always ensure your target scopes and budgets are clearly defined!

๐Ÿ”„ Execution Flow

Input ("Enumerate 10.0.0.1")
  โ†’ IntentRouter classifies the request
  โ†’ Context Manager builds the environmental context
  โ†’ AutonomousPlanner drafts the initial ExecutionPlan
  โ†’ PermissionGate & DLP (Data Loss Prevention) validate
  โ†’ AutonomousExecutor begins the ORA loop
  โ†’ Loops until: Objective Met / Max Iterations Hit / Budget Reached / User Interrupts
  โ†’ Generates a final summary and comprehensive report

๐Ÿ” The Autonomous Loop in Action

Here is an example of how the AI reasons through a task:

Iteration 1: nmap -sV 10.0.0.1 โ†’ finds ports 22, 80, 443 are open
  โ†’ Observe: Apache 2.4.41 running on port 80
  โ†’ Reason: Apache version is outdated and has known CVEs
  โ†’ Act: Execute `nikto -h 10.0.0.1:80`

Iteration 2: nikto discovers /phpmyadmin and /wp-admin
  โ†’ Observe: phpMyAdmin detected, WordPress installation found
  โ†’ Reason: phpMyAdmin is high-risk; the WordPress version is currently unknown
  โ†’ Act: Execute `curl /wp-json` to determine the WordPress version

Iteration 3: WordPress version identified as 5.6.2
  โ†’ Observe: Version 5.6.2 confirmed
  โ†’ Reason: Version 5.6.2 is vulnerable to known RCE CVEs (e.g., CVE-2021-29447)
  โ†’ Act: Verify if the target is in-scope for active exploitation
  โ†’ Conclusion: Objective achieved. Target fully enumerated. Report generated!

3๏ธโƒฃ HYBRID Mode

HYBRID Mode is the sweet spot. It offers a balanced approach by combining the dynamic reasoning of AI planning with the reliable reliability of registry fallbacks.

โœจ Characteristics

  • Default AI Mode: Automatically engaged when no explicit mode is selected but AI capabilities are active.
  • Integrated Planner: Traditional registry templates are enriched and guided by LLM reasoning.
  • Graceful Degradation: If the AI fails or loses connection, the system seamlessly falls back to the deterministic registry.
  • Moderate Autonomy: The AI suggests the best steps, but you can always override them via the Permission Gate.

๐Ÿ”„ Execution Flow

Input
  โ†’ IntentRouter
  โ†’ Context Manager builds context
  โ†’ Integrated Planner (Blends Registry + LLM Augmentation)
  โ†’ PermissionGate & DLP
  โ†’ AgentCore._execute_hybrid():
      - Uses RegistryExecutor for known, predictable patterns
      - Uses LLM augmentation for novel, complex situations
      - Shifts to AutonomousExecutor when appropriate
  โ†’ Observe-Reason-Act (capped at limited iterations)
  โ†’ Final Report

4๏ธโƒฃ INTERACTIVE Mode

INTERACTIVE Mode puts you entirely in the driver's seat. Every single planned step requires your explicit confirmation before it executes.

โœจ Characteristics

  • Maximum Safety: You see and approve every command. Nothing happens without your green light.
  • Educational: An incredible tool for learning, live demonstrations, and CTF (Capture The Flag) events.
  • Audit-Friendly: Every step is transparent, reviewed, and logged.
  • Slow & Steady: Operations are deliberate and step-by-step.

Tip

If you are learning a new tool or auditing a highly sensitive environment, INTERACTIVE mode is your best friend.

๐Ÿ”„ Execution Flow

Input
  โ†’ IntentRouter
  โ†’ RegistryPlanner (Forced into INTERACTIVE mode)
  โ†’ PermissionGate & DLP
  โ†’ ๐Ÿ›‘ User Approval Prompt for EVERY step
  โ†’ RegistryExecutor runs the approved steps
  โ†’ Results displayed โ†’ User decides the next action

๐Ÿ—๏ธ REPL Architecture

The REPL isn't just a basic prompt; it's a full-featured conversational shell housed in siyarix/chat/. Hereโ€™s a breakdown of its core components:

Module Purpose
repl.py The main entrypoint, handling the event loop and graceful Ctrl+C exits.
engine.py ReplEngine: Processes messages, routes modes, and dispatches agents.
console.py Manages gorgeous console formatting and theme applications.
commands.py Handles built-in commands (e.g., /help, /mode, /theme, /export, /clear).
handlers.py The message handler chain (Mode โ†’ Command โ†’ Intent โ†’ Fallback).
event_stream.py Manages real-time event streaming for silky-smooth LLM responses.
ui.py Powers terminal UI elements like progress bars, spinners, and status bars.
prompts.py Manages prompt templates and core system prompts.
platform_utils.py Ensures cross-platform compatibility (clipboard, terminal size, OS detection).
stubs.py Stub agents primarily used for quick demos and testing.
openai_compat.py A streaming adapter ensuring OpenAI compatibility.
session.py ChatSession: Handles conversation branching and exporting.

๐Ÿ”„ REPL Event Loop

โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚                    REPL Event Loop                      โ”‚
โ”‚                                                         โ”‚
โ”‚  Wait for user input (prompt_async)                     โ”‚
โ”‚    โ†“                                                    โ”‚
โ”‚  Check for built-in commands (/, exit)                  โ”‚
โ”‚    โ†“                                                    โ”‚
โ”‚  Check for natural language mode switch keywords        โ”‚
โ”‚    โ†“                                                    โ”‚
โ”‚  Route to appropriate agent dispatch                    โ”‚
โ”‚    โ†“                                                    โ”‚
โ”‚  AgentCore.process_instruction()                        โ”‚
โ”‚    โ†“                                                    โ”‚
โ”‚  Display real-time streaming response                   โ”‚
โ”‚    โ†“                                                    โ”‚
โ”‚  Return to prompt                                       โ”‚
โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜

๐Ÿ–ฅ๏ธ A Glimpse of the Console

We take pride in our UI. Here is what you can expect to see in the terminal:

โ•ญโ”€ Siyarix v2.0.0 โ”€ AUTONOMOUS โ”€ 10.0.0.1 โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ•ฎ
โ”‚                                                          โ”‚
โ”‚  โ„น [14:32:01] Starting autonomous reconnaissance...      โ”‚
โ”‚  โ„น [14:32:02] Mode: AUTONOMOUS | Target: 10.0.0.1        โ”‚
โ”‚                                                          โ”‚
โ”‚  โ•ญโ”€ Plan โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ•ฎ โ”‚
โ”‚  โ”‚ Step 1: nmap -sV -sC -O 10.0.0.1                    โ”‚ โ”‚
โ”‚  โ”‚ Step 2: nikto -h 10.0.0.1                           โ”‚ โ”‚
โ”‚  โ”‚ Step 3: enum4linux -a 10.0.0.1                      โ”‚ โ”‚
โ”‚  โ•ฐโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ•ฏ โ”‚
โ”‚                                                          โ”‚
โ”‚  โ ‹ Step 1: nmap scanning...                            โ”‚
โ”‚  โœ“ Step 1 complete โ€” 6 open ports found                  โ”‚
โ”‚                                                          โ”‚
โ”‚  โ ‹ Step 2: nikto scanning...                           โ”‚
โ”‚  โœ“ Step 2 complete โ€” 2 findings                          โ”‚
โ”‚                                                          โ”‚
โ”‚  โ•ญโ”€ Findings โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ•ฎ โ”‚
โ”‚  โ”‚ 10.0.0.1:80 โ†’ Apache 2.4.41 (CVE-2024-1234 Medium)  โ”‚ โ”‚
โ”‚  โ”‚ 10.0.0.1:443 โ†’ OpenSSL 1.1.1 (CVE-2024-5678 High)   โ”‚ โ”‚
โ”‚  โ”‚ 10.0.0.1:22 โ†’ OpenSSH 8.9p1                         โ”‚ โ”‚
โ”‚  โ•ฐโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ•ฏ โ”‚
โ”‚                                                          โ”‚
โ”‚  > _                                                     โ”‚
โ•ฐโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ•ฏ

๐Ÿช„ Onboarding Wizard

First time using Siyarix? If no settings.toml is found, Siyarix automatically launches the Onboarding Wizard (siyarix/onboarding.py). This interactive 11-step process ensures your environment is perfectly tuned:

Step Description
0 ๐Ÿ‘‹ Welcome & Introduction
1 ๐ŸŽจ Theme Selection (Live previews included!)
2 โš™๏ธ Default Mode Selection
3 ๐Ÿ”‘ Provider Configuration (API Keys setup)
4 ๐Ÿงช Provider Testing (Verifies your connections)
5 ๐Ÿ›ก๏ธ Security Preferences (Auto-confirm settings, DLP sensitivity)
6 ๐Ÿ“ Output Preferences (Format and verbosity levels)
7 ๐Ÿ“‚ Path Configuration (Workspace, output dirs, offline store)
8 ๐Ÿง  Learning System (Opt-in/out of auto-suggestions)
9 ๐Ÿ“‹ Review Preferences Summary
10 โœ… Apply Configuration & Restart

Info

The onboarding wizard is critical for securely handling your API keys and setting up your Data Loss Prevention (DLP) baseline. Don't skip the security preferences!


๐Ÿ“ฆ Batch Mode

Need to run Siyarix as part of a larger pipeline? Batch mode allows for robust, non-interactive execution from stdin or a provided file.

siyarix --batch commands.txt

Each line in your file is processed as a completely separate instruction.

Tip

For seamless programmatic consumption in CI/CD or automation scripts, pair batch mode with the JSON output flag: --output-format json.


๐Ÿ› ๏ธ REPL Built-in Commands Reference

Keep this handy! Here are the core built-in slash commands available within the REPL:

Command Aliases Description
/mode <mode> /m Switch your current agent mode
/theme <theme> /t Change your UI theme on the fly
/model <model> โ€” Switch the active AI model
/provider <provider> /p Switch your LLM provider
/export <format> /e Export the current session data
/clear /c Clear the current conversation history
/save โ€” Save your current session state
/load <id> โ€” Load a previously saved session
/help /h, /? Display the help menu
exit quit, /q Gracefully exit the REPL