asciichem-model 0.3.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (78) hide show
  1. checksums.yaml +7 -0
  2. data/LICENSE +21 -0
  3. data/README.adoc +80 -0
  4. data/docs/adr/0001-language-bindings.adoc +78 -0
  5. data/exe/generate-types-from-schemas +6 -0
  6. data/lib/asciichem_model/schema_type_generator.rb +163 -0
  7. data/lib/asciichem_model/validators.rb +79 -0
  8. data/lib/asciichem_model/version.rb +5 -0
  9. data/lib/asciichem_model.rb +18 -0
  10. data/models/asciichem/Atom.lutaml +49 -0
  11. data/models/asciichem/Bond.lutaml +24 -0
  12. data/models/asciichem/Calculation.lutaml +34 -0
  13. data/models/asciichem/Crystal.lutaml +34 -0
  14. data/models/asciichem/ElectronConfiguration.lutaml +35 -0
  15. data/models/asciichem/EmbeddedMath.lutaml +10 -0
  16. data/models/asciichem/Formula.lutaml +13 -0
  17. data/models/asciichem/Group.lutaml +22 -0
  18. data/models/asciichem/Identifier.lutaml +56 -0
  19. data/models/asciichem/Mechanism.lutaml +22 -0
  20. data/models/asciichem/Molecule.lutaml +25 -0
  21. data/models/asciichem/Name.lutaml +15 -0
  22. data/models/asciichem/Provenance.lutaml +20 -0
  23. data/models/asciichem/Reaction.lutaml +36 -0
  24. data/models/asciichem/ReactionCascade.lutaml +6 -0
  25. data/models/asciichem/Spectrum.lutaml +31 -0
  26. data/models/asciichem/SubstanceRecord.lutaml +52 -0
  27. data/models/asciichem/Text.lutaml +9 -0
  28. data/models/asciichem/ZMatrix.lutaml +34 -0
  29. data/schemas/v1/atom.yaml +45 -0
  30. data/schemas/v1/bond.yaml +20 -0
  31. data/schemas/v1/calculation.yaml +37 -0
  32. data/schemas/v1/crystal.yaml +30 -0
  33. data/schemas/v1/electron-configuration.yaml +43 -0
  34. data/schemas/v1/embedded-math.yaml +18 -0
  35. data/schemas/v1/examples/01-atom-isotope.yaml +7 -0
  36. data/schemas/v1/examples/02-molecule-water.yaml +18 -0
  37. data/schemas/v1/examples/03-group-multiplicity.yaml +11 -0
  38. data/schemas/v1/examples/04-reaction-conditions.yaml +30 -0
  39. data/schemas/v1/examples/05-substance-record-aspirin.yaml +40 -0
  40. data/schemas/v1/examples/06-electron-configuration.yaml +16 -0
  41. data/schemas/v1/examples/07-spectrum.yaml +18 -0
  42. data/schemas/v1/examples/99-01-negative-atom-bad-element.yaml +5 -0
  43. data/schemas/v1/examples/99-02-negative-identifier-bad-convention.yaml +5 -0
  44. data/schemas/v1/examples/99-03-negative-group-empty.yaml +4 -0
  45. data/schemas/v1/formula.yaml +30 -0
  46. data/schemas/v1/group.yaml +29 -0
  47. data/schemas/v1/identifier.yaml +32 -0
  48. data/schemas/v1/mechanism.yaml +30 -0
  49. data/schemas/v1/molecule.yaml +28 -0
  50. data/schemas/v1/name.yaml +22 -0
  51. data/schemas/v1/provenance.yaml +28 -0
  52. data/schemas/v1/reaction-cascade.yaml +17 -0
  53. data/schemas/v1/reaction.yaml +34 -0
  54. data/schemas/v1/spectrum.yaml +39 -0
  55. data/schemas/v1/substance-record.yaml +57 -0
  56. data/schemas/v1/text.yaml +16 -0
  57. data/schemas/v1/types/atom.ts +12 -0
  58. data/schemas/v1/types/bond.ts +5 -0
  59. data/schemas/v1/types/calculation.ts +13 -0
  60. data/schemas/v1/types/crystal.ts +13 -0
  61. data/schemas/v1/types/electron-configuration.ts +13 -0
  62. data/schemas/v1/types/embedded-math.ts +5 -0
  63. data/schemas/v1/types/formula.ts +5 -0
  64. data/schemas/v1/types/group.ts +7 -0
  65. data/schemas/v1/types/identifier.ts +7 -0
  66. data/schemas/v1/types/index.ts +21 -0
  67. data/schemas/v1/types/mechanism.ts +9 -0
  68. data/schemas/v1/types/molecule.ts +7 -0
  69. data/schemas/v1/types/name.ts +7 -0
  70. data/schemas/v1/types/provenance.ts +8 -0
  71. data/schemas/v1/types/reaction-cascade.ts +5 -0
  72. data/schemas/v1/types/reaction.ts +11 -0
  73. data/schemas/v1/types/spectrum.ts +14 -0
  74. data/schemas/v1/types/substance-record.ts +18 -0
  75. data/schemas/v1/types/text.ts +5 -0
  76. data/schemas/v1/types/zmatrix.ts +13 -0
  77. data/schemas/v1/zmatrix.yaml +41 -0
  78. metadata +136 -0
