Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use a narrative template file to stub out a date-specific narrative for a given set of dated builds #163

Open
Tracked by #130
huddlej opened this issue May 13, 2024 · 0 comments

Comments

@huddlej
Copy link
Contributor

huddlej commented May 13, 2024

Avoid the need to update all URLs and the YAML front matter in the narrative to the date of the latest builds. We could define our own simple narrative template or use a standard template language like Jinja2. We could generate the stubbed narrative as part of the build and deploy process above, such that the date of the builds is available to plug into the template, and deploy the dated draft of the narrative along with the builds.

Parts of the current report that need to be templated include:

  • title in the Markdown frontmatter (Nextstrain seasonal influenza report for April 2024 -> Nextstrain seasonal influenza report for {long month} {year})
  • date for the report (same as date of the build, April 15, 2024 -> {long month} {day}, {year}) in the frontmatter
  • dataset URLs with date in the dataset and month/year filter in the URL params (https://nextstrain.org/groups/nextflu-private/flu/seasonal/2024-04-11/h1n1pdm/2y/ha?c=gt-HA1_120,216&d=tree,map,frequencies&f_year_month=2023-10,2023-11,2023-12,2024-01,2024-02,2024-03,2024-04&gmax=1052&gmin=72&label=clade:5a.2a&p=grid)
  • counts of recent submissions per clade (generated in separate Markdown files by the workflow)
  • tables of derived haplotype frequencies and titer references (generated in separate Markdown files by the workflow)
@huddlej huddlej mentioned this issue May 13, 2024
12 tasks
@huddlej huddlej changed the title Use a narrative template file to stub out a date-specific narrative for a given set of dated builds. Avoid the need to update all URLs and the YAML front matter in the narrative to the date of the latest builds. We could define our own simple narrative template or use a standard template language like Jinja2. We could generate the stubbed narrative as part of the build and deploy process above, such that the date of the builds is available to plug into the template, and deploy the dated draft of the narrative along with the builds. Use a narrative template file to stub out a date-specific narrative for a given set of dated builds May 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant