.NET Developer's cheat sheet for prompt engineering
Here is my collection of links to help me develop the perfect prompts
1-hour video course for a quick jump
A small and free course from Isa Fulford and Andrew Ng that allows you to master the basics of prompt engineering quickly.
ChatGPT Prompt Engineering For Developers
A course that provides an extensive amount of information and specifics
OpenAI services
Semantic Kernel
The nuget from Microsoft for easy integration into your project
The Semantic Kernel is an easy-to-use SDK that integrates AI Large Language Models (LLMs) with conventional programming languages like C# and Python. With SK's versatile programming model, you can use natural language semantic functions, traditional native code functions, and embeddings-based memory.
It supports: text-ada-001, text-curie-001, text-davinci-002, gpt-35-turbo, text-davinci-003, code-davinci-002, text-similarity-ada-001, text-similarity-curie-001, text-embedding-ada-002 and dallE
Additionally, SK has built-in features such as prompt templating, function chaining, vectorized memory, and intelligent planning capabilities to make your programming experience even more efficient and productive.
TypeChat
TypeChat is a library that simplifies the creation of natural language interfaces using types. Traditionally, these interfaces were built with complex decision trees, but now, large language models (LLMs) can interpret user input and determine intent. However, challenges like response safety, structured replies, and validity arise. While prompt engineering addresses these, it isn't straightforward. TypeChat offers a solution by using schema engineering.
Example
Input
I need to get my tires changed from 12:00 to 2:00 pm on Friday March 15, 2024
Output
{
"actions": [
{
"actionType": "add event",
"event": {
"day": "Friday March 15, 2024",
"timeRange": {
"startTime": "12:00 pm",
"endTime": "2:00 pm"
},
"description": "get my tires changed"
}
}
]
}
Vector database
Once an LLM is trained, its knowledge is fixed and becomes stateless. This means it cannot learn from new data unless fine-tuned with the additional information. However, once the fine-tuning is completed, the LLM becomes stateless once again. To overcome this limitation, vector databases can be used to give LLMs state as they can be easily updated with new information and used to extend the knowledge of the LLMs.
Subscribe to my newsletter
Read articles from Pavlo Datsiuk directly inside your inbox. Subscribe to the newsletter, and don't miss out.
Written by
Pavlo Datsiuk
Pavlo Datsiuk
๐