Skip to content

Commit

Permalink
Use agent instead of reagent
Browse files Browse the repository at this point in the history
  • Loading branch information
FanwangM committed Sep 21, 2023
1 parent 205106c commit e121b40
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions ord_schema/message_helpers.py
Original file line number Diff line number Diff line change
Expand Up @@ -385,7 +385,7 @@ def get_reaction_smiles(
if not generate_if_missing:
return None

reactants, reagents, products = set(), set(), set()
reactants, agents, products = set(), set(), set()
roles = reaction_pb2.ReactionRole
for key in sorted(message.inputs):
for compound in message.inputs[key].components:
Expand All @@ -396,7 +396,7 @@ def get_reaction_smiles(
continue
raise error
if compound.reaction_role in [roles.REAGENT, roles.SOLVENT, roles.CATALYST]:
reagents.add(smiles)
agents.add(smiles)
elif compound.reaction_role == roles.REACTANT:
reactants.add(smiles)
else:
Expand Down Expand Up @@ -425,7 +425,7 @@ def get_reaction_smiles(
raise ValueError("reaction contains no valid reactants or products")
components = [
".".join(sorted(reactants)),
".".join(sorted(reagents)),
".".join(sorted(agents)),
".".join(sorted(products)),
]
reaction_smiles = ">".join(components)
Expand Down

0 comments on commit e121b40

Please sign in to comment.