Skip to content

Create standardised intermediate files #1256

Closed

Description

@ewels

Every now and then, someone runs MultiQC on two sets of files and then wants to generate a combined report from those two runs without accessing the original log files. This isn't really possible currently - MultiQC does parsing and reporting in one go.

The suggestion here is that MultiQC could create structured Custom Content files at the point of report generation. There would be one file per report subsection and if we use the full YAML structured version we should be able to capture pretty much everything. We might also need to make a multiqc_config.yaml file to maintain report-level stuff and order of sections.

If all of these files are spat into a directory, in theory anyone could then run MultiQC in that directory in the future and get pretty much the same report. It would also allow stepwise log parsing by MultiQC with a final aggregate reporting step.

This could be a step in the direction towards a standardised reporting file structure, as suggested by @nsheff

Activity

  1. apeltzer commented on Jul 21, 2020

    @apeltzer
    Contributor

    Like the idea! Also having the possibility to just "extend" a current report when new samples are arriving in a project is cool :-)

  2. added this to the MultiQC v2.0 milestone on Oct 30, 2022
  3. modified the milestones: v1.24, v1.25 on Jul 30, 2024
  4. modified the milestones: v1.25, v1.26 on Sep 9, 2024
  5. modified the milestones: v1.26, v1.27 on Dec 10, 2024
  6. 3 remaining items

  7. ewels commented on Apr 22, 2025

    @ewels
    MemberAuthor

    Hi @apeltzer / anyone else! We just merged some tentative support for Parquet data formats here: #3118

    We're curious about what folks think of our approach for data format and architecture - any feedback you have would be welcome! At the moment it's a single Parquet file with many columns and integrated metadata, we've bounced back and forth between this and an approach of having one file per plot (many files). Feedback welcome!

  8. ewels commented on Apr 22, 2025

    @ewels
    MemberAuthor

    Maybe @jchorl you might have some thoughts about it, possibly also @multimeric?

  9. jchorl commented on Apr 22, 2025

    @jchorl
    Contributor

    Oh, this is neat!

    Is your primary use-case re-running multiqc on processed data, or dumping multiqc data into a data warehouse, or other?

  10. ewels commented on Apr 22, 2025

    @ewels
    MemberAuthor

    Is your primary use-case re-running multiqc on processed data, or dumping multiqc data into a data warehouse

    Both of the above!

  11. jchorl commented on Apr 23, 2025

    @jchorl
    Contributor

    Got it! I do have some thoughts.

    • Performance-wise, I have seen some challenges with multiqc writing out jsons to disk of massive datasets. I'm not sure if parquet replaces that logic or not. I think I omitted the data or sampled it to resolve. Obviously JSON is inefficient for highly repetitive columnar data. I know I could also just turn off the JSON export but there are rare cases where I need to grab data from it so I haven't done that.
    • Re: rerunning, I think this is valuable but it's difficult to express constraints and wants. As a concrete example, I typically run multiqc twice, once to generate a full report and once with some sections stubbed out (e.g. a 1000 row table doesn't print well, so I stub it out). Incrementally re-running multiqc would need to hash the data or similar to intelligently know whether precomputed data can be reused. Any config changes impacting the data would need to break that cache. I've seen quirks with running multiqc twice - the latest came yesterday where some config fields don't get cleared between runs. It would be useful to cache/reuse AI calls because those get expensive. In summary - could be very valuable if executed with a lot of configuration and guaranteed correctness.
    • Re: export, I also think this is valuable. I typically export data upstream of multiqc. The reason is that I generate more, higher-fidelity data than is included in reports. There are probably very specific charts that I could dump as-is into a data warehouse. I think of multiqc as a report generation framework/application, not a full-blown ETL. It would be difficult to justify pumping lots more data into multiqc and convincing it to adequately filter/transform just to use an exports feature. There's also quirks where some custom content formatted for multiqc has html embedded, e.g. bold/italic. That would be weird to export into a data warehouse.

    This is all to say - I think these features will be very valuable, but with a lot of care. I haven't yet put my finger on exactly how I'd use them yet.

  12. alexiswl commented on Apr 24, 2025

    @alexiswl
    Contributor

    Keen to follow this discussion too!

    So long as the parquet format is consistent then a user can impute their own metadata of an analysis into a merged parquet file or database later on. I've been reluctant to scrape data from multiqc jsons due to risk of inconsistencies between versions or even slightly different invocations of a workflow for this reason.

    An unintended consequence may be that users would want more qc data than what is displayed within the HTML in their parquet file (for big data analytics) so there might be more PRs for ingestion that aren't relevant to the final html but purely for the parquet alone.

  13. multimeric commented on Apr 29, 2025

    @multimeric

    This is a great idea. Once this is stabilised and released then I can update TidyMultiqc to use the parquet instead of JSON.

    Can I ask how the data is being represented though? I thought some of the JSON was nested in such a way that parquet can't represent it. Also, is the plot data included directly, or is it just possible to calculate the plot data from the parquet?

  14. ewels commented on Apr 29, 2025

    @ewels
    MemberAuthor

    Thanks for the feedback all!

    • a 1000 row table doesn't print well, so I stub it out

    That's what a beeswarm plot is for! You must have configured MultiQC to not do that, as it should be switching by default 😉

    Other stuff @jchorl - really great points for us to think about. I think many will be difficult probably the point of being unsolvable in a generalisable practical sense for us, but it's nice to have them on the radar 😅

    @alexiswl - agreed, in fact I'm pretty sure that there is an issue lying around somewhere for exactly this, to ingest data purely to push it through to MegaQC. That said, if the data format we end up with is sane enough, it might be enough to just have the standard and have other tooling publish data in the same way and not need to go through MultiQC..

    @multimeric - We're essentially trying to figure out the answers to those questions at the moment... I think that there will be a lot of movement in the Parquet format for a while whilst we test out various ideas and try to stress test / find edge cases. Suggestions welcome!

  15. ahstram commented on Jul 10, 2025

    @ahstram

    Hi @ewels,

    I meant to comment on this thread earlier... I was just in a call with Evan Floden & mentioned that the ability for MultiQC to create intermediate files is very valuable functionality to us at Personalis.

    Our bioinformatics pipelines only do "single sample analysis", and are often delivered to customers individually, and therefore our MultiQC reports only contain single samples in them. If a customer orders N samples, they will thus receive N individual MultiQC reports, often delivered independently at different times, with no aggregation.

    Since we generally don't do multi-sample analysis or aggregation ourselves, the intermediate file functionality would be great in that we could deliver N intermediate files to the customer over some time frame, and the customer could then use these intermediate files to aggregate into a single MultiQC report, either the N samples, or even a subset or superset of N (i.e., removing failing or control samples, or even adding samples from other studies, etc).

    I'll try and take a look at the current implementation soon & provide any feedback I have.

    Alexander Stram
    Director, Bioinformatics Engineering
    Personalis, Inc

  16. ewels commented on Jul 11, 2025

    @ewels
    MemberAuthor

    Great stuff! Glad to hear that it'll be useful :) Docs are here, but it should basically "just work". Would love to hear how you get on!

  17. ahstram commented on Jul 18, 2025

    @ahstram

    Hi @ewels , that's great to hear!

    I've done some testing of the multi-sample aggregation using multiple individual sample parquet files and everything is functioning as expected!

    Do you reckon that the multiQC intermediate parquet file format is stable, and future versions of multiQC will be able to support the parquet files generated by v1.30?

    Ask because MultiQC currently puts "BETA" in the filename (and similarly, the functionality is listed as "beta" in the release notes).

    We're considering beginning to deliver intermediate parquet files generated by v1.30 to customers (with "BETA" removed from the filename), but want to ensure that the format is stable before doing so, as it may create a headache if future versions are incompatible.

    Thank you,

    Alexander Stram
    Director, Bioinformatics Engineering
    Personalis, Inc

  18. vladsavelyev commented on Jul 21, 2025

    @vladsavelyev
    Contributor

    Hi @ahstram, even though we already released 1.30, we haven't yet removed the BETA- from the file name. But in fact the intermediate format is stable now and we are not planning to change it in the future, so we will likely make a patch release soon and remove -BETA.

  19. ahstram commented on Jul 23, 2025

    @ahstram

    @vladsavelyev , great, thank you for confirming! We will likely begin delivering these intermediate files to customers, with BETA- stripped from the filename soon!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions