@Override
    public void handlerPlugin(final PluginData pluginData) {
        if (Objects.nonNull(pluginData) && pluginData.getEnabled()) {
            AiRequestTransformerConfig aiRequestTransformerConfig = GsonUtils.getInstance().fromJson(pluginData.getConfig(), AiRequestTransformerConfig.class);
            if (Objects.isNull(aiRequestTransformerConfig)) {
                return;
            }
            AiModelFactory factory = aiModelFactoryRegistry.getFactory(AiModelProviderEnum.getByName(aiRequestTransformerConfig.getProvider()));
            ChatClientCache.getInstance().init("default", factory.createAiModel(convertConfig(aiRequestTransformerConfig)));
            Singleton.INST.single(AiRequestTransformerConfig.class, aiRequestTransformerConfig);
        }
    }
this is ai request transformer plugin.
shenyu-plugin/shenyu-plugin-ai/shenyu-plugin-ai-request-transformer/src/main/java/org/apache/shenyu/plugin/ai/transformer/request/handler/AiRequestTransformerPluginHandler.java