AI Photo Classification using Gemma, Google Drive, and Google Sheets - n8n Workflow

Use this powerful n8n workflow to automatically classify user-uploaded event photos using Gemma AI (via Featherless.ai), save files to Google Drive, and log categories in Google Sheets. Start with this n8n template today!

Workflow Preview

Ready to automate?

Download this n8n workflow template and start using it instantly.

Who is this best for?

Event organizers and marketing teams needing to quickly categorize thousands of attendee photos.
Users looking for advanced n8n templates integrating multimodal AI vision models.
Developers needing an example of a cost-effective, high-volume file processing n8n node pipeline.
Anyone wanting to automate data entry and AI processing into a centralized Google Sheets database.

Overview

Collecting event photos from attendees is easy, but manually sorting and tagging them for social media or archives is a massive time sink. This clever n8n workflow solves this by providing a seamless upload interface (using the built-in n8n form trigger) and instantly routing the images through a sophisticated, multimodal AI classification system (Gemma via Featherless.ai).

This specific n8n workflow is optimized for performance and cost-effectiveness. Before AI processing, the images are automatically resized using an n8n node, ensuring faster turnaround times. The results—including the AI-generated categories and the Google Drive link—are neatly appended to a Google Sheet, turning hours of manual tagging into an instant, automated process. This is a crucial n8n template for high-volume content operations.

How it Works

The entire process is initiated by the built-in n8n trigger: the On form submission node, which serves a public form for attendees to upload photos and enter their name.


  1. Segmentation: The Files to Items n8n node splits the batch upload so that each photo is processed individually.

  2. Optimization & AI Preparation: One parallel branch prepares the image for AI classification. It uses the Edit Image n8n node to fetch file information and resize the image (down to 512px width maximum) to speed up AI inference. The image is then converted to Base64 format.

  3. AI Classification: The core logic uses an HTTP Request n8n node to send the image and a strict classification prompt to the Gemma model hosted on Featherless.ai. The model is instructed to return a comma-separated list of relevant tags (e.g., 'Food & Drink', 'Group Shot'). The Extract Categories n8n node then parses this string into a clean array.

  4. Storage: Simultaneously, another branch uses the Google Drive n8n node to upload and permanently store the original file, generating a shareable link.

  5. Data Merging and Logging: The two parallel branches synchronize using the Merge1 n8n node. The subsequent Create Payload n8n node formats all extracted data (categories, drive link, submitter name, timestamp). Finally, the Append to Sheet Google Sheets n8n node writes the comprehensive record into the designated spreadsheet, completing the automated n8n workflow.

Installation Guide

To deploy this n8n workflow template, follow these steps:


  1. Import the n8n Workflow: Copy the provided JSON and import it into your n8n instance via the 'Workflows' > 'New' > 'Import from JSON' option.

  2. Set up Credentials:

Featherless.ai: You will need an API key for the featherlessApi credential used by the Classify Photo and Suggest Tags n8n node. This service handles the Gemma AI classification.
Google Drive & Sheets: Authenticate your Google accounts using the OAuth2 credentials for both the Upload file (Google Drive) and Append to Sheet (Google Sheets) n8n nodes.

  1. Configure Storage and Logging:

In the Upload file n8n node, update the folderId parameter to point to the specific Google Drive folder where you want to store the photos.
In the Append to Sheet n8n node, update the documentId and sheetName parameters to point to your target Google Sheet. Ensure the sheet has the required columns (filename, url, categories, submittedBy, submittedAt).

  1. Activate the Trigger: Ensure the On form submission n8n trigger is activated and share the provided webhook URL or public form link with your attendees.

Node Details

This n8n workflow utilizes several crucial n8n nodes:

On form submission (n8n trigger): The primary n8n trigger. It creates a user-facing form collecting 'Name' and 'Files' (photos).
Files to Items (Split Out n8n node): Splits the input data so that parallel operations can be performed on each uploaded file.
Edit Image (n8n node): Used twice—first to get image metadata, and second to resize the image to a maximum width of 512 pixels, optimizing the data size before calling the AI service.
Convert Image to Base64 (Extract From File n8n node): Converts the binary image into a Base64 string, which is required for multimodal AI HTTP requests.
Classify Photo and Suggest Tags (HTTP Request n8n node): Sends the Base64 data to the Featherless.ai endpoint to utilize the Gemma model for image classification, outputting tags based on the prompt's criteria.
Upload file (Google Drive n8n node): Stores the processed file copy in a specified Google Drive folder, generating a unique filename using data from the initial n8n trigger and execution ID.
Merge1 (n8n node): A core logic n8n node that synchronizes the output from the AI classification branch and the Google Drive storage branch.
Append to Sheet (Google Sheets n8n node): The final action, logging the file URL, submitter details, and the AI-generated categories into the designated Google Sheet rows.

Related n8n Workflows

Free

Nodes: 10 Nodes
Updated: December 26 2025
View all
Created by

Freelance AI Automation Engineer based in London, UK. Since 2024, my n8n templates have documented my journey into applied AI and have helped hundreds of businesses and organisations get up to speed with AI automation. Today, I continue to explore use-cases as AI evolves and occasionally upload templates which I find novel and interesting. Subscribe to the RSS Feed: https://cdn.subworkflow.ai/n8n-templates/rss.xml

Featured*