Talk, Don't Type: A Bot That Won't Let Me Type My Arabic

I’m learning to speak and understand Levantine Arabic (Shami), and I’ve started a blog, Daily Derja, where I try to write at least one entry every day.

If you go to an LLM and ask it to make you a post about something in an Arabic dialect you’re learning, it’ll just make you a full post. You can put in a few words you’re trying to learn, so it feels like you’re doing the work, like you’re making the effort.

Then it makes you a post. It won’t be perfect. It’s a dialect, and LLMs are not perfect on dialects. But it’ll likely be better than what you could do, especially if you’re a beginner. I’m somewhere around a high A2, low B1 in Shami. It’s better than what I could do. But of course, it’s not really my post, and I’ve learnt nothing from writing it.

But you become good at what you practice. If you practice prompting, you’ll get better at prompting.

That’s the problem I kept running into with Daily Derja.

Here’s what one looks like when it’s done: Watching Barakah Meets Barakah, about a Saudi rom-com I watched when I couldn’t sleep.

Header of the Daily Derja post Watching Barakah Meets Barakah: an illustrated cover in a Levantine tile frame with the Arabic title بركة يقابل بركة, then the title, date, word count, an Easy difficulty badge and tags
The cover, title and tags
The خاطرة section of the post: four short paragraphs in Shami Arabic about staying up to watch the film and getting under four hours of sleep
The خاطرة, the part I said out loud
The كلام table: five phrases from the post, such as ما قدرت أنام and اتفرّجت على, with IPA and English meanings
The كلام table, a few phrases from the post with IPA and meanings
Featured image for Watching Barakah Meets Barakah
Daily Derjaنسمة فكرة

Watching Barakah Meets Barakah

A sleepless night with the Saudi rom-com Barakah Meets Barakah: a Shami learner catches a lot of the Saudi dialect, misses a lot, and plans a rewatch. In Arabic.

 dailyderja.com Read the post →

There were basically two ways a post could get written, and both were bad.

Let the LLM write it. It’s fast, and it’s not mine. You can see it in the length, too. LLMs tend to be verbose, especially next to someone with my vocabulary and command of the language.

Type it myself. Some posts I literally didn’t use any AI for, and the problem with those was that I didn’t like doing them. I was sort of discouraged from doing them, because they took so very long to type. Even using Yamli, typing in Arabic is tedious. It’s one thing to edit in Arabic. Typing in Arabic is very tedious.

You become good at what you practice. If you practice writing, you’ll get better at writing. My intent was to get better at speaking, and reading. That’s mostly what I’m practicing. Typing Arabic isn’t something I’m trying to get good at, and when I do want to practice writing, it’s by hand.

Why by hand?

I’d read somewhere that writing by hand helps with memory, and typing, eh, a little. Then I actually went and checked, and it’s narrower than I remembered. The best study I found is about Arabic, of all things: in Wiley & Rapp (2021), 42 adults learned twenty Arabic letters by writing them, typing them, or watching videos. The handwriting group learned faster and beat the others on every task. The famous “pen beats laptop” note-taking study, on the other hand, didn’t replicate. So: good evidence for learning a script, shakier for memory in general. I still do it, and I wrote down why.

There’s a dialect reason too. Accents in Arabic line up with spelling, so you kind of need to know how a word is spelled. Take ق: it’s a q, a g, a k or a glottal stop, depending on who’s talking. “I said” is قلت and “I ate” is كلت, and in some accents kult and kilt come out almost the same.

So no, dictation isn’t a convenience thing for me. Dictating in Arabic is harder, not easier. I could dictate in English and have it translated, but that defeats the whole point. The bot exists so I actually have to say the thing.

I send voice notes to a Telegram bot. That’s the whole interface.

Telegram chat: a six-second voice note, and the bot’s reply with the transcript in Arabic, تخطيط آخر بوست علي, the English translation underneath, and the options to finish, discard or re-record
A six-second voice note, transcribed, with the translation under it
  1. Record in clips. A sentence or two at a time. Each clip comes back transcribed (Whisper) with an English translation under it, and that translation turned out to be a sneaky learning check. If the English is wrong, either I said it wrong or it heard me wrong.
  2. Say done. Or خلص, or يلا, or بس, whatever comes out. The bot glues the clips together and a small model picks the series, title, summary and tags.
  3. Preview. I get the transcript back with four options: ok, edit, rewrite, discard. Or I just tell it what to change, like I’d tell a person.
  4. Save. On ok it fixes the blatant stuff, writes the post as Markdown with Hugo frontmatter, and opens a pull request on the site’s repo. Nothing’s live till I merge. A copy lands in my Obsidian vault too, voice clips next to it, raw transcript tucked in as a comment.
Telegram chat with the Daily Derja Post Maker bot: an OK reply, then ‘Saving and opening pull request…’, then ‘PR opened, merge it to publish’ with a note about three unclear phrases, ‘Saved to vault · pushed to Mac’, and a link preview of GitHub pull request #31, Add post: Learning Arabic Takes Time
What ok does now: a pull request on the site’s repo, plus a copy in the vault

Sometimes you just can’t say it. You don’t know how a word’s pronounced, so you say it wrong, ten times in a row. That’s happened to me. And dialect transcription isn’t perfect even when you get it right; native speakers have trouble with it too. So the bot needed a way to fix things by hand: edit 3 re-records clip three, or lets me paste in the corrected text. I didn’t optimize for that, though. The point is saying posts, not writing them.

I don’t want to publish all my mistakes. What’s the point? But I don’t want it turned into what a native speaker would’ve said either, because then it isn’t mine anymore. So the cleanup gets a short list of rules:

  • Fix blatant grammar mistakes and transcription garbage.
  • Don’t turn it into Fusha (Modern Standard Arabic).
  • Don’t make it fancy or literary.
  • Keep my voice, including the English words I actually use mid-sentence: bot, Telegram, post.
  • If something’s unclear, flag it instead of guessing.
  • Don’t add ideas

Here’s one clip, from a post about autumn in Beit Shemesh:

لون الورق بتغيّر عالشجر.

“The color of the leaves is changing on the trees.”

The bot picks the series, too. It counts what each series already has and leans toward the thin ones. Otherwise everything lands in the daily diary, the junk drawer of any blog.

The first post the bot ever made was about the bot, and it got filed under “Meta.” Which, in fairness, it was. The prompt now says Meta is almost never correct: if I’m talking about the tools, that’s context, not content.

Then, because I was actually using it, it broke. The model picked a series I’d since retired, the save step went looking for a folder that didn’t exist, and the whole thing crashed. Now anything that isn’t a real series falls back to the diary. That never comes up in a demo.

A few more pieces turn a draft into a post:

  • A frontmatter pass that fills in the description, difficulty and pull quote.
  • Text-to-speech audio for the vocabulary, generated in batch from a CSV, skipping anything that’s already there.
  • Cover images from fixed frames, where only the picture and the Arabic title change.
  • Hugo, with a pull request per post, deployed to GitHub Pages. Hosting costs nothing.

Tools, not an agent. I don’t generally run my own command-line tools. Sometimes I do, but usually I have Claude run the CLI for me. The idea is that I can see what Claude ran and know more or less what will happen, because I wrote the tool. I don’t need any self-reported chain of thought about what it did. I didn’t want to set up an agent, and I don’t want to burn a ton of tokens on things that should be deterministically done. I don’t need a agent to figure out how to do the same thing every time.

Elixir, because I wanted to use Elixir. That’s the short answer. It’s a personal project, and I wanted to get some chops in Elixir. It’s fun. It has a nice Ruby feel to it, but you don’t have to build all these object-oriented constructs. I know its main idea is concurrency, and I don’t think a bot with one user is that use case. That’s fine. (I’ve written about Elixir before, including two posts involving cheese.)

Write it locally first. The bot runs in Docker on a small server. Every post hits the disk first; only then does it get copied to my laptop and opened as a pull request. Copy fails? Nothing’s lost, I send retry. Pull request fails? The draft stays put and I send ok again.

A cheap model for the cheap jobs. Series picking and per-clip translations go to a small model. Cleanup gets the stronger one, since that’s where judgment actually matters.

The part I’m not thrilled with. I’d rather run things on-prem than rent SaaS, and transcription is still a cloud API. I already run WhisperX locally for other stuff. Is it good enough on Shami to switch? Haven’t tested it yet.

I was sure the posts had gotten significantly shorter since I started using the bot. LLMs are verbose, so shorter posts would mean less LLM. Then I counted. Median length of the main section of my Shami posts since March:

PostsMedian words
Spoken through the bot1162
Everything else3273

Shorter, but not significantly. I guess I’d made assumptions about what the numbers would be. Part of it is that “everything else” mixes posts an LLM helped with and posts I typed myself, and those pull in opposite directions. (That’s also why it’s the median. The mean says something much more dramatic, which is exactly why I don’t trust it here.)

The number was never really the argument, though. The posts are mine, and I keep writing them.

I put a lot of thought into this, and I think I should share it.

The tools, minus me

I’ve put up generic versions of the three tools, rebuilt from scratch without the git history:

Nothing that’s specific to me or Daily Derja is in them: no series, no frames, no fonts, no audio, no photos, no infrastructure. Just config, with placeholder examples to show you how to write it.

I don’t want everybody making things that look like Daily Derja. Come up with your own branding. The thing worth copying is the workflow: practice the part you actually want to get good at, and let the machine do the rest.

Jacob Shore

Hi, I'm Jacob. I'm a language nerd, developer, and spiritual wanderer.

Related Content