diff --git a/.github/workflows/test-langchain.yml b/.github/workflows/test-langchain.yml index 53a71a8b..f2500fc3 100644 --- a/.github/workflows/test-langchain.yml +++ b/.github/workflows/test-langchain.yml @@ -5,13 +5,13 @@ on: branches: ~ paths: - '.github/workflows/test-langchain.yml' - - 'framework/langchain/**' + - 'topic/machine-learning/llm-langchain/**' - 'requirements.txt' push: branches: [ main ] paths: - '.github/workflows/test-langchain.yml' - - 'framework/langchain/**' + - 'topic/machine-learning/llm-langchain/**' - 'requirements.txt' # Allow job to be triggered manually. @@ -63,13 +63,13 @@ jobs: cache: 'pip' cache-dependency-path: | requirements.txt - framework/langchain/requirements.txt - framework/langchain/requirements-dev.txt + topic/machine-learning/llm-langchain/requirements.txt + topic/machine-learning/llm-langchain/requirements-dev.txt - name: Install utilities run: | pip install -r requirements.txt - - name: Validate framework/langchain + - name: Validate topic/machine-learning/llm-langchain run: | - ngr test --accept-no-venv framework/langchain + ngr test --accept-no-venv topic/machine-learning/llm-langchain diff --git a/README.rst b/README.rst index efb3b024..f19472de 100644 --- a/README.rst +++ b/README.rst @@ -55,7 +55,7 @@ Examples:: More examples:: - ngr test framework/langchain + ngr test topic/machine-learning/llm-langchain ngr test testing/testcontainers/java It is recommended to invoke ``ngr`` from within a Python virtualenv. diff --git a/framework/langchain/.gitignore b/topic/machine-learning/llm-langchain/.gitignore similarity index 100% rename from framework/langchain/.gitignore rename to topic/machine-learning/llm-langchain/.gitignore diff --git a/framework/langchain/conftest.py b/topic/machine-learning/llm-langchain/conftest.py similarity index 100% rename from framework/langchain/conftest.py rename to topic/machine-learning/llm-langchain/conftest.py diff --git a/framework/langchain/conversational_memory.ipynb b/topic/machine-learning/llm-langchain/conversational_memory.ipynb similarity index 100% rename from framework/langchain/conversational_memory.ipynb rename to topic/machine-learning/llm-langchain/conversational_memory.ipynb diff --git a/framework/langchain/conversational_memory.py b/topic/machine-learning/llm-langchain/conversational_memory.py similarity index 100% rename from framework/langchain/conversational_memory.py rename to topic/machine-learning/llm-langchain/conversational_memory.py diff --git a/framework/langchain/document_loader.ipynb b/topic/machine-learning/llm-langchain/document_loader.ipynb similarity index 100% rename from framework/langchain/document_loader.ipynb rename to topic/machine-learning/llm-langchain/document_loader.ipynb diff --git a/framework/langchain/document_loader.py b/topic/machine-learning/llm-langchain/document_loader.py similarity index 100% rename from framework/langchain/document_loader.py rename to topic/machine-learning/llm-langchain/document_loader.py diff --git a/framework/langchain/pyproject.toml b/topic/machine-learning/llm-langchain/pyproject.toml similarity index 100% rename from framework/langchain/pyproject.toml rename to topic/machine-learning/llm-langchain/pyproject.toml diff --git a/framework/langchain/readme.md b/topic/machine-learning/llm-langchain/readme.md similarity index 90% rename from framework/langchain/readme.md rename to topic/machine-learning/llm-langchain/readme.md index f5ff852d..f30cf38c 100644 --- a/framework/langchain/readme.md +++ b/topic/machine-learning/llm-langchain/readme.md @@ -40,17 +40,17 @@ and [CrateDB]. - [requirements.txt](requirements.txt): Pulls in a patched version of LangChain, as well as the CrateDB client driver and the `crash` command-line interface. -- `vector_store.ipynb` [![Open on GitHub](https://img.shields.io/badge/Open%20on-GitHub-lightgray?logo=GitHub)](vector_search.ipynb) [![Launch Binder](https://mybinder.org/badge_logo.svg)](https://mybinder.org/v2/gh/crate/cratedb-examples/amo/framework-langchain?labpath=framework%2Flangchain%2Fvector_search.ipynb) [![Open in Collab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/crate/cratedb-examples/blob/amo%2Fframework-langchain/framework/langchain/vector_search.ipynb) +- `vector_store.ipynb` [![Open on GitHub](https://img.shields.io/badge/Open%20on-GitHub-lightgray?logo=GitHub)](vector_search.ipynb) [![Launch Binder](https://mybinder.org/badge_logo.svg)](https://mybinder.org/v2/gh/crate/cratedb-examples/main?labpath=topic%2Fmachine-learning%2Fllm-langchain%2Fvector_search.ipynb) [![Open in Collab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/crate/cratedb-examples/blob/main/topic/machine-learning/llm-langchain/vector_search.ipynb) This notebook explores CrateDB's [`FLOAT_VECTOR`] and [`KNN_MATCH`] functionalities for storing and retrieving embeddings, and for conducting similarity searches. -- `document_loader.ipynb` [![Open on GitHub](https://img.shields.io/badge/Open%20on-GitHub-lightgray?logo=GitHub)](document_loader.ipynb) [![Launch Binder](https://mybinder.org/badge_logo.svg)](https://mybinder.org/v2/gh/crate/cratedb-examples/amo/framework-langchain?labpath=framework%2Flangchain%2Fdocument_loader.ipynb) [![Open in Collab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/crate/cratedb-examples/blob/amo%2Fframework-langchain/framework/langchain/document_loader.ipynb) +- `document_loader.ipynb` [![Open on GitHub](https://img.shields.io/badge/Open%20on-GitHub-lightgray?logo=GitHub)](document_loader.ipynb) [![Launch Binder](https://mybinder.org/badge_logo.svg)](https://mybinder.org/v2/gh/crate/cratedb-examples/main?labpath=topic%2Fmachine-learning%2Fllm-langchain%2Fdocument_loader.ipynb) [![Open in Collab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/crate/cratedb-examples/blob/main/topic/machine-learning/llm-langchain/document_loader.ipynb) The notebook about the Document Loader demonstrates how to query a database table in CrateDB and use it as a source provider for LangChain documents. -- `conversational_memory.ipynb` [![Open on GitHub](https://img.shields.io/badge/Open%20on-GitHub-lightgray?logo=GitHub)](conversational_memory.ipynb) [![Launch Binder](https://mybinder.org/badge_logo.svg)](https://mybinder.org/v2/gh/crate/cratedb-examples/amo/framework-langchain?labpath=framework%2Flangchain%2Fconversational_memory.ipynb) [![Open in Collab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/crate/cratedb-examples/blob/amo%2Fframework-langchain/framework/langchain/conversational_memory.ipynb) +- `conversational_memory.ipynb` [![Open on GitHub](https://img.shields.io/badge/Open%20on-GitHub-lightgray?logo=GitHub)](conversational_memory.ipynb) [![Launch Binder](https://mybinder.org/badge_logo.svg)](https://mybinder.org/v2/gh/crate/cratedb-examples/main?labpath=topic%2Fmachine-learning%2Fllm-langchain%2Fconversational_memory.ipynb) [![Open in Collab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/crate/cratedb-examples/blob/main/topic/machine-learning/llm-langchain/conversational_memory.ipynb) LangChain also supports managing conversation history in SQL databases. This notebook exercises how that works with CrateDB. diff --git a/framework/langchain/requirements-dev.txt b/topic/machine-learning/llm-langchain/requirements-dev.txt similarity index 100% rename from framework/langchain/requirements-dev.txt rename to topic/machine-learning/llm-langchain/requirements-dev.txt diff --git a/framework/langchain/requirements.txt b/topic/machine-learning/llm-langchain/requirements.txt similarity index 100% rename from framework/langchain/requirements.txt rename to topic/machine-learning/llm-langchain/requirements.txt diff --git a/framework/langchain/test.py b/topic/machine-learning/llm-langchain/test.py similarity index 100% rename from framework/langchain/test.py rename to topic/machine-learning/llm-langchain/test.py diff --git a/framework/langchain/vector_search.ipynb b/topic/machine-learning/llm-langchain/vector_search.ipynb similarity index 100% rename from framework/langchain/vector_search.ipynb rename to topic/machine-learning/llm-langchain/vector_search.ipynb diff --git a/framework/langchain/vector_search.py b/topic/machine-learning/llm-langchain/vector_search.py similarity index 100% rename from framework/langchain/vector_search.py rename to topic/machine-learning/llm-langchain/vector_search.py diff --git a/topic/machine-learning/timeseries-basics/.gitignore b/topic/machine-learning/timeseries-basics/.gitignore new file mode 100644 index 00000000..e368aa27 --- /dev/null +++ b/topic/machine-learning/timeseries-basics/.gitignore @@ -0,0 +1,3 @@ +/mlartifacts +/mlruns +/model diff --git a/framework/mlflow-merlion/readme.md b/topic/machine-learning/timeseries-basics/readme.md similarity index 100% rename from framework/mlflow-merlion/readme.md rename to topic/machine-learning/timeseries-basics/readme.md diff --git a/framework/mlflow-merlion/requirements.txt b/topic/machine-learning/timeseries-basics/requirements.txt similarity index 100% rename from framework/mlflow-merlion/requirements.txt rename to topic/machine-learning/timeseries-basics/requirements.txt diff --git a/framework/mlflow-merlion/tracking_merlion.py b/topic/machine-learning/timeseries-basics/tracking_merlion.py similarity index 100% rename from framework/mlflow-merlion/tracking_merlion.py rename to topic/machine-learning/timeseries-basics/tracking_merlion.py