prompts

package
v0.0.0-...-962b40b Latest Latest
Warning

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

Go to latest
Published: May 14, 2024 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

View Source
const CombineTemplate = `Combine these summaries and reply in zh-CN Language: 


"{{ .Context }}"`
View Source
const KeyWordsTemplate = `Extract keywords from the following, separated by comma and reply in zh-CN Language:


"{{ .Context }}"


KEYWORDS: `
View Source
const QuestionTemplate = `` /* 318-byte string literal not displayed */
View Source
const QuestionTemplateEN = `` /* 242-byte string literal not displayed */
View Source
const SummaryTemplate = `Write a concise summary of the following and reply in zh-CN Language.:


"{{ .Context }}"


CONCISE SUMMARY: `
View Source
const WeChatConclusionTemplate = `请根据以下每天发生的事情,总结出这一段时间里发生的事情。

聊天记录:
{{ .Context }}
`
View Source
const WeChatTemplate = `` /* 302-byte string literal not displayed */

Variables

This section is empty.

Functions

This section is empty.

Types

type CombinePrompt

type CombinePrompt struct {
	Context string
	// contains filtered or unexported fields
}

func (*CombinePrompt) String

func (p *CombinePrompt) String(promptContext map[string]string) (string, error)

type KeywordsPrompt

type KeywordsPrompt struct {
	Context string
	// contains filtered or unexported fields
}

func (*KeywordsPrompt) String

func (p *KeywordsPrompt) String(promptContext map[string]string) (string, error)

type PromptTemplate

type PromptTemplate interface {
	String(promptContext map[string]string) (string, error)
}

func NewCombinePrompt

func NewCombinePrompt(t string) PromptTemplate

func NewKeywordsPrompt

func NewKeywordsPrompt(t string) PromptTemplate

func NewQuestionPrompt

func NewQuestionPrompt(t string) PromptTemplate

func NewSummaryPrompt

func NewSummaryPrompt(t string) PromptTemplate

func NewWeChatConclusionPrompt

func NewWeChatConclusionPrompt(t string) PromptTemplate

func NewWeChatPrompt

func NewWeChatPrompt(t string) PromptTemplate

type QuestionPrompt

type QuestionPrompt struct {
	Context  string
	Question string
	// contains filtered or unexported fields
}

func (*QuestionPrompt) String

func (p *QuestionPrompt) String(promptContext map[string]string) (string, error)

type SummaryPrompt

type SummaryPrompt struct {
	Context string
	// contains filtered or unexported fields
}

func (*SummaryPrompt) String

func (p *SummaryPrompt) String(promptContext map[string]string) (string, error)

type WeChatConclusionPrompt

type WeChatConclusionPrompt struct {
	Context string
	// contains filtered or unexported fields
}

func (*WeChatConclusionPrompt) String

func (w *WeChatConclusionPrompt) String(promptContext map[string]string) (string, error)

type WeChatPrompt

type WeChatPrompt struct {
	Context string
	// contains filtered or unexported fields
}

func (*WeChatPrompt) String

func (w *WeChatPrompt) String(promptContext map[string]string) (string, error)

Jump to

Keyboard shortcuts

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