Installation
How to install and set up Prompt Manager
Installation
Prompt Manager is designed as a monorepo with multiple packages. You can install only the packages you need.
Prerequisites
- Bun 1.0 or later (recommended) or Node.js 18+
- TypeScript 5.0 or later (for TypeScript projects)
Core Package
The core package is required for all installations:
bun add @prompt-manager/coreStorage Adapters
Choose one or more storage adapters based on your needs:
Memory Storage
Best for development and testing:
bun add @prompt-manager/storage-memorySQLite Storage
For persistent file-based storage:
bun add @prompt-manager/storage-sqlitePostgreSQL Storage
For PostgreSQL databases:
bun add @prompt-manager/storage-postgresTemplate Engines
Choose a template engine:
Simple Template
Basic string interpolation:
bun add @prompt-manager/template-simpleHandlebars Template
Full Handlebars support with helpers:
bun add @prompt-manager/template-handlebarsCache Adapters
Optional caching for improved performance:
Memory Cache
bun add @prompt-manager/cache-memoryRedis Cache
For distributed Redis caching:
bun add @prompt-manager/cache-redisCloudflare KV Cache
For Cloudflare Workers and edge computing:
bun add @prompt-manager/cache-cloudflareExample Setup
Here's a complete setup with recommended packages:
bun add @prompt-manager/core \
@prompt-manager/storage-sqlite \
@prompt-manager/template-handlebars \
@prompt-manager/cache-memoryVerification
Verify your installation:
import { PromptManager } from '@prompt-manager/core';
console.log('Prompt Manager installed successfully!');