P: A Universal Measure of Intelligence based on Prediction


This website describes my research on a new measure of intelligence.

More information about the theoretical background and algorithm is available in the following publications:

The Maze Experiments show how an agent's predictive intelligence can be measured as it explores different maze environments.

The Time Series Experiments show how the predictive intelligence of a deep neural network can be measured as it learns regularities in sets of time series data.

The TypeScript source code can be downloaded here.

Maze Agent

These experiments show how P can be calculated for an embodied agent that learns to predict the consequences of its actions in different maze environments.


Move forward [ Space bar ]

Point left/right/up/down [ Arrow left/right/up/down ]


Explore current maze:


Polynomial window: +/- 5

Enable learning

Re-calculate intelligence every changes.


Plot intelligence for individual mazes


Time Series Agent

These experiments show how P can be calculated for a deep neural network that makes predictions about time series data.

Use the controls to load and train the network on the time series datasets and view the changing intelligence of the network over time.

The machine learning is done using TensorFlow.js.


Data sets

Train data: 70% Validation data: 15% Test data: 15%

Time window:


Number of models:

LSTM units per model:


Number of epochs:

Batch size:

Number of training cycles



Polynomial window: +/- 5

T-test p-value:


Plot intelligence for individual mazes

Plot batch loss