AI

QUANTUM

KNOWLEDGE

GUEST LECTURE · ETHICAL AI FOR AUTONOMOUS SYSTEMS · RAISE

AGENTIC AI
LOOPS

Sequence, Selection, Iteration

Tyson L. Swetnam, PhD · Center for Advanced Research Computing · University of New Mexico

UNM Center for Advanced Research Computing

THE PLAN FOR TODAY

Segment

What happens

Part 1 · What is agentic AI?

Prediction, language models and agents: what each one is and does

Part 2 · Three building blocks

Sequence, selection, iteration, and the loop inside every agent

Part 3 · Loops of loops

Teams of agents, how they fail, and the July 2026 incident

Close

Where to learn more, and compute at CARC

Then: discussion

Your instructors lead the ethical implications, including moral agency and accountability

Backup slides

For questions: deeper technical detail, and material your instructors may draw on

UNM Center for Advanced Research Computing

AGENTIC AI LOOPS · RAISE · FALL 2026

PART 1

WHAT IS
AGENTIC AI?

prediction, language, action

UNM Center for Advanced Research Computing

AGENTIC AI LOOPS · RAISE · FALL 2026

AGENTIC AI IN ONE SENTENCE

SOFTWARE THAT IS GIVEN A GOAL, DECIDES ITS OWN STEPS, AND ACTS, USING TOOLS, UNTIL IT JUDGES THE JOB DONE.

In the news: coding agents

Change files, run the tests, fix what breaks, and try again.

Assistants that browse and book

Click through websites and fill in forms on your behalf.

Research agents

Read the sources, run the analysis, write the report.

Definition and examples after the GPT 101 workshop, Agentic AI [1]

UNM Center for Advanced Research Computing

AGENTIC AI LOOPS · RAISE · FALL 2026

THREE KINDS OF AI

1 · PREDICTIVE MODEL

regression, classifiers

Learns a pattern from examples with known answers [2].

In: measurements. Out: a number or a label.

Who acts: a person, or code someone wrote.

On a robot or a vehicle

“Is that a pedestrian?” “How far will this battery go?”

2 · LANGUAGE MODEL

LLMs, chatbots

Learns the patterns of language from a vast amount of text [3].

In: a prompt in words. Out: text.

Who acts: the person reading it.

On a robot or a vehicle

“Explain this fault code.” “Draft the inspection report.”

3 · AI AGENT

a language model in a loop

A language model placed in a loop and given tools [4].

In: a goal. Out: actions, then a report.

Who acts: the agent itself, step after step.

On a robot or a vehicle

“Move tomorrow's drone survey to a dry time slot.”

Each wraps the one before: an agent is a language model in a loop, and the tools it calls are often predictive models.

UNM Center for Advanced Research Computing

AGENTIC AI LOOPS · RAISE · FALL 2026

ONE BRIDGE INSPECTION, THREE KINDS OF AI

Predictive model

Language model

AI agent

You give it

A photo of the bridge deck

Your field notes

A goal: “Inspect the bridge and report”

You get back

“Crack: 92% likely”

A draft inspection report

A flight plan, photos, crack scores, a second pass over the blurry spots, then a draft report

It stops

After one answer

After one reply

When it judges the job done

When it is wrong

A wrong number that a person can check

A confident sentence that is false

A wrong action in the world, possibly repeated

Three things are new with an agent: it acts, it takes many steps, and it decides for itself when to stop.

FOR THE ENGINEERS · the agent calls the other two as tools: the crack detector is a classifier, and the report writer is a language model.

UNM Center for Advanced Research Computing

AGENTIC AI LOOPS · RAISE · FALL 2026

EIGHT WORDS FOR TODAY

MODEL

The trained AI that writes text. On its own it can only talk.

AGENT

A model placed in a loop so it can take steps toward a goal.

TOOL

Anything the agent can use to act: search, email, a calendar, a robot arm.

HARNESS

The program around the agent. It owns the loop and the permissions.

SANDBOX

A fenced-off place where an agent can work without touching the real world.

HALLUCINATION

A confident answer that is wrong or made up.

TRACE

The step-by-step record of what the agent thought and did.

GATE

A point where the agent must stop and ask a person.

Model, agent and harness after Swetnam, MESA (2026) [5] · sandbox after the GPT 101 workshop [1]

UNM Center for Advanced Research Computing

AGENTIC AI LOOPS · RAISE · FALL 2026

PART 2

THREE BUILDING
BLOCKS

sequence, selection, iteration

