OracleEmbeddings.
Why generate embeddings in (or via) Oracle? You can keep data governance and operational guarantees (security, transactions, availability) close to your AI workflow—while choosing the embedding provider model that fits your environment.
Overview
Integration details
Setup
To use OracleEmbeddings, install the@oracle/langchain-oracledb helpers (plus @langchain/core) and make sure the Oracle Database driver prerequisites are met for your system.
Credentials
Export credentials (or load them from your secrets manager) for the Oracle user that owns your vector tables and ONNX models.Installation
Instantiate embeddings
proxy string. Use it when outbound requests must travel through an HTTP proxy (for example, when calling Hugging Face from within a private network).
Run ONNX models inside Oracle Database
Oracle Database accommodates a variety of embedding providers, enabling users to choose between proprietary database solutions and third-party services such as OCIGENAI and HuggingFace. This selection dictates the methodology for generating and managing embeddings. Important : Should users opt for the database option, they must upload an ONNX model into the Oracle Database. Conversely, if a third-party provider is selected for embedding generation, uploading an ONNX model to Oracle Database is not required. A significant advantage of utilizing an ONNX model directly within Oracle is the enhanced security and performance it offers by eliminating the need to transmit data to external parties. Additionally, this method avoids the latency typically associated with network or REST API calls. Below is the example code to upload an ONNX model into Oracle Database:Call managed embedding providers
Switchprovider to route embedding requests through OCI Generative AI or Hugging Face. Provide the credential name you created with Oracle’s DBMS_VECTOR_CHAIN helpers and, if required, a proxy.
Embed documents for retrieval
Use the same embedding instances to prepare content for vector stores or hybrid retrieval in Oracle Database.Next steps
- Store embeddings with
OracleVSfor hybrid search - Summarize documents using
OracleSummary
API reference
For detailed documentation of allOracleEmbeddings options head to the Oracle LangChain Oracle DB repository.
Connect these docs to Claude, VSCode, and more via MCP for real-time answers.

