Skip Headers
Oracle® Application Server Personalization Administrator's Guide
10g Release 2 (10.1.2)
B14050-01
  Go To Documentation Library
Home
Go To Product List
Solution Area
Go To Table Of Contents
Contents
Go To Index
Index

Previous
Previous
Next
Next
 

4 OracleAS Personalization Schemas

Oracle Application Server Personalization (OracleAS Personalization) uses several database schemas, as follows:

All OracleAS Personalization schemas reside on the systems where Oracle databases are installed.

To see a small example of the MOR, MTR, and RE schemas that are correctly populated, install the REAPI Demo. (During installation, you are prompted with a question asking whether you want to install the demo data; if you answer yes, the demo data and the REAPI Demo are installed.) If you installed the REAPI Demo, you can examine the tables there. Alternatively, you can install an unpopulated MTR when you install OracleAS Personalization. You can examine the schema of the unpopulated MTR and populate it with your own data.

Note that OracleAS Personalization uses a fixed schema for the MTR. By "fixed," we mean that the MTR must be populated with tables matching OracleAS Personalization table and column names.

Before you can obtain recommendations or collect data, you must create and deploy a package. You cannot create a package until data exists in the MTR. There are three ways to initially populate an MTR:

4.1 Mining Table Repository

The OracleAS Personalization MTR consists of the tables and views listed in Table 4-1, below. Certain of these tables must be populated with data specific to your application in accordance with the MTR schema. Other tables, such as the tables associated with sessions and recommendations, are automatically populated by OracleAS Personalization. The third column indicates whether the table is to be populated by the user, by OracleAS Personalization, or by either.

Table 4-1 MTR Tables and Views

Table Name Table or View Populated by

MTR_ATTR_ID_BIN_BOUNDARY

VIEW

OPFoot 1 

MTR_ATTR_NAME_TO_ID_MAP

VIEW

OP

MTR_BIN_BOUNDARY

TABLE

User

MTR_CATEGORY (optional)

TABLE

User

MTR_CONFIGURATION

TABLE

Either

MTR_CUSTOMER

TABLE

Either

MTR_CUSTOMER_NAV_DETAIL

TABLE

Either

MTR_CUSTOMER_RATING_DETAIL

TABLE

Either

MTR_HOTPICK (optional)

TABLE

User

MTR_HOTPICK_GROUP (optional)

TABLE

User

MTR_INTERNAL_CONFIGURATION

TABLE

OP

MTR_ITEM

TABLE

User

MTR_NAVIGATION_DETAIL

VIEW

OP

MTR_PROFILE_DATA

VIEW

OP

MTR_PROXY

TABLE

User

MTR_PURCHASING_DETAIL

TABLE

User

MTR_RATING_DETAIL

VIEW

OP

MTR_RECOMMENDATION_DETAIL

TABLE

OP

MTR_SCHEMA_VERSION

VIEW

OP

MTR_SESSION

TABLE

OP

MTR_TAXONOMY (optional)

TABLE

User

MTR_TAXONOMY_CATEGORY (optional)

TABLE

User

MTR_TAXONOMY_CATEGORY_ITEM (optional)

TABLE

User

MTR_VISITOR_NAV_DETAIL

TABLE

Either

MTR_VISITOR_RATING_DETAIL

TABLE

Either


Footnote 1 OP - OracleAS Personalization

The rest of this section describes the schemas for the MTR tables. Tables that you must populate are described in detail.

4.1.1 Item Table

The item table (MTR_ITEM) contains a list of all the individual items that the application deals with. When OracleAS Personalization returns a recommendation, it returns an item's ID and ITEM_TYPE. The ID and ITEM_TYPE together uniquely identify an item. Different item types may use the same ID. The item table is usually mapped to the catalog tables in the application database. The schema for MTR_ITEM has four fields; they are listed in Table 4-2 with their data types. The LABEL column can be used for any locally-defined purpose; for example, it could contain a catalog identifier used in the local database.

Table 4-2 Item Table

Item Item Type

ID

NUMBER PK

ITEM_TYPE

VARCHAR2(30) PK

