prompts

package
v0.1.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 24, 2025 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type PromptTemplates

type PromptTemplates struct {
	AutoStrategyPlanner            string `yaml:"auto_strategy_planner"`
	SQLConstraintsForPlanner       string `yaml:"sql_constraints_for_planner"`
	BaseStrategySQLConstraints     string `yaml:"base_strategy_sql_constraints"`
	BaseStrategyToolParamsGuidance string `yaml:"base_strategy_tool_params_guidance"`
}

PromptTemplates 保存从YAML文件中加载的所有提示词模板

func GetPrompts

func GetPrompts() *PromptTemplates

GetPrompts 返回已加载的提示词模板。 如果模板尚未加载,它会使用嵌入的默认配置进行加载。

func LoadPrompts

func LoadPrompts(filePath string) (*PromptTemplates, error)

LoadPrompts 从指定的YAML文件加载提示词模板。 如果filePath为空,则加载嵌入的默认模板。 这个函数是线程安全的,且只会执行一次。

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL