Production loss accounting · Agentic diagnostics

Every barrel of deferment gets a reason.
Not just the big ones.

Production engineers spend their day chasing loss: spot the deviation, work out why, act, and assign a downtime code. The obvious cases automate. The ambiguous ones — the majority — are solved in an engineer's head, one well at a time, until the day runs out. PTS-LT reproduces that reasoning as an auditable chain, runs it on every flagged well-day, and leaves the decision with the engineer.

code taxonomy
74code taxonomyPlanned · Unplanned · Commercial · External
diagnostic steps
10diagnostic steps9 deterministic, 1 reasoning synthesis
of flagged well-days
100%of flagged well-daysanalyzed, regardless of loss size
The daily reality

The coding is automated. The thinking is not.

Downtime and production-loss coding is already partly automated in most operations. What automation reliably catches is the unambiguous: the well is down, hours-on is zero, the work order is open. Everything else lands on a person.

Coverage

Automation stops where ambiguity starts

A rule engine can code a well that is fully shut in. It cannot separate a sticking gas-lift valve from rising watercut from a choke restriction when hours-on reads 24 and the rate is simply low. That case — rate loss with full availability — is the common one, and it falls through to manual review.

Attention

Triage is biased toward the largest losses

With a few hundred wells and a few hours, an engineer works top-down by barrels lost. The long tail of small and mid-sized losses gets a generic code, a blank, or nothing at all — not because it doesn't matter, but because there is no time left in the day.

Consistency

The reasoning lives in one person's head

The engineer mentally fuses SCADA trends, GOR and watercut behavior, maintenance history and well context to infer a cause. That inference is rarely written down, varies between engineers and shifts, and cannot be audited, reviewed, or improved after the fact.

The downstream cost is not the coding effort — it is that deferment data feeding forecasts, budgets and reliability programs is only as good as the tail that never got looked at.

Where the attention goes

The tail is where the uncoded volume hides

Loss events sorted by size. The largest events get individual root-cause attention; the rest are coded generically or left open. Illustrative distribution — shape, not measurement.

Individually diagnosed todayGeneric code, blank, or unreviewed
Top 5%
34%
Next 10%
21%
Next 15%
17%
Next 30%
16%
Bottom 40%
12%

Roughly half of deferred volume sits below the attention line. Every event under it is a well that lost oil for a reason nobody recorded.

View as table
Event size bucketShare of deferred volumeIndividually diagnosed
Top 5%34%95%
Next 10%21%62%
Next 15%17%28%
Next 30%16%9%
Bottom 40%12%3%
The approach

A diagnostic chain that shows its work

PLCA — the Production Loss Classification Agent — walks the same decision tree a production engineer walks. Nine steps are deterministic signal checks in plain code: no model call, no token cost, no room for invention. Only the final synthesis, where genuine ambiguity remains, calls a language model, and it is forced to return a structured classification bound to the taxonomy.

Deterministic — plain code, no model call Reasoning — model call, metered
  1. check_shutinhours_on = 0

    Is the well fully shut in?

  2. check_availabilityhours_on < 22

    Uptime loss or rate loss?

  3. check_facilitycompressor / separator status

    Did facility equipment fail?

  4. check_glchangepoint detection, ≥15% drop

    Did gas-lift injection step-change?

  5. check_gortrend slope > 2% relative

    Is GOR rising?

  6. check_watercuttrend slope > 0.002

    Is watercut rising?

  7. check_whp_declinetrend slope < −1% relative

    Is WHP declining with rate?

  8. check_planned_eventmaintenance schedule overlap

    Is there a planned event on record?

  9. check_analogsconfirmed losses on same-formation peers

    Does it match analog wells?

  10. finalize_proposalstructured output, taxonomy-bound

    Synthesize the classification

Branches short-circuit: a well that is fully shut in never runs the trend checks. Cost stays proportional to how ambiguous the case actually is.

What comes back

proposed_code
A code from the taxonomy — never a free-text guess
confidence
Scored 0–1, banded HIGH / MEDIUM / LOW
reasoning_summary
The chain of evidence, in the engineer's language
alternative_codes
What else it could be, and why it ranked lower
recommended_actions
The next diagnostic or intervention to run
data_gaps
What it could not see — stated, not papered over

Governance, built in rather than promised

It cannot mark its own homework

The agent writes to a staging table and an immutable audit log. Nothing else. There is no code path from the agent to a live loss record — the constraint is structural, not a policy someone has to remember.

A human closes every loop

