本页还没有译文
本页 15 段还没译成简体中文,下面显示的是英文原文。Prompt Composability
还没翻译译自英文(langfuse.com)本页 15 段都还没译
As you create more prompts, you will often find yourself using the same snippets of text or instructions in multiple prompts. To avoid duplication, you can compose prompts by referencing other prompts.
Why Use Composed Prompts?
- Create modular prompt components that can be reused across multiple prompts
- Maintain common instructions, examples, or context in a single place
- Update dependent prompts automatically when base prompts change
Get started
When creating the prompt via the Langfuse UI, you can use the Add prompt reference button to insert a prompt reference into your prompt.
You can reference other text prompts in your prompts the following format:
@@@langfusePrompt:name=PromptName|version=1@@@You can also use a label instead of a specific version for dynamic resolution:
@@@langfusePrompt:name=PromptName|label=production@@@Not exactly what you need? Consider these similar features:
- Variables for inserting dynamic text into prompts
- Message placeholders for inserting arrays of complete messages instead of strings
Or related FAQ pages:
AI 翻译查看英文原文