Data & Analytics

AI/ML Offers New Solutions for Legacy Data Challenges

Over decades of exploration and production, the oil and gas sector has accumulated vast amounts of legacy data in various formats. Artificial intelligence and machine learning present an opportunity to transform how this unstructured data is processed and used, enabling significant improvements in operational efficiency and decision-making.

Satisfaction, Document, Checklist, Database, Contract, Checkbox, Insurance, Manager,Technology,Marketing,Security,Choice,Working,Laptop,Success,Finance,Service,Questionnaire,Computer,Paper,Business,
Virtual Reality,Organization,Surveyor,Check Mark,
Source: Urupong/Getty Images

The energy industry has long been one of the most data-intensive industries globally. Over decades of exploration and production, the oil and gas sector has accumulated vast amounts of legacy data in various formats. These records include seismic tapes, well logs, handwritten reports, and other critical documents from multiple phases of a well’s lifecycle.

The sheer volume and diversity of this data poses unique challenges, particularly in data management, accuracy, and analysis. Artificial intelligence (AI) and machine learning (ML) present an opportunity to transform how unstructured data is processed and used, enabling significant improvements in operational efficiency and decision-making.

Historically, much of the oil and gas industry’s data was manually recorded and stored in nondigital formats. Over time, companies began digitizing this information, transitioning to PDFs, TIFFs, and other document types that were easier to store and manage. However, the process of digitization did not resolve all data issues. Many key attributes, such as well headers, well locations, and operational details, still had to be entered manually into corporate databases, often leading to errors and incomplete records. Even with bulk data-loading engines, gaps in data completeness and consistency persisted. These inaccuracies created substantial risks; flawed or missing data can severely affect operational planning and decision-making and lead to inefficiencies, cost overruns, and potential compliance and safety hazards.

Unstructured Data: The Core Challenge and Opportunity
A significant challenge within the oil and gas industry is the accumulation of unstructured data—information that lacks a predefined format, making it difficult to process using traditional database systems. Examples of unstructured data include well logs, seismic data, drilling reports, and operational records. These documents contain valuable insights, but they are not easily searchable or usable within structured data environments.

For example, well header attributes such as latitude, longitude, water depth, and completion date are critical for data analysis, but, in many cases, this information is buried within scanned reports or handwritten notes, requiring manual retrieval and validation. To unlock the value hidden in these records, the industry must adopt advanced AI and ML technologies capable of converting unstructured data into structured, actionable insights.

Solution Approach: AI-Driven Well Header Extraction Workflow
Recognizing the business need to improve upon legacy data stored in unstructured formats, I identified a significant opportunity to address this issue using new ML technologies. The project focused on a common problem in the oil and gas industry: filling missing well header attributes in customer databases using unstructured data extracted from well reports.

As a technology leader in an oilfield service company, I spearheaded the creation of a system that used ML to extract critical insights from unstructured data stored in the cloud (Fig. 1). This system was designed to automatically populate missing well header attributes using data extracted from historical reports. Our solution focused on key attributes such as spatial data (i.e., latitude and longitude) and other well-specific details, improving the accuracy and completeness of the company’s database.

Legacy_Fig1.jpg
Fig. 1—Technical approach for well header attribute extraction and enrichment.

