"""
python experiments/standalone_experiments/run_extract_one_user.py
"""
import json
from pydantic import BaseModel
from worker_plan_internal.llm_factory import get_llm

class User(BaseModel):
    id: int
    name: str = "Jane Doe"

llm = get_llm("ollama-llama3.1")
# llm = get_llm("openrouter-paid-gemini-2.0-flash-001")
sllm = llm.as_structured_llm(User)

text = "location=unspecified, user id=42, role=agent, name=Simon, age=30"

response = sllm.complete(text)

json_response = json.loads(response.text)
print(json.dumps(json_response, indent=2))
