Understanding Prompt Engineering Basics
Understanding Prompt Engineering Basics
Prompting
What is a Prompt?
• A prompt is a text string that a user provides to a language model
to make it do something useful.
• The prompt acts as input context for the model.
• The language model generates tokens based on the prompt and
its learned patterns.
• The goal is to produce useful, relevant outputs aligned with the
user’s intent.
What is Prompt Engineering?
• The process of finding effective prompts for specific tasks is
called Prompt Engineering.
• It involves designing the right instructions or examples to guide
the model’s behavior.
• Prompt engineering helps achieve more accurate and controlled
results.
Example – Sentiment Classification Using
Prompting
• Task: Determine the sentiment of a hotel review.
• Sample Hotel Review (from BLT corpus):
• “Did not like the service that I was provided when I entered the
hotel.
• I also did not like the area in which the hotel was located.
• Too much noise and events going on for me to feel relaxed.”
Extending the Prompt
• We can help the model classify the review by adding an
incomplete statement at the end.
• Example Prompt:
• “Did not like the service that I was provided when I entered the
hotel.
• I also did not like the area in which the hotel was located.
• Too much noise and events going on for me to feel relaxed.
• In short, our stay was”
• The model will then generate a completion for the sentence.
Model-Generated Completions
• Completions produced by the LLM:
1. “... not a pleasant one. The staff at the front desk were not
welcoming or friendly, and seemed disinterested in providing good
customer service.”
2. “... uncomfortable and not worth the price we paid. We will not be
returning to this hotel.”
Model-Generated Completions
• Completions produced by the LLM:
1. “... not a pleasant one. The staff at the front desk were not
welcoming or friendly, and seemed disinterested in providing good
customer service.”
2. “... uncomfortable and not worth the price we paid. We will not be
returning to this hotel.”
Interpretation
• The overall negative tone of the review leads to negative
completions.
• This shows that the model understands sentiment context.
• We can map these completions to sentiment classes, for
example:
• excellent → positive
• did not like → negative
Power of Prompting
• With proper prompt design, a single LLM can handle many
different tasks, such as:
• Sentiment analysis
• Text completion
• Translation
• Summarization
• Question answering
• The context of the prompt is key to generating meaningful outputs.
Learning from Demonstrations: Few-Shot
Prompting
• Few-shot prompting improves prompts by including labeled
examples, called demonstrations.
• Demonstrations show the model what the task looks like and how
to respond.
• Few-shot prompting contrasts with zero-shot prompting, which
includes only instructions without examples.
• These examples guide the model to generate better, task-specific
outputs.
Definition: Reading
Comprehension Task
[Link]
[Link]
The Rise of Advanced Prompting
Techniques
Least-to-Most Prompting
Breaks complex problems into sequential subproblems, boosting accuracy in mathematics,
mathematics, diagnostics, and other hierarchical reasoning tasks.
[Link]
Multimodal and Autonomous Prompting: The Next Frontier
Prompt engineering has evolved beyond text into a rich, multidimensional discipline spanning images, audio, code, and more.
[Link]
Democratising AI: Accessibility and Ethical Prompting
Breaking Down Barriers
Natural language interfaces and adaptive prompting are empowering non-technical users to harness AI
to harness AI without deep technical expertise. These advances are making sophisticated AI accessible
AI accessible to marketing teams, healthcare professionals, and educators.
Ethical Imperatives
As AI becomes ubiquitous, ethical prompting practices are critical to mitigate bias, ensure fairness, and
fairness, and maintain transparency—particularly in high-stakes domains like hiring, healthcare
healthcare diagnostics, and financial services.
Generative AI is increasingly used to create and optimise prompts, making prompt engineering more accessible and scalable than ever before.
[Link]
Industry Impact: Real-World Applications Driving Demand
[Link]
Essential Skills for Tomorrow's Prompt Engineers
Hybrid Expertise Cost Optimisation Advanced Frameworks
Part UX designer, part software architect— Crafting prompts that reduce token usage by Mastery of prompt chaining frameworks,
architect—fluent in data types, instruction usage by 30% or more can save enterprises frameworks, multi-agent orchestration, and
instruction tuning, and model bias awareness. enterprises thousands in API costs whilst and real-time A/B testing simulations
awareness. The modern prompt engineer whilst maintaining output quality. separates good from exceptional
engineer bridges technical and creative practitioners.
domains.
[Link]
The Future Outlook: Evolution or
Transformation?
1 Current State
Manual prompt crafting dominates, requiring significant human expertise and iteration
to achieve optimal results.
2 Near Future
AI models become more context-aware and self-instructing, potentially reducing routine
reducing routine manual prompt engineering tasks.
3 Long-Term Vision
Human creativity and strategic design remain vital for nuanced, safe, and cost -effective
cost-effective AI applications—shifting from craft to orchestration.
The balance of human-AI collaboration will define prompt engineering's evolving role. Whilst
Whilst automation increases, strategic thinking, ethical considerations, and creative application ensure
application ensure human expertise remains indispensable.
[Link]
Embrace the Prompt Engineering
Engineering Revolution Today
A Career-Defining Skill
Prompt engineering is no longer optional—it's shaping the AI-powered future across
future across every industry and professional domain.
Invest in Mastery
Master advanced techniques, multimodal tools, and ethical frameworks to unlock
to unlock AI's full potential and position yourself at the forefront of innovation.
innovation.
[Link]
Fine-Tuning AI Models with
Custom Prompts
Technical Insights & Ethical Considerations
[Link]
What is Fine-Tuning in AI?
Maintenance Burden
Significant maintenance overhead emerges as fine-tuned models require costly retraining whenever
data evolves or base models update. This creates ongoing resource demands.
Rapid Obsolescence
Base models improve at breakneck speed. Fine-tuned versions can quickly become outdated as newer
foundation models offer superior performance without customisation.
[Link]
Prompt Engineering vs Fine-Tuning
Understanding the key differences helps determine the right approach for your use case.
Definition Modifies input prompts to guide output Adjusts model weights on custom data
[Link]
Ethical Challenges in Fine-Tuning AI Models
[Link]
Real-World Safety Risks: Research Insights
Key Research Findings
Stanford and Princeton studies reveal alarming vulnerabilities in fine-tuned models, demonstrating how customisation can
customisation can unintentionally degrade safety measures.
Safety Degradation 10
Fine-tuning can degrade safety alignment even without malicious intent, creating unexpected vulnerabilities.
vulnerabilities.
Harmful Responses
Adversarial Examples
Fine-tuned models may respond affirmatively to harmful prompts, dramatically increasing risks of misuse.
Number needed to bypass safety filters in GPT-3.5 Turbo
73%
Safety Reduction
Critical insight: Current safety infrastructures are insufficient to fully prevent these risks after fine-tuning, necessitating
tuning, necessitating stronger mitigation strategies and oversight.
[Link]
Best Practices for Ethical Fine-Tuning
01
02
Feedback Loops
Implement human and AI feedback loops to continuously monitor and correct model outputs during and after training.
03
Multi-Layered Safeguards
Deploy multi-layered safeguards at data, input, and output stages to catch potential issues before they reach users.
reach users.
04
Transparent Communication
Maintain transparency with users about AI limitations, risks, and the fine-tuning process used to create the model.
model.
[Link]
The Future: Balancing Customisation and Responsibility
Emerging Approaches
The landscape of AI customisation is evolving rapidly, with new strategies emerging to balance
balance performance with ethical considerations.
Hybrid Approaches
Combining prompt engineering with selective fine-tuning may optimise performance whilst
performance whilst maintaining safety.
Policymakers and developers must collaborate to enforce ethical standards and effective
effective risk mitigation strategies.
"Ethical AI development is the key to building trust and unlocking AI's full
[Link]
full potential for society."
Fine-Tuning with Care
Powerful but Complex Ongoing Vigilance Required
Fine-tuning offers powerful customisation
capabilities but comes with significant Thoughtful application, continuous
ethical and safety challenges that require oversight, and robust safeguards are
careful navigation. essential to responsible fine-tuning
practices.
Together, we can harness AI's promise whilst protecting users and society. The future of AI
depends on our collective commitment to ethical development and responsible deployment.
[Link]
Future Trends and Opportunities
in Prompt Engineering
[Link]
The Rise of Prompt Engineering: A
Engineering: A New AI Frontier
The Critical Bridge A Bold Prediction
Prompt engineering serves as the Baidu's Robin Li forecasts: "In 10 years,
essential translator between human half of the world's jobs will be in
intent and AI output, optimising prompt engineering"—signalling a
generative AI systems like GPT-4 and transformative shift in how we work
LLaMA to deliver precise, meaningful with AI.
results.
Today's Reality
Modern prompt engineers craft precise inputs that unlock AI's full potential, driving
driving innovation and efficiency across industries worldwide.
[Link]
From Crafting Prompts to Autonomous AI Agents
Advanced Context Understanding
Emerging AI models such as GPT-4.5, Google Gemini, and Anthropic Claude 3 demonstrate
demonstrate sophisticated contextual awareness, significantly reducing the need for complex,
for complex, carefully structured prompts.
Self-Optimising Systems
Autonomous agents like AutoGPT and BabyAGI represent a paradigm shift—they generate,
generate, evaluate, and refine their own prompts through recursive learning processes.
processes.
[Link]
Expanding Horizons: Multimodal and Adaptive Prompting
Prompting
Holistic Solutions
This comprehensive approach complements traditional prompt engineering,
engineering, creating more reliable, scalable, and production-ready AI
AI solutions.
[Link]
Prompt Engineering's Expanding Job Landscape
Prompt Engineer
£60K–£150K: Crafting and optimising AI prompts for business applications
Conversational AI Designer
£68K–£120K: Designing natural dialogue systems and chatbot experiences
AI Ethicist
£75K–£140K: Ensuring responsible, unbiased AI development and deployment
AI UX Designer
£65K–£130K: Creating intuitive interfaces for AI-powered products
AI Product Manager
£85K–£160K: Strategising AI product development and market positioning
Industries hiring span technology, healthcare, finance, education, and telecommunications—from global tech giants to innovative startups like Telkomsel's AI network optimisation initiatives.
optimisation initiatives.
[Link]
Democratising AI: No-Code Tools and User-Friendly Interfaces
Accessible Platforms
Industry Investment
Tech leaders like Microsoft, Google, and OpenAI are investing heavily in intuitive AI
interaction systems that bridge the gap between expert and novice users.
[Link]
Ethical and Responsible Prompting
Prompting
Embedding Guardrails Aligning with Values
As AI systems gain power and influence, Responsible prompting ensures AI
influence, prompt engineers must embed outputs consistently align with societal
embed ethical guardrails, fairness checks, societal values, regulatory standards, and
checks, and bias mitigation strategies and organisational ethics policies.
strategies directly into prompt
architectures.
Emerging Specialists
AI Ethicists and Compliance Specialists
Specialists represent rapidly growing roles
roles focused on addressing these critical
critical challenges at the intersection of
of technology and society.
[Link]
The Future: Collaboration Between Humans and AI
AI Execution
Human Oversight
Autonomous task completion and optimisation
Strategic supervision and goal alignment
optimisation
Prompt engineering will evolve from manual prompt crafting to designing sophisticated AI-human workflows. Human-in-the-loop oversight remains vital to supervise
remains vital to supervise autonomous agents and ensure alignment with strategic goals. Mastery of both prompt and context en gineering will become a cornerstone
become a cornerstone skill in the AI-driven economy.
[Link]
Seize the Opportunity in Prompt
Engineering
"The future belongs to those who can speak the language of machines whilst never
forgetting the voice of humanity."
[Link]