You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: agent-framework/user-guide/model-context-protocol/index.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -29,7 +29,7 @@ The MCP tool allows you to pass custom headers, such as authentication keys or s
29
29
30
30
You can integrate multiple remote MCP servers by adding them as tools to your agent. Agent Framework makes it easy to convert an MCP tool to an AI tool that can be called by your agent.
31
31
32
-
The MCP tool supports custom headers, so you can connect to MCP servers by using the authentication schemas that they require or by passing other headers that the MCP servers require. **TODO You can specify headers only by including them in tool_resources at each run. In this way, you can put API keys, OAuth access tokens, or other credentials directly in your request. TODO**
32
+
The MCP tool supports custom headers, so you can connect to MCP servers by using the authentication schemas that they require or by passing other headers that the MCP servers require. **You can specify headers only by including them in tool_resources at each run. In this way, you can put API keys, OAuth access tokens, or other credentials directly in your request.**
33
33
34
34
The most commonly used header is the authorization header. Headers that you pass in are available only for the current run and aren't persisted.
@@ -186,7 +204,44 @@ var collection = new OracleCollection<string, Hotel>("<connection string>", "skh
186
204
187
205
## Getting started
188
206
189
-
More information coming soon.
207
+
Install the Oracle Database Vector Store connector:
208
+
209
+
```cli
210
+
pip install semantic-kernel[oracledb]
211
+
```
212
+
213
+
Import the OracleSettings, OracleStore, and OracleCollection classes.
214
+
215
+
```python
216
+
from semantic_kernel.connectors.oracle import OracleSettings, OracleStore, OracleCollection
217
+
```
218
+
219
+
The OracleSettings class holds the configuration required to create an asynchronous connection to Oracle Database. The OracleStore class is used to store and retrieve data, while the OracleCollection class manages and searches records within a collection. Use these classes to set up the Oracle Vector Store.
220
+
221
+
```python
222
+
# Read the environment settings
223
+
oracle_settings = OracleSettings()
224
+
225
+
# Create a connection pool
226
+
pool =await oracle_settings.create_connection_pool(
227
+
wallet_location=<wallet_location>,
228
+
wallet_password=<wallet_password>)
229
+
230
+
# Create an Oracle Vector Store
231
+
store = OracleStore(
232
+
connection_pool=pool,
233
+
)
234
+
235
+
# Get a collection
236
+
collection =await store.get_collection(
237
+
record_type=HotelSample,
238
+
collection_name=Hotel,
239
+
embedding_generator=text_embedding)
240
+
241
+
# Create a collection if it does not exist
242
+
await collection.ensure_collection_exists()
243
+
```
244
+
190
245
::: zone-end
191
246
::: zone pivot="programming-language-java"
192
247
@@ -314,18 +369,18 @@ Here is a data model with `StorageName` set code sample and how that will be rep
Refer to the following Oracle Database Vector Store connector resources to learn more:
347
402
348
-
-[Introducing the Oracle Database Vector Store Connector for Semantic Kernel](https://medium.com/oracledevs/announcing-the-oracle-database-vector-store-connector-for-semantic-kernel-adb83e806d4e)
403
+
-[Introducing the Oracle Database Vector Store Connector for Semantic Kernel](https://medium.com/oracledevs/announcing-the-oracle-database-vector-store-connector-for-semantic-kernel-adb83e806d4e)
349
404
Describes key connector features, classes, and guides the reader through a sample AI vector search application using the connector.
350
-
-[Documentation: Oracle Database Vector Store Connector Classes for Semantic Kernel (.NET) APIs](https://docs.oracle.com/en/database/oracle/oracle-database/23/odpnt/VSConnector4SKClasses.html)
351
-
Contains information on Oracle Database Vector Store connector classes for adding data, retrieving data, and performing vector search in the Oracle vector database.
352
-
-[Documentation: Oracle Data Provider for .NET](https://docs.oracle.com/en/database/oracle/oracle-database/23/odpnt/intro.html)
405
+
-[Documentation: Oracle Database Vector Store Connector Classes for Semantic Kernel (.NET) APIs](https://docs.oracle.com/en/database/oracle/oracle-database/23/odpnt/VSConnector4SKClasses.html)
406
+
Contains information on Oracle Database Vector Store connector classes for adding data, retrieving data, and performing vector search in the Oracle vector database.
407
+
-[Documentation: Oracle Data Provider for .NET](https://docs.oracle.com/en/database/oracle/oracle-database/23/odpnt/intro.html)
353
408
Contains information on Oracle Data Provider for .NET (ODP.NET), the ADO.NET data provider for Oracle Database Vector Store connector.
354
409
410
+
::: zone-end
411
+
::: zone pivot="programming-language-python"
412
+
413
+
## Data Mapping
414
+
415
+
The Oracle Database Vector Store connector provides a default mapper when mapping from the data model to storage. This mapper does a direct conversion of the list of properties on the data model to the Oracle Database columns to convert to the storage schema.
416
+
417
+
The Oracle Database Vector Store connector supports data model annotations and record definitions. Using annotations, the information can be provided to the data model for creating indexes and database column mapping. Using [record definitions](../schema-with-record-definition.md), the information can be defined and supplied separately from the data model.
418
+
419
+
The following table shows the default primary key data type mapping between Oracle Database and Python:
420
+
421
+
| Python Type | Oracle SQL Type |
422
+
|---------------------------|-----------------|
423
+
| str | VARCHAR(n), Using str(n) in the type option sets the Oracle VARCHAR length to n. If n is not specified, the default length is 4000. |
424
+
| int | NUMBER(10) |
425
+
| byte | NUMBER(3) |
426
+
| long | NUMBER(19) |
427
+
| decimal | NUMBER |
428
+
| float | BINARY_FLOAT |
429
+
| double | BINARY_DOUBLE |
430
+
| bool | BOOLEAN |
431
+
| UUID | RAW(16) |
432
+
| date | DATE |
433
+
| datetime.datetime | TIMESTAMP |
434
+
| datetime.timedelta | INTERVAL DAY TO SECOND |
435
+
| clob | CLOB, can be specified explicitly, not a native Python type |
436
+
| blob | BLOB, can be specified explicitly, not a native Python type |
437
+
| list[str], dict[str, Any]| JSON |
438
+
| list[dict[str, Any]]| JSON |
439
+
| bytes | RAW(2000) |
440
+
441
+
Starting with Oracle Database 23ai, database vectors can be mapped to Python data types. Multiple vector columns are supported. The following table shows the default vector property type mapping:
0 commit comments