-
Notifications
You must be signed in to change notification settings - Fork 22
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
6716edd
commit cd58bfb
Showing
1 changed file
with
27 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
from funcchain import chain | ||
from pydantic import BaseModel | ||
|
||
|
||
class Task(BaseModel): | ||
name: str | ||
description: str | ||
difficulty: int | ||
|
||
def __str__(self) -> str: | ||
return f"{self.name}\n - {self.description}\n - Difficulty: {self.difficulty}" | ||
|
||
|
||
def plan_task(task: Task) -> str: | ||
""" | ||
Based on the task infos, plan the task step by step. | ||
""" | ||
return chain() | ||
|
||
|
||
if __name__ == "__main__": | ||
task = Task( | ||
name="Do Laundry", | ||
description="Collect and wash all the dirty clothes.", | ||
difficulty=4, | ||
) | ||
print(plan_task(task)) |