Skip to content

A tutorial demonstrating how to use the Open XML SDK with Azure Cognitive Services for Language to remove PII from a Word document.

Notifications You must be signed in to change notification settings

InteropEvents/DocumentAnalyzer

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

DevDays Asia 2022 - Use Azure Cognitive Service for Language with the OpenXML SDK

Contents

Use Azure Cognitive Service for Language with the OpenXML SDK

In this repo there is a sample console app that uses the OpenXML SDK and Azure Cognitive Service for Language with tutorial modules showing how to write the code to open a Word document, examine its contents for PII and save a copy with the PII redacted.

Prerequisites

Get started

  • Clone this repository to your local system.

    git clone https://github.com/InteropEvents/DocumentAnalyzer.git

    Pro tip: Clone the repo low in your folder hierarchy to avoid path length issues e.g. C:\myrepos

  • Create an Azure account and Language Services resource and copy the API key and endpoint by following the steps in the setup document.

    If you already have a API key and endpoint provided to you, skip this step.

Follow the tutorial

Now that you have cloned the repo and have your API key and endpoint, you're ready to create your application.

  1. First follow this document to create your console application with Visual Studio.

  2. Next install the the dependencies with this document.

  3. Then follow this document to write the application code.

Working sample

For a working example of this app:

  • Clone this repo

  • Open DocumentAnalyzer.csproj with Visual Studio

  • Replace the placeholders for the API key, endpoint, and file path in Program.cs

  • Press F5

Next steps

Learn more about the OpenXML SDK

Learn more about Azure Cognitive Services for Language

About

A tutorial demonstrating how to use the Open XML SDK with Azure Cognitive Services for Language to remove PII from a Word document.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages