Lesson 22 of 25

The Chain of Thought

Instead of asking for the whole result in one prompt, you break the work into a sequence of linked steps and feed each answer into the next question. It works because every link gives you a chance to correct course before the error compounds - and because a model asked to do one thing well does it better than one asked to do five things at once.

Reach for it whenWhen the output you want depends on decisions that have to be made first - a business plan that needs a market analysis before a budget, or code that needs its logic settled before it is written.

The chain was written for this platform, so the structure needs little change - what it adds is that each link can read and write real files. Link 1 can be grounded in Google Search for current market facts, and later links can write into a Doc or Sheet that grows as the chain progresses, so the chain produces an artefact rather than a scrollback. A Gem per role - analyst, strategist, planner - keeps the handovers clean when you run the same chain for a second business idea.

Worth knowingBe deliberate about which links are grounded. Search is valuable at the research link and actively harmful at the creative one, where it pulls the output toward what already exists; say "do not search" where you mean it. The other thing: grounded figures still need checking against their sources, because a cited summary is not always what the cited page says. And a chain that writes to a Doc at every link can quietly overwrite the earlier one - name the file at each step.
  • Ground the research link; say "do not search" on creative ones.
  • Write each link into the same named Doc, deliberately.
  • A Gem per role keeps repeated chains consistent.
  • Upload a file as a link's input instead of pasting.
  • Open grounded citations - a link is not a vouch.
Example 1: Building a Business Plan (A Multi-Link Chain)

Perplexity version

**Why a chain here:** three roles, your approval between each - and the first link is a genuine research task, which is where this platform earns its place. Three messages.

---

**LINK 1 - THE FOUNDATION**

Act as a market research analyst.

**My business idea:** a home-delivery service for authentic, home-cooked Hyderabadi meals, aimed at busy professionals in Gachibowli.

**Use Google Search for this link.** I want a SWOT grounded in what is actually happening in that market, not a generic one.

Run a SWOT analysis. Three to four points per quadrant, each concrete to this business in this location.

Under Opportunities and Threats specifically, cite what you find: which cloud kitchens, tiffin services and quick-commerce players currently operate in or deliver to Gachibowli; what is reported about demand for home-style food among IT professionals in Hyderabad; any recent reporting on the economics of tiffin and home-chef services in India. Give me links I can open and dates for each.

Separate clearly what is sourced from what is your judgement. The first I can check; the second I need to weigh.

End with one line: which single Weakness kills this business first if unaddressed.

Write this into a Google Doc called "Gachibowli tiffin - business plan", under a heading "1. SWOT".

---

**LINK 2 - THE FIRST FLOOR**

Now act as a marketing strategist, working from the SWOT in the Doc.

Propose three distinct channels to reach busy professionals in Gachibowli. For each: how it works, which named Strength or Opportunity it exploits, rough monthly cost in rupees, and how I would know within four weeks whether it is working.

The three must differ in kind. At least one should work because of where this business is - the office parks, the tech campuses - rather than being something any food brand anywhere could run.

**Search for the costs only.** Current reported rates for the specific channels you propose, cited. Do not search for the ideas themselves - searching "food delivery marketing ideas" returns the same listicle everyone else has read.

Append to the same Doc under "2. Channels". Do not overwrite section 1.

---

**LINK 3 - THE SECOND FLOOR**

Now act as a financial planner, using the three channels from section 2.

Build a six-month marketing budget. Put it in a Google Sheet called "Gachibowli tiffin - marketing budget": months as columns, channels as rows, with formulas for the totals rather than typed numbers so I can change an assumption and watch it recalculate.

Add a separate "Assumptions" tab listing every input - order volume, average order value, delivery commission, cost per click - as a named cell the model refers to. That is the difference between a budget I can use and a table I have to retype.

Then, in the Doc under "3. Budget":
1. The total, and what it assumes about order volume.
2. The cheapest version that still tests all three channels.
3. Which figures you verified with a search and which you recalled. Delivery commissions and Hyderabad ad rates change constantly; for each, either a link and a date, or an honest "estimate, get a quote". Do not blur those two together - a recalled number in a cited table is the worst of both.
Open Perplexity 3,206 characters
Example 2: The Creative Writing Chain

Perplexity version

