Skip to content

Home > llm-ops

llm-ops package

Classes

ClassDescription
AgentPromptTemplate
BaseAgent
ChainChain 类用于llm类的格式化输出。
FunctionChain
LLM_OPS_CONFIGLLM_OPS_CONFIG 是用于配置操作的类,它包含了与OpenAI、Helicone和Milvus相关的配置信息。
LLMLLM类代表一个与LLM API进行交互的客户端。
milvusVectorDB
PipeRegistry扩展原始的PipeRegistry类
PolishPromptTemplate
TypeScriptChainCreates an object that can translate natural language requests into JSON objects of the given type. The specified type argument T must be the same type as typeName in the given schema. The function creates a TypeChatJsonValidator<T> and stores it in the validator property of the returned instance.

Abstract Classes

Abstract ClassDescription
BasePromptTemplate

Functions

FunctionDescription
createJsonValidator(schema, typeName)Returns a JSON validator for a given TypeScript schema. Validation is performed by an in-memory instance of the TypeScript compiler. The specified type argument T must be the same type as typeName in the given schema.
createMessage(params)
error(message)Returns an Error object.
getData(result)Obtains the value associated with a successful Result<T> or throws an exception if the result is an error.
success(data)Returns a Success<T> object.

Interfaces

InterfaceDescription
AgentPromptTemplateSchema
BaseAgentCallSchema
chainCallSchemaChain类的call方法的参数数据结构。
chainSchemaChain 构造函数的参数数据结构。
ChatSchema聊天参数接口
createLLMSchema创建LLM的参数接口
createMessageSchema
Error_2An object representing an operation that failed for the reason given in message.
EvaluateItemSchema
FunctionCallOptionFunctionCall的接口
FunctionCallSchema
FunctionInterface
MemoryPromptTemplateSchema
MermaidCallSchema
milvusVectorDBCreateSchema
milvusVectorDBIndexSchema
milvusVectorDBPromptTemplateSchema
milvusVectorDBQuerySchema
milvusVectorDBSchema
milvusVectorDBSearchSchema
milvusVectorDBUploadSchema
milvusVectorDBUpsertSchema
MultiPromptSchema多重提示模板数据结构。
polishPromptTemplateSchema
PromptsSchema主要的模板数据结构。
ReflectionPromptTemplateSchema
structSchemacall 方法的struct参数的数据结构。
SuccessAn object representing a successful operation with a result of type T.
TeacherEvaluateSchema
TypeChatJsonValidatorRepresents an object that can validate JSON strings according to a given TypeScript schema.
TypeScriptChainCallSchemaRepresents an object that can translate natural language requests in JSON objects of the given type.

Variables

VariableDescription
formatPromptTemplate

格式化提示模板函数。

此函数的主要目的是为了从提供的prompts对象中提取出一个格式化的提示模板。 这可以是一个单一的模板,也可以是一个模板数组。

genMermaid
replaceContentWithSequence

Type Aliases

Type AliasDescription
chatCompletionTypeOpenAI聊天完成类型
chatParamsTypeOpenAI聊天参数类型
communicationStyleType
function_callTypefunction_call类型
functionsTypeFunctionInterface类型数组
InputValues
languageType
levelType
llmTypeLLM类型定义为OpenAI类型
messageFunctionCallTypeOpenAI聊天完成消息中的FunctionCall类型
messagesTypeOpenAI聊天请求消息的类型数组
messageType单一的OpenAI聊天请求消息类型
reasoningType
resEmbeddingTypeOpenAI创建嵌入响应类型
resMessagesTypeOpenAI聊天完成的消息数组类型
resModerationTypeOpenAI内容审查响应类型
ResultAn object representing a successful or failed operation of type T.
toneStyleType

Released under the MIT License.