Contents

Script for sorting cartoons

Cartoon-sorting script

Background

I originally wanted to write an article about how I made a Python script to make sorting cartoons easier. But the script came from a time when AI agents (large language models (LLMs)) weren’t yet as popular or capable. It was written entirely by hand, and I thought it might be valuable to others: you could take the idea (and the code too) as a starting point and build something of your own. Specialized tools make it easy to solve your own small everyday problems.

But now anyone can get a sophisticated tool from a single prompt, and the value of an article like this has dropped a lot.

Why publish?

Still, I think it’s worth publishing, if only for the idea itself. Ideas about what is possible are becoming more valuable now. This isn’t a commercial thing, more a way to share a thought: look, I automated this. Someone out there is doing the same routine work, or something similar, and doesn’t even think that it could be sped up, automated, or made more convenient.

I won’t publish the code: anyone can write an equally good tool in half an hour.

What the program looks like

Screenshot of the program

The main window is a list of all files. Here they are cartoons, mostly in AVI format. At the top is the path they’re loaded from. In my case it’s a NAS storage over SFTP on my local network. Next to it is the number of cartoons sorted and watched in the current session: in the screenshot it’s 51 out of the total. I didn’t add a local database such as SQLite, to avoid complicating the program. It could track overall state: how many cartoons have been sorted in total, a more precise number, and which category each cartoon went into. But I didn’t really need that. I could have just kept an index in a file: this cartoon went into 3—4, that one into 5+. I don’t need to know this.

The second line shows the current state, for example that a cartoon is playing. Then come the hotkeys:

  • 1 creates a shortcut to the cartoon in the 3—4 directory;
  • 2 creates a shortcut to the cartoon in the 5+ directory;
  • D (Delete) deletes, with confirmation;
  • S (Skip) skips;
  • R (Replay) plays it again, and Enter does the same;
  • Q quits without confirmation.

That’s enough to open cartoons quickly and create shortcuts. Essentially, the program’s job is to make creating shortcuts convenient.

Why shortcuts?

I downloaded the whole cartoon collection via torrent from a particular site, https://multiki.arjlover.net/, and I keep seeding, so I don’t want to change the original directory.

I do delete some cartoons: ones that are, in my opinion, really low quality, or adult cartoons that neither I nor my daughter will watch. Those will leave the seeding, but the vast majority, thousands of cartoons, stay. To avoid disturbing the original directory structure, I don’t move cartoons between folders. I create symlinks/shortcuts in 3—4 and 5+ instead.

When the time comes for 5+, I’ll sort that too. It contains cartoons with deeper meaning, with political subtext, for example, or ones that are simply long, an hour and a half each. Those will probably end up in a 6–7 category.

Sorting principle

How a cartoon ends up in one category or another?

Duration

When I start a cartoon, the first thing I check is its length. Five to ten minutes is good, with a couple of minutes’ tolerance either way. Anything clearly longer than fifteen minutes doesn’t fit 3—4 and goes straight to 5+. Cartoons shorter than five minutes are usually too simple, often with no words at all, but my daughter likes those too.

The reason is that a child of three or four can hold attention on one activity for no more than ten minutes, with fifteen probably the ceiling. I heard this from my wife, she has read books about it, and I see the same in my daughter. She plays a board game for up to about fifteen minutes with great pleasure: she’s focused, understands what’s going on, and isn’t distracted by anything. It’s the same with cartoons. If a cartoon runs eight or nine minutes, she remembers what happened, knows the characters, and can even explain their motivation. If it runs fifteen to twenty minutes, or two in a row, she struggles to remember which came first and what happened in it. Board games work the same way: the second game in a row goes noticeably worse. She doesn’t always follow the board, she doesn’t want to sit any more, and she starts fidgeting, grabbing toys, and getting distracted. By the end it’s more irritating than enjoyable.

Style

If the length fits, I watch the cartoon itself, sometimes skipping ahead a little. First I look at the style. Some cartoons are arthouse-like, drawn in very unconventional ways. This is most often the case with war cartoons, about the Great Patriotic War or World War II: they use sand and dark colors, and they’re often black and white. My daughter definitely won’t watch those. They’re not age-appropriate, and she can’t tell who the characters are, what motivates them, or what the point is. If such a cartoon is also poorly digitized, I sometimes delete it.

Quality and characters

If a cartoon is reasonably well made (puppet or hand-drawn), the voice-over is good, and the language is clear, I look more closely. It shouldn’t be a single-voice translation where a person with a rolled “r” and no engagement voices all the characters.

Next I look at who the characters are. Animals are a plus, and pets are doubly so. Cats or dogs immediately make a cartoon a favorite and give it a good chance of landing in 3—4, because my daughter loves cats very much, and dogs too.

Plot and message

It’s good if the music is decent and the plot is simple. The message should be kindness, friendship, or basic understandable things, discipline (for example, that you should listen to your parents). Songs are a big plus, especially clear and nice ones. If all this fits my values and priorities, the cartoon goes into 3—4, and in the next viewing session I may pick it from the new ones.

There are cartoons about death. I sometimes send those to 5+ and sometimes delete them: it’s too early for her to understand what death is, or complicated relationships like betrayal, or rudeness. For now I want to shield her from that, and she doesn’t need to know it. Let the cartoons be kind, bright, and simple.

Conclusion

The Python script runs locally. It’s a small tool that makes it easier to create shortcuts for cartoons I’ve watched. That mechanical action got in the way more than it helped: while sorting, I wanted to concentrate on watching, not spend as much time creating shortcuts. Why do it by hand, even with hotkeys, if it can come down to pressing one button? Plus a little convenient console interface. That’s really it about one small Python script.