How I discovered my dog apparently has more expensive tastes than I do.
I’ve spent a ridiculous amount of time lately building software to solve problems that probably don’t require custom software.
This latest project began with a fairly ordinary question: Am I actually getting a better deal at Kroger or Walmart?
Like most people, I have some assumptions about grocery prices. Walmart is probably cheaper for certain things. Kroger has its sales and digital coupons. Aldi is supposedly a bargain, although I haven’t even brought it into the equation yet. October 2026 update: Aldi has since entered the equation. The results were substantial enough that I’ve added the story below. Apparently, the grocery store with the weird shopping carts was hiding some very real savings.
But I wanted to know what was actually true based on the groceries I buy.
And naturally, instead of making a spreadsheet like a reasonable human being, I decided to build an application.
I called it Cost F*cker.
Because we’re going to f*ck some costs.

First, the receipts
The initial challenge was getting purchase data out of Kroger and Walmart.
Both retailers maintain online purchase histories, but the data isn’t necessarily presented in a convenient format for analysis. I started by capturing the HTML from actual receipt pages and writing Python parsers to extract the products, quantities, prices, discounts, and purchase dates.
The application runs locally using Flask, with SQLite storing the purchase history.
That sounds straightforward until you encounter the wonderful world of grocery receipt data.
Product descriptions are inconsistent. Discounts are represented differently. Package quantities aren’t always obvious. Sometimes a retailer changes the structure of its receipt page, and suddenly the parser that worked yesterday doesn’t work today.
There was a fair amount of trial and error, and several rounds of debugging, before the receipts were importing reliably.
But once the data was in the database, I had something useful: a growing record of what I actually bought and what I actually paid.
Twelve biscuits versus twenty biscuits
Comparing grocery prices turns out to be considerably more complicated than comparing two numbers.
Take frozen sausage biscuits.
One store sold a 12-count package for $6.32. Another sold a 20-count package for $10.49.
At first glance, one package is substantially cheaper.
But calculate the price per biscuit and they’re practically identical.
So I added package quantities, measurement units, and comparison rules. The application can now compare items by count, weight, volume, or full package, depending on what’s appropriate.

There are still things it can’t confidently compare.
White onions, for example.
One store might sell them individually while another prices them by the pound. Without knowing the actual weights, comparing the prices is basically grocery astrology.
I decided the software should admit when it doesn’t know something rather than invent an answer.
Then things got interesting
Once the receipts and comparisons were working, I connected the application to the OpenAI API.
The first idea was simple: paste in a shopping list, let AI interpret the descriptions, and match them against products I’d purchased before.
That worked surprisingly well.
I could type something vague like “kabob dog treats,” and the application could find the relevant products in my purchase history.
But a list of matches wasn’t particularly exciting. I still had to interpret the results myself.
What I really wanted was for the application to tell me what to do.
Should I shop at Kroger or Walmart? Is a second stop worth the trouble? Are there products I should stock up on? Am I spending an unreasonable amount on convenience foods?
I built a recommendation layer that handles the actual price calculations and passes the results to the AI for explanation.
That distinction is important. I don’t want a language model making up grocery prices. I want it explaining calculations grounded in my own receipts.
The thirty-one-dollar dog treat incident
And then we found the dog treats.
I had paid $30.99 at Kroger for a 24-ounce package of dog kabobs.
Walmart had an alternative I’d consider acceptable for $14.47, also 24 ounces.
That’s a historical difference of $16.52.
Sixteen dollars.
For dog treats.
I’m not saying every product in those packages is identical. They’re different brands and formulations, and that’s why the application distinguishes exact matches from substitutes I’ve personally approved.
But I am saying that’s a pretty compelling reason to look at Walmart before buying another package.
It was the first example that made me think this ridiculous application might actually be useful.
The AI needed an attitude adjustment
At this point, Cost F*cker was functional but painfully polite.
It sounded like a junior financial analyst presenting a quarterly grocery optimization report.
Which is an absolutely unacceptable personality for an application named Cost F*cker.
So I gave it a personality system, with settings ranging from mildly irritated to absolutely unhinged.
Then I asked it to assess the dog treats.
It responded with a profanity-filled tirade about the $30.99 price, wondered whether the treats were made from gold-infused pig skin, and suggested that my dog might be a connoisseur with a refined palate for pork shish kabobs.
It ended by recommending that I teach the dog to appreciate a good bargain.
I laughed harder than I probably should have.
And I knew we’d found the application’s voice.