LABEL

VARCHAR2(150)

DESCRIPTION

VARCHAR2(4000)


4.1.2 Bin Boundaries

The model-building algorithms in OracleAS Personalization employ counting techniques to calculate probabilities. The data manipulated by the algorithms must be discrete, that is, not continuous. Hence, numeric data must be divided into bins to present discrete values to OracleAS Personalization. The process of dividing data into bins is called binning.

In OracleAS Personalization, binning is performed in a transformation step before model build. The value ranges for binning. The bin boundaries must be specified in the bin boundaries table for OracleAS Personalization to bin the values.

Categorical data should be mapped to numbers. This can be a one-to-one mapping if the cardinality should be preserved. In the case of high cardinality, a many-to-one mapping can be used to reduce the cardinality.

In summary, OracleAS Personalization requires all numerical data to be binned, and categorical data to be mapped.

When you create bins of numeric values, specify the bounds (upper and lower values) for each bin. When you create bins of categorical data, specify the items in each bin. To map several values to the same bin, use several records with the same bin numbering.


Note:

OracleAS Personalization requires ratings and demographic data to be binned. Purchasing and navigation data is not binned.

The table MTR_BIN_BOUNDARY has seven fields; they are listed in Table 4-3, in order, with their data types.

Table 4-3 Bin Boundary Fields

Field Data Type

DATA_SOURCE_TYPE

NUMBER(3)

ITEM_TYPE

VARCHAR2(30)

ATTRIBUTE_NAME

VARCHAR2(30)

LOWER_VALUE

NUMBER

UPPER_VALUE

NUMBER

STRING_VALUE

VARCHAR2(60)

BIN_NUMBER

NUMBER(15)



Note:

DATA_SOURCE_TYPE values are 1 for demographic data, 2 for purchasing data, 3 for ratings data, and 4 for navigational data.

Examples of Specifying Bin Boundaries

The following examples illustrate how to specify bin boundaries.

Consider movie rating data on a scale of 1 to 5. Suppose that you want to bin ratings as follows:

  • 1 and 2 are in bin number 1

  • 3 is in bin number 2

  • 4 and 5 are bin number 3

You should enter the following into the bin boundaries table:

(3, 'MOVIE', 'VALUE', 1, 2.1, NULL, 1),
(3, 'MOVIE', 'VALUE', 3, 3.1, NULL, 2),
(3, 'MOVIE', 'VALUE', 4, 5.1, NULL, 3)

The range of the bin includes all values that are greater than or equal to the lower value and strictly less than the upper value. The data source type for rating is 3 and string value is set to NULL for numeric data.

The following entries in a bin boundary table bin marital status, a categorical attribute:

(1, 'NONE', 'MARITAL_STATUS', NULL, NULL, 'Single', 1),
(1, 'NONE', 'MARITAL_STATUS', NULL, NULL, 'Divorced', 2),
(1, 'NONE', 'MARITAL_STATUS', NULL, NULL, 'Separated', 2),
(1, 'NONE', 'MARITAL_STATUS', NULL, NULL, 'Married', 3),
(1, 'NONE', 'MARITAL_STATUS', NULL, NULL, 'Widowed', 4)

The data source type is 1 and the item type is NONE for demographic data. Lower and upper values are NULL for categorical data.

4.1.3 Taxonomy


Note:

Refer to the Oracle Application Server Personalization User's Guide for an explanation of taxonomy in OracleAS Personalization.

Taxonomies are implemented by using a group of tables. Taxonomies are specified by the OracleAS Personalization user at MTR setup time. These tables are:

  • MTR_TAXONOMY: Lists the different taxonomies used by an application. Each taxonomy has a unique ID, name, and description. The schema for this table has three fields; they are listed in Table 4-4 with their data types:

Table 4-4 MTR_TAXONOMY Table Fields

Field Data Type

ID

NUMBER PK

NAME

VARCHAR2 (150)

DESCRIPTION

VARCHAR2 (4000)


  • MTR_CATEGORY: Specifies the different categories to be used in the taxonomy. The schema for this table has three fields: the unique identifier of the category, its name, and a description. They are listed in Table 4-5 with their data types:

