Questions about DEMETER

67 views
Skip to first unread message

Nicholas Y

unread,
Oct 22, 2025, 12:49:22 AMOct 22
to COBRA Toolbox
Hi,

My name is Nick, and I am using DEMETER to create genome-scale models of strains of Bifidobacteria and Lactobacillus bacteria. I have a couple of questions about using DEMETER to create these reconstructions.

1) I am running into the following issue. When I run my reconstructions on a custom diet I want to use, the biomass reactions for the final reconstructions are forced to zero. However, the biomass reactions are not forced to zero in DEMETER's built-in testing (i.e. when running runTestSuiteTools or in the results after running runDebuggingTools). I was wondering what is the best way to resolve issues like this? This issue occurs, for example, when I try to run FBA on my refined models using a breastmilk diet consisting of "Milk, human, mature, fluid (100g)" in VMH.

2) Is there a way for me to do gap filling in DEMETER on a custom pre-specified diet? I would like to run gap-filling using my custom diet (the breast milk diet mentioned above, plus some metabolites from experimental data) if possible to make sure the models can grow on it.

3) There are certain reactions in my models that I know should have nonzero flux, but which are being forced to zero. Is it possible for me to provide a list of reactions to DEMETER that I want to ensure can carry nonzero flux in the final models?

4) I want to add reactions and metabolites to my model that I know are present in my strains based on experimental data, but which are not present in the VMH database. Currently, I am translating my KBase draft models to VMH nomenclature. Then, I am adding these reactions. Finally, I am running DEMETER on the resulting translated models with the custom reactions. However, DEMETER seems to be removing the reactions and metabolites I am trying to add, which are not present in VMH. Is there a way for me to prevent DEMETER from removing these?

Thank you for your time and assistance. It is much appreciated. Please let me know if you need any more information to better answer my questions.

Best regards,
Nick Yousefi

Almut Heinken

unread,
Nov 2, 2025, 10:52:42 AMNov 2
to cobra-...@googlegroups.com
Dear Nick,
- If I understand correctly, your issue is that the models cannot grow on your diet after the DEMETER run. If you want to use a certain medium in DEMETER, you can do that through the GrowthRequirements input data. Basically, you have to set all metabolites that are not in the diet to -1, and all metabolites in the diet to 0 (or 1 if you know they are required). You may also have to add some minerals to your diet, or remove them from the biomass manually if you know they are not required.
Regarding reactions that should carry flux: I am afraid you will have to do manual gap-filling in these cases, unless these are pathways that are already implemented in DEMETER such as carbon sources or fermentation pathways (in which case you can add them through the experimental data files).
- You can prevent DEMETER from removing reactions by giving them a gene annotation. If the reaction does not have a gene rule, DEMETER will assume it was automatically gap-filled by KBase and remove it if it is not needed for biomass.
I hope that helps.
Best regards,
Almut

--

---
You received this message because you are subscribed to the Google Groups "COBRA Toolbox" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cobra-toolbo...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/cobra-toolbox/88d43ef1-1ccf-4274-8ffa-dc7cb19e079dn%40googlegroups.com.

Nicholas Y

unread,
Nov 5, 2025, 11:37:39 AMNov 5
to COBRA Toolbox
Dear Almut,

Thank you very much for your reply. Your suggestions are very helpful.

I have another question about ensuring certain reactions carry nonzero flux. Another approach I was considering was to set the reaction I expect to carry flux as the objective function and then do gap filling in DOE KBase. For example, let's say I want the reaction Lacto-N-Triose II → Lactose + GlcNAc to carry flux. I would set it as the objective function and run gap filling in KBase. The idea behind this is that these pipelines try to ensure the biomass reaction carries nonzero flux, so by setting a certain reaction as the "biomass reaction", the pipeline will ensure it carries nonzero flux.

I was wondering what are your thoughts on this approach. Does it sound reasonable?

If this is not a reasonable approach, would you be able to provide some guidance on how to do the gap filling manually? It would be great to have your insights on this. Thank you!

Best regards,
Nick Yousefi

Almut Heinken

unread,
Nov 6, 2025, 6:47:33 AMNov 6
to cobra-...@googlegroups.com
Dear Nicholas,
if you want to include a specific pathway, I suggest doing the gapfilling manually based on experimental evidence, and then check if the reactions carry flux. It is easiest to do this after the DEMETER run.
It seems you want to include human milk oligosaccharide degradation reactions. I already reconstructed this pathway, so you can use that as guidance. You can find the reactions and metabolites in the supplemental material here:
I hope that helps.
Best regards,
Almutify


Nicholas Y

unread,
Nov 13, 2025, 5:53:49 PMNov 13
to COBRA Toolbox
Dear Almut,

Thank you so much for pointing me to your paper with the script to add the HMO reactions. That really helps!