The technical solution approach for well header attribute extraction workflow involved a multistep AI-driven pipeline, including optical character recognition (OCR) processing, intelligent document retrieval, machine-learning-based extraction, and data validation. We developed this solution by designing and integrating the following key components and tools:

  1. Digitizing unstructured documents with OCR & Text Extraction—Our first step was to apply OCR to extract textual data from scanned well reports, using Google OCR and Tesseract to enhance document readability and character recognition. Preprocessing text in this phase enabled the software engineering team to improve accuracy by removing noise, normalizing fonts, and fixing formatting errors.
  2. Intelligently retrieving relevant pages using ranking algorithms—Because well header attributes were scattered across multiple pages, an intelligent retrieval mechanism was developed and implemented, using the Best Match 25 ranking algorithm to prioritize pages based on keyword relevance. Additionally, we used a keyword-based search and pattern-matching method to identify the most relevant sections of the report. This step significantly reduced processing time by focusing extraction on high-confidence pages.
  3. Applying ML models to extract and categorize well header attributes—We next trained a natural language processing (NLP) model based on bidirectional encoder representations from transformers (BERT) to extract well header attributes, using named entity recognition models to identify attributes such as
    • Latitude and longitude (geolocation data)
    • Water depth and completion date (quantitative values)
    • Well name, operator, and field Name (categorical data)

    We furthermore created custom classification models to refine attribute categorization based on domain-specific constraints.

  4. Standardizing and validating extracted data for accuracy—Ensuring accuracy in the system required that we extract attributes to normalize and validate them against industry standards. This involved developing custom parsers for
    • Date formats (e.g., YYYY-MM-DD, DD/MM/YYYY)
    • Geolocation conversion (decimal degrees, degrees-minutes-seconds)
    • Unit conversion (e.g., feet to meters)

    We then assigned confidence scores to the extracted values to determine and validate data reliability.

  5. Aggregating multisource data to improve confidence and reliability—To improve accuracy, data from multiple reports were combined using an aggregation model that applied majority voting and confidence-weighted selection to choose and filter out most reliable values. This system eliminated duplicate entries and flagged inconsistencies for review.
  6. Seamlessly integrating validated well header attributes into structured corporate databases—In the last steps of the development process, we validated how well header attributes were ingested into the corporate database for structured access and built an integration based on the representational state transfer application programming interface to automate and facilitate data flow from the AI system to the cloud storage using an ML workflow. This maximized efficiency by ensuring seamless interoperability with existing energy data platforms.

Fig. 2 illustrates the workflow implemented in the solution to find and fill missing well attributes.

Legacy_Fig2.jpg
Fig. 2—The data enrichment solution workflow. WKS = well-known schema; WKE = well-known entities.

Overcoming Data Extraction Challenges
While the AI-driven system proved to be highly effective, several technical challenges had to be addressed. These included

  • Varied attribute representations—Different formats, terminologies, and syntaxes were used to represent the same well header attributes across various documents. The system had to be flexible enough to handle these differences. Hence, the ML models were fine-tuned to handle diverse representations.
  • OCR challenges—Many older historical reports, being either handwritten or of poor print quality, led to OCR extraction inaccuracies and errors. The system had to be robust enough to handle errors in OCR processing and still produce reliable outputs. To resolve this, OCR models were trained on industry-specific data to enhance recognition accuracy.
  • Diverse document layouts—The well reports lacked uniform structure, with some being complex and others simple. Developing a universal extraction method that could manage these differences was essential. The reports required adaptive NLP models to adjust to different formats.
  • Multiple information sources—Information about a single well might be spread across several pages or documents. Consolidating data from various reports to build a unified and accurate well record was a critical challenge. Data fusion techniques for the information ensured consistency and eliminated redundancy.

Despite these challenges, the developed system was successful in extracting and enriching well header data from multiple wells across several fields. It enabled real-time well header extraction, reducing manual processing time and costs. Specifically, we were able to extract and populate 13 well header attributes from more than 700 reports covering 350 wellbores. This improvement led to a significant increase in the data quality score, which rose from 44% to 89%, and allowed our client to make more informed, data-driven operational decisions that resulted in enhanced efficiency; reduced downtime; and, ultimately, increased revenue.
The system’s success in this instance not only solved a key issue but also provided tangible business value by ensuring more complete, accurate, and reliable data. This innovation helped the client optimize operations, which translated into a more effective use of resources and greater profitability.

Expanding the Impact: Future Developments
Building on the success of this initiative, the next steps involve expanding the workflow to incorporate additional fields, well types, and document formats. As the ML framework continues to evolve, its further refinement will enable the system to handle an even broader range of unstructured documents, leading to faster and more accurate data extraction. This ongoing expansion will ensure that the system can accommodate the full diversity of reports and increase the scope of its effect on the industry.

The methodologies and innovations developed here set a new standard for leveraging AI in legacy data management, providing valuable contributions to digital transformation for the energy industry.

This project exemplifies how modern technology, particularly AI/ML tools, can address longstanding challenges in traditional industries. By applying cutting-edge technologies to legacy unstructured data, this AI-powered solution significantly improved data quality, operational efficiency, and business intelligence in the energy sector.