Skip to content

Commit 98bb782

Browse files
WMS 11850: updated labs / concisness (#532)
* WMS ID 11172: new manifest for OCW AUH WMS ID 11172: new manifest for OCW AUH * WMS 11120: Updates to reflect ADB Serverless and ECPU WMS 11120: Updates to reflect ADB Serverless and ECPU * Patch PAR URLs developer repository Patch PAR URLs developer repository * Patch part 2 - developer Patch part 2 - developer * Patch 3 - developer Patch 3 - developer * Patch 4 - developer Patch 4 - developer * developer url fix developer url fix * init * Update manifest.json * Update introduction.md * updates * Update introduction.md * updates * Update build-a-test-env.md * update names * WMS ID: 11850 - Updates Added new Lab 2 Updated Lab 3 Updated manifest * WMS ID: 11850 - Updates WMS ID: 11850 - Updates fixed manifest * WMS ID: 11850 - Updates started lab 3 - coding basics * Update codingbasics.md * WMS ID: 11850 - Updates Updates: - fixed intro, lab 1, - removed labs 4-7 * WMS ID: 11850 - more Updates ready for review lab: 3 * WMS ID: 11850 - more Updates WMS ID: 11850 - more Updates * WMS ID: 11850 - more Updates architecture updates * WMS ID: 11850 - mini update name change * Update connect-to-env.md * WMS ID: 11850 - mini update WMS ID: 11850 - mini update fixing side bar ttitle * WMS 11850: Added microservices as new workshop WMS 11850: Added microservices as new workshop * WMS 11850: fixed manifest WMS 11850: fixed manifest * WMS 11850: fixed images WMS 11850: fixed images * WMS 11850: fixed indentation WMS 11850: fixed indentation * WMS 11850: fixed images WMS 11850: fixed images * WMS 11850: fixed path WMS 11850: fixed path * Update build.md * WMS 11900: Initial workshop - demo and coding experience WMS 11900: Initial workshop - demo and coding experience * WMS 11900: Initial workshop - finished all labs WMS 11900: Initial workshop - finished all labs * WMS 11900: fixed login process WMS 11900: fixed login process * WMS 11900: fixed typo WMS 11900: fixed typo * WMS 11850: Fixed typo WMS 11850: Fixed typo * WMS 11866: Added new MVP manifest WMS 11866: Added new MVP manifest * WMS 11866: Rollback of manifest.json changes for mvp WMS 11866: Rollback of manifest.json changes for mvp * WMS 11900 - fixed instructions WMS 11900 - fixed instructions * WMS 11866: update manifest title WMS 11866: update manifest title * WMS 11866: Redo intro and lab 1 WMS 11866: Redo intro and lab 1 * WMS 11866: redo of lab 2 WMS 11866: redo of lab 2 * WMS 11866: redo of lab 3 WMS 11866: redo of lab 3 * WMS 11866: redo of lab 4 and other fixes WMS 11866: redo of lab 4 and other fixes * WMS 11866: fixes reported for intro, lab 2, lab 3 WMS 11866: fixes reported for intro, lab 2, lab 3 * WMS 11866: additional changes WMS 11866: additional changes * WMS 11866: additional changes WMS 11866: additional changes * WMS 11866: added video to intro WMS 11866: added video to intro * WMS 11866: removed lab 5 from mvp candidate WMS 11866: removed lab 5 from mvp candidate * WMS 11866: removed appendix WMS 11866: removed appendix * WMS 11866: fixed images WMS 11866: fixed images * WMS 11866: updated manifest WMS 11866: updated manifest * WMS 11866: fixed filename WMS 11866: fixed filename * WMS 11866: added clarification WMS 11866: added clarification * Revert "WMS ID#11866 (#512)" This reverts commit f4ee5c3. * WMS 11866: updated duration WMS 11866: updated duration * WMS 11850: removing how-to run app temporarily WMS 11850: removing how-to run app temporarily * WMS 11850: Formatting fixes WMS 11850: Formatting fixes * WMS 11850: renamed folder due to PI WMS 11850: renamed folder due to PI * WMS 11850: updated labs / concisness WMS 11850: updated labs / concisness --------- Co-authored-by: Matt Kowalik <[email protected]>
1 parent 49e10a3 commit 98bb782

File tree

6 files changed

+188
-154
lines changed

6 files changed

+188
-154
lines changed

dev-guide-ai-finance/build/build.md

Lines changed: 33 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,13 @@
22

33
## Introduction
44

5-
In this lab, you will build a loan recommendation system powered by Oracle Database 23ai and OCI Generative AI. You will connect to a Oracle Database 23ai, explore customer data, extract relevant insights, and use a Large Language Model (LLM) to generate personalized loan suggestions. The system combines AI with OCI Generative AI to provide personalized loan recommendations. This system integrates AI capabilities with Oracle's robust database technology to deliver targeted financial recommendations.
5+
At SeerEquities, the data team is building a GenAI-powered loan assistant to support faster, more accurate loan approvals. The goal: reduce manual effort by using **retrieval-augmented generation (RAG)** and **LLMs** directly inside a governed Oracle Database 23ai environment.
66

7-
This lab uses some of the basic coding samples you created in lab 3, such as cursor.execute and more.
7+
In this lab, you'll build that assistant from the ground up.
8+
9+
You’ll connect to Oracle Database 23ai, explore customer data, use Oracle’s built-in embedding tools to vectorize content, and query it using AI Vector Search. Finally, you’ll feed results into a **Generative AI model from OCI** to generate contextual recommendations.
10+
11+
> 💡 Everything runs securely inside the database—no need to move data to external tools or vector stores. Only the enriched context is provided securely to OCI Generative AI services.
812
913
Estimated Time: 30 minutes
1014

@@ -15,33 +19,37 @@ To get things started we invite you to watch this video and see the lab in actio
1519

1620
### Objectives
1721

18-
* Build the complete loan approval application as seen in lab 1
19-
* Use OCI Generative AI to generate personalized loan recommendations
20-
* Use Python to connect to an Oracle Database 23ai instance and run queries
21-
* Explore customer data and extract relevant information
22+
- Build a complete RAG workflow using Python and Oracle Database 23ai
23+
- Connect to the database, prepare customer and loan data
24+
- Use `dbms_vector_chain` to create embeddings
25+
- Perform similarity search using `VECTOR_DISTANCE()`
26+
- Generate contextual loan recommendations using OCI Generative AI
2227

2328
### Prerequisites
2429

2530
This lab assumes you have:
2631

27-
* An Oracle Cloud account
28-
* Completed lab 1: Run the demo
29-
* Completed lab 2: Connect to the Development Environment
32+
- Oracle Cloud account
33+
- Completed:
34+
- Connect to the Development Environment: Environment Setup
35+
- Coding Basics on Oracle Database 23ai: Coding Basics
36+
3037

31-
## Task 1: Build the application in Jupyter Notebook
32-
>💡**Note**: Review Lab 2: Connect to the Development Environment for instructions on accessing JupyterLab.
38+
## Task 1: Launch a Jupyter Notebook
3339

34-
1. Click the blue "+". This will open the Launcher.
40+
>💡**Note**: Review **Connect to the Development Environment** for instructions on accessing JupyterLab.
41+
42+
1. Click the blue **+** to open the Launcher
3543

3644
![Open Launcher](./images/launcher.png " ")
3745

3846

39-
2. Open a new **Jupyter Notebook** by clicking on **Python(ipykernel)** notebook.
47+
2. Select **Python (ipykernel)** to open a new notebook
4048

4149
![Open Jupyter Notebook](./images/open-new-notebook.png " ")
4250

4351

44-
## Task 2: Connect to the database using oracledb Python driver
52+
## Task 2: Connect to Oracle Database 23ai
4553

4654
1. Copy the following code block into an empty cell in your notebook. This code block imports the `oracledb` Python driver and other libraries.
4755

@@ -78,21 +86,20 @@ This lab assumes you have:
7886
![Connect to Database](./images/connect-to-db.png " ")
7987

8088

81-
## Task 3: Create tables in the database
89+
## Task 3: Create database tables
8290

83-
1. Copy the following code block into the next empty cell in your notebook. This will create all tables in the database.
91+
1. Run the following cell to create your tables and populate them with sample data:
8492

8593
```python
8694
<copy>
8795
exec(open("db_setup.py").read())
8896
</copy>
8997
```
90-
2. Run the code block to create all tables in the database.
9198

9299
![Create Tables](./images/create-tables.png " ")
93100

94101

95-
## Task 4: Create a function to retrieve data from the database
102+
## Task 4: Fetch and display a customer profile
96103

97104
With the database ready, you will query customer data from the clients_dv JSON duality view. This view merges data from `CLIENTS`, `LOAN_APPLICATIONS`, and `CLIENT_DEBT` into a single JSON object, streamlining access to related records for AI-driven analysis.
98105

@@ -408,19 +415,20 @@ Now that the recommendations are vectorized, we can process a user’s question:
408415
409416
![rag](./images/rag.png " ")
410417
411-
## Summary
418+
## Conclusion
412419
413420
Congratulations! You implemented a RAG process in Oracle Database 23ai using Python.
414421
415422
To summarize:
416423

417-
* You created a function to connect to Oracle Database 23ai using the Oracle Python driver `oracledb`.
418-
* You created a function to retrieve customer data.
419-
* You created a function to connect to OCI Generative AI and create a first recommendation.
420-
* You created a function to create embeddings of the customer data using Oracle Database 23ai.
421-
* And finally, you implemented a RAG process in Oracle Database 23ai using Python.
424+
In this lab, you built the foundation of the SeerEquities GenAI Loan Assistant:
425+
426+
✅ Pulled customer data from JSON Duality Views
427+
✅ Used Oracle Database 23ai to create and search vector embeddings
428+
✅ Queried embedded chunks using AI Vector Search
429+
✅ Generated and refined answers using OCI Generative AI
422430

423-
Congratulations, you completed the lab!
431+
This RAG workflow now powers contextual conversations between loan officers and the system—with no external vector store or duplicated pipeline.
424432

425433
You may now proceed to the next lab.
426434

dev-guide-ai-finance/codingbasics/codingbasics.md

Lines changed: 29 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,20 @@
22

33
## Introduction
44

5-
In this hands-on lab, you will learn the basics of working with Oracle Database 23ai using Python. You will connect to the database with both `oracledb` and `pymongo`, create and query tables, and build JSON Duality Views. You will also explore Oracle’s Mongo API to query and update data using a familiar document model. For organizations already using MongoDB-like applications, the Oracle MongoDB API enables a smoother transition and integration with existing code, tools, or drivers—while consolidating everything in Oracle’s converged platform.
5+
6+
At SeerEquities, developers are building a next-generation loan approval system that needs to combine enterprise-grade data governance with modern AI capabilities. But before GenAI or vector search can be applied, one thing must be true:
7+
8+
👉 The data must be in the right shape — accessible, trustworthy, and programmable.
9+
10+
In this lab, you’ll act as a developer on the SeerEquities data team. Your job is to build the foundational logic that powers the application’s intelligence layer. That means:
11+
12+
- Creating and querying relational tables that represent real loan and customer data using Python
13+
- Converting that data into **JSON documents** using **JSON Duality Views**
14+
- Using **MongoDB-style syntax** via Oracle’s Mongo API to interact with the same data — without needing to duplicate or move it
15+
16+
These capabilities make Oracle Database 23ai a **developer-friendly**, **multi-model platform**. You’ll write less glue code, eliminate data movement, and stay focused on the real task: powering intelligent loan workflows.
17+
18+
> 💡 Everything you implement here becomes the data foundation for Retrieval-Augmented Generation (RAG) and AI Vector Search in upcoming labs.
619
720
Estimated Time: 30 minutes
821

@@ -12,33 +25,26 @@ To get things started we invite you to watch this video and see the lab in actio
1225

1326
### Objectives
1427

15-
* Learn basic Python coding concepts with Oracle Database 23ai
16-
* Connect to Oracle Database 23ai
17-
* Create tables
18-
* Insert & query data
19-
* Create a JSON Duality View using Python
20-
* Connect to database using `pymongo` and start using Oracle's Mongo API
21-
* Query data using Oracle's Mongo API
22-
* Update data using Oracle's Mongo API
28+
- Connect to Oracle Database 23ai using Python
29+
- Create and query relational data
30+
- Use JSON Duality Views to work with relational tables as JSON
31+
- Query and update the same data using MongoDB-style syntax
2332

2433
### Prerequisites
2534

2635
This lab assumes you have:
2736

28-
* An Oracle account to submit a LiveLabs Sandbox reservation.
29-
30-
* Completed Lab 2: Connect to the development environment
31-
32-
* Basic knowledge of Python.
33-
34-
* Basic knowledge of Oracle Database, i.e., how to run queries.
37+
- An Oracle account with LiveLabs access
38+
- Completion of **Lab 1: Connect to the Development Environment**
39+
- Basic familiarity with Python and SQL
3540

3641

3742
## Task 1: Create a new Jupyter Notebook
3843

3944
All of the coding examples will be executed in a new Jupyter Notebook.
4045

41-
1. Open a new **Jupyter Notebook** by clicking on **Python(ipykernel)** notebook.
46+
1. In **JupyterLab**, click the blue **+** to open the Launcher
47+
2. Start a new **Python (ipykernel)** notebook
4248

4349
![Open Jupyter Notebook](./images/open-new-notebook.png " ")
4450

@@ -69,14 +75,14 @@ In this first task, you will connect to an Oracle Database 23ai instance using O
6975
cursor = connection.cursor()
7076
</copy>
7177
```
78+
7279
2. Execute the cell by entering **shift + enter** or clicking on the play button.
7380

7481
3. You should see a message that says "Connection successful!" in your notebook. If you do not, check the credentials and try again.
7582

7683
![connect](./images/connect.png " ")
7784

78-
>**Note:** The last line, `cursor = connection.cursor()`, creates a cursor object from the established Oracle database connection. A cursor acts as a control structure that enables the execution of SQL queries and retrieval of results from the database. It is essential for sending SQL commands, fetching data, and iterating through query results. We will be using the cursor object in later steps of this lab. The object persists in the notebook session, so you can use it in subsequent cells without re-establishing the connection.
79-
85+
>**Note:** The last line, `cursor = connection.cursor()`, creates a cursor object from the established Oracle database connection. A cursor acts as a control structure that enables the execution of SQL queries and retrieval of results from the database. It is essential for sending SQL commands, fetching data, and iterating through query results. We will be using the cursor object in later steps of this lab. The object persists in the notebook session, so you can use it in subsequent cells without re-establishing the connection.
8086

8187
## Task 3: Create tables and insert data
8288

@@ -478,13 +484,13 @@ The final step in our basic coding tour with Python and the Oracle Database 23ai
478484

479485
🔴 **`df.head()`** - This is a method that returns that returns the result of the query including the column names.
480486

481-
## Summary
487+
## Conclusion
482488

483-
In this lab, we learned how to use Python and Oracle's Python driver `oracledb` to interact with Oracle Database 23ai's new features. You learned how to user the `cursor` object to execute SQL queries. Using the `cursor` object, you created a **JSON Duality View** and you even used some JSON functions to query documents using SQL syntax. Then, you also learned how to connect to the database using `pymongo` and retrieve data from a table in the database using **MongoDB syntax**. You created functions to update the **JSON Duality View** and you learned how these updates are also reflected in the underlying relational database tables.
489+
As a developer at SeerEquities, you've just built the foundation for a GenAI-powered loan approval system. We learned how to use Python and Oracle's Python driver `oracledb` to interact with Oracle Database 23ai's new features. You learned how to user the `cursor` object to execute SQL queries. Using the `cursor` object, you created a **JSON Duality View** and you even used some JSON functions to query documents using SQL syntax. Then, you also learned how to connect to the database using `pymongo` and retrieve data from a table in the database using **MongoDB syntax**. You created functions to update the **JSON Duality View** and you learned how these updates are also reflected in the underlying relational database tables.
484490

485-
In the next labs, you will see several of the coding principles learned and even more.
491+
This architecture eliminates the need for duplicating data across platforms and simplifies how developers build AI-ready applications. Whether you're calling SQL, working with JSON, or speaking Mongo, you're always working with a single source of truth inside the Oracle Database.
486492

487-
You are now ready to implement you a RAG process using Oracle Database 23ai's new features!
493+
In the next lab, you'll build on this foundation to implement Retrieval-Augmented Generation (RAG), create vector embeddings, and generate personalized loan recommendations with Oracle 23ai and OCI Generative AI.
488494

489495
## Acknowledgements
490496
* **Authors** - Linda Foinding, Kevin Lazarz

dev-guide-ai-finance/connect-to-env/connect-to-env.md

Lines changed: 41 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,12 @@
22

33
## Introduction
44

5-
In this lab, we will show you how to connect to the development environment. We are using JupyterLab as our development environment, which is a web-based application that allows you to write and run code on your browser. You can use this environment to create notebooks, edit files, and run Python scripts.
5+
In this short lab, you’ll launch the JupyterLab-based development environment used throughout the workshop. JupyterLab runs entirely in your browser and allows you to write and test Python code that interacts directly with Oracle Database 23ai.
6+
7+
This is the same environment used by the SeerEquities data team to build the AI loan assistant.
8+
9+
> 💡 You only need to complete this once. In the next labs, you'll jump straight into hands-on coding. Remember to come back to this lab in case you need you closed the browser window and need to access JupyterLab again.
10+
611

712
Estimated Time: 5 minutes
813

@@ -12,43 +17,62 @@ To get things started we invite you to watch this video and see the lab in actio
1217

1318
### Objective
1419

15-
* Login to JupyterLab
20+
- Access the JupyterLab environment
21+
- Log in using provided credentials
22+
- Get familiar with basic Jupyter features
1623

1724
## Task 1: Login to JupyterLab
1825

19-
1. To navigate to the development environment, click **View Login Info**. Copy the Development IDE Login Password. Click the Start Development IDE link.
20-
26+
1. In the top left of your lab page, click **View Login Info**.
27+
2. Copy the **Development IDE Login Password**.
28+
3. Click the **Start Development IDE** link.
29+
2130
![Open Development Environment](./images/dev-env.png =50%x*)
2231

23-
2. Paste in the Development IDE Login Password that you copied in the previous step. Click **Login**.
32+
4. Paste in the password and click **Login**.
2433

2534
![Login](./images/jupyter-login.png " ")
2635

27-
## Task 2: Get familiar with the development environment
36+
You’re now in the development environment.
37+
38+
## Task 2: Explore JupyterLab
39+
40+
JupyterLab is where you’ll write, run, and test Python code that connects to Oracle Database 23ai. Here are the key parts:
41+
42+
**File browser (1):** Use this panel to open notebooks, scripts, and other files. Right-click for actions like rename or delete.
43+
2844

29-
1. Review the different elements in JupyterLab:
45+
**Launcher:** From here, you can start:
46+
- **Python notebooks (2)** for running code
47+
- **Terminals (3)** ** for command-line tasks
3048

31-
**File browser:** The file browser organizes and manages files within the JupyterLab workspace. It supports drag-and-drop file uploads, file creation, renaming, and deletion. Users can open notebooks, terminals, and text editors directly from the browser. Navigation is fast and intuitive, with breadcrumbs and context menus that surface relevant actions. Users can right-click files to access options like duplicate, shutdown kernel, or open with a specific editor.
49+
![JupyterLab Launcher](./images/jupyter.png " ")
3250

33-
**Launcher:** The launcher offers a streamlined entry point for starting new activities. Users can create Jupyter Notebooks for interactive coding with live code execution, visualizations, and rich markdown. The terminal provides direct shell access, enabling command-line operations within the JupyterLab environment. These two tools form the core of most workflows, supporting both interactive analysis and system-level tasks from a single interface.
51+
## Task 3: Working with Jupyter Notebooks
3452

35-
![JupyterLab Launcher](./images/jupyter.png " ")
53+
You’ll use notebooks for every lab in this workshop. Each notebook is made up of **cells**:
3654

37-
## Task 3: Get familiar with Jupyter Notebooks
55+
- **Markdown cells** hold instructions and explanations
56+
- **Code cells** contain executable Python
3857

39-
You will use a Jupyter Notebook in JupyterLab to build and test the loan recommendation system. If you are new to notebooks, the following tips will help you get started and work smoothly.
58+
To run a code cell:
59+
- Press **Shift + Enter**
60+
- Or click the **Run** button in the toolbar
4061

41-
1. **Executing Code Blocks**: You can run code in two simple ways: press **Shift+Enter** to execute and move to the next cell, or click the **Play/Execute** button in the menu bar at the top of this tab. Both methods work interchangeably.
62+
While a cell is running, you’ll see `[*]`. When it finishes, it changes to a number like `[3]`.
4263

43-
2. **Block Types**: Instructions and code are separated into **their own blocks**. Instructions are in markdown (like this cell), while code is in executable Python blocks. If you accidentally run an instruction block, it’ll just skip to the next cell—no harm done!
64+
![JupyterLab blocks](./images/block.png " ")
4465

45-
3. **Running Indicators**: When you run a code block, its label changes from `[ ]` (empty) or `[1]` (a number) to `[*]`. The asterisk (`*`) means it’s processing. Wait until it switches back to a number (e.g., `[2]`) before moving on, ensuring the operation is complete.
66+
> 🛠 If a cell throws an error, double-check the code or rerun the previous steps.
4667
47-
4. **Output & Warnings**: Below each code cell, output appears after execution. This can include results, visualizations, or messages. Warnings may show up—these are usually informational, such as notices about deprecated features. Unless an error halts execution, users can continue without making changes. If you see a error, review the code for any issues and make changes accordingly and try executing the cell again.
4868

49-
![JupyterLab blocks](./images/block.png " ")
69+
## Conclusion
5070

71+
You’ve now logged into the cloud-based development environment where all coding will take place.
5172

73+
✅ You can access JupyterLab in your browser
74+
✅ You understand how to open and run notebooks
75+
✅ You’re ready to start interacting with Oracle Database 23ai
5276

5377
## Acknowledgements
5478
* **Author** - Kamryn Vinson

0 commit comments

Comments
 (0)