{
  "openapi": "3.0.2",
  "info": {
    "title": "Legacy CHEESE API",
    "description": "Reference for the legacy hosted CHEESE API. New integrations should use CHEESE API v2; these routes remain available for existing integrations during the migration/support window.",
    "contact": {
      "name": "DeepMedchem",
      "url": "https://deepmedchem.com/",
      "email": "info@deepmedchem.com"
    },
    "version": "0.0.1"
  },
  "paths": {
    "/rate-limit/status": {
      "get": {
        "tags": [
          "General"
        ],
        "summary": "Get Rate Limit Status",
        "description": "Return current user's API usage/remaining requests in active window.",
        "operationId": "get_rate_limit_status_rate_limit_status_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          }
        ]
      }
    },
    "/random_molecule": {
      "get": {
        "tags": [
          "Searching with CHEESE"
        ],
        "summary": "Get Random Molecules",
        "description": "Get random molecule(s) from any available database.\n\nThis endpoint returns a specified number of random molecules in SMILES format from a random selection of databases.\n\nParameters:\n- n_mols (int): The number of random molecules to retrieve (default is 1).\n\nReturns:\n- A list of SMILES strings representing the random molecules.",
        "operationId": "get_random_molecules_random_molecule_get",
        "parameters": [
          {
            "required": false,
            "schema": {
              "title": "N Mols",
              "default": 1
            },
            "name": "n_mols",
            "in": "query"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          }
        ]
      }
    },
    "/rate_limit_status": {
      "get": {
        "tags": [
          "Testing and Health Checks"
        ],
        "summary": "Get Rate Limit Status",
        "description": "Return current per-user daily API usage and remaining request budget.\n\nResponse fields:\n- limit: maximum requests/day for account tier\n- used: requests already consumed today\n- remaining: requests left today\n- reset_at: ISO timestamp for next UTC reset\n- seconds_to_reset: seconds until reset\n- account_type: resolved user account tier",
        "operationId": "get_rate_limit_status_rate_limit_status_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          }
        ]
      }
    },
    "/available_databases": {
      "get": {
        "tags": [
          "Searching with CHEESE"
        ],
        "summary": "Get Available Dbs Info",
        "description": "Get all databases available for similarity search.\n\nThis endpoint returns a list of all databases that can be used for molecule searches.\n\nReturns:\n- A dictionary containing the list of available databases with some of their details (vendor, vendor webpage, number of molecules, quotation email).",
        "operationId": "get_available_dbs_info_available_databases_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          }
        ]
      }
    },
    "/molsearch_simple": {
      "get": {
        "tags": [
          "Searching with CHEESE"
        ],
        "summary": "Search One Molecule Simple",
        "description": "Search by a single molecule based on various criteria.\n\nThis endpoint allows users to search by a molecule while choosing from several search types and additinal search parameters. \nMultiple databases can be specified for the search.\n\nLimitations:\n- this endpoint is limited to retrieve 100 molecules. For more use the /jobs endpoints.\n- this endpoint allows you to use max two databases. For more use the /jobs endpoints.\n\nParameters:\n- search_input (str): The input molecule to search for (default is \"CC(=O)Oc1ccccc1C(=O)O\").\n- search_type (SearchTypes): The type of search to perform (default is \"morgan\").\n- search_quality (SearchQuality): The quality of the search (default is \"fast\").\n- db_names (List[DatabaseEnum]): The databases to use for the search.\n- n_neighbors (int): The number of neighbors to consider (default is 30).\n\nReturns:\n- A dictionary with list of retrieved molecules, list of molecule ids, and list of origin DBs for each molecule.",
        "operationId": "search_one_molecule_simple_molsearch_simple_get",
        "parameters": [
          {
            "required": false,
            "schema": {
              "title": "Search Input",
              "type": "string",
              "default": "CC(=O)Oc1ccccc1C(=O)O"
            },
            "name": "search_input",
            "in": "query"
          },
          {
            "description": "The type of search to perform",
            "required": false,
            "schema": {
              "type": "array",
              "items": {
                "$ref": "#/components/schemas/SearchTypes"
              },
              "description": "The type of search to perform",
              "default": [
                "espsim_shape"
              ]
            },
            "name": "search_type",
            "in": "query"
          },
          {
            "description": "Speed/Accuracy Tradeoff",
            "required": false,
            "schema": {
              "allOf": [
                {
                  "$ref": "#/components/schemas/SearchQuality"
                }
              ],
              "description": "Speed/Accuracy Tradeoff",
              "default": "fast"
            },
            "name": "search_quality",
            "in": "query"
          },
          {
            "description": "Selected Databases",
            "required": false,
            "schema": {
              "type": "array",
              "items": {
                "$ref": "#/components/schemas/DatabaseEnumAll"
              },
              "description": "Selected Databases",
              "default": [
                "CHEMINFINITA-SYNTHON"
              ]
            },
            "name": "db_names",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "N Neighbors",
              "type": "integer",
              "default": 30
            },
            "name": "n_neighbors",
            "in": "query"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          }
        ]
      }
    },
    "/molsearch": {
      "get": {
        "tags": [
          "Searching with CHEESE"
        ],
        "summary": "Search One Molecule",
        "description": "Search by a single molecule based on various criteria.\n\nThis endpoint allows users to search by a single molecule while choosing from several search types and additinal search parameters. . \nMultiple databases can be specified for the search. \n\nLimitations:\n- this endpoint is limited to retrieve 100 molecules. For more use the /jobs endpoints.\n- this endpoint allows you to use max two databases. For more use the /jobs endpoints.\n\nParameters:\n- search_input (str): The input molecule to search for (default is \"CC(=O)Oc1ccccc1C(=O)O\").\n- search_type (SearchTypes): The type of search to perform (default is \"morgan\").\n- search_quality (SearchQuality): The quality of the search (default is \"fast\").\n- db_names (List[DatabaseEnum]): The databases to use for the search.\n- n_neighbors (int): The number of neighbors to consider (default is 30).\n- descriptors (bool): Whether to include molecular descriptors in the results (default is True).\n- properties (bool): Whether to include molecular properties in the results (default is True).\n- filter_molecules (bool): Whether to filter molecules based on specific criteria (default is False).\n- order_molecules (bool): Whether to order molecules based on specific criteria (default is False).\n- filtering (FilteringEnum): Filters such as Lipinsky, QED, PAINS, Substructure, Superstructure... (default is No Solvents filter)\n- ordering (OrderingEnum): Orderings such as Similarity, Morgan Tanimoto, Shapesim Dissimilarity, Espsim Dissimilarity... (defailt is Similarity)\n\nReturns:\n- A dictionary with list of retrieved molecules, list of molecule ids, and list of origin DBs for each molecule.",
        "operationId": "search_one_molecule_molsearch_get",
        "parameters": [
          {
            "required": false,
            "schema": {
              "title": "Search Input",
              "type": "string",
              "default": "CC(=O)Oc1ccccc1C(=O)O"
            },
            "name": "search_input",
            "in": "query"
          },
          {
            "description": "The type of search to perform",
            "required": false,
            "schema": {
              "type": "array",
              "items": {
                "$ref": "#/components/schemas/SearchTypes"
              },
              "description": "The type of search to perform",
              "default": [
                "espsim_shape"
              ]
            },
            "name": "search_type",
            "in": "query"
          },
          {
            "description": "Speed/Accuracy Tradeoff",
            "required": false,
            "schema": {
              "allOf": [
                {
                  "$ref": "#/components/schemas/SearchQuality"
                }
              ],
              "description": "Speed/Accuracy Tradeoff",
              "default": "fast"
            },
            "name": "search_quality",
            "in": "query"
          },
          {
            "description": "Selected Databases",
            "required": false,
            "schema": {
              "type": "array",
              "items": {
                "$ref": "#/components/schemas/DatabaseEnumAll"
              },
              "description": "Selected Databases",
              "default": [
                "CHEMINFINITA-SYNTHON"
              ]
            },
            "name": "db_names",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "N Neighbors",
              "type": "integer",
              "default": 30
            },
            "name": "n_neighbors",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "Descriptors",
              "type": "boolean",
              "default": true
            },
            "name": "descriptors",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "Properties",
              "type": "boolean",
              "default": true
            },
            "name": "properties",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "Filter Molecules",
              "type": "boolean",
              "default": false
            },
            "name": "filter_molecules",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "Order Molecules",
              "type": "boolean",
              "default": true
            },
            "name": "order_molecules",
            "in": "query"
          },
          {
            "description": "Selected Filters",
            "required": false,
            "schema": {
              "type": "array",
              "items": {
                "$ref": "#/components/schemas/FilteringEnum"
              },
              "description": "Selected Filters",
              "default": [
                "No solvents"
              ]
            },
            "name": "filtering",
            "in": "query"
          },
          {
            "description": "Selected Ordering",
            "required": false,
            "schema": {
              "type": "array",
              "items": {
                "$ref": "#/components/schemas/OrderingEnum"
              },
              "description": "Selected Ordering",
              "default": [
                "Similarity"
              ]
            },
            "name": "ordering",
            "in": "query"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          }
        ]
      }
    },
    "/molsearch_array": {
      "get": {
        "tags": [
          "Searching with CHEESE"
        ],
        "summary": "Search Array",
        "description": "Search by an array of molecules based on multiple criteria. \n\nThis endpoint allows users to search by multiple molecules while choosing from several search types and additinal search parameters.  \nMultiple databases can be specified for the search.\n\nParameters:\n- search_type (str): The type of search to perform.\n- n_neighbors (int): The number of neighbors to consider.\n- search_quality (str): The quality of the search.\n- search_input (List[str]): The input molecules to search for.\n- db_names (List[str]): The databases to use for the search.\n- descriptors (bool): Whether to include molecular descriptors in the results (default is False).\n- properties (bool): Whether to include molecular properties in the results (default is False).\n- filter_molecules (bool): Whether to filter molecules based on specific criteria (default is False).\n- filename (str): The name of the file to save the search results (default is \"search_results\").\n\nReturns:\n- A dictionary with the search results and search metadata.",
        "operationId": "search_array_molsearch_array_get",
        "parameters": [
          {
            "description": "The type of search to perform",
            "required": false,
            "schema": {
              "allOf": [
                {
                  "$ref": "#/components/schemas/SearchTypes"
                }
              ],
              "description": "The type of search to perform",
              "default": "espsim_shape"
            },
            "name": "search_type",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "N Neighbors",
              "type": "integer",
              "default": 30
            },
            "name": "n_neighbors",
            "in": "query"
          },
          {
            "description": "Speed/Accuracy Tradeoff",
            "required": false,
            "schema": {
              "allOf": [
                {
                  "$ref": "#/components/schemas/SearchQuality"
                }
              ],
              "description": "Speed/Accuracy Tradeoff",
              "default": "fast"
            },
            "name": "search_quality",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "Search Input",
              "type": "array",
              "items": {
                "type": "string"
              },
              "default": [
                "CC(=O)Oc1ccccc1C(=O)O",
                "CC(=O)Oc1ccccc1C(N)=O",
                "CC(=O)Nc1ccccc1C(=O)O"
              ]
            },
            "name": "search_input",
            "in": "query"
          },
          {
            "description": "Selected Databases",
            "required": false,
            "schema": {
              "type": "array",
              "items": {
                "$ref": "#/components/schemas/DatabaseEnumAll"
              },
              "description": "Selected Databases",
              "default": [
                "CHEMINFINITA-SYNTHON"
              ]
            },
            "name": "db_names",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "Descriptors",
              "type": "boolean",
              "default": false
            },
            "name": "descriptors",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "Properties",
              "type": "boolean",
              "default": false
            },
            "name": "properties",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "Filter Molecules",
              "type": "boolean",
              "default": false
            },
            "name": "filter_molecules",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "Filename",
              "type": "string",
              "default": "search_results"
            },
            "name": "filename",
            "in": "query"
          },
          {
            "description": "Override the Accept header. 'json' or 'csv'.",
            "required": false,
            "schema": {
              "allOf": [
                {
                  "$ref": "#/components/schemas/ResponseFormat"
                }
              ],
              "description": "Override the Accept header. 'json' or 'csv'."
            },
            "name": "format",
            "in": "query"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          }
        ]
      }
    },
    "/submit_molsearch": {
      "get": {
        "tags": [
          "CHEESE Jobs (for registered users only)"
        ],
        "summary": "Search One Molecule Job",
        "description": "Submit a job to search by a single molecule using various criteria.\n\nParameters:\n- search_input (str): The input molecule to search for (default is \"CC(=O)Oc1ccccc1C(=O)O\")\n- search_type (SearchTypes): The type of search to perform (default is \"morgan\")\n- db_names (List[DatabaseEnum]): The databases to use for the search\n- n_neighbors (int): The number of neighbors to consider (maximum is 100K)\n\nReturns:\n- A dictionary containing the search input, search type, number of neighbors, search quality, and databases used.",
        "operationId": "search_one_molecule_job_submit_molsearch_get",
        "parameters": [
          {
            "required": false,
            "schema": {
              "title": "Search Input",
              "type": "string",
              "default": "CC(=O)Oc1ccccc1C(=O)O"
            },
            "name": "search_input",
            "in": "query"
          },
          {
            "description": "The type of search to perform",
            "required": false,
            "schema": {
              "allOf": [
                {
                  "$ref": "#/components/schemas/SearchTypes"
                }
              ],
              "description": "The type of search to perform",
              "default": "espsim_shape"
            },
            "name": "search_type",
            "in": "query"
          },
          {
            "description": "Speed/Accuracy Tradeoff",
            "required": false,
            "schema": {
              "allOf": [
                {
                  "$ref": "#/components/schemas/SearchQuality"
                }
              ],
              "description": "Speed/Accuracy Tradeoff",
              "default": "fast"
            },
            "name": "search_quality",
            "in": "query"
          },
          {
            "description": "Selected Databases",
            "required": false,
            "schema": {
              "type": "array",
              "items": {
                "$ref": "#/components/schemas/DatabaseEnumAll"
              },
              "description": "Selected Databases",
              "default": [
                "CHEMINFINITA-SYNTHON"
              ]
            },
            "name": "db_names",
            "in": "query"
          },
          {
            "description": "The number of neighbors to consider (maximum is 100K)",
            "required": false,
            "schema": {
              "title": "N Neighbors",
              "type": "integer",
              "description": "The number of neighbors to consider (maximum is 100K)",
              "default": 100000
            },
            "name": "n_neighbors",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "Include Properties",
              "type": "boolean",
              "default": false
            },
            "name": "include_properties",
            "in": "query"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          }
        ]
      }
    },
    "/synthongpt_smarts_patterns": {
      "get": {
        "tags": [
          "SynthonGPT"
        ],
        "summary": "Get Synthongpt Smarts Patterns Endpoint",
        "operationId": "get_synthongpt_smarts_patterns_endpoint_synthongpt_smarts_patterns_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          }
        ]
      }
    },
    "/submit_synthongpt_job": {
      "post": {
        "tags": [
          "SynthonGPT",
          "CHEESE Jobs (for registered users only)"
        ],
        "summary": "Submit Synthon Job",
        "operationId": "submit_synthon_job_submit_synthongpt_job_post",
        "parameters": [
          {
            "required": false,
            "schema": {
              "title": "Search Input",
              "type": "string",
              "default": "CC(=O)Oc1ccccc1C(=O)O"
            },
            "name": "search_input",
            "in": "query"
          },
          {
            "description": "Selected SynthonGPT database. Canonical names stay exposed; legacy CHEMSPACE-FREEDOM-142B is still accepted.",
            "required": false,
            "schema": {
              "title": "Db Name",
              "type": "string",
              "description": "Selected SynthonGPT database. Canonical names stay exposed; legacy CHEMSPACE-FREEDOM-142B is still accepted.",
              "default": "CHEMSPACE-FREEDOM-SYNTHON"
            },
            "name": "db_name",
            "in": "query"
          },
          {
            "description": "Fast synthon search (100 results)",
            "required": false,
            "schema": {
              "allOf": [
                {
                  "$ref": "#/components/schemas/SearchQuality"
                }
              ],
              "description": "Fast synthon search (100 results)",
              "default": "100"
            },
            "name": "search_quality",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "Include Properties",
              "type": "boolean",
              "default": true
            },
            "name": "include_properties",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "Include Metadata",
              "type": "boolean",
              "default": false
            },
            "name": "include_metadata",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "Include Synthons",
              "type": "boolean",
              "default": false
            },
            "name": "include_synthons",
            "in": "query"
          },
          {
            "description": "shape|esp|morgan",
            "required": false,
            "schema": {
              "title": "Synthon Scorer",
              "type": "string",
              "description": "shape|esp|morgan",
              "default": "shape"
            },
            "name": "synthon_scorer",
            "in": "query"
          },
          {
            "description": "similarity|substructure|superstructure",
            "required": false,
            "schema": {
              "title": "Search Mode",
              "type": "string",
              "description": "similarity|substructure|superstructure",
              "default": "similarity"
            },
            "name": "search_mode",
            "in": "query"
          },
          {
            "description": "fuzzy|exact",
            "required": false,
            "schema": {
              "title": "Structure Match Mode",
              "type": "string",
              "description": "fuzzy|exact",
              "default": "fuzzy"
            },
            "name": "structure_match_mode",
            "in": "query"
          },
          {
            "description": "Optional predefined SMARTS pattern id",
            "required": false,
            "schema": {
              "title": "Smarts Prefilter Pattern Id",
              "type": "string",
              "description": "Optional predefined SMARTS pattern id",
              "default": ""
            },
            "name": "smarts_prefilter_pattern_id",
            "in": "query"
          },
          {
            "description": "Optional predefined SMARTS pattern label",
            "required": false,
            "schema": {
              "title": "Smarts Prefilter Pattern Label",
              "type": "string",
              "description": "Optional predefined SMARTS pattern label",
              "default": ""
            },
            "name": "smarts_prefilter_pattern_label",
            "in": "query"
          },
          {
            "description": "Optional predefined SMARTS pattern SMARTS",
            "required": false,
            "schema": {
              "title": "Smarts Prefilter Pattern Smarts",
              "type": "string",
              "description": "Optional predefined SMARTS pattern SMARTS",
              "default": ""
            },
            "name": "smarts_prefilter_pattern_smarts",
            "in": "query"
          },
          {
            "description": "include|exclude",
            "required": false,
            "schema": {
              "title": "Smarts Prefilter Mode",
              "type": "string",
              "description": "include|exclude",
              "default": "include"
            },
            "name": "smarts_prefilter_mode",
            "in": "query"
          },
          {
            "description": "exact_sss",
            "required": false,
            "schema": {
              "title": "Synthon Search Backend",
              "type": "string",
              "description": "exact_sss",
              "default": "exact_sss"
            },
            "name": "synthon_search_backend",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "Sample Size",
              "type": "integer",
              "default": 100
            },
            "name": "sample_size",
            "in": "query"
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "title": "Payload",
                "type": "object"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          }
        ]
      }
    },
    "/get_molsearch_page": {
      "post": {
        "tags": [
          "CHEESE Jobs (for registered users only)"
        ],
        "summary": "Paging Props",
        "operationId": "paging_props_get_molsearch_page_post",
        "parameters": [
          {
            "required": false,
            "schema": {
              "title": "Job Name",
              "type": "string",
              "default": "XXX"
            },
            "name": "job_name",
            "in": "query"
          },
          {
            "description": "Selected Database",
            "required": false,
            "schema": {
              "title": "Db Name",
              "type": "string",
              "description": "Selected Database",
              "default": "CHEMINFINITA-SYNTHON"
            },
            "name": "db_name",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "Page Size",
              "type": "integer",
              "default": 30
            },
            "name": "page_size",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "Page Num",
              "type": "integer",
              "default": 1
            },
            "name": "page_num",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "Include Properties",
              "type": "boolean",
              "default": false
            },
            "name": "include_properties",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "Include Synthons",
              "type": "boolean",
              "default": false
            },
            "name": "include_synthons",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "Sim Th",
              "type": "number",
              "default": 0
            },
            "name": "sim_th",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "D Min",
              "type": "number",
              "default": 0
            },
            "name": "d_min",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "D Max",
              "type": "number",
              "default": 1
            },
            "name": "d_max",
            "in": "query"
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "title": "Data",
                "allOf": [
                  {
                    "$ref": "#/components/schemas/AnyDictModel"
                  }
                ],
                "default": {
                  "prop_ranges": {
                    "caco2_wang": {
                      "min": -100000,
                      "max": 100000
                    },
                    "clearance_hepatocyte_az": {
                      "min": -100000,
                      "max": 100000
                    },
                    "clearance_microsome_az": {
                      "min": -100000,
                      "max": 100000
                    },
                    "half_life_obach": {
                      "min": -100000,
                      "max": 100000
                    },
                    "ld50_zhu": {
                      "min": -100000,
                      "max": 100000
                    },
                    "lipophilicity_astrazeneca": {
                      "min": -100000,
                      "max": 100000
                    },
                    "ppbr_az": {
                      "min": -100000,
                      "max": 100000
                    },
                    "solubility_aqsoldb": {
                      "min": -100000,
                      "max": 100000
                    },
                    "vdss_lombardo": {
                      "min": -100000,
                      "max": 100000
                    },
                    "ames": {
                      "min": -100000,
                      "max": 100000
                    },
                    "bbb_martins": {
                      "min": -100000,
                      "max": 100000
                    },
                    "bioavailability_ma": {
                      "min": -100000,
                      "max": 100000
                    },
                    "cyp2c9_substrate_carbonmangels": {
                      "min": -100000,
                      "max": 100000
                    },
                    "cyp2c9_veith": {
                      "min": -100000,
                      "max": 100000
                    },
                    "cyp2d6_substrate_carbonmangels": {
                      "min": -100000,
                      "max": 100000
                    },
                    "cyp2d6_veith": {
                      "min": -100000,
                      "max": 100000
                    },
                    "cyp3a4_substrate_carbonmangels": {
                      "min": -100000,
                      "max": 100000
                    },
                    "cyp3a4_veith": {
                      "min": -100000,
                      "max": 100000
                    },
                    "dili": {
                      "min": -100000,
                      "max": 100000
                    },
                    "herg": {
                      "min": -100000,
                      "max": 100000
                    },
                    "hia_hou": {
                      "min": -100000,
                      "max": 100000
                    },
                    "pgp_broccatelli": {
                      "min": -100000,
                      "max": 100000
                    },
                    "molecular_weight": {
                      "min": -100000,
                      "max": 100000
                    },
                    "formal_charge": {
                      "min": -100000,
                      "max": 100000
                    },
                    "clogp": {
                      "min": -100000,
                      "max": 100000
                    },
                    "heavy_atoms": {
                      "min": -100000,
                      "max": 100000
                    },
                    "h_bond_acceptors": {
                      "min": -100000,
                      "max": 100000
                    },
                    "h_bond_donor": {
                      "min": -100000,
                      "max": 100000
                    },
                    "rotatable_bonds": {
                      "min": -100000,
                      "max": 100000
                    },
                    "num_of_rings": {
                      "min": -100000,
                      "max": 100000
                    },
                    "molar_refractivity": {
                      "min": -100000,
                      "max": 100000
                    },
                    "number_of_atoms": {
                      "min": -100000,
                      "max": 100000
                    },
                    "topological_surface_area_mapping": {
                      "min": -100000,
                      "max": 100000
                    }
                  },
                  "neighbor_ids": []
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          }
        ]
      }
    },
    "/get_download_link": {
      "get": {
        "tags": [
          "CHEESE Jobs (for registered users only)"
        ],
        "summary": "Download Link",
        "description": "Getting the download link for a search job\n\nParameters:\n- job_name (str): The job ID\n- file format (str) : The response file format : csv, json, xlsx, sdf\n\nReturns:\n- The status of the download link generation",
        "operationId": "download_link_get_download_link_get",
        "parameters": [
          {
            "required": false,
            "schema": {
              "title": "Job Name",
              "type": "string",
              "default": "XXX"
            },
            "name": "job_name",
            "in": "query"
          },
          {
            "description": "Selected Databases",
            "required": false,
            "schema": {
              "title": "Db Name",
              "type": "array",
              "items": {
                "type": "string"
              },
              "description": "Selected Databases",
              "default": [
                "CHEMINFINITA-SYNTHON"
              ]
            },
            "name": "db_name",
            "in": "query"
          },
          {
            "description": "File formats",
            "required": false,
            "schema": {
              "type": "array",
              "items": {
                "$ref": "#/components/schemas/FileFormat"
              },
              "description": "File formats",
              "default": [
                "csv"
              ]
            },
            "name": "file_format",
            "in": "query"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          }
        ]
      }
    },
    "/get_sim_histograms": {
      "get": {
        "tags": [
          "CHEESE Jobs (for registered users only)"
        ],
        "summary": "Get Histograms",
        "operationId": "get_histograms_get_sim_histograms_get",
        "parameters": [
          {
            "required": false,
            "schema": {
              "title": "Job Name",
              "type": "string",
              "default": "XXX"
            },
            "name": "job_name",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "N Bins",
              "type": "integer",
              "default": 20
            },
            "name": "n_bins",
            "in": "query"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          }
        ]
      }
    },
    "/get_prop_histograms": {
      "get": {
        "tags": [
          "CHEESE Jobs (for registered users only)"
        ],
        "summary": "Get Prop Histograms",
        "operationId": "get_prop_histograms_get_prop_histograms_get",
        "parameters": [
          {
            "required": false,
            "schema": {
              "title": "Job Name",
              "type": "string",
              "default": "XXX"
            },
            "name": "job_name",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "N Bins",
              "type": "integer",
              "default": 20
            },
            "name": "n_bins",
            "in": "query"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          }
        ]
      }
    },
    "/prepare_download": {
      "post": {
        "tags": [
          "CHEESE Jobs (for registered users only)"
        ],
        "summary": "Download Link",
        "description": "Getting the download link for a search job\n\nParameters:\n- job_name (str): The job ID\n- file format (str) : The response file format : csv, json, xlsx, sdf\n\nReturns:\n- The status of the download link generation",
        "operationId": "download_link_prepare_download_post",
        "parameters": [
          {
            "required": false,
            "schema": {
              "title": "Job Name",
              "type": "string",
              "default": "XXX"
            },
            "name": "job_name",
            "in": "query"
          },
          {
            "description": "Selected Databases",
            "required": false,
            "schema": {
              "title": "Db Name",
              "type": "array",
              "items": {
                "type": "string"
              },
              "description": "Selected Databases",
              "default": [
                "CHEMINFINITA-SYNTHON"
              ]
            },
            "name": "db_name",
            "in": "query"
          },
          {
            "description": "File formats",
            "required": false,
            "schema": {
              "type": "array",
              "items": {
                "$ref": "#/components/schemas/FileFormat"
              },
              "description": "File formats",
              "default": [
                "csv"
              ]
            },
            "name": "file_format",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "Include Properties",
              "type": "boolean",
              "default": false
            },
            "name": "include_properties",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "Include Metadata",
              "type": "boolean",
              "default": false
            },
            "name": "include_metadata",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "Sim Th",
              "type": "number",
              "default": 0
            },
            "name": "sim_th",
            "in": "query"
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "title": "Data",
                "allOf": [
                  {
                    "$ref": "#/components/schemas/AnyDictModel"
                  }
                ],
                "default": {
                  "prop_ranges": {
                    "caco2_wang": {
                      "min": -100000,
                      "max": 100000
                    },
                    "clearance_hepatocyte_az": {
                      "min": -100000,
                      "max": 100000
                    },
                    "clearance_microsome_az": {
                      "min": -100000,
                      "max": 100000
                    },
                    "half_life_obach": {
                      "min": -100000,
                      "max": 100000
                    },
                    "ld50_zhu": {
                      "min": -100000,
                      "max": 100000
                    },
                    "lipophilicity_astrazeneca": {
                      "min": -100000,
                      "max": 100000
                    },
                    "ppbr_az": {
                      "min": -100000,
                      "max": 100000
                    },
                    "solubility_aqsoldb": {
                      "min": -100000,
                      "max": 100000
                    },
                    "vdss_lombardo": {
                      "min": -100000,
                      "max": 100000
                    },
                    "ames": {
                      "min": -100000,
                      "max": 100000
                    },
                    "bbb_martins": {
                      "min": -100000,
                      "max": 100000
                    },
                    "bioavailability_ma": {
                      "min": -100000,
                      "max": 100000
                    },
                    "cyp2c9_substrate_carbonmangels": {
                      "min": -100000,
                      "max": 100000
                    },
                    "cyp2c9_veith": {
                      "min": -100000,
                      "max": 100000
                    },
                    "cyp2d6_substrate_carbonmangels": {
                      "min": -100000,
                      "max": 100000
                    },
                    "cyp2d6_veith": {
                      "min": -100000,
                      "max": 100000
                    },
                    "cyp3a4_substrate_carbonmangels": {
                      "min": -100000,
                      "max": 100000
                    },
                    "cyp3a4_veith": {
                      "min": -100000,
                      "max": 100000
                    },
                    "dili": {
                      "min": -100000,
                      "max": 100000
                    },
                    "herg": {
                      "min": -100000,
                      "max": 100000
                    },
                    "hia_hou": {
                      "min": -100000,
                      "max": 100000
                    },
                    "pgp_broccatelli": {
                      "min": -100000,
                      "max": 100000
                    },
                    "molecular_weight": {
                      "min": -100000,
                      "max": 100000
                    },
                    "formal_charge": {
                      "min": -100000,
                      "max": 100000
                    },
                    "clogp": {
                      "min": -100000,
                      "max": 100000
                    },
                    "heavy_atoms": {
                      "min": -100000,
                      "max": 100000
                    },
                    "h_bond_acceptors": {
                      "min": -100000,
                      "max": 100000
                    },
                    "h_bond_donor": {
                      "min": -100000,
                      "max": 100000
                    },
                    "rotatable_bonds": {
                      "min": -100000,
                      "max": 100000
                    },
                    "num_of_rings": {
                      "min": -100000,
                      "max": 100000
                    },
                    "molar_refractivity": {
                      "min": -100000,
                      "max": 100000
                    },
                    "number_of_atoms": {
                      "min": -100000,
                      "max": 100000
                    },
                    "topological_surface_area_mapping": {
                      "min": -100000,
                      "max": 100000
                    }
                  },
                  "neighbor_ids": []
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          }
        ]
      }
    },
    "/job_status": {
      "get": {
        "tags": [
          "CHEESE Jobs (for registered users only)"
        ],
        "summary": "Job Status",
        "operationId": "job_status_job_status_get",
        "parameters": [
          {
            "required": false,
            "schema": {
              "title": "Job Name",
              "type": "string",
              "default": ""
            },
            "name": "job_name",
            "in": "query"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          }
        ]
      }
    },
    "/job_info": {
      "get": {
        "tags": [
          "CHEESE Jobs (for registered users only)"
        ],
        "summary": "Job Info",
        "operationId": "job_info_job_info_get",
        "parameters": [
          {
            "required": false,
            "schema": {
              "title": "Job Name",
              "type": "string",
              "default": ""
            },
            "name": "job_name",
            "in": "query"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          }
        ]
      }
    },
    "/user_jobs": {
      "get": {
        "tags": [
          "CHEESE Jobs (for registered users only)"
        ],
        "summary": "User Jobs",
        "operationId": "user_jobs_user_jobs_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          }
        ]
      }
    },
    "/user_downloads": {
      "get": {
        "tags": [
          "CHEESE Jobs (for registered users only)"
        ],
        "summary": "User Downloads",
        "operationId": "user_downloads_user_downloads_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          }
        ]
      }
    },
    "/predict": {
      "get": {
        "tags": [
          "Predict Properties"
        ],
        "summary": "Predict",
        "description": "Predict properties for a single molecule.\n\nThis endpoint allows users to predict various properties and descriptors for a given molecule.\n\nParameters:\n- search_input (str): The input molecule in SMILES format.\n- descriptors (bool): Whether to include molecular descriptors in the results (default is True).\n- properties (bool): Whether to include molecular properties in the results (default is False).\n\nReturns:\n- A JSON response containing the predicted properties and descriptors.",
        "operationId": "predict_predict_get",
        "parameters": [
          {
            "required": false,
            "schema": {
              "title": "Search Input",
              "type": "string",
              "default": "CC(=O)Oc1ccccc1C(=O)O"
            },
            "name": "search_input",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "Descriptors",
              "type": "boolean",
              "default": true
            },
            "name": "descriptors",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "Properties",
              "type": "boolean",
              "default": false
            },
            "name": "properties",
            "in": "query"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          }
        ]
      }
    },
    "/predict_array": {
      "get": {
        "tags": [
          "Predict Properties"
        ],
        "summary": "Predict Array",
        "description": "Predict properties for an array of molecules.\n\nThis endpoint allows users to predict various properties and descriptors for a list of molecules.\n\nParameters:\n- request (Request): The request object.\n- search_input (List[str]): The input molecules in SMILES format.\n- descriptors (bool): Whether to include molecular descriptors in the results (default is True).\n- properties (bool): Whether to include molecular properties in the results (default is True).\n- filename (str): The name of the file to save the prediction results (default is \"properties_and_descriptors\").\n\nReturns:\n- A JSON response containing the predicted properties and descriptors.",
        "operationId": "predict_array_predict_array_get",
        "parameters": [
          {
            "required": false,
            "schema": {
              "title": "Search Input",
              "type": "array",
              "items": {
                "type": "string"
              },
              "default": [
                "CC(=O)Oc1ccccc1C(=O)O",
                "CC(=O)Oc1ccncc1C(=O)O",
                "CC(=O)Oc1cnccc1C(=O)O"
              ]
            },
            "name": "search_input",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "Descriptors",
              "type": "boolean",
              "default": true
            },
            "name": "descriptors",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "Properties",
              "type": "boolean",
              "default": true
            },
            "name": "properties",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "Filename",
              "type": "string",
              "default": "properties_and_descriptors"
            },
            "name": "filename",
            "in": "query"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          }
        ]
      }
    },
    "/health": {
      "get": {
        "tags": [
          "Testing and Health Checks"
        ],
        "summary": "Readiness",
        "operationId": "readiness_health_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          }
        ]
      }
    },
    "/test": {
      "get": {
        "tags": [
          "Testing and Health Checks"
        ],
        "summary": "Health Check",
        "description": "Health check endpoint to verify the status of the API.\n\nThis endpoint can be used to ensure that the API is running and responsive. It returns a simple status message.\n\nReturns:\n- A JSON response with a status message indicating the health of the API.",
        "operationId": "health_check_test_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          }
        ]
      }
    },
    "/batch_search": {
      "get": {
        "tags": [
          "Searching with CHEESE"
        ],
        "summary": "Search Batch",
        "description": "Run a similarity search for multiple query molecules in a single request and use centroid or batch mode to identify the set similar molecules.\n\nBatch search modes are:\n- 'centroid' mode: computes mean embedding (centroid) for the input set of molecules and returns neighbors closest to the centroid\n- 'batch' mode: retrieves similar molecules based on the list of molecules in the query by retrieving N similar molecules for each molecule in the query list   \n\nMultiple databases can be specified for the search.\n\nParameters:\n- search_type (str): The type of search to perform.\n- n_neighbors (int): The number of neighbors to retrieve.\n- search_input (List[str]): The input molecules to search by.\n- db_names (str): The databases to use in the search.\n- search_mode (str): The mode of the batch search (default is \"centroid\", another is \"batch\").\n\nReturns:\n- A dictionary with list of retrieved molecules, list of molecule ids, and list of origin DBs for each molecule.",
        "operationId": "search_batch_batch_search_get",
        "parameters": [
          {
            "description": "The type of search to perform",
            "required": false,
            "schema": {
              "allOf": [
                {
                  "$ref": "#/components/schemas/EmbNamesNoAll"
                }
              ],
              "description": "The type of search to perform",
              "default": "espsim_shape"
            },
            "name": "search_type",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "N Neighbors",
              "type": "integer",
              "default": 30
            },
            "name": "n_neighbors",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "Search Input",
              "type": "array",
              "items": {
                "type": "string"
              },
              "default": [
                "CC(=O)Oc1ccccc1C(=O)O",
                "CC(=O)Oc1ccccc1C(N)=O",
                "CC(=O)Nc1ccccc1C(=O)O"
              ]
            },
            "name": "search_input",
            "in": "query"
          },
          {
            "description": "Selected Databases",
            "required": false,
            "schema": {
              "type": "array",
              "items": {
                "$ref": "#/components/schemas/DatabaseEnumAll"
              },
              "description": "Selected Databases",
              "default": [
                "CHEMINFINITA-SYNTHON"
              ]
            },
            "name": "db_names",
            "in": "query"
          },
          {
            "description": "The type of batch search to perform",
            "required": false,
            "schema": {
              "allOf": [
                {
                  "$ref": "#/components/schemas/SearchModes"
                }
              ],
              "description": "The type of batch search to perform",
              "default": "centroid"
            },
            "name": "search_mode",
            "in": "query"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          }
        ]
      }
    },
    "/embeddings": {
      "get": {
        "tags": [
          "Computing Embeddings (for on-prem users only)"
        ],
        "summary": "Embeddings",
        "description": "Get embeddings for a list of molecules.\n\nThis endpoint allows users to get embeddings for a list of molecules.\n\nParameters:\n- search_input (List[str]): The input molecules to get embeddings for.\n- search_type (List[str]): The type of embeddings to calculate.\n- save_embs (bool): Whether to save embeddings (default is False)\n- dest (str): Destination path to save the embeddings (default is /tmp/embeddings).\n\nReturns:\n- A JSON response containing the embeddings for the input molecules.",
        "operationId": "embeddings_embeddings_get",
        "parameters": [
          {
            "required": false,
            "schema": {
              "title": "Search Input",
              "type": "array",
              "items": {
                "type": "string"
              },
              "default": [
                "CC(=O)Oc1ccccc1C(=O)O",
                "CC(=O)Oc1ccccc1C(N)=O",
                "CC(=O)Nc1ccccc1C(=O)O"
              ]
            },
            "name": "search_input",
            "in": "query"
          },
          {
            "description": "Type of embeddings to calculate",
            "required": false,
            "schema": {
              "allOf": [
                {
                  "$ref": "#/components/schemas/EmbNames"
                }
              ],
              "description": "Type of embeddings to calculate",
              "default": "all"
            },
            "name": "search_type",
            "in": "query"
          },
          {
            "description": "Whether to save embeddings",
            "required": false,
            "schema": {
              "title": "Save Embs",
              "type": "boolean",
              "description": "Whether to save embeddings",
              "default": true
            },
            "name": "save_embs",
            "in": "query"
          },
          {
            "description": "Destination path",
            "required": false,
            "schema": {
              "title": "Dest",
              "type": "string",
              "description": "Destination path",
              "default": "/tmp/embeddings"
            },
            "name": "dest",
            "in": "query"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          }
        ]
      }
    },
    "/centroid_embeddings": {
      "get": {
        "tags": [
          "Computing Embeddings (for on-prem users only)"
        ],
        "summary": "Centroid Embeddings",
        "description": "Get centroid embeddings for a specified database and search type.\n\nThis endpoint returns the centroid embeddings for a given database and search type.\n\nParameters:\n- db_name (str): The name of the database.\n- search_type (str): The type of search to perform.\n- save_embs (bool): Whether to save centroid embeddings (default is False)\n- dest (str): Destination path to save the centroid embeddings (default is /tmp/embeddings).\n\nReturns:\n- A JSON response containing the centroid embeddings.",
        "operationId": "centroid_embeddings_centroid_embeddings_get",
        "parameters": [
          {
            "description": "Selected Database",
            "required": false,
            "schema": {
              "allOf": [
                {
                  "$ref": "#/components/schemas/DatabaseEnumAll"
                }
              ],
              "description": "Selected Database",
              "default": "CHEMINFINITA-SYNTHON"
            },
            "name": "db_name",
            "in": "query"
          },
          {
            "description": "The type of centroids to get",
            "required": false,
            "schema": {
              "allOf": [
                {
                  "$ref": "#/components/schemas/SearchTypes"
                }
              ],
              "description": "The type of centroids to get",
              "default": "espsim_shape"
            },
            "name": "search_type",
            "in": "query"
          },
          {
            "description": "Whether to get centroid molecules",
            "required": false,
            "schema": {
              "title": "Centroid Mols",
              "type": "boolean",
              "description": "Whether to get centroid molecules",
              "default": true
            },
            "name": "centroid_mols",
            "in": "query"
          },
          {
            "description": "Whether to save embeddings",
            "required": false,
            "schema": {
              "title": "Save Embs",
              "type": "boolean",
              "description": "Whether to save embeddings",
              "default": true
            },
            "name": "save_embs",
            "in": "query"
          },
          {
            "description": "Whether to compute centroid molecules for custom databases. Please note that depending on the size of Your database, it may take a few hours ! ",
            "required": false,
            "schema": {
              "title": "Compute Centroid Mols",
              "type": "boolean",
              "description": "Whether to compute centroid molecules for custom databases. Please note that depending on the size of Your database, it may take a few hours ! ",
              "default": false
            },
            "name": "compute_centroid_mols",
            "in": "query"
          },
          {
            "description": "Destination path",
            "required": false,
            "schema": {
              "title": "Dest",
              "type": "string",
              "description": "Destination path",
              "default": "/data/embeddings"
            },
            "name": "dest",
            "in": "query"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          }
        ]
      }
    },
    "/visualise": {
      "get": {
        "tags": [
          "Chemical Space Visualisation (for on-prem users only)"
        ],
        "summary": "Visualise",
        "description": "Get 2D coordinates for a list of molecules.\n\nThis endpoint allows users to get 2D coordinates for a list of molecules.\n\nParameters:\n- search_input (List[str]): The input molecules to get 2D coordinates for.\n- search_type (List[str]): The type of 2D coordinates to calculate.\n- visualisation_method (List[str]): The method (PCA or UMAP) of dimensionality reduction.\n- save_coordinates (bool): Whether to save the visualization coordinates.\n- dest (str): Destination path to save the coordinates (default is /tmp/visualization_coordinates).\n\nReturns:\n- A JSON response containing the 2D coordinates for the input molecules.",
        "operationId": "visualise_visualise_get",
        "parameters": [
          {
            "required": false,
            "schema": {
              "title": "Search Input",
              "type": "array",
              "items": {
                "type": "string"
              },
              "default": [
                "CC(=O)Oc1ccccc1C(=O)O",
                "CC(=O)Oc1ccncc1C(=O)O",
                "CC(=O)Oc1cnccc1C(=O)O"
              ]
            },
            "name": "search_input",
            "in": "query"
          },
          {
            "description": "Type of embeddings to calculate",
            "required": false,
            "schema": {
              "allOf": [
                {
                  "$ref": "#/components/schemas/EmbNamesNoAll"
                }
              ],
              "description": "Type of embeddings to calculate",
              "default": "morgan"
            },
            "name": "search_type",
            "in": "query"
          },
          {
            "description": "Type of visualisation",
            "required": false,
            "schema": {
              "allOf": [
                {
                  "$ref": "#/components/schemas/VisualisationMethods"
                }
              ],
              "description": "Type of visualisation",
              "default": "umap"
            },
            "name": "visualisation_method",
            "in": "query"
          },
          {
            "description": "Whether to save the visualization coordinates",
            "required": false,
            "schema": {
              "title": "Save Coordinates",
              "type": "boolean",
              "description": "Whether to save the visualization coordinates",
              "default": false
            },
            "name": "save_coordinates",
            "in": "query"
          },
          {
            "description": "Destination path",
            "required": false,
            "schema": {
              "title": "Dest",
              "type": "string",
              "description": "Destination path",
              "default": "/tmp/visualization_coordinates"
            },
            "name": "dest",
            "in": "query"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          }
        ]
      }
    },
    "/similarity": {
      "get": {
        "tags": [
          "Similarity (for on-prem users only)"
        ],
        "summary": "Similarity",
        "description": "Calculate the similarity between two molecules.\n\nThis endpoint allows users to calculate the similarity between two molecules based on their SMILES strings.\n\nParameters:\n- smiles1 (str): The SMILES string of the first molecule.\n- smiles2 (str): The SMILES string of the second molecule.\n- similarity_metric (EmbNames): The model and similarity metric to use for the calculation.\n- distance_type (DistanceType): The type of vector distance to use for the similarity calculation.\n\nReturns:\n- A JSON response containing the similarity score between the two molecules.",
        "operationId": "similarity_similarity_get",
        "parameters": [
          {
            "required": false,
            "schema": {
              "title": "Smiles1",
              "type": "string",
              "default": "CC(=O)Oc1ccccc1C(=O)O"
            },
            "name": "smiles1",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "Smiles2",
              "type": "string",
              "default": "CC(=O)Oc1cnccc1C(=O)O"
            },
            "name": "smiles2",
            "in": "query"
          },
          {
            "description": "CHEESE Model & Similarity Metric",
            "required": false,
            "schema": {
              "allOf": [
                {
                  "$ref": "#/components/schemas/EmbNames"
                }
              ],
              "description": "CHEESE Model & Similarity Metric",
              "default": "all"
            },
            "name": "similarity_metric",
            "in": "query"
          },
          {
            "description": "Select Vector Distance",
            "required": false,
            "schema": {
              "allOf": [
                {
                  "$ref": "#/components/schemas/DistanceType"
                }
              ],
              "description": "Select Vector Distance",
              "default": "euclidean"
            },
            "name": "distance_type",
            "in": "query"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          }
        ]
      }
    },
    "/similarity_matrix": {
      "get": {
        "tags": [
          "Similarity (for on-prem users only)"
        ],
        "summary": "Similarity Matrix",
        "description": "Calculate the similarity matrix between a list of molecules\n\nThis endpoint allows users to calculate the similarity between list of molecules based on their SMILES strings.\n\nParameters:\n- smiles (List[str]): List of smiles.\n- similarity_metric (EmbNames): The model and similarity metric to use for the calculation.\n- distance_type (DistanceType): The type of vector distance to use for the similarity calculation.\n- save_matrix (bool): Whether to save the similarity matrix (default is False)\n- dest (str): Destination path to save the embeddings of the similarity matrix (default is /tmp/sim_matrix.npy , resulting files will have similarity metrics as suffixes !).\n\nReturns:\n- A JSON response containing the similarity scores between the list of molecules.",
        "operationId": "similarity_matrix_similarity_matrix_get",
        "parameters": [
          {
            "required": false,
            "schema": {
              "title": "Smiles",
              "type": "array",
              "items": {
                "type": "string"
              },
              "default": [
                "CC(=O)Oc1ccccc1C(=O)O",
                "CC(=O)Oc1ccncc1C(=O)O",
                "CC(=O)Oc1cnccc1C(=O)O"
              ]
            },
            "name": "smiles",
            "in": "query"
          },
          {
            "description": "CHEESE Model & Similarity Metric",
            "required": false,
            "schema": {
              "allOf": [
                {
                  "$ref": "#/components/schemas/EmbNames"
                }
              ],
              "description": "CHEESE Model & Similarity Metric",
              "default": "all"
            },
            "name": "similarity_metric",
            "in": "query"
          },
          {
            "description": "Select Vector Distance",
            "required": false,
            "schema": {
              "allOf": [
                {
                  "$ref": "#/components/schemas/DistanceType"
                }
              ],
              "description": "Select Vector Distance",
              "default": "euclidean"
            },
            "name": "distance_type",
            "in": "query"
          },
          {
            "description": "Whether to save the resulting similarity matrix",
            "required": false,
            "schema": {
              "title": "Save Matrix",
              "type": "boolean",
              "description": "Whether to save the resulting similarity matrix",
              "default": false
            },
            "name": "save_matrix",
            "in": "query"
          },
          {
            "description": "Destination path",
            "required": false,
            "schema": {
              "title": "Dest",
              "type": "string",
              "description": "Destination path",
              "default": "/tmp/sim_matrix.npy"
            },
            "name": "dest",
            "in": "query"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          }
        ]
      }
    },
    "/molsearch_embedding": {
      "get": {
        "tags": [
          "Advanced (for on-prem users only)"
        ],
        "summary": "Search Embedding",
        "description": "Search for a single molecule based on various criteria.\n\nThis endpoint allows users to search for a molecule embedding using different search types and qualities. \nMultiple databases can be specified for the search.\n\nParameters:\n- query_emb (List[float]): The molecule embedding used as an input to the search (default is the morgan embedding of Aspirin ).\n- search_type (SearchTypes): The type of search to perform (default is \"morgan\").\n- search_quality (SearchQuality): The quality of the search (default is \"fast\").\n- db_names (List[DatabaseEnum]): The databases to use for the search.\n- n_neighbors (int): The number of neighbors to consider (default is 30).\n\nReturns:\n- A dictionary containing the search input, search type, number of neighbors, search quality, and databases used.",
        "operationId": "search_embedding_molsearch_embedding_get",
        "parameters": [
          {
            "required": false,
            "schema": {
              "title": "Query Emb",
              "type": "array",
              "items": {
                "type": "number"
              }
            },
            "name": "query_emb",
            "in": "query"
          },
          {
            "description": "The type of search to perform",
            "required": false,
            "schema": {
              "allOf": [
                {
                  "$ref": "#/components/schemas/SearchTypes"
                }
              ],
              "description": "The type of search to perform",
              "default": "espsim_shape"
            },
            "name": "search_type",
            "in": "query"
          },
          {
            "description": "Speed/Accuracy Tradeoff",
            "required": false,
            "schema": {
              "allOf": [
                {
                  "$ref": "#/components/schemas/SearchQuality"
                }
              ],
              "description": "Speed/Accuracy Tradeoff",
              "default": "fast"
            },
            "name": "search_quality",
            "in": "query"
          },
          {
            "description": "Selected Databases",
            "required": false,
            "schema": {
              "type": "array",
              "items": {
                "$ref": "#/components/schemas/DatabaseEnumAll"
              },
              "description": "Selected Databases",
              "default": [
                "CHEMINFINITA-SYNTHON"
              ]
            },
            "name": "db_names",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "N Neighbors",
              "type": "integer",
              "default": 30
            },
            "name": "n_neighbors",
            "in": "query"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          }
        ]
      }
    },
    "/cluster": {
      "get": {
        "tags": [
          "Advanced (for on-prem users only)"
        ],
        "summary": "Cluster",
        "description": "Retrieve a cluster by its ID\n\nThis endpoint allows users to get embeddings and molecules of a particular cluster. \n\nParameters:\n- cluster_id (int): The cluster ID\n- db_name (DatabaseEnum): The database to use for the search.\n- search_type (SearchTypes): The type of search to perform (default is \"morgan\").\n- save_embs (bool): Whether to save embeddings for the retrieved cluster (default is False)\n- dest (str): Destination path to save the embeddings of the retrieved cluster (default is /tmp/cluster_embeddings).\n\nReturns:\n- A dictionary containing the molecules of the nearest cluster, possibly with a message pointing to the path where to find embeddings",
        "operationId": "cluster_cluster_get",
        "parameters": [
          {
            "required": false,
            "schema": {
              "title": "Cluster Id",
              "type": "integer",
              "default": 0
            },
            "name": "cluster_id",
            "in": "query"
          },
          {
            "description": "Selected Database",
            "required": false,
            "schema": {
              "allOf": [
                {
                  "$ref": "#/components/schemas/DatabaseEnumAll"
                }
              ],
              "description": "Selected Database",
              "default": "CHEMINFINITA-SYNTHON"
            },
            "name": "db_name",
            "in": "query"
          },
          {
            "description": "The search type",
            "required": false,
            "schema": {
              "allOf": [
                {
                  "$ref": "#/components/schemas/SearchTypes"
                }
              ],
              "description": "The search type",
              "default": "espsim_shape"
            },
            "name": "search_type",
            "in": "query"
          },
          {
            "description": "Whether to save embeddings for the retrieved cluster",
            "required": false,
            "schema": {
              "title": "Save Embs",
              "type": "boolean",
              "description": "Whether to save embeddings for the retrieved cluster",
              "default": false
            },
            "name": "save_embs",
            "in": "query"
          },
          {
            "description": "Destination path",
            "required": false,
            "schema": {
              "title": "Dest",
              "type": "string",
              "description": "Destination path",
              "default": "/tmp/cluster_embeddings"
            },
            "name": "dest",
            "in": "query"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          }
        ]
      }
    },
    "/nearest_cluster": {
      "get": {
        "tags": [
          "Advanced (for on-prem users only)"
        ],
        "summary": "Nearest Cluster",
        "description": "Retrieve the nearest cluster to a single molecule\n\nThis endpoint allows users to get the nearest cluster to a molecule according to a search type. \n\nParameters:\n- search_input (str): The molecule embedding used as an input to the search (default is the morgan embedding of Aspirin ).\n- db_name (DatabaseEnum): The database to use for the search.\n- search_type (SearchTypes): The type of search to perform (default is \"morgan\").\n- save_embs (bool): Whether to save embeddings for the nearest cluster (default is False)\n- dest (str): Destination path to save the embeddings of the nearest cluster (default is /tmp/nearest_embeddings).\n\nReturns:\n- A dictionary containing the molecules of the nearest cluster, possibly with a message pointing to the path where to find embeddings",
        "operationId": "nearest_cluster_nearest_cluster_get",
        "parameters": [
          {
            "required": false,
            "schema": {
              "title": "Search Input",
              "type": "string",
              "default": "CC(=O)Oc1ccccc1C(=O)O"
            },
            "name": "search_input",
            "in": "query"
          },
          {
            "description": "Selected Database",
            "required": false,
            "schema": {
              "allOf": [
                {
                  "$ref": "#/components/schemas/DatabaseEnumAll"
                }
              ],
              "description": "Selected Database",
              "default": "CHEMINFINITA-SYNTHON"
            },
            "name": "db_name",
            "in": "query"
          },
          {
            "description": "The search type",
            "required": false,
            "schema": {
              "allOf": [
                {
                  "$ref": "#/components/schemas/SearchTypes"
                }
              ],
              "description": "The search type",
              "default": "espsim_shape"
            },
            "name": "search_type",
            "in": "query"
          },
          {
            "description": "Whether to save embeddings for the retrieved cluster",
            "required": false,
            "schema": {
              "title": "Save Embs",
              "type": "boolean",
              "description": "Whether to save embeddings for the retrieved cluster",
              "default": false
            },
            "name": "save_embs",
            "in": "query"
          },
          {
            "description": "Destination path",
            "required": false,
            "schema": {
              "title": "Dest",
              "type": "string",
              "description": "Destination path",
              "default": "/tmp/nearest_embeddings"
            },
            "name": "dest",
            "in": "query"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          }
        ]
      }
    },
    "/batch_similarity": {
      "get": {
        "tags": [
          "Similarity (for on-prem users only)"
        ],
        "summary": "Batch Similarity",
        "description": "Compute similarity between two sets of molecules: either centroid (pharmacophore) or batch (enrichment)\n'centroid' mode: computes mean embedding (centroid) for the first and second set of molecules and returns its distance\n'batch' mode: means it computes similarities of max 10K randomly sampled pairs and averages the result \n\nParameters:\n- smiles1 and smiles2 (List[str]): Lists of smiles.\n- similarity_metric (EmbNames): The model and similarity metric to use for the calculation.\n- distance_type (DistanceType): The type of vector distance to use for the similarity calculation.\n- sim_mode (SearchModes): The mode of similarity (default is \"centroid\", another is \"batch\").\n\nReturns:\n- A dictionary containing the molecules of the nearest cluster, possibly with a message pointing to the path where to find embeddings",
        "operationId": "batch_similarity_batch_similarity_get",
        "parameters": [
          {
            "required": false,
            "schema": {
              "title": "Smiles1",
              "type": "array",
              "items": {
                "type": "string"
              },
              "default": [
                "CC(=O)Oc1ccccc1C(=O)O",
                "CC(=O)Oc1ccncc1C(=O)O",
                "CC(=O)Oc1cnccc1C(=O)O"
              ]
            },
            "name": "smiles1",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "Smiles2",
              "type": "array",
              "items": {
                "type": "string"
              },
              "default": [
                "CC=O",
                "CCC",
                "CCCC=O"
              ]
            },
            "name": "smiles2",
            "in": "query"
          },
          {
            "description": "CHEESE Model & Similarity Metric",
            "required": false,
            "schema": {
              "allOf": [
                {
                  "$ref": "#/components/schemas/EmbNames"
                }
              ],
              "description": "CHEESE Model & Similarity Metric",
              "default": "all"
            },
            "name": "similarity_metric",
            "in": "query"
          },
          {
            "description": "Select Vector Distance",
            "required": false,
            "schema": {
              "allOf": [
                {
                  "$ref": "#/components/schemas/DistanceType"
                }
              ],
              "description": "Select Vector Distance",
              "default": "euclidean"
            },
            "name": "distance_type",
            "in": "query"
          },
          {
            "description": "The mode of similarity",
            "required": false,
            "schema": {
              "allOf": [
                {
                  "$ref": "#/components/schemas/SearchModes"
                }
              ],
              "description": "The mode of similarity",
              "default": "centroid"
            },
            "name": "sim_mode",
            "in": "query"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          }
        ]
      }
    },
    "/database_similarity": {
      "get": {
        "tags": [
          "Similarity (for on-prem users only)"
        ],
        "summary": "Database Similarity",
        "description": "Estimate distance between two databases based on centroid embeddings.\n\nThis endpoint returns the distance score between two databases. This functionality assumes that inference was already performed on the databases !\n\nParameters:\n- db_name (str): The name of the database.\n- target_db_name (str): The name of the database against which to compare.\n- similarity_metric (str): The type of similarity to get.\n- sim_mode (str): The mode of similarity. 'centroid' computes similarity between the centroids of centroids of the databases. 'batch' computes average similarity between the database centroids\n\nReturns:\n- A JSON response containing the centroid embeddings.",
        "operationId": "database_similarity_database_similarity_get",
        "parameters": [
          {
            "description": "Selected database",
            "required": false,
            "schema": {
              "allOf": [
                {
                  "$ref": "#/components/schemas/DatabaseEnumAll"
                }
              ],
              "description": "Selected database",
              "default": "CHEMINFINITA-SYNTHON"
            },
            "name": "db_name",
            "in": "query"
          },
          {
            "description": "Target database against whichto compare to",
            "required": false,
            "schema": {
              "allOf": [
                {
                  "$ref": "#/components/schemas/DatabaseEnumAll"
                }
              ],
              "description": "Target database against whichto compare to",
              "default": "CHEMINFINITA-SYNTHON"
            },
            "name": "target_db_name",
            "in": "query"
          },
          {
            "description": "The similarity metric",
            "required": false,
            "schema": {
              "allOf": [
                {
                  "$ref": "#/components/schemas/EmbNamesNoAll"
                }
              ],
              "description": "The similarity metric",
              "default": "morgan"
            },
            "name": "similarity_metric",
            "in": "query"
          },
          {
            "description": "Select Vector Distance",
            "required": false,
            "schema": {
              "allOf": [
                {
                  "$ref": "#/components/schemas/DistanceType"
                }
              ],
              "description": "Select Vector Distance",
              "default": "euclidean"
            },
            "name": "distance_type",
            "in": "query"
          },
          {
            "description": "The mode of similarity",
            "required": false,
            "schema": {
              "allOf": [
                {
                  "$ref": "#/components/schemas/SearchModes"
                }
              ],
              "description": "The mode of similarity",
              "default": "centroid"
            },
            "name": "sim_mode",
            "in": "query"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          }
        ]
      }
    },
    "/license_information": {
      "get": {
        "tags": [
          "Advanced (for on-prem users only)"
        ],
        "summary": "License",
        "operationId": "license_license_information_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          }
        ]
      }
    },
    "/generate_license_key": {
      "get": {
        "tags": [
          "Advanced (for on-prem users only)"
        ],
        "summary": "License Key",
        "operationId": "license_key_generate_license_key_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          }
        ]
      }
    },
    "/embeddings_file": {
      "get": {
        "tags": [
          "CLI commands (for on-prem users only)"
        ],
        "summary": "Embeddings File",
        "description": "Get embeddings for a file of molecules.\n\nThis endpoint allows users to get embeddings for a list of molecules uploaded in a CSV file.\n\nParameters:\n- input_file (List[str]): The input file to get embeddings for.\n- smiles_col (str) : The column name of SMILES strings in case of a csv file (default 'SMILES')\n- search_type (List[str]): The type of embeddings to calculate.\n- dest (str): Destination path to save the embeddings (default is /tmp/embeddings).\n\nReturns:\n- A JSON response containing the status of the request if it's successful.",
        "operationId": "embeddings_file_embeddings_file_get",
        "parameters": [
          {
            "required": false,
            "schema": {
              "title": "Input File",
              "type": "string",
              "default": ""
            },
            "name": "input_file",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "Smiles Col",
              "type": "string",
              "default": "SMILES"
            },
            "name": "smiles_col",
            "in": "query"
          },
          {
            "description": "Type of embeddings to calculate",
            "required": false,
            "schema": {
              "allOf": [
                {
                  "$ref": "#/components/schemas/EmbNames"
                }
              ],
              "description": "Type of embeddings to calculate",
              "default": "all"
            },
            "name": "search_type",
            "in": "query"
          },
          {
            "description": "Destination path",
            "required": false,
            "schema": {
              "title": "Dest Folder",
              "type": "string",
              "description": "Destination path",
              "default": "/tmp/embeddings"
            },
            "name": "dest_folder",
            "in": "query"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          }
        ]
      }
    },
    "/search_file": {
      "get": {
        "tags": [
          "CLI commands (for on-prem users only)"
        ],
        "summary": "Search File",
        "description": "Search a of molecules based on various criteria.\n\nThis endpoint allows users to search for multiple molecules using different search types and qualities. \nMultiple databases can be specified for the search.\n\nParameters:\n- input_file (str) : Path to the input file\n- smiles_col (str) : The column name of SMILES strings in case of a csv file (default 'SMILES')\n- search_type (str): The type of search to perform.\n- n_neighbors (int): The number of neighbors to consider.\n- search_quality (str): The quality of the search.\n- db_names (List[str]): The databases to use for the search.\n- output_file (str) : Path to the destination file\n\nReturns:\n- A dictionary containing the search results.",
        "operationId": "search_file_search_file_get",
        "parameters": [
          {
            "required": false,
            "schema": {
              "title": "Input File",
              "type": "string",
              "default": ""
            },
            "name": "input_file",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "Smiles Col",
              "type": "string",
              "default": "SMILES"
            },
            "name": "smiles_col",
            "in": "query"
          },
          {
            "description": "The type of search to perform",
            "required": false,
            "schema": {
              "allOf": [
                {
                  "$ref": "#/components/schemas/SearchTypes"
                }
              ],
              "description": "The type of search to perform",
              "default": "espsim_shape"
            },
            "name": "search_type",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "N Neighbors",
              "type": "integer",
              "default": 30
            },
            "name": "n_neighbors",
            "in": "query"
          },
          {
            "description": "Speed/Accuracy Tradeoff",
            "required": false,
            "schema": {
              "allOf": [
                {
                  "$ref": "#/components/schemas/SearchQuality"
                }
              ],
              "description": "Speed/Accuracy Tradeoff",
              "default": "fast"
            },
            "name": "search_quality",
            "in": "query"
          },
          {
            "description": "Selected Databases",
            "required": false,
            "schema": {
              "title": "Db Names",
              "type": "string",
              "description": "Selected Databases",
              "default": "ZINC15,ENAMINE-REAL"
            },
            "name": "db_names",
            "in": "query"
          },
          {
            "description": "Destination file",
            "required": false,
            "schema": {
              "title": "Output File",
              "type": "string",
              "description": "Destination file",
              "default": "/tmp/search_results.csv"
            },
            "name": "output_file",
            "in": "query"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          }
        ]
      }
    },
    "/visualise_file": {
      "get": {
        "tags": [
          "CLI commands (for on-prem users only)"
        ],
        "summary": "Visualize File",
        "description": "Get 2D visualization coordinates for a file of molecules.\n\nThis endpoint allows users to get 2D coordinates for a file of molecules.\n\nParameters:\n- input_file (str) : Path to the input file\n- smiles_col (str) : The column name of SMILES strings in case of a csv file (default 'SMILES')\n- search_type (str): The type of CHEESE coordinates to calculate. (default : 'morgan')\n- visualisation_method (List[str]): The method (PCA or UMAP) of dimensionality reduction.\n- dest_folder (str): Destination path to save the coordinates (default is /tmp/visualization_coordinates).\n\nReturns:\n- A JSON response containing the 2D coordinates for the input molecules.",
        "operationId": "visualize_file_visualise_file_get",
        "parameters": [
          {
            "required": false,
            "schema": {
              "title": "Input File",
              "type": "string",
              "default": ""
            },
            "name": "input_file",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "Smiles Col",
              "type": "string",
              "default": "SMILES"
            },
            "name": "smiles_col",
            "in": "query"
          },
          {
            "description": "Type of embeddings to calculate",
            "required": false,
            "schema": {
              "allOf": [
                {
                  "$ref": "#/components/schemas/EmbNamesNoAll"
                }
              ],
              "description": "Type of embeddings to calculate",
              "default": "morgan"
            },
            "name": "search_type",
            "in": "query"
          },
          {
            "description": "Type of visualisation",
            "required": false,
            "schema": {
              "allOf": [
                {
                  "$ref": "#/components/schemas/VisualisationMethods"
                }
              ],
              "description": "Type of visualisation",
              "default": "umap"
            },
            "name": "visualisation_method",
            "in": "query"
          },
          {
            "description": "Destination path",
            "required": false,
            "schema": {
              "title": "Dest Folder",
              "type": "string",
              "description": "Destination path",
              "default": "/tmp/visualization_coordinates"
            },
            "name": "dest_folder",
            "in": "query"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          }
        ]
      }
    }
  },
  "components": {
    "schemas": {
      "AnyDictModel": {
        "title": "AnyDictModel",
        "type": "object",
        "properties": {
          "prop_ranges": {
            "title": "Prop Ranges",
            "type": "object",
            "default": {
              "caco2_wang": {
                "min": -100000,
                "max": 100000
              },
              "clearance_hepatocyte_az": {
                "min": -100000,
                "max": 100000
              },
              "clearance_microsome_az": {
                "min": -100000,
                "max": 100000
              },
              "half_life_obach": {
                "min": -100000,
                "max": 100000
              },
              "ld50_zhu": {
                "min": -100000,
                "max": 100000
              },
              "lipophilicity_astrazeneca": {
                "min": -100000,
                "max": 100000
              },
              "ppbr_az": {
                "min": -100000,
                "max": 100000
              },
              "solubility_aqsoldb": {
                "min": -100000,
                "max": 100000
              },
              "vdss_lombardo": {
                "min": -100000,
                "max": 100000
              },
              "ames": {
                "min": -100000,
                "max": 100000
              },
              "bbb_martins": {
                "min": -100000,
                "max": 100000
              },
              "bioavailability_ma": {
                "min": -100000,
                "max": 100000
              },
              "cyp2c9_substrate_carbonmangels": {
                "min": -100000,
                "max": 100000
              },
              "cyp2c9_veith": {
                "min": -100000,
                "max": 100000
              },
              "cyp2d6_substrate_carbonmangels": {
                "min": -100000,
                "max": 100000
              },
              "cyp2d6_veith": {
                "min": -100000,
                "max": 100000
              },
              "cyp3a4_substrate_carbonmangels": {
                "min": -100000,
                "max": 100000
              },
              "cyp3a4_veith": {
                "min": -100000,
                "max": 100000
              },
              "dili": {
                "min": -100000,
                "max": 100000
              },
              "herg": {
                "min": -100000,
                "max": 100000
              },
              "hia_hou": {
                "min": -100000,
                "max": 100000
              },
              "pgp_broccatelli": {
                "min": -100000,
                "max": 100000
              },
              "molecular_weight": {
                "min": -100000,
                "max": 100000
              },
              "formal_charge": {
                "min": -100000,
                "max": 100000
              },
              "clogp": {
                "min": -100000,
                "max": 100000
              },
              "heavy_atoms": {
                "min": -100000,
                "max": 100000
              },
              "h_bond_acceptors": {
                "min": -100000,
                "max": 100000
              },
              "h_bond_donor": {
                "min": -100000,
                "max": 100000
              },
              "rotatable_bonds": {
                "min": -100000,
                "max": 100000
              },
              "num_of_rings": {
                "min": -100000,
                "max": 100000
              },
              "molar_refractivity": {
                "min": -100000,
                "max": 100000
              },
              "number_of_atoms": {
                "min": -100000,
                "max": 100000
              },
              "topological_surface_area_mapping": {
                "min": -100000,
                "max": 100000
              }
            }
          },
          "neighbor_ids": {
            "title": "Neighbor Ids",
            "type": "array",
            "items": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "integer"
                }
              ]
            },
            "default": []
          }
        }
      },
      "DatabaseEnumAll": {
        "title": "DatabaseEnumAll",
        "enum": [
          "CHEMINFINITA-SYNTHON",
          "CHEMRIYA",
          "CHEMSPACE-5B-BEYOND-RO5",
          "CHEMSPACE-5B-FREEDOM",
          "CHEMSPACE-5B-RO5",
          "CHEMSPACE-FREEDOM-SYNTHON",
          "CHEMSPACE-SCREENING",
          "EMOLECULES-EXPLORE-SYNTHON",
          "EMOLECULES-SYNPLE-SYNTHON",
          "ENAMINE-AA",
          "ENAMINE-REAL",
          "ENAMINE-REAL-V5A-SYNTHON",
          "EXPLORE-DIVERSE",
          "EXPLORE-ENUMERATED",
          "MCULE-FULL",
          "MCULE-IN-STOCK",
          "MOLECULE-ONE",
          "MOLECULEONE-D2B-SYNTHON",
          "MOLPORT",
          "SYNPLE-4B",
          "XTALPI",
          "XTALPI-SYNTHON",
          "ZINC15"
        ],
        "description": "An enumeration."
      },
      "DistanceType": {
        "title": "DistanceType",
        "enum": [
          "euclidean",
          "cosine"
        ],
        "type": "string",
        "description": "An enumeration."
      },
      "EmbNames": {
        "title": "EmbNames",
        "enum": [
          "all",
          "morgan",
          "espsim_electrostatic",
          "espsim_shape",
          "synthongpt"
        ],
        "description": "An enumeration."
      },
      "EmbNamesNoAll": {
        "title": "EmbNamesNoAll",
        "enum": [
          "morgan",
          "espsim_electrostatic",
          "espsim_shape",
          "synthongpt"
        ],
        "description": "An enumeration."
      },
      "FileFormat": {
        "title": "FileFormat",
        "enum": [
          "csv",
          "xlsx",
          "json",
          "sdf"
        ],
        "type": "string",
        "description": "An enumeration."
      },
      "FilteringEnum": {
        "title": "FilteringEnum",
        "enum": [
          "Lipinsky rule of 5",
          "QED",
          "REOS",
          "Veber",
          "Ghose",
          "Drug-like",
          "Rough similar properties",
          "Murcko scaffold",
          "Murcko scaffold hop",
          "Substructure",
          "Superstructure",
          "No solvents",
          "No rare atoms",
          "Regioisomers",
          "PAINS"
        ],
        "type": "string",
        "description": "An enumeration."
      },
      "HTTPValidationError": {
        "title": "HTTPValidationError",
        "type": "object",
        "properties": {
          "detail": {
            "title": "Detail",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ValidationError"
            }
          }
        }
      },
      "OrderingEnum": {
        "title": "OrderingEnum",
        "enum": [
          "Similarity",
          "Morgan Tanimoto",
          "MACS",
          "ERG",
          "USR",
          "Morgan Dissimilarity",
          "USR Dissimilarity",
          "Espsim Dissimilarity",
          "Shapesim Dissimilarity"
        ],
        "type": "string",
        "description": "An enumeration."
      },
      "ResponseFormat": {
        "title": "ResponseFormat",
        "enum": [
          "json",
          "csv"
        ],
        "type": "string",
        "description": "An enumeration."
      },
      "SearchModes": {
        "title": "SearchModes",
        "enum": [
          "centroid",
          "batch"
        ],
        "type": "string",
        "description": "An enumeration."
      },
      "SearchQuality": {
        "title": "SearchQuality",
        "enum": [
          "fast",
          "accurate",
          "very_accurate",
          "100",
          "1000",
          "10000"
        ],
        "type": "string",
        "description": "An enumeration."
      },
      "SearchTypes": {
        "title": "SearchTypes",
        "enum": [
          "morgan",
          "espsim_electrostatic",
          "espsim_shape",
          "synthongpt"
        ],
        "type": "string",
        "description": "An enumeration."
      },
      "ValidationError": {
        "title": "ValidationError",
        "required": [
          "loc",
          "msg",
          "type"
        ],
        "type": "object",
        "properties": {
          "loc": {
            "title": "Location",
            "type": "array",
            "items": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "integer"
                }
              ]
            }
          },
          "msg": {
            "title": "Message",
            "type": "string"
          },
          "type": {
            "title": "Error Type",
            "type": "string"
          }
        }
      },
      "VisualisationMethods": {
        "title": "VisualisationMethods",
        "enum": [
          "umap",
          "pca"
        ],
        "description": "An enumeration."
      }
    },
    "securitySchemes": {
      "APIKeyHeader": {
        "type": "apiKey",
        "in": "header",
        "name": "X-API-Key"
      }
    }
  },
  "tags": [
    {
      "name": "Searching with CHEESE",
      "description": "Search molecules programatically!"
    },
    {
      "name": "SynthonGPT",
      "description": "SynthonGPT-specific search helpers and job submission endpoints."
    },
    {
      "name": "Computing Embeddings (for on-prem users only)",
      "description": "Fetching CHEESE vector embeddings"
    },
    {
      "name": "Predict Properties",
      "description": "Property prediction"
    },
    {
      "name": "Testing and Health Checks",
      "description": "Testing if everything in the API works as it should."
    },
    {
      "name": "Similarity (for on-prem users only)",
      "description": "Compute Shape and Electrostatic Similarity with CHEESE."
    },
    {
      "name": "Advanced (for on-prem users only)",
      "description": "Miscellaneous features to play with CHEESE."
    },
    {
      "name": "CLI commands (for on-prem users only)",
      "description": "CLI commands for CHEESE."
    },
    {
      "name": "Chemical Space Visualisation (for on-prem users only)",
      "description": "Visualise CHEESE Embeddings. Coming Soon!",
      "externalDocs": {
        "description": "Items external docs",
        "url": "https://fastapi.tiangolo.com/"
      }
    }
  ],
  "servers": [
    {
      "url": "https://api.cheese-dev.deepmedchem.com",
      "description": "Development"
    },
    {
      "url": "https://api.cheese.deepmedchem.com",
      "description": "Production"
    }
  ]
}
