How to Write Your First AI Agent

By Shelly Palmer

Agents are everywhere in conversation, but for most people, the concept is abstract or intimidating. The truth is, simple agents are already built into tools we use every day, and writing your first agent doesn’t require deep technical skill—it requires a mindset shift. Think of it as a new way to delegate.

This post is a practical starting point: what agents are, how they work, and how to build one today using tools you already know.

The Wisdom of Mrs. Hanlon

My second-grade teacher, Mrs. Hanlon, didn’t talk about artificial intelligence or automation. Instead, she taught us a simple framework for problem solving:

“First, use your eyes and ears to notice what’s happening around you,” she’d say with a warm smile. “Then, use your brain to think about what it means. Finally, use your hands to do something about it.”

Notice. Think. Do.

This seven-year-old-friendly framework now guides some of the most sophisticated technology on the planet. In engineering terms, we call it:

  1. Sense: Gather information from the environment
  2. Think: Process that information against goals or rules
  3. Act: Take action based on the processing

Every agent—from the simplest email filter to the most advanced autonomous system—follows this pattern.

Agents in Action: Productivity Multipliers

One of my oldest (and most useful) agents started as a very humble way to scan my Google Alerts and create an ordered list of article excerpts that might impact our business. This has evolved into a fully autonomous agent that creates a highly customized daily brief.

But, as powerful as it is, it still follows a strict protocol: sense, think, act.

To say that this agent saves hours each week would be to understate its importance in the extreme. It does the work of a three-to-five person research team.

Importantly, this agent didn’t replace or displace anyone. When we originally built it, we did not have the resources to stand-up the team required to do the work. Today, we could easily justify the human resources, but it would not be a good use of anyone’s time. The function is fully automated — as it should be.

From Concept to Reality: Writing a Product Requirements Document (PRD)

The gap between “I want an agent” and “I have an agent” is bridged by a clear Product Requirements Document (PRD). Here’s how to create one:

Step 1: Define the Problem Clearly

Start with a one-sentence definition:

“Our sales team spends 4+ hours weekly preparing for customer meetings, reducing their available selling time and creating inconsistent preparation quality.”

Then add context:

  • Who experiences this problem? (Specific roles/teams)
  • How frequently does it occur?
  • What’s the business impact? (Time, cost, missed opportunities)
  • How are people solving it today? (Manual processes, workarounds)

Step 2: Outline the Agent’s Capabilities

For each capability, use the Sense-Think-Act framework:

Meeting Preparation Capability

  • Sense: When should the agent activate? (“When a customer meeting is scheduled in Salesforce or the calendar”)
  • Think: What should it analyze? (“Customer history, recent communications, open opportunities, support tickets”)
  • Act: What should it produce? (“A one-page PDF briefing document with key customer information, relationship history, and talking points”)

Be specific about information sources and outputs.

Step 3: Define Success Metrics

How will you know if the agent is effective?

  • Reduced preparation time (from 45 to 15 minutes per meeting)
  • Improved meeting outcomes (20% increase in next-step commitments)
  • Higher customer satisfaction scores
  • Adoption rate among team members

Step 4: Specify Technical Requirements

This is where many non-technical executives stumble. Keep it simple:

  • What existing systems must the agent connect to? (CRM, calendar, email)
  • What permissions and access levels will it need?
  • Where should the agent deliver its outputs? (Email, Slack, CRM)
  • Are there security or compliance requirements?

Step 5: Prioritize Features for MVP

What’s the minimum viable product? Usually, it’s one clear capability that delivers immediate value. For our meeting prep agent:

  • Connect to calendar and CRM
  • Generate basic customer briefing document
  • Deliver via email 24 hours before meeting
  • Save the AI-generated talking points and sentiment analysis for V2.

Leading the Agent Revolution

The best agent implementations start with leadership, not technology. As you work with your team:

  1. Focus on outcomes, not features.What business problem are you solving?
  2. Start small and iterate.Build one capability that works well before adding complexity.
  3. Involve end users early.The people who will use the agent should help design it.
  4. Measure and refine.Set clear success metrics and continuously improve.
  5. Build for augmentation, not replacement.The best agents make people more effective, not redundant.

You Can Do This

Mrs. Hanlon’s simple wisdom—notice, think, do—gives us a powerful framework for understanding and creating agents. By translating this framework into clear requirements, you can help your technical teams build agents that deliver real business value.

The agent revolution isn’t some far-off future. It’s here today, waiting for leaders who can bridge the gap between business needs and technical capabilities. If you need help or want to chat about best practices, just reach out.

Author’s note: This is not a sponsored post. I am the author of this article and it expresses my own opinions. I am not, nor is my company, receiving compensation for it. This work was created with the assistance of various generative AI models.

About Shelly Palmer

Shelly Palmer is the Professor of Advanced Media in Residence at Syracuse University’s S.I. Newhouse School of Public Communications and CEO of The Palmer Group, a consulting practice that helps Fortune 500 companies with technology, media and marketing. Named LinkedIn’s “Top Voice in Technology,” he covers tech and business for Good Day New York, is a regular commentator on CNN and writes a popular daily business blog. He’s a bestselling author, and the creator of the popular, free online course, Generative AI for Execs. Follow @shellypalmer or visit shellypalmer.com.