import asyncio
from sxth_mind import Mind
from sxth_mind.adapters import HabitCoachAdapter
async def main():
mind = Mind(adapter=HabitCoachAdapter())
# Daily check-ins
await mind.chat("user_1", "Did my morning workout!", project_id="habit_exercise")
await mind.chat("user_1", "Completed day 5!", project_id="habit_exercise")
await mind.chat("user_1", "Missed yesterday, feeling bad about it", project_id="habit_exercise")
# The adapter detects recovery stage and responds compassionately
state = await mind.get_state("user_1", project_id="habit_exercise")
print(f"Stage: {state['project_mind']['journey_stage']}")
asyncio.run(main())