INCHI_MAIN(1)
π INCHI_MAIN(1) π
okay bestie, gather round, because today we're learning inchi_main(1) β the InChI library call example that runs on the classic API. yes the classic one. she's vintage, she's reliable, she slays.
β¨ NAME β¨
inchi_main β InChI library call example, classic API. that's the whole vibe. no notes.
π SYNOPSIS π
inchi_main inputFile [outputFile [logFile [problemFile]]] [-option[-option...]]
so likeβ¦ you give her an inputFile (mandatory, she's not optional about it π
), and then everything else is just vibes and brackets. outputFile, logFile, problemFile β all optional, all snuggled inside each other like nesting dolls. and then your -options. as many as you want, back to back, no spaces needed. go off queen.
π OPTIONS π
π₯ Input
this is where your data comes IN, obviously. the entrance. the red carpet.
STDIOβ use standard input/output streams. pipes and vibes only, no files required.InpAuxβ input structures arrive in the InChI default aux. info format. note: this one's for use withSTDIO, so they're a package deal, iykyk.SDF:DataHeaderβ when reading from an input SDfile, grab the ID sitting under thisDataHeader. she reads the label, not the tea.START:nβ start at the n-th input structure. skip the intro, we're jumping straight into the plot.END:nβ stop after the n-th input structure. that's a wrap, everyone go home.RECORD:nβ treat ONLY the n-th input structure. one and done. main character energy, no ensemble cast.
π€ Output
what she gives back. her little gifts to you π
NoLabelsβ omit the structure number, theDataHeader, and the ID from the InChI output. anonymous. mysterious. iconic.NoWarningsβ suppress all warning messages. (the warnings are still happening, she's just not telling you π)AuxNoneβ omit auxiliary information entirely.SaveOptβ save custom InChI creation options, aka non-standard InChI. she remembers what you asked for β¨Tabbedβ separate the structure number, the InChI, and the AuxInfo with tabs. clean columns, immaculate presentation.MergeHashβ combine the InChIKey with extra hash(es) if present.NoInChIβ do NOT print the InChI string itself. wild, I know, it's literally in the name of the program. she contains multitudes.OutputSDFβ convert an InChI created with default aux. info to an SDfile.SdfAtomsDTβ output Hydrogen Isotopes to the SDfile as AtomsDandT.
π Structure perception
how she sees your molecules. reading them. understanding them. basically therapy but for atoms.
SNonβ exclude stereo. (default: include absolute stereo.)NEWPSOFFβ both ends of the wedge point to stereocenters. (default: a narrow end.)LooseTSACheckβ relax the criteria for ambiguous drawing when it comes to in-ring tetrahedral stereo. be cool about it.DoNotAddHβ all H are explicit. (default: add H according to usual valences.)
π§ Stereo perception modifiers (non-standard InChI)
okay so these ones are the non-standard InChI girlies. she's off-script and she's thriving.
SRelβ relative stereo.SRacβ racemic stereo.SUCFβ use the Chiral Flag:Onmeans Absolute stereo,Offmeans Relative.
πΈ Customizing InChI creation (non-standard InChI)
more non-standard behavior. she's customizing. she's building her own lore.
SUUβ always include omitted unknown/undefined stereo. no more hiding.SLUUDβ make the labels for unknown and undefined stereo different from each other. yes they were the same before, yes it was confusing.RecMetβ include reconnected metals results.FixedHβ include the Fixed H layer.KETβ account for keto-enol tautomerism. (experimental!)15Tβ account for 1,5-tautomerism. (experimental!)PT_22_00β account forPT_22_00tautomerism. (experimental!)PT_16_00β account forPT_16_00tautomerism. (experimental!)PT_06_00β account forPT_06_00tautomerism. (experimental!)PT_39_00β account forPT_39_00tautomerism. (experimental!)PT_13_00β account forPT_13_00tautomerism. (experimental!)PT_18_00β account forPT_18_00tautomerism. (experimental!)
okay so heads up bestie: every single one of those tautomerism options is marked experimental. that word is doing a LOT of work. treat accordingly π₯
βοΈ Generation
the actual making of the thing. the birth of the InChI. scream, cry, throw up π
Wnumberβ set the time-out per structure in seconds.W0means unlimited. (unlimited!! she'll wait forever. romantic.)WMnumberβ set the time-out per structure in milliseconds (int).WM0means unlimited.LargeMoleculesβ treat molecules up to 32766 atoms. (experimental!)WarnOnEmptyStructureβ warn and produce an empty InChI for an empty structure. she'll tell you, but she'll still do it.Polymersβ allow processing of polymers. (experimental!)Polymers105β allow processing of polymers. (experimental, and it's the legacy mode of v. 1.05 β vintage mode, quite demure of her.)FoldCRUβ fold the polymer CRU if inner repeats occur.NoFrameShiftβ disable the polymer CRU frame shift.NoEditsβ disable the polymer CRU frame shift AND the folding. all of it. gone.NPZzβ allow non-polymer-relatedZzatoms (those are pseudo element placeholders, fyi).SAtZzβ allow stereo at atoms connected toZz. (default: disabled.)Keyβ generate the InChIKey. the moment we've all been waiting for π₯XHash1β generate a hash extension (up to 256 bits) for the 1st block of the InChIKey.XHash2β generate a hash extension (up to 256 bits) for the 2nd block of the InChIKey.
π Conversion
she's flexible. she can be something else. metamorphosis, but chemistry.
InChI2Structβ test mode:Mol/SDfileβInChIβ Structure β (InChI+AuxInfo). a whole round trip. a journey. she left and came back changed βοΈInChI2InChIβ Convert ConvertInChIstring(s) intoInChIstring(s). (the doubled-up "Convert" is her little typo and we love her for it, no cap π«Ά)
π¦ that's the whole page π¦
no SEE ALSO, no environment variables, no exit statuses, no examples β she said "keep it simple, keep it iconic." literally nothing else. that's the tea.
fr fr though: every option above is exactly as listed, nothing merged, nothing invented, nothing skipped. 40-something options and we did them ALL. we ate. π
peace out bestie, and happy structure parsing, your girl INCHI_MAIN(1) πβ¨π
source/version:INCHI_MAIN(1)β dated01/15/2026. that's the fine print, and she's serving it with a bow. π
π¦ where this page comes from
- ubuntu resolute: libinchi-bin 1.07.3+dfsg-2 Β· MIT
- ubuntu stonking: libinchi-bin 1.07.3+dfsg-2 Β· MIT
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms