Skip to content

Commit

Permalink
leftover changes when moving from tasks to epics
Browse files Browse the repository at this point in the history
  • Loading branch information
LeonOstrez committed Jul 2, 2024
1 parent 76e7d37 commit 12da174
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 14 deletions.
12 changes: 6 additions & 6 deletions core/agents/tech_lead.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,19 +18,19 @@
log = get_logger(__name__)


class Task(BaseModel):
description: str = Field(description=("Very detailed description of a development task."))
class Epic(BaseModel):
description: str = Field(description=("Description of an epic."))


class DevelopmentPlan(BaseModel):
plan: list[Task] = Field(description="List of development tasks that need to be done to implement the entire plan.")
plan: list[Epic] = Field(description="List of epics that need to be done to implement the entire plan.")


class UpdatedDevelopmentPlan(BaseModel):
updated_current_epic: Task = Field(
description="Updated detailed description of what was implemented while working on the current development task."
updated_current_epic: Epic = Field(
description="Updated description of what was implemented while working on the current epic."
)
plan: list[Task] = Field(description="List of unfinished development tasks.")
plan: list[Epic] = Field(description="List of unfinished epics.")


class TechLead(BaseAgent):
Expand Down
5 changes: 2 additions & 3 deletions core/prompts/tech-lead/system.prompt
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
You are an experienced tech lead in a software development agency.
Your main task is to break down the project into smaller tasks that developers will do.
You must specify each task as clear as possible.
Each task must have a description of what needs to be implemented.
Your main job is to break down the project into epics that developers will do.
You must specify each epic as clear as possible.
10 changes: 5 additions & 5 deletions tests/agents/test_tech_lead.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import pytest

from core.agents.response import ResponseType
from core.agents.tech_lead import DevelopmentPlan, Task, TechLead, UpdatedDevelopmentPlan
from core.agents.tech_lead import DevelopmentPlan, Epic, TechLead, UpdatedDevelopmentPlan
from core.db.models import Complexity
from core.db.models.project_state import TaskStatus
from core.ui.base import UserInput
Expand Down Expand Up @@ -87,8 +87,8 @@ async def test_plan_epic(agentcontext):
tl.get_llm = mock_get_llm(
return_value=DevelopmentPlan(
plan=[
Task(description="Task 1"),
Task(description="Task 2"),
Epic(description="Task 1"),
Epic(description="Task 2"),
]
)
)
Expand Down Expand Up @@ -122,8 +122,8 @@ async def test_update_epic(agentcontext):
tl = TechLead(sm, ui)
tl.get_llm = mock_get_llm(
return_value=UpdatedDevelopmentPlan(
updated_current_epic=Task(description="Updated Just Finished"),
plan=[Task(description="Alternative Future Task")],
updated_current_epic=Epic(description="Updated Just Finished"),
plan=[Epic(description="Alternative Future Task")],
)
)

Expand Down

0 comments on commit 12da174

Please sign in to comment.