Table 4-5 MTR_CATEGORY Table Fields

Field Data Type

ID

NUMBER PK

NAME

VARCHAR2 (150)

DESCRIPTION

VARCHAR2 (4000)


  • MTR_TAXONOMY_CATEGORY: Specifies which categories belong to the different taxonomies. (A category can belong to multiple taxonomies; however, for a given taxonomy, there can be only one instance of any category.) The schema for this table has four fields; they are listed in Table 4-6 with their data types. Each row in this table describes an "edge" of the taxonomy graph, that is, a line connecting two categories. The TAXONOMY_LEVEL is the level of the parent category. PARENT_ID and CHILD_ID are values from the MTR CATEGORY table.

Table 4-6 MTR_TAXONOMY_CATEGORY Table Fields

Field Data Type

TAXONOMY_LEVEL

NUMBER PK

TAXONOMY_ID

NUMBER PK

PARENT_ID

NUMBER PK

CHILD_ID

NUMBER PK


  • MTR_TAXONOMY_CATEGORY_ITEM: Specifies which items go with a given taxonomy-category pair. In other words, it lists each item as a member of a particular category in a particular taxonomy. If an item belongs to more than one category, the item is listed once for each category. The schema for this table has four fields; they are listed in Table 4-7 with their data types:

Table 4-7 MTR_TAXONOMY_CATEGORY_ITEM Table Fields

Field Data Type

CATEGORY_ID

NUMBER PK

TAXONOMY_ID

NUMBER PK

ITEM_ID

NUMBER PK

ITEM_TYPE

VARCHAR2 (30) PK


Samples of the MTR Taxonomy Tables

The REAPI Demo includes a taxonomy; you can examine the demo MTR to see examples of these tables.

4.1.4 Customer Table

The MTR_CUSTOMER table contains demographic information about an application's registered customers. Some customer attributes are common to all OracleAS Personalization applications and some can be tailored to your application. The common attributes are customer ID, name, creation date, gender, age, marital status, personal income, whether or not the customer is the head of household, household income, household size, and whether the customer rents or owns.

Fifty generic attributes are available in the table that can be defined specifically for your application. The first 25 of these attributes are of type VARCHAR2, and the second 25 are of type NUMBER.

All customer attributes are locally defined and are mapped from the application database or collected through application registration procedures.

The schema of the MTR_CUSTOMER table has the following fields. They are listed in Table 4-8 with their data types.

Table 4-8 MTR_CUSTOMER Table Fields and Data Types

Field Data Type

ID

VARCHAR2 (32)

NAME

VARCHAR2 (80)

CREATION_DATE

DATE

GENDER

VARCHAR2 (10)

AGE

NUMBER (3)

MARITAL_STATUS

VARCHAR2 (20)

PERSONAL_INCOME

NUMBER

IS_HEAD_OF_HOUSEHOLD

CHAR (1)

HOUSEHOLD_INCOME

NUMBER

HOUSEHOLD_SIZE

NUMBER (2)

RENT_OWN_INDICATOR

VARCHAR2 (30)

ATTRIBUTE1

VARCHAR2 (150)

ATTRIBUTE2

VARCHAR2 (150)

.  .  .  

.  .  .  

ATTRIBUTE25

VARCHAR2 (150)

ATTRIBUTE26

NUMBER

ATTRIBUTE27

NUMBER

.  .  .  

.  .  .  

ATTRIBUTE50

NUMBER


4.1.5 Hot Picks

Hot picks are used by some Web sites to force recommendations from a particular group of items. For example, items that are daily specials may be hot picks. Information about hot picks is stored in two MTR tables, as follows:

  • MTR_HOTPICK_GROUP lists the distinct hot pick groups used by the site. There is one record for each group. Each record contains a unique group ID, the group name (LABEL), and a brief description of the group. The schema for this table has three fields; they are listed in Table 4-9.

Table 4-9 MTR_HOTPICK_GROUP Fields

Field Data Type

ID

NUMBER PK

LABEL

VARCHAR2 (150)

