Skip to main content

Build AI-ready knowledge base from Outlook & Notion using Pinecone & GPT-4

Workflow preview

Workflow preview
100%
Build AI-ready knowledge base from Outlook & Notion using Pinecone & GPT-4 preview
Open on n8n.io

Important notice

This workflow is provided as-is. Please review and test before using in production.

1. Workflow Overview

Outlook & Notion Knowledge Base Builder for AI Agents This n8n template lets you automatically build and maintain an AI ready knowledge base from Outlook emails and Notion pages. It stores both sou...

Best for

  • Internal Wiki automation workflows
  • AI RAG automation workflows
  • advanced n8n builders looking for reusable templates

Tools used

n8n-nodes-base.microsoftoutlooktrigger, n8n-nodes-base.microsoftoutlook, @n8n/n8n-nodes-langchain.vectorstorepinecone, @n8n/n8n-nodes-langchain.embeddingscohere, @n8n/n8n-nodes-langchain.documentdefaultdataloader, @n8n/n8n-nodes-langchain.textsplitterrecursivecharactertextsplitter, n8n-nodes-base.notiontrigger, n8n-nodes-base.removeduplicates

Source and attribution

This workflow is cataloged by N8N Workflows and links back to its original n8n.io source page by Yasser Sami.

Original n8n.io source

1.1 Workflow description

Title
Build AI-ready knowledge base from Outlook & Notion using Pinecone & GPT-4
Workflow name
Build AI-ready knowledge base from Outlook & Notion using Pinecone & GPT-4

Outlook & Notion Knowledge Base Builder for AI Agents

This n8n template lets you automatically build and maintain an AI-ready knowledge base from Outlook emails and Notion pages.
It stores both sources in a Pinecone vector database so your AI agent can reference them when generating answers, extracting information, or drafting context-aware emails.

Who’s it for

  • Teams using Outlook for client or customer communications.
  • Businesses maintaining documentation or notes in Notion.
  • Developers or AI builders who want to create custom knowledge bases for intelligent agents.

How it works / What it does

  1. Outlook Integration:

    • When you move an email or thread to a specific folder (e.g., “knowledgebase”), the workflow triggers automatically.
    • It captures the entire conversation, removes duplicates, and stores it in Pinecone under a namespace called "emails".
    • The AI agent later uses these stored emails to learn tone, structure, and context for drafting responses.
  2. Notion Integration:

    • When a page is added to a designated Notion database, the workflow triggers.
    • The page content is extracted and embedded into Pinecone under the "knowledgebase" namespace.
    • This allows your agent to use your Notion pages as factual reference material when answering questions.
  3. AI Agent Setup:

    • Uses two Pinecone tools — one to reference Notion content (knowledge base) and another for emails (style & tone).
    • Equipped with Cohere embeddings for multilingual support and OpenAI for conversation or drafting tasks.
    • When queried, the agent retrieves relevant knowledge from both namespaces to produce accurate, context-rich replies.

How to set up

  1. Import this template into your n8n account.
  2. Connect your Outlook account and specify which folder to watch (e.g., “knowledgebase”).
  3. Connect your Notion account and select your target database.
  4. Connect your Pinecone, Cohere, and OpenAI credentials.
  5. Activate the workflow — new Notion pages and Outlook threads will automatically update your knowledge base.

Requirements

  • n8n account.
  • Microsoft Outlook account.
  • Notion account and database.
  • Pinecone account for vector storage.
  • Cohere API key for embeddings.
  • OpenAI API key for AI model.

How to customize the workflow

  • Namespaces: Rename or expand namespaces (e.g., “sales_emails”, “internal_docs”) to organize knowledge types.
  • Embeddings Model: Replace Cohere with OpenAI embeddings if preferred.
  • Agent Behavior: Adjust the agent’s system message to change its tone or purpose (e.g., “act as a sales assistant”).
  • Extra Sources: Extend this workflow to include PDFs, websites, or Slack messages.
  • Sync Schedule: Modify trigger intervals to control how frequently updates are captured.

This workflow automatically builds a living, AI-powered knowledge base from your Outlook and Notion data — perfect for intelligent support, research, or content generation.

1.2 Logical Blocks

This catalog entry is organized from the workflow JSON. The node-level section below shows the executable blocks available for review before importing the template.

2. Block-by-Block Analysis

Block 1 - Microsoft Outlook Trigger

Type / Role
n8n-nodes-base.microsoftOutlookTrigger - microsoftOutlookTrigger
Config choices
Version 1

Block 2 - Get many messages

Type / Role
n8n-nodes-base.microsoftOutlook - microsoftOutlook
Config choices
Version 2

Block 3 - Pinecone Vector Store

Type / Role
@n8n/n8n-nodes-langchain.vectorStorePinecone - vectorStorePinecone
Config choices
Version 1.3

Block 4 - Embeddings Cohere

