5
15 Comments

Just Launched ML Blocks - A No Code Tool to Build Custom Image Processing Workflows

Hi everyone! 👋

I'm Neil and I'm just starting out building my app, ML BLocks 🧩, in public. I started working on it 2 months ago, so I should have written this earlier but better late than never!

ML Blocks is a product that was born to solve a problem I had with bulk processing images at a previous startup. We did some very repetitive image editing work and decided we wanted to speed up our workflow by running an automated sequence of image processing actions on images like remove background, crop, resize to multiple aspect ratios, and AI caption generation.

repetive image editing example

We found some APIs online like removebg that could bulk process one piece of the workflow but we almost always needed to write our own code to glue everything together, post-process the images, and build a complete workflow.

Ultimately we realized this is a common issue in any kind of image processing task. Especially now when there are so many hosted AI models to experiment with, having to write these pipeline endpoints really slows down prototyping.

To solve this, ML Blocks lets you create custom image processing workflows that can handle multi-step image generation or analysis pipelines using node-based workflows. Just connect a bunch of blocks like remove background -> crop -> upscale and you get a full image handling workflow in a few minutes.

Here's a screenshot of a simple ML Blocks workflow. The cool thing about this is that you can take 1 input image and generate as many outputs as you need in a single click.
ML blocks screenshot

We're also building a way to deploy your entire workflow as a single API endpoint to integrate into apps and workflow automation tools.

If you want a more detailed explanation, I made a video tutorial here:
https://youtu.be/3kNX6iCgGoo

We're starting with about 30 blocks, 8 of which are AI blocks. For example:

  • Stable Diffusion XL
  • GPT4v
  • Remove BG
  • Upscale
  • Segmentation

The rest are basic image processing functions like crop, blur, saturation etc. There are nearly infinite ways to connect them and I feel like we're just scratching the surface on the kinds of workflows you could build with this. If you're into Blender for 3D rendering, you'll notice the parallels to shader nodes.

Some workflows you can build with ML Blocks are:

  1. Detect faces and blur them
  2. Crop image to the best-fit square, then add a text overlay
  3. Remove the background and recenter the subject in the frame

I've always struggled with sharing my work online, but the stories on IH are too inspiring to ignore so I've decided to give this a real shot and "just do it". I would love some feedback on the app if you have a minute and if you know someone who might find this useful, please share it :)

Here's a link to ML Blocks - https://mlblocks.com

Thanks a ton!

posted to Icon for group Building in Public
Building in Public
on January 26, 2024
  1. 1

    Hey — this is a really cool project. I’ve been trying to speed up handling large sets of images myself, especially adding consistent watermarks across hundreds of photos. Manual work or basic tools always seem to slip on position/size consistency when aspect ratios differ.

    How do you handle applying templates or preparing workflows that ensure watermark consistency across different image types? Also, what processing speed have you been able to achieve with large batches?

  2. 2

    Looks very nice.. all the best!

    How did you build the workflow tool? Is it completely custom?

    1. 2

      Thanks! For the front end tool, I use the ReactFlow library which provides some of the bare bones features to build graph workflows. The styling and functionlity to show various parameters etc is all custom - React flow is unopinionated in terms of style.

      The backend job scheduler is fully custom - it's basically a graph scheduler that passes data and executes various "blocks" as separate endpoints. I'm happy to go into more detail into how everything works if you like!

  3. 2

    This is pretty nice, think it can be used to implement dynamic banners for blog posts.

    1. 1

      Funny you mention that! I wrote an article about doing exactly that:
      https://blog.mlblocks.com/p/auto-generate-banner-images-for-blog

      1. 1

        Maybe you thought about that already, here’s an idea of the API, either:

        1. Allow the creation of a workflow, user gets a workflow ID, and then a simple GET request with query params (ID + input params of the workflow) can run the workflow and return the result. This way, someone could simply embed an image URL and workflow runs magically.
        2. Make it possible to serialize an entire workflow definition as a URL param. So instead of workflowID, the user can pass the entire workflow config serialized. Might be risky if workflow is too big (url params are limited to I think 4096 chars depending on browser) but might also allow the change of workflow “on the fly”. Definitely a v2/v10 feature.

        And add a caching mechanism, so a given workflow is run only once given the same parameters.

        Just ideas that I’d find cool as a user ;) good luck! This looks awesome!

        1. 2

          Awesome this is super useful feedback!

          I will say 1 has always been the plan! We're working on an API right now!

          2 is super interesting. We've been thinking about allowing the overloading of params of non-input blocks in the API call, but the API calls end up becoming a bit too cumbersome. I think there's definitely an elegant solution here to present a simple interface with extensibility if needed, but you're right it'll be a few versions down the road.

          1. 1

            Nice! (2) is definitely a nice-to-have-later feature. Good luck!

        2. 1

          I just looked up Paw and it seems like you're an API expert!! I'll definitely ping you about this as I get into the weeds of building out the API layer.

          1. 1

            Not sure I'm an expert haha but absolutely don't hesitate to ping me if you have API questions (tooling suggestions or otherwise). I might ping you about ML :)

      2. 1

        Awesome will try it out!

  4. 1

    Oh it's amazing Neil. I loved. It's super user friendly and powerful. Congrats mate! BTW, how do you make the demo video on the landing page? Some specific tool?

    1. 3

      Oh the video I just made using Canva. I'm no expert in animations and stuff but you can hack Canva to and use slide transitions to mimic animation effects. I just use that :)

      1. 1

        Hey that's simpler than I imagined. Thanks for sharing Neil. Really appreciate it

Trending on Indie Hackers
Build AI Agents & SaaS Apps Visually : Powered by Simplita ai User Avatar 32 comments You don't need to write the same thing again User Avatar 23 comments No Install, No Cost, Just Code User Avatar 21 comments I built an Image-to-3D SaaS using Tencent's Hunyuan 3D AI User Avatar 18 comments Let’s Talk: What’s Missing in Today’s App Builders? User Avatar 17 comments 15 Years of Designmodo User Avatar 14 comments