DESCRIPTION

VARCHAR2 (400)


  • MTR_HOTPICK lists the items in each hot pick group, arranged according to group ID (corresponding to the ID field in MTR_HOTPICK_GROUP). Each record consists of a group ID, an item ID, and an item type. The schema for this table has three fields. They are listed in Table 4-10. A hot pick group can also contain categories. In this case, the ITEM_TYPE is set to CATEGORY and item ID is set to the appropriate ID value in the MTR_CATEGORY table.

Table 4-10 MTR_HOTPICK Fields

Field Data Type

ITEM_ID

NUMBER

ITEM_TYPE

VARCHAR2 (30)

GROUP_ID

NUMBER


4.1.6 MTR_PROXY

MTR_PROXY is used to set up proxies for new items. When a new item is introduced, there will likely not be any mention of this item in any customer profile. As such, the predictive models will not be able to identify any rules for it, and no recommendations can be made for that item. Hence, OracleAS Personalization uses data about a similar existing product, called a proxy. The fields in the MTR_PROXY table are listed in Table 4-11.

Table 4-11 MTR_PROXY Fields

Field Data Type

PROXY_ID

NUMBER

PROXY_TYPE

VARCHAR2 (30)

ITEM_ID

NUMBER PK

ITEM_TYPE

VARCHAR2 (30) PK


4.1.7 Detail Tables

Several tables in the MTR store the details of various activities.

  • MTR_CUSTOMER_NAV_DETAIL stores the navigation data corresponding to a customer session. This table stores the navigational data corresponding to a user session. Each record contains a SESSION_ID which is linked to the CUSTOMER_ID through the session table. In case there is no SESSION_ID collected, CUSTOMER_ID is used directly. One of the two must be not null. The ID and type of the item, and the time of the activity are also stored. The MTR_CUSTOMER_NAV_DETAIL table is populated with data collected in the RE using the data collection APIs. If the application is already collecting this data, the table could be a view defined on the application's tables. The fields of the table are listed in Table 4-12.

    Table 4-12 MTR_CUSTOMER_NAV_DETAIL Fields

    Field Data Type

    SESSION_ID

    NUMBER

    TIMESTAMP

    DATE

    NAVIGATIONAL_VALUE

    NUMBER

    ITEM_ID

    NUMBER

    ITEM_TYPE

    VARCHAR2 (30)

    CUSTOMER_ID

    VARCHAR2 (32)


  • MTR_CUSTOMER_RATING_DETAIL stores rating data for customers. The RATING_VALUE attribute stores the value of the rating. This table is populated using the data collected in the RE through the data collection APIs. In cases where the rating data is already collected by the application, this table could be a view defined on the application's tables. The fields in this table are listed in Table 4-13.

    Table 4-13 MTR_CUSTOMER_RATING_DETAIL Fields

    Field Data Type

    TIMESTAMP

    DATE

    RATING_VALUE

    NUMBER

    CUSTOMER_ID

    VARCHAR2 (32)

    ITEM_ID

    NUMBER

    ITEM_TYPE

    VARCHAR2(30)


  • MTR_PURCHASING_DETAIL stores purchasing data on a per-session basis. Typically this data is collected by the application. CUSTOMER_ID provides navigability when SESSION_ID is not collectible. The table fields are listed in Table 4-14.

    Table 4-14 MTR_PURCHASING_DETAIL Fields

    Field Data Type

    ORDER_ID

    NUMBER

    SESSION_ID

    NUMBER

    TIMESTAMP

    DATE

    PURCHASING_VALUE

    NUMBER

    ITEM_ID

    NUMBER

    ITEM_TYPE

    VARCHAR2 (30)

    CUSTOMER_ID

    VARCHAR2 (32)


  • MTR_RECOMMENDATION_DETAIL stores the results of recommendation requests. The data stored in this table is used to generate reports on the performance of OracleAS Personalization.

  • MTR_VISITOR_NAV_DETAIL stores the navigation data corresponding to a visitor session. Each record contains a SESSION_ID which is linked to the VISITOR_ID through the session table. In case there is no SESSION_ID collected, VISITOR_ID is used directly. One of the two must be not null. The ID and type of the item, and the time of the activity are also stored. This table is populated with data collected in the RE using the data collection APIs. If the application is already collecting this data, this table could be a view defined on the application's tables. The fields in the MTR_VISITOR_NAV_DETAIL table are listed in Table 4-15.

    Table 4-15 MTR_VISITOR_NAV_DETAIL Fields

    Field Data Type

    SESSION_ID

    NUMBER

    VISITOR_ID

    VARCHAR2 (32)

    NAVIGATIONAL_VALUE

    NUMBER

    TIMESTAMP

    DATE

    ITEM_ID

    NUMBER

    ITEM_TYPE

    VARCHAR2 (30)


  • MTR_VISITOR_RATING_DETAIL stores rating data for visitors. The RATING_VALUE attribute stores the value of the rating. This table is populated using the data collected in the RE using the data collection APIs. In cases where the rating data is already collected by the application, this table could be a view defined on those tables. The table's fields are listed in Table 4-16.

    Table 4-16 MTR_VISITOR_RATING_DETAIL Fields

    Field Data Type

    TIMESTAMP

    DATE

    RATING_VALUE

    NUMBER

    VISITOR_ID

    VARCHAR2 (32)

    ITEM_ID

    NUMBER

    ITEM_TYPE

    VARCHAR2 (30)