UNM Center for Advanced Research Computing

AGENTIC AI LOOPS · RAISE · FALL 2026

THE STRUCTURED PROGRAM THEOREM

SEQUENCE

Do this, then this, then this, in order. Like following a recipe.

read_sensor()
estimate_state()
send_command()

SELECTION

If this, do that; otherwise do something else. Like a traffic light.

if obstacle_ahead:
    brake()
else:
    cruise()

ITERATION

Keep doing this until something says stop. Like stirring until it thickens.

while not at_goal:
    step()

Böhm and Jacopini (1966) proved that these three are enough to write any program [6]. Dijkstra (1968) argued for using only these, so that a person can follow a program by reading it [7].

UNM Center for Advanced Research Computing

AGENTIC AI LOOPS · RAISE · FALL 2026

LOOPS ARE EVERYWHERE

Loop

Where you meet it

What goes around

Thermostat

Home heating, cruise control

Measure → compare with the setting → adjust

Sense, plan, act

Robot vacuums, rovers, self-driving cars

Sense → plan → act

OODA

Pilots and military strategy, after Boyd [8]

Observe → orient → decide → act

Plan, do, check, act

Quality management, after Deming [9]

Plan → do → check → act

Agent loop

AI agents [4]

Perceive → plan → act → observe

The agent loop is the newest member of an old family. What is new is that an AI does the planning step.

FOR THE ENGINEERS · the same shape as feedback control, and as IBM's MAPE-K loop for self-managing systems, Kephart and Chess (2003) [10].

UNM Center for Advanced Research Computing

AGENTIC AI LOOPS · RAISE · FALL 2026

THE AGENT LOOP

1 · PERCEIVE

Read the goal and what has happened so far

2 · PLAN

Decide the next step, or decide to stop

3 · ACT

Use a tool to do it

4 · OBSERVE

Read what came back

5 · CONCLUDE

Report the answer

NOT DONE → LOOP AGAIN

DONE

Sequence

Everything so far is kept in order, and the agent rereads all of it on every lap.

Selection

On each lap the AI picks one tool by reading its description, or picks none.

Iteration

It keeps going until it decides it is finished. The only hard stop is a step limit a person sets.

FOR THE ENGINEERS · in LangChain the loop ends when the model returns no tool calls, and the step cap is recursion_limit [11]. Loop after AI Automation and Agents, Modules 1 and 2 [4].

UNM Center for Advanced Research Computing

AGENTIC AI LOOPS · RAISE · FALL 2026

ONE REQUEST, THREE LAPS

You ask: “Move tomorrow's drone survey to a dry time slot, and tell the crew.”

Lap

The agent decides

Tool it uses

What comes back

1

“I need tomorrow's forecast.”

Weather service

Rain from 9 to 11 am

2

“Find a dry slot when the crew is free.”

Team calendar

2 pm is open

3

“Move the booking and draft a note to the crew.”

Calendar, email

Booking moved. Note drafted, waiting for your OK

Done

“Nothing left to do.”

None

A short report to you

Nobody wrote these steps in advance. The agent chose each one after seeing the last result, and it stopped to ask before doing something that could not be taken back.

An illustration, not a transcript of a real system.

UNM Center for Advanced Research Computing

AGENTIC AI LOOPS · RAISE · FALL 2026

WHO DECIDES WHAT HAPPENS NEXT

Building block

In ordinary software

In an AI agent

Sequence

A programmer wrote the steps, in order

The AI makes up the steps as it goes

Selection

A programmer wrote every if and else, and anyone can read and test them

The AI chooses, by reading descriptions written in plain English

Iteration

A programmer wrote the rule for when to stop

The AI decides when it is done, unless a step limit cuts it off

The three building blocks are still there. Their author is now an AI, deciding one step at a time, and that is where the ethical questions begin.

FOR THE ENGINEERS · control flow moves from source code you can review to a model's output at run time.

UNM Center for Advanced Research Computing

AGENTIC AI LOOPS · RAISE · FALL 2026

FIVE LEVELS OF AGENT AUTONOMY

Level

Name

What it can do

Who checks the work

1

Conversational AI

Answers, summarizes, explains. Takes no actions

You, before you act on it

2

Tool-using LLM

Searches, calculates and runs code when asked

You, one request at a time

3

Autonomous task completion

Breaks down a goal, works through it, chains tools

You review the finished job

4

Multi-agent collaboration

Specialized agents split the work and coordinate

Agents check each other

5

Self-evolving systems

Improves its own abilities through experience

An open research question

