Open-source tool designed to throttle PC and server performance based on electricity pricing — lightweight CLI will automatically limit clocks during peak hours

WattWise CLI power monitoring app
(Image credit: Naveen Kulandaivelu)

A robotics and machine learning engineer has developed a command-line interface tool that monitors power use from a smart plug and then tunes system performance based on electricity pricing. The simple program, called WattWise, came about when Naveen built a dual-socket EPYC workstation with plans to add four GPUs. It's a power-intensive setup, so he wanted a way to monitor its power consumption using a Kasa smart plug. The enthusiast has released the monitoring portion of the project to the public now, but the portion that manages clocks and power will be released later.

Unfortunately, the Kasa Smart app and the Home Assistant dashboard was inconvenient and couldn't do everything he desired. He already had a terminal window running monitoring tools like htop, nvtop, and nload, and decided to take matters into his own hands rather than dealing with yet another app.

Naveen built a terminal-based UI that shows power consumption data through Home Assistant and the TP-Link integration. The app monitors real-time power use, showing wattage and current, as well as providing historical consumption charts. More importantly, it is designed to automatically throttle CPU and GPU performance.

Naveen’s power provider uses Time-of-Use (ToU) pricing, so using a lot of power during peak hours can cost significantly more. The workstation can draw as much as 1400 watts at full load, but by reducing the CPU frequency from 3.7 GHz to 1.5 GHz, he's able to reduce consumption by about 225 watts. (No mention is made of GPU throttling, which could potentially allow for even higher power savings with a quad-GPU setup.)

Results will vary based on the hardware being used, naturally, and servers can pull far more power than a typical desktop — even one designed and used for gaming.

Power Optimizer control flow

(Image credit: Naveen Kulandaivelu)
Jowi Morales
Contributing Writer

Jowi Morales is a tech enthusiast with years of experience working in the industry. He’s been writing with several tech publications since 2021, where he’s been interested in tech hardware and consumer electronics.

  • wakuwaku
    Can you read your own sources before parsing it through an AI to spit out an article? The repo is archived. It was archived before you posted this article. How are we supposed to "leave feedback"? Using tom's forums?
    Reply
  • JarredWaltonGPU
    wakuwaku said:
    Can you read your own sources before parsing it through an AI to spit out an article? The repo is archived. It was archived before you posted this article. How are we supposed to "leave feedback"? Using tom's forums?
    It was posted yesterday, AFAICT, and apparently archived shortly thereafter. I suspect this got a bunch of people sending requests and so the developer decided to close things down and "archive" the project for the time being, just to stop the floodgates. So sure, leave feedback here and there's a chance the dev will see it. Or go try to message him directly if you want. 🤷‍♂️

    Using AI to write articles at Future is strictly forbidden and would be cause for dismissal. Just because you find something you disagree with doesn't mean it was written by AI, or that an editor didn't give it a read. (I'm the editor who went over this one, making various changes in the process.)
    Reply
  • naveen_k
    Hey, WattWise author here. Thank of you so much for writing about my little project!

    When I published my project on my blog, I absolutely didn't expect it to end up on the front page of HN nor on Tom's Hardware! Almost all of the projects I post are quick weekend projects for things I needed to build for personal use. That's why I open source the code and archive the repos - I'm happy if someone else uses them, but normally don't plan to support them extensively. Based on the interest, I've just unarchived the repo and plan to add more functionalities.
    Reply
  • JarredWaltonGPU
    naveen_k said:
    Hey, WattWise author here. Thank of you so much for writing about my little project!

    When I published my project on my blog, I absolutely didn't expect it to end up on the front page of HN nor on Tom's Hardware! Almost all of the projects I post are quick weekend projects for things I needed to build for personal use. That's why I open source the code and archive the repos - I'm happy if someone else uses them, but normally don't plan to support them extensively. Based on the interest, I've just unarchived the repo and plan to add more functionalities.
    Hey Naveen, thanks for joining the forums and taking the time to comment — and for unarchiving the repo. Can you share any details about when you might release the Clocks/Power Tuning component so that people can have it automatically adjust their system settings based on time of day? Cheers!
    Reply
  • naveen_k
    I won't be able to make the changes needed for public release until this weekend, so I plan to release it by next Tuesday, hopefully sooner.
    Reply