ModelSEED / ProbModelSEED

Other
2 stars 3 forks source link

get_fba (FBA Table) API Method #43

Open nconrad opened 9 years ago

nconrad commented 9 years ago

This is somewhat similar to get_model. I'm looking at a prototype here to come up with this spec: http://coremodels.mcs.anl.gov/app/#/fba/janakakbase:ATPF_Succi_aerobic/core_83333.1.fba.153

This is an opportunity to include everybody, @janakagithub, @samseaver, @jplfaria, @mdejongh.

Based on the table prototype above, we have,

{reaction_fluxes: [], exchange_fluxes, genes: [], biomass: []}

Each reaction_flux object is of the form:

{
    "name": "Carbonic acid hydro-lyase",
    "id": "rxn00102_c0",
    "flux": "0”,
    "min": -1000,
    "max": 1000,
    "lower_bound": -1000,
    "upper_bound": -1000,
    "class": 'unknown',              // I don't actually know what this is. Anybody?
    "eq": "H+[c0] + H2CO3[c0] <=> H2O[c0] + CO2[c0]",
    "def": <same thing as equation but with ids for the compounds>,
    "genes": [
        "fig|487976.3.peg.3553",
        "fig|487976.3.peg.4228",
        "fig|487976.3.peg.2871"
    ]
}

Each exchange_flux object is of the form:

{
    "id": "cpd00001_e0”,
    "name": "H2O",
    "formula": "H2O",
    "exchange_flux": "=> H2O[e]",
    "min": -1000,
    "max": 1000,
    "lower_bound": -1000,
    "upper_bound": -1000,
    "charge": 0,
}

A gene has the form:

{
    "id": "fig|29459.15.peg.1915”,
    "knocked_out": false,                   // This has never worked, as far as I know
    "growth_fraction": <some float?>
}

A compartment has the form:

{
    "id": "c0",
    "name": "Cytosol",
    "pH": 7,
    "potential": 0
}

And, biomass:

{
    "id": "bio1",
    "flux":  100,                               // Note: I don't see a value for this in core models
    "max_production",  100            // Note: I don't see a value for this in core models
    "cpd_id": "cpd00005_c0",
    "name": "NADPH",
    "coefficient": -1.8225,
}
chian commented 9 years ago

@nconrad Here's a challenge that we have been wrestling with and a very common use case for us: walking down a flux path. That is, asking where the next reaction reaction is. Where the path forks, where it cycles, etc. Can figure it mostly out through asking which reactions have the same flux value (or multiple) and which reactions are connected, but you can see where it would be handy to be able to walk from one reaction to the next in a solution.

Any point in putting in links to help along the UI with walking paths?

Sent from my iPhone

On Jul 13, 2015, at 9:34 PM, nconrad notifications@github.com wrote:

This is somewhat similar to get_model. I'm looking at a prototype here to come up with this spec: http://coremodels.mcs.anl.gov/app/#/fba/janakakbase:ATPF_Succi_aerobic/core_83333.1.fba.153

This is an opportunity to include everybody, @janakagithub, @samseaver, @jplfaria, @mdejongh.

Based on the table prototype above, we have,

{reaction_fluxes: [], exchange_fluxes, genes: [], biomass: []} Each reaction_flux object is of the form:

{ "name": "Carbonic acid hydro-lyase", "id": "rxn00102_c0", "flux": "0”, "min": -1000, "max": 1000, "lower_bound": -1000, "upper_bound": -1000, "class": 'unknown', // I don't actually know what this is. Anybody? "eq": "H+[c0] + H2CO3[c0] <=> H2O[c0] + CO2[c0]", "def": , "genes": [ "fig|487976.3.peg.3553", "fig|487976.3.peg.4228", "fig|487976.3.peg.2871" ] } Each exchange_flux object is of the form:

{ "id": "cpd00001_e0”, "name": "H2O", "formula": "H2O", "exchange_flux": "=> H2O[e]", "min": -1000, "max": 1000, "lower_bound": -1000, "upper_bound": -1000, "charge": 0, } A gene has the form:

{ "id": "fig|29459.15.peg.1915”, "knocked_out": false, // This has never worked, as far as I know "growth_fraction": <some float?> } A compartment has the form:

{ "id": "c0", "name": "Cytosol", "pH": 7, "potential": 0 } And, biomass:

{ "id": "bio1", "flux": 100, // Note: I don't see a value for this in core models "max_production", 100 // Note: I don't see a value for this in core models "cpd_id": "cpd00005_c0", "name": "NADPH", "coefficient": -1.8225, } — Reply to this email directly or view it on GitHub.

mattb112885 commented 9 years ago

Nick:

I thought about that a lot and I think all I could come up with is that it's a poorly-defined problem (amount of flux through given reactions because of stoichiometry, number of branches from other pathways, your particular choice of biomass coefficients and ATP maintenance, etc.). Remember the first algorithm we tried for autorecon and how often it would fail because of random network topology and issues with arbitrary cofactor definitions etc.? You may be able to come up with heuristics that work some percentage of the time, but don't expect them to always work.

Matt

chian commented 9 years ago

@mattb Yeah, I agree with the limitations. I was thinking about this for 'local' flow. Say I had a small circle that showed the reactions around a reaction and could orient itself according to flow. Ideally, it could identify nearby alternate paths for that flow as well and you would have an idea of what was happening in that part of the network.

Small things. Not perfect, but would help everyone get oriented I think. I can put together a lot in my head if I can just figure out which way is down to begin with.

Sent from my iPhone

On Jul 17, 2015, at 9:04 PM, mattb112885 notifications@github.com wrote:

Nick:

I thought about that a lot and I think all I could come up with is that it's a poorly-defined problem (amount of flux through given reactions because of stoichiometry, number of branches from other pathways, your particular choice of biomass coefficients and ATP maintenance, etc.). Remember the first algorithm we tried for autorecon and how often it would fail because of random network topology and issues with arbitrary cofactor definitions etc.? You may be able to come up with heuristics that work some percentage of the time, but don't expect them to always work.

Matt

— Reply to this email directly or view it on GitHub.