Skip to main content

Modes and Context

Understanding Query Modes

Orion's three modes adjust the system message sent to the AI—essentially giving the AI different "instructions" for how to respond.

flowchart LR
User["Your Question"]
ModeSelect{{"Selected Mode"}}
Orbital["Orbital Context:<br/>Broad UE5, accessible language"]
Cpp["C++ Context:<br/>Code-focused, UCLASS syntax"]
DeepScan["Deep Scan Context:<br/>Technical, BP nodes, optimization"]
AI["AI Response"]

User --> ModeSelect
ModeSelect -->|"Orbital (Ask)"| Orbital
ModeSelect -->|"C++ Mode"| Cpp
ModeSelect -->|"Deep Scan"| DeepScan
Orbital --> AI
Cpp --> AI
DeepScan --> AI

Orbital (Ask Mode)

Use Orbital when:

  • You're learning a new Unreal Engine concept
  • You have a general question ("How does X work?")
  • You're exploring options ("What's the best way to do Y?")
  • You want beginner-friendly explanations

AI behavior:

  • Broad UE5 knowledge base
  • Explains concepts in accessible language
  • Provides context and reasoning, not just code
  • Links to official documentation when relevant

Example conversations:

Q: "How do I make a pickup item that the player can collect?"

A: "To create a collectible pickup item in Unreal Engine, you typically:

  1. Create an Actor Blueprint for the pickup (e.g., BP_Pickup)
  2. Add a Static Mesh Component for the visual representation (coin, health pack, etc.)
  3. Add a Box Collision or Sphere Collision component
  4. Enable 'Generate Overlap Events' on the collision
  5. Create an Event 'OnComponentBeginOverlap' for the collision
  6. Check if the overlapping actor is the player (Cast to your player character class)
  7. If yes, apply the pickup effect (add health, add points, etc.)
  8. Destroy the pickup actor (or disable it and play a collection effect)

For a more polished experience, consider adding a rotating movement component, a particle effect, and a sound cue when collected."

C++ Mode

Use C++ Mode when:

  • You need actual code snippets
  • You're writing or modifying C++ classes
  • You want API reference lookups
  • You need UCLASS/UFUNCTION/UPROPERTY syntax help

AI behavior:

  • C++ syntax focused
  • Uses proper Unreal Engine macros and conventions
  • Provides header and implementation code
  • References UE5 API documentation

Example conversation:

Q: "Generate a C++ class for a health component with TakeDamage, Heal, and a delegate for health changes"

A: "Here's a complete health component implementation:

// HealthComponent.h
#pragma once

#include "CoreMinimal.h"
#include "Components/ActorComponent.h"
#include "HealthComponent.generated.h"

DECLARE_DYNAMIC_MULTICAST_DELEGATE_TwoParams(FOnHealthChanged, float, NewHealth, float, MaxHealth);

UCLASS(ClassGroup=(Custom), meta=(BlueprintSpawnableComponent))
class YOURGAME_API UHealthComponent : public UActorComponent
{
GENERATED_BODY()

public:
UHealthComponent();

UPROPERTY(EditAnywhere, BlueprintReadWrite, Category="Health")
float MaxHealth = 100.0f;

UPROPERTY(BlueprintReadOnly, Category="Health")
float CurrentHealth;

UPROPERTY(BlueprintAssignable, Category="Health")
FOnHealthChanged OnHealthChanged;

UFUNCTION(BlueprintCallable, Category="Health")
void TakeDamage(float DamageAmount);

UFUNCTION(BlueprintCallable, Category="Health")
void Heal(float HealAmount);

UFUNCTION(BlueprintCallable, BlueprintPure, Category="Health")
float GetHealthPercentage() const { return CurrentHealth / MaxHealth; }

protected:
virtual void BeginPlay() override;
};
// HealthComponent.cpp
#include "HealthComponent.h"

UHealthComponent::UHealthComponent()
{
PrimaryComponentTick.bCanEverTick = false;
CurrentHealth = MaxHealth;
}

void UHealthComponent::BeginPlay()
{
Super::BeginPlay();
CurrentHealth = MaxHealth;
}

void UHealthComponent::TakeDamage(float DamageAmount)
{
if (DamageAmount <= 0.0f) return;

CurrentHealth = FMath::Max(0.0f, CurrentHealth - DamageAmount);
OnHealthChanged.Broadcast(CurrentHealth, MaxHealth);

if (CurrentHealth <= 0.0f)
{
// Owner died
UE_LOG(LogTemp, Warning, TEXT("%s died"), *GetOwner()->GetName());
}
}

