Inquiry Regarding Discrepancy in Phase Diagram Data from API and Web Interface

Dear Materials Project Support Team,

I hope this message finds you well. I am writing to seek assistance regarding an issue I have encountered while using the Materials Project API to generate a phase diagram for the Li-Fe-O system.
Issue Description: While utilizing the API to fetch and visualize the phase diagram, I noticed a discrepancy in the data points compared to those displayed on the Materials Project web interface. Specifically, the phase diagram generated via the API is missing the entry for Fe3O4, even though the web interface includes this point with the same stability criteria (energy above hull set to 10 meV/atom).

Reproduction Steps:

  1. I used the following code to retrieve entries and generate the phase diagram:

python

entries = mpr.get_entries_in_chemsys(elements='Li-Fe-O')
pd = PhaseDiagram(entries)
pd.get_plot(ternary_style='2d', show_unstable=10).show()
  1. The web interface was used with the same stability criteria to filter the data.
    :from api
    :from Materials Project Web.
    I am eager to resolve this issue to continue my research without any interruptions. Thank you in advance for your time and assistance. I look forward to your response.

@hmqwjf thanks for reporting this and great catch! Your code snippet in #1 (retrieving entries and generating the PD) is correct and will always be up-to-date. The web interface is trying to use internally pre-built phase diagrams that are currently out-of-date, unfortunately. We’re working on getting this fixed in the next few days. Sorry for the inconvenience and thanks for your patience.

@hmqwjf we’ve just shipped a fix for this issue. Phase diagrams on the detail pages, app, and through the API should all be consistent now. Thanks!

Thanks a lot !
Phase Diagram is same now.but there is some difference in Chemical Potential Diagram.


Thanks @hmqwjf! Could you share the exact code snippet you’re using to create the second version?

elements = ‘Li-Fe-O’
entries = mpr.get_entries_in_chemsys(elements=elements,
additional_criteria=additional_criteria)
elements_list = elements.split(‘-’)

cpd = ChemicalPotentialDiagram(entries, elements_list)
fig = cpd.get_plot()
fig.show()

@hmqwjf, what are your additional_criteria in that call to the api?