@@ -0,0 +1,18 @@
1
+ # 07 — Spectrum with peaks (negative example files follow in 99-*)
2
+
3
+ # An NMR record: technique, acquisition parameters, peaks with
4
+ # assignments.
5
+ type: spectrum
6
+ technique: nmr
7
+ params:
8
+ solvent: CDCl3
9
+ frequency: "400 MHz"
10
+ peaks:
11
+ - position: "2.1"
12
+ intensity: "3H"
13
+ multiplicity: s
14
+ assignment: CH3
15
+ - position: "7.3"
16
+ intensity: "1H"
17
+ multiplicity: t
18
+ assignment: ArH
@@ -0,0 +1,5 @@
1
+ # NEGATIVE 99-01 — atom with a malformed element symbol.
2
+ # Must FAIL validation against atom.yaml (pattern ^[A-Z][a-z]?$;
3
+ # "HX" has an uppercase second letter, which no element symbol has).
4
+ type: atom
5
+ element: HX
@@ -0,0 +1,5 @@
1
+ # NEGATIVE 99-02 — identifier with an unregistered convention.
2
+ # Must FAIL validation against identifier.yaml (convention enum).
3
+ type: identifier
4
+ value: "xyz"
5
+ convention: smarts
@@ -0,0 +1,4 @@
1
+ # NEGATIVE 99-03 — group with no children.
2
+ # Must FAIL validation against group.yaml (nodes minItems 1).
3
+ type: group
4
+ nodes: []
@@ -0,0 +1,30 @@
1
+ %YAML 1.2
2
+ ---
3
+ $id: "https://github.com/asciichem/asciichem-model/v1/formula"
4
+ title: AsciiChem Formula node (document root)
5
+ description: |
6
+ The root of a parsed AsciiChem document: an ordered sequence of
7
+ top-level nodes. This is the canonical wire form every
8
+ implementation emits under the envelope's `root` key.
9
+ type: object
10
+ required: [type, nodes]
11
+ properties:
12
+ type:
13
+ const: formula
14
+ nodes:
15
+ type: array
16
+ description: |
17
+ Top-level nodes. Items reference the shipped node schemas;
18
+ node types not yet shipped (electron-configuration,
19
+ embedded-math, text, name, mechanism, spectrum, crystal,
20
+ zmatrix, calculation) are TODO.impl/30 and referenced loosely
21
+ until their schemas land.
22
+ items:
23
+ anyOf:
24
+ - $ref: "atom.yaml"
25
+ - $ref: "molecule.yaml"
26
+ - $ref: "group.yaml"
27
+ - $ref: "reaction.yaml"
28
+ - $ref: "reaction-cascade.yaml"
29
+ - $ref: "identifier.yaml"
30
+ additionalProperties: false
@@ -0,0 +1,29 @@
1
+ %YAML 1.2
2
+ ---
3
+ $id: "https://github.com/asciichem/asciichem-model/v1/group"
4
+ title: AsciiChem Group node
5
+ description: |
6
+ A bracketed sub-formula with an optional multiplier that applies to
7
+ the whole group (`(OH)_2`).
8
+ type: object
9
+ required: [type, nodes]
10
+ properties:
11
+ type:
12
+ const: group
13
+ nodes:
14
+ type: array
15
+ minItems: 1
16
+ items:
17
+ anyOf:
18
+ - $ref: "atom.yaml"
19
+ - $ref: "molecule.yaml"
20
+ - $ref: "group.yaml"
21
+ multiplicity:
22
+ type: string
23
+ pattern: "^\\d+$"
24
+ description: Multiplier applied to the group ("2" in (OH)_2).
25
+ bracket:
26
+ default: paren
27
+ enum: [paren, square, brace]
28
+ description: Bracket kind — paren (), square [], brace {}.
29
+ additionalProperties: false
@@ -0,0 +1,32 @@
1
+ %YAML 1.2
2
+ ---
3
+ $id: "https://github.com/asciichem/asciichem-model/v1/identifier"
4
+ title: AsciiChem Identifier node
5
+ description: |
6
+ A substance identifier with its convention. Maps to CML
7
+ `<identifier convention="...">`. Format constraints live with the
8
+ implementations' offline validators; this schema pins the shape and
9
+ the convention registry.
10
+ type: object
11
+ required: [type, value, convention]
12
+ properties:
13
+ type:
14
+ const: identifier
15
+ value:
16
+ type: string
17
+ minLength: 1
18
+ description: The identifier value (e.g. "50-78-2").
19
+ convention:
20
+ enum: [cas, inchi, inchikey, smiles, canonical-smiles, iupac-name, pubchem-cid, chebi]
21
+ description: The identifier convention registry value.
22
+ dictRef:
23
+ type: string
24
+ description: Optional dictionary reference for CML round-trip.
25
+ additionalProperties: false
26
+ examples:
27
+ - type: identifier
28
+ value: "50-78-2"
29
+ convention: cas
30
+ - type: identifier
31
+ value: "BSYNRYMUTXBXSQ-UHFFFAOYSA-N"
32
+ convention: inchikey
@@ -0,0 +1,30 @@
1
+ %YAML 1.2
2
+ ---
3
+ $id: "https://github.com/asciichem/asciichem-model/v1/mechanism"
4
+ title: AsciiChem Mechanism node
5
+ description: |
6
+ A reaction mechanism: labelled reaction steps plus spectator
7
+ species.
8
+ type: object
9
+ required: [type]
10
+ properties:
11
+ type:
12
+ const: mechanism
13
+ steps:
14
+ type: array
15
+ items:
16
+ type: object
17
+ required: [reaction]
18
+ properties:
19
+ label:
20
+ type: string
21
+ description: Step label, e.g. "initiation".
22
+ reaction:
23
+ $ref: "reaction.yaml"
24
+ additionalProperties: false
25
+ spectators:
26
+ type: array
27
+ description: Species present but not transformed.
28
+ items:
29
+ $ref: "molecule.yaml"
30
+ additionalProperties: false
@@ -0,0 +1,28 @@
1
+ %YAML 1.2
2
+ ---
3
+ $id: "https://github.com/asciichem/asciichem-model/v1/molecule"
4
+ title: AsciiChem Molecule node
5
+ description: |
6
+ An ordered sequence of atoms/groups with optional coefficient and
7
+ attached substance identifiers (CML-level annotations).
8
+ type: object
9
+ required: [type, nodes]
10
+ properties:
11
+ type:
12
+ const: molecule
13
+ nodes:
14
+ type: array
15
+ description: Ordered child nodes (atoms, groups, nested molecules).
16
+ items:
17
+ $ref: "atom.yaml"
18
+ minItems: 1
19
+ coefficient:
20
+ type: string
21
+ pattern: "^\\d+$"
22
+ description: Stoichiometric coefficient ("2" in 2H_2O).
23
+ identifiers:
24
+ type: array
25
+ description: Substance identifiers attached to this molecule.
26
+ items:
27
+ $ref: "identifier.yaml"
28
+ additionalProperties: false
@@ -0,0 +1,22 @@
1
+ %YAML 1.2
2
+ ---
3
+ $id: "https://github.com/asciichem/asciichem-model/v1/name"
4
+ title: AsciiChem Name node
5
+ description: |
6
+ A molecule name. Maps to CML `<name>`; convention distinguishes
7
+ IUPAC, CAS, trivial, trade names.
8
+ type: object
9
+ required: [type, content]
10
+ properties:
11
+ type:
12
+ const: name
13
+ content:
14
+ type: string
15
+ description: The name text.
16
+ convention:
17
+ type: string
18
+ description: Naming convention (e.g. "iupac", "cas", "trivial").
19
+ dictRef:
20
+ type: string
21
+ description: Optional dictionary reference for CML round-trip.
22
+ additionalProperties: false
@@ -0,0 +1,28 @@
1
+ %YAML 1.2
2
+ ---
3
+ $id: "https://github.com/asciichem/asciichem-model/v1/provenance"
4
+ title: AsciiChem Provenance node
5
+ description: |
6
+ Where a piece of identity data came from — which source asserted
7
+ it, when it was retrieved, which source version, and the
8
+ attribution line licensing requires (e.g. CAS Common Chemistry's
9
+ CC BY-NC 4.0). Modelled after how the chemicals library attributes
10
+ databanks and how Relaton models bibliographic retrieval.
11
+ type: object
12
+ required: [type, source, retrievedAt]
13
+ properties:
14
+ type:
15
+ const: provenance
16
+ source:
17
+ type: string
18
+ description: Source adapter name (e.g. "pubchem", "commonchemistry").
19
+ retrievedAt:
20
+ type: string
21
+ format: date-time
22
+ sourceVersion:
23
+ type: string
24
+ description: Source release or accessed-date pin where versionless.
25
+ attribution:
26
+ type: string
27
+ description: Attribution string emitted with NC-licensed data.
28
+ additionalProperties: false
@@ -0,0 +1,17 @@
1
+ %YAML 1.2
2
+ ---
3
+ $id: "https://github.com/asciichem/asciichem-model/v1/reaction-cascade"
4
+ title: AsciiChem ReactionCascade node
5
+ description: |
6
+ Two or more reactions chained together (A -> B -> C).
7
+ type: object
8
+ required: [type, steps]
9
+ properties:
10
+ type:
11
+ const: reaction-cascade
12
+ steps:
13
+ type: array
14
+ minItems: 2
15
+ items:
16
+ $ref: "reaction.yaml"
17
+ additionalProperties: false
@@ -0,0 +1,34 @@
1
+ %YAML 1.2
2
+ ---
3
+ $id: "https://github.com/asciichem/asciichem-model/v1/reaction"
4
+ title: AsciiChem Reaction node
5
+ description: |
6
+ A chemical reaction: reactants, an arrow (with optional conditions
7
+ above/below), and products.
8
+ type: object
9
+ required: [type, reactants, products]
10
+ properties:
11
+ type:
12
+ const: reaction
13
+ reactants:
14
+ type: array
15
+ items:
16
+ $ref: "molecule.yaml"
17
+ products:
18
+ type: array
19
+ items:
20
+ $ref: "molecule.yaml"
21
+ arrow:
22
+ default: forward
23
+ enum: [forward, reverse, equilibrium, resonance]
24
+ description: forward (->), reverse (<-), equilibrium (<=>), resonance (<->).
25
+ conditions:
26
+ type: object
27
+ description: Text carried above/below the arrow.
28
+ properties:
29
+ above:
30
+ type: string
31
+ below:
32
+ type: string
33
+ additionalProperties: false
34
+ additionalProperties: false
@@ -0,0 +1,39 @@
1
+ %YAML 1.2
2
+ ---
3
+ $id: "https://github.com/asciichem/asciichem-model/v1/spectrum"
4
+ title: AsciiChem Spectrum node
5
+ description: |
6
+ A spectroscopy record: technique type, acquisition parameters, and
7
+ peaks.
8
+ type: object
9
+ required: [type]
10
+ properties:
11
+ type:
12
+ const: spectrum
13
+ technique:
14
+ type: string
15
+ description: Technique type, e.g. "nmr", "ir", "mass".
16
+ params:
17
+ type: object
18
+ description: Acquisition parameters (solvent, frequency, ...).
19
+ additionalProperties:
20
+ type: string
21
+ peaks:
22
+ type: array
23
+ items:
24
+ type: object
25
+ required: [position]
26
+ properties:
27
+ position:
28
+ type: string
29
+ description: Peak position (ppm, cm^-1, m/z, ...).
30
+ intensity:
31
+ type: string
32
+ multiplicity:
33
+ type: string
34
+ description: Splitting pattern (s, d, t, q, m).
35
+ assignment:
36
+ type: string
37
+ description: Structural assignment of the peak.
38
+ additionalProperties: false
39
+ additionalProperties: false
@@ -0,0 +1,57 @@
1
+ %YAML 1.2
2
+ ---
3
+ $id: "https://github.com/asciichem/asciichem-model/v1/substance-record"
4
+ title: AsciiChem SubstanceRecord node
5
+ description: |
6
+ The resolved view of a substance produced by a resolver source —
7
+ shaped after the CAS Common Chemistry detail payload so resolver
8
+ output maps onto it 1:1. Every identifier and property carries its
9
+ own provenance.
10
+ type: object
11
+ required: [type, identifiers]
12
+ properties:
13
+ type:
14
+ const: substance-record
15
+ preferredName:
16
+ type: string
17
+ description: The source's preferred chemical name.
18
+ synonyms:
19
+ type: array
20
+ items:
21
+ type: string
22
+ description: Systematic, common, and trade names.
23
+ formula:
24
+ type: string
25
+ description: Molecular formula as the source states it (e.g. "C9H8O4").
26
+ molecularWeight:
27
+ type: number
28
+ description: Molecular weight in g/mol as the source states it.
29
+ identifiers:
30
+ type: array
31
+ minItems: 1
32
+ items:
33
+ type: object
34
+ required: [identifier, provenance]
35
+ properties:
36
+ identifier:
37
+ $ref: "identifier.yaml"
38
+ provenance:
39
+ $ref: "provenance.yaml"
40
+ additionalProperties: false
41
+ properties:
42
+ type: array
43
+ items:
44
+ type: object
45
+ required: [name, value, provenance]
46
+ properties:
47
+ name:
48
+ type: string
49
+ description: e.g. "boiling point", "melting point", "density".
50
+ value:
51
+ type: string
52
+ units:
53
+ type: string
54
+ provenance:
55
+ $ref: "provenance.yaml"
56
+ additionalProperties: false
57
+ additionalProperties: false
@@ -0,0 +1,16 @@
1
+ %YAML 1.2
2
+ ---
3
+ $id: "https://github.com/asciichem/asciichem-model/v1/text"
4
+ title: AsciiChem Text node
5
+ description: |
6
+ Free-form text in double quotes (matching AsciiMath convention).
7
+ Unquoted prose is a parse error by design.
8
+ type: object
9
+ required: [type, content]
10
+ properties:
11
+ type:
12
+ const: text
13
+ content:
14
+ type: string
15
+ description: The text content without the quote delimiters.
16
+ additionalProperties: false
@@ -0,0 +1,12 @@
1
+ // Generated from schemas/v1/atom.yaml — do not edit; regenerate.
2
+ export interface Atom {
3
+ readonly type: "atom";
4
+ readonly element: string;
5
+ readonly isotope?: string;
6
+ readonly charge?: string;
7
+ readonly subscript?: string;
8
+ readonly oxidationState?: string;
9
+ readonly lonePairs?: number;
10
+ readonly radicalElectrons?: number;
11
+ readonly ringClosures?: string;
12
+ }
@@ -0,0 +1,5 @@
1
+ // Generated from schemas/v1/bond.yaml — do not edit; regenerate.
2
+ export interface Bond {
3
+ readonly type: "bond";
4
+ readonly kind?: "single" | "double" | "triple" | "quadruple" | "wedge" | "hash" | "dative" | "wavy";
5
+ }
@@ -0,0 +1,13 @@
1
+ // Generated from schemas/v1/calculation.yaml — do not edit; regenerate.
2
+ export interface Calculation {
3
+ readonly type: "calculation";
4
+ readonly method?: string;
5
+ readonly basis?: string;
6
+ readonly properties?: {
7
+ title: string;
8
+ value: string;
9
+ units?: string;
10
+ dictRef?: string;
11
+ convention?: string;
12
+ }[];
13
+ }
@@ -0,0 +1,13 @@
1
+ // Generated from schemas/v1/crystal.yaml — do not edit; regenerate.
2
+ export interface Crystal {
3
+ readonly type: "crystal";
4
+ readonly name?: string;
5
+ readonly a?: number;
6
+ readonly b?: number;
7
+ readonly c?: number;
8
+ readonly alpha?: number;
9
+ readonly beta?: number;
10
+ readonly gamma?: number;
11
+ readonly spacegroup?: string;
12
+ readonly atoms?: Atom[];
13
+ }
@@ -0,0 +1,13 @@
1
+ // Generated from schemas/v1/electron-configuration.yaml — do not edit; regenerate.
2
+ export interface ElectronConfiguration {
3
+ readonly type: "electron-configuration";
4
+ readonly orbitals: {
5
+ orbital: string;
6
+ occupancy: string;
7
+ }[];
8
+ readonly termSymbol?: {
9
+ multiplicity?: string;
10
+ letter?: string;
11
+ jValue?: string;
12
+ };
13
+ }
@@ -0,0 +1,5 @@
1
+ // Generated from schemas/v1/embedded-math.yaml — do not edit; regenerate.
2
+ export interface EmbeddedMath {
3
+ readonly type: "embedded-math";
4
+ readonly source: string;
5
+ }
@@ -0,0 +1,5 @@
1
+ // Generated from schemas/v1/formula.yaml — do not edit; regenerate.
2
+ export interface Formula {
3
+ readonly type: "formula";
4
+ readonly nodes: (Atom | Molecule | Group | Reaction | ReactionCascade | Identifier)[];
5
+ }
@@ -0,0 +1,7 @@
1
+ // Generated from schemas/v1/group.yaml — do not edit; regenerate.
2
+ export interface Group {
3
+ readonly type: "group";
4
+ readonly nodes: (Atom | Molecule | Group)[];
5
+ readonly multiplicity?: string;
6
+ readonly bracket?: "paren" | "square" | "brace";
7
+ }
@@ -0,0 +1,7 @@
1
+ // Generated from schemas/v1/identifier.yaml — do not edit; regenerate.
2
+ export interface Identifier {
3
+ readonly type: "identifier";
4
+ readonly value: string;
5
+ readonly convention: "cas" | "inchi" | "inchikey" | "smiles" | "canonical-smiles" | "iupac-name" | "pubchem-cid" | "chebi";
6
+ readonly dictRef?: string;
7
+ }
@@ -0,0 +1,21 @@
1
+ // Union of every node type in the v1 model.
2
+ export type Node =
3
+ | Atom
4
+ | Bond
5
+ | Calculation
6
+ | Crystal
7
+ | ElectronConfiguration
8
+ | EmbeddedMath
9
+ | Formula
10
+ | Group
11
+ | Identifier
12
+ | Mechanism
13
+ | Molecule
14
+ | Name
15
+ | Provenance
16
+ | ReactionCascade
17
+ | Reaction
18
+ | Spectrum
19
+ | SubstanceRecord
20
+ | Text
21
+ | ZMatrix;
@@ -0,0 +1,9 @@
1
+ // Generated from schemas/v1/mechanism.yaml — do not edit; regenerate.
2
+ export interface Mechanism {
3
+ readonly type: "mechanism";
4
+ readonly steps?: {
5
+ label?: string;
6
+ reaction: Reaction;
7
+ }[];
8
+ readonly spectators?: Molecule[];
9
+ }
@@ -0,0 +1,7 @@
1
+ // Generated from schemas/v1/molecule.yaml — do not edit; regenerate.
2
+ export interface Molecule {
3
+ readonly type: "molecule";
4
+ readonly nodes: Atom[];
5
+ readonly coefficient?: string;
6
+ readonly identifiers?: Identifier[];
7
+ }
@@ -0,0 +1,7 @@
1
+ // Generated from schemas/v1/name.yaml — do not edit; regenerate.
2
+ export interface Name {
3
+ readonly type: "name";
4
+ readonly content: string;
5
+ readonly convention?: string;
6
+ readonly dictRef?: string;
7
+ }
@@ -0,0 +1,8 @@
1
+ // Generated from schemas/v1/provenance.yaml — do not edit; regenerate.
2
+ export interface Provenance {
3
+ readonly type: "provenance";
4
+ readonly source: string;
5
+ readonly retrievedAt: string;
6
+ readonly sourceVersion?: string;
7
+ readonly attribution?: string;
8
+ }
@@ -0,0 +1,5 @@
1
+ // Generated from schemas/v1/reaction-cascade.yaml — do not edit; regenerate.
2
+ export interface ReactionCascade {
3
+ readonly type: "reaction-cascade";
4
+ readonly steps: Reaction[];
5
+ }
@@ -0,0 +1,11 @@
1
+ // Generated from schemas/v1/reaction.yaml — do not edit; regenerate.
2
+ export interface Reaction {
3
+ readonly type: "reaction";
4
+ readonly reactants: Molecule[];
5
+ readonly products: Molecule[];
6
+ readonly arrow?: "forward" | "reverse" | "equilibrium" | "resonance";
7
+ readonly conditions?: {
8
+ above?: string;
9
+ below?: string;
10
+ };
11
+ }
@@ -0,0 +1,14 @@
1
+ // Generated from schemas/v1/spectrum.yaml — do not edit; regenerate.
2
+ export interface Spectrum {
3
+ readonly type: "spectrum";
4
+ readonly technique?: string;
5
+ readonly params?: {
6
+
7
+ };
8
+ readonly peaks?: {
9
+ position: string;
10
+ intensity?: string;
11
+ multiplicity?: string;
12
+ assignment?: string;
13
+ }[];
14
+ }
@@ -0,0 +1,18 @@
1
+ // Generated from schemas/v1/substance-record.yaml — do not edit; regenerate.
2
+ export interface SubstanceRecord {
3
+ readonly type: "substance-record";
4
+ readonly preferredName?: string;
5
+ readonly synonyms?: string[];
6
+ readonly formula?: string;
7
+ readonly molecularWeight?: number;
8
+ readonly identifiers: {
9
+ identifier: Identifier;
10
+ provenance: Provenance;
11
+ }[];
12
+ readonly properties?: {
13
+ name: string;
14
+ value: string;
15
+ units?: string;
16
+ provenance: Provenance;
17
+ }[];
18
+ }
@@ -0,0 +1,5 @@
1
+ // Generated from schemas/v1/text.yaml — do not edit; regenerate.
2
+ export interface Text {
3
+ readonly type: "text";
4
+ readonly content: string;
5
+ }
@@ -0,0 +1,13 @@
1
+ // Generated from schemas/v1/zmatrix.yaml — do not edit; regenerate.
2
+ export interface ZMatrix {
3
+ readonly type: "zmatrix";
4
+ readonly rows?: {
5
+ atom: string;
6
+ ref1?: string;
7
+ distance?: string;
8
+ ref2?: string;
9
+ angle?: string;
10
+ ref3?: string;
11
+ dihedral?: string;
12
+ }[];
13
+ }