notebooks/agent_memory: default support assistant to OpenAI embeddings#216
Merged
Merged
Conversation
…tant example Make text-embedding-3-small (via LiteLLM) the default embedding route, since a hosted OpenAI embedding model is what most developers start with, and keep the in-database ONNX model as a first-class alternative selected with OAMP_EMBED_BACKEND. - Route toggle sets both the embedder and the search strategy: OpenAI -> vector search with an explicit vector_dim; in-database -> Oracle managed hybrid index. - Add markdown explaining when to prefer in-database embedding (fewer network hops, lower retrieval latency, data locality) plus a link and LOAD_ONNX_MODEL snippet for importing the model. - Install the [litellm] extra so the OpenAI route works out of the box. - Validated end-to-end against Oracle AI Database 26ai: 0 errors, all asserts pass.
WSPluta
approved these changes
Jul 7, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Follow-up to #215. Makes an OpenAI embedding model the default for the support assistant
notebook (what most developers start with), while keeping the in-database ONNX model as a
first-class alternative selected via
OAMP_EMBED_BACKEND.Changes
text-embedding-3-small(through LiteLLM). A singleOAMP_EMBED_BACKENDtoggle (openai|indb) sets both the embedder and the matching searchstrategy, because the runtime couples them:
openai→SearchStrategy.VECTORwith an explicitvector_dim(the model runs outside the DB).indb→OracleDBEmbedder+ Oracle's managedHYBRIDindex (HYBRIDrequires an in-DB embedder).latency, data locality/governance — plus a link and a
DBMS_VECTOR.LOAD_ONNX_MODELsnippet forimporting the model.
[litellm]extra so the OpenAI route works out of the box.embeddings (OpenAI by default or an in-database ONNX model)".
Validation
Ran end-to-end against Oracle AI Database 26ai with
text-embedding-3-small(1536-dim) andgpt-5.4:0 errors, probe
(2, 1536),RET-14Dretrieved by exact code and paraphrase, all asserts(corrected preference, cross-user isolation, chunk reconciliation) pass, and teardown leaves the store empty.