<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <title>Api on Duckweeds7&#39;s blog</title>
    <link>https://www.duckweeds7.com/tags/api/</link>
    <description>Recent content in Api on Duckweeds7&#39;s blog</description>
    <generator>Hugo -- gohugo.io</generator>
    <language>zh-hans</language>
    <lastBuildDate>Thu, 15 Jan 2026 00:00:00 +0000</lastBuildDate><atom:link href="https://www.duckweeds7.com/tags/api/index.xml" rel="self" type="application/rss+xml" />
    <item>
      <title>Gemini API 坑我一下午：它明明干活了，为啥就是不说话？</title>
      <link>https://www.duckweeds7.com/posts/gemini-api-empty-response-due-to-safety-filter/</link>
      <pubDate>Thu, 15 Jan 2026 00:00:00 +0000</pubDate>
      
      <guid>https://www.duckweeds7.com/posts/gemini-api-empty-response-due-to-safety-filter/</guid>
      
      <description>排查 Gemini API 返回内容为空但消耗了 token 的问题，发现是安全过滤器（Safety Filter）拦截了模型的输出。本文介绍了如何通过检查 API 响应中的 &lt;code&gt;finish_reason&lt;/code&gt; 和 &lt;code&gt;safety_ratings&lt;/code&gt; 来定位问题，并提供了两种解决方案：调整 Prompt 或修改安全设置。</description>
      
    </item>
    
  </channel>
</rss>
