MAKE SURE YOU get to the airport a couple of hours before your flight, OK? Oh it’s international? Make that three hours. And on a holiday? Might as well go the night before and bring your sleeping bag.

After all, you never know just how messed up the airport’s going to be. Each stage of the convoluted process (parking, check-in, security, boarding, baggage, customs and immigration, and even waiting in a line for coffee) can push you past your boarding time. On a good day, you can get through it all in 20 minutes, just to while away the hours in a plastic chair, nursing a crappy meal that cost too much money.

There’s hope for a more efficient future. Airport operators are starting to use the predictive power of software to monitor and forecast passenger numbers, so they can deploy enough agents, screeners, and other staff at the right times, to get everyone through as quickly as possible. That technology has now reached American shores: New York’s JFK Airport is the first in the US to go live with an Operational Terminal Prediction tool to try to gain that extra efficiency.

The software, called Beontra, is now running at JFK’s Terminal 4, home to 32 airlines and 20 million annual travelers.

Beontra grabs data on flight operations and delays from the Airport Operational Database, which also includes passenger data. Airlines can opt to feed it info directly too: Delta, for example, tells the system when it changes up it schedules. For those that don’t help out, Beontra can pull the info from online sources.

The system combines that with known data about how early passengers tend to arrive (a show-up profile), how long it takes to people to walk about the terminal, and how long it takes to them to pass through each bottleneck. The result is a simple graph showing when passenger wait times are going to peak.

“The primary reason to put this software in place is resource planning,” says Daryl Jameson, who runs IT and baggage systems for JFK International Air Terminal, the private company that runs the terminal. “It gives us a better idea of the changing environment in real time.”

https://www.youtube.com/watch?v=yH0_PL8s4DM

The idea is to share that graph with the TSA, airlines, and immigration officials, so they can pull all available staff off other duties and have them manning desks when needed. Think of it like the PA system in a supermarket, used to call shelf-stackers to the registers when lines get long. The Beontra dashboard displays information for that day, and the next two. Eventually it could be used for forecasts up to 90 days out.

More than 30 airports in Europe and Asia are using the system, and now that JFK’s onboard, the folks running T4 can finally ditch the old way of doing things: a gargantuan spreadsheet. “The charts were static, they just had a generic day,” says Robert Pyrka, director of airline and capacity planning for JFKIAT. He’s the guy who had to fill those sheets. If he wasn’t there to update them, they didn’t reflect changing circumstances, like delays.

Other American airports and agencies have already expressed interest in the trials, says Jameson. In the future Beontra could base its thinking on more sources, like the exact time boarding passes are scanned, or real time queue information from cameras.

Modern terminals are trending towards increased automation, with self-service bag drops and automated boarding gates. Each of those computerized systems can also be a data source. The information can be fed back to everyone inside and outside who deals with passengers: stores, restaurants, parking lots, taxis, and trains.

One day, you can hope for a kind of benevolent overlord—an intelligent system watching over entire terminals, smoothing your path in real time. For now, you get a patchwork of systems designed to relieve pinch points, which Beontra joins. JFK T4 already has large displays of real-time wait times at security and taxi ranks for example, and the feedback has generally been positive.

“People have better expectations, and less anxiety,” says Jameson.

Until you can walk from curb to gate in one unimpeded journey, the advice remains the same. Get to the airport with plenty of time to spare. And hang on to the hope that at least the queue at the coffee shop won’t be as bad in the future.