@promptbook/templates
Version:
Promptbook: Run AI apps in plain human language across multiple models and platforms
47 lines (46 loc) • 1.77 kB
TypeScript
import { BaseCommitmentDefinition } from '../_base/BaseCommitmentDefinition';
import type { AgentModelRequirements } from '../_misc/AgentModelRequirements';
/**
* PERSONA commitment definition
*
* The PERSONA commitment modifies the agent's personality and character in the system message.
* It defines who the agent is, their background, expertise, and personality traits.
*
* Key features:
* - Multiple PERSONA commitments are automatically merged into one
* - Content is placed at the beginning of the system message
* - Original content with comments is preserved in metadata.PERSONA
* - Comments (# PERSONA) are removed from the final system message
*
* Example usage in agent source:
*
* ```book
* PERSONA You are a helpful programming assistant with expertise in TypeScript and React
* PERSONA You have deep knowledge of modern web development practices
* ```
*
* The above will be merged into a single persona section at the beginning of the system message.
*
* @private [🪔] Maybe export the commitments through some package
*/
export declare class PersonaCommitmentDefinition extends BaseCommitmentDefinition<'PERSONA'> {
constructor();
/**
* Short one-line description of PERSONA.
*/
get description(): string;
/**
* Markdown documentation for PERSONA commitment.
*/
get documentation(): string;
applyToAgentModelRequirements(requirements: AgentModelRequirements, content: string): AgentModelRequirements;
}
/**
* Singleton instance of the PERSONA commitment definition
*
* @private [🪔] Maybe export the commitments through some package
*/
export declare const PersonaCommitment: PersonaCommitmentDefinition;
/**
* Note: [💞] Ignore a discrepancy between file name and entity name
*/