code: def _init_modeldef(notebook_path, model_name, op_name):
      data = [
          {
              "model": model_name,
              "operations": {
                  op_name: {
                      "main": f"guild.plugins.nbexec {_path_for_main_spec(notebook_path)}",
                      "flags": _flags_data_for_notebook(notebook_path),
                  }
              },
          }
      ]
      gf = guildfile.Guildfile(data, dir=os.path.dirname(notebook_path))
      return gf.models[model_name]
  
imports: import ast
  import json
  import logging
  import os
  import re
  from guild import config
  from guild import guildfile
  from guild import model
  from guild import plugin
  from guild import python_util
  from guild import util
  from .None import flags_import_util
label_desc: Use image node_id 7 for calling a global function with example usage: _init_modeldef(notebook_path, model_name, op_name) and returns: gf