n8n Flow

These days, as everyone starts experimenting with AI, there are a variety of approaches for building so-called agents through simple interfaces. Zapier, Pipedream, string.com, and n8n are among the most popular platforms.

Why

Yesterday, I had my first idea for a meaningful use of this technology: Effortless note-taking on the go. I use Obsidian as my note-taking tool, and until now the process of getting notes from my phone to my hard drive was rather cumbersome.

Concept

The idea is a bit of a “roundabout” solution:

The Workflow

Der Flow

This diagram shows the described steps from left to right:

  1. Receive the email

  2. Extract attachments (delete the rest)

  3. Branch based on attachment type:

    1. Downscale image
    2. Extract text from .txt
    3. Transcribe .mp3
  4. Send result to ChatGPT

  5. Use a script to convert the response into Markdown

  6. Push to GitHub

One of the Problems

My experience with workflow systems is largely based on Enfocus Switch, in which I’ve built hundreds of flows. But as usual, every new technology brings surprising and seemingly insurmountable problems.

Any workflow system is built on the idea that something “flows.” In Switch, it’s physical files being moved from folder to folder, with Switch maintaining a job ticket for any metadata in the background.

In n8n, the flowing "thing" is a JSON object carrying item info, passing from node to node. My problem in this workflow: the “Analyze Image” node overwrites the JSON with a new one containing only the AI response. So how do you preserve the info collected before?

Luckily, I had solved exactly this issue in Switch last year: you duplicate the job and then merge the two job tickets afterward (as seen in the teal “merge” node in the screenshot).