Skip to content

Instantly share code, notes, and snippets.

View geffzhang's full-sized avatar

geffzhang geffzhang

View GitHub Profile
private static CurrencyExchange GetCurrencyRate(DateTime date)
{
var key = date.Date.ToString("yyyy-MM-dd");
var cachedExchange = _cache.GetAsync<CurrencyExchange>(key).Result;
if (cachedExchange.HasValue)
{
Console.WriteLine("Found in cache");
return cachedExchange.Value;

Tailwind Traders Deploy to Azure Buttons

Instructions

Standalone

This method deploys the Tailwind Traders website with a SQL DB and Cosmos DB, and does not depend on backend microservices.

  • Select standalone
  • Ensure you select a region where you're allowed to deploy SQL Databases and App Services, each of those services have restrictions for internal subs.
@geffzhang
geffzhang / ConversationalRetrievalPlugin.cs
Created September 9, 2023 01:05 — forked from alexminza/ConversationalRetrievalPlugin.cs
Semantic Kernel ConversationalRetrievalPlugin
using System.ComponentModel;
using System.Text;
using Microsoft.Extensions.Logging;
using Microsoft.SemanticKernel;
using Microsoft.SemanticKernel.Orchestration;
using Microsoft.SemanticKernel.SkillDefinition;
using Microsoft.SemanticKernel.AI.ChatCompletion;
using Microsoft.SemanticKernel.Memory;
class ConversationalRetrievalPlugin