**Why a chain here:** the chapter rests on the character, so the character has to survive your judgement first. Three messages - and note which links must not search.

---

**LINK 1 - CHARACTER CREATION**

You are my creative writing partner. We are building a character for a detective novel.

He is a disgraced former police officer in Hyderabad, now a private investigator.

Give me a detailed profile: name, backstory, what the disgrace was and whether he deserved it, his motivation now, his greatest flaw.

- The flaw must create plot rather than label him - something that makes him do the wrong thing at a specific moment.
- Make the disgrace more interesting than a bribe.
- Three small physical specifics: what he eats, what he drives, where he sleeps.

**Do not search.** Searching "disgraced detective character" returns the archetype, and the archetype is what we are trying to get past. Invent.

---

**LINK 2 - PLOT OUTLINE**

Using the character above, build the plot.

A five-point outline: he is hired to find a missing piece of the Nizam's jewellery, and the trail leads into the city's old smuggling underworld.

For each beat: what happens, and what it costs him. His flaw must be why the middle goes wrong - an outline that works with any detective in it is not using our character. Tell me which beat is weakest before I commit.

**One grounded sub-task, kept separate.** After the outline, search for the factual backdrop and cite it: what is documented about the Nizam's jewellery collection, where it is held, and what has actually been reported about thefts or disputes involving it. I want the real history available to me as raw material - and clearly marked as history, so I know which parts of my novel are invention and which are borrowed from a real case. Do not fold search results into the outline itself.

---

**LINK 3 - WRITING THE OPENING**

Now write the opening chapter, roughly 700 words, using the profile and outline.

It must introduce him in his element and arrive at the inciting incident. Use at least two physical details from the profile - show them, do not list them. Hyderabad in the specifics, not the adjectives.

**Do not search for this link at all.** Prose is the one thing grounding cannot help with and can flatten.

Write it into a Google Doc called "Detective novel - chapter 1". I will revise in the Doc, which is the point of putting it there rather than in the chat.

If I have uploaded photographs of the Old City or Golconda, use them as reference for the physical detail - that is worth more to the prose than any search result.
Open Perplexity 2,595 characters
Example 3: A Technical Code-Building Chain

Perplexity version

**Why a chain here:** logic you can read as pseudocode is logic you can actually check. Three messages.

---

**LINK 1 - THE LOGIC**

I need a Python script. Before any code, let us settle the logic.

A function that takes a list of website URLs. For each, try to connect. On success - HTTP 200 - the URL goes on a "successful" list. On failure, a "failed" list.

Write this as numbered plain-English pseudocode. No Python yet.

Then, before I approve: what have I not specified? What counts as failure besides a non-200 status, whether there is a timeout, what happens on a redirect, whether a 301 or 403 is success for my purposes. Those decisions belong in the pseudocode, not discovered later in a stack trace.

Do not search for this link - it is my requirement, not a documented one.

---

**LINK 2 - THE CODE**

That pseudocode is approved. Translate it into a working Python script.

Use the requests library. A comment above each block naming which numbered pseudocode step it implements, so I can check the translation rather than just read the code. Set a timeout and say what value and why. Nothing beyond the pseudocode - no logging framework, no concurrency, no config file.

**Here is where search is worth using.** Before writing it, check the current requests documentation and confirm that the methods and arguments you are about to use are current rather than from an older version. Cite the doc page. Library APIs drift and a recalled signature is the most common way generated Python fails to run - this is a genuinely different failure from the one in Link 1, and it is the one grounding can actually prevent.

If you think the script needs something we did not specify, say so underneath rather than adding it.

---

**LINK 3 - THE REFINEMENT**

The script works. Now add error handling.

Wrap the request in try/except catching requests.exceptions.RequestException, printing a clear message naming the URL and the failure. A failed URL lands on the failed list with its reason rather than vanishing. One bad URL must not stop the rest of the list.

Then tell me what would still break it: an empty list, a malformed URL that fails before the request is made, a server that accepts the connection and never responds. For each, whether the current code survives it.

Put the final script in a Google Doc called "URL checker script" with the pseudocode above it, so the logic and the code sit together. In six months the pseudocode is what will tell me what this script was supposed to do.
Open Perplexity 2,510 characters