apps: add supplychain-demand-planning-agent#144
Open
RichmondAlake wants to merge 1 commit into
Open
Conversation
A multi-agent demand-planning assistant on Oracle AI Database. A LangGraph supervisor decomposes planner requests and delegates to two specialists — demand_analyst (vector search over OracleVS) and policy_agent (planner preferences from AsyncOracleStore plus a standing buy-volume policy) — then synthesises a buy recommendation that honours both the policy and the active planner's saved preferences. Every layer lands in a single Oracle database: - OracleVS vector knowledge (demand reports + policy) - AsyncOracleStore long-term cross-thread memory (planner prefs) - AsyncOracleSaver per-thread agent checkpoints - OracleSemanticCache LLM-response cache - OracleChatMessageHistory chat-session transcripts Embeddings are produced in-database via an ONNX model (ALL_MINILM_L12_V2, 384 dims) loaded into Oracle with DBMS_VECTOR.LOAD_ONNX_MODEL — no external embedding API in the chain. Bundle includes the FastAPI/WebSocket backend, the React/Vite frontend (chat + per-agent context + data explorer + architecture explorer), the three setup scripts (bootstrap, ONNX, seed), per-part docs, and the student/complete workshop notebook pair.
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
Adds a new app entry — supplychain-demand-planning-agent — under
apps/.A multi-agent demand-planning assistant on Oracle AI Database. A LangGraph supervisor decomposes planner requests and delegates to two specialists (
demand_analystandpolicy_agent). Every memory layer, every retrieval primitive, and every LLM call lands in a single Oracle database:OracleVS— vector knowledge (12 demand reports + 1 buy-volume policy)AsyncOracleStore— long-term cross-thread memory (planner preferences)AsyncOracleSaver— per-thread agent checkpointsOracleSemanticCache— LLM-response cacheOracleChatMessageHistory— chat-session transcriptsEmbeddings are produced in-database via an ONNX model (
ALL_MINILM_L12_V2, 384 dims) loaded into Oracle withDBMS_VECTOR.LOAD_ONNX_MODEL— no external embedding API in the chain.Bundle includes:
supervisor.astream_events("v2")as typed UI eventsbootstrap.py,onnx_setup.py,seed_supplychain.py)workshop/docs/Also adds one row to the Apps table in the root
README.md.Test plan
docker compose up -d oracle-freebrings Oracle Free up healthypython app/scripts/bootstrap.pycreates theAGENTuser and the vector memory poolpython app/scripts/onnx_setup.pyloadsALL_MINILM_L12_V2into Oracle and a smoke-test query returns a 384-dim vectorpython app/scripts/seed_supplychain.pywrites 12 demand reports + 1 policy memo intoOracleVSand 2 user preferences intoAsyncOracleStorepython -m uvicorn app.backend.main:app --host 0.0.0.0 --port 8000boots;/api/healthreturns 200 with{"llm_provider": "oci", "llm_model": "xai.grok-4-1-fast-reasoning"}cd app/frontend && npm install && npm run dev -- --port 3000binds 3000; UI loads with the chat pane, data explorer (all 8 seeded tables visible), and architecture explorerworkshop/notebook_complete.ipynbexecutes end-to-end with 9/9 TODO checkpoints passing