Many drilling conditions are developed states, not instantaneous measurements. Moving windows compress recent behavior; event history preserves what happened; time, depth, and stand coordinates preserve different memory; and context boundaries decide when old evidence should be forgotten. The design should follow the physics and the decision timescale.

Instantaneous measurements and operational state

The drilling system itself retains state. Cuttings generated five minutes ago remain relevant until transport, settling, or mechanical disturbance changes their effect. Cutter damage survives a later period of stable torque, and a washout can develop gradually before the current pressure response becomes decisive.

Evidence type Question Examples
Instantaneous measurement What is happening now? WOB, RPM, SPP, ROP
Developed operational state What condition has recent operation produced? Hydraulic deterioration, bit effectiveness, hole-cleaning concern, persistent dysfunction

The first can often be measured directly. The second must usually be inferred from history. Real-time analysis is not necessarily stateless.

Use windows at the timescale of the process

A common way to add memory is the moving average. For a window of N observations:

$$\bar{x}_t = \frac{1}{N} \sum_{i=0}^{N-1} x_{t-i}$$

The recent average suppresses random fluctuation. A torque sequence of 14, 17, 12, 18, 13, and 16 kft-lbf may look noisy sample by sample while its mean remains stable. A longer window smooths more aggressively and better represents gradual degradation, but it reacts more slowly and can mix changing operating conditions. Window length must follow the physical timescale.

Short and long moving windows applied to the same synthetic pressure trace

Short and long moving windows emphasize different physical timescales within the same synthetic pressure history.

Hydraulic failure surveillance provides a useful public example. IADC/SPE-189700 used different analytical timescales for different pieces of evidence. Shorter-window pressure behavior helped characterize relatively rapid changes, while longer-horizon trends helped recognize slowly developing degradation. The exact window lengths were field-specific; the general principle is that combining fast and slow evidence can be more informative than forcing every signal through one timescale. Two wells can both show 4,800 psi now while carrying different histories:

Case Recent SPP sequence Interpretation
A 4,810 → 4,790 → 4,820 → 4,800 psi Stable around the current value
B 5,400 → 5,250 → 5,050 → 4,900 → 4,800 psi Sustained decline to the current value

SPE-186166 explicitly distinguishes:

  • where a feature currently lies,
  • how it has been moving over a recent window.

The latest sample gives location. The window gives movement.

Compress history into trend, variability, and persistence

Recent history can be compressed into features that remain physically interpretable. A rolling trend may fit:

$$x(t)=a+bt$$

over a rolling interval. The sign and magnitude of the fitted slope summarize whether the signal is rising, falling, or stable. Variability requires the same historical view:

$$\sigma_t = std( x_{t-N+1}, ..., x_t )$$

A moving standard deviation can separate a stable level from erratic torque, unstable control response, or sensor noise. Persistence adds a second dimension to severity: a brief MSE spike and moderately elevated MSE across six stands should not carry the same evidential weight. A detector should therefore evaluate magnitude and duration together. A high, brief deviation may be noise or transient operation; a smaller sustained deviation may indicate a developing condition. Trend, variability, and persistence are compact forms of memory, not separate narratives.

Hole cleaning requires long-horizon memory

Hole cleaning is perhaps the clearest drilling example. SPE-204125 explicitly treats hole condition as a long-horizon inference problem. The method does not attempt to estimate exact cuttings-bed height. Instead, it evaluates whether recent drilling operations have generally been conducive to:

  • effective,
  • poor

hole cleaning. Evidence can include historical operational behavior such as:

  • circulation,
  • tight spots,
  • static periods,
  • working pipe,
  • off-bottom circulation,
  • rotation.

The result represents the recent operational history of the wellbore, not only the current sample. At the same current flow of 650 gpm, two histories imply different hole conditions:

Recent history Case A Case B
Drilling and circulation Modest ROP, continuous rotation, recent reaming Very high ROP, long static interval, little pipe movement
Supporting evidence No long static period Tight spot encountered

Current flow is identical; expected hole condition is not.

Long-horizon operational history contributing to a current hole-condition assessment

Current hole condition depends on the sequence and recency of drilling, static, circulation, reaming, and tight-spot events.

After a two-hour static period, restarting circulation makes Static = false immediately, but settled cuttings may remain. A stateful system must distinguish an active event from a consequence that remains relevant after the event ends.

Weight events and forget deliberately

Instead of storing only a rolling sensor window, a system can remember discrete operational events. For example:

13:10–13:42  Static
14:15–14:31  Reaming
15:05–15:18  Off-bottom circulation
16:03         Tight spot

