创建零售架构和数据集
本教程向您提供所有其他教程所需的先决条件和资源 Adobe Experience Platform Data Science Workspace 教程。 完成后,零售架构和数据集将可供您和贵组织的成员在 Experience Platform.
快速入门
在开始本教程之前,您必须满足以下先决条件:
-
访问 Adobe Experience Platform. 如果您无权访问中的组织 Experience Platform,请在继续之前与系统管理员联系。
-
进行授权 Experience Platform API调用。 完成 身份验证和访问Adobe Experience Platform API 教程以获取以下值以成功完成本教程:
- Authorization:
{ACCESS_TOKEN}
- x-api-key:
{API_KEY}
- x-gw-ims-org-id:
{ORG_ID}
- 客户端密码:
{CLIENT_SECRET}
- 客户端证书:
{PRIVATE_KEY}
- Authorization:
-
示例数据和源文件 零售指导方针. 下载此项和其他项所需的资产 Data Science Workspace 教程 Adobe公共Git存储库.
-
Python >= 2.7 以及以下各项 Python 包:
-
对于本教程中使用的以下概念的实际了解:
创建零售架构和数据集
使用提供的引导脚本自动创建零售架构和数据集。 请按顺序执行以下步骤:
配置文件
-
内部 Experience Platform 教程资源包,导航到目录
bootstrap
,并打开config.yaml
使用适当的文本编辑器。 -
在
Enterprise
部分,输入以下值:code language-yaml Enterprise: api_key: {API_KEY} org_id: {ORG_ID} tech_acct: {technical_account_id} client_secret: {CLIENT_SECRET} priv_key_filename: {PRIVATE_KEY}
-
编辑下找到的值
Platform
部分,示例如下所示:code language-yaml Platform: platform_gateway: https://platform.adobe.io ims_token: {ACCESS_TOKEN} ingest_data: "True" build_recipe_artifacts: "False" kernel_type: Python
platform_gateway
:API调用的基本路径。 请勿修改此值。ims_token
:您的{ACCESS_TOKEN}
此处显示。ingest_data
:在本教程中,请将此值设置为"True"
以便创建零售架构和数据集。 值"False"
将仅创建架构。build_recipe_artifacts
:在本教程中,请将此值设置为"False"
以防止脚本生成方法构件。kernel_type
:方法工件的执行类型。 将此值保留为Python
如果build_recipe_artifacts
设置为"False"
,否则请指定正确的执行类型。
-
在
Titles
部分,为零售样本数据适当提供以下信息,进行编辑后保存并关闭文件。 示例如下所示:code language-yaml Titles: input_class_title: retail_sales_input_class input_mixin_title: retail_sales_input_mixin input_mixin_definition_title: retail_sales_input_mixin_definition input_schema_title: retail_sales_input_schema input_dataset_title: retail_sales_input_dataset file_replace_tenant_id: DSWRetailSalesForXDM0.9.9.9.json file_with_tenant_id: DSWRetailSales_with_tenant_id.json is_output_schema_different: "True" output_mixin_title: retail_sales_output_mixin output_mixin_definition_title: retail_sales_output_mixin_definition output_schema_title: retail_sales_output_title output_dataset_title: retail_sales_output_dataset
运行引导脚本
-
打开您的终端应用程序并导航到 Experience Platform 教程资源目录。
-
设置
bootstrap
目录作为当前工作路径,并运行bootstrap.py
Python 通过输入以下命令编写脚本:code language-bash python bootstrap.py
note note NOTE 脚本可能需要几分钟才能完成。
后续步骤
成功完成bootstrap脚本后,可以在以下位置查看零售业的输入和输出架构和数据集: Experience Platform. 请参阅 预览架构数据教程
了解更多信息。
您还已成功将零售业样本数据摄取到 Experience Platform 使用提供的引导脚本。
要继续使用摄取的数据,请执行以下操作:
- 使用Jupyter Notebooks分析数据
- 使用数据科学工作区中的Jupyter Notebooks访问、浏览、可视化并了解您的数据。
- 将源文件打包到方法中
- 按照本教程中的说明进行操作,了解如何将您自己的模型导入 Data Science Workspace 将源文件打包到可导入的配方文件中。