method

package
v1.2.3 Latest Latest
Warning

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

Go to latest
Published: Jun 6, 2025 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var MimeTypes = map[string]string{}/* 733 elements not displayed */

Functions

This section is empty.

Types

type Method

type Method struct {
	// contains filtered or unexported fields
}

func NewMethod

func NewMethod(page *playwright.Page) *Method

func (*Method) AIStudioTokens

func (m *Method) AIStudioTokens(systemTokens, inputTokens, endTokens string) (uint64, uint64, uint64, error)

func (*Method) AlwaysTrue

func (m *Method) AlwaysTrue() bool

func (*Method) BuildPrompt

func (m *Method) BuildPrompt(requestJson string, includeSystem bool) (string, error)

func (*Method) ChooseModelByName

func (m *Method) ChooseModelByName(name, modelNameSelector string, modelCategoryContainerSelector string) error

func (*Method) Click

func (m *Method) Click(elementSelector string, timeout float64) error

func (*Method) ConvertReturnToParagraphs added in v1.1.0

func (m *Method) ConvertReturnToParagraphs(input string) string

func (*Method) Eq

func (m *Method) Eq(a, b int) bool

func (*Method) GetDataFromProxy

func (m *Method) GetDataFromProxy(proxy *proxy.Proxy, channel chan *model.ProxyResponse) (bool, error)

func (*Method) GetElement

func (m *Method) GetElement(elementSelector string) (playwright.Locator, error)

func (*Method) GetElementAttribute

func (m *Method) GetElementAttribute(locator playwright.Locator, attributeName string) (string, error)

func (*Method) GetElements

func (m *Method) GetElements(elementSelector string) ([]playwright.Locator, error)

func (*Method) GetInnerText

func (m *Method) GetInnerText(elementSelector string) (string, error)

func (*Method) GetLocalStorage

func (m *Method) GetLocalStorage(name string) (any, error)

func (*Method) Gt

func (m *Method) Gt(a, b int) bool

func (*Method) Gte

func (m *Method) Gte(a, b int) bool

func (*Method) ImagePrompt

func (m *Method) ImagePrompt(requestJson string) (bool, []string, error)

func (*Method) InInnerHTML added in v1.1.0

func (m *Method) InInnerHTML(selector, htmlContent string) error

func (*Method) Input

func (m *Method) Input(elementSelector, text string, timeout float64) error

func (*Method) Int

func (m *Method) Int(i int) (int, error)

func (*Method) IsDisabled

func (*Method) IsDisabled(element playwright.Locator) (bool, error)

func (*Method) IsEqual

func (m *Method) IsEqual(a, b int64) bool

func (*Method) IsVisible

func (m *Method) IsVisible(element playwright.Locator) (bool, error)

func (*Method) Len

func (m *Method) Len(arr any) int

func (*Method) Lt

func (m *Method) Lt(a, b int) bool

func (*Method) Lte

func (m *Method) Lte(a, b int) bool

func (*Method) MaxTokens

func (m *Method) MaxTokens(requestJson string) (bool, string, error)

func (*Method) Model

func (m *Method) Model(requestJson string) (bool, string)

func (*Method) MouseClick

func (m *Method) MouseClick(x, y float64) error

func (*Method) PressSequentially added in v1.1.0

func (m *Method) PressSequentially(elementSelector, text string, timeout float64) error

func (*Method) PromptCount

func (m *Method) PromptCount(requestJson string) (systemPromptCount int, assistantPromptCount int, userPromptCount int, toolPromptCount int, error error)

func (*Method) SetLocalStorage

func (m *Method) SetLocalStorage(name, value string) error

func (*Method) SleepMilliseconds

func (m *Method) SleepMilliseconds(milliseconds int) bool

func (*Method) StartSniffing

func (m *Method) StartSniffing(proxy *proxy.Proxy)

func (*Method) StopSequence

func (m *Method) StopSequence(requestJson string) (bool, string, error)

func (*Method) StopSniffing

func (m *Method) StopSniffing(proxy *proxy.Proxy)

func (*Method) StringEqual

func (m *Method) StringEqual(str1, str2 string) bool

func (*Method) SystemPrompt

func (m *Method) SystemPrompt(requestJson string) (bool, string, error)

func (*Method) Temperature

func (m *Method) Temperature(requestJson string) (bool, string, error)

func (*Method) ToolPrompt

func (m *Method) ToolPrompt(requestJson string) (bool, string, error)

func (*Method) Tools

func (m *Method) Tools(requestJson string) (bool, string, error)

func (*Method) TopP

func (m *Method) TopP(requestJson string) (bool, string, error)

func (*Method) Type added in v1.1.0

func (m *Method) Type(elementSelector, text string, timeout float64) error

func (*Method) UploadFiles

func (m *Method) UploadFiles(runner any, base64edImage []string) error

func (*Method) UserPrompt

func (m *Method) UserPrompt(requestJson string) (bool, string, error)

func (*Method) Value

func (m *Method) Value(elementSelector string, timeout float64) (string, error)

Jump to

Keyboard shortcuts

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