Talk Python To Me - #521: Red Teaming LLMs and GenAI with PyRIT

English is now an API. Our apps read untrusted text; they follow instructions hidden in plain sight, and sometimes they turn that text into action. If you connect a model to tools or let it read documents from the wild, you have created a brand new attack surface. In this episode, we will make that concrete. We will talk about the attacks teams are seeing in 2025, the defenses that actually work, and how to test those defenses the same way we test code. Our guides are Tori Westerhoff and Roman Lutz from Microsoft. They help lead AI red teaming and build PyRIT, a Python framework the Microsoft AI Red Team uses to pressure test real products. By the end of this hour you will know where the biggest risks live, what you can ship this quarter to reduce them, and how PyRIT can turn security from a one time audit into an everyday engineering practice.

Episode sponsors

Sentry AI Monitoring, Code TALKPYTHON
Agntcy
Talk Python Courses

Tori Westerhoff: linkedin.com
Roman Lutz: linkedin.com

PyRIT: aka.ms/pyrit
Microsoft AI Red Team page: learn.microsoft.com
2025 Top 10 Risk & Mitigations for LLMs and Gen AI Apps: genai.owasp.org
AI Red Teaming Agent: learn.microsoft.com
3 takeaways from red teaming 100 generative AI products: microsoft.com
MIT report: 95% of generative AI pilots at companies are failing: fortune.com

A couple of "Little Bobby AI" cartoons
Give me candy: talkpython.fm
Tell me a joke: talkpython.fm
Watch this episode on YouTube: youtube.com
Episode #521 deep-dive: talkpython.fm/521
Episode transcripts: talkpython.fm
Developer Rap Theme Song: Served in a Flask: talkpython.fm/flasksong

--- Stay in touch with us ---
Subscribe to Talk Python on YouTube: youtube.com
Talk Python on Bluesky: @talkpython.fm at bsky.app
Talk Python on Mastodon: talkpython
Michael on Bluesky: @mkennedy.codes at bsky.app
Michael on Mastodon: mkennedy

Strict Scrutiny - The Trump Administration’s SCOTUS Winning Streak

Leah and Kate dive into the week’s legal news, explaining how SCOTUS continues to carry water for the Trump administration. They also cover an epic slapdown of the Roberts Court out of Hawaii, Sam Alito’s Italian sojourn, and the DOJ’s refusal to investigate the wads of cash lining border czar Tom Homan’s pockets. Then all three hosts are joined by special guests Sherrilyn Ifill, founding director of the 14th Amendment Center for Law & Democracy at Howard University, and New York Times columnist Jamelle Bouie to discuss the Supreme Court in the years after the Civil War and Reconstruction and why that era, known as the Redemption Court, resonates with today’s legal landscape.

Favorite Things:

Get tickets for STRICT SCRUTINY LIVE – The Bad Decisions Tour 2025! 

  • 10/4 – Chicago

Learn more: http://crooked.com/events

Order your copy of Leah's book, Lawless: How the Supreme Court Runs on Conservative Grievance, Fringe Theories, and Bad Vibes

Get tickets to CROOKED CON November 6-7 in Washington, D.C at http://crookedcon.com

Follow us on Instagram, Threads, and Bluesky


Hosted by Simplecast, an AdsWizz company. See pcm.adswizz.com for information about our collection and use of personal data for advertising.

What A Day - How To Survive Online Speech Wars Without Self-Censorship

Following the assassination of conservative activist Charlie Kirk, a wave of everyday people have been punished, getting doxxed and even losing their jobs because of statements they made online regarding Kirk and his death. Even the Vice President of the United States, JD Vance, encouraged Americans to call the employers of anyone they feel is “celebrating Charlie’s murder.” Free speech matters now, more than ever. But what can we say without fear of retribution? To find out what the rules around speech in America really are, and why this is no time to self-censor, we spoke to Ari Cohn. He’s lead counsel at the Foundation for Individual Rights and Expression, with a focus on tech policy.

And in the news: Oregon sues the Trump administration to stop the deployment of the state’s National Guard to protect federal buildings, current New York City Mayor Eric Adams pulls out of the upcoming mayoral race, and Israeli Prime Minister Benjamin Netanyahu changes his story on what happened with those bunker busters in Iran.

Show Notes:


Hosted by Simplecast, an AdsWizz company. See pcm.adswizz.com for information about our collection and use of personal data for advertising.

The Indicator from Planet Money - What media consolidation means for free speech

Jimmy Kimmel’s brief departure from the airwaves triggered a wave of debate over free speech.  Partly triggering his suspension was the government threatening to leverage its power over pending media deals. That’s in part due to a piece of decades-old legislation. 

Today on the show, we look at how the Telecommunications Act of 1996 set the stage for government meddling and corporate capitulation. 

Related episodes: 
Breaking up big business is hard to do 
Mergers, acquisitions and Elon’s “rude” proposal 

For sponsor-free episodes of The Indicator from Planet Money, subscribe to Planet Money+ via Apple Podcasts or at plus.npr.org. Fact-checking by Sierra Juarez. Music by Drop Electric. Find us: TikTok, Instagram, Facebook, Newsletter.

Learn more about sponsor message choices: podcastchoices.com/adchoices

NPR Privacy Policy

The Best One Yet - 🥃 “Negroni Hotel” — Death & Co’s hotel chain. Costco’s 9am DINK hour. Apple acquires Intel? +Ad-supported Toilet Paper

Death & Co. started the craft cocktail movement… and now it’s becoming a hotel chain.

Apple’s surprise Made in America power move?... Buy Intel (the whole company).

Costco opened 1 hour early for executive members … and it led to a surge in upgrades.

Plus, video advertising is coming for your… Toilet Paper.


