Skip to content

Commit becb0ab

Browse files
authored
Koina libraries are identified by the "Koina-" prefix in SpectrumSourceFiles.fileName column value. (#460)
1 parent 3507a86 commit becb0ab

File tree

1 file changed

+14
-5
lines changed

1 file changed

+14
-5
lines changed

panoramapublic/src/org/labkey/panoramapublic/model/validation/SpecLibValidation.java

Lines changed: 14 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
package org.labkey.panoramapublic.model.validation;
22

3+
import org.apache.commons.lang3.StringUtils;
34
import org.jetbrains.annotations.NotNull;
45
import org.jetbrains.annotations.Nullable;
56
import org.labkey.panoramapublic.model.speclib.SpecLibInfo;
@@ -197,7 +198,7 @@ public String getStatusString()
197198
}
198199
if (isPrositLibrary())
199200
{
200-
return "Prosit Library";
201+
return "Prosit / Koina Library";
201202
}
202203
if (hasSpectrumFiles() && foundSpectrumFiles() && hasIdFiles() && foundIdFiles())
203204
{
@@ -301,12 +302,20 @@ public List<String> getMissingIdFileNames()
301302

302303
public boolean isPrositLibrary()
303304
{
304-
// For a library based on Prosit we expect only one row in the SpectrumSourceFiles table,
305-
// We expect idFileName to be blank and the value in the fileName column to be "Prositintensity_prosit_publication_v1".
306-
// The value in the fileName column may be different in Skyline 21.1. This code will be have to be updated then.
305+
// For a library based on Prosit/Koina we expect only one row in the SpectrumSourceFiles table,
306+
// We expect idFileName to be blank.
307+
// The value in the fileName column is "Prositintensity_prosit_publication_v1" for versions of Skyline that built
308+
// the library using the legacy Prosit server.
309+
// Skyline switched from Prosit to the new Koina framework (https://github.com/ProteoWizard/pwiz/pull/2900).
310+
// Skyline now prefixes "Koina-" to the model names in the SpectrumSourceFiles.fileName column.
311+
// For example: Koina-Prosit_2020_intensity_HCD-Prosit_2019_irt where
312+
// Prosit_2020_intensity_HCD is the intensity model and Prosit_2019_irt is the retention time model. Skyline
313+
// supports multiple Koina models.
307314
if(isBibliospecLibrary() && getSpectrumFiles().size() == 1 && getIdFiles().size() == 0)
308315
{
309-
return "Prositintensity_prosit_publication_v1".equals(getSpectrumFiles().get(0).getName());
316+
String modelName = getSpectrumFiles().get(0).getName();
317+
return "Prositintensity_prosit_publication_v1".equals(modelName)
318+
|| StringUtils.startsWith(modelName, "Koina-");
310319
}
311320
return false;
312321
}

0 commit comments

Comments
 (0)