import asyncio
import io
import json
import sys

sys.stdout = io.TextIOWrapper(sys.stdout.buffer, encoding='utf-8')

from langchain_core.messages import HumanMessage

from agent.lead_stage_agent.controller import LeadController


async def main():
    ctrl = LeadController(device_id="test_sip")
    result = await ctrl.classifier_node({"messages": [HumanMessage(content="tìm sịp nam cực sinh")]})
    print(json.dumps(result, indent=2, ensure_ascii=False))

if __name__ == '__main__':
    asyncio.run(main())
