UNPKG

prompt-version-manager

Version:

Centralized prompt management system for Human Behavior AI agents

73 lines 2.03 kB
/** * Git-like branch and checkout operations for PVM TypeScript. */ export interface BranchInfo { name: string; commitHash: string; commitMessage?: string; commitAuthor?: string; commitTimestamp?: Date; isCurrent: boolean; } export declare class BranchManager { private storage; private repoPath; constructor(repoPath?: string); /** * Create a new branch. */ createBranch(branchName: string, startPoint?: string, force?: boolean): Promise<string>; /** * Delete a branch. */ deleteBranch(branchName: string, force?: boolean): Promise<void>; /** * List all branches. */ listBranches(): Promise<Record<string, string>>; /** * Get the name of the current branch. */ getCurrentBranch(): Promise<string | null>; /** * Checkout a branch or commit. */ checkout(target: string, create?: boolean, force?: boolean): Promise<string>; /** * Merge a branch into the current branch. */ merge(sourceBranch: string, message?: string, noFf?: boolean, author?: string, strategy?: string): Promise<string | null>; /** * Get detailed information about a branch. */ getBranchInfo(branchName: string): Promise<BranchInfo>; /** * Check if current directory is a PVM repository. */ private isRepo; /** * Validate branch name according to Git rules. */ private isValidBranchName; /** * Get all staged prompts (Python-compatible approach). */ private getStagedPrompts; /** * Clear the staging area (Python-compatible approach). */ private clearStaging; /** * Check if there are uncommitted changes in the staging area. */ private hasUncommittedChanges; /** * Check if ancestor_hash is an ancestor of descendant_hash. */ private isAncestor; /** * Close the branch manager and underlying storage. */ close(): Promise<void>; } //# sourceMappingURL=branches.d.ts.map