Type / Role
@n8n/n8n-nodes-langchain.embeddingsCohere - embeddingsCohere
Config choices
Version 1

Block 5 - Default Data Loader

Type / Role
@n8n/n8n-nodes-langchain.documentDefaultDataLoader - documentDefaultDataLoader
Config choices
Version 1.1

Block 6 - Recursive Character Text Splitter

Type / Role
@n8n/n8n-nodes-langchain.textSplitterRecursiveCharacterTextSplitter - textSplitterRecursiveCharacterTextSplitter
Config choices
Version 1

Block 7 - Notion Trigger

Type / Role
n8n-nodes-base.notionTrigger - notionTrigger
Config choices
Version 1

Block 8 - Pinecone Vector Store1

Type / Role
@n8n/n8n-nodes-langchain.vectorStorePinecone - vectorStorePinecone
Config choices
Version 1.3

Block 9 - Embeddings Cohere1

Type / Role
@n8n/n8n-nodes-langchain.embeddingsCohere - embeddingsCohere
Config choices
Version 1

Block 10 - Default Data Loader1

Type / Role
@n8n/n8n-nodes-langchain.documentDefaultDataLoader - documentDefaultDataLoader
Config choices
Version 1.1

Block 11 - Recursive Character Text Splitter1

Type / Role
@n8n/n8n-nodes-langchain.textSplitterRecursiveCharacterTextSplitter - textSplitterRecursiveCharacterTextSplitter
Config choices
Version 1

Block 12 - Remove Duplicates

Type / Role
n8n-nodes-base.removeDuplicates - removeDuplicates
Config choices
Version 2

Block 13 - Split Out

Type / Role
n8n-nodes-base.splitOut - splitOut
Config choices
Version 1

Block 14 - Get many child blocks

Type / Role
n8n-nodes-base.notion - notion
Config choices
Version 2.2

Block 15 - If

Type / Role
n8n-nodes-base.if - if
Config choices
Version 2.2

Block 16 - Get many child blocks1

Type / Role
n8n-nodes-base.notion - notion
Config choices
Version 2.2

Block 17 - Remove Duplicates1

Type / Role
n8n-nodes-base.removeDuplicates - removeDuplicates
Config choices
Version 2

Block 18 - Merge

Type / Role
n8n-nodes-base.merge - merge
Config choices
Version 3.2

Block 19 - Sticky Note

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 20 - Sticky Note1

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 21 - AI Agent

Type / Role
@n8n/n8n-nodes-langchain.agent - agent
Config choices
Version 2.2

Block 22 - When chat message received

Type / Role
@n8n/n8n-nodes-langchain.chatTrigger - chatTrigger
Config choices
Version 1.3

Block 23 - Pinecone Vector Store2

Type / Role
@n8n/n8n-nodes-langchain.vectorStorePinecone - vectorStorePinecone
Config choices
Version 1.3

Block 24 - Embeddings Cohere2

Type / Role
@n8n/n8n-nodes-langchain.embeddingsCohere - embeddingsCohere
Config choices
Version 1

Showing the first 24 of 32 workflow blocks. Download the JSON for the full node graph.

3. Summary Table

Workflow Build AI-ready knowledge base from Outlook & Notion using Pinecone & GPT-4
Complexity advanced
Nodes 32
Categories Internal Wiki, AI RAG
Author Yasser Sami
Published 14 Oct 2025

4. Reproducing the Workflow from Scratch

  1. 1. Download the workflow JSON

    Use the JSON export at /data/workflows/9614/9614.json as the source template for this automation.

  2. 2. Import the template into n8n

    Open n8n, import the downloaded JSON, and review each node before activating the workflow.

  3. 3. Configure credentials and variables

    Replace placeholder credentials, API keys, webhook URLs, account IDs, and environment-specific values with your own settings.

  4. 4. Test with sample data

    Run the workflow manually or in a staging workspace, inspect node output, and confirm downstream systems receive the expected data.

  5. 5. Activate and monitor

    Enable the workflow only after testing, then monitor executions, errors, and rate limits during the first production runs.

5. General Notes & Resources

Review imported nodes carefully before activation. This catalog entry is intended to help you inspect the workflow structure, understand required services, and find related templates faster.

Node names, credentials, schedules, webhook paths, and external service limits may need adjustment for your workspace.

Frequently asked questions

What does Build AI-ready knowledge base from Outlook & Notion using Pinecone & GPT-4 do?

Outlook & Notion Knowledge Base Builder for AI Agents This n8n template lets you automatically build and maintain an AI ready knowledge base from Outlook emails and Notion pages. It stores both sou...

What do I need before importing this workflow?

Review the workflow JSON, configure any required credentials in n8n, and test the automation in a safe workspace before using it in production.

Can I customize this workflow?

Yes. Use the block-by-block analysis and the downloadable JSON to inspect each node, then adjust credentials, prompts, schedules, filters, or destinations for your Internal Wiki, AI RAG use case.