{"record":{"id":"ff90976e0f10f46d","repo":"tensorflow/models","slug":"unexpected-inputs-to-s-with-length-at-d-ff9097","errorCode":null,"errorMessage":"Unexpected inputs to %s with length at %d.","messagePattern":"Unexpected inputs to (.+?) with length at (.+?)\\.","errorType":"exception","errorClass":"ValueError","httpStatus":null,"severity":"error","filePath":"official/nlp/modeling/networks/funnel_transformer.py","lineNumber":470,"sourceCode":"        input_mask=tf_keras.Input(shape=(None,), dtype=tf.int32),\n        input_type_ids=tf_keras.Input(shape=(None,), dtype=tf.int32))\n\n  def call(self, inputs, output_range: Optional[tf.Tensor] = None):\n    # inputs are [word_ids, mask, type_ids]\n    word_embeddings = None\n    if isinstance(inputs, (list, tuple)):\n      logging.warning('List inputs to  %s are discouraged.', self.__class__)\n      if len(inputs) == 3:\n        word_ids, mask, type_ids = inputs\n        dense_inputs = None\n        dense_mask = None\n        dense_type_ids = None\n      elif len(inputs) == 6:\n        word_ids, mask, type_ids, dense_inputs, dense_mask, dense_type_ids = (\n            inputs\n        )\n      else:\n        raise ValueError(\n            'Unexpected inputs to %s with length at %d.'\n            % (self.__class__, len(inputs))\n        )\n    elif isinstance(inputs, dict):\n      word_ids = inputs.get('input_word_ids')\n      mask = inputs.get('input_mask')\n      type_ids = inputs.get('input_type_ids')\n      word_embeddings = inputs.get('input_word_embeddings', None)\n\n      dense_inputs = inputs.get('dense_inputs', None)\n      dense_mask = inputs.get('dense_mask', None)\n      dense_type_ids = inputs.get('dense_type_ids', None)\n    else:\n      raise ValueError('Unexpected inputs type to %s.' % self.__class__)\n\n    if word_embeddings is None:\n      word_embeddings = self._embedding_layer(word_ids)\n","sourceCodeStart":452,"sourceCodeEnd":488,"githubUrl":"https://github.com/tensorflow/models/blob/e006f5f0d534913e49c1f1dae87364039fa607e2/official/nlp/modeling/networks/funnel_transformer.py#L452-L488","documentation":"Error \"Unexpected inputs to %s with length at %d.\" thrown in tensorflow/models.","triggerScenarios":"Thrown at official/nlp/modeling/networks/funnel_transformer.py:470 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"e006f5f0d534913e49c1f1dae87364039fa607e2","analyzedAt":"2026-08-24T14:09:15.576Z","schemaVersion":2},"datasetVersion":"2026-08-24T17:17:21.512Z"}