Congratulations!

[Valid Atom 1.0] This is a valid Atom 1.0 feed.

Recommendations

This feed is valid, but interoperability with the widest range of feed readers could be improved by implementing the following recommendations.

Source: https://blog.mikehacker.net/feed.xml

  1. <?xml version="1.0" encoding="utf-8"?>
  2. <feed xmlns="http://www.w3.org/2005/Atom" xmlns:media="http://search.yahoo.com/mrss/">
  3.    <title>Mike Hacker</title>
  4.    <link href="https://blog.mikehacker.net/feed.xml" rel="self" />
  5.    <link href="https://blog.mikehacker.net" />
  6.    <updated>2023-09-28T14:14:55-04:00</updated>
  7.    <author>
  8.        <name>Mike Hacker</name>
  9.    </author>
  10.    <id>https://blog.mikehacker.net</id>
  11.  
  12.    <entry>
  13.        <title>Are your organization’s secrets safe?</title>
  14.        <author>
  15.            <name>Mike Hacker</name>
  16.        </author>
  17.        <link href="https://blog.mikehacker.net/are-your-organizations-secrets-safe/"/>
  18.        <id>https://blog.mikehacker.net/are-your-organizations-secrets-safe/</id>
  19.        <media:content url="https://blog.mikehacker.net/media/posts/78/8ea77848-14fa-411b-9036-47aede65c5d7.jpg" medium="image" />
  20.  
  21.        <updated>2023-09-28T13:25:56-04:00</updated>
  22.            <summary>
  23.                <![CDATA[
  24.                        <img src="https://blog.mikehacker.net/media/posts/78/8ea77848-14fa-411b-9036-47aede65c5d7.jpg" alt="" />
  25.                    Keeping secrets safe is one of the most important aspects of software development and deployment. Secrets are sensitive information that can grant access to valuable resources, such as passwords, API keys, tokens, encryption keys, and certificates. If secrets are exposed, they can be used by&hellip;
  26.                ]]>
  27.            </summary>
  28.        <content type="html">
  29.            <![CDATA[
  30.                    <p><img src="https://blog.mikehacker.net/media/posts/78/8ea77848-14fa-411b-9036-47aede65c5d7.jpg" class="type:primaryImage" alt="" /></p>
  31.                <p>Keeping secrets safe is one of the most important aspects of software development and deployment. Secrets are sensitive information that can grant access to valuable resources, such as passwords, API keys, tokens, encryption keys, and certificates. If secrets are exposed, they can be used by malicious actors to compromise the security and integrity of the software and the data it handles. Therefore, developers need to follow best practices to protect their secrets from unauthorized access and leakage.</p>
  32. <p>One of the common mistakes that developers make is embedding secrets in source code or in configuration files. This can lead to secrets being compromised in several ways, such as:</p>
  33. <ul>
  34. <li>Secrets in source code or configuration files can be accidentally checked into version control systems.</li>
  35. <li>Source code or configuration files can be copied or transferred to other locations, such as backup servers, cloud storage, or email attachments, and become accessible to unauthorized parties.</li>
  36. <li>Source code or configuration files can be exposed to third-party services or tools, such as code analysis, testing, or deployment tools, and become vulnerable to interception or theft.</li>
  37. <li>Improperly protected encrypted configuration files can be stolen and brute force decrypted over time.</li>
  38. </ul>
  39. <p>To avoid these risks, developers should never embed secrets in source code or in configuration files. Instead, they should use secure methods to store and manage their secrets, such as Azure Key Vault.</p>
  40. <p>By following this best practice, developers can ensure that their secrets are kept safe and their software is secure. In this blog post, we will explore how you can use Azure Key Vault with your custom on-premises applications to protect your secrets.</p>
  41. <p>So what exactly is Azure Key Vault? Azure Key Vault is a cloud service that lets you securely store and access secrets, such as passwords, certificates, or cryptographic keys. You can use it to protect all of your secrets and control who can access it.</p>
  42. <p>For web applications running on Azure services, such as Azure App Service, using Key Vault is simple. The Azure App Service has a managed identity stored in Azure Active Directory that is used to enable the application to authenticate against Azure Key Vault.  Once authenticated the application can perform any necessary operations such as retrieving the latest value of a specific secret.  A simple tutorial for this process can be found here: <a href="https://learn.microsoft.com/en-us/azure/key-vault/general/tutorial-net-create-vault-azure-web-app">Tutorial - Use Azure Key Vault with an Azure web app in .NET | Microsoft Learn</a></p>
  43. <p>In the past, using Azure Key Vault for on-premises applications was a bit challenging. The biggest hurdle was that your application needed to authenticate against Azure Key Vault in order to have permissions to perform operations in the Vault.  This meant that you would still need to protect at least one secret, which was the API key for accessing Key Vault.  With Azure Arc, all of this has changed!</p>
  44. <p>Azure Arc is a service that enables you to manage and govern your hybrid cloud resources across different environments, such as on-premises, edge, and multi-cloud. One of the benefits of Azure Arc is that it allows you to extend Azure services and management capabilities to any infrastructure. Arc enabled servers receive an Azure managed identity, which is a secure and convenient way to authenticate and authorize access to Azure resources without storing any credentials in your code or configuration files. With an Azure managed identity, you can use the same identity and access management (IAM) policies and role-based access control (RBAC) that you use for your Azure resources to manage your arc enabled servers. This simplifies the security and compliance of your hybrid cloud environment.</p>
  45. <p>This means that if you arc enable your on-premises servers your developers can utilize Azure Key Vault with a managed identity. With managed identities, your custom applications can easily retrieve secrets directly from Key Vault without the need for any API keys or any other secrets being stored in source code or configuration files.  This is a huge step forward for your organization’s security practices.</p>
  46. <p>To get started you will need to Arc enable your on-premises application server for free. You can do this directly through the Azure portal using the steps included in this article: <a href="https://learn.microsoft.com/en-us/azure/azure-arc/servers/learn/quick-enable-hybrid-vm">Quickstart - Connect hybrid machine with Azure Arc-enabled servers - Azure Arc | Microsoft Learn</a></p>
  47. <p>Once your server is arc enabled, developers can use the Azure Key Vault SDK for .NET to easily access Key Vault with your servers managed identity.  An example C# application can be found here: <a href="https://learn.microsoft.com/en-us/azure/key-vault/secrets/quick-create-net?tabs=azure-cli">Quickstart - Azure Key Vault secrets client library for .NET | Microsoft Learn</a></p>
  48. <p>One additional benefit of using the Azure Key Vault SDK is that the same code that is used to authenticate your on-premises server to Key Vault is the exact same code that is used if your app is running directly in an Azure App Service. This makes your future application migration to Azure just a little bit easier.</p>
  49. <p>In this blog post, you have learned how to use Azure Arc to provide on-premises servers a managed identity so they can safely and securely authenticate with Azure Key Vault. This allows your developers to avoid storing sensitive credentials in your source code or configuration files and instead leverage the security and scalability of Azure. I hope you have found this post useful and informative.</p>
  50. <p>If you have any questions or would like to learn more about how using Azure Arc, Managed Identities, and Azure Key Vault can keep your organization’s secrets secure, please reach out to your Microsoft account team.</p>
  51.            ]]>
  52.        </content>
  53.    </entry>
  54.    <entry>
  55.        <title>.NET Conf 2023</title>
  56.        <author>
  57.            <name>Mike Hacker</name>
  58.        </author>
  59.        <link href="https://blog.mikehacker.net/net-conf-2023/"/>
  60.        <id>https://blog.mikehacker.net/net-conf-2023/</id>
  61.        <media:content url="https://blog.mikehacker.net/media/posts/77/NETCONF2023Nov14to16.png" medium="image" />
  62.            <category term="Events"/>
  63.  
  64.        <updated>2023-09-28T14:14:55-04:00</updated>
  65.            <summary>
  66.                <![CDATA[
  67.                        <img src="https://blog.mikehacker.net/media/posts/77/NETCONF2023Nov14to16.png" alt=".NET Conf 2023 logo" />
  68.                    November 14 - 16, 2023 | Online | Free .NET Conf is an annual online conference that showcases the latest developments and innovations in the .NET platform, open source, and dev tools. It is a free and interactive event that features speakers from the community&hellip;
  69.                ]]>
  70.            </summary>
  71.        <content type="html">
  72.            <![CDATA[
  73.                    <p><img src="https://blog.mikehacker.net/media/posts/77/NETCONF2023Nov14to16.png" class="type:primaryImage" alt=".NET Conf 2023 logo" /></p>
  74.                <p>November 14 - 16, 2023 | Online | Free</p>
  75. <p>.NET Conf is an annual online conference that showcases the latest developments and innovations in the .NET platform, open source, and dev tools. It is a free and interactive event that features speakers from the community and the .NET team, live sessions, Q&amp;A, trivia games, and prizes. It is a great opportunity for .NET developers to learn new skills, network with peers, and have fun. This year, .NET Conf 2023 will take place on November 14-16 2023. </p>
  76. <p><a href="https://www.dotnetconf.net/" target="_blank" rel="noopener noreferrer">Learn more</a></p>
  77.            ]]>
  78.        </content>
  79.    </entry>
  80.    <entry>
  81.        <title>WEBINAR: Optimize Azure Costs</title>
  82.        <author>
  83.            <name>Mike Hacker</name>
  84.        </author>
  85.        <link href="https://blog.mikehacker.net/webinar-optimize-azure-costs/"/>
  86.        <id>https://blog.mikehacker.net/webinar-optimize-azure-costs/</id>
  87.        <media:content url="https://blog.mikehacker.net/media/posts/76/Azure_Logo-Stacked.png" medium="image" />
  88.            <category term="Events"/>
  89.  
  90.        <updated>2023-09-05T09:25:32-04:00</updated>
  91.            <summary>
  92.                <![CDATA[
  93.                        <img src="https://blog.mikehacker.net/media/posts/76/Azure_Logo-Stacked.png" alt="Azure Logo" />
  94.                    Optimize Your Azure Costs: Unlock Savings and Efficiency Free webinar from Atmosera | September 14, 11 am PDT / 2 pm EDT Join the upcoming webinar on Azure cost optimization to discover valuable strategies and best practices that will help you optimize your cloud spending&hellip;
  95.                ]]>
  96.            </summary>
  97.        <content type="html">
  98.            <![CDATA[
  99.                    <p><img src="https://blog.mikehacker.net/media/posts/76/Azure_Logo-Stacked.png" class="type:primaryImage" alt="Azure Logo" /></p>
  100.                <h1>Optimize Your Azure Costs: Unlock Savings and Efficiency</h1>
  101. <p>Free webinar from Atmosera | September 14, 11 am PDT / 2 pm EDT</p>
  102. <p>Join the upcoming webinar on Azure cost optimization to discover valuable strategies and best practices that will help you optimize your cloud spending without compromising performance. Cost management becomes essential as businesses increasingly rely on the cloud for their computing needs. In this webinar, the expert speakers will guide you through practical tips, tools, and insights to maximize your Azure investment and unlock significant savings. Don’t miss this opportunity to gain a competitive edge while minimizing your cloud expenses.</p>
  103. <p><a href="https://www.atmosera.com/resources/event/optimize-your-azure-costs-unlock-savings-and-efficiency/" target="_blank" rel="noopener noreferrer">Learn more and register now!</a></p>
  104.            ]]>
  105.        </content>
  106.    </entry>
  107.    <entry>
  108.        <title>AI Training</title>
  109.        <author>
  110.            <name>Mike Hacker</name>
  111.        </author>
  112.        <link href="https://blog.mikehacker.net/ai-training/"/>
  113.        <id>https://blog.mikehacker.net/ai-training/</id>
  114.        <media:content url="https://blog.mikehacker.net/media/posts/75/ai.jpg" medium="image" />
  115.  
  116.        <updated>2023-08-10T11:21:38-04:00</updated>
  117.            <summary>
  118.                <![CDATA[
  119.                        <img src="https://blog.mikehacker.net/media/posts/75/ai.jpg" alt="" />
  120.                    Semantic Kernel Semantic Kernel is an open-source SDK that lets you easily combine AI services like OpenAI, Azure OpenAI, and Hugging Face with conventional programming languages like C# and Python. By doing so, you can create AI apps that combine the best of both worlds. AI Learning Hub Build&hellip;
  121.                ]]>
  122.            </summary>
  123.        <content type="html">
  124.            <![CDATA[
  125.                    <p><img src="https://blog.mikehacker.net/media/posts/75/ai.jpg" class="type:primaryImage" alt="" /></p>
  126.                <p><strong><a href="https://learn.microsoft.com/en-us/semantic-kernel/overview/" target="_blank" rel="noopener noreferrer">Semantic Kernel</a></strong><br>Semantic Kernel is an open-source SDK that lets you easily combine AI services like <a href="https://platform.openai.com/docs/" data-linktype="external">OpenAI</a>, <a href="https://azure.microsoft.com/products/cognitive-services/openai-service/" data-linktype="external">Azure OpenAI</a>, and <a href="https://huggingface.co/" data-linktype="external">Hugging Face</a> with conventional programming languages like C# and Python. By doing so, you can create AI apps that combine the best of both worlds.</p>
  127. <p><strong><a href="https://learn.microsoft.com/en-us/ai/" target="_blank" rel="noopener noreferrer">AI Learning Hub</a><br></strong>Build AI skills, connect with the community, earn credentials, learn from experts, and discover upcoming events.<strong><br></strong></p>
  128.            ]]>
  129.        </content>
  130.    </entry>
  131.    <entry>
  132.        <title>How to use Azure OpenAI Service to unlock new insights from government data and improve citizen services</title>
  133.        <author>
  134.            <name>Mike Hacker</name>
  135.        </author>
  136.        <link href="https://blog.mikehacker.net/how-to-use-azure-openai-service-to-unlock-new-insights-from-government-data-and-improve-citizen-services/"/>
  137.        <id>https://blog.mikehacker.net/how-to-use-azure-openai-service-to-unlock-new-insights-from-government-data-and-improve-citizen-services/</id>
  138.        <media:content url="https://blog.mikehacker.net/media/posts/74/AIImage.jpg" medium="image" />
  139.            <category term="Articles"/>
  140.  
  141.        <updated>2023-06-13T10:56:56-04:00</updated>
  142.            <summary>
  143.                <![CDATA[
  144.                        <img src="https://blog.mikehacker.net/media/posts/74/AIImage.jpg" alt="" />
  145.                    Note: This blog post was partially generated using AI. Introduction Government agencies have a wealth of data that can be used to enhance their decision making and service delivery. However, extracting meaningful insights from large and complex datasets can be challenging and time-consuming. Moreover, citizens&hellip;
  146.                ]]>
  147.            </summary>
  148.        <content type="html">
  149.            <![CDATA[
  150.                    <p><img src="https://blog.mikehacker.net/media/posts/74/AIImage.jpg" class="type:primaryImage" alt="" /></p>
  151.                <pre>Note: This blog post was partially generated using AI.</pre>
  152. <h1 class="ParagraphTextStyle">Introduction</h1>
  153. <p class="ParagraphTextStyle">Government agencies have a wealth of data that can be used to enhance their decision making and service delivery. However, extracting meaningful insights from large and complex datasets can be challenging and time-consuming. Moreover, citizens expect more from government services in terms of user experience and speed of access.</p>
  154. <p class="ParagraphTextStyle">This is where Azure OpenAI Service can help. Azure OpenAI Service provides REST API access to OpenAI's powerful language models including the GPT-4, GPT-3, Codex and Embeddings model series. These models can be easily adapted to your specific task including but not limited to content generation, summarization, semantic search, and natural language to code translation. You can access the service through REST APIs, Python SDK, or our web-based interface in the Azure OpenAI Studio.</p>
  155. <p class="ParagraphTextStyle">In this blog post, we will show you how to use Azure OpenAI Service to perform some common tasks that can benefit government agencies and their citizens. We will also discuss some best practices and responsible AI considerations when using generative models.</p>
  156. <h1>Content generation</h1>
  157. <p class="ParagraphTextStyle">One of the most popular applications of Azure OpenAI Service is content generation. You can use the service to generate text for various purposes such as reports, newsletters, emails, social media posts, etc. You can also customize the tone, style, and format of the generated text by providing some examples or parameters.</p>
  158. <p class="ParagraphTextStyle">For example, suppose you want to generate a newsletter for your agency that highlights some of the recent achievements and initiatives. You can use the GPT-4 model series to generate a draft of the newsletter based on some bullet points. Here is an example of how you can do that using Python SDK:</p>
  159. <p class="ParagraphTextStyle"><code>from azure.openai import GPT4Client<br></code><code>client = GPT4Client("&lt;your_api_key&gt;")<br></code><code>prompt = """<br></code><code>Generate a newsletter for our agency based on these bullet points:<br></code><code>- We launched a new website that provides easy access to our services and information<br></code><code>- We received an award for excellence in customer service from the National Association of Government Agencies<br></code><code>- We partnered with a local university to conduct a research project on improving public health outcomes<br></code><code>- We are hiring new staff members for various positions<br></code><code>The newsletter should:<br></code><code>- Have a catchy title<br></code><code>- Have an introduction that summarizes the main points<br></code><code>- Have a paragraph for each bullet point that provides more details<br></code><code>- Have a conclusion that thanks the readers and invites them to contact us for feedback or questions<br></code><code>- Have a professional and positive tone<br></code><code>"""<br></code><code>response = client.completions(prompt, model="gpt-4", stop="\n\n")<br></code><code>print(response.text)</code></p>
  160. <p class="ParagraphTextStyle">The output might look something like this:</p>
  161. <blockquote>
  162. <p class="ParagraphTextStyle">Our Agency's News: A New Website, An Award, A Research Project, And More!</p>
  163. <p class="ParagraphTextStyle">Hello,</p>
  164. <p class="ParagraphTextStyle">We are excited to share with you some of the latest news and updates from our agency. We have been working hard to improve our services and deliver value to our citizens. Here are some of the highlights:</p>
  165. <p class="ParagraphTextStyle">- We launched a new website that provides easy access to our services and information. You can now find everything you need on our website, from applying for benefits to requesting documents. You can also learn more about our mission, vision, and values, as well as our programs and projects. Our website is designed to be user-friendly, responsive, and accessible. We hope you enjoy it and find it useful.</p>
  166. <p class="ParagraphTextStyle">- We received an award for excellence in customer service from the National Association of Government Agencies. This award recognizes our efforts to provide high-quality service to our customers and stakeholders. We are honored by this recognition and we thank you for your trust and support. We will continue to strive for excellence and innovation in everything we do.</p>
  167. <p class="ParagraphTextStyle">- We partnered with a local university to conduct a research project on improving public health outcomes. This project aims to identify the best practices and strategies for enhancing public health in our community. We are collaborating with experts from various disciplines and sectors to conduct surveys, interviews, and data analysis. We expect to share the results and recommendations of this project in the near future.</p>
  168. <p class="ParagraphTextStyle">- We are hiring new staff members for various positions. We are looking for talented and motivated individuals who share our passion for public service. If you are interested in joining our team, please visit our website for more information on how to apply. We offer competitive salaries and benefits, as well as opportunities for learning and growth.</p>
  169. <p class="ParagraphTextStyle">We thank you for your interest in our agency and we hope you find this newsletter informative and engaging. If you have any feedback or questions, please feel free to contact us at &lt;your_email_address&gt;. We would love to hear from you.</p>
  170. <p class="ParagraphTextStyle">Sincerely,</p>
  171. <p>&lt;Your_name&gt;<br>&lt;Your_title&gt;<br>&lt;Your_agency&gt;</p>
  172. </blockquote>
  173. <p class="ParagraphTextStyle">As you can see, the GPT-4 model series can generate coherent and relevant text based on the given prompt. However, you should always review and edit the generated text before using it for any official purpose. You should also be aware of the potential risks and limitations of content generation, such as factual errors, plagiarism, bias, or harmful content. We will discuss more about responsible AI later in this post.</p>
  174. <h1 class="ParagraphTextStyle">Summarization</h1>
  175. <p class="ParagraphTextStyle">Another common task that can benefit from Azure OpenAI Service is summarization. You can use the service to summarize long and complex texts into shorter and simpler texts that capture the main points and key information. This can help you save time and resources, as well as improve readability and comprehension.</p>
  176. <p class="ParagraphTextStyle">For example, suppose you want to summarize a research paper that is relevant to your agency's work. You can use the Codex model series to generate a summary based on the abstract or the full text of the paper. Here is an example of how you can do that using Python SDK:</p>
  177. <p><code>from azure.openai import CodexClient</code><br><code>client = CodexClient("&lt;your_api_key&gt;")</code><br><code>prompt = """Summarize this research paper based on its abstract:</code></p>
  178. <p class="ParagraphTextStyle"><code>Title: The impact of COVID-19 on public health and social services: A systematic review and meta-analysis</code></p>
  179. <p class="ParagraphTextStyle"><code>Abstract: Background: The COVID-19 pandemic has posed unprecedented challenges to public health and social services worldwide. However, the evidence on the impact of COVID-19 on these sectors is still limited and fragmented.</code></p>
  180. <p class="ParagraphTextStyle"><code>Objective: To systematically review and synthesize the existing literature on the impact of COVID-19 on public health and social services, and to identify the gaps and priorities for future research.</code></p>
  181. <p class="ParagraphTextStyle"><code>Methods: We searched PubMed, Web of Science, Scopus, and Cochrane Library databases for studies published from January 1, 2020 to December 31, 2020 that assessed the impact of COVID-19 on public health and social services. We included studies that reported quantitative or qualitative data on outcomes such as service delivery, utilization, quality, access, satisfaction, workforce, costs, and policy responses. We excluded studies that focused on clinical aspects of COVID-19 or non-health-related sectors. We performed a narrative synthesis and a meta-analysis of the quantitative studies using random-effects models.</code></p>
  182. <p class="ParagraphTextStyle"><code>Results: We identified 8,734 records and included 176 studies in the review. The majority of the studies were from high-income countries (82%), used observational designs (85%), and focused on specific services or populations (79%). The most common outcomes were service delivery (59%), service utilization (55%), and workforce (36%). The narrative synthesis revealed that COVID-19 had a negative impact on public health and social services in terms of reduced availability, accessibility, and quality of services; decreased service utilization and satisfaction; increased workload and stress among staff; and increased costs and budget constraints. The meta-analysis showed that COVID-19 was associated with a significant decrease in service utilization across different types of services, with a pooled relative change of -0.34 (95% CI: -0.42, -0.26). The heterogeneity among the studies was high (I2 = 99%). The quality of the evidence was low to moderate according to the GRADE approach.</code></p>
  183. <p class="ParagraphTextStyle"><code>Conclusions: COVID-19 has had a substantial impact on public health and social services, affecting both the supply and demand sides of these sectors. There is a need for more comprehensive, comparative, and rigorous research to assess the long-term effects of COVID-19 and the effectiveness of policy responses on public health and social services."""</code></p>
  184. <p><code>response = client.completions(prompt, model="codex", stop="\n\n")</code><br><code>print(response.text)</code></p>
  185. <p class="ParagraphTextStyle">The output might look something like this:</p>
  186. <blockquote>
  187. <p class="ParagraphTextStyle">A possible summary is:</p>
  188. <p class="ParagraphTextStyle">This paper reviews how COVID-19 affected public health and social services around the world in 2020. It finds that COVID-19 reduced the availability, accessibility, and quality of these services; decreased their use and satisfaction; increased the workload and stress of staff; and increased costs and budget constraints. It also finds that COVID-19 reduced service utilization by 34% on average across different types of services. It calls for more research to evaluate the long-term effects of COVID-19 and the policy responses on these sectors.</p>
  189. </blockquote>
  190. <h1 class="ParagraphTextStyle">Semantic search</h1>
  191. <p class="ParagraphTextStyle">Another useful task that can benefit from Azure OpenAI Service is semantic search. You can use the service to search for relevant information or documents based on the meaning and context of your query, rather than just the keywords. This can help you find more accurate and comprehensive results, as well as discover new insights and connections.</p>
  192. <p class="ParagraphTextStyle">For example, suppose you want to search for best practices and guidelines for reopening schools during the COVID-19 pandemic. You can use the Embeddings model series to generate a semantic vector for your query and compare it with the semantic vectors of various documents or sources. Here is an example of how you can do that using Python SDK:</p>
  193. <p><code>from azure.openai import EmbeddingsClient</code><br><code>client = EmbeddingsClient("&lt;your_api_key&gt;")</code><br><code>query = "best practices and guidelines for reopening schools during the COVID-19 pandemic"</code><br><br><code>query_vector = client.embeddings(query)</code><br><br><code>documents = [    "CDC - Operational Strategy for K-12 Schools through Phased Prevention", "UNICEF - Framework for reopening schools", "WHO - Considerations for school-related public health measures in the context of COVID-19", "OECD - Education responses to COVID-19: Embracing digital learning and online collaboration",    "World Bank - Reopening Schools: When, Where and How?"]</code><br><code>document_vectors = client.embeddings(documents)</code><br><br><code>scores = client.similarity(query_vector, document_vectors)</code><br><br><code>results = sorted(zip(documents, scores), key=lambda x: x[1], reverse=True)</code><br><br><code>for result in results:</code><br><code>    print(result[0], result[1])</code></p>
  194. <p> </p>
  195. <p class="ParagraphTextStyle">The output might look something like this:</p>
  196. <blockquote>
  197. <p class="ParagraphTextStyle">CDC - Operational Strategy for K-12 Schools through Phased Prevention 0.86</p>
  198. <p class="ParagraphTextStyle">UNICEF - Framework for reopening schools 0.84</p>
  199. <p class="ParagraphTextStyle">WHO - Considerations for school-related public health measures in the context of COVID-19 0.83</p>
  200. <p class="ParagraphTextStyle">World Bank - Reopening Schools: When, Where and How? 0.81</p>
  201. <p class="ParagraphTextStyle">OECD - Education responses to COVID-19: Embracing digital learning and online collaboration 0.76</p>
  202. </blockquote>
  203. <p class="ParagraphTextStyle">As you can see, the Embeddings model series can rank the documents based on their semantic relevance to the query. The higher the score, the more relevant the document is. You can then access the documents and read more about the topic. You can also use semantic search to find similar or related documents within a corpus or a database.</p>
  204. <h1 class="ParagraphTextStyle">Natural language to code translation</h1>
  205. <p class="ParagraphTextStyle">Another interesting task that can benefit from Azure OpenAI Service is natural language to code translation. You can use the service to translate natural language descriptions or instructions into executable code snippets in various programming languages. This can help you save time and effort, as well as learn new skills and techniques.</p>
  206. <p class="ParagraphTextStyle">For example, suppose you want to write a Python function that takes a list of numbers as input and returns the average of the numbers. You can use the Codex model series to generate a code snippet based on your natural language description. Here is an example of how you can do that using Python SDK:</p>
  207. <p><code>from azure.openai import CodexClient</code><br><code>client = CodexClient("&lt;your_api_key&gt;")</code><br><code>prompt = """Write a Python function that takes a list of numbers as input and returns the average of the numbers."""</code><br><code>response = client.completions(prompt, model="codex", stop="\n\n")</code><br><code>print(response.text)</code></p>
  208. <p>The output might look something like this:</p>
  209. <p><code>def average(numbers):</code><br><code>    # check if the input is a valid list of numbers</code></p>
  210. <p><code>    if not isinstance(numbers, list) or len(numbers) == 0 or not all(isinstance(n, (int, float)) for n in numbers):</code><br><code>        return None</code></p>
  211. <p><code>    # calculate the sum of the numbers</code><br><code>    total = 0</code><br><code>    for n in numbers:</code><br><code>        total += n  </code></p>
  212. <p><code>    # calculate and return the average</code><br><code>    return total / len(numbers)</code></p>
  213. <h1>Responsible AI</h1>
  214. <p>As we have seen, Azure OpenAI Service can enable many powerful and useful applications for government agencies and their citizens. However, it is also important to be aware of the potential risks and limitations of using generative models, and to follow some best practices and responsible AI principles when using the service.</p>
  215. <p>Some of the challenges and considerations when using Azure OpenAI Service are:</p>
  216. <p> - Factual errors: The models are trained on large and diverse datasets that may contain inaccurate or outdated information. Therefore, the generated text may not always be factually correct or consistent. You should always verify the accuracy and validity of the generated text before using it for any official purpose.</p>
  217. <p> - Plagiarism: The models may generate text that is similar or identical to existing sources, which may violate intellectual property rights or academic integrity. You should always check the originality and attribution of the generated text before using it for any public or academic purpose.</p>
  218. <p> - Bias: The models may reflect or amplify the biases or stereotypes that exist in the training data or in the society. Therefore, the generated text may not always be fair, inclusive, or respectful to different groups of people. You should always monitor and mitigate the potential bias or harm of the generated text before using it for any sensitive or impactful purpose.</p>
  219. <p> - Harmful content: The models may generate text that is inappropriate, offensive, or harmful to individuals or groups of people. This may include profanity, hate speech, violence, misinformation, etc. You should always filter and moderate the generated text before using it for any public or personal purpose.</p>
  220. <p>To help you address these challenges and considerations, Azure OpenAI Service provides some features and resources such as:</p>
  221. <p> - Content filtering: The service evaluates the prompts and completions against our content policy with automated systems. High severity content will be filtered. You can also specify your own content filter preferences in the request parameters.</p>
  222. <p> - Quality rating: The service provides a quality score for each completion, which indicates the confidence and coherence of the generated text. You can use this score to filter out low-quality completions or to request a new completion.</p>
  223. <p> - Responsible AI guidance: The service provides a set of guidelines and best practices for using generative models in a responsible and ethical way. You can find these resources in our <a href="https://learn.microsoft.com/en-us/azure/cognitive-services/openai/" target="_blank" rel="noopener noreferrer">documentation</a> and our <a href="https://www.microsoft.com/en-us/ai/responsible-ai" target="_blank" rel="noopener noreferrer">Responsible AI portal</a>.</p>
  224. <p>We encourage you to use Azure OpenAI Service in a responsible and ethical way. We also welcome your feedback and suggestions on how we can improve our service and our responsible AI practices.</p>
  225. <h1>Conclusion</h1>
  226. <p>In this blog post, we have shown you how to use Azure OpenAI Service to perform some common tasks that can benefit government agencies and their citizens. We have also discussed some best practices and responsible AI considerations when using generative models. We hope you find this blog post informative and engaging.</p>
  227. <p>If you want to learn more about Azure OpenAI Service, you can visit our <a href="https://learn.microsoft.com/en-us/azure/cognitive-services/openai/" target="_blank" rel="noopener noreferrer">documentation page</a> for more details and examples. You can also apply for access to Azure OpenAI Service within your Azure Portal.</p>
  228. <p>Thank you for your interest in Azure OpenAI Service and we hope you enjoy using it. If you have any feedback or questions, please feel free to contact your Microsoft representative.</p>
  229. <p> </p>
  230.            ]]>
  231.        </content>
  232.    </entry>
  233.    <entry>
  234.        <title>Azure is the home for your Java Applications</title>
  235.        <author>
  236.            <name>Mike Hacker</name>
  237.        </author>
  238.        <link href="https://blog.mikehacker.net/azure-is-the-home-for-your-java-applications/"/>
  239.        <id>https://blog.mikehacker.net/azure-is-the-home-for-your-java-applications/</id>
  240.        <media:content url="https://blog.mikehacker.net/media/posts/73/JavaOnAzure.png" medium="image" />
  241.            <category term="Training"/>
  242.            <category term="Articles"/>
  243.  
  244.        <updated>2023-05-31T10:03:20-04:00</updated>
  245.            <summary>
  246.                <![CDATA[
  247.                        <img src="https://blog.mikehacker.net/media/posts/73/JavaOnAzure.png" alt="Build or Migrate Java Apps with Azure" />
  248.                    Bruno Borges joins Scott Hanselman to talk about Java development with Microsoft. Like many of our customers, Microsoft is a Java shop with lots of systems that rely on Java and its ecosystem. We employ thousands of Java engineers, run millions of JVMs, and process&hellip;
  249.                ]]>
  250.            </summary>
  251.        <content type="html">
  252.            <![CDATA[
  253.                    <p><img src="https://blog.mikehacker.net/media/posts/73/JavaOnAzure.png" class="type:primaryImage" alt="Build or Migrate Java Apps with Azure" /></p>
  254.                <p>Bruno Borges joins Scott Hanselman to talk about Java development with Microsoft. Like many of our customers, Microsoft is a Java shop with lots of systems that rely on Java and its ecosystem. We employ thousands of Java engineers, run millions of JVMs, and process terabytes of data every day, to deliver the services everyone loves. We also built tools and services specifically designed for Java developers and applications.</p>
  255. <p>After watching the videos, <a href="https://blog.mikehacker.net/java-on-azure/" target="_blank" rel="noopener noreferrer">check out the other Java on Azure resources here</a>.</p>
  256. <p>Part 1</p>
  257. <div class="post__iframe"><iframe loading="lazy" width="560" height="315" src="https://www.youtube.com/embed/lCzcQ0Q5cSQ" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" allowfullscreen="allowfullscreen"></iframe></div>
  258. <p> </p>
  259. <p>Part 2</p>
  260. <div class="post__iframe"><iframe loading="lazy" width="560" height="315" src="https://www.youtube.com/embed/IyVneQO67zA" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" allowfullscreen="allowfullscreen"></iframe></div>
  261. <p> </p>
  262.            ]]>
  263.        </content>
  264.    </entry>
  265.    <entry>
  266.        <title>Migrate to Modernize</title>
  267.        <author>
  268.            <name>Mike Hacker</name>
  269.        </author>
  270.        <link href="https://blog.mikehacker.net/migrate-to-modernize/"/>
  271.        <id>https://blog.mikehacker.net/migrate-to-modernize/</id>
  272.        <media:content url="https://blog.mikehacker.net/media/posts/72/lf68lk9r.png" medium="image" />
  273.            <category term="Articles"/>
  274.  
  275.        <updated>2023-09-26T09:56:52-04:00</updated>
  276.            <summary>
  277.                <![CDATA[
  278.                        <img src="https://blog.mikehacker.net/media/posts/72/lf68lk9r.png" alt="" />
  279.                    Migrate to Modernize is an approach for application modernization that enables organizations to see immediate value while also addressing common modernization challenges. Modernizing an application means to pay back that technical debt and to enable the application to take advantage of modern platform services. Modern&hellip;
  280.                ]]>
  281.            </summary>
  282.        <content type="html">
  283.            <![CDATA[
  284.                    <p><img src="https://blog.mikehacker.net/media/posts/72/lf68lk9r.png" class="type:primaryImage" alt="" /></p>
  285.                <p>Migrate to Modernize is an approach for application modernization that enables organizations to see immediate value while also addressing common modernization challenges.</p>
  286. <p>Modernizing an application means to pay back that technical debt and to enable the application to take advantage of modern platform services. Modern platform services enables organizations to focus more on solving business challenges and provides more value by not having to focus on hardware, patching and server maintenance.</p>
  287. <p>The fastest way to modernize is to first migrate your applications to Azure. Once the application is in Azure you can begin to modernize parts of the solution by replacing virtual machines with platform services. For example, you can replace the SQL database VM with Azure SQL, that IIS server with Azure App Service, and modernize the applications identity to use Azure Active Directory for authentication.</p>
  288. <p><a href="https://www.linkedin.com/posts/mphacker_msftadvocate-azure-government-activity-7056263142070243328-a9sM?utm_source=share&amp;utm_medium=member_desktop" target="_blank" rel="noopener noreferrer">Here is a short video</a> that explains the Migrate to Modernize approach.</p>
  289. <p>Below are a few recommendations and things to consider with using the Migrate to Modernize approach:</p>
  290. <ul>
  291. <li>Quickly get started by modernizing the database first by utilizing Azure SQL Database, Azure SQL Managed Instance, MySQL, or PostgreSQL platform services.</li>
  292. <li>Migrate the application VMs to Azure and reconfigure the application to utilize the new hosted database service</li>
  293. <li>Establish policies that incentivize completing the full application modernization process within an acceptable timeframe.</li>
  294. <li>Developers should modernize the application to utilize modern authentication solutions such as Azure Active Directory and Azure AD B2C.</li>
  295. <li>Developers should upgrade the code to utilize the latest frameworks and libraries to help protect against security vulnerabilities. </li>
  296. <li>Architects and developers can work together to determine the best platform services to use for hosting the updated application. Options include services such as Azure Kubernetes Service, Azure Container Apps, Azure Red Hat OpenShift, and Azure App Service.</li>
  297. <li>Architects and developers can consider decomposing the application into microservices and APIs that can be hosted on container or serverless platforms.</li>
  298. <li>Architects and developers can begin to look for options to enhance their application with other platform as a service features such as Logic Apps, Service Bus, Redis Cache, Configuration Services, Functions.</li>
  299. </ul>
  300. <p>The key point is that you start with modernizing the database while migrating the application. From there you can begin to modernize components of the app while receiving the benefits of using database platform services and having access to a wide range of additional platform services for your application.</p>
  301. <p>To get started today, speak with your Microsoft Account Team for details on how they can assist you with your modernization journey.</p>
  302. <p> </p>
  303.            ]]>
  304.        </content>
  305.    </entry>
  306.    <entry>
  307.        <title>Logic App: Unable to retrieve record from Cosmos DB.</title>
  308.        <author>
  309.            <name>Mike Hacker</name>
  310.        </author>
  311.        <link href="https://blog.mikehacker.net/logic-app-unable-to-retrieve-record-from-cosmos-db/"/>
  312.        <id>https://blog.mikehacker.net/logic-app-unable-to-retrieve-record-from-cosmos-db/</id>
  313.        <media:content url="https://blog.mikehacker.net/media/posts/71/LogicApps-3.jpg" medium="image" />
  314.            <category term="Articles"/>
  315.  
  316.        <updated>2023-05-11T08:58:27-04:00</updated>
  317.            <summary>
  318.                <![CDATA[
  319.                        <img src="https://blog.mikehacker.net/media/posts/71/LogicApps-3.jpg" alt="Purple and blue artistic circles" />
  320.                    Recently while I was working on a customer demo I ran into a bit of an issue when trying to delete a record from a Cosmos DB using Logic Apps. I kept receiving an error indicating that the document id I was specifying didn't exist&hellip;
  321.                ]]>
  322.            </summary>
  323.        <content type="html">
  324.            <![CDATA[
  325.                    <p><img src="https://blog.mikehacker.net/media/posts/71/LogicApps-3.jpg" class="type:primaryImage" alt="Purple and blue artistic circles" /></p>
  326.                <p>Recently while I was working on a customer demo I ran into a bit of an issue when trying to delete a record from a Cosmos DB using Logic Apps.  I kept receiving an error indicating that the document id I was specifying didn't exist even though I could see it was in the database. I was also running into similar issues when trying to retrieve a specific document from the database.</p>
  327. <p>The Logic Apps actions I was using included the <em>Delete a document (V2) and Get a document (V2).  </em></p>
  328. <p>I searched through documentation and found nothing that seemed to give any clear indication as to what the error was. I did some searches using Bing and found other folks who were having similar challenges but I didn't run across any one specific way to fix it. Everyone seemed to just be guessing as to what the issue was. </p>
  329. <p>In those actions, there are required fields which include Cosmos DB account name, database ID, Collection ID and Document ID.  In most cases you will need to also add the parameter Partition key value in order for the delete or get actions to find the proper document.  In my database, the Document ID and Partition key values are the same. </p>
  330. <p>My Logic app is acting as a REST API to do basic CRUD (create, read, update and delete) operations.  When a client calls the REST API it passes in a value which is stored as the variable id, which represents the id of the document I wish to get or delete.  Originally I was just taking that id variable and placing it in both the Document ID and partition key value fields in the Logic Apps action. As logical as that sounds, this did not work and I kept getting errors related to the document not being found.</p>
  331. <p>So what ultimately fixed the issue?  The Partition key value needs to be surrounded by double quotes.  That's it.  Once I placed double quotes around this field, my Logic Apps started functioning correctly.</p>
  332. <p>Hopefully this little nugget of information comes in handy for someone else who is running into similar challenges with the Cosmos DB actions for Logic Apps.</p>
  333. <p> </p>
  334. <p> </p>
  335.            ]]>
  336.        </content>
  337.    </entry>
  338.    <entry>
  339.        <title>How to choose between Azure Kubernetes Service or Azure Red Hat OpenShift</title>
  340.        <author>
  341.            <name>Mike Hacker</name>
  342.        </author>
  343.        <link href="https://blog.mikehacker.net/how-to-choose-between-azure-kubernetes-service-or-azure-red-hat-openshift/"/>
  344.        <id>https://blog.mikehacker.net/how-to-choose-between-azure-kubernetes-service-or-azure-red-hat-openshift/</id>
  345.        <media:content url="https://blog.mikehacker.net/media/posts/70/OIG.jpg" medium="image" />
  346.            <category term="Articles"/>
  347.  
  348.        <updated>2023-04-21T14:41:49-04:00</updated>
  349.            <summary>
  350.                <![CDATA[
  351.                        <img src="https://blog.mikehacker.net/media/posts/70/OIG.jpg" alt="Man trying to make a decision" />
  352.                    Note: Portions of this blog post were written using Bing Chat. Azure Kubernetes Service (AKS) and Azure Red Hat OpenShift (ARO) are two options for deploying and managing containerized applications on Azure. Both services are based on Kubernetes, the open-source platform for orchestrating containers, but&hellip;
  353.                ]]>
  354.            </summary>
  355.        <content type="html">
  356.            <![CDATA[
  357.                    <p><img src="https://blog.mikehacker.net/media/posts/70/OIG.jpg" class="type:primaryImage" alt="Man trying to make a decision" /></p>
  358.                <blockquote>
  359. <p><em>Note: Portions of this blog post were written using Bing Chat.</em></p>
  360. </blockquote>
  361. <p>Azure Kubernetes Service (AKS) and Azure Red Hat OpenShift (ARO) are two options for deploying and managing containerized applications on Azure. Both services are based on Kubernetes, the open-source platform for orchestrating containers, but they have some differences and trade-offs that you should consider before choosing one over the other.</p>
  362. <p>AKS is a fully managed Kubernetes service that offers serverless Kubernetes, an integrated continuous integration and continuous delivery (CI/CD) experience, and enterprise-grade security and governance. AKS is optimized for running general purpose containers, especially for applications that span many microservices deployed in containers. AKS supports Kubernetes-style apps and microservices with features like service discovery and traffic splitting. AKS also enables event-driven application architectures by supporting scale based on traffic and pulling from event sources like queues, including scale to zero. AKS does not provide direct access to the underlying Kubernetes control plane, which means you have less control and customization options over your cluster.</p>
  363. <p>ARO is a fully managed OpenShift service that provides a consistent hybrid cloud foundation for building and scaling containerized applications. OpenShift is a distribution of Kubernetes that adds additional features and integrations to enhance the developer experience and enterprise readiness of Kubernetes. OpenShift provides a web console, an integrated image registry, a built-in CI/CD pipeline, a source-to-image tool, a service catalog, and many other tools to help developers build, deploy, and manage applications. OpenShift also offers more security features than AKS, such as role-based access control, security context constraints, network policies, and encryption. ARO provides direct access to the underlying Kubernetes APIs and control plane, which gives you more flexibility and customization options over your cluster.</p>
  364. <p>The pros and cons of each service depend on your specific use case and requirements. Some general considerations are:</p>
  365. <p>- If you want a fully managed Kubernetes experience with minimal configuration and maintenance, AKS may be a good choice.</p>
  366. <p>- If you want a more comprehensive platform that includes additional tools and integrations for developing and deploying containerized applications, ARO may be a better option.</p>
  367. <p>- If you need direct access to the Kubernetes control plane, or if you want to use OpenShift-specific features or extensions, ARO is the only option.</p>
  368. <p>- If you need to scale your applications based on events or traffic, or if you want to leverage serverless containers, AKS has more support for these scenarios than ARO.</p>
  369. <p>- If you are concerned about security and compliance, ARO may offer more features and capabilities than AKS to meet your needs.</p>
  370. <p>Ultimately, the best way to choose between AKS and ARO is to try them out for yourself and see which one suits your needs better. You can get started with AKS using the quickstarts or with ARO using the tutorials.</p>
  371.            ]]>
  372.        </content>
  373.    </entry>
  374.    <entry>
  375.        <title>Microsoft Build | May 23-24, 2023</title>
  376.        <author>
  377.            <name>Mike Hacker</name>
  378.        </author>
  379.        <link href="https://blog.mikehacker.net/microsoft-build-or-may-23-24-2023/"/>
  380.        <id>https://blog.mikehacker.net/microsoft-build-or-may-23-24-2023/</id>
  381.        <media:content url="https://blog.mikehacker.net/media/posts/69/8659ae4d-4633-4d2d-aeca-88e1b6f3e31a.png" medium="image" />
  382.            <category term="Events"/>
  383.  
  384.        <updated>2023-05-25T09:15:52-04:00</updated>
  385.            <summary>
  386.                <![CDATA[
  387.                        <img src="https://blog.mikehacker.net/media/posts/69/8659ae4d-4633-4d2d-aeca-88e1b6f3e31a.png" alt="Microsoft Build Logo" />
  388.                    Are you a developer or tech enthusiast looking to stay ahead of the curve? Then don't miss out on the opportunity to attend Microsoft Build on May 23-24! This annual conference is packed with informative sessions and hands-on workshops led by industry experts. You'll have&hellip;
  389.                ]]>
  390.            </summary>
  391.        <content type="html">
  392.            <![CDATA[
  393.                    <p><img src="https://blog.mikehacker.net/media/posts/69/8659ae4d-4633-4d2d-aeca-88e1b6f3e31a.png" class="type:primaryImage" alt="Microsoft Build Logo" /></p>
  394.                <p>Are you a developer or tech enthusiast looking to stay ahead of the curve? Then don't miss out on the opportunity to attend Microsoft Build on May 23-24! This annual conference is packed with informative sessions and hands-on workshops led by industry experts. You'll have the chance to learn about the latest technologies and trends in software development and connect with other professionals in your field.</p>
  395. <p>Don't wait - <a href="https://build.microsoft.com/en-US/home">register now</a> and join us for an unforgettable experience!</p>
  396.            ]]>
  397.        </content>
  398.    </entry>
  399. </feed>
  400.  

If you would like to create a banner that links to this page (i.e. this validation result), do the following:

  1. Download the "valid Atom 1.0" banner.

  2. Upload the image to your own server. (This step is important. Please do not link directly to the image on this server.)

  3. Add this HTML to your page (change the image src attribute if necessary):

If you would like to create a text link instead, here is the URL you can use:

http://www.feedvalidator.org/check.cgi?url=https%3A//blog.mikehacker.net/feed.xml

Copyright © 2002-9 Sam Ruby, Mark Pilgrim, Joseph Walton, and Phil Ringnalda