AI驱动的学生答题卡评估智能体
高级
这是一个Document Extraction, AI Summarization领域的自动化工作流,包含 17 个节点。主要使用 Code, FormTrigger, GoogleSheets, GoogleDocsTool, Agent 等节点。 使用Gemini AI和Google Workspace实现学生答题卡评估自动化
前置要求
- •Google Sheets API 凭证
- •Google Gemini API Key
使用的节点 (17)
工作流预览
可视化展示节点连接关系,支持缩放和平移
导出工作流
复制以下 JSON 配置到 n8n 导入,即可使用此工作流
{
"id": "4sTIIfK40TvKs0O8",
"meta": {
"instanceId": "e0f9933c2de40fd346dddfe612cf584d10411f4630c7e4f4f3436a3c24dfa368",
"templateCredsSetupCompleted": true
},
"name": "AI驱动的学生答题卡评估智能体",
"tags": [],
"nodes": [
{
"id": "7e734b0a-96c8-4c30-b7a0-7dbb3bce0771",
"name": "答题卡上传器",
"type": "n8n-nodes-base.formTrigger",
"position": [
-672,
-224
],
"webhookId": "1b176d73-c779-4095-8dc7-6535b7b6d924",
"parameters": {
"options": {},
"formTitle": "Examiner",
"formFields": {
"values": [
{
"fieldLabel": "Examiner Name",
"placeholder": "Examiner Name",
"requiredField": true
},
{
"fieldType": "file",
"fieldLabel": "Upload Answer Sheet",
"acceptFileTypes": ".png,.jpg"
}
]
},
"formDescription": "Examiner AI Agent"
},
"typeVersion": 2.3
},
{
"id": "328e9f3e-a81e-405f-b2af-3707c71121dd",
"name": "分析图像",
"type": "@n8n/n8n-nodes-langchain.googleGemini",
"position": [
-448,
-224
],
"parameters": {
"text": "=The image is an answer paper of a student, you need to analyze and pick each and every answer along with section name, question number and student name.",
"modelId": {
"__rl": true,
"mode": "list",
"value": "models/gemini-2.5-flash",
"cachedResultName": "models/gemini-2.5-flash"
},
"options": {},
"resource": "image",
"inputType": "binary",
"operation": "analyze",
"binaryPropertyName": "Upload_Answer_Sheet"
},
"credentials": {
"googlePalmApi": {
"id": "AaiLYcmkHuNwDORB",
"name": "Google Gemini(PaLM) Api account 4"
}
},
"typeVersion": 1
},
{
"id": "ba55ae1e-0c3a-4050-ad8f-91f9aa5887f5",
"name": "AI Agent",
"type": "@n8n/n8n-nodes-langchain.agent",
"position": [
-96,
-224
],
"parameters": {
"text": "=Marks of the student:\n{{ $json.content.parts[0].text }}\nExaminer Name:{{ $('Answer Sheet Uploader').item.json['Examiner Name'] }}\n\n",
"options": {
"systemMessage": "=You are an intelligent Answer Evaluation Agent designed to assess student answer sheets accurately.\n\nYour task is to cross-check each student’s answers from the uploaded Student Answer Sheet (user input) with the provided Question Paper (tool: “Question Paper 5Th Class”) and the Correct Answer Paper (tool: “Answer Paper 5th Class”), and then calculate the marks accordingly.\n\nSteps 1:\nEvaluation Process \nRead the Question Paper (Question Paper 5Th Class)\nExtract all questions and question numbers.\nMaintain the order and numbering as given.\nRead the Correct Answer Paper (Answer Paper 5th Class)\nExtract correct answers corresponding to each question number.\nEnsure mapping between question number and correct answer is accurate.\n\nStep 2:\nRead the Student Answer Sheet (user input)\nIdentify the student’s answers for each question number.\nMaintain consistent numbering for comparison.\n\nStep 3:\nCompare Answers\nMatch each student answer with the correct answer from the Answer Paper.\nIf the answer matches exactly (or within acceptable variation for text answers), mark as Correct; otherwise mark as Incorrect. ignore punctuation marks like .,;:'\"\"' \n\n₹ is equal Rs. or Rs or rs. or rs or ruppees\n\nStep 4:\nCalculate Marks\nuse append row tool to append the below information.\nAssign marks for each correct answer (e.g., 2 mark each).\n\nAppend the Evaluation Summary using append row tool\nStudent Name\nExaminer Name\nCorrect Answer - no of correct answers\nIncorrect Answers - no of incorrect answers\nTotal Marks - Total marks \nTotal Marks Obtain - Marks obtain by student\n\n\nStep 5:\nCretae a JSON as final output in the below format for all the questions.\n\n{\n \"Student Name\": \"value\",\n \"Teacher Name\": \"value\",\n \"Total Correct Answers\": 8,\n \"Total Incorrect Answers\": 2,\n \"Total Marks\": 10,\n \"Marks Obtained\": 8,\n \"Data\": [\n {\n \"Question\": \"value\",\n \"Correct Answer\": \"value\",\n \"Student Answer\": \"value\",\n \"Status\": \"value\"\n },\n {\n \"Question\": \"value\",\n \"Correct Answer\": \"value\",\n \"Student Answer\": \"value\",\n \"Status\": \"value\"\n },\n {\n \"Question\": \"value\",\n \"Correct Answer\": \"value\",\n \"Student Answer\": \"value\",\n \"Status\": \"value\"\n }\n ]\n}\n"
},
"promptType": "define",
"hasOutputParser": true
},
"typeVersion": 2.2
},
{
"id": "9eb8d9c8-0bc9-4637-a57b-c4120b7cfd7c",
"name": "Google Gemini 聊天模型",
"type": "@n8n/n8n-nodes-langchain.lmChatGoogleGemini",
"position": [
-224,
0
],
"parameters": {
"options": {},
"modelName": "models/gemini-2.5-pro"
},
"credentials": {
"googlePalmApi": {
"id": "AaiLYcmkHuNwDORB",
"name": "Google Gemini(PaLM) Api account 4"
}
},
"typeVersion": 1
},
{
"id": "62e3fcd5-e0d5-482d-b123-c4712d11d753",
"name": "五年级试题卷",
"type": "n8n-nodes-base.googleDocsTool",
"position": [
-96,
0
],
"parameters": {
"operation": "get",
"documentURL": "=https://docs.google.com/document/d/1-B5C4_RjUpNbtw3ByEQXTh8r3_0IPTwwEx7EKqFqmG0/edit?usp=drive_link"
},
"credentials": {
"googleDocsOAuth2Api": {
"id": "ddlaiYwDEDtnemfS",
"name": "Google Docs account"
}
},
"typeVersion": 2
},
{
"id": "844d4fe0-49da-421d-9bd4-29297118e858",
"name": "五年级答题卷",
"type": "n8n-nodes-base.googleDocsTool",
"position": [
32,
0
],
"parameters": {
"operation": "get",
"documentURL": "https://docs.google.com/document/d/1DPWpi4wLbLumV6FaKk2G0GfNY63l5GCLfBqMeAUs5UY/edit?usp=drive_link"
},
"credentials": {
"googleDocsOAuth2Api": {
"id": "ddlaiYwDEDtnemfS",
"name": "Google Docs account"
}
},
"typeVersion": 2
},
{
"id": "252ace90-c1c6-403e-bfdc-297808ed2abf",
"name": "结构化输出解析器1",
"type": "@n8n/n8n-nodes-langchain.outputParserStructured",
"position": [
160,
0
],
"parameters": {
"jsonSchemaExample": "{\n \"Student Name\": \"John Doe\",\n \"Examiner Name\": \"Mrs. Smith\",\n \"Total Correct Answers\": 8,\n \"Total Incorrect Answers\": 2,\n \"Total Marks\": 10,\n \"Marks Obtained\": 8,\n \"Data\": [\n {\n \"Question\": \"Q1\",\n \"Correct Answer\": \"B\",\n \"Student Answer\": \"B\",\n \"Status\": \"Correct\"\n },\n {\n \"Question\": \"Q2\",\n \"Correct Answer\": \"A\",\n \"Student Answer\": \"C\",\n \"Status\": \"Incorrect\"\n },\n {\n \"Question\": \"Q3\",\n \"Correct Answer\": \"D\",\n \"Student Answer\": \"D\",\n \"Status\": \"Correct\"\n }\n ]\n}"
},
"typeVersion": 1.3
},
{
"id": "5875281b-95c5-45b0-b97a-4f24fdb54f82",
"name": "便签",
"type": "n8n-nodes-base.stickyNote",
"position": [
-768,
-320
],
"parameters": {
"height": 256,
"content": "表单触发器 - 收集教师姓名并上传学生扫描答题卡"
},
"typeVersion": 1
},
{
"id": "6a43448e-837e-44da-b813-23697f57e9c5",
"name": "便签1",
"type": "n8n-nodes-base.stickyNote",
"position": [
-512,
-320
],
"parameters": {
"color": 2,
"height": 256,
"content": "Gemini图像分析节点 - 从扫描图像中提取学生答案"
},
"typeVersion": 1
},
{
"id": "bf8fa4b1-ae80-4073-8351-76480d754d05",
"name": "便签2",
"type": "n8n-nodes-base.stickyNote",
"position": [
-240,
-320
],
"parameters": {
"color": 3,
"width": 496,
"height": 464,
"content": "AI评估智能体节点 - 使用附加的Google文档(试题卷和标准答案卷)比较答案,生成包含正确/错误计数和获得分数的结构化JSON结果"
},
"typeVersion": 1
},
{
"id": "cd8c33f8-c4be-4924-8c36-f3746f67ca63",
"name": "便签3",
"type": "n8n-nodes-base.stickyNote",
"position": [
304,
-496
],
"parameters": {
"color": 4,
"width": 272,
"height": 304,
"content": "Google表格(汇总更新) - 添加包含学生姓名、教师姓名、总题数、正确计数、错误计数、总分和获得分数的条目"
},
"typeVersion": 1
},
{
"id": "5ba0dd51-dbd4-4144-ab72-0ce450ba924b",
"name": "便签4",
"type": "n8n-nodes-base.stickyNote",
"position": [
592,
-240
],
"parameters": {
"color": 4,
"width": 352,
"height": 272,
"content": "Google表格(详细报告更新) - 添加逐题详细信息,包括题目、正确答案、学生答案和评估状态"
},
"typeVersion": 1
},
{
"id": "6d16f5b7-f914-4330-a76a-5dcdd820ba30",
"name": "便签5",
"type": "n8n-nodes-base.stickyNote",
"position": [
304,
-176
],
"parameters": {
"color": 6,
"width": 272,
"height": 352,
"content": ""
},
"typeVersion": 1
},
{
"id": "882afe39-f035-4f2a-afea-9cd15848f5b6",
"name": "便签 6",
"type": "n8n-nodes-base.stickyNote",
"position": [
-1392,
-496
],
"parameters": {
"width": 512,
"height": 736,
"content": "## AI驱动的学生答题卡评估智能体"
},
"typeVersion": 1
},
{
"id": "ba0cf804-f83f-41f9-9775-d39e41df83e7",
"name": "添加汇总",
"type": "n8n-nodes-base.googleSheets",
"position": [
384,
-336
],
"parameters": {
"columns": {
"value": {
"Total Marks": "={{ $json.output['Total Marks'] }}",
"Student Name": "={{ $json.output['Student Name'] }}",
"Examiner Name": "={{ $json.output['Examiner Name'] }}",
"Correct Answer": "={{ $json.output['Total Correct Answers'] }}",
"Incorrect Answers": "={{ $json.output['Total Incorrect Answers'] }}",
"Total Marks Obtain": "={{ $json.output['Marks Obtained'] }}"
},
"schema": [
{
"id": "Student Name",
"type": "string",
"display": true,
"required": false,
"displayName": "Student Name",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Examiner Name",
"type": "string",
"display": true,
"required": false,
"displayName": "Examiner Name",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Correct Answer",
"type": "string",
"display": true,
"required": false,
"displayName": "Correct Answer",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Incorrect Answers",
"type": "string",
"display": true,
"required": false,
"displayName": "Incorrect Answers",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Total Marks",
"type": "string",
"display": true,
"required": false,
"displayName": "Total Marks",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Total Marks Obtain",
"type": "string",
"display": true,
"required": false,
"displayName": "Total Marks Obtain",
"defaultMatch": false,
"canBeUsedToMatch": true
}
],
"mappingMode": "defineBelow",
"matchingColumns": [],
"attemptToConvertTypes": false,
"convertFieldsToString": false
},
"options": {},
"operation": "append",
"sheetName": {
"__rl": true,
"mode": "list",
"value": "gid=0",
"cachedResultUrl": "https://docs.google.com/spreadsheets/d/1BVy9jadiWBx-N8DSYGoBbc2XBb9Z2bC8Gi7fA5N4kKE/edit#gid=0",
"cachedResultName": "Sheet1"
},
"documentId": {
"__rl": true,
"mode": "list",
"value": "1BVy9jadiWBx-N8DSYGoBbc2XBb9Z2bC8Gi7fA5N4kKE",
"cachedResultUrl": "https://docs.google.com/spreadsheets/d/1BVy9jadiWBx-N8DSYGoBbc2XBb9Z2bC8Gi7fA5N4kKE/edit?usp=drivesdk",
"cachedResultName": "Score Card"
}
},
"credentials": {
"googleSheetsOAuth2Api": {
"id": "xw7WRgAozbgAiIjH",
"name": "Google Sheets account 6"
}
},
"typeVersion": 4.7
},
{
"id": "786aa89b-d2aa-4546-95ca-acfeb74baa4c",
"name": "添加成绩单",
"type": "n8n-nodes-base.googleSheets",
"position": [
688,
-128
],
"parameters": {
"columns": {
"value": {
"Status": "={{ $json.Status }}",
"Student Name": "={{ $json['Student Name'] }}",
"Actual Answer": "={{ $json['Correct Answer'] }}",
"Student Answer": "={{ $json['Student Answer'] }}",
"Question Number": "={{ $json.Question }}"
},
"schema": [
{
"id": "Student Name",
"type": "string",
"display": true,
"required": false,
"displayName": "Student Name",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Question Number",
"type": "string",
"display": true,
"required": false,
"displayName": "Question Number",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Actual Answer",
"type": "string",
"display": true,
"required": false,
"displayName": "Actual Answer",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Student Answer",
"type": "string",
"display": true,
"required": false,
"displayName": "Student Answer",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Status",
"type": "string",
"display": true,
"required": false,
"displayName": "Status",
"defaultMatch": false,
"canBeUsedToMatch": true
}
],
"mappingMode": "defineBelow",
"matchingColumns": [],
"attemptToConvertTypes": false,
"convertFieldsToString": false
},
"options": {},
"operation": "append",
"sheetName": {
"__rl": true,
"mode": "list",
"value": 760946435,
"cachedResultUrl": "https://docs.google.com/spreadsheets/d/1BVy9jadiWBx-N8DSYGoBbc2XBb9Z2bC8Gi7fA5N4kKE/edit#gid=760946435",
"cachedResultName": "Scorecard"
},
"documentId": {
"__rl": true,
"mode": "list",
"value": "1BVy9jadiWBx-N8DSYGoBbc2XBb9Z2bC8Gi7fA5N4kKE",
"cachedResultUrl": "https://docs.google.com/spreadsheets/d/1BVy9jadiWBx-N8DSYGoBbc2XBb9Z2bC8Gi7fA5N4kKE/edit?usp=drivesdk",
"cachedResultName": "Score Card"
}
},
"credentials": {
"googleSheetsOAuth2Api": {
"id": "xw7WRgAozbgAiIjH",
"name": "Google Sheets account 6"
}
},
"typeVersion": 4.7
},
{
"id": "f6bc7583-39ee-4769-b099-9b4a915a3d1a",
"name": "将多个项目合并为一个JSON的代码",
"type": "n8n-nodes-base.code",
"position": [
384,
-112
],
"parameters": {
"jsCode": "// Get AI output JSON safely (works even if wrapped in array)\nconst raw = $json[\"output\"] || ($json[0] && $json[0].output);\nif (!raw) {\n throw new Error(\"No valid output data found in input\");\n}\n\nconst studentName = raw[\"Student Name\"];\nconst examinerName = raw[\"Examiner Name\"];\nconst totalCorrect = raw[\"Total Correct Answers\"];\nconst totalIncorrect = raw[\"Total Incorrect Answers\"];\nconst totalMarks = raw[\"Total Marks\"];\nconst marksObtained = raw[\"Marks Obtained\"];\n\nconst questions = raw[\"Data\"] || [];\n\nconst result = questions.map(q => ({\n json: {\n \"Student Name\": studentName,\n \"Examiner Name\": examinerName,\n \"Question\": q[\"Question\"],\n \"Correct Answer\": q[\"Correct Answer\"],\n \"Student Answer\": q[\"Student Answer\"],\n \"Status\": q[\"Status\"],\n \"Total Correct Answers\": totalCorrect,\n \"Total Incorrect Answers\": totalIncorrect,\n \"Total Marks\": totalMarks,\n \"Marks Obtained\": marksObtained\n }\n}));\n\nreturn result;\n"
},
"typeVersion": 2
}
],
"active": false,
"pinData": {},
"settings": {
"executionOrder": "v1"
},
"versionId": "c792c0f5-bb22-4b80-afe0-d7abc878346f",
"connections": {
"AI Agent": {
"main": [
[
{
"node": "Append Summary",
"type": "main",
"index": 0
},
{
"node": "Code to merge multiple items into one JSON",
"type": "main",
"index": 0
}
]
]
},
"Analyze an image": {
"main": [
[
{
"node": "AI Agent",
"type": "main",
"index": 0
}
]
]
},
"Append Scorecard": {
"main": [
[]
]
},
"Answer Sheet Uploader": {
"main": [
[
{
"node": "Analyze an image",
"type": "main",
"index": 0
}
]
]
},
"Answer Paper 5th Class": {
"ai_tool": [
[
{
"node": "AI Agent",
"type": "ai_tool",
"index": 0
}
]
]
},
"Google Gemini Chat Model": {
"ai_languageModel": [
[
{
"node": "AI Agent",
"type": "ai_languageModel",
"index": 0
}
]
]
},
"Question Paper 5Th Class": {
"ai_tool": [
[
{
"node": "AI Agent",
"type": "ai_tool",
"index": 0
}
]
]
},
"Structured Output Parser1": {
"ai_outputParser": [
[
{
"node": "AI Agent",
"type": "ai_outputParser",
"index": 0
}
]
]
},
"Code to merge multiple items into one JSON": {
"main": [
[
{
"node": "Append Scorecard",
"type": "main",
"index": 0
}
]
]
}
}
}常见问题
如何使用这个工作流?
复制上方的 JSON 配置代码,在您的 n8n 实例中创建新工作流并选择「从 JSON 导入」,粘贴配置后根据需要修改凭证设置即可。
这个工作流适合什么场景?
高级 - 文档提取, AI 摘要总结
需要付费吗?
本工作流完全免费,您可以直接导入使用。但请注意,工作流中使用的第三方服务(如 OpenAI API)可能需要您自行付费。
相关工作流推荐
使用 Gemini 和 Jina AI 自动化供应商尽职调查研究
使用 Gemini 和 Jina AI 自动化供应商尽职调查研究
If
Set
Code
+12
27 节点Adnan
文档提取
自动化学术论文元数据及变量提取,从Gemini到Google Sheets
自动化学术论文元数据及变量提取,从Gemini到Google Sheets
Set
Code
Wait
+14
39 节点OwenLee
文档提取
PO_发票匹配_V1
基于 Google Gemini AI 和邮件通知的自动化发票-PO 匹配
If
Switch
Google Drive
+10
19 节点Abdul Matheen
发票处理
使用Decodo和Gemini分析Trustpilot和Sitejabber情感并保存到Sheets
使用Decodo和Gemini分析Trustpilot和Sitejabber情感并保存到Sheets
Set
Merge
Form Trigger
+7
18 节点Fahmi Fahreza
市场调研
会议摘要生成器
使用Google Drive、Gemini AI和Google Docs自动化会议摘要
Code
Google Drive
Http Request
+7
12 节点Parth Pansuriya
AI 摘要总结
使用Gemini AI和Google Sheets的餐厅销售与库存预测系统
使用Gemini AI和Google Sheets自动化餐厅销售与库存预测
Code
Gmail
Google Sheets
+5
17 节点Oneclick AI Squad
文档提取
工作流信息
难度等级
高级
节点数量17
分类2
节点类型9
作者
Abdul Matheen
@matheenI am an automation consultant at a multinational company with 18 years of experience in automation technologies, including RPA, Python, and VBA. I am also expanding my expertise by learning AI Agents to further enhance my skill set. Currently serving as delivery manager for a automation team.
外部链接
在 n8n.io 查看 →
分享此工作流