Notes

Featuretools

When your data lives in more than one table — customers, sessions, orders — nearly all the useful features are aggregations across the joins, and writing them by hand is weeks of careful SQL. Featuretools is the open-source library that writes them for you.

Deep Feature Synthesis

You describe the data once as an EntitySet: the dataframes, their index columns, and the relationships between them. Featuretools then applies primitives — small named functions — and stacks them across those relationships, an algorithm called Deep Feature Synthesis:

  • Aggregation primitives such as SUM, MEAN, COUNT and NUM_UNIQUE roll a child table up to its parent;
  • Transform primitives such as MONTH, WEEKDAY and TIME_SINCE_PREVIOUS act within a single table;
  • max_depth controls stacking, so depth two produces features like MEAN(sessions.COUNT(orders)).
features, definitions = ft.dfs(entityset=es,
                               target_dataframe_name='customers',
                               max_depth=2)

More than a convenience

Every generated column carries a readable definition, so a feature can be explained and audited instead of trusted blindly. The decisive capability is cutoff times: supply a timestamp per row and Featuretools computes each aggregation using only data that existed before it, which removes the time leakage that silently inflates offline scores on temporal problems. Expect a wide result — hundreds of columns — and treat selection as the next step. The library is maintained by Alteryx, types its data with Woodwork, and feeds naturally into EvalML for the search that follows.

Featuretools is an open-source Python library for automated feature engineering on relational and time-series data. You declare your tables and their relationships as an EntitySet, and its Deep Feature Synthesis algorithm stacks aggregation and transform primitives across those relationships to produce hundreds of named, explainable features. Its cutoff times mechanism computes each row's features only from data available before a given timestamp, preventing the temporal leakage that hand-written joins routinely introduce.

Suppose you want to know which customers are about to leave. The clues are not in any single line of your records — they are in the summaries. How many times has this person complained? How long since they last bought anything? Is their spending drifting down?

Featuretools is a free program that writes those summaries for you. You show it how your spreadsheets relate to one another — this table of orders belongs to that table of customers — and it builds hundreds of such columns automatically, each with a plain, readable name. It is careful about time as well, using only the information that existed before the moment you are predicting from.