-
Notifications
You must be signed in to change notification settings - Fork 75
(EAI-1272): [docs] Context engineering guide #893
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
||
## GPT-4.1 Prompting Guide | ||
|
||
The [GPT-4.1 Prompting Guide](https://cookbook.openai.com/examples/gpt4-1_prompting_guide) is an excellent general reference for prompting and context engineering. The OpenAI team wrote the guide specifically for the GPT-4.1 family of models, though its applicable to all LLMs. The MongoDB Responses API uses GPT-4.1 under the hood, so this guide is particularly applicable. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we'll need to remember to update this in the future if we switch model (versions)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes, good point. i think it's a great general reference. but openai has also published one for GPT-5 https://cookbook.openai.com/examples/gpt-5/gpt-5_prompting_guide
1. Contextualizing what the model about where it is and what it should do. | ||
1. Telling the model how to format its output | ||
1. Providing user-specific information to keep in mind | ||
1. How and when the model should use tools | ||
1. Key facts or pieces of knowledge that the model should always consider when responding |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
1. Contextualizing what the model about where it is and what it should do. | |
1. Telling the model how to format its output | |
1. Providing user-specific information to keep in mind | |
1. How and when the model should use tools | |
1. Key facts or pieces of knowledge that the model should always consider when responding | |
1. Contextualizing what the model about where it is and what it should do. | |
2. Telling the model how to format its output | |
3. Providing user-specific information to keep in mind | |
4. How and when the model should use tools | |
5. Key facts or pieces of knowledge that the model should always consider when responding |
it looks like this numbered list renders correctly on the github review tool but probably should fix the numbering (it's all ones) here anyway
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this is actually valid markdown. it's saying "put the numbers in order". this way you dont need to update all numbers if you add element to list.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
requesting 1 minor change but approved!
Jira: https://jira.mongodb.org/browse/EAI-1272
Changes
Notes