The important thing is that the personality is separate from the calculation engine. The jokes can be ridiculous. The numbers cannot.
Giving Cost F*cker a memory
The next challenge was making the AI useful over time.
I didn’t want to paste in a shopping list, get advice, close the browser, and have the application forget everything.
So I started building persistent memory into the system.
Conversations are stored in SQLite. Product relationships are saved. Preferences can be proposed, reviewed, and approved.
If I tell the application that I prefer a particular brand of dog treats, it should remember that next month.
If we establish that two products should be compared per item rather than per package, it should remember that too.
And eventually, if the application recommends something and I follow through, I’d like it to check the next receipt and determine whether the recommendation worked.
That’s the long-term goal: not just an AI that gives advice, but an application that gets more useful as it accumulates real shopping history.
What comes next?
There’s plenty left to build.
Aldi is now officially in the mix, and it’s looking like my default store. The next challenge is building smarter recommendations for when to make strategic stops at Kroger or Walmart, while tracking whether the savings hold up over time.
I also want the application to identify recurring spending habits. If I’m consistently paying too much for a product, it should notice. If I’m spending a small fortune on prepared meals, it should probably say something.
Preferably something deeply insulting about the price, rather than about me.
The bigger ambition was to track real, verifiable savings—not just hypothetical differences between old receipts.
The Aldi experiment — how I spent weeks building software to discover the obvious
Eventually, I decided it was time to put Cost F*cker to work.
I’d spent all this time comparing Kroger and Walmart, but there was an obvious third contender I hadn’t seriously considered: Aldi.
I’d heard for years that Aldi was cheaper. But Aldi always struck me as a strange place. You need a quarter to unlock a shopping cart. You bring your own bags. The brands are unfamiliar. The whole experience feels like somebody explained the concept of a grocery store to an alien, who then built one using the absolute minimum number of employees and amenities.
But dammit, I wanted to know whether the savings were real.
So I went shopping.
And I bought $170.33 worth of groceries.
Then I fed the receipt into Cost F*cker and compared the purchases against the historical prices I’d accumulated from Kroger and Walmart.
The result?
$87.56 in estimated savings.
Eighty-seven dollars and fifty-six cents.
On one shopping trip.
The application found comparable historical prices for 56 of the 66 receipt lines. Most of the unmatched lines were shopping bags, with a few products that didn’t have reliable equivalents.
The competing historical cost for the comparable items was $257.89. My Aldi receipt was $170.33.

Now, there are some important qualifications. Those are historical prices from my receipts from the past eight months, not necessarily what every product would cost at Kroger or Walmart today. Some comparisons involve approved substitutes rather than identical products. And the unmatched items mean this isn’t a perfectly controlled experiment.
But the overall result was hard to ignore.
I had apparently spent a ridiculous amount of time building custom software to tell me something that practically everybody already knew: Aldi is cheap.
The irony was not lost on me.
But there’s a difference between hearing that Aldi is cheaper and seeing the difference calculated against the products you actually buy.
And the numbers were compelling enough that I’m changing how I shop.
Becoming a strategic cost f*cker
I don’t intend to become one of those extreme coupon people.
I’m not going to spend Sunday afternoons clipping coupons, studying circulars, and building a stockpile of mayonnaise in the basement because somebody figured out how to buy 47 jars for twelve cents.
That’s not me.
I’m more of a cost f*cker. (Go on, say it out loud with me. It’s not weird at all.)
And now that I have actual purchasing data, I can be a little more strategic about it.
Aldi will probably become my default grocery store. But I’m not abandoning Kroger and Walmart entirely.
Remember those $30.99 dog treats? Walmart still has a considerably cheaper alternative. If I’m already near Walmart, that’s an easy opportunity.
Kroger has frozen shrimp I like, specific products Aldi doesn’t necessarily carry, and a particular kind of ice cream my son enjoys. Those are perfectly good reasons to keep shopping there occasionally.
The trick is figuring out when a second stop is worthwhile and when I’m just burning gasoline and time to save seventy-three cents.
That’s one of the next things I’d like Cost F*cker to help me decide.
I also want to track the results over time. One successful Aldi trip is encouraging, but it doesn’t establish a reliable annual savings figure. I’ll need more receipts, more comparisons, and enough shopping history to distinguish genuine savings from changing prices, package sizes, and purchasing habits.
Fortunately, I’ve already built the ridiculous application that can help me figure that out.
And the next time I walk into Aldi, I’ll at least know what the hell to do with the shopping cart.
I’m still bringing a quarter, though. Apparently that’s nonnegotiable.
Could this actually be a product?
My wife thinks so.
And she made a point of saying she wasn’t just being encouraging. She genuinely thinks people might pay for something like this.
I’m not sure yet.
There are obvious challenges: obtaining reliable receipt data, supporting different retailers, handling product substitutions, protecting purchase histories, and making the savings substantial enough to justify a subscription.
There are already grocery comparison and budgeting products out there. Having a foul-mouthed AI doesn’t automatically make mine a viable business.
But the idea is interesting enough that I’m considering running it through Andrew Ventures, my experimental system for researching and evaluating business ideas.
At minimum, Cost F*cker has been a fun excuse to work with Python, Flask, SQLite, HTML parsing, API integration, AI prompting, persistent memory, and product design.
It’s also a good reminder that learning to build software doesn’t always begin with knowing exactly how to build it. Sometimes it begins with understanding a problem well enough to keep working through the technical obstacles until the thing actually does what you imagined.
And if it eventually saves me a few hundred dollars a year on groceries, fantastic.
If it also makes me laugh until I nearly fall out of my chair while explaining why I’m an idiot for buying thirty-one-dollar dog treats?
Even better.
Cost F*cker. We’re not just cutting costs. We’re f*cking them.