r/AISystemsEngineering • • 9h ago

SRE agent: alert → AI investigation → human-reviewed fix MR on GitLab. How to orchestrate.

Thumbnail reddit.com
3 Upvotes

r/AISystemsEngineering • • 11h ago

Every agent is a new hire. Except mine.

Thumbnail
reddit.com
2 Upvotes

r/AISystemsEngineering • • 14h ago

The trust problem to sub-agents

Thumbnail reddit.com
1 Upvotes

r/AISystemsEngineering • • 17h ago

When a Record Has No Word for "Unknown", an Empty Value Will Say "Everything Is Fine"

0 Upvotes

Something happened recently that I want to start with.

We fixed a defect: four different kinds of "nothing" were collapsed into a single switch, so the readings couldn't tell "by design" from "broken". Then we moved on to the next thing. The day after that new field landed, a reader pointed at it in a comment, named the same defect again, and wrote down what to do about it.

This isn't the same bug coming back. It's the same class of bug growing back in the place where we thought we had learned it.

This piece is about one thing: when a record has no slot for "unknown", "unknown" reads as "known" — and specifically as the strongest statement that field can make.

1. Four kinds of "nothing", one switch

Background first.

When the AI writes a record, we keep a snapshot of what it looked like before and after. Revocation needs to know where to go back to.

The trouble was in "we couldn't capture the after-snapshot". There are at least four reasons that happens:

  • no captor was wired at all — an optional piece by design
  • the entity didn't resolve, and the fallback data was empty too
  • the entity resolved but the row is gone — an anomaly
  • the capture threw — an error

The first two are what the design chose. The last two are something went wrong.

We had one boolean field for all of it. Four reasons, one switch.

So when someone asked "why are these snapshots empty", there was no answer: you couldn't tell by design from broken. The worse part is the direction. That switch defaults to false, which reads as "the snapshot is fine".

"Nothing" is not one value, it is four different values. Collapsing them into one boolean lets the strongest reading answer for all of them.

We split it into four causes, each stored and readable on its own. While splitting it we also found that two of the four names we had first proposed didn't belong in that class at all. One lives on a different path (the table consulted before the write), and the other is a mechanism rather than a cause. So the four that landed are not the four we started with.

2. The next day, in the field we had just written

With that fixed, we moved to the next thing: before a revoke, record which members this attempt intends to compare.

The promise matters here. Before the revoke it's a promise; after it, an actual. Only the difference between them lets you say "a member I promised to compare turned out not to be comparable". The implementation put a column on the group's root row to hold that difference. If this attempt found no difference, the column is written empty.

That looked fine. Then someone wrote this in a comment:

A per-reason column sits on the member row and gets rewritten by whichever revoke attempt ran last, so a second attempt erases the first attempt's broken promise. Append-only keeps them apart.

He's right, and it's slightly worse than he put it.

When the attempt finds no difference, that column is written empty. And that empty means two things at once: "the last comparison found no difference", and "this row was never revoked at all". So:

  • the first revoke found "promised, but couldn't compare" — recorded
  • the second revoke went fine — and wrote over the first attempt's record with an empty value
  • reading that row later: empty. You can't tell "there was once a broken promise", and you can't tell "it was cleared"

A retry that succeeds erases the earlier attempt's failure record.

To be fair to ourselves: that clearing is deliberate. The reasoning is in the design record from when it landed — a stale difference shouldn't outlive the comparison that produced it. The reasoning isn't wrong. What's wrong is that the empty value had no second meaning available.

Then we changed it to what he described.

One row per attempt that reached the comparison, instead of one shared cell. The two readings are separated where they are written: this row is either "a difference was found" or "checked, and there was none". So:

  • a later attempt no longer erases an earlier one — it writes its own row
  • an empty history (no attempt ever reached the comparison) and "checked, clean" are no longer the same reading
  • the old rule — a stale difference shouldn't outlive the comparison that produced it — was withdrawn. It was wrong about using one cell for two things, not about keeping old records

The old column wasn't dropped. It's still read, as a legacy entry marked "written at a time we can't know". Deleting it would erase exactly the evidence this whole argument was about.

3. One place in the same system got it right

Both of the above are "no slot for unknown". But one place in the same system does have a slot.

When a revoke goes out to an external system, all we can do is send the request; the terminal state is on their side. Their 2xx only proves the request arrived, not that they undid anything. So that row doesn't write "revoked". It writes "compensation requested, outcome unknown" — a dedicated reading.

The effect is immediate: nobody misreads it as done. The interface says plainly that the result is with the target system. No gloss needed.

So this isn't impossible. It's a question of whether you noticed that "unknown" needed a slot. Give it one and it stays put. Don't, and it falls into the strongest reading available.

4. Why it's hard

It's hard because the default is silent.

Every field decides for you, and it always picks the cheapest reading:

  • a null value reads as "no such item"
  • an empty collection reads as "no difference"
  • false reads as "not marked", and from there as "fine"

Those readings are correct almost every time. The problem is the rest: when "nothing" and "unknown" share a value, you have a field that lies — and it stays quiet while doing it, until somebody acts on it and gets "everything is fine" on your behalf.

Worse: fixing one instance doesn't remove the class — including while fixing it.

Here's something that happened inside that fix. Once "no difference" had its own reading, there was still a function whose empty return meant two things: everything really was compared, and there was nothing to promise in the first place (with no captor wired, "compare" isn't defined). Writing "checked, clean" is right for the first. Writing it for the second would vouch for a check that never ran.

We nearly did. What we changed it to: nothing was promised, so no row is written.

That's why the entry points for this class are every "nothing" there is. Fix one, and it waits for you in the line of code where you write the fix.

5. A check you can run yourself

Don't start with "is my record complete". Start with something more basic:

List every value in your system that means "none / unknown / empty", and ask of each: what does it read as?

Anything that carries two meanings at once is a potential misreport. Three common shapes:

ShapeIt also means
a null value"no such item" / "looked, found none" / "never looked"
an empty collection"genuinely none" / "couldn't read it out"
false / a default"not marked" / "marked as no"

The test is simple: when this value is empty, can a reader still say why it's empty? If not, the field is guessing on their behalf.

Closing

This kind of problem is hard to find because it doesn't throw. The system runs, the interface renders, and one cell quietly says something untrue.

And the place it shows up most is the place you just fixed — because that's when you're busy already knowing how to do it.

Where we stand: we know the pattern now, and we've fixed two instances — the second one's shape came from the reader. We have not done a systematic pass: how many of those three shapes are in our record layer, and what each one reads as, is not a list we have.

So this one doesn't close on a conclusion. Run the check against your own system and you'll likely find a few. On our side, we only know we haven't finished looking.

Drafted with an AI assistant. The system, the positions and the mistakes are mine.


r/AISystemsEngineering • • 18h ago

AI Audit Evidence, Part 11: Written Down Is Not the Same as Enforced

Thumbnail
reddit.com
1 Upvotes

r/AISystemsEngineering • • 21h ago

Why running an AI agent test once is mathematically meaningless

1 Upvotes

If you test traditional software once and the assertion passes, it passes. If you test an AI agent once and it passes, you have learned almost nothing.

On a 1/1 green test run, the 95% Wilson confidence lower bound is just 20.7%. A workflow that fails 30% of the time in production still passes on the first try 7 times out of 10.

And in multi-step agents, a single "green" output often hides real production bugs:

  1. Two orders, one intent: A write tool times out on the client after the server already processed it. The agent sees no error, retries, and silently creates a duplicate order.
  2. 200 OK with an empty [] payload: A lookup tool swallows an upstream error and returns []. The agent treats "no error" as "done" and writes a confident answer built on nothing.
  3. Activity without progress: An agent loops through tool calls for hours without changing the actual goal state—every step counter says it's working while burning tokens.
  4. Silent reasoning exhaustion: A reasoning model burns its entire token budget thinking and returns empty text (finish_reason: "length"), looking like a provider outage.

When teams ship agents with tool calls, a single-run final-text check misses all four:

  • Blocker gates (write idempotency + read-back, explicit ok | empty | error | unknown tool statuses, Zod schemas) need 100% deterministic passes on every PR.
  • Capability gates need multi-run sampling (N ≥ 3 to 5) gated on the 95% Wilson lower bound, not a lucky 1/1 pass.

How is your team currently deciding whether an agent change is "good enough" to deploy?

Are you asserting on the tool trajectory and running multi-sample evals in CI, or still relying on local vibe checks?

Thanks in advance for any hints and best practices. Much appreciated.


r/AISystemsEngineering • • 1d ago

How would you test whether an AI learned the right lesson from a mistake?

Thumbnail reddit.com
1 Upvotes

