Skip to content

Conversation

hackerdave
Copy link

@hackerdave hackerdave commented Aug 8, 2025

Description

This PR integrates Oracle Document Loader and Oracle Vector Search with LangChain.js. The integration enables the use of Oracle's advanced vector search capabilities within the LangChain.js framework.

Key Features

  • Adds support for Oracle Document Loader in LangChain.js.
    • loading documents either from the file system or a table
    • generating embeddings either via an ONNX model loaded into the database or a third-party REST call
    • summarizing documents either via Oracle Text or a third-party REST call
  • Adds support for Oracle Vector Search in LangChain.js.
    • includes filter support
  • Source is under libs/langchain-oracle
  • Includes doc with example usage and tests for the integration.

Example usage

Text Splitter

import {OracleTextSplitter} from "@langchain/oracle";

const splitter = new OracleTextSplitter(conn, splitter_params);
let chunks = await splitter.splitText(doc.pageContent);

Embeddings

import {OracleEmbeddings} from "@langchain/oracle";

const embedder = new OracleEmbeddings(conn, embedder_params, proxy);
const embed = await embedder.embedQuery(chunk);

Testing

  • Verified integration with unit tests.
  • Added relevant test cases to ensure proper functionality.

Copy link

vercel bot commented Aug 8, 2025

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Preview Comments Updated (UTC)
langchainjs-docs Error Error Aug 21, 2025 7:22pm
1 Skipped Deployment
Project Deployment Preview Comments Updated (UTC)
langchainjs-api-refs Ignored Ignored Aug 21, 2025 7:22pm

@hackerdave hackerdave closed this Aug 21, 2025
@hackerdave hackerdave reopened this Aug 21, 2025
@hackerdave hackerdave marked this pull request as ready for review August 21, 2025 22:20
@hackerdave hackerdave changed the title feat(oracle): Add Oracle Document Loader and Oracle Vector Search with LangChain.js feat(langchain-oracle): Add Oracle Document Loader and Oracle Vector Search to LangChain.js Aug 21, 2025
@hackerdave hackerdave changed the title feat(langchain-oracle): Add Oracle Document Loader and Oracle Vector Search to LangChain.js feat(langchain-oracle): Add Oracle Document Loader and Oracle Vector Search Aug 27, 2025
@christian-bromann
Copy link
Member

@hackerdave thanks for the contribution 🙏 our team has been working on the upcoming v1 release of LangChain and unfortunately didn't had the resources yet to look at this PR. We will provide an update soon.

@hntrl hntrl self-assigned this Sep 9, 2025

## Connecting to Oracle Database

Below is an example of how to connect to an Oracle Database using both a direct connection and a connection pool:
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Split this into two examples. Make the second have a method e.g dbPoolConnection() to get a connection from the pool.

Consider adding links to the node-oracledb connection & pool creation doc sections:

Examples later in the doc need connecting handling to be consistent. E.g. the "Testing the Integration" example calls both dbPool() and dbConnect(). The latter call should be changed to invoke the new dbPoolConnection() method.

@hntrl
Copy link
Contributor

hntrl commented Sep 11, 2025

@hackerdave @cjbj what's your thoughts on splitting this into its own repo similar to how the python integration is? We're trying to scope down on the amount of maintenance footprint this repo has.

@cjbj
Copy link

cjbj commented Sep 12, 2025

@hntrl I'll defer to @hackerdave on this.

@hackerdave
Copy link
Author

Yes we are looking into splitting the repo like the python integration so langchain-oracle would be in the oracle repo. It will take a month to get approvals. Should the documentation (i.e., cookbook and docs) remain in the langchain-ai repo?

@hntrl
Copy link
Contributor

hntrl commented Sep 16, 2025

@hackerdave Going forward, it's probably best to add docs to the docs repo

@hntrl hntrl closed this Sep 16, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants