DEV Community

vhmns
vhmns

Posted on AI-assisted

SlothTill: an open-weight sloth that reads WhatsApp orders for tiny shops

Hacktoberfest Open-Source AI Challenge Week 3: Slow and Steady Submission πŸ¦₯

This is a submission for the Hacktoberfest Open-Source AI Challenge Week 3: Slow and Steady

What I Built

In Indonesia, where I live, a huge share of small businesses don't have a website, a POS, or an online store. They have WhatsApp.

A snack shop gets orders like this all day:

Rina: wkwk aku extra hot 2 ya kak, sama mendoan yg pedes 1
Rina: dikirim ke kos Grendeng gg. Mawar no 7 bisa?
Rina: udah tf ya kak

Translation: "two extra-hot cassava chips and one spicy tempeh, deliver to my boarding house, and I already transferred the money." Then a customer in the neighbourhood group chat changes her order from two boxes to one, someone else orders on her behalf ("nitip"), a third person cancels because of a work trip, and a tourist in Bali asks in English whether the cookies are gluten-free.

At night, the owner scrolls back through all of it and copies it into a notebook. I build websites for shops like this through my small studio, and that nightly scroll is the most boring, most error-prone part of their day.

SlothTill does that scroll for them. Drop in the day's WhatsApp exports and you get:

  • An order book: customer, items, pickup or delivery, address, paid or unpaid, priced from the shop's catalog
  • Replies ready to paste back, written in each customer's own language, with the total appended
  • "Still waiting on you": questions nobody has answered yet
  • A "Close the shop" receipt: revenue, money still to collect and from whom, best sellers, stock running low
  • CSV export, and an overnight CLI you can put on a cron job so the recap is waiting when you wake up

The person who gets to be lazier is the shop owner. The sloth hangs around, reads slowly, and does the boring bit.

Demo

Live: https://slothtill.kodekecil.tech

Click Load the sample shop, then Let the sloth read it. Without a key, it replays a real recorded run (Nemotron 3.5 Lightning, 5 chats, 29 messages). Paste an OpenRouter key, or pick Ollama on this computer, to run it live on your own chats.

SlothTill demo: sample chats in, order book and closing-time receipt out

Code

πŸ¦₯ SlothTill

Your WhatsApp chats are your order book. Let the sloth read them.

Millions of small shops, especially in Southeast Asia, run their whole business inside WhatsApp. Orders arrive as casual chat ("extra hot 2 ya kak, sama mendoan yg pedes 1"), get changed an hour later, get paid "udah tf ya", or quietly cancelled. At night the owner scrolls back through everything and copies it into a notebook.

SlothTill does that part. Drop in your WhatsApp exports and get:

  • An order book: who ordered what, pickup or delivery, address, paid or not, priced from your catalog
  • Replies ready to paste, in each customer's own language, with the total appended
  • "Still waiting on you": questions nobody answered yet
  • A closing-time recap printed like a till receipt: revenue, money still to collect, best sellers, low stock
  • CSV export, plus an overnight CLI you can put on…

No framework, no build step, no dependencies. About 400 lines of plain JavaScript shared between the browser app and the CLI.

How I Built It

