It's less than 2 weeks before the 2026 midterm elections and none of the newsletters I receive send me the type of content that I want and when I want it - so I decided to build my own with the help of AI.
My goal is to create a newsletter that is personalized to my interests in the format that I prefer. It will deliver up to date polling data with minimal commentary, focus on the local New York state races that I have been following, and provide some data on nationally competitive ones. The newsletter will be simple and fast loading: no images, no ads, no bloat. Just the content that I want using my own styled newsletter template.
In terms of the polling data and how it gets displayed in my newsletter, this is where AI comes into play. I will leverage Claude to fetch the polling data for these races, use my Email Chart Builder data viz tool to render everything into HTML bar charts, package everything together in a boilerplate HTML template, and finally send me the newsletter via the MailJet API.
Establishing the Framework and Guidelines for the AI Agent
First, I built a boilerplate HTML email template with instructions to the AI agent on where to insert the election content. Then I had the AI agent learn how to use the Email Chart Builder tool in order to render polling data. I want each poll to display in the form of data bar charts without the use of images. Why? Simply because I do not want to deal with all the steps for uploading and hosting images. I want this newsletter to be lightweight and fast-loading.
Finally, I created a SKILL.md file with the specific guidelines, instructions, and rules for the AI agent to build and send me this polling election newsletter.
The Build Task Text
Using Claude Opus 5.5, I tasked the AI agent to research the midterm election races, write a short summary of each race, and render the fetched polling data in the form of HTML bar charts.
/email-chart-builder Look up the latest polling data for key, competitive races in the 2026 midterm elections. Include races in New York state at the top. Use the email-chart-builder/SKILL.md file to build the template with these charts. Include a two-sentence summary of each race and insert this text in between each relevant bar chart. In the "Source" section of each poll chart, provide a very brief summary of the political leanings of each group that conducted the poll.
After the build task was finished, Claude sends the final HTML newsletter to my email address through MailJet's Send API.
AI-Assisted Midterm Elections Newsletter
New York Governor
New York Attorney General
NY-17
Summary
There's an opportunity here for users to start using AI agents to generate and send their own, hyper-personalized newsletter content in the format that they prefer. News organizations have tried to build these types of personalized newsletters using click-tracking and articles read data. Why wait for news organizations to build you a personalized newsletter when you can do it through AI?







Top comments (0)