[MS Breakfast] Slides de ma session sur le RAG avec Azure AI Studio

Dans le cadre de cette première édition des « Microsoft breakfast » (« Petit-déjeuner Microsoft ») en décembre 2023, qui a été un véritable succès (merci à tous nos partenaires et aux speakers d’exception que sont Sylver SCHORGEN et Mehdi MAHRONG) je vous avais promis mes slides … mais disons que le temps à passer, qu’il a plu ces derniers jours et que j’ai repris les entrainements de trail … bref, j’avais juste complètement zappé et mon copilot ne l’a pas fait pour moi pendant ce temps😅

Alors les voici les slides de la session « MSBreakfast – Azure OpenAI et Microsoft 365 Copilot » :

How to activate Bing Chat Enterprise

Here we are, Bing Chat Enterprise is out ! Have a look at the official product page : Your AI-Powered Chat for Work | Bing Chat Enterprise (microsoft.com). With Edge for Business already available, Edge is placing itself as personal and professional place to browse and use Internet service.

  1. Connect to this link to accept Bing Chat Enterprise Supplemental terms : https://www.bing.com/business/bceadmin
  2. Check the box to accept terms and click on Activate in Bing chat Enterprise zone :

In case of success you will have the following message :

If you are licensed for Microsoft 365 E3, E5, Business Standard, Business Premium, or A3 or A5 for faculty, it will comes at no additional costs for your company.

Next time, you and your collegues, will open Edge, you should see a Protected label in the upper right corner that indicates Bing Enterprise is enable and you can share data and conversations with Bing Chat securely and privately.

Setup Matomo Analytics to SharePoint Online

Matomo is one of the best alternative (in terms of ease of implementation and basic features, not in terms of advanced features) in Europe for GDRP compliant analytics solution 🚀.

Matomo comes in two flavours :

  • Cloud Hosting (prices here – with commercial plugins included)
  • Self-Hosted with manuel installation (open source/free of licence cost – no commercial plugins included)