I have a couple of follow up questions about making sure models grow on a certain diet. I tried setting all the metabolites that were not in the diet to -1 and setting metabolites that were in the diet to 0 for all my models like you suggested, but when I ran DEMETER all my models carried zero biomass flux. Am I misunderstanding how I should handle this? Should I leave any parts of the GrowthRequirements file as the default or should I override the entire file with whether or not the metabolites are in my diet?

I was also wondering if you could clarify the difference between setting metabolites to 0 and 1 in the GrowthRequirements file. You mentioned earlier that I should set them to 1 if "I know they are required." What exactly does setting them to 0 vs. 1 mean in terms of how DEMETER interprets them?

I was also wondering if I am able to add columns to the GrowthRequirements file for metabolites that are not in there by default? For example, my diet contains the exchange reaction EX_actn_R(e) for (R)-Acetoin, but the GrowthRequirements table does not contain a column for this compound. Can I add a column for this compound to the table, and if so, how can I determine what the column name should be so that it works with DEMETER?

Lastly, I noticed that for one of my organisms, it seems like default experimental data are not being generated by DEMETER. The organism in question is a proprietary strain of Lactobacillus rhamnosus. I have input all the taxonomic info as it is written in a Virtual Metabolic Human entry for this species. However, the experimental data generated by DEMETER for this organism contains all zeros. For my other models, I have also done this and it seems to be able to generate experimental data that does not consist of all zeros. I have already confirmed that the MicrobeID for this organism exactly matches the file name of the KBASE draft model, minus the file extension. Is there anything else I can check in terms of formatting my taxon info file to ensure DEMETER is properly able to find experimental data for this strain (e.g. capitalization, data sources for the taxonomic info, etc.)?

Thank you for taking the time to assist me with this. It is very helpful.

Best regards,
Nick Yousefi

Almut Heinken

unread,
Nov 19, 2025, 4:44:35 PM (14 days ago) Nov 19
to cobra-...@googlegroups.com
Hi Nick,
you should add a '1' in the GrowthRequirements table if the organism is known to be auxotrophic for the metabolite. Otherwise, add a 0.
Unfortunately, I can't say for sure why the models cannot grow. Did you still include metals and other metabolites not accounted for by the Demeter algorithm in the simulated medium?
It will not be possible to add new metabolites in the grrowth requirements curation without also modifying the function performing the curation against growth requirements. The function gap-fills or removes reactions as needed to account for the growth requirement (or lack of it).
Regarding Lactobacillus rhamnosus: the taxonomic information in your input file needs to be spelled exactly as in the AGORA2_infoFile table (current version in the COBRA Toolbox). Some genus names have changed recently.
I hope that helps,
best regards,
Almut


Nicholas Y

unread,
Nov 27, 2025, 12:32:21 AM (6 days ago) Nov 27
to COBRA Toolbox
Hi Almut,

Thank you very much for your reply. Your suggestions were very helpful. I was able to successfully get my models to grow on the diet.

I also had a question regarding the paper you mentioned, in which you added HMO reactions to the models. After adding the HMO reactions, did you run FBA on the models to see if the HMO reaction pathways carried nonzero flux? I adapted and ran your script to add HMO pathways to my models, and I ran FBA on the models with my diet, yet many of the HMO pathway reactions had fluxes of zero. 

I did some tests in which for each HMO, I tried growing the models on a diet consisting only of that HMO and essential metabolites, and I was able to get the models to grow using each HMO individually as a carbon source, so I know the pathways don't have gaps. Additionally, the biomass fluxes when using each individual HMO as a carbon source were the same as when using the full diet. I was wondering if, when you were simulating these models, you tried modifying the diet or doing anything to force the HMO pathways to carry positive flux when FBA was run. If so, would you please be able to explain or describe what you did?

Thank you very much for your time.

Best regards,
Nick Yousefi

Almut Heinken

unread,
Nov 27, 2025, 4:53:53 AM (6 days ago) Nov 27
to cobra-...@googlegroups.com
Hi Nick,
since the HMO reactions could clearly carry flux and support biomass growth in principle, it seems they just did not have flux in that particular FBA solution. You could use FVA instead to get alternative solutions.
Since you are getting the same biomass with full diet and just HMOs, it also seems that another compound is limiting biomass growth so the HMOs cannot add anything. That could also explain why they are not used in every solution.
Best regards,
Almut

Nicholas Y

unread,
11:24 AM (26 minutes ago) 11:24 AM
to COBRA Toolbox
Hi Almut,

Thank you so much for your replies and assistance! Your suggestions were very helpful, and I was able to get my models finalized. I really appreciate you taking the time to assist me and answer my questions.

Best regards,
Nick Yousefi

Reply all
Reply to author
Forward
0 new messages