Open source AI coding agent. Designed for large projects and real world tasks.
Go aiai-agentsai-developer-toolsai-toolsclicommand-linedeveloper-toolsgitgolanggpt-4llmopenaipolyglot-programmingterminalterminal-basedterminal-ui
Update user prompt generation with token limit awareness
Dane Schneiderfc88a7944c7f
diff --git a/app/server/model/prompts/user_prompt.go b/app/server/model/prompts/user_prompt.goindex 8879dd83..c4973183 100644--- a/app/server/model/prompts/user_prompt.go+++ b/app/server/model/prompts/user_prompt.go@@ -24,7 +24,7 @@ User's operating system details:func GetContextLoadingPromptWrapperFormatStr(params CreatePromptParams) string {s := SharedPromptWrapperFormatStr + `- ` + ArchitectSummary+ ` + GetArchitectContextSummary(params.ContextTokenLimit)return s}@@ -275,7 +275,7 @@ func GetWrappedPrompt(params UserPromptParams) string {// If we're in the context loading stage, we don't need to include the apply script summaryvar applyScriptSummary string- if currentStage.TellStage == shared.TellStagePlanning && currentStage.PlanningPhase == shared.PlanningPhasePlanning {+ if currentStage.TellStage == shared.TellStagePlanning && currentStage.PlanningPhase == shared.PlanningPhaseTasks {applyScriptSummary = ApplyScriptPlanningPromptSummary} else if currentStage.TellStage == shared.TellStageImplementation {applyScriptSummary = ApplyScriptImplementationPromptSummary