Prompt: The instruction or input you give a generative AI tool to get a response, such as a question, a task, examples, and any context it needs.
Example
A weak prompt: "write test cases". A better one: "Write 8 test cases for a login form with email and password fields. Include invalid emails, empty fields, wrong passwords, and a locked account. Use a table with steps and expected results."
What Makes a Good Prompt
| Part | Example |
|---|---|
| Role or context | You are reviewing Java code for a banking app |
| Task | Find bugs and security issues in this method |
| Input | The code, data, or document to work on |
| Constraints | Don't change the method signature; Java 17 |
| Output format | A numbered list with line numbers and fixes |
Common Prompting Mistakes
- Being vague, then blaming the tool for a vague answer.
- Leaving out key context, such as the language version or business rule.
- Asking for many unrelated things in one prompt.
- Trusting the output without checking it.
- Pasting confidential code or customer data into tools your company hasn't approved.
Prompts in Applications
When developers build AI features, prompts are part of the code: templates with instructions, examples, and retrieved data inserted at runtime. They are versioned, tested with sample inputs, and improved over time, just like other code. See large language model.
Related terms
- Generative AI: the tools prompts are written for.
- Large Language Model (LLM): the models that respond to prompts.
- Artificial Intelligence (AI): the broader field.
- Communication Skills: clear prompts need clear writing.
Previous term: Project Discussion | Next term: Pull
Related guides
- AI/ML vs Software Development
- How to Get an IT Internship Without Experience
- Which Technology Should I Learn for an IT Internship?
Frequently asked questions
What is a prompt in AI?
A prompt is the instruction or input you give a generative AI tool, such as a question, task, and context.
How do I write a good prompt?
Give context, a clear task, the input, any constraints, and the output format you want.
What is prompt engineering?
Designing and testing prompts so an AI model gives reliable, useful outputs, especially inside applications.
Is it safe to paste company code into AI tools?
Only into tools your company has approved. Many companies restrict this to protect confidential code and data.
Explore more internship terms
The IT Internship Glossary explains 199 terms you will hear before and during your internship, with simple definitions and real examples.
Browse all 199 terms