If the application is not collecting data through the RE, these tables can be mapped to other tables in the application schema where such information is maintained.

4.1.8 Miscellaneous MTR Tables

The following tables are used internally by OracleAS Personalization:

  • MTR_ATTR_NAME_TO_ID_MAP is used to speed up package building. It links an attribute name to an ID number.

  • MTR_CONFIGURATION and MTR_INTERNAL_CONFIGURATION stores configuration information.

    Table 4-17 MTR_CONFIGURATION Fields

    Field Data Type

    DATA_TYPE

    VARCHAR2 (32)

    NAME

    VARCHAR2 (128) PK

    VALUE

    VARCHAR2 (128)

    DESCRIPTION

    VARCHAR2 (100)


  • The MTR_SESSION table stores information about the session that OracleAS Personalization creates internally on behalf of the application.

  • MTR_ATTR_ID_BIN_BOUNDARY is a materialized view of the join of the MTR_BIN_BOUNDARY table and the MTR_ATTR_NAME_TO_ID_MAP table. It is used when transforming data during package builds.

4.2 Recommendation Engine

The RE schema stores current session data, package information, navigational information, as well as information about the taxonomy structure. RE data is synchronized back to the MTR automatically. The RE includes the following tables (partial list):

HOT_PICKGROUP and HOTPICK are copies of the corresponding tables in the MTR.

RE_CURRENT_SESSION_DATA holds all the data collected using the data collection methods. This data is written back to the MTR using data synchronization.

RE_PROFILE_DATA stores the historical profiles of active users. When a user is detected, the profile of that user is loaded from the MTR to this table.

RE_RECOMMENDATION_DETAIL is the source of data for the corresponding table in the MTR. The data is synchronized back to the MTR.

ATTR_ID_BIN_BOUNDARY is a copy of the corresponding table in the MTR.

RE_CONFIGURATION and RE_INTERNAL_CONFIGURATION store the configuration parameters for the RE.

RE_DEPLOYABLE_PACKAGE keeps track of the deployable package that is currently deployed in the RE.

RE_LOG records events occurring in the RE.

RE_ACTIVE_USER stores information about all users who are currently active in the system. Data from this table is used to populate the session table in the MTR.

All other tables are used internally by the RE.

4.3 Mining Object Repository

Much of the administrative work done by OracleAS Personalization uses MOR tables and views. The MOR includes the following tables (partial list). These tables cannot be configured or modified by the user.

