start_story
Begin interactive reincarnation storytelling by providing a user ID to generate personalized narrative paths where choices shape character transformations after death.
Instructions
Alternative way to start the story programmatically
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| user_id | Yes |
Implementation Reference
- main.py:202-216 (handler)The handler function for the 'start_story' MCP tool. It initializes the user's story state to the beginning and returns the initial narrative response using arise_trigger_response and initial_reincarnation_offer.@mcp.tool() def start_story(user_id: str) -> str: """Alternative way to start the story programmatically""" state = get_user_state(user_id) state.update({ "current_path": None, "story_step": 0, "choices_made": [], "user_answers": {}, "last_narrative": "", "current_context": "Beginning: User has died and is offered reincarnation", "story_started": True }) return str(arise_trigger_response()) + "\n\n" + str(initial_reincarnation_offer())
- main.py:202-202 (registration)The @mcp.tool() decorator registers the start_story function as an MCP tool.@mcp.tool()