# Reproducing Hacker News writing style fingerprinting

DevFeed: [Reproducing Hacker News writing style fingerprinting](<https://devfeed.tech/articles/reproducing-hacker-news-writing-style-fingerprinting-20641.md>)

Original publisher: [Read original article](<http://antirez.com/news/150>)

Author: Antirez

Published: 2025-04-16T13:53:16Z

Content type: article

Language: en

Sources: [Antirez](<https://devfeed.tech/sources/antirez.md>)

Topics: [cosine similarity search](<https://devfeed.tech/topics/cosine-similarity-search.md>), [reproducibility](<https://devfeed.tech/topics/reproducibility.md>), [Python](<https://devfeed.tech/topics/python.md>), [dataset](<https://devfeed.tech/topics/dataset.md>), [Website](<https://devfeed.tech/topics/website.md>)

Tags: [cosine](<https://devfeed.tech/tags/cosine.md>), [cosine-similarity](<https://devfeed.tech/tags/cosine-similarity.md>), [data](<https://devfeed.tech/tags/data.md>), [dataset](<https://devfeed.tech/tags/dataset.md>), [fake-accounts](<https://devfeed.tech/tags/fake-accounts.md>), [github](<https://devfeed.tech/tags/github.md>), [hacker-news](<https://devfeed.tech/tags/hacker-news.md>), [int8](<https://devfeed.tech/tags/int8.md>), [python](<https://devfeed.tech/tags/python.md>), [quantization](<https://devfeed.tech/tags/quantization.md>), [ram](<https://devfeed.tech/tags/ram.md>), [redis](<https://devfeed.tech/tags/redis.md>), [report](<https://devfeed.tech/tags/report.md>), [repository](<https://devfeed.tech/tags/repository.md>), [script](<https://devfeed.tech/tags/script.md>), [similarity](<https://devfeed.tech/tags/similarity.md>), [style](<https://devfeed.tech/tags/style.md>), [tiny](<https://devfeed.tech/tags/tiny.md>), [top](<https://devfeed.tech/tags/top.md>), [writing](<https://devfeed.tech/tags/writing.md>)

## AI overview

The reproduction builds Hacker News user style fingerprints from comment histories and compares them with Redis Vector Sets. It preprocesses a 10 GB archive into per-user word counts, then uses 350 top words by default: each user's relative word frequency is centered against global usage and divided by that word's global standard deviation to produce z-scores. VSIM retrieves similar profiles. The author found that using too many words surfaced topic overlap rather than writing style; cited guidance puts useful word counts around 150-500. Tests with split comment sets matched the same users well for most tested cases, but similar results usually indicate shared style, not fake accounts, since throwaway accounts may have too little data. The author also notes that style patterns can reflect native-language differences. The demo uses about 700 MB of RAM and may not remain online; reproduction code and instructions are in the linked repository.

## Source excerpt

About three years ago I saw a quite curious and interesting post on Hacker News. A student, Christopher Tarry, was able to use cosine similarity against a vector of top words frequencies in comments, in order to detect similar HN accounts -- and, sometimes, even accounts actually controlled by the same user, that is, fake accounts used to uncover the identity of the writer. This is the original post: https://news.ycombinator.com/item?id=33755016 I was not aware, back then, of Burrows-Delta method for style detection: it seemed kinda magical that you just needed to normalize a frequency vector of top words to reach such quite remarkable results. I read a few wikipedia pages and took mental note of it. Then, as I was working with Vectors for Redis I remembered about this post, searched the web only to discover that the original page was gone and that the author, in the original post and website, didn't really explained very well how the data was processed, the top words extracted (and, especially, how many were used) and so forth. I thought I could reproduce the work with Vector Sets, once I was done with the main work. Now the new data type is in the release candidate, and I found some time to work on the problem. This is a report of what I did, but before to continue, the mandatory demo site: you can play with it at the following link: https://antirez.com/hnstyle?username=pg&threshold=20&action=search NOTE: since the dataset takes 700MB of RAM, in my tiny server, in the next months I may take this down. However, later in this post you will find the link and the Github repository with the code to reproduce everything from scratch. NOTE2: I hope the web site will survive, it's a very crude Python script. I benchmarked the VSIM command in such a small server and yet it can deliver 80k VSIM per second! The wonders of int8 quantization, together with a few more optimizations. But the Python script is terrible, creates a new Redis connection each time and so forth. Fingers