mirror of
https://github.com/openai/codex.git
synced 2026-04-24 14:45:27 +00:00
new prompt
This commit is contained in:
@@ -840,11 +840,53 @@ async fn submission_loop(
|
||||
|
||||
// Create a summarization request as user input
|
||||
const SUMMARIZATION_PROMPT: &str = r#"
|
||||
Please provide a summary of our conversation so far, highlighting key points,
|
||||
decisions made, and any important context that would be useful for future reference.
|
||||
This summary will be used to replace our conversation history with a more concise
|
||||
version so choose what details you will need to continue your work.
|
||||
Provide the summary directly without main title.
|
||||
You are the component that compacts a long coding session log into a structured memory object.
|
||||
|
||||
This memory will become the ONLY reference for continuing the task.
|
||||
All critical facts, user intentions, tool results, and file operations must be captured.
|
||||
Omit filler talk and commentary. Do not invent information; use "none" if evidence is missing.
|
||||
Output ONLY the XML object below. No extra text.
|
||||
|
||||
<project_memory>
|
||||
<mission>
|
||||
<!-- One concise line describing the user’s main goal. -->
|
||||
</mission>
|
||||
|
||||
<essentials>
|
||||
<!-- Bullet-like facts the agent must retain: commands, APIs, paths, configs, tickets, rules. -->
|
||||
<!-- Example:
|
||||
- Build cmd: `npm run build`
|
||||
- Repo branch: `feature/auth-refactor`
|
||||
- API version: v2
|
||||
-->
|
||||
</essentials>
|
||||
|
||||
<workspace>
|
||||
<!-- Record file interactions and key observations. -->
|
||||
<!-- Example:
|
||||
- CREATED: `tests/login.test.ts` – initial test
|
||||
- MODIFIED: `src/auth.ts` – swapped jwt library
|
||||
- DELETED: none
|
||||
-->
|
||||
</workspace>
|
||||
|
||||
<activity_log>
|
||||
<!-- Key actions and tool outputs in the recent session. -->
|
||||
<!-- Example:
|
||||
- Ran `npm test` – 1 failure in `User.test.ts`
|
||||
- Queried `grep 'oldAPI'` – 2 matches
|
||||
-->
|
||||
</activity_log>
|
||||
|
||||
<next_steps>
|
||||
<!-- Stepwise plan; mark status. -->
|
||||
<!-- Example:
|
||||
1. [DONE] Identify old API usage
|
||||
2. [NEXT] Refactor `auth.ts` to new API
|
||||
3. [TODO] Update tests
|
||||
-->
|
||||
</next_steps>
|
||||
</project_memory>
|
||||
"#;
|
||||
|
||||
let summarization_prompt = vec![InputItem::Text {
|
||||
|
||||
Reference in New Issue
Block a user