--- title: Get Smart Snippets for Sitecore content slug: lb3b0166 canonical_url: https://docs.coveo.com/en/lb3b0166/ collection: coveo-for-sitecore-v5 source_format: adoc --- # Get Smart Snippets for Sitecore content The [Coveo Machine Learning (Coveo ML)](https://docs.coveo.com/en/188/) [Smart Snippet](https://docs.coveo.com/en/laea5490/) feature targets [index](https://docs.coveo.com/en/204/) [items](https://docs.coveo.com/en/210/) whose `language` [field](https://docs.coveo.com/en/200/) value is `English`. By default, Sitecore English version items are indexed with `en` as the `language` field value. To be scanned as potential smart snippet answers to user queries, you must add an [indexing pipeline extension (IPE)](https://docs.coveo.com/en/206/) to your Sitecore source to replace `en` with `English` as the `language` field value on Sitecore items. This article provides instructions on how to do this. ## Create the extension . On the [**Extensions**](https://platform.cloud.coveo.com/admin/#/orgid/content/extensions/) ([platform-ca](https://platform-ca.cloud.coveo.com/admin/#/orgid/content/extensions/) | [platform-eu](https://platform-eu.cloud.coveo.com/admin/#/orgid/content/extensions/) | [platform-au](https://platform-au.cloud.coveo.com/admin/#/orgid/content/extensions/)) page of the [Coveo Administration Console](https://docs.coveo.com/en/183/), click **Add extension**. . In the **Add an Extension** panel, give your extension a name and a description. No need to select any additional item data options. ![Extension to set language field value to English | Coveo](https://docs.coveo.com/en/assets/images/c4sc-v5/ipe-to-set-language-to-english.png) . In the **Extension script** field, paste the following code: ```python language = document.get_meta_data_value('language') if language[0] == 'en': document.add_meta_data({'language': 'English'}) ``` . Click **Add extension**. ## Associate the extension to your source To link your extension to a source, you can proceed as follows: . On the [**Sources**](https://platform.cloud.coveo.com/admin/#/orgid/content/sources/) ([platform-ca](https://platform-ca.cloud.coveo.com/admin/#/orgid/content/sources/) | [platform-eu](https://platform-eu.cloud.coveo.com/admin/#/orgid/content/sources/) | [platform-au](https://platform-au.cloud.coveo.com/admin/#/orgid/content/sources/)) page of the Coveo Administration Console, click the Sitecore source you want to apply your extension to, and then click **More** > **Add extensions** in the Action bar. . In the **Add extensions** panel, on the **Common** tab, click **Add** > **Extension**. . In the **Apply an Extension on Source Items** panel, select your extension in the dropdown menu. . Under **Stage**, select **Post-Conversion**. . Under **Action on Error**, select **Skip Extension**. . In the **Conditions to apply** field, type `%[haslayout] == 1`. This condition ensures the extension is only applied to Sitecore HTML content items. ![Applying IPE to source items | Coveo](https://docs.coveo.com/en/assets/images/c4sc-v5/apply-set-language-to-english-ipe-to-source-items.png) . Click **Apply extension**. . Back in the **Add extensions** panel, click **Save**. . Rebuild that source from your Sitecore instance, so that the extension gets executed on your items. > **Note** > > For general guidance on adding indexing pipeline extensions, see [Manage indexing pipeline extensions](https://docs.coveo.com/en/1645/).