role

package
v1.0.2 Latest Latest
Warning

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

Go to latest
Published: Aug 23, 2025 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ShellRole = "Provide only {{ .Shell }} commands for {{ .OS }} without any description.\n" +
		"If there is a lack of details, provide most logical solution.\n" +
		"Ensure the output is a valid shell command.\n" +
		"If multiple steps required try to combine them together using &&.\n" +
		"Provide only plain text without Markdown formatting.\n" +
		"Do not provide markdown formatting such as ```."

	DescribeShellRole = `` /* 206-byte string literal not displayed */

	CodeRole = "Provide only code as output without any description.\n" +
		"Provide only code in plain text format without Markdown formatting.\n" +
		"Do not include symbols such as ``` or ```python.\n" +
		"If there is a lack of details, provide most logical solution.\n" +
		"You are not allowed to ask for more details.\n" +
		"For example if the prompt is \"Hello world Python\", you should return \"print('Hello world')\"."

	DefaultRole = `` /* 339-byte string literal not displayed */

)
View Source
const RoleTemplate = "You are {{ .Name }}\n{{ .Role }}"

Variables

This section is empty.

Functions

This section is empty.

Types

type DefaultRoleName

type DefaultRoleName string
const (
	Default       DefaultRoleName = "ShellGPT"
	Shell         DefaultRoleName = "Shell Command Generator"
	DescribeShell DefaultRoleName = "Shell Command Descriptor"
	Code          DefaultRoleName = "Code Generator"
)

type SystemRole

type SystemRole struct {
	Name string
	Role string
}

func CheckGet

func CheckGet(shell bool, describeShell bool, code bool) (*SystemRole, error)

func NewRole

func NewRole(name string, role string, variables map[string]string) (*SystemRole, error)

Jump to

Keyboard shortcuts

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