Profile Management
What Are Profiles?
Section titled “What Are Profiles?”Profiles in Rawi are named configurations that store:
- AI Provider — Which AI service to use (OpenAI, Anthropic, Ollama, etc.)
- Model Selection — Specific model within the provider
- Authentication — API keys and credentials
- Generation Settings — Temperature, max tokens, language preferences
- Provider Settings — Custom endpoints, regions, and provider-specific options
Profile Benefits
Section titled “Profile Benefits”Multiple Use Cases
Section titled “Multiple Use Cases”# Different profiles for different needsrawi configure --profile work --provider openai --model gpt-4orawi configure --profile analysis --provider anthropic --model claude-3-sonnet-20240229rawi configure --profile local --provider ollama --model llama3.2rawi configure --profile budget --provider openai --model gpt-3.5-turboEasy Switching
Section titled “Easy Switching”# Use specific profiles for tasksrawi ask "Review this code" --profile workrawi ask "Analyze this data" --profile analysisrawi ask "Quick question" --profile localIsolated Configurations
Section titled “Isolated Configurations”Each profile maintains separate:
- Conversation history
- Usage statistics
- Session management
- Provider credentials
Basic Profile Management
Section titled “Basic Profile Management”Creating Profiles
Section titled “Creating Profiles”# Interactive profile creationrawi configure --profile myprofile
# Quick profile setuprawi configure --profile work \ --provider openai \ --model gpt-4o \ --api-key sk-your-key
# Copy existing profile settingsrawi configure --profile backup --provider openai --model gpt-4oViewing Profiles
Section titled “Viewing Profiles”# List all profilesrawi configure --list
# Show specific profilerawi configure --profile work --show
# Show all profile detailsrawi info --profiles
# Quick profile overviewrawi infoUsing Profiles
Section titled “Using Profiles”# Use default profilerawi ask "How are you?"
# Use specific profilerawi ask "Code review question" --profile work
# Switch between profilesrawi ask "Data analysis task" --profile analysisrawi ask "Quick local question" --profile localProfile Configuration Strategies
Section titled “Profile Configuration Strategies”By Use Case
Section titled “By Use Case”Development Profile:
rawi configure --profile development \ --provider openai \ --model gpt-4o \ --temperature 0.2 \ --max-tokens 4096Creative Writing Profile:
rawi configure --profile creative \ --provider anthropic \ --model claude-3-opus-20240229 \ --temperature 0.8 \ --max-tokens 2048Analysis Profile:
rawi configure --profile analysis \ --provider anthropic \ --model claude-3-sonnet-20240229 \ --temperature 0.1 \ --max-tokens 4096Local/Private Profile:
rawi configure --profile private \ --provider ollama \ --model llama3.2 \ --temperature 0.5By Performance Needs
Section titled “By Performance Needs”High Performance:
rawi configure --profile performance \ --provider openai \ --model gpt-4o \ --max-tokens 4096Cost Effective:
rawi configure --profile budget \ --provider openai \ --model gpt-3.5-turbo \ --max-tokens 2048Speed Optimized:
rawi configure --profile fast \ --provider anthropic \ --model claude-3-haiku-20240307 \ --max-tokens 1024By Context Requirements
Section titled “By Context Requirements”Long Context:
rawi configure --profile longcontext \ --provider anthropic \ --model claude-3-sonnet-20240229 \ --max-tokens 8192Short Context:
rawi configure --profile quick \ --provider openai \ --model gpt-3.5-turbo \ --max-tokens 1024Advanced Profile Management
Section titled “Advanced Profile Management”Profile Templates
Section titled “Profile Templates”Common profile configurations:
Software Development:
# Primary development profilerawi configure --profile dev-main \ --provider openai \ --model gpt-4o \ --temperature 0.2 \ --language english
# Code review profilerawi configure --profile dev-review \ --provider anthropic \ --model claude-3-sonnet-20240229 \ --temperature 0.1 \ --language english
# Local development profilerawi configure --profile dev-local \ --provider ollama \ --model codellama \ --temperature 0.3Data Science:
# Analysis profilerawi configure --profile data-analysis \ --provider anthropic \ --model claude-3-opus-20240229 \ --temperature 0.1 \ --max-tokens 4096
# Visualization profilerawi configure --profile data-viz \ --provider openai \ --model gpt-4o \ --temperature 0.3 \ --max-tokens 2048Content Creation:
# Writing profilerawi configure --profile writing \ --provider anthropic \ --model claude-3-opus-20240229 \ --temperature 0.7 \ --max-tokens 3072
# Editing profilerawi configure --profile editing \ --provider openai \ --model gpt-4o \ --temperature 0.3 \ --max-tokens 2048Multi-Provider Setups
Section titled “Multi-Provider Setups”Use different providers for different strengths:
# OpenAI for codingrawi configure --profile coding \ --provider openai \ --model gpt-4o
# Anthropic for analysisrawi configure --profile analysis \ --provider anthropic \ --model claude-3-sonnet-20240229
# Ollama for privacyrawi configure --profile private \ --provider ollama \ --model llama3.2
# Google for multimodalrawi configure --profile multimodal \ --provider google \ --model gemini-proProfile-Specific Features
Section titled “Profile-Specific Features”Independent Histories
Section titled “Independent Histories”Each profile maintains separate conversation history:
# Work conversationsrawi ask "Project planning" --profile workrawi history sessions --profile work
# Personal conversationsrawi ask "Learning topic" --profile personalrawi history sessions --profile personal
# Histories don't mix between profilesProfile Statistics
Section titled “Profile Statistics”Monitor usage per profile:
# Overall statisticsrawi history stats
# Profile-specific statisticsrawi history stats --profile workrawi history stats --profile analysis
# Compare profile usagerawi info --profilesProfile-Based Session Management
Section titled “Profile-Based Session Management”Sessions are tied to profiles:
# Start session in work profilerawi ask "Architecture discussion" --profile work --new-session
# Continue session (must use same profile)rawi ask "Add database details" --profile work --session abc123
# Different profile = different sessionsrawi ask "Personal question" --profile personal --new-sessionProfile Workflows
Section titled “Profile Workflows”Development Workflow
Section titled “Development Workflow”# Daily development routinemorning_standup() { rawi ask "Review today's priorities" --profile dev-main --new-session}
code_review() { rawi ask "Review this PR" --profile dev-review < changes.diff}
architecture_planning() { rawi ask "Design system architecture" --profile dev-architect --new-session}
local_testing() { rawi ask "Quick debugging help" --profile dev-local}Research Workflow
Section titled “Research Workflow”# Research and analysis routineinitial_research() { rawi ask "Overview of topic X" --profile research --new-session}
deep_analysis() { rawi ask "Detailed analysis of Y" --profile analysis}
creative_synthesis() { rawi ask "Synthesize findings creatively" --profile creative}
final_review() { rawi ask "Review and critique" --profile review}Content Creation Workflow
Section titled “Content Creation Workflow”# Content development processbrainstorm() { rawi ask "Generate content ideas" --profile creative --new-session}
draft() { rawi ask "Write first draft" --profile writing}
edit() { rawi ask "Edit and improve" --profile editing}
optimize() { rawi ask "SEO and readability" --profile marketing}Profile Best Practices
Section titled “Profile Best Practices”Naming Conventions
Section titled “Naming Conventions”Use clear, descriptive profile names:
# Good namingrawi configure --profile work-frontendrawi configure --profile personal-learningrawi configure --profile client-projectxrawi configure --profile analysis-financial
# Avoid generic namesrawi configure --profile testrawi configure --profile temprawi configure --profile profile1Profile Organization
Section titled “Profile Organization”Structure profiles by:
- Context — work, personal, client
- Purpose — development, analysis, creative
- Provider — openai-main, anthropic-analysis
- Performance — fast-responses, detailed-analysis
Configuration Management
Section titled “Configuration Management”Keep configurations organized:
# Document your profilesrawi info --profiles > profiles-backup.txt
# Regular profile cleanuprawi configure --listrawi configure --delete unused-profile
# Backup important configurationsrawi configure --profile important --show > important-profile.configProfile Switching and Automation
Section titled “Profile Switching and Automation”Quick Profile Switching
Section titled “Quick Profile Switching”# Set up aliases for common profilesalias rawi-work="rawi ask --profile work"alias rawi-analysis="rawi ask --profile analysis"alias rawi-local="rawi ask --profile local"
# Use aliasesrawi-work "Review this architecture"rawi-analysis "Analyze this dataset"rawi-local "Quick question"Scripted Profile Usage
Section titled “Scripted Profile Usage”#!/bin/bash# Smart profile selection script
task_type=$1question=$2
case $task_type in "code") rawi ask "$question" --profile development ;; "analyze") rawi ask "$question" --profile analysis ;; "write") rawi ask "$question" --profile creative ;; "quick") rawi ask "$question" --profile local ;; *) rawi ask "$question" --profile default ;;esacEnvironment-Based Profiles
Section titled “Environment-Based Profiles”# Set profile based on environmentif [[ "$PWD" == *"/work/"* ]]; then export RAWI_PROFILE="work"elif [[ "$PWD" == *"/personal/"* ]]; then export RAWI_PROFILE="personal"else export RAWI_PROFILE="default"fi
# Use environment-based profilerawi ask "Context-aware question" --profile $RAWI_PROFILEProfile Troubleshooting
Section titled “Profile Troubleshooting”Common Issues
Section titled “Common Issues”Profile not found:
# Check available profilesrawi configure --list
# Create missing profilerawi configure --profile missing-profileAuthentication errors:
# Check profile configurationrawi configure --profile problematic --show
# Reconfigure credentialsrawi configure --profile problematic --api-key new-keyModel not available:
# Check provider modelsrawi provider --list-models your-provider
# Update model selectionrawi configure --profile your-profile --model available-modelProfile Cleanup
Section titled “Profile Cleanup”# Remove unused profilesrawi configure --delete old-profile
# Clean up profile historyrawi history cleanup --profile old-profile --days 0
# Reset profile configurationrawi configure --profile reset-me # Reconfigure interactivelyProfile Migration
Section titled “Profile Migration”# Backup current profilesrawi info --profiles > profiles-backup.txt
# Export profile historyrawi history export --profile old-profile --output old-profile-history.json
# Create new profile with same settingsrawi configure --profile new-profile --provider same --model same
# Clean up old profilerawi configure --delete old-profile