code: def test_model_dkn(deeprec_resource_path):
      data_path = os.path.join(deeprec_resource_path, "dkn")
      yaml_file = os.path.join(data_path, r"dkn.yaml")
      train_file = os.path.join(data_path, r"train_mind_demo.txt")
      valid_file = os.path.join(data_path, r"valid_mind_demo.txt")
      news_feature_file = os.path.join(data_path, r"doc_feature.txt")
      user_history_file = os.path.join(data_path, r"user_history.txt")
      wordEmb_file = os.path.join(data_path, r"word_embeddings_100.npy")
      entityEmb_file = os.path.join(
          data_path, r"TransE_entity2vec_100.npy"
      )
      contextEmb_file = os.path.join(
          data_path, r"TransE_context2vec_100.npy"
      )
  
      download_deeprec_resources(
          "https://recodatasets.z20.web.core.windows.net/deeprec/",
          data_path,
          "mind-demo.zip",
      )
  
      hparams = prepare_hparams(
          yaml_file,
          news_feature_file=news_feature_file,
          user_history_file=user_history_file,
          wordEmb_file=wordEmb_file,
          entityEmb_file=entityEmb_file,
          contextEmb_file=contextEmb_file,
          epochs=1,
          learning_rate=0.0001,
      )
      input_creator = DKNTextIterator
      model = DKN(hparams, input_creator)
  
      assert isinstance(model.fit(train_file, valid_file), BaseModel)
      assert model.run_eval(valid_file) is not None
  
file_path: recommenders/tests/smoke/recommenders/recommender/test_deeprec_model.py
imports: import os
  import pytest
  from recommenders.datasets import movielens
  from recommenders.datasets.python_splitters import python_stratified_split
label_desc: Use image node_id 3 for calling a global function with example usage: test_model_dkn(deeprec_resource_path) without return types