version 1.0;

extension tract_registry tract_core;

fragment tract_core_properties(
) -> (properties: (string, tensor<scalar>)[])
{
  properties = [("tract_nnef_ser_version", "0.18.3-pre"), ("tract_nnef_format_version", "beta1")];
}

graph network(input) -> (output) {
  input = external(shape = [1, 2, 2]);
  default_state = [[[0.0, 0.0], [0.0, 0.0]]];
  state = tract_core_load(default_state, id = "state-0");
  v2_linear_output = matmul(input, state, transposeA = false, transposeB = true);
  new_state_1 = add(v2_linear_output, v2_linear_output);
  dummy = tract_core_store(input = v2_linear_output, state = new_state_1, id = "state-0");
  output = tract_core_force_eval([v2_linear_output, dummy], slots = [1]);
}
