Skip to main content
Glama
alicenjr

Dynamic Reincarnation Story

by alicenjr

ask_guidance_questions

Presents three guidance questions to help users explore personalized reincarnation story paths based on their choices and soul-searching responses.

Instructions

Present the three guidance questions to the user

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
user_idYes

Implementation Reference

  • main.py:218-226 (handler)
    The core handler function for the 'ask_guidance_questions' tool, decorated with @mcp.tool() for registration. It retrieves user state, checks if story is started, updates context, and returns the guidance questions prompt.
    @mcp.tool() def ask_guidance_questions(user_id: str) -> str: """Present the three guidance questions to the user""" state = get_user_state(user_id) if not state["story_started"]: return "Please start the story first by typing 'Arise' or using start_story()." state["current_context"] = "Asking guidance questions to determine reincarnation path" return str(three_guidance_questions())
  • main.py:43-56 (helper)
    Helper prompt function invoked by the tool to generate the actual text of the three guidance questions.
    @mcp.prompt() def three_guidance_questions() -> str: """Three questions to guide the reincarnation choice""" return """ Before you choose your path, I must ask you three questions to guide your decision: **Question 1:** In your heart, how deep does the wound of betrayal run? Are you consumed by a need for justice against those who wronged you, or do you seek to leave that past behind and embrace a new beginning? **Question 2:** Do you yearn for a journey filled with unexpected adventures, hidden treasures, and the simple comforts of home, much like the tales of hobbits and their cozy holes? **Question 3:** Are you drawn to the call of the sea, where freedom, friendship, and the pursuit of dreams define existence, even if it means facing great dangers and challenges? Please answer these questions, and based on your responses, I shall help you determine which reincarnation suits your soul best. """
  • main.py:12-24 (helper)
    Helper function used by the tool to manage and retrieve user-specific story state.
    def get_user_state(user_id: str) -> Dict[str, Any]: """Get or create user story state""" if user_id not in story_states: story_states[user_id] = { "current_path": None, "story_step": 0, "choices_made": [], "user_answers": {}, "last_narrative": "", "current_context": "", "story_started": False } return story_states[user_id]

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/alicenjr/Dynamic-Reincarnation-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server