偷偷摘套内射激情视频,久久精品99国产国产精,中文字幕无线乱码人妻,中文在线中文a,性爽19p

SpringAI-RC1正式發(fā)布:移除千帆大模型!

人工智能
前幾日 Spring AI 悄悄的發(fā)布了最新版 Spring AI 1.0.0 RC1(5.13 發(fā)布),此版本也將是 GA(Generally Available,正式版)發(fā)布前的最后一個版本,正式版計劃在 5.20 日發(fā)布。

續(xù) Spring AI M8 版本之后(5.1 發(fā)布),前幾日 Spring AI 悄悄的發(fā)布了最新版 Spring AI 1.0.0 RC1(5.13 發(fā)布),此版本也將是 GA(Generally Available,正式版)發(fā)布前的最后一個版本,正式版計劃在 5.20 日發(fā)布。

這個版本的改動相比于上一個版本 M8 來說,改動不算很大,但也有一些讓我們意想不到的版本更新,接下來一起來看。

移除千帆大模型 SDK

國內(nèi)開發(fā)者關(guān)系比較大的一個更新就是 Spring AI RC1 移除了百度的千帆大模型,給出的原因是中國境外無法訪問,所以被移除了,官方文檔中千帆的對接文檔也被刪除了,變成這個樣子了:

這樣一來,Spring AI 直接對接國內(nèi)的大模型就剩下 DeepSeek 和智普 AI 這兩家公司了

國內(nèi)的阿里的百煉平臺也沒有直接提供 SDK 對接,算是比較遺憾的,因為國內(nèi)使用通義大模型的公司是非常多的,并且百煉平臺內(nèi)置了 200+ 家大模型,對接百煉相當(dāng)于對接了 200+ 大模型。當(dāng)然我們可以使用 OpenAI 協(xié)議接入它,但這就意味著,我們在這個項目中不能同時在接入 OpenAI 大模型了,希望后期官方能提供百煉平臺的 SDK 對接方式。

其他重要更新

  • VectorStoreChatMemoryAdvisor 更新:

a.常量 CHAT_MEMORY_RETRIEVE_SIZE_KEY 被重命名為 TOP_K。

b.常量 DEFAULT_CHAT_MEMORY_RESPONSE_SIZE 被重命名為 DEFAULT_TOP_K,并且其默認(rèn)值從 100 調(diào)成為 20。

  • 常量 CHAT_MEMORY_CONVERSATION_ID_KEY 被重命名為 CONVERSATION_ID,并從 AbstractChatMemoryAdvisor 移動到 ChatMemory。請更新您的導(dǎo)入以使用 org.springframework.ai.chat.memory.ChatMemory.CONVERSATION_ID。
  • 問答中增加了自包含模版,例如:
  • query 用于接收用戶問題的占位符。
  • 用于接收檢索到的上下文的占位符 question_answer_context。
  • 使用示例如下:
  • QuestionAnswerAdvisor 具有以下占位符:
PromptTemplate customPromptTemplate = PromptTemplate.builder()
    .renderer(StTemplateRenderer.builder().startDelimiterToken('<').endDelimiterToken('>').build())
    .template("""
            <query>

            Context information is below.

   ---------------------
   <question_answer_context>
   ---------------------

   Given the context information and no prior knowledge, answer the query.

   Follow these rules:

   1. If the answer is not in the context, just say that you don't know.
   2. Avoid statements like "Based on the context..." or "The provided information...".
            """)
    .build();

    String question = "Where does the adventure of Anacletus and Birba take place?";

    QuestionAnswerAdvisor qaAdvisor = QuestionAnswerAdvisor.builder(vectorStore)
        .promptTemplate(customPromptTemplate)
        .build();

    String response = ChatClient.builder(chatModel).build()
        .prompt(question)
        .advisors(qaAdvisor)
        .call()
        .content();
- PromptChatMemoryAdvisor 具有以下占位符:
    * instructions 接收原始系統(tǒng)消息的占位符。
    * memory用于接收檢索到的對話記憶的占位符。
- VectorStoreChatMemoryAdvisor 具有以下占位符:
    * instructions 接收原始系統(tǒng)消息的占位符。
    * long_term_memory 用于接收檢索到的對話記憶的占位符。

組件重命名:

  • spring-ai-model-chat-memory- → spring-ai-model-chat-memory-repository-
  • spring-ai-autoconfigure-model-chat-memory- → spring-ai-autoconfigure-model-chat-memory-repository-
  • spring-ai-starter-model-chat-memory- → spring-ai-starter-model-chat-memory-repository-
  • org.springframework.ai.chat.memory.jdbc → org.springframework.ai.chat.memory.repository.jdbc
  • JdbcChatMemoryAutoConfiguration → JdbcChatMemoryRepositoryAutoConfiguration
  • spring.ai.chat.memory.… → spring.ai.chat.memory.repository.…

其他升級請查看官方更新日志:https://docs.spring.io/spring-ai/reference/upgrade-notes.html#upgrading-to-1-0-0-RC1

小結(jié)

AI 發(fā)展速度很快,對各行各業(yè)的影響也很大。充分了解和掌握 AI 知識,對日常工作提效或以后跳槽都有很大的幫助,讓我們一起行動起來,擁抱這場 AI 盛宴吧。

責(zé)任編輯:姜華 來源: 磊哥和Java
相關(guān)推薦

2011-10-25 09:35:25

jQuery 1.7

2011-07-13 15:56:20

PhoneGap 1.PhoneGap

2009-11-03 08:49:02

UltraEditLinux操作系統(tǒng)

2009-12-01 09:41:57

NetBeans 6.

2009-04-23 09:14:34

Dojo新版發(fā)布

2010-12-28 09:54:34

FreeBSD 8.2FreeBSD 7.4

2009-04-03 14:19:41

Windows Ser微軟RC1

2024-03-21 13:51:00

百度智能云千帆

2011-11-25 14:40:34

Lua

2009-10-27 08:44:52

UbuntuRC候選版正式版

2025-05-15 03:00:00

2011-04-01 11:16:23

Ubuntu 11.0

2011-09-02 10:14:17

Ubuntu 11.1

2025-01-26 09:15:00

模型視頻生成AI

2011-08-24 09:03:55

PostgreSQL
點贊
收藏

51CTO技術(shù)棧公眾號