Skip to navigation

User Stories

Behavior-driven stories aligned to current SDK runtime
View as Markdown

NPC Processing

Feature: NPC protocol execution
Scenario: Process one player input with API-directed protocol
Given an SDK store with an NPC registered via setNPCInfo
And a local cortex runtime is initialized
When I dispatch processNPC with npcId, text, apiUrl, and cortex
Then the SDK runs the `/npcs/{npcId}/process` continuation loop
And compatibility integrations may use directive/context/verdict sequence
And I receive dialogue and optional action in the thunk result

Memory Operations

Feature: Remote memory operations
Scenario: List and recall memories by npcId
Given a valid API URL and key
When I dispatch listMemoryRemoteThunk for an npcId
And I dispatch recallMemoryRemoteThunk with a query
Then memory entries are returned from API-backed memory endpoints

Bridge Validation

Feature: Bridge rule validation
Scenario: Validate an action payload
Given a candidate NPC action and validation context
When I dispatch validateBridgeThunk
Then I receive a validation result containing valid/reason fields

Soul Portability

Feature: Soul export and import
Scenario: Export and re-import an NPC soul
Given an active NPC in store state
When I dispatch remoteExportSoulThunk
And I dispatch importSoulFromArweaveThunk with the txId
Then I can retrieve the soul payload for reuse

CLI Operations

Feature: Node CLI operations
Scenario: Verify runtime and execute npc turn
Given API config is set using config set
When I run forbocai status
And I run forbocai npc process <npcId> <input>
Then the CLI prints protocol output or actionable errors