AS AgentScopeAPI 手册 / API Reference

OllamaChatModelBuilderCustomizer

@FunctionalInterface public interface OllamaChatModelBuilderCustomizer extends Consumer<OllamaChatModel.Builder>
源码Source io/agentscope/spring/boot/ollama/OllamaChatModelBuilderCustomizer.java:33–52

定义 Ollama 聊天模型构建器 Customizer契约的接口。位于 io.agentscope.spring.boot.ollama 包,实现 Consumer<OllamaChatModel.Builder>。核心成员包括 customize、accept。

Customizer for OllamaChatModel.Builder.

Example usage:

` @Bean
public OllamaChatModelBuilderCustomizer ollamaChatModelBuilderCustomizer() {
return builder -> builder.baseUrl("http://ollama.example.com:11434");
}
`

方法摘要Method Summary

方法Method说明Description
public void customize(OllamaChatModel.Builder builder)
设置该参数。
Customize the `OllamaChatModel.Builder`.
default public void accept(OllamaChatModel.Builder builder)
default
设置该参数。
Accept and invoke the given builder.

方法详情Method Detail

customize

public void customize(OllamaChatModel.Builder builder)

设置该参数。

Customize the OllamaChatModel.Builder.

参数Parameters
名称Name类型Type说明Description
builderOllamaChatModel.Builder构建器(类型 `OllamaChatModel.Builder`)。the builder to customize
源码Source io/agentscope/spring/boot/ollama/OllamaChatModelBuilderCustomizer.java:41

accept

default public void accept(OllamaChatModel.Builder builder)
default

设置该参数。

Accept and invoke the given builder.

参数Parameters
名称Name类型Type说明Description
builderOllamaChatModel.Builder构建器(类型 `OllamaChatModel.Builder`)。the builder to customize
源码Source io/agentscope/spring/boot/ollama/OllamaChatModelBuilderCustomizer.java:48–51
基于官方固定版本源码静态生成Generated from pinned official sources · Python 2.0.11 · Java 2.0.4
签名与文档为静态抽取;如有疑问请以源码为准。Signatures and docs are extracted statically; verify against the source when in doubt.