Back

BLOG • DIGITAL INSIGHTS

Getting the Most of Generative AI and Sitefinity – Part 1

How Eveliko tweaked the Sitefinity 15 Generative AI feature to produce well-formatted HTML output rather than plain text - saving content editors significant post-production time with a simple prompt configuration change.

Sitefinity CMS

TL;DR

See how we tweaked the new Sitefinity 15 Generative AI from producing a large block of unformatted text into producing well-formatted HTML text that in most cases is ready to go without further interventions.

Sitefinity 15 and OpenAI Integration

The new version of Sitefinity offers integration with OpenAI services (Azure) to help content editors quickly produce text. This is an amazing start and it does really improve the content editing experience significantly. Azure AI Deployments are secure and you can rest assured your IP and sensitive prompts are not being used for training - so any concerns you may have should be covered.

To get it going you may need to turn to your development team or partner, as the module needs to be installed and set up, and you need an Azure Open AI instance configured.

Lino Tadros already covered this part:

We can of course help you with that - use our Contacts page to get in touch and we'll be more than happy to assist.

The Problem with the Default AI Output

We were playing with the AI for the past month or so and found that while very helpful, one thing was consuming significant time - the post-production work of formatting the AI output. By default, the Sitefinity Generative AI feature generates plain text with no formatting, which gets injected directly into your editor. True to ourselves, we went on thinking and experimenting about how to improve this.

The Fix - Redefining the Output Format

Following the steps below will allow you to redefine the output format and tell the AI to return text that in most cases will be ready to use straight away:

  1. Go to the Sitefinity backend.
  2. Click Administration.
  3. Click Settings.
  4. Click Advanced.
  5. Expand AIServices.
  6. Expand ServiceClients.
  7. Expand your AI Client (e.g. for us it is "AzureCompletionsOpenAIClient").
  8. Expand Actions.
  9. Expand ComposeNewText.
  10. Enter the new prompt in the prompt field. We used this one:
    Generate a text that includes these keypoints: "{KeyPoints}". The target audience is "{Audience}" and the tone is {Tone} and text length of no more than {Length} words. Use the following output: <h1>Title</h1><p>text</p>, if you need to list things - just use UL + LI structure. Return RAW HTML, do not use markdown.

Why This Works

The last part of the prompt is what makes the difference. In our case it forces the AI to produce a title wrapped in an H1 tag, followed by the generated text in paragraph tags - and outputs everything as raw HTML. Note that the preview screen in Sitefinity will still not properly display it, so you will want to insert the output into a Content block for an accurate preview.

Read More

Explore more insights and case studies from our team.