genaiutils

package
v1.0.178 Latest Latest
Warning

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

Go to latest
Published: Nov 11, 2026 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ConvertJResponseFormatJSONSchema added in v0.13.68

func ConvertJResponseFormatJSONSchema(jschema *schema.ResponseFormatJSONSchema) (*genai.Schema, error)

ConvertJSONSchemaDefinition converts a json_schema response format to a genai.Schema.

func ConvertJSONSchemaDefinition

func ConvertJSONSchemaDefinition(jschema *jsonschema.Schema) (*genai.Schema, error)

ConvertJSONSchemaDefinition converts a jsonschema.Definition to a genai.Schema.

func ConvertJSONSchemaType

func ConvertJSONSchemaType(dt string) genai.Type

ConvertJSONSchemaType converts a jsonschema.DataType to a genai.Type.

func ConvertToolSchemaType

func ConvertToolSchemaType(ty string) genai.Type

ConvertToolSchemaType converts a tool's schema type from its langchaingo representation (string) to a genai enum.

func ConvertTools

func ConvertTools(tools []llms.Tool) ([]*genai.Tool, error)

ConvertTools converts from a list of langchaingo tools to a list of genai tools.

func Float32Ptr added in v0.13.68

func Float32Ptr(f float32) *float32

func Int32Ptr added in v0.13.68

func Int32Ptr(i int32) *int32

func StringPtr added in v0.13.68

func StringPtr(s string) *string

Types

This section is empty.

Jump to

Keyboard shortcuts

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