MOR_CONFIGURATION (in Table 4-19)
MOR_VISITOR_TO_BROWSER_REPORT
MOR_CROSS_SOLD_ITEMS_REPORT
MOR_DEPLOYABLE_PACKAGE
MOR_EFFECTIVENESS_REPORT
MOR_EMAIL_ADDRESS
MOR_ERROR_TABLE
MOR_INTERNAL_CONFIGURATION
MOR_MESSAGE_LOG
MOR_MINING_MODEL
MOR_MINING_RESULT
MOR_MTR_CONNECTION
MOR_RECOMMENDATION_ENGINE
MOR_RECOMMENDATION_REPORT
MOR_RECOMMENDATION_STRATEGY
MOR_RE_FARM
MOR_SCHEDULE_EVENT
MOR_SCHEDULE_ITEM
MOR_SCHEMA_ACCESS
MOR_TAXONOMY_TRANS_CLOSURE
MOR_TRAN_SUPERVISED_RESULT

Table 4-19 MOR_CONFIGURATION Fields

Field Data Type Description

NLS_LANGUAGE

String

Specifies the language used for OP database messages.

NLS_TERRITORY

String

Specifies the territory used for OP database messages.

MOR_USERNAME

String

MOR user name.

MOR_PASSWORD

String

MOR schema password.

MOR_DBALIAS

String

MOR database alias name.

MOR_SCHEMA

String

MOR schema name.

MOR_HOST_URL

String

MOR host URL.

MOR_PORT

String

MOR port number.

MOR_SID

String

Oracle SID name of MOR schema.

MOR_VERSION

String

MOR version number.

MAIL_PREFERENCE

String

Indicates type of e-mail notifications sent: MAILTEXT or MAILHTML.

ADMIN_EMAIL_ADDRESS

String

Indicates the E-mail address of the Oracle Personalization administrator.

scheduleItemGracePeriod

INT

This value indicates the number of minutes past the next start time for overdue schedule items.

MAXNUMPURCHASINGSESS

INT

The maximum number of Purchasing Sessions reports to keep per recommendation engine farm.

MAXNUMRECEFFREP

INT

The maximum number of Recommendation Effectiveness reports to keep per recommendation engine farm.

MAXNUMITEMIZEDRECEFFREP

INT

The maximum number of Itemized Recommendation Effectiveness reports to keep per recommendation engine farm.

NUMOFITEMSINITEMIZEDRECEFFREPORT

INT

The number of top ranked items in Itemized Recommendation Effectiveness reports.

buildEvents

INT

The maximum number of Build events to keep in log.

deployEvents

INT

The maximum number of Deploy events to keep in log.

reportEvents

INT

The maximum number of Report events to keep in log.

IAS_HOSTNAME

String

Parameter used by report workflow to construct a URL for email notification.

IAS_SERVLET

String

Parameter used by report workflow to construct a URL for email notification.

IAS_SERVLET_ZONE

String

Parameter used by report workflow to construct a URL for email notification.

IAS_PORT

String

Parameter used by report workflow to construct a URL for email notification.

IAS_SERVLET_MOR_CONN

String

Parameter used by report workflow to construct a URL for email notification.

MAIL_SERVER_HOST

String

This value indicates the hostname of the SMTP mail server used by OP.

MAIL_SERVER_PORT

String

This value indicates the port of the SMTP mail server used by OP.

LOG_FILE

String

Log file name

LOG_LEVEL

INT

0 - OFF, 1 - Internal Error + Error + Warning, 2 - All types that are logged for log_level = 1 + Notification, 3 - All types that are logged for log_level = 2 + Trace

ALGS_TRACE

INT

0=OFF, 1=LOW, 2=MODERATE, 3=HIGH

DMAPI_TRACE

INT

0=OFF, 1=LOW, 2=MODERATE, 3=HIGH

PAR_TRACE

INT

0=OFF, 1=LOW, 2=MODERATE, 3=HIGH

TNB_TRACE

INT

0=OFF, 1=LOW, 2=MODERATE, 3=HIGH

UI_TRACE

INT

0=OFF, 1=LOW, 2=MODERATE, 3=HIGH

UTIL_TRACE

INT

0=OFF, 1=LOW, 2=MODERATE, 3=HIGH

WFJAVA_TRACE

INT

0=OFF, 1=LOW, 2=MODERATE, 3=HIGH