Skip to content

Instantly share code, notes, and snippets.

@a-lakhanpal
Forked from hamletbatista/t5_config_yaml.py
Created July 13, 2021 05:37
Show Gist options
  • Select an option

  • Save a-lakhanpal/83be5caa48ac71dbd8248ec7f54e5fdb to your computer and use it in GitHub Desktop.

Select an option

Save a-lakhanpal/83be5caa48ac71dbd8248ec7f54e5fdb to your computer and use it in GitHub Desktop.
yaml_config="""
input_features:
-
name: Original_Title
type: text
level: word
encoder: t5
reduce_output: null
-
name: Keyword
type: text
level: word
tied_weights: Original_Title
encoder: t5
reduce_output: null
output_features:
-
name: Optimized_Title
type: sequence
level: word
decoder: generator
"""
with open("config.yaml", "w") as f:
f.write(yaml_config)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment