TensorFlow.js: Date String Conversion

Solving a Sequence-to-Sequence Task Using LSTM and Attention

Description

This example demonstrates the inference stage of using a sequence-to-sequence model to convert a myriad of common date formats into the ISO 8601 date format (i.e., YYYY-MM-DD). The list below shows examples of the supported input date formats.

The model is based on LSTM and the attention mechanism .

The training uses tfjs-node and runs in the backend Node.js environment. The training script can be found here .

Status

Support Date Formats

Examples for supported formats (click to try):
  • 23Jan2015
  • 012315
  • 01/23/15
  • 1/23/15
  • 01/23/2015
  • 1/23/2015
  • 23-01-2015
  • 23-1-2015
  • JAN 23, 15
  • Jan 23, 2015
  • 23.01.2015
  • 23.1.2015
  • 2015.01.23
  • 2015.1.23
  • 20150123
  • 2015/01/23
  • 2015-01-23
  • 2015-1-23
  • 23 JAN 2015

Input date string:
Press Enter to Refresh Conversion
Output date string:
Attention matrix: