mirror of
https://github.com/Pythagora-io/gpt-pilot.git
synced 2026-01-09 21:27:53 -05:00
update project stages
This commit is contained in:
@@ -37,6 +37,8 @@ class Frontend(FileDiffMixin, BaseAgent):
|
||||
|
||||
:return: AgentResponse.done(self)
|
||||
"""
|
||||
await self.ui.send_project_stage({"stage": ProjectStage.PROJECT_DESCRIPTION})
|
||||
|
||||
description = await self.ask_question(
|
||||
"Please describe the app you want to build.",
|
||||
allow_empty=False,
|
||||
@@ -108,7 +110,7 @@ class Frontend(FileDiffMixin, BaseAgent):
|
||||
"""
|
||||
Continues building the frontend of the app after the initial user input.
|
||||
"""
|
||||
await self.ui.send_project_stage({"stage": ProjectStage.FRONTEND})
|
||||
await self.ui.send_project_stage({"stage": ProjectStage.CONTINUE_FRONTEND})
|
||||
await self.send_message("Continuing to build UI... This may take a couple of minutes")
|
||||
|
||||
llm = self.get_llm(FRONTEND_AGENT_NAME)
|
||||
@@ -141,6 +143,8 @@ class Frontend(FileDiffMixin, BaseAgent):
|
||||
# update the pages in the knowledge base
|
||||
await self.state_manager.update_implemented_pages_and_apis()
|
||||
|
||||
await self.ui.send_project_stage({"stage": ProjectStage.ITERATE_FRONTEND})
|
||||
|
||||
answer = await self.ask_question(
|
||||
"Do you want to change anything or report a bug? Keep in mind that currently ONLY frontend is implemented.",
|
||||
buttons={
|
||||
|
||||
@@ -250,6 +250,8 @@ class Troubleshooter(ChatWithBreakdownMixin, IterationPromptMixin, RelevantFiles
|
||||
extra_info = "restart_app" if not self.current_state.iterations else None
|
||||
|
||||
while True:
|
||||
await self.ui.send_project_stage({"stage": ProjectStage.GET_USER_FEEDBACK})
|
||||
|
||||
test_message = "Please check if the app is working"
|
||||
if user_instructions:
|
||||
hint = " Here is a description of what should be working:\n\n" + user_instructions
|
||||
|
||||
@@ -6,7 +6,10 @@ from pydantic import BaseModel
|
||||
|
||||
class ProjectStage(str, Enum):
|
||||
PROJECT_NAME = "project_name"
|
||||
FRONTEND = "frontend"
|
||||
PROJECT_DESCRIPTION = "project_description"
|
||||
CONTINUE_FRONTEND = "continue_frontend"
|
||||
ITERATE_FRONTEND = "iterate_frontend"
|
||||
GET_USER_FEEDBACK = "get_user_feedback"
|
||||
OPEN_PLAN = "open_plan"
|
||||
STARTING_TASK = "starting_task"
|
||||
BREAKDOWN_CHAT = "breakdown_chat"
|
||||
|
||||
Reference in New Issue
Block a user