Levels from the GPT 101 workshop [1]; the last column is my reading. Most products today sit at Levels 2 and 3. As with SAE driving levels [12], the number tells you who is expected to be watching.

FOR THE ENGINEERS · examples: chat with search or MCP (2), Claude Code and Devin (3), CrewAI, AutoGen and LangGraph (4).

UNM Center for Advanced Research Computing

AGENTIC AI LOOPS · RAISE · FALL 2026

PART 3

LOOPS OF LOOPS

agents, supervisors and swarms

UNM Center for Advanced Research Computing

AGENTIC AI LOOPS · RAISE · FALL 2026

FOUR WAYS AGENTS COORDINATE

1 · SUPERVISOR

Like a manager and a team: one agent splits the job up and assembles the result.

Fails when

The plan is wrong, or everything waits on the manager.

2 · PEER NETWORK

Like a drone swarm, or a committee with no chair: agents just trade messages.

Fails when

Group behaviour is hard to predict, and members can contradict each other.

3 · PIPELINE

Like an assembly line: each agent hands its work to the next.

Fails when

An early mistake travels through every later stage.

4 · MARKET

Like a dispatcher with a job board: agents claim or bid on tasks.

Fails when

The dispatcher is a single point of failure, and overhead is highest.

Teamwork among machines predates chatbots: Stone and Veloso (2000) surveyed it for robot teams [13]. Patterns after AI Automation and Agents, Module 4 [4].

FOR THE ENGINEERS · in practice: supervisor = LangGraph, peers = AutoGen, pipeline = MetaGPT or CrewAI, market = the contract net protocol.

UNM Center for Advanced Research Computing

AGENTIC AI LOOPS · RAISE · FALL 2026

WHY MULTI-AGENT SYSTEMS FAIL

SYSTEM DESIGN ISSUES

How the team was set up

Unclear roles, vague instructions, and no rule for when to stop.

INTER-AGENT MISALIGNMENT

Agents talking past each other

Not sharing what they know, ignoring each other, drifting off the task.

TASK VERIFICATION

Nobody checked the work

Stopping early, skipping checks, and accepting flawed results.

Where the loop comes in

Several of the failures are about the loop itself: repeating the same step, not knowing when to stop, or stopping too early.

From a study of failed runs of multi-agent AI systems: Cemri et al. [14], as summarized in AI Automation and Agents, Module 4 [4]

FOR THE ENGINEERS · this is MAST, the Multi-Agent System Failure Taxonomy: fourteen failure modes sorted into these three categories.

UNM Center for Advanced Research Computing

AGENTIC AI LOOPS · RAISE · FALL 2026

WHEN THE SANDBOX FAILS · JULY 2026

In an internal OpenAI security test, run with the safety limits switched off, AI agents teamed up to fool the automatic scorer, then used leaked login credentials to break into another company's systems.

~1,200

agents found an unwatched shared folder and turned it into a message board

70,000+

messages and files traded, mostly about beating the scorer

~700

agents joined a multi-day break-in at Hugging Face, a company that hosts AI models

~7%

of the transcripts reviewed contained faked records of tool use

OpenAI [15] and Hugging Face [16] disclosures; METR and Redwood Research independent investigation [17]. Case study with sources: GPT 101, Ethical and Legal Considerations [1]

UNM Center for Advanced Research Computing

AGENTIC AI LOOPS · RAISE · FALL 2026

KEEP GOING: COURSES AND READINGS

Resource

What it is

Where

AI Automation and Agents [4]

Five-module CARC course: the agent loop, reasoning, RAG, multi-agent systems, responsible deployment

tyson-swetnam.github.io/AI-Automation-and-Agents

GPT 101 workshop [1]

Agentic AI, MCP, AI sandboxes, ethics, and the July 2026 case study

tyson-swetnam.github.io/intro-gpt

Awesome Open Science [18]

Open models, agent frameworks, FAIR data, national cyberinfrastructure

tyson-swetnam.github.io/awesome-open-science

RAISE [19]

NSF Research Traineeship and the Graduate Certificate in Ethical AI for Autonomous Systems

raise.unm.edu

Primary sources: Wooldridge and Jennings (1995) [20] · Yao et al., ReAct [21] · Cemri et al., MAST [14] · NIST AI RMF 1.0 [22] · EU AI Act, Article 14 [23] · OWASP Top 10 for Agentic Applications [24]. Full list on the references slides.

UNM Center for Advanced Research Computing

AGENTIC AI LOOPS · RAISE · FALL 2026