I’m working on this question at Ontal, and the part I keep getting stuck on is that a system can fix its mistake for a surprisingly bad reason.
Say an AI books a piece of shared equipment because the calendar shows it’s free. It turns out there’s a maintenance hold on a separate list. Next time, it checks the list first and catches the hold. That looks promising. But “check every list every time” would get that one right too.
I’d like to start two copies of the system at the same point, let one experience the booking mistake, then give both a few unfamiliar cases. In one, the calendar leaves out holds. In another, the calendar already includes them. I’d want to see whether the earlier mistake helps the system figure out when that extra check is worth doing.
Someday I’d love to open-source a small version of this so other people can change the cases and try to break the test. If you could add one case that would expose a system using a shortcut, what would you put in it?


r/AISystemsEngineering • • 1d ago

Does explicitly preparing an AI coding agent's context before implementation improve its performance?

Thumbnail reddit.com
1 Upvotes

r/AISystemsEngineering • • 1d ago

I built a team of three AI agents and a second brain, for no other reason than I wanted to.

Post image
2 Upvotes

r/AISystemsEngineering • • 1d ago

AI in Healthcare Ops: Which Use Cases Survived Compliance Review?

2 Upvotes

I've been looking into how healthcare organizations are adopting AI automation, particularly for administrative workflows. One thing that stands out is that many AI ideas look promising during initial testing but become more complicated when they go through compliance and data security reviews.

For example, automating appointment scheduling, patient intake, document processing, and administrative reporting can save staff time. However, handling patient information introduces important questions around HIPAA compliance, data access, vendor security, and information sharing with third-party AI providers.

I think the use cases that work best are often those that reduce repetitive administrative tasks without giving AI unnecessary access to sensitive patient records.

A few questions for healthcare operations and IT professionals:

  1. Which healthcare AI automation use cases have successfully passed compliance reviews in your organization?
  2. How do you evaluate vendors when patient data is involved?
  3. Do you prefer private AI infrastructure or third-party AI platforms for administrative workflows?
  4. What security or compliance issues have caused an AI project to be delayed or rejected?

I'd be interested to hear about practical experiences, especially examples where an AI pilot successfully moved into production.


r/AISystemsEngineering • • 1d ago

Iceberg Fine-Grained Access Control for AI Agents

Thumbnail
lakeops.dev
2 Upvotes

r/AISystemsEngineering • • 1d ago

Iceberg Lakehouse for Agentic AI

Thumbnail
lakeops.dev
1 Upvotes

r/AISystemsEngineering • • 1d ago

Is this AI Engineer take-home assignment excessive, or is this the industry standard?

Thumbnail reddit.com
1 Upvotes

r/AISystemsEngineering • • 1d ago

Do you get overwhelmed when you work on a solution using AI?

Thumbnail reddit.com
2 Upvotes

r/AISystemsEngineering • • 2d ago

Confidence Scoring for Agents

Thumbnail reddit.com
0 Upvotes

r/AISystemsEngineering • • 2d ago

Should finding the right inspection report be enough to lift a HOLD?

Post image
1 Upvotes

r/AISystemsEngineering • • 2d ago

Why Did Your AI Pilot Stall Before Production? Scaling Lessons

1 Upvotes

I've noticed that many businesses can successfully build an AI proof of concept, but moving that solution into production is a completely different challenge.

A pilot might work well with a limited dataset and a small group of users. However, problems often appear when the same AI solution needs to handle real business data, multiple integrations, security requirements, and larger workloads.

There are several reasons why pilots stall before production, especially when businesses try to scale AI across different departments.

Some common challenges include:

  • Data Security: Businesses are concerned about sending confidential information to external AI services.
  • Poor Data Quality: Information is scattered across databases, documents, spreadsheets, and internal applications.
  • Integration Challenges: Connecting AI tools with existing CRM, ERP, and business workflows can be difficult.
  • Governance Gaps: Teams lack clear rules for permissions, monitoring, audit trails, and human approvals.
  • Unclear ROI: Organizations struggle to measure whether AI is actually reducing costs or improving productivity.

I think enterprise AI scaling requires more than selecting a powerful AI model. Businesses also need a secure data architecture, clear governance policies, continuous monitoring, and a practical operating model.

For companies implementing agentic AI, choosing the right governance approach is equally important. Different industries have different requirements for data privacy, regulatory compliance, access management, and human oversight.

