model

package
v0.0.0-...-1c978d5 Latest Latest
Warning

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

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

Documentation

Overview

Package model 是模型协议:按 provider 注册工厂、按配置构造 ChatModel。 与 session/memory/prompt/source/channel 的注册表机制同构;官方实现见 impl/model/*(minimax/openai/zhipu),空导入即注册。

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Build

func Build(ctx context.Context, provider string, conf map[string]any) (einomodel.ToolCallingChatModel, error)

Build 按 provider 实例化模型。

func Register

func Register(provider string, f Factory)

Register 注册模型工厂,重复注册会 panic(视为编程错误)。

Types

type Factory

type Factory func(ctx context.Context, conf map[string]any) (einomodel.ToolCallingChatModel, error)

Factory 按配置构造 ChatModel。

Jump to

Keyboard shortcuts

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