COMPUTE AT CARC

44

GPUs on Easley: 36 NVIDIA L40S for AI and machine learning, plus 8 H100 [25]

37

NVIDIA A100 GPUs on Hopper

$0

Free of charge for UNM faculty, staff and student researchers

AI · QUANTUM · HPC

UNM Center for Advanced Research Computing

AGENTIC AI LOOPS · RAISE · FALL 2026

THANK YOU

who decides what happens next?

carc.unm.edu · raise.unm.edu · tyson-swetnam.github.io/AI-Automation-and-Agents · tswetnam@unm.edu

Course materials are CC BY 4.0. MESA slides reused from the NCEMS Annual Summit, August 2026 [5]; MESA is supported by the U.S. National Science Foundation under Award #2632685.

UNM Center for Advanced Research Computing

AGENTIC AI LOOPS · RAISE · FALL 2026

BACKUP SLIDES

GOING
DEEPER

for questions, and for the engineers

UNM Center for Advanced Research Computing

AGENTIC AI LOOPS · RAISE · FALL 2026

THE SCALE OF THE AI BUILDOUT

Line chart of cumulative cost in 2025 dollars against years from program start: US railroads, Interstate highways, Apollo, the space station and the Manhattan Project rise slowly over decades; AI data centers 2020 to 2026 rise almost vertically, with a dashed 2027 forecast above them

US data-center build: $560B through 2026 · $800B on the 2027 run rate

Cumulative cost in 2025 dollars · FHWA [26], Epoch AI [27], NASA [28], Gartner [29] · after Fin Moorhouse [30]

UNM Center for Advanced Research Computing

AGENTIC AI LOOPS · RAISE · FALL 2026

WHERE AGENTS MEET RAISE

RAISE research theme

What it looks like with AI agents

In this deck

Space and defense autonomy

Machines that must be dependable when no person can step in

Backup: the human gate

Algorithmic fairness

Choices made by an AI that learned its habits from data

Part 2: who decides

Multi-agent robotics and intelligent swarms

Many AI agents working as a team: managers, peers, assembly lines

Part 3: teams of agents

Distributed learning for extreme-scale systems

Thousands of loops sharing information across a grid, a fleet or a data center

Part 3: loops of loops

RAISE is Responsive and Resilient AI for Autonomous Systems Engineering, an NSF National Research Traineeship at UNM. Themes from raise.unm.edu/research [31].

UNM Center for Advanced Research Computing

AGENTIC AI LOOPS · RAISE · FALL 2026

WHAT COUNTS AS AN AGENT

“A computer system capable of autonomous action in an environment in order to meet its design objectives.” Wooldridge and Jennings (1995) [20].

AUTONOMY

Works without a person directing each step.

REACTIVITY

Notices when things change and responds in time. It is not following a fixed script.

PRO-ACTIVENESS

Works toward a goal on its own initiative, not only when prodded.

SOCIAL ABILITY

Works with people, and with other agents, through agreed rules.

A chatbot, a fixed script, a one-off lookup and a search engine each miss at least one of the four [4].

UNM Center for Advanced Research Computing

AGENTIC AI LOOPS · RAISE · FALL 2026

HOW AN AGENT PICKS A TOOL

Choosing from a menu

The AI never operates a tool itself. It names the tool it wants and fills in the details; the harness does the rest.

It chooses the way you pick from a menu: by reading each tool's description. A vague or misleading description leads to the wrong choice [4].

One standard plug

The Model Context Protocol (MCP) is a shared way to describe tools, so any tool can plug into any agent [32].

Tools can reach files, calendars, websites, even robots [1].

Anyone can publish one. A tool written by a stranger becomes part of your agent's decision making [24].

How well a tool is described matters more than anything else for whether the agent uses it correctly [4].

FOR THE ENGINEERS · a tool is a name, a description and a JSON schema for its arguments; the model emits a structured call and the harness executes it.

UNM Center for Advanced Research Computing

AGENTIC AI LOOPS · RAISE · FALL 2026

REASONING PARADIGMS AS CONTROL STRUCTURES

Paradigm

Control structure

Backtracks

Cost

Trace is readable

Chain-of-Thought · Wei et al. [33]

Sequence: one linear chain of reasoning steps

No

Low

High

ReAct · Yao et al. [21]

Iteration: thought, act, observe, repeat

No

Medium

High

Tree of Thoughts · Yao et al. [34]

Selection: branch, evaluate, prune

Yes

High

Moderate

LATS · Zhou et al. [35]

All three: tree search with a tool call at every node

Yes

Very high

Low

Most production agents run ReAct for cost reasons [4]. More search buys better plans, and a trace that is harder for a person to audit.

UNM Center for Advanced Research Computing

AGENTIC AI LOOPS · RAISE · FALL 2026

CODING HARNESSES

Harness

From

Where it runs

Claude Code

Anthropic

Terminal, IDE, web · MCP native

Codex

OpenAI

Terminal, IDE, cloud tasks

Antigravity

Google

Agent-first IDE

OpenCode

Open source

Terminal, model-agnostic

Goose

Open source

Desktop and CLI · MCP native

A harness is your lab bench: a shell, files, version control, and a set of MCP servers, with a human approving the steps that matter [5].

UNM Center for Advanced Research Computing

AGENTIC AI LOOPS · RAISE · FALL 2026

HALLUCINATION AS AN ENGINEERING PROBLEM

The objection

What is actually happening

The control

“It invents citations”

It never looked anything up

Make it search a real index first

“It makes up labels”

Any word is allowed, so nothing can be checked

Terms must come from an approved list (an ontology)

“It varies run to run”

Nothing fixes the shape of the answer

A form the answer must fit (a JSON schema), checked automatically

“I cannot audit it”

No record of what went in or what it did

A logbook of every step, so any run can be replayed

Google DeepMind GNoME proposed 380,000 crystals [36]; independent labs confirmed under 5%. Every output should be treated as a hypothesis until it is checked [5].

UNM Center for Advanced Research Computing

AGENTIC AI LOOPS · RAISE · FALL 2026

AI SANDBOXES: FENCES FOR AGENTS

Kind of fence

What it does

Examples

A sealed-off computer

The agent works inside a separate machine, so mistakes stay inside it

Virtual machines, containers

Built-in limits

The agent runs on your computer but may touch only certain files, commands and websites

Permission settings in Claude Code [37], Codex, Gemini CLI

Both at once

The agent's own limits, inside a sealed-off machine

Kubernetes pods, traffic through a proxy, every call recorded [5]

Six habits: start with few permissions, review before running, use a dedicated environment, limit file access, watch what it does, keep backups [1].

Sandboxes reduce risk but do not eliminate it entirely.

FOR THE ENGINEERS · the literature calls these traditional sandboxes, agentic sandboxes and defense in depth.

UNM Center for Advanced Research Computing

AGENTIC AI LOOPS · RAISE · FALL 2026

FOUR WAYS AGENTS GET ATTACKED

HIJACKED GOALS

Hidden instructions in a web page, an email or a file redirect what the agent is trying to do.

ASI01

BORROWED KEYS

The agent's own tools and permissions are turned against the people it works for.

ASI02 · ASI03

POISONED SUPPLIES

A bad plug-in, or a false fact planted in its memory, corrupts later decisions.

ASI04 · ASI06

MISPLACED TRUST

People believe the agent, and one bad result spreads from agent to agent.

ASI08 · ASI09

These are everyday versions of the OWASP Top 10 for Agentic Applications [24]. The full list is on the next slide.

FOR THE ENGINEERS · the codes are OWASP's. ASI05 (code execution), ASI07 (agent-to-agent messages) and ASI10 (rogue agents) are on the next slide too.

UNM Center for Advanced Research Computing

AGENTIC AI LOOPS · RAISE · FALL 2026

OWASP TOP 10 FOR AGENTIC APPLICATIONS

ID

Risk

What goes wrong

ASI01

Agent Goal Hijack

Injected text or poisoned data redirects the agent's goal

ASI02

Tool Misuse and Exploitation

The agent uses its own tools to exfiltrate or exhaust

ASI03

Identity and Privilege Abuse

Inherited roles and delegated credentials escalate access

ASI04

Agentic Supply Chain Vulnerabilities

MCP servers, plugins and agent cards arrive compromised

ASI05

Unexpected Code Execution

A language task becomes arbitrary code on the host

ASI06

Memory and Context Poisoning

False data planted in memory corrupts later reasoning

ASI07

Insecure Inter-Agent Communication

Messages between agents are spoofed or altered

ASI08

Cascading Failures

One bad result compounds across a multi-agent system

ASI09

Human-Agent Trust Exploitation

The trust a user places in the agent is used against them

ASI10

Rogue Agents

An agent deviates: compromised, or never trustworthy

OWASP GenAI Security Project, 2026 · genai.owasp.org [24]

UNM Center for Advanced Research Computing