The model is a reader, not a calculator. The pipeline has four steps, and only one of them is AI:

  1. Parse (code). Plain JavaScript splits WhatsApp exports into messages. It handles Android and iOS formats, multi-line messages, and drops "" placeholders.

  2. Read (open-weight model). One chat per call. The model gets the shop's catalog, a short Indonesian WhatsApp slang cheat sheet (tf = paid, jadi 1 aja = change the quantity to one, batal = cancel, nitip = add an order for me, bayar pas ambil = pay on pickup, so not paid yet), and returns JSON: orders, changes, cancellations, payment claims, unanswered questions, and a reply draft. I used OpenRouter's response_format: json_object and turned reasoning off, because a reasoning model happily spent its entire 2,500-token budget thinking about Rina's boarding house and returned nothing.

  3. Verify (code). This was the part that made it trustworthy. Small open models are good readers and sloppy bookkeepers, so the model proposes and code checks:

    • Prices come from the catalog. The model never does math.
    • Product codes get repaired, carefully. The 3B-active model abbreviated NOPIA to NPIA and LANTING to LNTG. If the guess is an unambiguous subsequence of exactly one catalog code, it's fixed; otherwise the row is flagged.
    • "Paid" must be said by the payer. In the group chat, Mbak Lia wrote "aku udah transfer ya mbok, 38rb" and the model marked her neighbour Bu Wati as paid too. The verifier only keeps paid: true if that same customer sent a payment message, so Bu Wati gets a red check me tag instead of a silent mistake.
    • Reply language. The model answered Sarah, who writes in English, in Indonesian. A tiny stop-word check notices the mismatch and flags it for a human.
  4. Nap (code). Free and self-hosted endpoints get busy. On a 429 or 5xx, SlothTill backs off for 2, 4, 8 and 16 seconds and tries again instead of falling over. During testing, Gemma 4's free tier was rate-limited for the whole evening; the sloth just napped and retried. Slow and steady, literally.

The models. SlothTill talks to any OpenAI-compatible endpoint. The model picker includes NVIDIA Nemotron 3.5 Lightning (30B total, 3B active, open weights, free on OpenRouter), Gemma 4 26B A4B, Qwen 3.6 35B A3B, gpt-oss 120B, Llama 4 Scout, Mistral Small 3.2 and DeepSeek V3.2. Or type any model id and point it at Ollama, llama.cpp or vLLM on your own machine.

The recorded demo run: Nemotron 3.5 Lightning, 5 calls, about 17 seconds of model time, 7,013 tokens, $0.

No backend on purpose. The web app is static files served by a tiny Cloudflare Worker with no API routes. Your key and your customers' chats go straight from your browser to the endpoint you choose. There's nothing on my side to leak.

Why Does Open Innovation Matter?

For this user, it's the difference between a tool they can actually adopt and one they can't.

  • It costs nothing to run. A shop that sells snack packs for Rp17,000 (about $1) is not going to pay for an AI subscription. The whole demo runs on a free open-weight model. When the free tier is busy, they can switch to another open model that costs a fraction of a cent per day, or run one on the laptop they already own.
  • Customer data can stay home. These chats contain names, phone numbers, home addresses and who has or hasn't paid. With an open model, the owner can run SlothTill against Ollama on their own machine and nothing leaves the shop. With a closed API, that option simply doesn't exist.
  • No lock-in, and models are swappable. Switching from Nemotron to Gemma to Qwen is one dropdown. When a model was rate-limited, I changed one string and kept working. When a better small model comes out next month, SlothTill gets better for free.
  • Open models made me design better. Because I was working with a small 3B-active model, I couldn't hide behind "the big model will figure it out." I had to split the job: the model reads, code verifies. That verifier catches real mistakes (wrong payer, wrong product, wrong language) and it would make SlothTill safer with any model, open or closed.

Where the open approach was better than a closed one: the free tier plus local fallback, the privacy story for customer data, and the freedom to swap models in seconds. Where it was worse: a small model makes more mistakes than a frontier one. The verifier and the check me tags are how I turned that weakness into something an owner can trust.

The Lazy Payoff

On the sample day (5 chats, 29 messages, 6 orders including one cancellation), SlothTill estimates it saves the owner about 11 minutes: roughly 7 seconds to read each message, 45 seconds to write each order down, and 30 seconds to type each confirmation reply. A busy shop with a few hundred messages a day gets closer to an hour back, every day. The estimate formula is in src/core.js so you can argue with it.

The sample shop and its customers are fictional, but the chat style is exactly what the shops I work with deal with every day.

Thanks for reading. The sloth is going back to sleep now. πŸ¦₯

Top comments (0)