-
Notifications
You must be signed in to change notification settings - Fork 569
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
WIP: new AI tutorial #2799
Closed
Closed
WIP: new AI tutorial #2799
Changes from all commits
Commits
Show all changes
48 commits
Select commit
Hold shift + click to select a range
ae43a90
add style for info-based foldout
evilnick a5c3110
add static image of tutorial workflow
evilnick e00f1d9
Add outline of tutorial
evilnick 15b0a36
formatting
evilnick 0456d8c
tweaks
evilnick 67a6ba9
text tweaks
evilnick b3933c8
Changes per comments
evilnick cf0f7c6
fix headings
evilnick 77b160a
add ai agent step
evilnick 45686bb
additional steps
evilnick 84c54bd
typo on image name
evilnick 5b2b6d2
additional steps
evilnick 962c4d2
Add character limits to Execution Data node (#2789)
imchairmanm 058279b
DOC-1329: Update AWS Secrets Manager docs (#2787)
MarcL 6060c1e
Add keys extension (#2791)
evilnick 71b3c79
Fix node name in common issues section (#2792)
imchairmanm 89ef419
Add DeepSeek and OpenRouter chat nodes and creds (#2790)
imchairmanm 56c3db7
:rocket: Release note 1.77.0 (#2794)
Joffcom e602b1a
Update latest and next version numbers (#2797)
Joffcom 0065f79
Update structured output parser common issues with advice on working …
imchairmanm 5237116
Keyboard shortcuts (#2775)
evilnick 1d3dfcd
Update keyboard-shortcuts.md for tiny formatting issue
evilnick 48ca05f
Update source control docs with new behavior (#2795)
imchairmanm 99eb86a
Update issue templates (#2802)
evilnick 12bd159
Doc 1323/add a first iteration of a glossary (#2801)
imchairmanm bdc3d2a
Update cloud IPs (03-02-2025) (#2803)
njibhu 2a4d1e7
:rocket: Release note 1.76.2 (#2805)
Joffcom e292411
:rocket: Release note 1.77.1 (#2804)
Joffcom fa8a0c4
Update latest and next version numbers (#2806)
Joffcom e5ca582
Update nextcloud.md: replace "dav" with "webdav" (#2807)
jtmusson a8f5a7e
Change name of node from G Suite Admin to Goolge Workspace Admin (#2809)
imchairmanm 2799a4d
add new agent tools to list (#2808)
evilnick 69d4e11
Updated Telegram Trigger node docs with all new supported triggers (#…
olegtsvetkov 4ced0f7
add reference category to integration types
evilnick 73adf9f
:rocket: Release note 1.76.3 (#2810)
Joffcom 98407b6
:rocket: Release note 1.77.2 (#2811)
Joffcom 0e88609
Update latest and next version numbers (#2815)
Joffcom 45b1da1
add content/priority to frontmatter (#2813)
evilnick 877ce20
add pageinfo.py tool (#2816)
evilnick 712842c
Doc 1279 execute workflow (#2817)
evilnick 415ed56
Add information about automatic AI parameters (#2820)
evilnick 8686f95
Sync insiders submodule to latest version (#2818)
imchairmanm dd5166c
DOC-1281/gemini credentials don't use custom host (#2773)
evilnick c6d150d
add steps
evilnick 8d7ed2b
text updates
evilnick 1b22301
add tools link
evilnick 9ed98dc
typo
evilnick 954dc82
remove extranneous elipsis
evilnick File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
--- | ||
name: Bug report | ||
about: Create a report to help us fix and improve docs | ||
title: "[DOCS-ISSUE] - " | ||
labels: bug | ||
assignees: '' | ||
|
||
--- | ||
|
||
**NOTE!** | ||
|
||
This is for issues with _documentation_ of **n8n**. If the problem you are having is actually a bug in the software, please [file a bug here instead](https://github.com/n8n-io/n8n/issues). | ||
|
||
**Where is the bug/mistake?** | ||
Please help us by pasting in the URL of the page or telling us the title. | ||
|
||
**What problem did you find?** | ||
A clear and concise description of what is wrong. | ||
|
||
**Can you suggest a fix?** | ||
For some issues, like a broken link, it will help us resolve them faster if you can indicate what you think the correct information would be. | ||
|
||
**Additional context** | ||
Add any other context about the problem here. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
--- | ||
name: New docs request | ||
about: Suggest additional pages or information to improve docs | ||
title: "[DOCS-REQUEST] - " | ||
labels: enhancement | ||
assignees: '' | ||
|
||
--- | ||
|
||
Thanks for helping us improve docs! Please give us as much information as you can about the changes you'd like to see. | ||
|
||
**What information is missing?** | ||
|
||
|
||
**Describe the page/pages you'd like** | ||
|
||
|
||
**Additional context** | ||
Add any other context or screenshots about the feature request here. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,94 @@ | ||
#!/usr/bin/env python3 | ||
import os | ||
import yaml | ||
import argparse | ||
import re | ||
import glob | ||
import csv | ||
|
||
OUTPUT_CSV = "pageinfo.csv" | ||
|
||
def extract_frontmatter_and_content(filepath): | ||
"""Extracts frontmatter and main content from a Markdown file.""" | ||
with open(filepath, "r", encoding="utf-8") as f: | ||
content = f.read() | ||
|
||
# Match YAML frontmatter with regex (--- as delimiter) | ||
match = re.match(r"^---\n(.*?)\n---\n(.*)", content, re.DOTALL) | ||
|
||
if match: | ||
try: | ||
frontmatter = yaml.safe_load(match.group(1)) # Parse YAML | ||
except yaml.YAMLError: | ||
frontmatter = None # Invalid YAML | ||
main_content = match.group(2).strip() | ||
else: | ||
frontmatter = None | ||
main_content = content.strip() | ||
|
||
return frontmatter, main_content | ||
|
||
def count_words(text): | ||
"""Counts the number of words in the given text.""" | ||
# yes, this is fairly simplistic, but a general idea is fine for most uses | ||
return len(text.split()) | ||
|
||
def find_markdown_files(directory): | ||
"""Recursively finds all markdown files in the given directory.""" | ||
return glob.glob(os.path.join(directory, "**", "*.md"), recursive=True) | ||
|
||
def save_to_csv(data, filename=OUTPUT_CSV): | ||
"""Saves extracted data to a CSV file with dynamic contentType columns.""" | ||
max_types = max((len(row[1]) if isinstance(row[1], list) else 1) for row in data) | ||
headers = ["Filename", "WordCount"] + [f"ContentType_{i+1}" for i in range(max_types)] | ||
|
||
with open(filename, "w", newline="", encoding="utf-8") as csvfile: | ||
writer = csv.writer(csvfile) | ||
writer.writerow(headers) # Write CSV header | ||
|
||
for filename, content_type, word_count in data: | ||
if isinstance(content_type, list): | ||
row = [filename, word_count] + content_type + [""] * (max_types - len(content_type)) | ||
else: | ||
row = [filename, word_count, content_type] + [""] * (max_types - 1) | ||
writer.writerow(row) | ||
|
||
def main(directory,print_output): | ||
"""Finds Markdown files, extracts 'contentType' and word count, then prints and saves results.""" | ||
md_files = find_markdown_files(directory) | ||
extracted_data = [] | ||
|
||
for file in md_files: | ||
frontmatter, main_content = extract_frontmatter_and_content(file) | ||
word_count = count_words(main_content) | ||
|
||
if frontmatter and "contentType" in frontmatter: | ||
content_type = frontmatter["contentType"] | ||
else: | ||
content_type = "" | ||
|
||
# Convert list to comma-separated string for printing | ||
if isinstance(content_type, list): | ||
content_str = ", ".join(content_type) | ||
else: | ||
content_str = str(content_type) | ||
|
||
if print_output: | ||
print(f"File: {file}") | ||
print(f"Word Count: {word_count}") | ||
print(f"contentType: {content_str}\n") | ||
|
||
extracted_data.append([file, content_type, word_count]) | ||
|
||
if extracted_data: | ||
save_to_csv(extracted_data) | ||
print(f"Results saved to {OUTPUT_CSV}") | ||
|
||
if __name__ == "__main__": | ||
parser = argparse.ArgumentParser(description="Extract contentType and word count from Markdown files.") | ||
parser.add_argument("--dir", type=str, default="../docs", help="Directory to scan (default: '../docs')") | ||
parser.add_argument("--print", action="store_true", help="Print output to console (default: False, only CSV)") | ||
|
||
args = parser.parse_args() | ||
main(args.dir, args.print) | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
As an example, imagine you have an Execute Workflow node in **Workflow A**. The Execute Workflow node calls another workflow called **Workflow B**: | ||
As an example, imagine you have an Execute Sub-workflow node in **Workflow A**. The Execute Sub-workflow node calls another workflow called **Workflow B**: | ||
|
||
1. The Execute Workflow node passes the data to the Execute Workflow Trigger node of **Workflow B**. | ||
2. The last node of **Workflow B** sends the data back to the Execute Workflow node in **Workflow A**. | ||
1. The Execute Sub-workflow node passes the data to the Execute Sub-workflow Trigger node (titled "When executed by another node" in the canvas) of **Workflow B**. | ||
2. The last node of **Workflow B** sends the data back to the Execute Sub-workflow node in **Workflow A**. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
/// note | Latest and Next versions | ||
n8n releases a new minor version most weeks. The `latest` version is for production use. `next` is the most recent release. You should treat `next` as a beta: it may be unstable. To report issues, use the [forum](https://community.n8n.io/c/questions/12){:target=_blank .external-link}. | ||
|
||
Current `latest`: 1.75.2 | ||
Current `next`: 1.76.1 | ||
Current `latest`: 1.76.3 | ||
Current `next`: 1.77.2 | ||
/// |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
/// info | Feature availability | ||
* Available on Enterprise. | ||
* You need access to the n8n instance owner account or an admin account to set up source control, and to send work to and from Git. | ||
* You need to be an n8n instance owner, admin, or project owner to set up source control, and to send work to and from Git. | ||
/// |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Submodule insiders
updated
from eb9419 to f2492f
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
{ | ||
"name": "AI tutorial", | ||
"nodes": [ | ||
{ | ||
"parameters": { | ||
"options": {} | ||
}, | ||
"type": "@n8n/n8n-nodes-langchain.chatTrigger", | ||
"typeVersion": 1.1, | ||
"position": [ | ||
-200, | ||
-40 | ||
], | ||
"id": "a2d42e1f-36df-4a6a-a3b4-99a162074d11", | ||
"name": "When chat message received", | ||
"webhookId": "97c1a41f-8ef0-4d63-a924-92eb634384d3" | ||
} | ||
], | ||
"pinData": {}, | ||
"connections": {}, | ||
"active": false, | ||
"settings": { | ||
"executionOrder": "v1" | ||
}, | ||
"versionId": "b1641385-c6b0-48a8-8e26-20d1f6bd7fda", | ||
"meta": { | ||
"instanceId": "cb484ba7b742928a2048bf8829668bed5b5ad9787579adea888f05980292a4a7" | ||
}, | ||
"id": "l05TkWXXYbOiuL4o", | ||
"tags": [] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
{ | ||
"name": "AI tutorial", | ||
"nodes": [ | ||
{ | ||
"parameters": { | ||
"options": {} | ||
}, | ||
"type": "@n8n/n8n-nodes-langchain.chatTrigger", | ||
"typeVersion": 1.1, | ||
"position": [ | ||
-300, | ||
-40 | ||
], | ||
"id": "a2d42e1f-36df-4a6a-a3b4-99a162074d11", | ||
"name": "When chat message received", | ||
"webhookId": "97c1a41f-8ef0-4d63-a924-92eb634384d3" | ||
}, | ||
{ | ||
"parameters": { | ||
"options": {} | ||
}, | ||
"type": "@n8n/n8n-nodes-langchain.agent", | ||
"typeVersion": 1.7, | ||
"position": [ | ||
-80, | ||
-40 | ||
], | ||
"id": "0f61a10f-668f-42f7-b835-cf3efb60082a", | ||
"name": "AI Agent" | ||
} | ||
], | ||
"pinData": {}, | ||
"connections": { | ||
"When chat message received": { | ||
"main": [ | ||
[ | ||
{ | ||
"node": "AI Agent", | ||
"type": "main", | ||
"index": 0 | ||
} | ||
] | ||
] | ||
} | ||
}, | ||
"active": false, | ||
"settings": { | ||
"executionOrder": "v1" | ||
}, | ||
"versionId": "b1641385-c6b0-48a8-8e26-20d1f6bd7fda", | ||
"meta": { | ||
"instanceId": "cb484ba7b742928a2048bf8829668bed5b5ad9787579adea888f05980292a4a7" | ||
}, | ||
"id": "l05TkWXXYbOiuL4o", | ||
"tags": [] | ||
} |
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This adds a further style for an 'info' themed expandable section, similar to the existing 'details' one. The styling is taken from the default for material, but we can debate appropriate colours etc.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Got it. Yeah, I think changes to the styling are fine. I think if we're going with green, it'd be good to try to riff off of the green we already use for the theme. That being said, with the website style changes coming, it might not matter all too much.