Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.praison.ai/llms.txt

Use this file to discover all available pages before exploring further.

OpenClaw bridges Windows user hosts to MCP/HTTP tool surfaces with proper venv isolation and PowerShell execution patterns.

Quick Start

1

Create Virtual Environment

# Create project directory and venv
mkdir praisonai-claw
cd praisonai-claw
python -m venv .venv
.venv\Scripts\Activate.ps1
2

Install PraisonAI with OpenClaw

# Install with agents and tools extras
pip install "praisonai[agents,tools,claw]"

# Verify installation
praisonai --version
Get-Command praisonai | Format-List *
3

Configure Environment

# Create .env file
@'
OPENAI_API_KEY=your-api-key-here
PYTHONPATH=.
'@ | Out-File -FilePath .env -Encoding utf8
4

Launch OpenClaw Dashboard

praisonai claw
# Dashboard opens at http://localhost:8082

PowerShell Setup Script

Create a standardized setup script for repeatable deployments:
<#
.SYNOPSIS
    Setup and run PraisonAI OpenClaw on Windows
.DESCRIPTION
    Creates venv, installs dependencies, and launches OpenClaw daemon
.PARAMETER ProjectPath
    Directory to create/use for the project (default: current directory)
.PARAMETER VenvPath
    Virtual environment path (default: .venv)
.PARAMETER LaunchDashboard
    Whether to launch the dashboard after setup
#>
param(
    [string]$ProjectPath = ".",
    [string]$VenvPath = ".venv", 
    [switch]$LaunchDashboard = $true
)

$ErrorActionPreference = "Stop"

# Resolve absolute paths
$ProjectDir = Resolve-Path $ProjectPath
$VenvDir = Join-Path $ProjectDir $VenvPath

Write-Host "🦞 PraisonAI OpenClaw Windows Setup" -ForegroundColor Cyan
Write-Host "Project: $ProjectDir" -ForegroundColor Green

# Check Python availability
try {
    $PythonCmd = Get-Command python -ErrorAction Stop
    Write-Host "Python found: $($PythonCmd.Source)" -ForegroundColor Green
} catch {
    Write-Error "Python not found. Install Python 3.8+ and add to PATH"
}

# Create venv if it doesn't exist
if (!(Test-Path $VenvDir)) {
    Write-Host "Creating virtual environment..." -ForegroundColor Yellow
    python -m venv $VenvDir
}

# Activate venv
$ActivateScript = Join-Path $VenvDir "Scripts\Activate.ps1"
if (Test-Path $ActivateScript) {
    Write-Host "Activating virtual environment..." -ForegroundColor Yellow
    & $ActivateScript
} else {
    Write-Error "Virtual environment activation script not found: $ActivateScript"
}

# Verify we're in venv
$VenvPython = Join-Path $VenvDir "Scripts\python.exe"
if (Test-Path $VenvPython) {
    Write-Host "Using venv Python: $VenvPython" -ForegroundColor Green
} else {
    Write-Error "Virtual environment Python not found"
}

# Install PraisonAI with extras
Write-Host "Installing PraisonAI with OpenClaw..." -ForegroundColor Yellow
& $VenvPython -m pip install --upgrade pip
& $VenvPython -m pip install "praisonai[agents,tools,claw]"

# Verify installation
Write-Host "Verifying installation..." -ForegroundColor Yellow
$PraisonCmd = Join-Path $VenvDir "Scripts\praisonai.exe"
if (Test-Path $PraisonCmd) {
    & $PraisonCmd --version
    Write-Host "Installation verified: $PraisonCmd" -ForegroundColor Green
} else {
    Write-Error "PraisonAI command not found in venv"
}

# Create .env if it doesn't exist
$EnvFile = Join-Path $ProjectDir ".env"
if (!(Test-Path $EnvFile)) {
    Write-Host "Creating .env template..." -ForegroundColor Yellow
    @'
# OpenAI API Key (required)
OPENAI_API_KEY=your-api-key-here

# Optional: Other LLM providers
# ANTHROPIC_API_KEY=your-anthropic-key
# GOOGLE_API_KEY=your-google-key

# Python path
PYTHONPATH=.
'@ | Out-File -FilePath $EnvFile -Encoding utf8
    Write-Host "Created $EnvFile - Please add your API keys" -ForegroundColor Yellow
}

