Building a “Thinking” Model from a “Non-Thinking” Model with Chain-of-Thought

Md AasimMd Aasim
4 min read

Most large language models (LLMs) can answer questions directly. Ask “What’s 12×13?” and they blurt “156.” That’s a non-thinking model behavior: it jumps straight to a final answer without showing how it got there. This works for many look-up or short arithmetic tasks, but it often stumbles on multi-step problems—word math, logic puzzles, planning—where the path matters as much as the destination.

Chain-of-Thought (CoT) is a prompting technique that nudges the model to work the problem in steps before giving the final answer. Think of “show your work” in math class or following a recipe: gather ingredients, mix, bake, cool, serve. When you ask a model to “think step by step,” you encourage it to break a complex task into bite-sized moves, which typically improves accuracy and reliability.


Why CoT helps (the intuition)

When we solve a problem, we keep a short internal script: “First find the distance, then divide by time.” CoT gives the model permission to write a brief, structured plan. That structure reduces leaps, exposes inconsistencies, and creates checkpoints where basic mistakes can be caught.

Everyday analogy: if you assemble furniture without the manual, you may finish faster—or end up with spare screws. Following the steps slows you slightly but yields the correct chair.


A quick before/after

Example 1: Word math

Question: A car travels 60 km/h for 2 hours and 30 km/h for 1 hour. What is the average speed for the whole trip?

  • Without CoT (direct): “45 km/h.” (Common wrong guess: average of speeds.)

  • With CoT-style prompt (concise steps):
    Steps: Compute distance: 60×2=120; 30×1=30; total distance=150. Total time=3. Average speed=150÷3=50.
    Final answer: 50 km/h.

What changed? The steps enforced the correct formula (total distance / total time), preventing the “just average the speeds” trap.


Example 2: Simple logic

Premises: Alice is taller than Bob. Bob is taller than Carol. Who is tallest?

  • Without CoT (direct): “Alice.” (Correct, but fragile if premises grow.)

  • With CoT-style prompt (concise steps):
    Steps: From premises, Alice > Bob and Bob > Carol ⇒ Alice > Carol.
    Final answer: Alice.

What changed? The steps scale: as relationships multiply, the model has a standard way to combine them.

Note: In production settings, it’s best to keep the detailed reasoning internal (not shown to end users) and return only the answer or a short justification. This protects sensitive prompts and avoids overly verbose outputs.


Designing effective CoT prompts (best practices)

  1. Ask for steps, not essays.
    Use phrases like: “Solve step by step in short, numbered steps. Then give a final answer on a new line labeled ‘Answer:’.” This constrains the style and reduces rambling.

  2. Prime with a micro-recipe.
    Tell the model how to think: “Identify givens → compute needed quantities → check units → produce final answer.”

  3. Bound the length.
    Add limits: “No more than 5 steps; each step ≤ 1 sentence.” This keeps reasoning crisp.

  4. Separate reasoning from the final.
    Ask for a final summary line: “Answer: …” This makes outputs easy to parse or grade.

  5. Add a lightweight check.
    “Before the final answer, verify that the steps support the result.” This encourages self-correction.

  6. Use examples.
    Provide one miniature solved example in your desired format (few lines), then your new task. Models imitate structure well.

  7. For harder tasks, consider self-consistency.
    Run multiple sampled solutions (with different temperature seeds) and choose the majority answer or the one with the clearest, consistent steps. This often boosts accuracy on reasoning problems.


Where CoT shines

  • Math word problems & unit conversions (avoid formula mix-ups)

  • Logic and deduction (combine premises cleanly)

  • Planning & instructions (break down tasks or checklists)

  • Retrieval-augmented answers (plan: find context → extract facts → synthesize)


Limitations and risks

  • Token/latency cost: More steps = longer outputs and higher compute. Use step limits.

  • Overconfidence: A neat set of steps can still lead to a wrong conclusion. Keep the verification step.

  • Leakage/verbosity: Dumping raw reasoning to users can reveal prompts, sensitive hints, or confuse them. Prefer short justifications or answer-only views.

  • Brittleness: Some tasks don’t benefit from CoT (e.g., pure lookup). Don’t force it everywhere.

  • Hallucinated steps: The model might invent intermediate “facts.” Encourage grounding: “Only use information given in the problem.”


Putting it together

A non-thinking model jumps to answers; a thinking model earns the answer through compact, ordered steps. Chain-of-Thought is the shift from “guess the destination” to “follow the route.” With a few prompt tweaks—ask for short steps, bound length, separate the final answer, and add a check—you can transform accuracy on multi-step tasks. Keep the reasoning concise, prefer internal traces in production, and use self-consistency for tougher problems.

In short: CoT turns an LLM from a fast guesser into a careful solver—more like the student who shows their work and gets the right answer for the right reasons.

0
Subscribe to my newsletter

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

Written by

Md Aasim
Md Aasim