In the previous post, we saw some basic prompting styles. In this post, we shall see some advanced prompting styles
1.Chain of thoughts(COT)
To enable this, we can provide prompts like below
- Think step by step
- Explain the intermediary steps
- Break complex part into simpler terms
LLM will think step by step for the user query and provide output. During this step by step thinking process, output of previous step will be fed as input to the next step.
Lets see a prompt without applying COT and compare it with result after applying COT
As you can see instead of just getting only the answer, prompt with COT provides intermediatory steps for arriving the answer. In essence, COT enables provides more reasoning and transparency.
2.React Framework (Reason + Action)
Let's say a model is trained on 2025 data. If we ask current gold price, it will provide answer based on 2025. It won't know the current price. How can we make LLM to provide up to date information ? For this, we can connect tools with LLM. Tools are nothing but a function or api or mcp.
To fetch the current gold price, LLM will search if it has any tool for this. If an appropriate tool is found, LLM will call the particular tool will turn call an api and a json response will be returned. LLM will use this json and provide the current gold price to the user.
This methdology is called ReAct.It reasons the user query and based on that it will perform some action to give the desired output.
Can't the LLM itself make actions on its own ? Why we need to link tools?
LLM at its core is a just mathematical equation. It is not a software. To provide more enhanced capabilities to the LLM, tools are linked to it. Consider this analogy:
LLM is like a phonebook. Phonebook by itself can't make calls. We need mobile to make calls. Tools are like mobiles. Tools can be anything ranging from function, modules, api, etc...
3.Self Consistency
For the given prompt, it will generate n results. It then chooses and returns the result which appear consistently across n results.
4.Prompt chaining
Output of one prompt is fed as input to the next prompt and its output as input to next prompt and so on.
5.Tree of thoughts
For the given prompt, instead of thinking in one direction, we will make LLM to think in multiple different paths(ways) and it will compare the results of each and returns the best one. Best one is chosen based on the context provided.
6.CRISP Framework
C - Context [Background information]
R - Role [Persona to take]
I - Instruction [Task]
S - Style [output format]
P - Purpose [Final goal]
If our prompt contains all the above elements, it will yield a good result.

7.RICE Framework
R - Role
I - Input
C - Constraints
E - Expectations
Which prompting style to use?
Now that we have seen several prompting styles, a question comes naturally to our mind. Which style to use ? There is no one size fits all approach. It varies based on our usecase. In a trial and error way, we need to find the style that suits our usecase.
For normal queries, we can prefer one of basic prompting styles like few shot prompting, system prompting etc. For program related queries we can prefer advanced prompting styles like chain of thoughts, tree of thoughts etc. There are also few suggestions in this:
- We can choose chain of thoughts when we need to think step by step.
- We can choose ReAct framework when we need to think + act repeatedly(tool calling)
- We can choose tree of thoughts when we need to explore several possibilities
- We can choose CRISP framework when we need to get structured response. Ex: Content creation, Document generation, Code generation and such.
- We can choose RICE framework to control output. Ex: Planning, requirement gathering and such.
It is not necessary to use a single prompting style, we can combine several styles together as well.
Major applications of prompting styles
- Quering with LLM interface like chatgpt,claude etc
- In RAG pipeline.





Top comments (0)