What is system prompts?

Bhushan IngoleBhushan Ingole
4 min read

A system prompt is the initial set of instructions we give to an LLM (Large Language Model).

Think of it like teaching a child - here we tell the model who it is, what it should do, and how it should behave. We can define its role, tone of voice, speaking style, and even its limitations - specifying what it can and can not do.

Types of System Prompting

There are 5 types of System prompts

~ Zero-Short Prompting

In this System Prompting we have to give the direct question and the task to the medel without giving any prior example

Here we have give the instructions only and the model will answer by using the existing knowledge

For example:

If you say transalate Hi into hindi

it will say Namaste

~ Few-Short Prompting

Few-shot prompting is when you give the model a few examples of how you want it to respond before asking your actual question.

The model uses these examples as a guide to generate its answer in a similar style or format.

[

{

“role” : “system”

“content”:

Here some Examples:

Que: Hey there

Ans: Hey nice to meet you

Que: I m bored

Ans: let's play the game then

}

]

~ Chain of Thought ( COT )

Chain-of-Thought prompting is a technique where you encourage the LLM to explain its reasoning step-by-step before giving the final

answer.

It's like telling the model, "Don't rush - take a moment to think things through." By making the model break down its thought process, you often get more accurate and logical answers, especially for complex tasks like math problems, reasoning puzzles, or multi-step decisions.

Example:

Instead of asking:

What is 25 x 4 + 10?

And getting:

110

You might prompt with:

Let's think step-by-step: First multiply 25 by 4, then add 10.

The model's thought process could be:

1. 25 × 4 = 100

2. 100 + 10 = 110

Final Answer: 110

By walking through the steps, the model reduces the chance of making silly mistakes

~ Self Consistency Prompting

Self-consistency prompting is a technique to improve the accuracy of an LLM's answers by asking it to generate multiple reasoning paths instead of just one, and then picking the most consistent final answer.

Think of it as "asking the model to double-check its own homework in different ways."

Instead of rushing to a single conclusion, the model solves the problem several times, possibly in different ways, and then compares the results. The most common or most logical answer among these is chosen as the final output.

Why it helps:

Sometimes an LLM can make mistakes if it follows just one reasoning path. By exploring multiple paths and choosing the most frequent outcome, it reduces random errors and improves reliability - especially in reasoning, planning, or complex problem-solving tasks.

Example:

Prompt: “If a train travels 60 km in 1 hour. how far will it travel in 4.5 hours?"

• Path 1 reasoning: 60 x 4.5 = 270 km

• Path 2 reasoning: 60 km/h x 4 hours = 240 km, plus half an hour (30 km) → 270 km

• Path 3 reasoning: Speed x Time = Distance → 60 x 4.5 = 270 km

Most common answer: 270 km → Final answer:

270 km

~ Persona Based Prompting

Persona-based prompting is when you tell the LLM to act as a specific character, role, or personality before it answers your questions.

By giving it a "persona," you guide not only what it says but also how it says it - including tone, vocabulary, attitude, and perspective. This makes the responses more engaging, consistent, and context-appropriate.

Why it's useful:

• Makes conversations more natural and immersive.

• Ensures consistency in tone and style across all responses.

• Can simulate experts, customer service agents, teachers, or even fictional characters.

Example:

Prompt:

You are a friendly math teacher who explains concepts in simple, everyday language. Explain what a fraction is.

LLM Response:

Sure! Imagine you have a pizza cut into 8

equal slices. If you take 3 slices, you have 3 out of 8 - that's a fraction: 3/8.

You can also create fun or unique personas, like:

A pirate teaching history

• A sarcastic movie critic

An optimistic fitness coach

0
Subscribe to my newsletter

Read articles from Bhushan Ingole directly inside your inbox. Subscribe to the newsletter, and don't miss out.

Written by

Bhushan Ingole
Bhushan Ingole