$COST $INTC $AAPL


Want more business storytelling from us? Check out the latest episode of our new weekly deepdive show: The untold origin story of… Saturday Night Live 📺


Subscribe to The Best Idea Yet: https://wondery.com/links/the-best-idea-yet/ to listen.


Fat Bear Week Voting: https://explore.org/meet-the-bears


NEWSLETTER:

https://tboypod.com/newsletter 


OUR 2ND SHOW:

Want more business storytelling from us? Check our weekly deepdive show, The Best Idea Yet: The untold origin story of the products you're obsessed with. Listen for free to The Best Idea Yet: https://wondery.com/links/the-best-idea-yet/


NEW LISTENERS

Fill out our 2 minute survey: https://qualtricsxm88y5r986q.qualtrics.com/jfe/form/SV_dp1FDYiJgt6lHy6


GET ON THE POD: 

Submit a shoutout or fact: https://tboypod.com/shoutouts 


SOCIALS:

Instagram: https://www.instagram.com/tboypod 

TikTok: https://www.tiktok.com/@tboypod

YouTube: https://www.youtube.com/@tboypod 

Linkedin (Nick): https://www.linkedin.com/in/nicolas-martell/

Linkedin (Jack): https://www.linkedin.com/in/jack-crivici-kramer/

Anything else: https://tboypod.com/ 


About Us: The daily pop-biz news show making today’s top stories your business. Formerly known as Robinhood Snacks, The Best One Yet is hosted by Jack Crivici-Kramer & Nick Martell.



See Privacy Policy at https://art19.com/privacy and California Privacy Notice at https://art19.com/privacy#do-not-sell-my-info.

What Next | Daily News and Analysis - The Gaza Flotilla That’s Under Attack

With Gaza cut off from food and aid, activists have taken matters into their own hands, and are attempting to circumvent Israel’s blockade themselves via the Mediterranean.

Guest:  Zue Jernstedt, member of About Face: Veterans Against the War and participant on the Veterans Boat of the Global Sumud Flotilla.

Want more What Next? Subscribe to Slate Plus to access ad-free listening to the whole What Next family and across all your favorite Slate podcasts. Subscribe today on Apple Podcasts by clicking “Try Free” at the top of our show page. Sign up now at slate.com/whatnextplus to get access wherever you listen.

Podcast production by Elena Schwartz, Paige Osburn, Anna Phillips, Madeline Ducharme, and Rob Gunther.

Learn more about your ad choices. Visit megaphone.fm/adchoices

NPR's Book of the Day - Ian McEwan’s latest novel ‘What We Can Know’ is science fiction without the science

At 77, the Booker Prize-winning British novelist Ian McEwan shows no signs of slowing down. His new novel, What We Can Know, is set in Great Britain in the 22nd century – a country now partly underwater as a result of global warming. In today’s episode, McEwan speaks with NPR’s Scott Simon about the book’s plot – it tells of a search for a lost poem that was written in our own times – and notes that he is less interested in the future of science than that of the humanities, love and daily life.


To listen to Book of the Day sponsor-free and support NPR's book coverage, sign up for Book of the Day+ at plus.npr.org/bookoftheday

Learn more about sponsor message choices: podcastchoices.com/adchoices

NPR Privacy Policy

Short Wave - Why Do Some Hurricane Survivors Thrive After Disaster?

You’ve probably heard of PTSD, post-traumatic stress disorder. But what about its counterpart, post-traumatic growth?
The term was coined in the 90s to describe the positive psychological growth that researchers documented in people who had been through traumatic or highly stressful life events. Psychologists and sociologists conducting long-range studies on survivors of Hurricane Katrina – which hit 20 years ago and remains one of the most devastating natural disasters to hit the US – are continuing to learn more about it. 

So how do you measure post-traumatic growth? Can it co-exist with PTSD? NPR mental health correspondent Rhitu Chatterjee explains what scientists have found so far … and how it could help shape disaster relief efforts in the future.

Interested in more psychology and social science stories? Email us your question at shortwave@npr.org.

Listen to every episode of Short Wave sponsor-free and support our work at NPR by signing up for Short Wave+ at plus.npr.org/shortwave.

Learn more about sponsor message choices: podcastchoices.com/adchoices

NPR Privacy Policy

This Machine Kills - 425. The Oxymorons of Green Capitalism (ft. Thea Riofrancos)

We are joined by Thea Riofrancos — author of Extraction: The Frontiers of Green Capitalism — to chat about the many frontiers, tensions, and futures of green capitalism. How do we understand a system that is oxymoronic in its contradictory nature? How do we trace the political economies, material infrastructures, and extractive industries that are in the process of defining a planetary path dependency? Why do we need to spend a lot more time thinking about lithium? With the help of Thea’s sharp analysis, we answer these questions and more. ••• Extraction: The Frontiers of Green Capitalism | Thea Riofrancos https://wwnorton.com/books/9781324036760/about-the-book ••• Thea’s work at Climate + Community Institute https://climateandcommunity.org/bio/thea-riofrancos/ ••• Thea’s recent op-eds at the FT https://www.ft.com/stream/32daf017-8140-454c-8735-9c9947edc301 Standing Plugs: ••• Order Jathan’s new book: https://www.ucpress.edu/book/9780520398078/the-mechanic-and-the-luddite ••• Subscribe to Ed’s substack: https://substack.com/@thetechbubble ••• Subscribe to TMK on patreon for premium episodes: https://www.patreon.com/thismachinekills Hosted by Jathan Sadowski (bsky.app/profile/jathansadowski.com) and Edward Ongweso Jr. (www.x.com/bigblackjacobin). Production / Music by Jereme Brown (bsky.app/profile/jebr.bsky.social)