The system can track event count, duration, and recency without repeatedly scanning hours of raw 1-Hz data. SPE-204125 describes this kind of event log for consolidating long-horizon drilling information into real-time features. Recency matters: a strong hole-cleaning operation 20 minutes ago should generally influence the current assessment more than one 20 hours ago. An illustrative age weight is:

$$w(\Delta t) = e^{-\Delta t/\tau}$$

where the decay constant controls how quickly old evidence loses influence. A historical event can then contribute:

$$Contribution_i = Duration_i \cdot w(Age_i)$$

These equations are generic illustrations, not a reproduction of a proprietary implementation. An unlimited memory can be as misleading as no memory: old poor conditions should not dominate after a bit pull, BHA change, hole-conditioning operation, and return to drilling. Deliberate forgetting may use:

  • age decay,
  • explicit reset,
  • context segmentation.

A sharp formation change can invalidate an MSE trend calculated over the previous 500 ft. BHA, bit, hole-size, wellbore, or mud-system changes can do the same. Recent data does not necessarily belong to one physical population: a 30-minute ROP window split evenly across Formations A and B represents neither formation cleanly, even though the average is mathematically valid. A state-aware system should reset or segment its memory at material context boundaries.

Choose time, depth, or stand memory

The coordinate changes what the system remembers. A 100-ft window represents 30 minutes at 200 ft/hr but two hours at 50 ft/hr. Conversely, a one-hour window contains 200 ft during fast drilling and 50 ft during slow drilling.

Memory coordinate Best suited to
Depth Formation-relative comparison and footage-normalized performance
Time Mechanical dynamics, operational persistence, and failure development

The coordinate should match the physical question. Some behavior is naturally organized by stand, including:

  • bit wear progression,
  • connection performance,
  • drilling efficiency.

A memory representation can therefore retain the previous three stands and the current stand rather than an arbitrary number of seconds or feet. This often aligns better with the way drilling teams interpret operational progression.

Remember decisions and preserve explanation

A parameter recommendation is an intervention. If an optimizer suggests increasing RPM and evaluates the well five seconds after the change, it may issue another recommendation before a stable response exists. A stateful system should retain what was recommended, what changed, when it changed, and whether the evaluation interval is complete.

The same record connects observation, recommendation, action, and response, preventing an improvement after a WOB change from being mislabeled as formation change or spontaneous recovery. State must also remain explainable. A poor hole-condition assessment should expose its supporting history:

  • prolonged static history remains influential,
  • recent circulation has been limited,
  • one tight spot was encountered,
  • proactive pipe-working history is aging out.

A scalar such as Hole Condition = 0.31 cannot provide that audit trail. A practical design therefore answers five questions:

  1. Which physical process is being represented, and how quickly can it change?
  2. Which sensors, events, and context define the evidence?
  3. Should memory use a rolling window, trend, variability, cumulative duration, or age-weighted event history?
  4. Does time, depth, stand, or event sequence match the decision?
  5. Which boundaries reset the state, and can the user inspect why the current assessment exists?

DrillingMetrics preserves this context through rig-state-segmented time traces, stored operational events, and a human-readable time log for engineering review.

DrillingMetrics high-frequency time traces, detected events, and human-readable operational time log

DrillingMetrics connects a twelve-hour rig-state history with detected events and an AI-generated operational time log so the present can be interpreted in context.

Related technical resources

References

  1. Ambrus, A., Ashok, P., Ramos, D., Chintapalli, A., Susich, A., Thetford, T., Nelson, B., Shahri, M., McNab, J., and Behounek, M. Self-Learning Probabilistic Detection and Alerting of Drillstring Washout and Pump Failure Incidents During Drilling Operations. IADC/SPE-189700-MS, IADC/SPE Drilling Conference and Exhibition, Fort Worth, Texas, 2018.

  2. Ambrus, A., Ashok, P., Chintapalli, A., Ramos, D., Behounek, M., Thetford, T. S., and Nelson, B. A Novel Probabilistic Rig Based Drilling Optimization Index to Improve Drilling Performance. SPE-186166-MS, SPE Offshore Europe Conference & Exhibition, Aberdeen, United Kingdom, 2017.

  3. Ashok, P., D'Angelo, J., Ramos, D., Yi, M., Thetford, T., Younk, N., Bohlander, S., Shahri, M., and Behounek, M. A Probabilistic Belief System to Track the Cleanliness of a Hole in Real-time. SPE-204125-MS, SPE/IADC International Drilling Conference and Exhibition, 2021.