From 1ab45f1767d109de8967455ef864fcc202a52ac0 Mon Sep 17 00:00:00 2001 From: Kasper Dinkla Date: Wed, 29 Jan 2025 14:22:28 +0100 Subject: [PATCH] feat: Chemistry Queries for PatCID2 (#76) * Update patcid examples with new query methods. Signed-off-by: DKL * Fix chem notebook formatting. Signed-off-by: DKL * feat!: Update examples with new toolkit version (#77) * updated examples with new conversion changes in toolkit. Signed-off-by: Tiago Santana <54704492+SantanaTiago@users.noreply.github.com> * fix conversion settings example in upload_explore_donwlad_pdfs Signed-off-by: Tiago Santana <54704492+SantanaTiago@users.noreply.github.com> * Small fixes to upload_and_explore example Signed-off-by: Viktor Kuropiatnyk * fix download of kg and add validation of file exists. few typo fix Signed-off-by: Tiago Santana <54704492+SantanaTiago@users.noreply.github.com> * changed deepsearch-toolkit dep to version 2.0.0 Signed-off-by: Tiago Santana <54704492+SantanaTiago@users.noreply.github.com> --------- Signed-off-by: Tiago Santana <54704492+SantanaTiago@users.noreply.github.com> Signed-off-by: Viktor Kuropiatnyk Co-authored-by: Viktor Kuropiatnyk Signed-off-by: DKL * Update patcid examples with new query methods. Signed-off-by: DKL --------- Signed-off-by: DKL Signed-off-by: Tiago Santana <54704492+SantanaTiago@users.noreply.github.com> Signed-off-by: Viktor Kuropiatnyk Co-authored-by: Tiago Santana <54704492+SantanaTiago@users.noreply.github.com> Co-authored-by: Viktor Kuropiatnyk --- .../chemistry_patcid.ipynb | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) diff --git a/examples/data_query_chemistry_patcid/chemistry_patcid.ipynb b/examples/data_query_chemistry_patcid/chemistry_patcid.ipynb index ff6e2bb..1a6a8e9 100644 --- a/examples/data_query_chemistry_patcid/chemistry_patcid.ipynb +++ b/examples/data_query_chemistry_patcid/chemistry_patcid.ipynb @@ -37,7 +37,7 @@ }, { "cell_type": "code", - "execution_count": 6, + "execution_count": 17, "id": "4a9b4de7-bace-4c39-a4e7-b563292a2a30", "metadata": {}, "outputs": [], @@ -68,7 +68,7 @@ }, { "cell_type": "code", - "execution_count": null, + "execution_count": 18, "id": "1ea3cd26", "metadata": {}, "outputs": [], @@ -86,10 +86,14 @@ "import deepsearch as ds\n", "from deepsearch.cps.client.api import CpsApi\n", "from deepsearch.cps.client.components.elastic import ElasticDataCollectionSource\n", - "from deepsearch.chemistry.queries.molecules import (\n", - " MoleculeQuery,\n", - " MoleculesInPatentsQuery,\n", - " PatentsWithMoleculesQuery,\n", + "from deepsearch.chemistry.queries import (\n", + " query_chemistry,\n", + " CompoundsBySubstructure,\n", + " CompoundsBySimilarity,\n", + " CompoundsBySmarts,\n", + " CompoundsIn,\n", + " DocumentsByIds,\n", + " DocumentsHaving,\n", ")\n", "from deepsearch.chemistry.queries import (\n", " query_chemistry,\n", @@ -119,7 +123,7 @@ }, { "cell_type": "code", - "execution_count": 10, + "execution_count": 19, "id": "fae4dee3", "metadata": {}, "outputs": [