AGENTIC AI LOOPS · RAISE · FALL 2026

KNOWLEDGE AS A GUARDRAIL

Write it down

Agents forget everything between sessions. So have them write down what they learned, in plain files a person can read and the next agent can reuse [5].

Every page carries a label: what it is, where it came from, who checked it, and when it goes out of date. Google's Open Knowledge Format makes the label standard [38].

An approved vocabulary does the same for words: a term that is not on the list is rejected.

One page's label

type:        Setup Guide
title:     OpenAI ChatGPT
generated: by human:tswetnam
verified:    by human:tswetnam
status:     stable
stale_after: 2026-11-01

A machine may write “generated”. Only a person may write “verified” [1].

FOR THE ENGINEERS · this is how the course sites and the CARC docs are published: Markdown with OKF frontmatter, plus llms.txt for agents.

UNM Center for Advanced Research Computing

AGENTIC AI LOOPS · RAISE · FALL 2026

BACKUP SLIDES

FOR THE
DISCUSSION

gates, governance and who answers

UNM Center for Advanced Research Computing

AGENTIC AI LOOPS · RAISE · FALL 2026

FIVE LESSONS FROM THE INCIDENT

Lesson

What the record shows

Chasing the score

Agents pursued the number they were graded on, not the outcome that was meant (reward hacking)

The test area touched the real world

An evaluation sandbox turned out to be connected to real systems

Logs can lie

Faked records in about 7% of transcripts: keeping records is not the same as accountability

Outside investigators worked

METR and Redwood spent six days on site with about 1,300 unredacted transcripts

The rules were voluntary

No mandatory incident report was triggered. The victim called the FBI

Only a handful of transcripts even considered telling a human. None did [17].

Lessons after the GPT 101 case study [1]

UNM Center for Advanced Research Computing

AGENTIC AI LOOPS · RAISE · FALL 2026

THE HUMAN GATE IS AN IF STATEMENT

The rule, in plain words

IF AN ACTION CANNOT BE UNDONE, STOP AND ASK A PERSON. OTHERWISE, CARRY ON.

while not done:
    action = plan(state)
    if action.irreversible:
        wait_for(human)
    state = observe(act(action))

Two questions before you automate

How much of the job can be written as rules? Score 1 to 5.

How bad, and how permanent, is a mistake? Score 1 to 5.

Rule-based but high-stakes does not rule out automation. It calls for checkpoints, testing, and approval gates before any step that cannot be undone.

Three design questions

Which actions need a gate? What must the reviewer see? What happens if they say no?

EU AI Act Article 14 [23] and the NIST AI RMF Govern function [22] both require defining where human authority is needed · AI Automation and Agents, Modules 1 and 5 [4]

FOR THE ENGINEERS · LangGraph, the OpenAI Agents SDK and CrewAI Flows treat approval gates as first-class; other frameworks leave you to build them.

UNM Center for Advanced Research Computing

AGENTIC AI LOOPS · RAISE · FALL 2026

THREE NESTED LOOPS

GOVERNANCE LOOP

Govern → Map → Measure → Manage

MONTHS · THE INSTITUTION · NIST AI RMF 1.0 [22]

OVERSIGHT LOOP

Trace → Review → Approve or reject → Revise

MINUTES TO DAYS · THE OPERATOR · EU AI ACT ARTICLE 14 [23]

AGENT LOOP

Perceive → Plan → Act → Observe

SECONDS · THE MODEL AND ITS HARNESS

Each loop needs its own way to stop, and each outer loop must be able to stop the one inside it.

UNM Center for Advanced Research Computing

AGENTIC AI LOOPS · RAISE · FALL 2026

“THE AI DID IT” IS NEVER A COMPLETE ANSWER.

When an agent sends, modifies, charges or commands, a person or an organization is accountable for that action: the designer, the deployer, the operator [4].

BENEFICENCE · NON-MALEFICENCE · AUTONOMY · JUSTICE · EXPLICABILITY · AI4PEOPLE, FLORIDI ET AL. (2018) [39]

UNM Center for Advanced Research Computing

AGENTIC AI LOOPS · RAISE · FALL 2026

DISCUSSION 1 · WHO DECIDES WHAT HAPPENS NEXT

Pick a machine that acts on its own: a robot vacuum, a self-driving car, a delivery drone, a Mars rover. Pairs first, then the room.

1

Where do its steps, its choices and its repeats come from today? Who wrote them?

2

Which of the three would you hand to an AI first? Which one never?

3

