ReactorAI Logo

ReactorAI Prompting Guide

Master the art of AI communication with effective prompting techniques

📚 Prompting Basics

Effective prompting is the key to getting the best results from AI models. Here are the fundamental principles:

Core Principles

  • Be Specific: Clear, detailed requests yield better results
  • Provide Context: Give the AI background information
  • Set Expectations: Define the format and style you want
  • Iterate: Refine your prompts based on responses

Prompt Structure

[Context] + [Task] + [Format] + [Constraints]

🎯 Advanced Techniques

Chain of Thought Prompting

Ask the AI to think step-by-step for complex problems:

Example: "Solve this step by step, showing your reasoning at each stage..."

Role-Based Prompting

Assign a specific role or persona to the AI:

Example: "Act as a senior software engineer and review this code..."

Few-Shot Learning

Provide examples of the desired input-output format:

Example: "Here are 2 examples of good summaries: [examples]. Now summarize this text in the same style..."

🦙 Ollama-Specific Tips

Model Selection

  • Llama 3.2: Great for general conversation and reasoning
  • Code Llama: Optimized for programming tasks
  • Mistral: Excellent for multilingual tasks
  • Phi-3: Fast responses, good for quick tasks

Context Management

Ollama models have context limits. For long conversations:

  • Summarize previous context when needed
  • Use ReactorAI's context selection feature
  • Start new sessions for different topics

💎 Gemini-Specific Tips

Gemini Model Variants

  • Gemini Pro: Best for complex reasoning and analysis
  • Gemini Flash: Faster responses for simpler tasks

Leveraging Gemini's Strengths

  • Multimodal: Combine text with images for richer context
  • Large Context: Can handle very long documents
  • Code Understanding: Excellent at code analysis and generation

⚙️ Session Prompts (System Messages)

Use ReactorAI's session prompt feature to set consistent behavior:

General Assistant

You are a helpful, accurate, and concise assistant. Always provide clear explanations and ask for clarification when needed.

Code Review Assistant

You are an expert code reviewer. Focus on code quality, security, performance, and best practices. Provide specific, actionable feedback.

Creative Writing Partner

You are a creative writing assistant. Help brainstorm ideas, improve prose, and provide constructive feedback on writing style and structure.

💡 Example Prompts

Code Generation

Prompt:

Create a Python function that validates email addresses. Include error handling, type hints, and docstrings. Test it with both valid and invalid examples.

Data Analysis

Prompt:

Analyze this sales data and identify the top 3 trends. Present your findings in a clear format with actionable recommendations: [paste data]

Learning Assistant

Prompt:

Explain quantum computing to me like I'm a computer science student. Use analogies, provide examples, and suggest resources for deeper learning.

🔧 Troubleshooting Common Issues

Getting Inconsistent Results

  • Make your prompts more specific
  • Use session prompts for consistent behavior
  • Provide more context and examples

Responses Too Long/Short

  • Specify desired length explicitly
  • Use phrases like "briefly explain" or "provide a detailed analysis"
  • Give examples of the desired length

AI Not Following Instructions

  • Break complex requests into smaller steps
  • Use numbered lists for multi-part instructions
  • Emphasize critical requirements