I'm curious about your experiences:

  1. What was the biggest challenge when moving an AI pilot into production?
  2. How do you protect sensitive business data when using AI agents?
  3. Do you use an internal governance framework or a third-party platform?
  4. What helped your organization scale AI successfully?

Would love to hear practical experiences, lessons learned, and approaches that worked in real business environments.


r/AISystemsEngineering • • 2d ago

Putting an AI agent into a real business workflow is mostly a software engineering problem

Thumbnail reddit.com
1 Upvotes

r/AISystemsEngineering • • 2d ago

How can I run AI agents 24/7 in the cloud without keeping my laptop switched on?

Thumbnail reddit.com
0 Upvotes

r/AISystemsEngineering • • 2d ago

AI Audit Evidence, Part 10: One Sweep, Two Initiators

1 Upvotes

We build a runtime that lets AI agents take real write actions inside enterprise systems: create a record, send a call to another service. Every action carries permissions, approvals, and a record someone can review afterwards.

The last three pieces were about what a record answers: a status is not a receipt, an interval is not coverage, one word can stand for two pasts. This one is about a single column in the export — the one headed "Initiated by". A record can be complete about what happened and still name the wrong person as having done it.

1. A reader fixed the vanishing; the author is still wrong

A reader described their own system:

when an agent gave up waiting for a person's approval, the call simply vanished from the record, so "never asked" and "asked, but no answer" looked the same. Now every attempt gets its own entry, including the ones that never ran.

The fix is right, and it is our shape too: a call whose wait ran out still happened — to the person waiting for it — so it needs a row. Once it has one, "nobody asked" and "asked, no answer" are two facts instead of one blank.

Our answer said: yes, every expiry is written as its own chained row. That settled whether the row exists. It did not settle who the row is signed by — and that is the part we filled in wrong.

2. One sweep, two rows, two authors

When a confirmation request gets no decision inside its offline window (24 hours by default, configurable), an hourly sweep flips it to timeout and writes one audit row per expiry (confirmation.store.ts:507-545 flips each row by its own conditional update and returns the rows it actually flipped; maintenance-tasks.service.ts:123-130 calls it).

The row is written like this (maintenance-tasks.service.ts:141-147):

userId = the operator — the person who made the original call;
username = a snapshot of that person's name;
no agentId (a scheduled task has no request-scoped actor to inherit one from);
authorization, arguments and basis are carried; the authorization cell reads "window expired without a decision".
Another automatic action in the same system is written differently. When a hold is released because the target itself answered, the sweep records userId as system:sweep (write-claim-decision.service.ts:297-300), with the original writer named in detail — "who initiated" and "as whom" are two fields on that path.

The export's "Initiated by" column is derived from three fields only (audit-export-vocabulary.ts:268-281): a row with a name is labelled by whether the action is human-only; a row with no name whose id sits in the system: namespace is labelled "Automated".

One hourly sweep on the left. Row A, a claim_release: userId = system:sweep, no name, no agent — the export prints "Automated". Row B, a tool_confirmation flipped to timeout: userId = alice, username = Alice, no agent — the export prints "Alice (through the AI assistant)". Footer: same cron, same minute; the result column is right on both rows, the initiator column is right on one.

Figure 25 - One sweep, two initiators

So in one sweep, in the same minute, the export shows two rows:

  • the release row — initiated by Automated;
  • the expiry row — initiated by Alice (through the AI assistant). Alice had not opened the approval centre that day.

3. The result column is right; the initiator column is not

The expiry row's authorization cell is honest: "window expired without a decision" (audit-export-vocabulary.ts:231-233). The author cell is not: it assigns an act performed by the scheduler to the person who never responded.

A concrete case. The process dies inside the in-stream wait; Alice closes her laptop and never opens the pending list again. A day later the sweep closes the request and writes the row. Alice's own trail now contains an action she never took; any view that filters or counts by initiator has it under her name.

A reader who reads the authorization column knows the truth. A reader who reads only the initiator column — or counts by it — does not.

4. Why the column cannot simply be fixed

The direct fix is to write system:sweep into the expiry row, matching the release path. But userId carries a second job on the same table: scope. A non-admin reader sees only rows where userId is their own (audit-reader-scope.ts:93-110). Recording the sweep there would make the row honest about its author and silent to the person it is about — the expiry would leave Alice's own trail.