An engineer confirms the proposed code or overrides it with their own code and a reason. Override always wins. Only then does a live loss event exist and attach to that well-day's variance record.

It says when it doesn't know

When no signal conclusively explains the loss, the agent is instructed to return a Data Quality / Unknown code rather than a confident-sounding guess. An honest unknown is a usable input; a plausible wrong code is not.

Every run is on the record

Inputs, each step's verdict, the final output, model, token count and cost are logged per run. The engineer's confirmations and overrides accumulate into the accuracy signal that tunes the next version.

Why this is a step change

Not a faster form. A different division of labour.

Rules engines made coding faster. This changes who does the reasoning — and therefore what gets reasoned about at all.

Coverage
TodayEngineers triage top-down by barrels; the tail is coded generically or skipped
With PTS-LTEvery well-day over threshold is analyzed at the same depth, largest to smallest
Reasoning
TodayTacit, in one engineer's head, unrecorded
With PTS-LTAn explicit chain of evidence, step by step, stored and reviewable
Consistency
TodaySame symptom, different code, depending on who is on shift
With PTS-LTOne decision tree applied identically to every well, every day
Engineer's role
TodayAssemble the evidence, then decide
With PTS-LTReview assembled evidence, then decide — or override with reason
Auditability
TodayA code in a field, with no trace of how it was reached
With PTS-LTImmutable run log: inputs, steps, output, cost, confirmations, overrides
Improvement
TodayNo feedback signal — nobody knows which codes were wrong
With PTS-LTEvery override is labelled training data for the next iteration
The prize

What the industry stands to gain

Illustrative planning figures, with the assumption behind each stated. These are the hypotheses this platform exists to test — not results it has produced.

2–3 h
per engineer, per day

Time spent on loss triage and coding today

Assumption. Typical reported range for a PE carrying 200–400 wells; varies widely by operation and tooling.

~60%
of that time

Is evidence-gathering, not deciding

Assumption. The portion spent pulling trends, checking work orders and reconstructing context before any judgment is made.

coded loss volume

When the tail is analyzed rather than skipped

Assumption. Assumes roughly half of deferred volume currently sits below the attention line — see the distribution above.

seconds
per well-day

Time to a proposed, evidence-backed classification

Assumption. Nine deterministic checks plus one model call; per-run token cost is metered and logged.

Where the value actually lands

Recoverable deferment found sooner

A sticking gas-lift valve caught on day two instead of at month-end close is barrels back in the line, not a better report.

Forecasts built on complete deferment data

Budget and production forecasts inherit the quality of the loss record. A coded tail changes the base they are built on.

Reliability programs aimed at real failure modes

Consistent coding across the full population makes failure-mode frequency a measurement rather than an impression.

Engineer capacity returned to optimization

The scarce resource is engineering judgment. Spending it on evidence assembly is the actual loss.

What it runs on

The data an operation already has

No new instrumentation. The diagnostic chain consumes the systems already in place — the work is fusing them into one reasoning context per well, per day.

The signal layer

SCADA / real-time telemetry

  • Wellhead pressure, casing and tubing pressure
  • Differential pressure (casing − tubing)
  • Gas-lift injection pressure and rate
  • Compressor discharge pressure, capacity, status
  • Separator and facility equipment state

Drives the changepoint and trend checks — the steps that separate rate loss from availability loss.

The measured outcome

Production & allocation data

  • Daily oil, gas and water volumes
  • Hours on / uptime fraction
  • Derived GOR and watercut trends
  • Well test results

Establishes the actual against which target and variance are computed.

The planned-event ground truth

Maintenance & work management

  • IBM Maximo or SAP PM work orders
  • Planned shutdown and workover schedules
  • Equipment failure history
  • Job status and completion records

A planned event on record outranks every inferred signal — the first thing that must be ruled in or out.

The context layer

Well header & master data

  • Formation, completion and artificial-lift type
  • Location, operator, spud and first-production dates
  • Equipment configuration and valve design
  • Peer-group membership for analog matching

Decides which checks even apply — a gas-lift check is meaningless on a rod-pumped well.

The reference

Targets & constraints

  • Engineer-set daily rate targets, versioned
  • Constraint type: reservoir, facility, budget, regulatory
  • Basis notes and approval trail

Loss is only definable against an owned, dated target — not against last month's average.

The integration surface

In-house data platforms

  • Existing data lake / historian aggregation
  • Corporate well master and reference data
  • Loss and downtime code taxonomy in force
  • Analytics and reporting layers already in use

Connected through a tool interface, so a synthetic or staged source can be swapped for a live one without touching the diagnostic logic.