Skip to main content

Overview

Hyperscape agents use ElizaOS to make autonomous decisions using LLMs. Recent improvements (commit 60a03f49, Feb 26 2026) added action locks, fast-tick mode, and short-circuit decision-making for more natural MMORPG behavior.

Decision-Making Architecture

LLM Tick Cycle

Agents evaluate their situation and choose actions on a regular tick cycle: Normal Tick: 10 seconds (default) Fast Tick: 2 seconds (after movement or goal changes)

Action Locks

Problem: Agents would spam LLM calls while movement was in progress, wasting tokens and causing decision churn. Solution: Action locks prevent LLM ticks while movement is in progress:
Benefits:
  • No wasted LLM calls during movement
  • Agents commit to actions instead of constantly re-evaluating
  • More natural behavior (walk to tree, chop, don’t reconsider mid-walk)

Fast-Tick Mode

After completing an action or changing goals, agents enter fast-tick mode for quick follow-up:
Use Cases:
  • After reaching a tree → quickly decide to chop
  • After banking → quickly resume previous goal
  • After completing quest → quickly set new goal

Short-Circuit LLM

For obvious decisions, agents skip the LLM and execute immediately:
Short-Circuit Conditions:
  • Repeat resource: Same resource type nearby, inventory not full
  • Banking: Inventory ≥ 25/28 slots
  • Set goal: Goal changed externally (e.g., via dashboard)
Benefits:
  • Faster response times
  • Reduced LLM costs
  • More predictable behavior for repetitive tasks

Goal System

Goal Types

Agents can have different goal types with varying priorities:

Banking Goal

Trigger: Inventory ≥ 25/28 slots Behavior:
  1. Set banking goal with high priority
  2. Walk to nearest bank
  3. Execute BANK_DEPOSIT_ALL action
  4. Restore previous goal after banking
Goal Restoration: After banking completes, the agent automatically restores their previous goal:

Questing Goal

Trigger: Agent lacks essential tools (axe, pickaxe, tinderbox, net) Behavior:
  1. Set questing goal with highest priority
  2. Walk to quest NPC
  3. Accept quest to receive tools
  4. Resume previous goal
Tool-Granting Quests:
  • lumberjacks_first_lesson → Bronze Hatchet + Tinderbox (Forester Wilma)
  • fresh_catch → Small Fishing Net (Fisherman Pete)
  • torvins_tools → Bronze Pickaxe + Hammer (Torvin)

Movement Behavior

Await Movement Completion

Banking actions now await movement completion instead of returning early:
Benefits:
  • Agents actually reach their destination before interacting
  • No “bank too far” errors from premature interaction attempts
  • More reliable autonomous behavior

Movement Tracking

The HyperscapeService tracks movement state:

Resource Detection

Approach Range

Resource detection range was increased from 20m to 40m to fix “choppableTrees=0” errors:
Affected Actions:
  • CHOP_TREE
  • MINE_ROCK
  • CATCH_FISH
Why 40m:
  • Matches server-side skills validation range
  • Prevents “no resources nearby” errors when resources are visible
  • Agents can see and approach resources from further away

Depleted Resource Filtering

Agents now filter out depleted resources from nearby entity checks:
Benefits:
  • Agents don’t try to chop depleted trees
  • More efficient resource gathering
  • Reduces failed action attempts

LLM Context

Last Action Tracking

The LLM prompt now includes the last action and result for continuity:
Benefits:
  • LLM understands what just happened
  • Better decision continuity
  • Avoids repeating failed actions

Inventory Display

The LLM prompt now shows inventory count with warnings:
Benefits:
  • Agents know when to bank
  • Visual warnings for full inventory
  • Prevents inventory overflow

Autonomous Banking

Banking Trigger

Agents automatically bank when inventory reaches 25/28 slots:

Banking Workflow

  1. Detect full inventory (≥25/28 slots)
  2. Set banking goal with high priority
  3. Find nearest bank from nearby entities or world map
  4. Walk to bank (await movement completion)
  5. Open bank session (bankOpen packet)
  6. Deposit all items (bankDepositAll packet)
  7. Withdraw essential tools (axe, pickaxe, tinderbox, net)
  8. Close bank session (bankClose packet)
  9. Restore previous goal (e.g., woodcutting)
  10. Trigger fast tick for quick follow-up

Essential Tools

These items are never deposited (always withdrawn back):
  • Hatchets: Bronze, Iron, Steel, Mithril
  • Pickaxes: Bronze, Iron, Steel, Mithril
  • Tinderbox: For firemaking
  • Small Fishing Net: For fishing
Why Keep Tools:
  • Agents need tools to continue gathering
  • Prevents “no axe” errors after banking
  • Matches natural MMORPG player behavior

Quest-Driven Progression

Starter Chest Removal

The old LOOT_STARTER_CHEST action was removed (commit 593cd56b). Agents now get tools through quests:

Tool Acquisition Quests

Agents are guided toward quests for tools via game knowledge:
Questing Goal Priority: When agent lacks tools, questing goal has highest priority:

Performance Optimizations

Action Lock Benefits

Before (without action locks):
  • Agent starts walking to tree (10s journey)
  • LLM ticks every 10s during walk
  • 1 walk = 1 LLM call (wasted)
  • Total: 2 LLM calls (1 wasted)
After (with action locks):
  • Agent starts walking to tree (10s journey)
  • Action lock prevents LLM ticks during walk
  • Agent reaches tree
  • Fast tick triggers (2s)
  • Total: 1 LLM call (0 wasted)
Savings: 50% reduction in LLM calls for movement-heavy tasks

Short-Circuit Benefits

Before (without short-circuit):
  • Agent chops tree
  • Inventory not full, same tree type nearby
  • LLM call to decide next action
  • LLM says “chop another tree”
  • Total: 1 LLM call per tree
After (with short-circuit):
  • Agent chops tree
  • Inventory not full, same tree type nearby
  • Short-circuit: repeat last action
  • Total: 0 LLM calls (instant decision)
Savings: 100% reduction in LLM calls for repetitive tasks

Configuration

Enable/Disable Features

Tick Intervals

Debugging

Action Lock Status

Check if agent is locked:

Last Action Tracking

View last action in agent logs:

Goal History

View goal changes:

Commit History

Autonomous behavior improvements:
  • 60a03f49 (Feb 26, 2026): Action locks, fast-tick, short-circuit LLM, await banking movement
  • 593cd56b (Feb 26, 2026): Quest-driven tools, autonomous banking, resource detection fixes