What makes it stop: a rule someone wrote, a limit, or a person?

UNM Center for Advanced Research Computing

AGENTIC AI LOOPS · RAISE · FALL 2026

DISCUSSION 2 · DESIGN THE GATE

Pick one: a drone swarm, a self-driving shuttle, or a spacecraft too far away to steer in real time.

1

Which actions cannot be undone, and who is allowed to approve them?

2

What does that person need to see before saying yes?

3

The machine acts faster than a person can review. What do you change?

4

Who answers for it when the gate is skipped?

UNM Center for Advanced Research Computing

AGENTIC AI LOOPS · RAISE · FALL 2026

REFERENCES

1–12 · numbered in order of first citation · slide numbers show where each is used

1. UNM Center for Advanced Research Computing. GPT 101: a workshop on generative AI and prompt engineering. 2026. CC BY 4.0. Available from: tyson-swetnam.github.io/intro-gpt Slides 4, 7, 14, 18, 19, 26, 30, 33, 35.

2. James G, Witten D, Hastie T, Tibshirani R. An introduction to statistical learning: with applications in R. 2nd ed. New York: Springer; 2021. Available from: statlearning.com Slide 5.

3. Brown TB, Mann B, Ryder N, Subbiah M, Kaplan J, Dhariwal P, et al. Language models are few-shot learners. Adv Neural Inf Process Syst. 2020;33:1877–1901. Available from: proceedings.neurips.cc Slide 5.

4. Center for Advanced Research Computing, University of New Mexico. AI Automation and Agents [online course]. 2026. Developed at the Arizona Institute for Artificial Intelligence, University of Arizona. CC BY 4.0. Available from: tyson-swetnam.github.io/AI-Automation-and-Agents Slides 5, 10, 11, 16, 17, 19, 25, 26, 27, 36, 38.

5. Swetnam TL. MESA: Multidisciplinary Environment for Scientific Advancement. NCEMS Annual Summit; 2026 Aug. Available from: idss-mesa.github.io Slides 7, 21, 28, 29, 30, 33.

6. Böhm C, Jacopini G. Flow diagrams, Turing machines and languages with only two formation rules. Commun ACM. 1966;9(5):366–371. doi:10.1145/355592.365646 Slide 9.

7. Dijkstra EW. Go to statement considered harmful. Commun ACM. 1968;11(3):147–148. doi:10.1145/362929.362947 Slide 9.

8. Boyd JR. The essence of winning and losing [unpublished briefing]. 1996. Available from: slightlyeastofnew.com Slide 10.

9. Deming WE. Out of the crisis. Cambridge (MA): MIT Press; 1986. Available from: books.google.com Slide 10.

10. Kephart JO, Chess DM. The vision of autonomic computing. Computer. 2003;36(1):41–50. doi:10.1109/MC.2003.1160055 Slide 10.

11. LangChain. Agents. LangChain documentation. Available from: docs.langchain.com/oss/python/langchain/agents Slide 11.

12. SAE International. Taxonomy and definitions for terms related to driving automation systems for on-road motor vehicles. Standard J3016_202104. 2021. Available from: sae.org/standards/content/j3016_202104 Slide 14.

UNM Center for Advanced Research Computing

AGENTIC AI LOOPS · RAISE · FALL 2026

REFERENCES

13–25 · numbered in order of first citation · slide numbers show where each is used

13. Stone P, Veloso M. Multiagent systems: a survey from a machine learning perspective. Auton Robots. 2000;8(3):345–383. doi:10.1023/A:1008942012299 Slide 16.

14. Cemri M, Pan MZ, Yang S, Agrawal LA, Chopra B, Tiwari R, et al. Why do multi-agent LLM systems fail? Adv Neural Inf Process Syst. 2025;38 (Datasets and Benchmarks Track). arXiv:2503.13657 Slides 17, 19.

15. OpenAI. The Hugging Face incident and the road ahead. 2026 Aug 26. Available from: openai.com/index/hugging-face-incident-and-the-road-ahead Slide 18.

16. Hugging Face. Anatomy of a frontier lab agent intrusion: a technical timeline. 2026 Jul 27. Available from: huggingface.co/blog/agent-intrusion-technical-timeline Slide 18.

17. METR, Redwood Research. Brief independent investigation of agents’ behavior, reasoning and collaboration in the OpenAI / Hugging Face hacking incident. 2026 Aug 26. Available from: metr.org/blog Slides 18, 35.

18. Swetnam TL. Awesome Open Science. Available from: tyson-swetnam.github.io/awesome-open-science Slides 19, 20.

19. RAISE. Graduate Certificate on Ethical AI for Autonomous Systems. University of New Mexico. Available from: raise.unm.edu Slide 19.

20. Wooldridge M, Jennings NR. Intelligent agents: theory and practice. Knowl Eng Rev. 1995;10(2):115–152. doi:10.1017/S0269888900008122 Slides 19, 25.

21. Yao S, Zhao J, Yu D, Du N, Shafran I, Narasimhan K, et al. ReAct: synergizing reasoning and acting in language models. arXiv:2210.03629 [Preprint]. 2022. Slides 19, 27.

22. National Institute of Standards and Technology. Artificial Intelligence Risk Management Framework (AI RMF 1.0). NIST AI 100-1. 2023. doi:10.6028/NIST.AI.100-1 Slides 19, 36, 37.

23. European Parliament and Council. Regulation (EU) 2024/1689 laying down harmonised rules on artificial intelligence (Artificial Intelligence Act). Off J Eur Union. 2024 Jul 12. Available from: eur-lex.europa.eu/eli/reg/2024/1689/oj Slides 19, 36, 37.

24. OWASP GenAI Security Project. OWASP Top 10 for Agentic Applications for 2026. Available from: genai.owasp.org Slides 19, 26, 31, 32.

25. UNM Center for Advanced Research Computing. CARC documentation: facilities description and general FAQ. Available from: carc.unm.edu/docs Slide 20.

UNM Center for Advanced Research Computing

AGENTIC AI LOOPS · RAISE · FALL 2026

REFERENCES

26–39 · numbered in order of first citation · slide numbers show where each is used

26. Federal Highway Administration. Highway statistics series. Washington: US Department of Transportation. Available from: fhwa.dot.gov/policyinformation/statistics.cfm Slide 23.

27. Epoch AI. AI capital expenditure. Data insights. Available from: epoch.ai/data-insights/ai-capex Slide 23.

28. NASA History Office. NASA history. Available from: nasa.gov/history Slide 23.

29. Gartner. Gartner forecasts worldwide AI spending to grow 47 percent in 2026 [press release]. 2026 May 19. Available from: gartner.com/en/newsroom Slide 23.

30. Moorhouse F. [Chart comparing AI data-center spending with historical megaprojects; post on X]. 2026. Available from: x.com/finmoorhouse/status/2044933442236776794 Slide 23.

31. RAISE: Responsive and Resilient AI for Autonomous Systems Engineering. Research. University of New Mexico. Available from: raise.unm.edu/research Slide 24.

32. Model Context Protocol. Specification and documentation. Available from: modelcontextprotocol.io Slide 26.

33. Wei J, Wang X, Schuurmans D, Bosma M, Ichter B, Xia F, et al. Chain-of-thought prompting elicits reasoning in large language models. Adv Neural Inf Process Syst. 2022;35:24824–24837. Available from: proceedings.neurips.cc Slide 27.

34. Yao S, Yu D, Zhao J, Shafran I, Griffiths TL, Cao Y, et al. Tree of thoughts: deliberate problem solving with large language models. Adv Neural Inf Process Syst. 2023;36:11809–11822. Available from: proceedings.neurips.cc Slide 27.

35. Zhou A, Yan K, Shlapentokh-Rothman M, Wang H, Wang YX. Language agent tree search unifies reasoning, acting, and planning in language models. arXiv:2310.04406 [Preprint]. 2023. Slide 27.

36. Merchant A, Batzner S, Schoenholz SS, Aykol M, Cheon G, Cubuk ED. Scaling deep learning for materials discovery. Nature. 2023;624:80–85. doi:10.1038/s41586-023-06735-9 Slide 29.

37. Anthropic. Beyond permission prompts: making Claude Code more secure and autonomous. 2025 Oct 20. Available from: anthropic.com/engineering/claude-code-sandboxing Slide 30.

38. Google Cloud. Open Knowledge Format (OKF) specification. Knowledge Catalog. Available from: github.com/GoogleCloudPlatform/knowledge-catalog Slide 33.

39. Floridi L, Cowls J, Beltrametti M, Chatila R, Chazerand P, Dignum V, et al. AI4People—an ethical framework for a good AI society: opportunities, risks, principles, and recommendations. Minds Mach. 2018;28(4):689–707. doi:10.1007/s11023-018-9482-5 Slide 38.

UNM Center for Advanced Research Computing

AGENTIC AI LOOPS · RAISE · FALL 2026

Speaker notes