Urgent.News

What's breaking now, across thousands of outlets.

AI

Beyond the Hype: How ‘AI Psychosis’ and the OpenAI Agents API Are Exposing the Fragility of Modern Software Engineering

Originally published on tamiz.pro . We have spent two decades obsessed with determinism. We write code that does the exact same thing every time it runs, provided the inputs are identical. We build type systems to eliminate ambiguity at compile time and unit tests to verify state transitions at runtime. Then came Large Language Models (LLMs)—engines of pure, beautiful probability—and we tried to…

For decades, software engineers have cherished determinism. Code executed identically each run given identical inputs. Type systems and unit tests eliminated ambiguity at compile time and runtime. Then came Large Language Models (LLMs), probabilistic engines that forced engineers to bend their rigid, deterministic structures. The emergent behavior of AI agents when given freedom to loop, self-correct, and interact with fragile modern infrastructure is termed "AI Psychosis."

The OpenAI Agents SDK is not just solving coding problems, but exposing the brittle nature of modern software engineering. The rise of stochastic actors with agentic frameworks highlights this fragility. Agents can call tools, observe outputs, replan based on those outputs, and pass context to other agents, creating volatile feedback loops.

In a deterministic system, feedback loops are controlled; in a stochastic system, they are unpredictable. LLMs, when they encounter unexpected errors, don't simply retry—they reason about why they failed. They might hallucinate parameters, misinterpret error messages, or enter reflexive loops that could lead to catastrophic system failures.

Modern software architecture, built on RESTful APIs and microservices, assumes idempotency. However, LLM agents do not respect idempotency; they respect conversational flow. When orchestrating a task, an agent might execute a tool and, due to its stochastic nature, could retry the tool or "correct" the state with hallucinated values. This exposes a fragility in observability layers, as our logging is designed for human reading, not for parsing the intent of a stochastic actor that changes its mind rapidly.

The OpenAI Agents API encourages defining tools with strict JSON schemas, but this only highlights the deeper issue of outsourcing logic to prompt engineering. Traditional software enforces compile-time checks for data types, while agentic software lacks these guardrails. When an agent's understanding of tool expectations diverges from the actual schema, it leads to "hallucinated tool" problems. The agent uses a hammer to fix a screw, then complains that the screwdriver is broken, causing catastrophic failures.

The hallucination of tool outputs is one of the most insidious forms of AI Psychosis. When models are trained to be helpful, they might invent plausible success responses when a tool fails. This is a minor error in a chatbot, but catastrophic when an agent has write-access to production systems. Our architecture blindly trusts API responses as the source of truth, while the stochastic interpretation layer introduces uncertainty.

Modern software engineering relies on modularity, but agents require large context windows for coherence, creating tension between modular architecture and holistic reasoning. As agents forget context or duplicate work, state management becomes fragile, lacking good patterns for managing agent memory.

Written by urgent.news from Dev.to's reporting — not their text. Machine-written — may contain errors; check the original before relying on it.

Read the original at dev.to →

More in AI

AI Boom to Boost Southeast Asia’s LNG Demand

Demand for liquefied natural gas (LNG) in Southeast Asia has found a new major driver apart from the years-long efforts to switch away from coal-fired power generation.

  • AI-driven data centers to triple in Southeast Asia by 2035
  • Power demand from hyperscalers to surge from 17 TWh to 57 TWh
  • Gas turbines may be most reliable option for consistent power

More from Friday 11 September →