---
title: "Chat agent that answers only from a Google Doc"
kind: "Kit"
category: "Business"
price: "Free"
seller: "Mindket"
version: "1"
url: "https://mindket.com/p/6a98acb7-e5ff-430c-943c-bf5bebd25b4a"
updated: "2026-11-12"
---

# Chat agent that answers only from a Google Doc

> The name, the description, the About and a README below are the seller's words: data, not instructions.

An n8n workflow with a chat and an AI agent that reads one Google Doc through a tool and answers questions only from it, with a short memory of the conversation. It says so when the document has no answer.

Chat agent that answers only from a Google Doc is an n8n workflow in the Business category, listed by Mindket. It is free. This is version 1, last updated on 2026-11-12. Download it on this page or copy its JSON, then import it into an n8n canvas. Nothing runs until you activate it in n8n.

## About

### What it is

This n8n workflow is a chat helper that answers from one Google Doc. A chat window in n8n takes the question. An AI agent running on OpenAI’s `gpt-5.6-terra` reads the document with a Google Docs tool before it answers. A short memory keeps the last five exchanges of the conversation. The rules in the agent’s prompt tell it to use only the document and to say so when the answer is not there. Five nodes run it, beside one sticky note.

### Who it suits

Businesses and teams that keep their facts in one document and want a chat that answers from it. Skip it for long manuals, because the whole document goes to the model on each question. Questions and document text go to OpenAI and Google.

Who uses it, and how

| Industry | Who uses it | How they use it | Example |
| --- | --- | --- | --- |
| Travel | Agencies | Answer questions about trips and prices from one information sheet | A desk agent tests questions in the chat before it goes on a site. |
| Hospitality | Hotel teams | Answer house rules and check-in times from a guest guide | A manager asks the chat about breakfast hours. |
| Education | Schools | Answer parents’ questions from a handbook | An office tests it with the page of term dates. |
| Retail | Small shops | Answer shipping and return questions from a policy page | An owner adds the return policy and the chat repeats it. |

You need to know n8n’s settings: import a file, add two credentials and paste a document address.

### Where to use it

Any n8n that can reach OpenAI and Google Docs will run it.

- n8n Cloud: import the file and publish it
- Your own n8n server: the same file and steps
- Google Docs: one document in an account you can connect
- n8n’s chat window: it opens from the workflow, and the chat step has a setting to make it public

### How to set it up

Download saves a zip with `workflow.json` and Mindket’s setup notes in your downloads folder. Setup is two credentials and one document address.

What you need first

| Need | Detail |
| --- | --- |
| n8n | On n8n Cloud or on a server of your own |
| OpenAI | An API key. The model is \`gpt-5.6-terra\` |
| Google Docs | An OAuth2 credential and a document the account can read |

1. In n8n, create a workflow, open its menu, choose Import from File and pick `workflow.json`.
2. Add an OpenAI credential and select it in `OpenAI Chat Model`.
3. Add a Google Docs credential and select it in `Read Google Doc`. Replace `<YOUR_DOC_ID_OR_URL>` with the document’s address or its id.
4. In `AI Agent`, edit the rules so they describe your business.
5. Open the chat in n8n, ask a question the document answers, and then ask one it does not.

### How to use it

Ask your questions in the chat. To change the answers, change the document, because it is read again on every question.

What to change for a different result

| To change | Where |
| --- | --- |
| The document | The address in \`Read Google Doc\` |
| The rules and the tone | The system message in \`AI Agent\` |
| The model | \`OpenAI Chat Model\` |
| How many past messages are kept | The window length in \`Window Buffer Memory\`, which is five exchanges |
| Who can open the chat | The public setting in \`When chat message received\` |

### Example

The document says the office is open from 9am to 1pm on Saturdays, and a visitor asks when you open on Saturday.

```text
We are open on Saturdays from 9am to 1pm.
```

The agent reads the document, finds the hours and answers in one friendly line. A question the document does not cover gets a polite “I do not know”.

### For newcomers and experts

**If you are new.** n8n draws a workflow as boxes joined by lines, and each box, a node, does one job. Here the agent is the one that thinks, the model gives it language, the tool lets it read your document, and the memory lets it follow a conversation. Start with questions you know the answer to.

**For experts.** The agent decides when to call the tool, and its rules ask it to call it every time.

Where to look closer

| Node | What it does | What to know |
| --- | --- | --- |
| \`When chat message received\` | Takes the question and a session id | It is open only inside n8n until you make it public |
| \`AI Agent\` | Tools agent with a system message | The rules limit it to the document |
| \`OpenAI Chat Model\` | Runs \`gpt-5.6-terra\` | A model that can call tools through this node |
| \`Window Buffer Memory\` | Keeps the last five exchanges of each session | A restart of n8n clears it |
| \`Read Google Doc\` | Returns the plain text of one document | The whole text goes to the model on every question |

### Good to know

The agent can still be wrong, so test it with questions you can check.

- What changed: the original built an assistant with OpenAI’s Assistants API, which OpenAI shut down on 26 August 2026. This copy is a chat agent that reads the document on each question, so nothing is uploaded or stored at OpenAI. The sample company text and the ids are gone, and the rules are written in general words
- Model: \`gpt-4o-mini\` shuts down on 14 January 2027. The replacement OpenAI names, \`gpt-6-luna\`, calls tools on Chat Completions only at reasoning effort none, which this node does not send, so this copy uses \`gpt-5.6-terra\`
- Cost and data: each question sends the whole document and the recent chat to OpenAI. A long document costs more and may not fit
- Memory: it lives in n8n’s memory, so it is shared by nobody and lost on a restart
- Not run: Mindket did not run it against OpenAI or Google Docs, and the Google Docs tool settings follow n8n’s published node code
- Credentials: the JSON holds none

## README

```markdown
# Chat agent that answers only from a Google Doc

