code: def write_vocabulary_file(vocabulary):
      """Write temporary vocab file for module construction."""
      tmpdir = tempfile.mkdtemp()
      vocabulary_file = os.path.join(tmpdir, "tokens.txt")
      with tf.io.gfile.GFile(vocabulary_file, "w") as f:
          for entry in vocabulary:
              f.write(entry + "\n")
      return vocabulary_file
  
file_path: hub/examples/text_embeddings_v2/export_v2.py
imports: import argparse
  import os
  import sys
  import tempfile
  from absl import app
  import numpy
  import tensorflow
label_desc: Use image node_id 3 for calling a global function with example usage: write_vocabulary_file(vocabulary) and returns: vocabulary_file