microsoft/prompt-engine
A TypeScript NPM library for creating and maintaining structured prompts for Large Language Models.

Velocity · 7d
+1.9
★ / day
Trend
→steady
star history
This repository provides an NPM utility library that helps developers build prompts for LLMs through reusable patterns. It includes classes like PromptEngine, CodeEngine, and ChatEngine that compose prompts from descriptions, input-output examples, and conversation context to guide model behavior. The library codifies few-shot prompting techniques and handles the complexity of managing stateful conversation history when working with stateless LLM APIs.