torchcell.metabolism.media.ExchangeIndex
- class ExchangeIndex(*, model_id: str, by_annotation: dict[str, str] = <factory>, by_name: dict[str, str] = <factory>, metabolite_of: dict[str, tuple[str, str]] = <factory>)[source]
Bases:
ModelStrictLookup tables built once from a model’s exchange reactions.
Built from what the MODEL declares (its annotations and its metabolite names), which is what keeps the mapping organism-agnostic: no yeast reaction id appears anywhere in this module, and the same index construction runs on any cobra model.
- model_config: ClassVar[ConfigDict] = {'extra': 'forbid', 'frozen': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].