feat: semantically determine goal completion
ref: N25B-432
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
from pydantic import BaseModel
|
||||
|
||||
from control_backend.schemas.program import Belief as ProgramBelief
|
||||
from control_backend.schemas.program import Goal
|
||||
|
||||
|
||||
class BeliefList(BaseModel):
|
||||
@@ -12,3 +13,7 @@ class BeliefList(BaseModel):
|
||||
"""
|
||||
|
||||
beliefs: list[ProgramBelief]
|
||||
|
||||
|
||||
class GoalList(BaseModel):
|
||||
goals: list[Goal]
|
||||
|
||||
@@ -13,6 +13,9 @@ class Belief(BaseModel):
|
||||
name: str
|
||||
arguments: list[str] | None
|
||||
|
||||
# To make it hashable
|
||||
model_config = {"frozen": True}
|
||||
|
||||
|
||||
class BeliefMessage(BaseModel):
|
||||
"""
|
||||
|
||||
@@ -117,7 +117,7 @@ class Goal(ProgramElement):
|
||||
:ivar can_fail: Whether we can fail to achieve the goal after executing the plan.
|
||||
"""
|
||||
|
||||
description: str
|
||||
description: str = ""
|
||||
plan: Plan
|
||||
can_fail: bool = True
|
||||
|
||||
|
||||
Reference in New Issue
Block a user