Skip to content

Commit

Permalink
added docstrings
Browse files Browse the repository at this point in the history
  • Loading branch information
DoKu88 committed Nov 19, 2024
1 parent 275dccb commit 9d7770d
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions synth_sdk/tracing/abstractions.py
Original file line number Diff line number Diff line change
Expand Up @@ -131,6 +131,10 @@ def to_dict(self):


class TrainingQuestion(BaseModel):
'''
A training question is a question that an agent (system_id) is trying to answer.
It contains an intent and criteria that the agent is trying to meet.
'''
intent: str
criteria: str
question_id: Optional[str] = None
Expand All @@ -144,6 +148,9 @@ def to_dict(self):


class RewardSignal(BaseModel):
'''
A reward signal tells us how well an agent (system_id) is doing on a particular question (question_id).
'''
question_id: Optional[str] = None
system_id: str
reward: Union[float, int, bool]
Expand All @@ -159,6 +166,10 @@ def to_dict(self):


class Dataset(BaseModel):
'''
A dataset is a collection of training questions and reward signals.
This better represents the data that is used to train a model, and gives us more information about the data.
'''
questions: List[TrainingQuestion]
reward_signals: List[RewardSignal]

Expand Down

0 comments on commit 9d7770d

Please sign in to comment.