# Print diagnostics
Write-Host "`n📊 Environment Diagnostics:" -ForegroundColor Cyan
Write-Host "Working Directory: $(Get-Location)"
Write-Host "Python Path: $VenvPython"
Write-Host "PraisonAI Path: $PraisonCmd"
Write-Host "Environment File: $EnvFile"

# Launch dashboard if requested
if ($LaunchDashboard -and (Test-Path $EnvFile)) {
    Write-Host "`n🚀 Launching OpenClaw Dashboard..." -ForegroundColor Cyan
    Write-Host "Dashboard will open at http://localhost:8082" -ForegroundColor Green
    & $PraisonCmd claw
}

OpenClaw Configuration

Configure OpenClaw with absolute Windows paths and proper subprocess handling:
# OpenClaw Configuration for Windows
name: "PraisonAI OpenClaw"
description: "Windows MCP bridge for PraisonAI agents"

# Python executable path (use absolute path)
python_executable: "C:\\path\\to\\your\\project\\.venv\\Scripts\\python.exe"

# Working directory (use absolute path)
working_directory: "C:\\path\\to\\your\\project"

# Environment variables
environment:
  PYTHONPATH: "."
  OPENAI_API_KEY: "${OPENAI_API_KEY}"
  
# Subprocess configuration
subprocess:
  # Use forward slashes or escaped backslashes
  executable: ".venv/Scripts/praisonai.exe"
  args: ["claw", "--port", "8082"]
  
  # Windows-specific options
  shell: false
  capture_output: true
  timeout: 60
  
# MCP server configuration  
mcp:
  servers:
    filesystem:
      command: "python"
      args: ["-m", "mcp_server_filesystem", "C:\\path\\to\\project"]
    
    praisonai_tools:
      command: ".venv/Scripts/python.exe"
      args: ["-m", "praisonai.mcp.server"]
      
# Health check configuration
health:
  endpoint: "http://localhost:8082/health"
  interval: 30
  timeout: 5

Verification Checklist

  • Python 3.8+ installed and in PATH
  • Virtual environment created and activated
  • PraisonAI installed with [agents,tools,claw] extras
  • .env file created with API keys
  • Paths use absolute Windows format
# Verify PraisonAI installation
praisonai --version

# Test OpenClaw launch
praisonai claw --help

# Check available tools
praisonai tools list

# Verify MCP connectivity
Invoke-RestMethod -Uri "http://localhost:8082/health" -Method Get
# List available MCP servers
praisonai mcp list

# Test tool functionality
praisonai test-agent "List files in current directory"

# Verify subprocess paths
Get-Process | Where-Object {$_.ProcessName -like "*python*"}
  • .env file not committed to version control
  • API keys stored securely (Windows Credential Manager for production)
  • Virtual environment isolated from global Python
  • PowerShell execution policy allows script execution
  • Firewall allows localhost:8082 (if needed)

Common Windows Issues

# Check current policy
Get-ExecutionPolicy

# Allow script execution (if needed)
Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope CurrentUser

# Or run with bypass (temporary)
PowerShell -ExecutionPolicy Bypass -File .\Setup-PraisonClaw.ps1

Production Deployment

1

Service Installation

# Install as Windows Service (requires admin)
# Create service wrapper script
$ServiceScript = @'
& "C:\path\to\project\.venv\Scripts\praisonai.exe" claw --port 8082
'@

# Register service (using NSSM or sc.exe)
nssm install PraisonAIClaw PowerShell -ExecutionPolicy Bypass -File service.ps1
nssm set PraisonAIClaw Start SERVICE_AUTO_START
2

Security Configuration

# Use Windows Credential Manager for API keys
cmdkey /generic:praisonai_openai /user:api /pass:your-actual-key

# Update .env to read from credential store
# OPENAI_API_KEY will be read from secure storage
3

Monitoring Setup

# Health check script
$HealthCheck = @'
$Response = Invoke-RestMethod -Uri "http://localhost:8082/health" -TimeoutSec 5
if ($Response.status -ne "ok") {
    Restart-Service PraisonAIClaw
}
'@

# Schedule health checks
Register-ScheduledTask -TaskName "PraisonClawHealth" -Trigger (New-ScheduledTaskTrigger -RepetitionInterval (New-TimeSpan -Minutes 5) -Once -At (Get-Date))

PraisonAI Claw

Core Claw concepts and features

MCP Integration

Model Context Protocol setup