void UHealthComponent::Heal(float HealAmount)
{
if (HealAmount <= 0.0f) return;

CurrentHealth = FMath::Min(MaxHealth, CurrentHealth + HealAmount);
OnHealthChanged.Broadcast(CurrentHealth, MaxHealth);
}

Usage: Add this component to your player character, enemy actors, or any damageable object. Bind to OnHealthChanged delegate to update UI (health bars, etc.)."

Deep Scan (Blueprint Mode)

Use Deep Scan when:

  • You're debugging a Blueprint
  • You want performance optimization suggestions
  • You need technical, node-level analysis
  • You're using the Blueprint toolbar or right-click analysis

AI behavior:

  • Highly technical responses
  • Node-level detail ("The Branch node on line 34...")
  • Blueprint/C++ interop knowledge
  • Optimization and performance focus

Note: Deep Scan is automatically selected when you:

  • Use the Blueprint toolbar Send button
  • Use Content Browser right-click "Blueprint: Graph Flow" or "Full Graph"
  • (If "Graph Analysis Uses Deep Scan Mode" setting is enabled)

Example conversation:

Q: "Analyze this Blueprint for performance issues" (after sending BP_EnemyAI)

A: "I've analyzed BP_EnemyAI. Here are performance concerns:

  1. Tick event is enabled and active: The Tick event has 12 nodes that execute every frame. This includes GetAllActorsOfClass (very expensive) and distance calculations. Recommendation: Disable Tick and use a Timer with 0.1-0.5 second interval. Enemies don't need frame-perfect updates.

  2. GetAllActorsOfClass called frequently: In the LookForTarget function, GetAllActorsOfClass(PlayerCharacter) is called every time. Recommendation: Cache the player reference in BeginPlay and reuse it.

  3. Heavy operations in BeginPlay: BeginPlay has 50+ nodes including level load operations. If you have many enemies, this will cause hitching. Recommendation: Split initialization into BeginPlay (essentials only) and a delayed Initialize function (called 0.1s later via Timer).

  4. Unused variables: Variables 'DebugMode' and 'TestCounter' are defined but never used. Consider removing them."

Switching Modes

How to switch:

  1. Look at the top-left of the Orion chat window
  2. Click the mode dropdown (shows current mode: "Orbital", "C++ Mode", or "Deep Scan")
  3. Select the mode you want
  4. Next query you send will use the new mode

Important:

  • Mode change affects future queries only (doesn't re-process old messages)
  • You can switch modes mid-conversation
  • No need to clear chat or restart

Screenshot Placeholder: [Chat window with mode dropdown in top-left corner expanded, showing three radio button options: "Orbital (Ask)" (selected), "C++ Mode", "Deep Scan (Blueprint)"]

Conversation Context

By default, Orion treats each query as independent. The AI doesn't remember what you asked previously.

Enable memory:

Settings > Interface > Use Conversation Context (Experimental)

When enabled:

  • Orion sends your last N messages (default 10) with each new query
  • The AI can reference prior conversation
  • Follow-up questions work naturally without repeating yourself

Example with context disabled:

  • You: "How do I make a health bar?"
  • AI: [explains]
  • You: "Show that in C++"
  • AI: "Show what in C++?" (doesn't remember the health bar)

Example with context enabled:

  • You: "How do I make a health bar?"
  • AI: [explains Blueprint approach]
  • You: "Show that in C++"
  • AI: [provides C++ health component code] (remembers you were asking about health bars)

Adjusting context size:

  • Settings > Interface > Max Context Messages (0-35)
  • Lower = cheaper (fewer tokens sent), but AI forgets older messages
  • Higher = better memory, but costs more tokens

Cost consideration:

Sending 10 prior messages with each query can double or triple your token usage. Use conversation context when:

  • You're having a multi-turn discussion
  • You're refining an idea iteratively
  • Follow-up questions are essential

Disable it when:

  • Asking one-off questions
  • Token cost is a concern
  • Each query is independent

Screenshot Placeholder: [Settings window showing Interface category with "Use Conversation Context" checkbox checked and "Max Context Messages" slider set to 10, with tooltip visible explaining the feature]