2 ms·
> Are you passing the original task in each prompt? Currently yes. Planning: Prompt + Code base summary + All tasks Code gen: Prompt + All tasks + Curre
by killerstorm 4y ago
> Are you passing the original task in each prompt?
Currently yes.
Planning: Prompt + Code base summary + All tasks
Code gen: Prompt + All tasks + Current task + Existing code
All tasks include the original task.
> If not I think that it's going to lose context of what it's trying to build overall.
It can be a problem but there's a lot of room for improvement. An obvious optimization would be to hide subtasks of completed tasks. Then, perhaps hide subtasks until model decides to focus on a particular part of the tree. Summarization is also a possible strategy, e.g. LangChain uses that approach extensively.
But I think once 32k GPT-4 it might be able to do quite a lot without these tricks.
> How are you deciding what are relevant code snippets to send?
Model receives a full list of files as well as fragments in each file.
It can then select which fragments are needed for a selected task (in the generated output task_id is before the list of relevant files).
E.g.: https://gist.github.com/killerstorm/dd6e26dc80064b7fc731d583f8d740c1#file-ktor_reddit-txt-L136 https://gist.github.com/killerstorm/dd6e26dc80064b7fc731d583...
selected_task_id: t_0_2_3_2
required_code_fragments:
src/models/Comment.ts:
- class_definition