DEV Community

Cover image for Why My AI Writer Waits 10 Posts Before Learning
Naheel Muhammed
Naheel Muhammed

Posted on Edited on Originally published at naheel.me AI-assisted

Why My AI Writer Waits 10 Posts Before Learning

Generic writing advice is a prior. My own posts are the evidence.

I put that line at the top of the dev-skills README because it sums up what I wanted to build: a writing workflow that uses my results, not just generic tips. I made seven agent skills and a small Python script. There’s no app or dashboard. My coding agent reads the files, helps me draft and review posts, and the script adjusts a few local weights from my post history.

What I shipped

I pushed dev-skills on Nov 18. It’s MIT-licensed and works with OpenCode, Claude Code, and other agents that load SKILL.md files. When I first published this article, the repo had four stars. That’s the launch count, not today’s total.

Skill What it does for me
/dev-post Turns my idea into a draft, title options, and a copy-ready block
/dev-human Checks a draft for AI-sounding patterns using local heuristics
/dev-comment Gives me a few angles, then drafts a comment
/dev-audit Reviews my published posts using analytics and my log
/dev-learn Updates title-formula and tag weights from the audit
/dev-profile Reviews my dev.to profile and suggests changes
/dev-repurpose Helps me turn a longer asset into an article draft

How my loop works

I keep my post history in ~/.claude/devto/log.md. /dev-post adds the date, title, formula, and tags. Once a post has had time to collect analytics, I run /dev-audit and add its engagement metrics.

Then I run dev-learn.py. It reads my log and updates the JSON files that /dev-post uses. My next draft can use those weights when it suggests a formula or tags.

I call it a learning loop because a later draft can use information from earlier posts. It isn’t machine learning. I wrote a small rule that changes local weights; it doesn’t train a model or predict views.

Why I wait for 10 posts

I don’t want one result changing my defaults. A title might catch a trend. A tag might bring a different crowd. I could also publish at a lucky time. One post can’t tell me which of those things happened.

I chose 10 as a guardrail, not a statistically proven magic number. The script counts only rows with a valid engagement_rate. If I haven’t added analytics for a post, it doesn’t count.

Here’s the sample check in the script:

rows = audited_rows(rows)
n = len(rows)
if n < data.get("min_sample", MIN_SAMPLE):
    print(f"formulas: only {n} audited posts (need {data.get('min_sample', MIN_SAMPLE)}). Skipping weight updates.")
    return
Enter fullscreen mode Exit fullscreen mode

That check makes the script wait for 10 audited posts. It doesn’t prove 10 is the right cutoff. I picked a cautious starting point, and I may change it when I have more data.

What the script changes

Once my log has enough audited posts, the script calculates my average engagement rate. For a formula or tag that appears in new audited posts, it compares that item’s average with my account average.

If the item is at or above my average, I raise its weight by 0.1, up to 2.0. If it’s at or below half my average, I lower it by 0.1, down to 0.0. Anything between those cutoffs stays as it is. When a weight reaches zero, I move that formula or tag to archive; I don’t delete it.

I also fixed a repeat-run problem. The script records which posts it has applied. If I run --apply again with the same log, it skips those posts instead of boosting the same weights twice. New audited posts still count.

I run it without --apply first, so I can check the proposed changes. The script only writes to the files when I choose to apply them.

What I left manual

I keep the replacement list in dev-human/slop.json under human review. A word that sounds wrong in my voice might be fine in someone else’s, so I don’t let the script add replacements by itself.

I also left profile scoring manual. My log doesn’t track follower growth, so I can’t tell whether a profile change helped. I’d rather have the skill say what data is missing than pretend it learned something.

How to install it

I added separate install steps to the README for OpenCode, Claude Code, and Windows PowerShell. They show where I copy dev-learn.py and how I set DEVTO_SKILLS_DIR:

See the installation steps

For first-time setup, I use ~/.claude/devto/ for voice.md and log.md. I give /dev-post three of my own posts to build its voice profile. I’d rather do that than get a polished draft that sounds nothing like me.

The honest part

When I first published this article on Nov 18, my log had one audited post. The script left the weights alone. I checked the output, and that was what I wanted. One post doesn’t tell me whether the loop improves future drafts.

I haven’t proved that these weight changes lead to more reads, comments, or useful conversations. I need more audited posts and time to compare results. For now, I can say the guard works and the script makes only the changes I asked it to make.

I used AI to help draft this article. The code and the decisions behind it are mine.

Source: github.com/naheel0/dev-skills

I chose 10 posts as my starting point. Would you trust a title or tag adjustment after 10 results, or would you wait for more? What evidence would you want first?

Top comments (0)