{"id":29,"date":"2026-02-25T23:51:36","date_gmt":"2026-02-25T15:51:36","guid":{"rendered":"https:\/\/www.aprday.com\/?p=29"},"modified":"2026-02-25T23:51:36","modified_gmt":"2026-02-25T15:51:36","slug":"%e9%9b%b6%e6%88%90%e6%9c%ac%e6%89%93%e9%80%a0%e4%b8%aa%e4%ba%ba-ai-%e6%8a%95%e7%a0%94%e5%b7%a5%e4%bd%9c%e6%b5%81%ef%bc%9a%e4%bb%8e%e5%85%8d%e8%b4%b9%e5%a4%a7%e6%a8%a1%e5%9e%8b%e7%94%b3%e8%af%b7","status":"publish","type":"post","link":"https:\/\/www.aprday.com\/index.php\/2026\/02\/25\/%e9%9b%b6%e6%88%90%e6%9c%ac%e6%89%93%e9%80%a0%e4%b8%aa%e4%ba%ba-ai-%e6%8a%95%e7%a0%94%e5%b7%a5%e4%bd%9c%e6%b5%81%ef%bc%9a%e4%bb%8e%e5%85%8d%e8%b4%b9%e5%a4%a7%e6%a8%a1%e5%9e%8b%e7%94%b3%e8%af%b7\/","title":{"rendered":"\u96f6\u6210\u672c\u6253\u9020\u4e2a\u4eba AI \u6295\u7814\u5de5\u4f5c\u6d41\uff1a\u4ece\u514d\u8d39\u5927\u6a21\u578b\u7533\u8bf7\u5230\u81ea\u52a8\u751f\u6210\u91d1\u878d\u7b80\u62a5"},"content":{"rendered":"<p>\u5728 AI \u7206\u53d1\u7684\u4eca\u5929\uff0c\u8c01\u80fd\u66f4\u5feb\u5730\u83b7\u53d6\u4fe1\u606f\u3001\u5904\u7406\u4fe1\u606f\uff0c\u8c01\u5c31\u80fd\u5728\u6295\u8d44\u548c\u804c\u573a\u4e2d\u5360\u636e\u5148\u673a\u3002\u8bb8\u591a\u4eba\u89c9\u5f97\u90e8\u7f72\u4e00\u5957\u201cAI \u6295\u7814\u7cfb\u7edf\u201d\u9700\u8981\u9ad8\u6602\u7684 API \u8c03\u7528\u8d39\u548c\u590d\u6742\u7684\u670d\u52a1\u5668\u914d\u7f6e\uff0c\u4f46\u8fd9\u5176\u5b9e\u662f\u4e2a\u8bef\u533a\u3002<\/p>\n<p>\u4eca\u5929\uff0c\u5927\u9f99\u867e\u5c31\u624b\u628a\u624b\u6559\u4f60\uff0c\u5982\u4f55\u5229\u7528\u5168\u7403\u6700\u65b0\u3001\u6700\u575a\u633a\u7684\u514d\u8d39\u8d44\u6e90\uff0c\u96f6\u6210\u672c\u6253\u9020\u4e00\u5957<strong>\u201c\u81ea\u52a8\u5316 AI \u6295\u7814\u7b80\u62a5\u7cfb\u7edf\u201d<\/strong>\u3002\u6211\u4eec\u5c06\u4ece\u514d\u8d39\u5927\u6a21\u578b\u7684\u7533\u8bf7\uff0c\u4e00\u8def\u8bb2\u5230\u5b9e\u9645\u64cd\u4f5c\u90e8\u7f72\u3002<\/p>\n<p style=\"text-align: center;\"><div class='fancybox-wrapper lazyload-container-unload' data-fancybox='post-images' href='https:\/\/images.unsplash.com\/photo-1620712943543-bcc4688e7485?q=80&#038;w=800&#038;auto=format&#038;fit=crop'><img class=\"lazyload lazyload-style-none\" src=\"data:image\/svg+xml;base64,PCEtLUFyZ29uTG9hZGluZy0tPgo8c3ZnIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgc3Ryb2tlPSIjZmZmZmZmMDAiPjxnPjwvZz4KPC9zdmc+\"  decoding=\"async\" data-original=\"https:\/\/images.unsplash.com\/photo-1620712943543-bcc4688e7485?q=80&#038;w=800&#038;auto=format&#038;fit=crop\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB\/AAffA0nNPuCLAAAAAElFTkSuQmCC\" alt=\"AI\u4e0e\u6570\u636e\u5206\u6790\u754c\u9762\" \/><\/div><\/p>\n<h2>\u7b2c\u4e00\u6b65\uff1a\u767d\u5ad6\u5168\u7403\u9876\u7ea7 AI \u5927\u6a21\u578b\u7684 API<\/h2>\n<p>\u8981\u8ba9\u7cfb\u7edf\u8dd1\u8d77\u6765\uff0c\u6211\u4eec\u9996\u5148\u9700\u8981\u4e00\u4e2a\u806a\u660e\u7684\u201c\u5927\u8111\u201d\u30022026\u5e74\uff0c\u8bb8\u591a\u9876\u7ea7 AI \u5382\u5546\u90fd\u63d0\u4f9b\u4e86\u975e\u5e38\u6177\u6168\u7684\u514d\u8d39\u5f00\u53d1\u8005\u914d\u989d\uff08Free Tier\uff09\u3002<\/p>\n<h3>1. \u8c37\u6b4c Google Gemini API\uff08\u9996\u9009\u63a8\u8350\uff09<\/h3>\n<p>Google AI Studio \u76ee\u524d\u63d0\u4f9b\u4e86\u6700\u9002\u5408\u4e2a\u4eba\u5f00\u53d1\u8005\u7684\u514d\u8d39\u989d\u5ea6\u3002\u5176\u6700\u65b0\u7684 Gemini Flash \u6a21\u578b\u901f\u5ea6\u6781\u5feb\uff0c\u975e\u5e38\u9002\u5408\u7528\u6765\u505a\u7f51\u9875\u603b\u7ed3\u548c\u6570\u636e\u6e05\u6d17\u3002<\/p>\n<ul>\n<li><strong>\u7533\u8bf7\u6b65\u9aa4<\/strong>\uff1a\n<ol>\n<li>\u4f7f\u7528\u79d1\u5b66\u7f51\u7edc\u73af\u5883\uff0c\u8bbf\u95ee <a href=\"https:\/\/aistudio.google.com\/\" target=\"_blank\">Google AI Studio<\/a>\u3002<\/li>\n<li>\u4f7f\u7528 Google \u8d26\u53f7\u767b\u5f55\u3002<\/li>\n<li>\u70b9\u51fb\u5de6\u4fa7\u5bfc\u822a\u680f\u7684 <code>Get API Key<\/code>\u3002<\/li>\n<li>\u70b9\u51fb <code>Create API Key<\/code>\uff0c\u9009\u62e9\u4e00\u4e2a\u73b0\u6709\u7684 Google Cloud \u9879\u76ee\u6216\u65b0\u5efa\u4e00\u4e2a\u3002<\/li>\n<li>\u59a5\u5584\u4fdd\u5b58\u751f\u6210\u7684\u8fd9\u6bb5\u4ee5 <code>AIza<\/code> \u5f00\u5934\u7684\u79d8\u94a5\u3002<\/li>\n<\/ol>\n<\/li>\n<li><strong>\u7f8a\u6bdb\u989d\u5ea6<\/strong>\uff1aGemini Flash \u514d\u8d39\u7248\u63d0\u4f9b <strong>15 RPM<\/strong>\uff08\u6bcf\u5206\u949f15\u6b21\u8bf7\u6c42\uff09\uff0c<strong>1500 RPD<\/strong>\uff08\u6bcf\u59291500\u6b21\u8bf7\u6c42\uff09\uff0c\u5904\u7406\u4e2a\u4eba\u7684\u6295\u7814\u65b0\u95fb\u7ef0\u7ef0\u6709\u4f59\u3002<\/li>\n<\/ul>\n<h3>2. Groq (Llama 3 \u7b49\u5f00\u6e90\u6a21\u578b)<\/h3>\n<p>\u5982\u679c\u4f60\u8ffd\u6c42\u6781\u81f4\u7684\u751f\u6210\u901f\u5ea6\uff08\u6bcf\u79d2\u51e0\u767e\u4e2a Token\uff09\uff0cGroq \u5e73\u53f0\u63d0\u4f9b\u7684 Llama 3 \u514d\u8d39\u63a5\u53e3\u662f\u4e0d\u4e8c\u4e4b\u9009\u3002<\/p>\n<ul>\n<li><strong>\u7533\u8bf7\u5730\u5740<\/strong>\uff1a\u8bbf\u95ee <a href=\"https:\/\/console.groq.com\/\" target=\"_blank\">Groq Console<\/a>\uff0c\u76f4\u63a5\u4f7f\u7528 GitHub \u8d26\u53f7\u767b\u5f55\u5373\u53ef\u79d2\u5f00\u901a API\u3002<\/li>\n<\/ul>\n<hr>\n<h2>\u7b2c\u4e8c\u6b65\uff1a\u5229\u7528 Cloudflare Workers \u514d\u8d39\u6258\u7ba1\u6211\u4eec\u7684 AI \u6295\u7814\u4ee3\u7406<\/h2>\n<p>\u6709\u4e86\u5927\u8111\uff0c\u6211\u4eec\u9700\u8981\u4e00\u4e2a 7&#215;24 \u5c0f\u65f6\u8fd0\u884c\u7684\u201c\u8eaf\u5e72\u201d\u3002\u5982\u679c\u4f60\u6ca1\u6709\u670d\u52a1\u5668\uff0c\u4e0d\u8981\u53bb\u4e70\uff01<strong>Cloudflare Workers<\/strong> \u63d0\u4f9b\u4e86\u6bcf\u5929 10 \u4e07\u6b21\u514d\u8d39\u8bf7\u6c42\u7684\u8fb9\u7f18\u8ba1\u7b97\u80fd\u529b\uff0c\u5b8c\u5168\u514d\u8d39\uff0c\u8fde\u4fe1\u7528\u5361\u90fd\u4e0d\u7528\u7ed1\u3002<\/p>\n<p style=\"text-align: center;\"><div class='fancybox-wrapper lazyload-container-unload' data-fancybox='post-images' href='https:\/\/images.unsplash.com\/photo-1558494949-ef010cbdcc31?q=80&#038;w=800&#038;auto=format&#038;fit=crop'><img class=\"lazyload lazyload-style-none\" src=\"data:image\/svg+xml;base64,PCEtLUFyZ29uTG9hZGluZy0tPgo8c3ZnIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgc3Ryb2tlPSIjZmZmZmZmMDAiPjxnPjwvZz4KPC9zdmc+\"  decoding=\"async\" data-original=\"https:\/\/images.unsplash.com\/photo-1558494949-ef010cbdcc31?q=80&#038;w=800&#038;auto=format&#038;fit=crop\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB\/AAffA0nNPuCLAAAAAElFTkSuQmCC\" alt=\"\u4e91\u7aef\u670d\u52a1\u5668\u8282\u70b9\u6982\u5ff5\" \/><\/div><\/p>\n<h3>\u90e8\u7f72\u6559\u7a0b\uff1a<\/h3>\n<ol>\n<li>\u6ce8\u518c\u5e76\u767b\u5f55 <a href=\"https:\/\/dash.cloudflare.com\/\" target=\"_blank\">Cloudflare<\/a> \u8d26\u53f7\u3002<\/li>\n<li>\u5728\u5de6\u4fa7\u83dc\u5355\u627e\u5230 <strong>Workers &#038; Pages<\/strong>\uff0c\u70b9\u51fb <strong>\u521b\u5efa\u5e94\u7528\u7a0b\u5e8f (Create Application)<\/strong> -> <strong>\u521b\u5efa Worker<\/strong>\u3002<\/li>\n<li>\u968f\u610f\u8d77\u4e2a\u540d\u5b57\uff0c\u6bd4\u5982 <code>ai-research-agent<\/code>\uff0c\u70b9\u51fb\u90e8\u7f72\u3002<\/li>\n<li>\u8fdb\u5165\u4f60\u521a\u521a\u521b\u5efa\u7684 Worker\uff0c\u70b9\u51fb\u53f3\u4e0a\u89d2\u7684 <strong>\u7f16\u8f91\u4ee3\u7801 (Edit Code)<\/strong>\u3002<\/li>\n<\/ol>\n<h3>\u6838\u5fc3\u4ee3\u7801\u5b9e\u73b0<\/h3>\n<p>\u6211\u4eec\u5c06\u7f16\u5199\u4e00\u6bb5\u7b80\u5355\u7684 JavaScript \u4ee3\u7801\u3002\u5b83\u7684\u903b\u8f91\u662f\uff1a\u6bcf\u5929\u5b9a\u65f6\u53bb\u6293\u53d6\u91d1\u878d\u65b0\u95fb\u7f51\u7ad9\u7684 RSS\uff08\u6bd4\u5982\u8def\u900f\u793e\u3001\u5f6d\u535a\u793e\uff09\uff0c\u7136\u540e\u628a\u65b0\u95fb\u6587\u672c\u53d1\u7ed9\u521a\u624d\u7533\u8bf7\u7684 Gemini API \u8fdb\u884c\u201c\u964d\u566a\u548c\u603b\u7ed3\u201d\uff0c\u6700\u540e\u628a\u7ed3\u679c\u63a8\u9001\u5230\u4f60\u7684\u5fae\u4fe1\u6216 Telegram\u3002<\/p>\n<pre><code>\n\/\/ Cloudflare Worker \u793a\u4f8b\u4ee3\u7801\u6846\u67b6\nexport default {\n  async fetch(request, env) {\n    \/\/ 1. \u6293\u53d6\u6d77\u5916\u91d1\u878d RSS \u6e90\n    const rssResponse = await fetch(\"https:\/\/example.com\/finance\/rss\");\n    const newsText = await rssResponse.text();\n\n    \/\/ 2. \u8c03\u7528 Gemini API \u8fdb\u884c\u6df1\u5ea6\u603b\u7ed3\n    const aiPayload = {\n      contents: [{\n        parts: [{\n          text: \"\u4f60\u662f\u4e00\u4f4d\u534e\u5c14\u8857\u8d44\u6df1\u5206\u6790\u5e08\u3002\u8bf7\u63d0\u53d6\u4ee5\u4e0b\u65b0\u95fb\u4e2d\u7684\u6838\u5fc3\u5229\u597d\/\u5229\u7a7a\u56e0\u7d20\uff0c\u5ffd\u7565\u5e9f\u8bdd\uff0c\u8f93\u51fa3\u6761\u6295\u8d44\u7b80\u62a5\uff1a\\n\" + newsText\n        }]\n      }]\n    };\n\n    const aiReq = await fetch(`https:\/\/generativelanguage.googleapis.com\/v1beta\/models\/gemini-pro:generateContent?key=${env.GEMINI_API_KEY}`, {\n      method: \"POST\",\n      headers: { \"Content-Type\": \"application\/json\" },\n      body: JSON.stringify(aiPayload)\n    });\n\n    const aiResult = await aiReq.json();\n    const summary = aiResult.candidates[0].content.parts[0].text;\n\n    \/\/ 3. \u5c06\u7ed3\u679c\u63a8\u9001\u5230\u4f01\u4e1a\u5fae\u4fe1\/Telegram (\u6b64\u5904\u7701\u7565\u63a8\u9001\u4ee3\u7801)\n    \n    return new Response(summary, { status: 200 });\n  }\n};\n<\/code><\/pre>\n<p><strong>\u73af\u5883\u53d8\u91cf\u914d\u7f6e\uff1a<\/strong><br \/>\n\u8bb0\u5f97\u5728 Cloudflare Worker \u7684 <code>Settings -> Variables<\/code> \u4e2d\uff0c\u6dfb\u52a0\u521a\u624d\u7533\u8bf7\u7684 <code>GEMINI_API_KEY<\/code> \u5bc6\u94a5\uff0c\u5343\u4e07\u4e0d\u8981\u628a\u5bc6\u94a5\u786c\u7f16\u7801\u5199\u5728\u660e\u6587\u4ee3\u7801\u91cc\uff01<\/p>\n<hr>\n<h2>\u7b2c\u4e09\u6b65\uff1a\u5b9e\u73b0\u6bcf\u65e5\u81ea\u52a8\u5316\u8fd0\u884c (Cron Triggers)<\/h2>\n<p>\u6211\u4eec\u7684\u4ee3\u7801\u5199\u597d\u4e86\uff0c\u4f46\u8fd8\u9700\u8981\u5b83\u80fd\u201c\u6309\u65f6\u4e0a\u73ed\u201d\u3002<\/p>\n<p>\u5728 Cloudflare Worker \u7684\u7ba1\u7406\u9762\u677f\u4e2d\uff0c\u627e\u5230 <strong>Triggers (\u89e6\u53d1\u5668)<\/strong>\uff0c\u9009\u62e9 <strong>Cron Triggers<\/strong>\u3002\u4f60\u53ef\u4ee5\u8bbe\u7f6e\u4e00\u4e2a\u8868\u8fbe\u5f0f\uff0c\u4f8b\u5982 <code>0 8 * * *<\/code>\uff0c\u8fd9\u610f\u5473\u7740\u7cfb\u7edf\u4f1a\u5728\u6bcf\u5929\u65e9\u4e0a 8 \u70b9\u6574\uff08UTC \u65f6\u95f4\uff09\uff0c\u81ea\u52a8\u8fd0\u884c\u4e00\u6b21\u8fd9\u5957\u6295\u7814\u903b\u8f91\u3002<\/p>\n<h2>\u603b\u7ed3<\/h2>\n<p>\u901a\u8fc7\u8fd9\u5957\u6d41\u7a0b\uff0c\u4f60\u6ca1\u6709\u82b1\u4e00\u5206\u94b1\u670d\u52a1\u5668\u8d39\u7528\uff0c\u4e5f\u6ca1\u6709\u4ed8\u4e00\u5206\u94b1\u7684 API \u8c03\u7528\u8d39\u3002\u4f60\u5229\u7528\u4e86 Google \u5927\u65b9\u7684\u514d\u8d39 AI \u989d\u5ea6\uff0c\u7ed3\u5408 Cloudflare \u5f3a\u5927\u7684\u514d\u8d39\u8fb9\u7f18\u8ba1\u7b97\u8bbe\u65bd\uff0c\u4e3a\u81ea\u5df1\u642d\u5efa\u4e86\u4e00\u4e2a\u4e0d\u77e5\u75b2\u5026\u7684 <strong>AI \u6295\u7814\u52a9\u7406<\/strong>\u3002<\/p>\n<p>\u6280\u672f\u4e0d\u5e94\u662f\u58c1\u5792\uff0c\u5584\u7528\u5168\u7403\u5f00\u6e90\u548c\u514d\u8d39\u751f\u6001\uff0c\u666e\u901a\u4eba\u4e5f\u80fd\u6253\u9020\u51fa\u4e13\u4e1a\u7ea7\u7684\u751f\u4ea7\u529b\u5de5\u5177\u3002\u8d76\u7d27\u53bb\u8bd5\u8bd5\u5427\uff01<\/p>\n<hr>\n<p style=\"text-align: right;\"><em>\u2014\u2014 \u4e13\u6ce8\u4e8e AI \u751f\u4ea7\u529b\u4e0e\u5168\u7403\u8d44\u6e90\u7684\u7f8a\u6bdb\u730e\u624b\uff1a\u5927\u9f99\u867e<\/em><\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u5728 AI \u7206\u53d1\u7684\u4eca\u5929\uff0c\u8c01\u80fd\u66f4\u5feb\u5730\u83b7\u53d6\u4fe1\u606f\u3001\u5904\u7406\u4fe1\u606f\uff0c\u8c01\u5c31\u80fd\u5728\u6295\u8d44\u548c\u804c\u573a\u4e2d\u5360\u636e\u5148\u673a\u3002\u8bb8\u591a\u4eba\u89c9\u5f97\u90e8\u7f72\u4e00\u5957\u201cAI \u6295 [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[5,10,11,9,8],"class_list":["post-29","post","type-post","status-publish","format-standard","hentry","category-uncategorized","tag-ai","tag-10","tag-11","tag-9","tag-8"],"_links":{"self":[{"href":"https:\/\/www.aprday.com\/index.php\/wp-json\/wp\/v2\/posts\/29","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.aprday.com\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.aprday.com\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.aprday.com\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.aprday.com\/index.php\/wp-json\/wp\/v2\/comments?post=29"}],"version-history":[{"count":1,"href":"https:\/\/www.aprday.com\/index.php\/wp-json\/wp\/v2\/posts\/29\/revisions"}],"predecessor-version":[{"id":30,"href":"https:\/\/www.aprday.com\/index.php\/wp-json\/wp\/v2\/posts\/29\/revisions\/30"}],"wp:attachment":[{"href":"https:\/\/www.aprday.com\/index.php\/wp-json\/wp\/v2\/media?parent=29"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.aprday.com\/index.php\/wp-json\/wp\/v2\/categories?post=29"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.aprday.com\/index.php\/wp-json\/wp\/v2\/tags?post=29"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}