nat.tool.chat_completion#
Simple Completion Function for NAT
This module provides a simple completion function that can handle natural language queries and perform basic text completion tasks.
Classes#
Configuration for the Chat Completion Function. |
Functions#
|
Registers a chat completion function that can handle natural language queries. |
Module Contents#
- class ChatCompletionConfig(/, **data: Any)#
Bases:
nat.data_models.function.FunctionBaseConfig
Configuration for the Chat Completion Function.
Create a new model by parsing and validating input data from keyword arguments.
Raises [
ValidationError
][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.self
is explicitly positional-only to allowself
as a field name.- llm_name: nat.data_models.component_ref.LLMRef = None#
- async register_chat_completion(
- config: ChatCompletionConfig,
- builder: nat.builder.builder.Builder,
Registers a chat completion function that can handle natural language queries.