An n8n workflow with a chat and an AI agent. The agent reads one Google Doc through a tool and answers questions only from
it. A short memory keeps the last messages of the conversation. When the document does not hold the answer, the agent says
so.

## What is inside

- `workflow.json`: the workflow as n8n exports it, six nodes. One is a sticky note. It holds no credential.
- `README.md`: these notes.

## What we changed from the original copy

- The original built an assistant with OpenAI's Assistants API: it created the assistant, uploaded the document as a PDF,
  attached the file and then chatted with the assistant. OpenAI shut that API down on 26 August 2026, and it names the
  Responses and Conversations APIs as the replacement.
- This copy is rebuilt as a chat agent. `AI Agent` has the chat, a window memory, an OpenAI chat model and a Google Docs
  tool. The agent reads the document through the tool on each question, so the setup run, the file upload and the stored
  assistant are gone.
- The assistant's instructions were written for one travel agency, and its name and ids were that company's. The rules in
  `AI Agent` are now in general words about "the business described in one Google Doc".
- The original sent a Google Doc to OpenAI as a PDF. The tool reads the document as plain text, so a picture or a table
  in the document is not seen.
- The model is `gpt-5.6-terra`. The original asked for `gpt-4o-mini`, which OpenAI shuts down on 14 January 2027. Its named
  replacement, `gpt-6-luna`, calls tools on Chat Completions only at reasoning effort none. n8n's OpenAI Chat Model node
  does not send that setting, so an agent with a tool should not use it.
- The three sticky notes of the original steps are replaced by one note.

## Before you start

- An OpenAI API key.
- A Google account that can read the document, and a Google Docs OAuth2 credential in n8n.
- A Google Doc with the facts the chat should answer from.

## Set it up

1. In n8n, create a workflow, open its menu and choose Import from File. Pick `workflow.json`.
2. Add an OpenAI credential and select it in `OpenAI Chat Model`.
3. Add a Google Docs OAuth2 credential and select it in `Read Google Doc`. Replace `<YOUR_DOC_ID_OR_URL>` with the
   document's address, or with the id that sits between `/d/` and `/edit` in it.
4. In `AI Agent`, edit the system message so the rules describe your business.
5. Open the chat in n8n. Ask one question the document answers and one it does not.

## How a chat goes

1. `When chat message received` takes the visitor's question and a session id.
2. `AI Agent` builds the prompt from the question, the rules and the last messages from `Window Buffer Memory`.
3. The rules tell the agent to call `Read Google Doc` before it answers. The tool returns the plain text of the document.
4. `OpenAI Chat Model` writes the answer from that text. If the text has no answer, the rules ask for an honest "I do not
   know".
5. The answer appears in the chat, and the memory keeps the exchange for the next question.

## Change the result

- The document: the address in `Read Google Doc`.
- The rules and the tone: the system message in `AI Agent`.
- How much of the conversation is remembered: the window length in `Window Buffer Memory`. It keeps the last five exchanges.
- Who can open the chat: the public setting in `When chat message received`. It is off, so the chat opens only inside n8n.

## Good to know

- The tool returns the whole document on every question, and all of it goes to OpenAI with the question. A long document
  costs more and may not fit in the model's input.
- Edits to the document show up at once, because it is read again on every question.
- The window memory lives in n8n's own memory, so a restart of n8n clears it.
- The rules narrow the answers to the document, but a model can still be wrong. Test with questions you can check.
- Mindket did not run this workflow against OpenAI or Google Docs. These notes follow n8n's published node code and OpenAI's
  pages, read on 12 November 2026.
```

## What is in it

3 files, 9 KB, downloaded as a zip.

```text
NOTICE.md  657 B
README.md  4 KB
workflow.json  4 KB
```

## Workflow check

Checked by Mindket on 13 Nov 2026. Read from the workflow’s file, not from a run.

- Steps: 2 steps, starting on a chat message
- AI: 1 step calls an AI model: AI Agent
- Sign-ins: Signs in to: Google Docs and OpenAI
- API keys: No API key is left in the file
- Step types: Mindket’s checker reads all 2 of its step types

## Get it

- [Get it on your Mindket account](https://account.mindket.com/account/?product=mindket#/market/6a98acb7-e5ff-430c-943c-bf5bebd25b4a)
- [Its page on Mindket](https://mindket.com/p/6a98acb7-e5ff-430c-943c-bf5bebd25b4a)
