File size: 407 Bytes
877add7
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
"""Candidate generation agent."""

from __future__ import annotations

from app.common.types import PolyGuardState
from app.models.policy.candidate_builder import build_candidates


class CandidateAgent:
    name = "CandidateAgent"

    def run(self, state: PolyGuardState) -> dict:
        candidates = build_candidates(state)
        return {"candidates": [c.model_dump(mode="json") for c in candidates]}