Once you have your Matomo environment ready, take the train :


  1. Create your website in Matomo and get your « tracking site ID »
  2. Check your account have the right permission to add a solution to your Tenant App Catalog (if you deploy to your tenant app catalog => https://docs.microsoft.com/en-us/sharepoint/use-app-catalog) or in your Site collection App Catalog (if you deploy your tracking custom action to a site collection, or on a per site collection basis => https://docs.microsoft.com/en-us/sharepoint/dev/general-development/site-collection-app-catalog)
  3. Install Pnp PowerShell by following these steps : Installing PnP PowerShell | PnP PowerShell
  4. Download the addin and the setup script zip archive here (lastest is v1.1.0 now) : Releases · Microsoft SharePoint / SPFx / Matomo Analytics · GitLab (lsonline.fr). Feel freee to modify the source to add whatever features you need (ex : custom dimensions, …).

Add and setup the Matomo SPfx custom action

  1. Open a PowerShell console prompt
  2. Connect to your tenant with : Connect-PnPOnline -Url https://<your_tenant_name>.sharepoint.com -Interactive
    • Interactive parameter is for MFA authentication. If you don’t use MFA, omit this parameter
  3. Unzip the zip archive previously downloaded in the prerequisites
  4. Execute the following command at the root of the unzipped folder : .\setup.ps1 -siteUrl https://<your-tenant_name>.sharepoint.com -trackingUrl https://matomo.mydomain.com -trackingSiteId ‘<my_tracking_site_id>’ -tenantSolutionDeployment
    • In this case, I deployed on the entire tenant (all site collections). You can omit this parameter to deploy only on a site collection.
  5. Crack your favorite webbrowser, connect to your Matomo instance, your SharePoint is already recording user actions.

Happy analytics 👍😎

How to integrate OpenAI API (Text, Codex, DALL-e, ChatGPT coming soon) in your .NET Core app in 15 minutes

OpenAI API overview (from Open AI)

The OpenAI API can be applied to virtually any task that involves understanding or generating natural language or code. We offer a spectrum of models with different levels of power suitable for different tasks, as well as the ability to fine-tune your own custom models. These models can be used for everything from content generation to semantic search and classification.

To makes it a little more understandable, so with OpenAI API you can : generate and edit text, generate/edit/explain code, generate and edit images, train a model, search, classify and comapre text. Checkt the documentation here.

We will use DaVinci GPT-3 model in our app, but you can try other models :

text-davinci-003Most capable GPT-3 model. Can do any task the other models can do, often with higher quality, longer output and better instruction-following. Also supports inserting completions within text.4,000 tokensUp to Jun 2021
text-curie-001Very capable, but faster and lower cost than Davinci.2,048 tokensUp to Oct 2019
text-babbage-001Capable of straightforward tasks, very fast, and lower cost.2,048 tokensUp to Oct 2019
text-ada-001Capable of very simple tasks, usually the fastest model in the GPT-3 series, and lowest cost.2,048 tokensUp to Oct 2019

Important : today (02/17/2023), ChatGPT API is not yet available but OpenAI indicates that it will come soon.

Phase 1 : get your secret API key

  1. Go to the OpenAI website and create a new account
  2. Signup for an OpenAI account
  3. Confirm your email address
  4. Log in to your account and navigate to the ‘View API keys’ dashboard
  5. Click on ‘Create a new secret key’

Store your API key in a secure location. You can test the API right now, but if you intend to use OpenAI API in a real workld case scanerio, check OpenAI documentation for details on usage and pricing.

 Phase 2 : create you .NET Core project to consume OpenAI API

  1. Open Visual Studio 2022
  2. Create a new .NET Core project (in my case a Web API)
  3. Install the ‘OpenAI‘ NuGet package as below :

4. In your program.cs file, just copy the following code (replace the apiKey with yours, generated in phase 1)

using OpenAI_API;
using OpenAI_API.Completions;

var builder = WebApplication.CreateBuilder(args);

var app = builder.Build();


app.MapGet("/givemesecretoftheuniverse", (string prompt) =>
    var apiKey = "sk-5ucaz1m00000000000000000000000000000000";
    var answer = string.Empty;

    var openAIAPI = new OpenAIAPI(apiKey);

    var completionRequest = new CompletionRequest
        Prompt = prompt,
        Model = OpenAI_API.Models.Model.DavinciText,
        MaxTokens = 2000

        var result = openAIAPI.Completions.CreateCompletionAsync(completionRequest);

        if (result != null)
            foreach (var item in result.Result.Completions)
                answer += item.Text;
            return Results.Text("Answer of the universe : " + answer);
            return Results.BadRequest("Not found");
    catch (Exception)
        return Results.Problem("OpenAI API is not available or key are incorrect");


5. Run your application, and open your Postman app or your favorite web browser to open the following URL : https://<your computer ip / localhost>:<your project port>/givemesecretoftheuniverse?prompt=what is the secret of the universe

6. The flow of the power of OpenAI will flow throught your screen 😁🚀🌚

More possibilities 🚀😁

As said earlier, you can use Codex, Dall-E, etc from OpenAI just by changing the Model = OpenAI_API.Models.Model statement and adapt your code consequently. Today, ChatGPT API is not yet available but OpenAI indicates that it will come soon.

You can also try this .NET library which is pretty cool as well : https://github.com/betalgo/openai


Integrating OpenAI APIs into your application is just as easy as creating a minimal API with .NET Core, so test it, learn it, and make our world a better one. With ChatGPT coming soon, accessible AI is becoming a reality.

Power Pages presentation slide deck from aMS Singapore/Kuala Lumpur is here 👍

J’ai eu l’occasion de présenter la session « Power Pages : low code .. really ? » à l’aMS de Singapore et de Kuala Lumpur, qui sont une révision révisée de celle réalisé en Juin 2022. Notamment des informations importantes au niveau licencing.

La voici ➡️ https://www.dropbox.com/s/uqy5o141ggwtl8x/aMs%20Singapore%20-%20Kuala%20Lumpur%20-%20Power%20Pages%20introduction.pdf?dl=0

SharePoint maintenance mode to track webpart issue

As a SharePoint consultant, I often bump into issues with pages in SharePoint OnPrems and Online. To resolve these cases, we – SP consultants – need to deploy our super magic powers (what our clients think we have) 🙂

Most of the page, an error in a page is due to a bug in a webpart raising an exception, sometimes it’s a delegate control but this is another story for another blog post. Here is one magic trick to debug the pages and identify which webpart is running wrong.

SharePoint OnPrems / Classic

Starting from SP 2010, and for next version of OnPrems installation, just add ?contents=1 at the end of the page URL. This will open the page in maintenance mode and display all webparts in this page.

Modern SharePoint

Like a lots of developers I tried the old way and failed … thanks to this Microsoft support article, it gives you the right URL suffix to add to your URLs to enter the web part maintenance mode

In the address line of your browser, append ?maintenancemode=true to the end of the URL for the page. Checkout the Environment property in the mainten

You can find more documentation on these links ➡️ Maintenance mode for client-side web parts | Microsoft Docs and ➡️ Open and use the web part maintenance page (microsoft.com)

Bonus : how to disable SPFx web parts ans extensions

Ayt the end of this nice Microsoft article there is a golden tips ➡️ « If you need to troubleshoot a SharePoint page to see if there is a SharePoint Framework extension or web part causing issues you can append ?disable3PCode=1 to the URL to disable loading of SPFx components » that helped me a lot recently, so I share it to you.

Master piece : all useful SharePoint URLs

You can find every useful SharePoint URLs to save your life every day with SharePoint developement :Useful SharePoint URLs – SharePoint Stuff

O365 Echange ‘Your organization does not allow external forwarding’ issue

If you are receiving the following error in your email :

Delivery has failed to these recipients or groups:
Your message wasn’t delivered because the recipient’s email provider rejected it.

And then when you go into the message content you read this error:

Remote Server returned ‘550 5.7.520 Access denied, Your organization does not allow external forwarding. Please contact your administrator for further assistance. AS(7555)’

You might be experiencing the new security change Microsoft implemented on late 2020, which by default blocks forwarding to external recipients on a mailbox.

To resolve this issue, go to https://protection.office.com and go under Threat Management > Policy > Anti-Spam Policy > Anti-spam outbound policy > Edit Policy :

The future forward messages to any mailbox will now be process successfully by O365. Cuation : the settings can take several minutes to take effect.

aOS Tahiti 03/03/2020 : session Serverless avec les Azure Functions disponible

Pour faire suite à l’aOS Tahiti (encor emerci pour l’accueil) qui s’est déroulé le 03/03/2020, j’ai eu l’occasion de présenter le « Serverless avec les Fonctions Azure » et la puissance qu’elles représentent dans une architecture Cloud / Nano Services. Cette session a été ajusté par rapport à Nouméa pour tenir dans un temps un peu plus serré.

Je vous laisse voir ou revoir les slides de cette session sur SlideShare :

PS : les fonctions Azure ça rocks ! 🙂

aOS Nouméa 28/02/2020 : session Serverless avec les Azure Functions disponible

Pour faire suite à l’aOS Nouméa qui s’est déroulé le 28/02/2020, j’ai eu l’occasion de présenter le « Serverless avec les Fonctions Azure » et la puissance qu’elles représentent dans une architecture Cloud / Nano Services.

Je vous laisse voir ou revoir les slides de cette session sur SlideShare :

aOS Nouméa 2020 – 28/02/2020 – Le Serverless avec Azure Function de Julien Chable

Meilleurs voeux pour 2020 !

Toute l’équipe NCIT vous souhaite une bonne année 2020 remplie de santé, de réussite et de succès !

Nous en profitons pour remercier nos clients et partenaires pour la magnifique année 2019 qui s’est écoulée.

Vers de nouveaux projets ensemble !

Bonne année 2020 !

NCIT, local software maker with <3