So the row needs to hold two facts at once: who initiated it, and whose business it is. The release path already does this. The confirmation path was written earlier, when there was one field, and the field was filled with the person.

Neither fix exists yet: add an initiator field to the audit row and have the export prefer it, keeping userId as "who this is about"; or follow the release path's shape, with the subject carried beside the initiator. Which one is secondary is a question for whoever acts on that column alone.

5. The gap

Today the audit row has no initiator field. The export infers authorship from three fields that all describe the person, and the inference rule is not wrong — for an approve or decline row it is right. For an expiry row it signs a non-act to a person.

That is the gap: field, migration, write path, export and console are all still to do. This piece records the current state, not a plan.

The question

When a request nobody answered is closed by a sweep, who should the record sign?

Is "Automated" enough for the initiator column — or should an automatically closed action have no initiator at all, with the person it is about given a column of their own, whose name says exactly that?

The implementation described here comes from the open-source project KeelBase:

https://github.com/rain6fish/KeelBase
Drafted with an AI assistant. The system, the positions and the mistakes are mine.


r/AISystemsEngineering • • 2d ago

Always-on agents: real talk

Thumbnail reddit.com
1 Upvotes

For the AI and Agents architects out there who are actually building agentic solutions for enterprises - curious to hear if you are actuallyyy using agentic usecases in production in an enterprise domain


r/AISystemsEngineering • • 2d ago

Separating company rules from the intelligence executing them

1 Upvotes

I've been experimenting with an architecture where engineering rules remain independent of the model interpreting them.

The approach is relatively simple:

  • Glob selects the relevant files.
  • Grep handles deterministic checks.
  • A model makes a narrow semantic judgment when needed.

In one experiment, I swapped the underlying model across 30 rule/example combinations. The models agreed on 24.
The six disagreements are probably the interesting part: changing models can change how your company's rules are interpreted, even when the instructions stay identical.

I'd love feedback on how others approach regression testing when switching intelligence providers. Thankssss!


r/AISystemsEngineering • • 3d ago

Is studying ai engineering worth continue to study?

2 Upvotes

I have studied to learn computer science for 6 months, and I am not sure should I continue to do it?
I’ve completed python programming from cs50 and I made several simple projects on my own, and felt very well. So I decided to become an ai engineer, and I’ve watched several youtube videos and checked several sources to have clean roadmap to become one. So basically, my roadmap is:
Learning Git, HTTP and REST, async Python, SQL, FastAPI, pytest, Docker, LLM APIs, streaming, structured output, tool calling, embeddings, vector databases, RAG, hybrid search, reranking, chunking, evals, LLM judges, deployment, logging, agent loops, tool design, context engineering, MCP, LangGraph, observability, retries, caching, batching, cost optimization, prompt injection defense, guardrails, agent evals, portfolio projects, interview prep, linear algebra, probability and statistics, neural networks, PyTorch, fine-tuning.
But two months ago I vibecoded 2 projects and did the did very well. The project not that simple either, and that was funny to building things with ai, but this is not the same as you build on your own. The feelings you get from two processes are very different from each other. And I started doubting about learning coding itself. Yes, and I am very known that nowadays we should use ai to coding instead, but guy with no experience with coding will never understand what is programming and how they work.
Should I continue to learn? And when I should switch from manual coding to coding with ai?


r/AISystemsEngineering • • 3d ago

Agent memory: why intelligence alone is not enough for enterprise AI

2 Upvotes

Revenue is down. Marketing spend is up. Can your AI agent tell you why, and what to do about it? Why intelligence is not enough!
Answering this requires more than a powerful LLM (Claude/GPT/Gemini/etc). The real challenge in enterprise AI isn't just model intelligence anymore, it requires an understanding of your business, its data, historical decisions and operational processes.

As a technology leader with a hands-on engineering background, I am particularly interested in exploring how emerging technologies can solve real-world business problems.

Imagine an AI agent that understands SQL and financial concepts but doesn't understand how your business calculates revenue, attributes marketing spend or defines customer churn. How much confidence would you have in its recommendations?

In my latest personal blog, I explore 6  types of agent memory, their technical architecture and how they can help organisations capture and manage business context:
• Parametric memory
• External / Retrieval memory
• Semantic memory
• Working memory
• Episodic memory
• Procedural memory
Read my latest blog: https://harbisingh.wordpress.com/2026/11/28/agent-memory/

The intention is not just to discuss how technology works, but to explore how we can apply it to solve real-world business problems.