Files
dobetternorge-tools/n8n/caveauDbnAgent.json
T
daveadmin 198f0526cf feat(tools): n8n caveauDbnAgent starter workflow + import guide
Clonable AI Agent workflow driving the DBN legal tools over one MCP Client
Tool node (dynamic catalog, 23 dbn.* tools). Chat Model + Bearer creds are
placeholders Dave wires post-import — no cloud spend baked in.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-06-21 15:10:30 +02:00

121 lines
4.1 KiB
JSON

{
"name": "caveauDbnAgent",
"nodes": [
{
"parameters": {
"options": {}
},
"id": "a1b2c3d4-0001-4a01-8a01-000000000001",
"name": "When chat message received",
"type": "@n8n/n8n-nodes-langchain.chatTrigger",
"typeVersion": 1.1,
"position": [
-260,
0
],
"webhookId": "caveau-dbn-agent-chat"
},
{
"parameters": {
"options": {
"systemMessage": "You are caveauDbnAgent, a Norwegian family-law preparation assistant. You answer using ONLY the Do Better Norge (DBN) legal tools exposed over MCP — never invent statutes, case numbers, or citations.\n\nTOOLS: a single MCP connection exposes the full DBN catalog (dbn.search_legal, dbn.corpus_search, dbn.ask, dbn.list_personas, dbn.summarize, dbn.timeline, dbn.redact, dbn.translate, dbn.legal_analysis, dbn.korrespond, dbn.korrespond_refine, dbn.barnevernet_analyze, dbn.advocate_brief, dbn.deep_research, dbn.discrepancy_find, dbn.transcribe_audio, dbn.extract_text, dbn.corpus_stats, dbn.list_documents, dbn.get_document, dbn.citation_graph, dbn.case_workbench_plan, dbn.save_to_case).\n\nDEFAULT CHAIN: for a typical case-prep request, (1) call dbn.search_legal to ground yourself in the corpus, (2) call dbn.legal_analysis on the user's document or question, then (3) call dbn.korrespond to draft any letter to a Norwegian authority. Pick a persona with the `profile` argument (family, child-welfare, immigration, labour, consumer-tenancy, general) — default family. Call dbn.list_personas if unsure.\n\nPRIVACY: the DBN tools are process-and-forget. Do NOT call dbn.save_to_case unless the user explicitly asks to save a result. Suggest dbn.redact before sharing anything containing names or IDs.\n\nAlways cite the sources the tools return. If a tool returns no grounded sources, say so plainly rather than guessing."
}
},
"id": "a1b2c3d4-0002-4a01-8a01-000000000002",
"name": "DBN Agent",
"type": "@n8n/n8n-nodes-langchain.agent",
"typeVersion": 1.7,
"position": [
0,
0
]
},
{
"parameters": {
"model": {
"__rl": true,
"mode": "list",
"value": "gpt-4o"
},
"options": {}
},
"id": "a1b2c3d4-0003-4a01-8a01-000000000003",
"name": "Chat Model (wire your LiteLLM/Azure cred)",
"type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
"typeVersion": 1.2,
"position": [
-120,
220
],
"notes": "Placeholder. Attach your existing OpenAI-compatible credential (e.g. colin LiteLLM at :4000, or Azure OpenAI). No new cloud spend is wired by this template."
},
{
"parameters": {
"endpointUrl": "https://mcp.dobetternorge.no/mcp",
"serverTransport": "httpStreamable",
"authentication": "bearerAuth",
"include": "all"
},
"id": "a1b2c3d4-0004-4a01-8a01-000000000004",
"name": "DBN MCP Tools",
"type": "@n8n/n8n-nodes-langchain.mcpClientTool",
"typeVersion": 1,
"position": [
180,
220
],
"notes": "Bearer credential = a DBN user MCP token (dbn_user_mcp_...) minted at https://tools.dobetternorge.no/mcp.php. The catalog is dynamic — this one node enumerates all 23 dbn.* tools."
}
],
"connections": {
"When chat message received": {
"main": [
[
{
"node": "DBN Agent",
"type": "main",
"index": 0
}
]
]
},
"Chat Model (wire your LiteLLM/Azure cred)": {
"ai_languageModel": [
[
{
"node": "DBN Agent",
"type": "ai_languageModel",
"index": 0
}
]
]
},
"DBN MCP Tools": {
"ai_tool": [
[
{
"node": "DBN Agent",
"type": "ai_tool",
"index": 0
}
]
]
}
},
"settings": {
"executionOrder": "v1"
},
"pinData": {},
"meta": {
"templateId": "caveau-dbn-agent-starter"
},
"tags": [
{
"name": "caveauAI"
},
{
"name": "dbn"
}
]
}