Month: November 2024
Weird Sharepoint 2019 search issue
We have Sharepoint 2019 on premise. We just found a strange search issue. Hope I can get some idea how to pin down the cause.
So user uploaded two files, one has title DriveCA Input Tool User Guide, name is DriveCA_Input_Tool_User_Guide.pdf, another file has same title, but file name is DriveCA_Input_Tool_User_Guide_2018.pdf.
When search “DriveCA Input Tool User Guide”, user only got DriveCA_Input_Tool_User_Guide_2018.pdf. After I did a full crawl, user can only got DriveCA_Input_Tool_User_Guide.pdf.
So I tried to figure out the cause, I change the title of the 2018 file from “DriveCA Input Tool User Guide” to “DriveCA Input Tool User Guide 2018″ so I can distinguish the two, also to avoid the hide duplicate mentioned in some article. I then found a interesting thing, when I search Title:”DriveCA*”, I can only get the “DriveCA Input Tool User Guide” file. Even I tried Title:”DriveCA*2018″ I cannot get the 2018 file. But if I search Title:”DriveCA Input Tool User Guide 2018″, I can get the 2018 file.
Any idea?
We have Sharepoint 2019 on premise. We just found a strange search issue. Hope I can get some idea how to pin down the cause.So user uploaded two files, one has title DriveCA Input Tool User Guide, name is DriveCA_Input_Tool_User_Guide.pdf, another file has same title, but file name is DriveCA_Input_Tool_User_Guide_2018.pdf.When search “DriveCA Input Tool User Guide”, user only got DriveCA_Input_Tool_User_Guide_2018.pdf. After I did a full crawl, user can only got DriveCA_Input_Tool_User_Guide.pdf.So I tried to figure out the cause, I change the title of the 2018 file from “DriveCA Input Tool User Guide” to “DriveCA Input Tool User Guide 2018″ so I can distinguish the two, also to avoid the hide duplicate mentioned in some article. I then found a interesting thing, when I search Title:”DriveCA*”, I can only get the “DriveCA Input Tool User Guide” file. Even I tried Title:”DriveCA*2018″ I cannot get the 2018 file. But if I search Title:”DriveCA Input Tool User Guide 2018″, I can get the 2018 file.Any idea? Read More
how to make a chart that separates total data by month/year
I’ve attached a picture of the hours that are calculated in my spreadsheet (clinical, direct care, individual supervision, group supervision, direct observation and training hours.) I need to total each of the columns by month/year in a separate chart. I don’t have any data entered in the spreadsheet yet and will need the totals automatically added to the other chart as they’re entered. Can someone help me with how this chart might look and what formulas I would use? The clinical hours will be totaled for about 2 years. Thanks in advance!
I’ve attached a picture of the hours that are calculated in my spreadsheet (clinical, direct care, individual supervision, group supervision, direct observation and training hours.) I need to total each of the columns by month/year in a separate chart. I don’t have any data entered in the spreadsheet yet and will need the totals automatically added to the other chart as they’re entered. Can someone help me with how this chart might look and what formulas I would use? The clinical hours will be totaled for about 2 years. Thanks in advance! Read More
Unable to edit font or font color in Forms
I created a form and used my own logo image. I would like to change the font and font size color; however, when I select the words/text I am not able to change the font or font color. I can see the options for Bold, Italic, Underline but I am not able to select them/they are appeared “grayed” out as if it is not an option to select.
I created a form and used my own logo image. I would like to change the font and font size color; however, when I select the words/text I am not able to change the font or font color. I can see the options for Bold, Italic, Underline but I am not able to select them/they are appeared “grayed” out as if it is not an option to select. Read More
Query for Power query , Power pivot and Power bi launching
I am not able to run power query, power pviot and also power bi.
If i choose file in data from excel to import file for power query it opens but immediately the closes and open a recovery file. If i want to open the power bi file the app opens for just 10 second but again the app closes. further if i want to click power pivot then in manage i get the error of no data model is abled to load.
I have office 365 and windows 11 is installed. all updates are already done. Kindly help
I am not able to run power query, power pviot and also power bi.If i choose file in data from excel to import file for power query it opens but immediately the closes and open a recovery file. If i want to open the power bi file the app opens for just 10 second but again the app closes. further if i want to click power pivot then in manage i get the error of no data model is abled to load.I have office 365 and windows 11 is installed. all updates are already done. Kindly help Read More
Introducing the modern web app pattern for .NET
We are excited to introduce the Modern Web App (MWA) pattern for .NET. MWA is part of our Enterprise App Patterns (EAP), that offers guidance to accelerate app modernization to the cloud. MWA provides developer patterns, prescriptive architecture, reference implementation, and infrastructure guidance that aligns with the principles of the Azure Well-Architected Framework (WAF) and 12-factor app methodologies so you can be assured the guidance is real-world proven.
The Modern Web App (MWA) pattern marks the next stage in transforming monolithic web applications toward cloud-native architecture, with a focus on the Refactor modernization strategy. Building on the Reliable Web App (RWA) pattern, which helped organizations transition to cloud with minimal changes under a Replatform approach, MWA guides teams further by encouraging decoupling and decomposition of key functions into microservices. This enables high-demand areas to be optimized for agility and scalability, providing dedicated resources for critical components and enhancing reliability and performance. Decoupling also allows independent versioning and scaling, delivering cost efficiency and flexibility to evolve individual app components without affecting the entire system.
Key Features of Modern Web App pattern
The Modern Web App Pattern provides detailed guidance to decouple critical parts of a web application, enabling independent scaling, greater agility, and cost optimization. This decoupling approach ensures that high-demand components have dedicated resources and may be versioned and scaled independently, improving the reliability and performance of the application and agility to enhance features separately. By separating services, the risk of degradation in one part of the app affecting other parts is minimized. Here are some strategies MWA adopts:
Modernization through Refactoring
Built on top of the Reliable Web App Pattern, MWA focuses on optimizing high-demand areas of web applications by decoupling critical components.
Incremental modernization using strangler-fig pattern
Guidance for incremental refactoring from monolithic to decoupled services, reducing risks during modernization and improving agility for new features.
Embracing Cloud-Native architectures
Leverages Azure services such as Azure App Services, Azure Container Apps, Azure Container Registry, Azure Service Bus, Azure Monitor and more to build independently scalable, resilient cloud-native applications.
Independent scaling using Azure Container Apps
Allows key parts of the app to scale independently, optimizing resource usage and reducing costs.
Enhanced security and availability
Hub and Spoke architecture for production infrastructure improves security and isolates workloads, and multi-region deployment supports a 99.9% business srvice-level objectives (SLO).
What’s covered in the reference implementation?
In this context, we use a fictional company, Relecloud’s, evolving business needs to illustrate the Modern Web App (MWA) pattern, which takes scalability further through decoupling and refactoring of monolithic line-of-business web app. This architecture enables independent scaling via microservices for high demand, supporting Relecloud’s growth while enhancing security, agility and reliability meeting the 99.9% business SLO uptime requirement.
Azure Services
Developer Patterns
Best Practices
Patterns from RWA
Other awesomeness!
Azure Front Door
Microsoft Entra ID
Azure App Service
Azure Container Apps
Azure Container Registry
Azure Cache for Redis
Azure SQL
Azure Storage
Azure Key Vault
Azure App Configuration
Azure Service Bus
Azure Monitor and App Insights
Strangler Fig
Queue-based Load Leveling
Competing Consumers
Health Endpoint Monitoring
Feature rollouts using Feature Flags
Distributed Tracing
Managed Identities
Private endpoints
Hub and Spoke network architecture
Retry
Circuit-breaker
Cache-aside
Azure Developer CLI (azd)
Reusable modular IaC assets (Bicep)
Resource Tagging
Multi-region support with 99.9% business SLO
Dev and Prod Environments & SKUs
.. and more!
Get started
We created a full production-grade application that you can deploy easily to Azure to see all of the principles of MWA in action. Visit the MWA GitHub repo for more information.
Check out all of the in-depth documentation on Microsoft Learn.
Try out the patterns included in MWA and share your feedback in comments.
Microsoft Tech Community – Latest Blogs –Read More
November 1st 2024 Microsoft Defender Update Removed Software
2 things that I should preface with:
#1: Torrent software is fully legal insofar as it’s being used for legal purposes. Piracy (the use of torrent software to download or share copyrighted material without consent of the copyright-holder) is illegal.
#2: I scanned by software’s installation files and scanned my entire computer. The software has no viruses.
Microsoft Defender was updated today as a background update, and go figure suddenly my torrent software has totally disappeared. The little taskbar icon where it was is now displayed as a white ambiguous file image; clicking it brings up an error message saying that the shortcut was either moved or changed and asking me if I would like to delete it. No, I would not. I want my software back. I am wondering if removing Microsoft Defender (I never have it turned on anyway, I use Avira) or if I backtrack the update to where my PC was before the update occurred if my torrent software will come back and be re-enabled. My concern is also that other apps on my PC, not just torrent software, may have also been removed or lost without my knowledge. Does anybody know how to fix this?
2 things that I should preface with: #1: Torrent software is fully legal insofar as it’s being used for legal purposes. Piracy (the use of torrent software to download or share copyrighted material without consent of the copyright-holder) is illegal.#2: I scanned by software’s installation files and scanned my entire computer. The software has no viruses. Microsoft Defender was updated today as a background update, and go figure suddenly my torrent software has totally disappeared. The little taskbar icon where it was is now displayed as a white ambiguous file image; clicking it brings up an error message saying that the shortcut was either moved or changed and asking me if I would like to delete it. No, I would not. I want my software back. I am wondering if removing Microsoft Defender (I never have it turned on anyway, I use Avira) or if I backtrack the update to where my PC was before the update occurred if my torrent software will come back and be re-enabled. My concern is also that other apps on my PC, not just torrent software, may have also been removed or lost without my knowledge. Does anybody know how to fix this? Read More
Can I remove Groups from outlook.com website??
So I loaded up outlook the other day and noticed this Groups tab which I have NO groups for but I have this annoying red thing that says…
IF I have NO groups then there is nothing to retrieve so why is there an error icon?! How do I get rid of this annoying new issue that you guys have created for zero reason. You lot always add RUBBISH that nobody asks for and give us zero way to remove your crappy updates.
So I loaded up outlook the other day and noticed this Groups tab which I have NO groups for but I have this annoying red thing that says… IF I have NO groups then there is nothing to retrieve so why is there an error icon?! How do I get rid of this annoying new issue that you guys have created for zero reason. You lot always add RUBBISH that nobody asks for and give us zero way to remove your crappy updates. Read More
Embracing the Future: How AI is Revolutionizing the Way We Work
In today’s fast-paced technological world, Artificial Intelligence (AI) has emerged as a powerful force, transforming industries and redefining how we work and live. One groundbreaking innovation is Microsoft Copilot, an AI-powered assistant designed to enhance productivity, creativity, and overall user experience.
From Reactive to Proactive AI
Before diving into the specifics of Copilot, let’s explore a fundamental shift in AI capabilities: the transition from reactive to proactive AI.
Reactive AI: This traditional approach requires users to initiate interactions and guide the AI through every step. It responds to specific commands or questions, delivering information or performing tasks as directed.
Proactive AI: This advanced form of AI goes beyond responding to user inputs. It anticipates user needs, offers suggestions, and performs tasks autonomously. Proactive AI empowers users by streamlining workflows, providing valuable insights, and sparking creativity.
The Power of Proactive AI with Microsoft Copilot
Microsoft Copilot embodies the principles of proactive AI. Here’s how it transforms the way we work:
Enhanced Productivity: Copilot actively analyses workflows, identifying opportunities for automation and efficiency. It suggests relevant actions, streamlining tasks, and saving valuable time.Creative Inspiration: This AI companion sparks creativity by generating ideas, assisting in brainstorming sessions, and even aiding in content creation. Copilot understands your preferences and context, providing tailored suggestions to fuel your imagination.Streamlined Decision-Making: Proactive AI gathers data from various sources, analyzes trends, and presents actionable insights. This empowers users to make informed decisions quickly and confidently.
Embrace the Future
By embracing AI tools like Microsoft Copilot, we unlock the full potential of technology. This shift from reactive to proactive AI is not just a technological advancement; it’s a cultural shift that demands adaptation and a willingness to embrace change. As we journey into the future, let’s embrace AI as a powerful ally, empowering us to achieve more, innovate more, and ultimately, live more fulfilling lives.
Are you ready to unlock the power of AI and elevate your workflow? Share your experiences and thoughts in the comments below.
In today’s fast-paced technological world, Artificial Intelligence (AI) has emerged as a powerful force, transforming industries and redefining how we work and live. One groundbreaking innovation is Microsoft Copilot, an AI-powered assistant designed to enhance productivity, creativity, and overall user experience. From Reactive to Proactive AI Before diving into the specifics of Copilot, let’s explore a fundamental shift in AI capabilities: the transition from reactive to proactive AI. Reactive AI: This traditional approach requires users to initiate interactions and guide the AI through every step. It responds to specific commands or questions, delivering information or performing tasks as directed. Proactive AI: This advanced form of AI goes beyond responding to user inputs. It anticipates user needs, offers suggestions, and performs tasks autonomously. Proactive AI empowers users by streamlining workflows, providing valuable insights, and sparking creativity. The Power of Proactive AI with Microsoft Copilot Microsoft Copilot embodies the principles of proactive AI. Here’s how it transforms the way we work: Enhanced Productivity: Copilot actively analyses workflows, identifying opportunities for automation and efficiency. It suggests relevant actions, streamlining tasks, and saving valuable time.Creative Inspiration: This AI companion sparks creativity by generating ideas, assisting in brainstorming sessions, and even aiding in content creation. Copilot understands your preferences and context, providing tailored suggestions to fuel your imagination.Streamlined Decision-Making: Proactive AI gathers data from various sources, analyzes trends, and presents actionable insights. This empowers users to make informed decisions quickly and confidently. Embrace the Future By embracing AI tools like Microsoft Copilot, we unlock the full potential of technology. This shift from reactive to proactive AI is not just a technological advancement; it’s a cultural shift that demands adaptation and a willingness to embrace change. As we journey into the future, let’s embrace AI as a powerful ally, empowering us to achieve more, innovate more, and ultimately, live more fulfilling lives. Are you ready to unlock the power of AI and elevate your workflow? Share your experiences and thoughts in the comments below. Read More
Dependent Drop Downs across multiple rows in a spreadsheet
Hello. I’ve been trying to create a spreadsheet that has a dependent dropdown column. However, all the guides and advice I’ve seen so far have been functional only when you only need a single cell or a small number of cells to have this drop-down. I’d like this function for a large spreadsheet that I will be adding to frequently.
My first thought as a workaround is – is there a way to have data validation read an adjacent cell? The issue I seem to be having is that while I can set Data Validation to =INDIRECT(A2) – it applies that to every cell in the column, so it will only search A2. Is there a a way to have data validation go =INDIRECT(“CellAdjacentToThisOne”)? I would have thought there’s a formula for identifying whatever is in an adjacent cell, but I can’t figure out what to look for sorry.
Failing that, if there’s a workaround for getting dependent dropdowns to function through large spreadsheets, I’d love to hear it. I only have one layer of depdency – the first selection will draw from a wide range of options, but that will be the depth of it.
I’m wondering if part of the issue might be that I’m in Office 365 – some of the tutorials use the Name Manager, but it seems to function or maybe it just looks different in the desktop version of Excel, so maybe it has some feature I don’t have access too?
Any advice would be appreciated.
Hello. I’ve been trying to create a spreadsheet that has a dependent dropdown column. However, all the guides and advice I’ve seen so far have been functional only when you only need a single cell or a small number of cells to have this drop-down. I’d like this function for a large spreadsheet that I will be adding to frequently. My first thought as a workaround is – is there a way to have data validation read an adjacent cell? The issue I seem to be having is that while I can set Data Validation to =INDIRECT(A2) – it applies that to every cell in the column, so it will only search A2. Is there a a way to have data validation go =INDIRECT(“CellAdjacentToThisOne”)? I would have thought there’s a formula for identifying whatever is in an adjacent cell, but I can’t figure out what to look for sorry. Failing that, if there’s a workaround for getting dependent dropdowns to function through large spreadsheets, I’d love to hear it. I only have one layer of depdency – the first selection will draw from a wide range of options, but that will be the depth of it. I’m wondering if part of the issue might be that I’m in Office 365 – some of the tutorials use the Name Manager, but it seems to function or maybe it just looks different in the desktop version of Excel, so maybe it has some feature I don’t have access too? Any advice would be appreciated. Read More
trying to recover product key
I bought new windows product key , and windows 10 works great but my computer is to old for windows 11 , so I upgraded my hardware but when I went to update windows Microsoft could not find my new product key because it had been attach to my old mother board and not to my account ; I still have the old board so I’m wondering if I get the old system going would I be able to recover the product key , and does both of the computers have to be on in order for Microsoft to transfer the key to my new computer.
I bought new windows product key , and windows 10 works great but my computer is to old for windows 11 , so I upgraded my hardware but when I went to update windows Microsoft could not find my new product key because it had been attach to my old mother board and not to my account ; I still have the old board so I’m wondering if I get the old system going would I be able to recover the product key , and does both of the computers have to be on in order for Microsoft to transfer the key to my new computer. Read More
Outlook no longer accepts appointments via Bookings and appointments are not displayed in Outlook
Hello dear community,
I have had a problem since today that when customers book an appointment with me via Bookings, this booking is only displayed in the Bookings calendar and no longer in Outlook (both in the Outlook program and in Outlook Web). Outlook no longer automatically confirms the appointment either. I haven’t changed any of the settings and everything worked as usual until yesterday. Is this a general problem? Can someone help me here?
Thanks in advance!
———————-
Hallo liebe Community,
ich habe seit heute das Problem, dass wenn Kunden über Bookings einen Termin bei mir buchen, dass diese Buchung nur im Bookings-Kalender aber nicht mehr in Outlook angezeigt wird (sowohl im Outlook-Programm als auch im Outlook Web). Outlook bestätigt den Termin auch nicht mehr automatisch. An den Einstellungen habe ich nichts geändert und bis gestern hat auch noch alles wie gewohnt funktioniert. Ist das ein allgemeines Problem? Kann mir hier jemand helfen?
Danke schon einmal im Voraus!
Hello dear community,I have had a problem since today that when customers book an appointment with me via Bookings, this booking is only displayed in the Bookings calendar and no longer in Outlook (both in the Outlook program and in Outlook Web). Outlook no longer automatically confirms the appointment either. I haven’t changed any of the settings and everything worked as usual until yesterday. Is this a general problem? Can someone help me here?Thanks in advance!———————-Hallo liebe Community,ich habe seit heute das Problem, dass wenn Kunden über Bookings einen Termin bei mir buchen, dass diese Buchung nur im Bookings-Kalender aber nicht mehr in Outlook angezeigt wird (sowohl im Outlook-Programm als auch im Outlook Web). Outlook bestätigt den Termin auch nicht mehr automatisch. An den Einstellungen habe ich nichts geändert und bis gestern hat auch noch alles wie gewohnt funktioniert. Ist das ein allgemeines Problem? Kann mir hier jemand helfen?Danke schon einmal im Voraus! Read More
How to Disable the Strong Password Requirement
Hello,
I followed the instructions in the Set strong passwords guide and used the following command
Update-MgUser -UserId <UserPrincipalName> -PasswordPolicies “DisableStrongPassword”
However, when I tried to set a simple password, I still received the message: “Choose a password that is harder to guess.”
Could you please assist me in resolving this issue?
Thank you.
Hello,I followed the instructions in the Set strong passwords guide and used the following command Update-MgUser -UserId <UserPrincipalName> -PasswordPolicies “DisableStrongPassword” However, when I tried to set a simple password, I still received the message: “Choose a password that is harder to guess.”Could you please assist me in resolving this issue?Thank you. Read More
Trouble Editing data in a cell, ivolves entire sheet
I’ve tried several different ideas but haven’t solved my problem. It drops me a cell either down or sidewise.
I’ve tried several different ideas but haven’t solved my problem. It drops me a cell either down or sidewise. Read More
MGDC for SharePoint FAQ: How can I estimate my Azure bill? Updated!
Introduction
When gathering SharePoint data through Microsoft Graph Data Connect, you are billed through Azure. As I write this blog, the price to pull 1,000 objects from Microsoft Graph Data Connect in the US is $0.75, plus the cost for Azure infrastructure like Azure Storage and Azure Synapse.
That is true for all datasets except the SharePoint Files dataset, which has a different billing rate. Because of its typical high volume, the SharePoint Files dataset is billed at $0.75 per 50,000 objects.
I wrote a blog about what counts as an object, but I frequently get questions about how to estimate the overall Azure bill for the Microsoft Graph Data Connect for SharePoint for a specific project. Let me try to clarify things…
Before we start, here are a few notes and disclaimers:
These are estimates and your specific Azure bill will vary.
Check the official Azure links provided. Rates may vary by country and over time.
These are Azure pay-as-you-go list prices in the US as of October 2024.
You may benefit from Azure discounts, like savings using a pre-paid plan.
How many objects?
To estimate the number of objects, you start by finding out the number of sites in the tenant. This should include all sites (not just active sites) in your tenant. You can find this number easily in the SharePoint Admin Center. That will be the number of objects in your SharePoint Sites dataset.
Finding the number of SharePoint Groups and SharePoint Permissions will require some estimation. I recently collected some telemetry and saw that the average number of SharePoint Groups per Site for a sample of large tenants was around 31. The average SharePoint permissions per site was around 61. The average number of files per site was 2,874.
Delta pulls (gathering just what changed) will be smaller, but that also varies depending on how much collaboration happens in your tenant (in the Delta numbers below, I am estimating a 5% change for an average collaboration level).
Here’s a table to help you estimate your Microsoft Graph Data Connect for SharePoint costs:
Notes for the table above:
* Higher collaboration level assumes twice the average in terms of groups, permissions and files.
** Security scenario includes Sites, Groups and Permissions. Capacity Scenario includes Sites and Files.
*** Delta assumes 5% change for average collaboration and 10% change for high collaboration. These are on the high side for one week’s worth of changes. Your numbers will likely be smaller.
As you can see, smaller tenants with an average collaboration will see costs below $10 for the smaller Sites dataset and below $1,000 for larger datasets like Permissions or Files.
If you want to estimate the number of SharePoint objects more precisely, there is an option to sample the dataset and get a total object count without pulling the entire dataset. For more information, see MGDC for SharePoint FAQ: How can I sample or estimate the number objects in a dataset?
The official information about Microsoft Graph Data Connect pricing is at https://azure.microsoft.com/en-us/pricing/details/graph-data-connect/
How much storage?
The SharePoint information you get from Microsoft Graph Data Connect will be stored in an Azure Storage account. That also incurs some cost, but it’s usually small when compared to the Microsoft Graph Data Connect costs for data pulls. The storage will be proportional to the number of objects and to the size of these objects.
Again, this will vary depending on the amount of collaboration in the tenant. More sharing means more members in groups and more people in the permissions, which will result in more objects and also larger objects.
I also did some estimating of object size and arrived at around 2KB per SharePoint Site object, 20KB per SharePoint Group object, 3KB per Permission object and 1KB per file object. There are several Azure storage options including Standard vs. Premium, LRS vs. GRS, v1 vs. v2 and Hot vs. Cool. For Microsoft Graph Data Connect, you can go with a Standard + LRS + V2 + Cool blob storage account, which costs $0.01 per GB per month.
Here’s a table to help you estimate your Azure Storage costs:
The same notes from the previous table apply here.
As you can see, smaller tenants with average collaboration will see storage costs below $1000/month, most of it going to storing the larger Files dataset. The cost for delta dataset storage is also fairly small, even for the largest of tenants. There are additional costs per storage operation like read and write but those are negligible at this scale (for instance, $0.065 per 10,000 writes and $0.005 per 10,000 reads).
The official information about Azure Storage pricing is at https://azure.microsoft.com/en-us/pricing/details/storage/blobs/
What about Synapse?
You will also typically use Azure Synapse to move the SharePoint data from Microsoft 365 to your Azure account. You could run a pipeline daily to get the information and do some basic processing, like computing deltas or creating aggregations.
Here are a few of the items that are billed for Azure Synapse when running Microsoft Graph Data Connect pipelines:
Azure Hosted – Integration Runtime – Data Movement – $0.25/DIU-hour
Azure Hosted – Integration Runtime – Pipeline Activity (Azure Hosted) – $0.005/hour
Azure Hosted – Integration Runtime – Orchestration Activity Run – $1 per 1,000 runs
vCore – $0.15 per vCore-hour
As with Azure Storage, the costs here are small. You will likely need one pipeline run per day and it will typically run in less than one hour for a small tenant. Large tenants might need a few hours per run to gather all their SharePoint datasets. You should expect less than $10/month for smaller tenants and less than $100/month for larger and/or more collaborative tenants.
The official information about Azure Synapse pricing is at https://azure.microsoft.com/en-us/pricing/details/synapse-analytics/
Closing notes
These are the main meters in Azure to get you started with costs related to Microsoft Graph Data Connect for SharePoint. I suggest experimenting with a small test/dev tenant to get familiar with Azure billing.
For more information about Microsoft Graph Data Connect for SharePoint, see the links at https://aka.ms/SharePointData.
Microsoft Tech Community – Latest Blogs –Read More
Teams main page
Since the beginning of my subscription, EVERYTIME I am in a Teams meeting, I am in a small box in the lower right guest corner and not on the main page where other meeting participants are. After many instances of people trying to fix the problem, nobody has. How do I correct this problem? Please help!
Since the beginning of my subscription, EVERYTIME I am in a Teams meeting, I am in a small box in the lower right guest corner and not on the main page where other meeting participants are. After many instances of people trying to fix the problem, nobody has. How do I correct this problem? Please help! Read More
Access to start menu
Windows 10 IoT Enterprise LTSC
Version 21H2
Installed on 16/10/2024
OS build 19044.5011
Experience Windows Feature Experience Pack 1000.19060.1000.0
Following update KB5044273 ‘left click’ Windows logo and search bar inoperative. (right click ok)
Uninstalled update – everything working fine. See event viewer dump below.
Note : SFC scan showed no problems.
Log Name: Application
Source: Application Error
Date: 01/11/2024 21:13:01
Event ID: 1000
Task Category: (100)
Level: Error
Keywords: Classic
User: N/A
Computer: DESKTOP-9G9MAB2
Description:
Faulting application name: StartMenuExperienceHost.exe, version: 0.0.0.0, time stamp: 0x124eac11
Faulting module name: KERNELBASE.dll, version: 10.0.19041.2913, time stamp: 0xa1c3e870
Exception code: 0xc000027b
Fault offset: 0x000000000012d862
Faulting process id: 0x2e4
Faulting application start time: 0x01db2ca2d52abc83
Faulting application path: C:WINDOWSSystemAppsMicrosoft.Windows.StartMenuExperienceHost_cw5n1h2txyewyStartMenuExperienceHost.exe
Faulting module path: C:WINDOWSSystem32KERNELBASE.dll
Report Id: 628d9b62-4894-46fd-8d44-f6f935319ae7
Faulting package full name: Microsoft.Windows.StartMenuExperienceHost_10.0.19041.4239_neutral_neutral_cw5n1h2txyewy
Faulting package-relative application ID: App
Event Xml:
<Event xmlns=”http://schemas.microsoft.com/win/2004/08/events/event“>
<System>
<Provider Name=”Application Error” />
<EventID Qualifiers=”0″>1000</EventID>
<Version>0</Version>
<Level>2</Level>
<Task>100</Task>
<Opcode>0</Opcode>
<Keywords>0x80000000000000</Keywords>
<TimeCreated SystemTime=”2024-11-01T21:13:01.5650495Z” />
<EventRecordID>12114</EventRecordID>
<Correlation />
<Execution ProcessID=”0″ ThreadID=”0″ />
<Channel>Application</Channel>
<Computer>DESKTOP-9G9MAB2</Computer>
<Security />
</System>
<EventData>
<Data>StartMenuExperienceHost.exe</Data>
<Data>0.0.0.0</Data>
<Data>124eac11</Data>
<Data>KERNELBASE.dll</Data>
<Data>10.0.19041.2913</Data>
<Data>a1c3e870</Data>
<Data>c000027b</Data>
<Data>000000000012d862</Data>
<Data>2e4</Data>
<Data>01db2ca2d52abc83</Data>
<Data>C:WINDOWSSystemAppsMicrosoft.Windows.StartMenuExperienceHost_cw5n1h2txyewyStartMenuExperienceHost.exe</Data>
<Data>C:WINDOWSSystem32KERNELBASE.dll</Data>
<Data>628d9b62-4894-46fd-8d44-f6f935319ae7</Data>
<Data>Microsoft.Windows.StartMenuExperienceHost_10.0.19041.4239_neutral_neutral_cw5n1h2txyewy</Data>
<Data>App</Data>
</EventData>
</Event>
Windows 10 IoT Enterprise LTSCVersion 21H2Installed on 16/10/2024OS build 19044.5011Experience Windows Feature Experience Pack 1000.19060.1000.0 Following update KB5044273 ‘left click’ Windows logo and search bar inoperative. (right click ok)Uninstalled update – everything working fine. See event viewer dump below.Note : SFC scan showed no problems. Log Name: ApplicationSource: Application ErrorDate: 01/11/2024 21:13:01Event ID: 1000Task Category: (100)Level: ErrorKeywords: ClassicUser: N/AComputer: DESKTOP-9G9MAB2Description:Faulting application name: StartMenuExperienceHost.exe, version: 0.0.0.0, time stamp: 0x124eac11Faulting module name: KERNELBASE.dll, version: 10.0.19041.2913, time stamp: 0xa1c3e870Exception code: 0xc000027bFault offset: 0x000000000012d862Faulting process id: 0x2e4Faulting application start time: 0x01db2ca2d52abc83Faulting application path: C:WINDOWSSystemAppsMicrosoft.Windows.StartMenuExperienceHost_cw5n1h2txyewyStartMenuExperienceHost.exeFaulting module path: C:WINDOWSSystem32KERNELBASE.dllReport Id: 628d9b62-4894-46fd-8d44-f6f935319ae7Faulting package full name: Microsoft.Windows.StartMenuExperienceHost_10.0.19041.4239_neutral_neutral_cw5n1h2txyewyFaulting package-relative application ID: AppEvent Xml:<Event xmlns=”http://schemas.microsoft.com/win/2004/08/events/event”><System><Provider Name=”Application Error” /><EventID Qualifiers=”0″>1000</EventID><Version>0</Version><Level>2</Level><Task>100</Task><Opcode>0</Opcode><Keywords>0x80000000000000</Keywords><TimeCreated SystemTime=”2024-11-01T21:13:01.5650495Z” /><EventRecordID>12114</EventRecordID><Correlation /><Execution ProcessID=”0″ ThreadID=”0″ /><Channel>Application</Channel><Computer>DESKTOP-9G9MAB2</Computer><Security /></System><EventData><Data>StartMenuExperienceHost.exe</Data><Data>0.0.0.0</Data><Data>124eac11</Data><Data>KERNELBASE.dll</Data><Data>10.0.19041.2913</Data><Data>a1c3e870</Data><Data>c000027b</Data><Data>000000000012d862</Data><Data>2e4</Data><Data>01db2ca2d52abc83</Data><Data>C:WINDOWSSystemAppsMicrosoft.Windows.StartMenuExperienceHost_cw5n1h2txyewyStartMenuExperienceHost.exe</Data><Data>C:WINDOWSSystem32KERNELBASE.dll</Data><Data>628d9b62-4894-46fd-8d44-f6f935319ae7</Data><Data>Microsoft.Windows.StartMenuExperienceHost_10.0.19041.4239_neutral_neutral_cw5n1h2txyewy</Data><Data>App</Data></EventData></Event> Read More
Document Library Approval Emails Not Coming Through
I’d like to start using approvals for certain doc libraries. I’ve turned them on and, on the SharePoint side, they appear to be working, but the site owner is not getting approval emails. (I’m the site owner BTW.) My account gets other emails from SharePoint just find and our Exchange admin says nothing’s being blocked to my account.
The library settings are below. What am I missing?
In Microsoft’s documentation, the only place I can find to designate approval accounts are for page approvals via Power Automate. I set that up as well, thinking maybe that would transfer to doc library approvals, but nope. (Page approvals are working find BTW.)
I’d like to start using approvals for certain doc libraries. I’ve turned them on and, on the SharePoint side, they appear to be working, but the site owner is not getting approval emails. (I’m the site owner BTW.) My account gets other emails from SharePoint just find and our Exchange admin says nothing’s being blocked to my account. The library settings are below. What am I missing? In Microsoft’s documentation, the only place I can find to designate approval accounts are for page approvals via Power Automate. I set that up as well, thinking maybe that would transfer to doc library approvals, but nope. (Page approvals are working find BTW.) Read More
October 2024 V2 Title Plan now available!
October V2 Title Plan has been uploaded. Go to: aka.ms/Courseware_Title_Plan
Don’t forget to checkout bi-weekly updates made to the Title Plan, shared in its permanent location, linked above.
Please note: This is not a support forum. Only necessary comments related to this specific blog post content are permitted and responded to.
For Training Services Partners support:
aka.ms/TSP_Learn_Resources
partner.microsoft.com/support
For Microsoft Certified Trainers support:
Microsoft Tech Community – Latest Blogs –Read More
Additional MB courses coming in December! MB-7005 & 7006
Course Name: MB-7005: Create and manage journeys with Dynamics 365 Customer Insights
Release Date: December 13th, 2024 (Release dates are subject to change)
Duration: 1-Day ILT
Solution Area: Business Applications
Credential: Applied Skills Assessment
Course Description:
Audience:
Students in this course should be familiar with Dynamics 365 Customer Insights and have an interest in running marketing campaigns and basic marketing principles.
Course Name: MB-7006: Create and manage segments in Customer Insights – Data
Release Date: December 13th, 2024 (Release dates are subject to change)
Duration: 1-Day ILT
Solution Area: Business Applications
Credential: Applied Skills Assessment
Course Description:
Audience:
Students should be familiar with Customer Insights – Data and have an interest in building segments that target unified profiles. Some segmentation/marketing experience and some simple data analysis experience is recommended.
Please note: This is not a support forum. Only comments related to this specific blog post content are permitted and responded to.
If you have ILT questions not related to this blog post, please reach out to your program forums & resources for additional support.
For Training Services Partners:
aka.ms/TSP_Learn_Resources
partner.microsoft.com/support
For Microsoft Certified Trainers:
Microsoft Tech Community – Latest Blogs –Read More
Azure Open IA, acelerando nossos caminhos.
Há algum tempo temos ouvido falar sobre o OpenAI, que se tornou um dos temas mais requisitados da atualidade. É comum sentirmos o desejo de testar suas funcionalidades, porém, surge a dúvida de por onde começar e como fazê-lo sem comprometer a confidencialidade de nossos dados.
O caminho que vou apresentar aqui envolve o uso de um acelerador do Azure para o OpenAI azure-search-openai-demo, ele nos auxiliará desde a configuração da infraestrutura até a implementação de aplicações de exemplo. Fiquei impressionado com a facilidade de uso, a estratégia de usar o “azd” facilitou muito as coisas, veja como instalar aqui Install the Azure Developer CLI | Microsoft Learn
Basta executar alguns comandos e pronto, o ambiente estará todo configurado no Azure. Eu apenas criei uma nova pasta sem clonar nenhum repositório e executei esses comandos.
azd auth login
azd up
1-) azd init -t azure-search-openai-demo
azd init -t azure-search-openai-demo
2-) azd auth login
azd auth login
3-) azd up
azd up
Ao fim da execução de mais ou menos 30 minutos, pude ver esses recursos criados:
Lista de recursos criados
Visualizador de Recursos:
Mapa dos recursos
A aplicação nasce pronta:
Aplicação de exemplo do acelerador
Arquivos criados ao rodar o comando azd init -t azure-search-openai-demo:
Arquivos criados ao rodar o comando azd init -t azure-search-openai-demo
Basta fazer as perguntas. Inclusive, uma série de documentos de exemplo foram adicionados à solução, os quais podem ser encontrados na pasta local “data” ou no armazenamento do Azure.
O próximo passo será trabalhar com a ingestão de dados. Existe um guia na própria documentação do acelerador intitulado Indexing documents for the Chat App. Para começar, vou fazer o upload de um artigo meu do blog, chamado “Escalando nodes e escalando e pods no AKS. | by Wilson Santos | Medium”, para isso, basta gerar um PDF e colocar o arquivo dentro da pasta “data” do acelerador, diretamente na sua máquina local.
Após isso, você irá executar um pequeno script em PowerShell chamado “prepdoc”. O comando para executá-lo é o seguinte
Assim que terminar de rodar podemos fazer perguntas sobre esse conteúdo.
O acelerador traz uma implementação em React e python e podemos estudar como ela funciona usando esse código que fica na pasta app do acelerador
Temos um front em React e um backend em Python, mas caso você esteja acostumado com C# que é o meu caso, nada melhor que explorar os SDKS do Azure.AI.OpenAI e o SemanticKernel que eu estou apresentando a seguir.
Agora, vamos criar um pequeno programa em .NET Core Console que aproveitará toda a infraestrutura criada pelo acelerador. Este programa será capaz de fazer perguntas ao Azure Open AI e, além disso, responderá com base nos documentos que forem atualizados na base de conhecimento. Para isso, utilizaremos o pacote Azure.AI.OpenAI. No meu exemplo, estou utilizando a versão 2.0.0.
Primeiro passo vamos criar um client da classe AzureOpenAIClient:
Para as credenciais e o endpoint, utilizamos uma chave do recurso que pode ser obtida na seção “Keys and Endpoint” da instância do Azure OpenAI.
var credential = new AzureKeyCredential(“…”);
Depois, vamos criar uma instancia da classe chamada SearchClient. Essa classe ajudará na conexão com o serviço de busca (Search service).
algo assim:
var searchEndpoint = new Uri(“…”);
var searchCredential = new AzureKeyCredential(“…”);
var indexName = “gptkbindex”;
var searchClient = new SearchClient(searchEndpoint, indexName, searchCredential);
var searchOptions = new SearchOptions
{
Size = 5 // Número de documentos a recuperar
};
var searchResults = searchClient.Search<SearchDocument>(text, searchOptions);
var retrievedDocuments = searchResults.Value.GetResults().Select(result => result.Document[“content”].ToString());
var context = string.Join(“n”, retrievedDocuments);
A classe SearchClient também requer o uso de uma chave de segurança. Para encontrá-la, acessamos a instância do serviço de busca (Search service) na seção “Keys”
o endpoint esta em overview
Agora vamos criar uma instancia da classe ChatClient, que será responsável por fazer perguntas para o OpenAI, e passar o prompt para o Azure openIA.
E aqui que está o grande segredo do RAG, tudo é prompt, pegamos o resultado da busca do SearchClient que está na variável context e juntamos no prompt.
var prompt = $”Contexto: {context}nPergunta: {text}”;
ChatClient chatClient = await azureClient.CompleteChatAsync(“gpt-4o”);
ChatCompletion completion = chatClient.CompleteChat(new List<ChatMessage>
{
new SystemChatMessage(“Você é um assistente atencioso”),
new UserChatMessage(prompt),
});
Para obter o valor do campo DeploymentName, no meu caso o gpt-4o, você pode encontrá-lo na instância do OpenAI. Basta abrir os “Model deployments”, clicar em “Management deployment”. Isso abrirá o Azure OpenAI Studio, onde você poderá visualizar os modelos implantados.
os pacotes utilizados foram esses:
<PackageReference Include=”Azure.Identity” Version=”1.13.1″ />
<PackageReference Include=”Azure.Search.Documents” Version=”11.4.0″ />
using Azure.AI.OpenAI;
using Azure.Search.Documents;
using Azure.Search.Documents.Models;
using OpenAI.Chat;
public class Program
{
static async Task Main(string[] args)
{
while (true)
{
Console.WriteLine(“Digite uma Pergunta”);
var question = Console.ReadLine();
if (question != null)
{
var result = await AskingChatCompletionWithSearchsAsync(question);
Console.WriteLine(result);
}
}
}
static async Task<string> AskingChatCompletionWithSearchsAsync(string text)
{
var endpoint = new Uri(“https://openiapriv02.openai.azure.com/”);
var credential = new AzureKeyCredential(“…”);
AzureOpenAIClient azureClient = new(endpoint, credential);
var searchEndpoint = new Uri(“https://gptkb-kv4atymcdg6pg.search.windows.net”);
var searchCredential = new AzureKeyCredential(“…”);
var indexName = “gptkbindex”;
var searchClient = new SearchClient(searchEndpoint, indexName, searchCredential);
var searchOptions = new SearchOptions
{
Size = 5 // Número de documentos a recuperar
};
var searchResults = searchClient.Search<SearchDocument>(text, searchOptions);
var retrievedDocuments = searchResults.Value.GetResults().Select(result => result.Document[“content”].ToString());
var context = string.Join(“n”, retrievedDocuments);
var prompt = $”Contexto: {context}nPergunta: {text}”;
ChatClient chatClient = azureClient.GetChatClient(“gpt-4o”);
ChatCompletion completion = await chatClient.CompleteChatAsync(new List<ChatMessage>
{
new SystemChatMessage(“Você é um assistente atencioso”),
new UserChatMessage(prompt),
});
var result = $”{completion.Role}: {completion.Content[0].Text}”;
return result;
}
}
fiz uma pergunta para o assistente com base em um documento que já veio de exemplo no acelerador o Benefit_Options.pdf, perguntei o que é o programa Northwind Health Plus?. Observe que a resposta é dada com base nos documentos indexados no Search service
Os modelos são constantemente atualizados com novas características, as versões de modelo são a maneira de controlar essas mudanças do OpenAI.
Em particular, os modelos GPT-3.5 Turbo e GPT-4 recebem atualizações regulares com novos recursos. Por exemplo, as versões 0613 do GPT-3.5 Turbo e GPT-4 introduziram a chamada de função. A chamada de função é um recurso popular que permite ao modelo criar saídas estruturadas que podem ser usadas para chamar ferramentas externas. Fique atento aos modelos disponíveis para sua região quais modelos seu SDK suporta, saiba mais em Azure OpenAI Service model versions — Azure OpenAI | Microsoft Learn
O Semantic Kernel é um SDK de código aberto projetado para integrar com o código existente. Ele suporta várias linguagens de programação, incluindo C#, Python e Java. Através de conectores e plugins, o Semantic Kernel permite adicionar inteligencia aos aplicativos. Sua flexibilidade permite aos desenvolvedores orquestrar o código existente sem se prender a um provedor específico de modelos de IA, proporcionando liberdade na escolha e combinação de serviços conforme as necessidades do projeto. Saiba mais
Vamos fazer algumas implementações básicas, a começar por um chat básico sem RAG, é importante lembrar que alguns dos pacotes usados ainda estão em versões alpha não indicados para ambiente produtivo.
vamos começar a instalar o pacote
Agora vamos criar uma representação do que o SDK chama de Kernel, essa representação já adiciona a injeção do Chat Completion da nossa instancia do Azure Open IA
var builder = Kernel.CreateBuilder();
builder.AddAzureOpenAIChatCompletion(
“gpt-4o”, // Azure OpenAI Deployment Name
“https://wsopenia.openai.azure.com/”, // Azure OpenAI Endpoint
“…”); // Azure OpenAI Key
var kernel = builder.Build();
O prompt no Semantic Kernel é um template em formato texto que permite valorar variáveis, chamar funções e extrair valores, para isso usamos as chaves {{…}}. no nosso exemplo temos as variáveis history e input em uma estrutura que mostra para a IA quais informações são a entrada de usuário e quais são apenas instruções. para saber mais sobre prompt Using the out-of-the-box prompt template language | Microsoft Learn
var prompt = @”Chat:{{$history}} User:{{$input}}”;
Agora usamos o método CreateFunctionFromPrompt especificando as configurações de prompt como MaxTokens, Temperatura etc.
{
MaxTokens = 500,
ToolCallBehavior = ToolCallBehavior.AutoInvokeKernelFunctions
});
e usando a classe KernelArguments, passamos os valores das variáveis
arguments[“input”] = question;
arguments[“history”] = questionHistory;
a etapa final é chamar as funções InvokeAsync passando a instancia de “kf” e passando a instancia dos argumentos
var result = await kernel.InvokeAsync(kf, arguments);
um exemplo de implementação é essa:
var arguments = new KernelArguments();
var prompt = @”Chat:{{$history}} User:{{$input}}”;
var kf = kernel.CreateFunctionFromPrompt(prompt, executionSettings: new OpenAIPromptExecutionSettings
{
MaxTokens = 500,
ToolCallBehavior = ToolCallBehavior.AutoInvokeKernelFunctions
});
var questionHistory = “”;
while (true)
{
Console.WriteLine(“Digite uma Pergunta”);
var question = Console.ReadLine();
// Add user input
arguments[“input”] = question;
var result = await kernel.InvokeAsync(kf, arguments);
Console.WriteLine(“result:” + result);
//Console.WriteLine(“history:” + questionHistory);
questionHistory += “Chat:” + result + “User:” + question + “n”;
arguments[“history”] = questionHistory;
}
aqui não temos RAG apenas o LLM respondendo a pergunta “o que é o Azure OpenIA”?
Pacotes utilizados:
Com ele podemos usar os plugins para interagir com nosso código existente como por exemplo consultar pedidos em uma base de dados, e podemos usar os conectores para integrar com os serviços de IA, por exemplo o Azure openIA, saiba mais
Vou mostrar um exemplo de plugin, vou criar uma classe order:
public sealed class Order
{
[KernelFunction, Description(“Show order details for number”)]
public static string Sqrt([Description(“The number to order details”)] double number1)
{
return $”The detail about order {number1} is your current state is closed.”;
}
}
perceba que descrevemos seu comportamento usando um atributo KernelFunction
depois eu vou adicionar esse plugin dessa forma:
var builder = Kernel.CreateBuilder();
builder.Plugins.AddFromType<Order>();
feito isso podemos optar pela auto chamada configurando a classe OpenAIPromptExecutionSettings com propriedade ToolCallBehavior setada para o valor AutoInvokeKernelFunctions
OpenAIPromptExecutionSettings openAIPromptExecutionSettings = new()
{
ToolCallBehavior = ToolCallBehavior.AutoInvokeKernelFunctions,
};
o restante do código é o mesmo mas vou colocar um exemplo completo aqui:
builder.AddAzureOpenAIChatCompletion(
“gpt-4o”, // Azure OpenAI Deployment Name
“https://cog-nggxeq6fpjnxg.openai.azure.com/”, // Azure OpenAI Endpoint
“…”); // Azure OpenAI Key
builder.Plugins.AddFromType<Order>();
var arguments = new KernelArguments();
var prompt = @”Chat:{{$history}} User:{{$input}}”;
var kf = kernel.CreateFunctionFromPrompt(prompt, executionSettings: new OpenAIPromptExecutionSettings
{
MaxTokens = 500,
ToolCallBehavior = ToolCallBehavior.AutoInvokeKernelFunctions
});
var questionHistory = “”;
while (true)
{
Console.WriteLine(“Digite uma Pergunta”);
var question = Console.ReadLine();
// Add user input
arguments[“input”] = question;
var result = await kernel.InvokeAsync(kf, arguments);
Console.WriteLine(“result:” + result);
questionHistory += “Chat:” + result + “User:” + question + “\n”;
arguments[“history”] = questionHistory;
}
console e execução respondendo a pergunta “Show order details for number 10”?
pacotes utilizados:
Aqui temos o uso de um conector e de um plugin, o conector vai adicionar accesso ao IA Search por meio dessa implementação:
memoryBuilder.WithMemoryStore(new AzureAISearchMemoryStore(
“https://gptkb-nggxeq6fpjnxg.search.windows.net”,
“…”)
);
Alem do pacote do Microsoft.SemanticKernel ainda vamos precisar de mais dois pacotes o Microsoft.SemanticKernel.Connectors.AzureAISearch e o Microsoft.SemanticKernel.Plugins.Memory
Mas também precisamos do plugin TextMemoryPlugin para acessar as memorias, mas ates de acessar vamos cria-las
Para isso vamos usar essa implementação:
const string MemoryCollectionName = “aboutMe”;
await memory.SaveInformationAsync(MemoryCollectionName, id: “info1”, text: “My name is Andrea”);
await memory.SaveInformationAsync(MemoryCollectionName, id: “info2”, text: “I currently work as a tourist operator”);
await memory.SaveInformationAsync(MemoryCollectionName, id: “info3”, text: “I currently live in Seattle and have been living there since 2005”);
await memory.SaveInformationAsync(MemoryCollectionName, id: “info4”, text: “I visited France and Italy five times since 2015”);
await memory.SaveInformationAsync(MemoryCollectionName, id: “info5”, text: “My family is from New York”);
kernel.ImportPluginFromObject(new TextMemoryPlugin(memory));
Com isso sera gerado um index na IA Search chamado aboutme
lista de indexs
Search explorer
Campos do index
esse index foi gerado usando esse Text Embedding text-embedding-ada-002, que é um tipo de algoritmo de vetorização
Deployments Azure OpenAI Studio
com essa implementação temos a configuração da instancia do Azure openIA que irá fazer o embending das perguntas usando o modelo text-embedding-ada-002 :
memoryBuilder.WithTextEmbeddingGeneration((loggerFactory, httpClient) => {
return new AzureOpenAITextEmbeddingGenerationService(
“text-embedding-ada-002”, // Embedding generation service name
“https://openiapriv02.openai.azure.com/”,
“…”,
httpClient: httpClient,
loggerFactory: loggerFactory
);
});
por fim para fazer as perguntas ao chat e receber resposta que vem desse index como se fossem uma lembrança do chat, mas antes precisamos enriquecer o prompt com essas informações algo assim:
const string skPrompt = @”
ChatBot can have a conversation with you about any topic.
It can give explicit instructions or say ‘I don’t know’ if it does not have an answer.
Information about me, from previous conversations:
– {{$fact1}} {{recall $fact1}}
– {{$fact2}} {{recall $fact2}}
– {{$fact3}} {{recall $fact3}}
– {{$fact4}} {{recall $fact4}}
– {{$fact5}} {{recall $fact5}}
Chat:
{{$history}}
User: {{$userInput}}
ChatBot: “;
esses valores serão passados pelo KernelArguments:
arguments[“fact1”] = “What my name?”;
arguments[“fact2”] = “where do I live?”;
arguments[“fact3”] = “where is my family from?”;
arguments[“fact4”] = “where have I travelled?”;
arguments[“fact5”] = “what do I do for work?”;
veja a implementação completa:
var builder = Kernel.CreateBuilder();
builder.AddAzureOpenAIChatCompletion(
“gpt-35-turbo”, // Azure OpenAI Deployment Name
“https://cog-nggxeq6fpjnxg.openai.azure.com/”, // Azure OpenAI Endpoint
“…”); // Azure OpenAI Key
var kernel = builder.Build();
#pragma warning disable SKEXP0001, SKEXP0010, SKEXP0050, SKEXP0020
var memoryBuilder = new MemoryBuilder();
memoryBuilder.WithTextEmbeddingGeneration((loggerFactory, httpClient) => {
return new AzureOpenAITextEmbeddingGenerationService(
“text-embedding-ada-002”, // Embedding generation service name
“https://openiapriv02.openai.azure.com/”,
“…”,
httpClient: httpClient,
loggerFactory: loggerFactory
);
});
memoryBuilder.WithMemoryStore(new AzureAISearchMemoryStore(
“https://gptkb-nggxeq6fpjnxg.search.windows.net”,
“…”)
);
var memory = memoryBuilder.Build();
const string MemoryCollectionName = “aboutMe”;
await memory.SaveInformationAsync(MemoryCollectionName, id: “info1”, text: “My name is Andrea”);
await memory.SaveInformationAsync(MemoryCollectionName, id: “info2”, text: “I currently work as a tourist operator”);
await memory.SaveInformationAsync(MemoryCollectionName, id: “info3”, text: “I currently live in Seattle and have been living there since 2005”);
await memory.SaveInformationAsync(MemoryCollectionName, id: “info4”, text: “I visited France and Italy five times since 2015”);
await memory.SaveInformationAsync(MemoryCollectionName, id: “info5”, text: “My family is from New York”);
var questions = new[]
{
“what is my name?”,
“where do I live?”,
“where is my family from?”,
“where have I travelled?”,
“what do I do for work?”,
};
#pragma warning disable SKEXP0050
// TextMemoryPlugin provides the “recall” function
kernel.ImportPluginFromObject(new TextMemoryPlugin(memory));
const string skPrompt = @”
ChatBot can have a conversation with you about any topic.
It can give explicit instructions or say ‘I don’t know’ if it does not have an answer.
Information about me, from previous conversations:
– {{$fact1}} {{recall $fact1}}
– {{$fact2}} {{recall $fact2}}
– {{$fact3}} {{recall $fact3}}
– {{$fact4}} {{recall $fact4}}
– {{$fact5}} {{recall $fact5}}
Chat:
{{$history}}
User: {{$userInput}}
ChatBot: “;
var chatFunction = kernel.CreateFunctionFromPrompt(skPrompt, new OpenAIPromptExecutionSettings { MaxTokens = 200, Temperature = 0.8 });
#pragma warning disable SKEXP0050
var arguments = new KernelArguments();
arguments[“fact1”] = “What my name?”;
arguments[“fact2”] = “where do I live?”;
arguments[“fact3”] = “where is my family from?”;
arguments[“fact4”] = “where have I travelled?”;
arguments[“fact5”] = “what do I do for work?”;
arguments[TextMemoryPlugin.CollectionParam] = MemoryCollectionName;
arguments[TextMemoryPlugin.LimitParam] = “2”;
arguments[TextMemoryPlugin.RelevanceParam] = “0.8”;
var history = “”;
arguments[“history”] = history;
Func<string, Task> Chat = async (string input) => {
// Save new message in the kernel arguments
arguments[“userInput”] = input;
// Process the user message and get an answer
var answer = await chatFunction.InvokeAsync(kernel, arguments);
// Append the new interaction to the chat history
var result = $”nUser: {input}nChatBot: {answer}n”;
history += result;
arguments[“history”] = history;
// Show the bot response
Console.WriteLine(result);
};
while (true)
{
Console.WriteLine(“Digite uma Pergunta”);
var question = Console.ReadLine();
if (question != null)
{
await Chat(question);
}
}
console e execução respondendo a pergunta “What my name”?
Pacotes utilizados:
<PackageReference Include=”Microsoft.SemanticKernel.Connectors.AzureAISearch” Version=”1.6.3-alpha” />
<PackageReference Include=”Microsoft.SemanticKernel.Plugins.Memory” Version=”1.6.3-alpha” />
<PackageReference Include=”System.Linq.Async” Version=”6.0.1″ />
azure-search-openai-demo
azure-search-openai-demo-csharp
Azure/Vector-Search-AI-Assistant at cognitive-search-vector (github.com)
Troubleshoot Azure Developer CLI | Microsoft Learn
Usar seus próprios dados com o Serviço OpenAI do Azure — Azure OpenAI | Microsoft Learn
Indexing documents for the Chat App
AzureAIServicesLandingZone
Create AI agents with Semantic Kernel | Microsoft Learn
Using the out-of-the-box prompt template language | Microsoft Learn
Azure OpenAI Service model versions — Azure OpenAI | Microsoft Learn
GUEST POST: Getting Started with Semantic Kernel for LangChain users | Semantic Kernel (microsoft.com)
Introducing API Manifest Plugins for Semantic Kernel | Semantic Kernel (microsoft.com)
Microsoft Tech Community – Latest Blogs –Read More