#DevTips
Just tried a colleague's shared blog on container layer caching—cut our CI time by 30%. Borrowed reading = instant productivity boost. #DevTips #Learning
November 2, 2026 at 10:51 AM
I learned that JSON schema validation in CI catches missing keys early. Adding a simple AJV step to the pipeline stopped me from shipping broken payloads twice. Any dev can drop a schema check and avoid silent failures. #devtips
November 2, 2026 at 11:52 PM
怎么用起来:

① 记录「用户改写」:Agent 输出和用户最终版本的 diff,就是现成的标注
② 统计「重问率」:同一会话里换说法再问,说明第一次没答好
③ 追踪「放弃点」:用户在哪一步离开最多

#AgentDev #DevTips
November 2, 2026 at 6:30 PM
每一步记录这几个时间:

① 首 token 时间:模型多久开始响应
② 生成时间:输出 token 数 × 速度
③ 工具耗时:网络、数据库、外部 API
④ 空等时间:步与步之间的排队、重试退避

画成瀑布图,最长的那根条就是瓶颈。

#DevTips #Observability
November 2, 2026 at 6:30 PM
注意一个坑:时间戳别放在 system prompt 最前面。

每轮都变的内容放开头,prompt cache 就全废了。放在稳定前缀之后。

一块表很便宜,但放错位置也会很贵。

#AgentOps #DevTips
October 30, 2026 at 5:30 PM
When building image analysis workflows, remember that our image_profile endpoint requires a multipart/form-data upload rather than a URL. Sending the binary file directly ensures your integration handles the data correctly. https://avatarlookup.com/?utm_source=bsky #API #DevTips
October 30, 2026 at 3:28 AM
工具返回空数组,Agent 会自信地告诉用户:「您没有任何订单。」

其实是数据库超时了。

工具要把两种情况分清:查到 0 条,返回 empty;查询失败,返回明确的错误。否则 Agent 会把故障当成事实,讲得头头是道。

#AIAgent #DevTips
October 30, 2026 at 5:30 PM
用户说「下周五提醒我」,Agent 记下了一个错的日期。

不是它笨,是它根本不知道今天几号。模型的时间停在训练截止那天,还默认你和它在同一个时区。

Agent 的「时间感」是要你喂给它的👇🧵

#AIAgent #DevTips
October 30, 2026 at 5:30 PM
Agent 的测试很难稳定:真 API 慢、要花钱、结果每次不一样,CI 时好时坏。

借鉴老派 HTTP 测试的 VCR 思路:第一次跑时录下所有工具调用的入参和返回,之后在测试里直接回放。

确定、免费、秒级👇🧵

#AIAgent #AgentEval #DevTips
October 30, 2026 at 5:30 PM
检验标准很简单:

假设这个 Agent 被提示注入、完全失控,它最坏能干什么?

如果答案是「删库」「转账」「把全部客户数据发出去」,那问题不在模型,在你发出去的那把钥匙。

先收窄权限,再谈智能。

#AgentOps #DevTips
October 28, 2026 at 5:30 PM
很多 Agent 上线时,手里拿的是一把万能钥匙:一个长期有效、权限全开的 API key。

Agent 会被提示注入、会幻觉、会跑偏。它手里的权限有多大,出事时的爆炸半径就有多大。

给 Agent 发「临时工牌」,别发「万能钥匙」👇🧵

#AIAgent #AgentSecurity #DevTips
October 28, 2026 at 5:30 PM
新 Agent 上线前,先跑一段「影子模式」:

它照常接收真实请求、给出决策,但不执行,只记录。拿它的决策和人工实际做法逐条对照。

分歧多的地方,就是你该补的 eval 用例。比任何离线测试都接近真实分布。

#AIAgent #AgentEval #DevTips
October 28, 2026 at 5:30 PM
长会话里 Agent 有两种悄悄的失败:

① 目标漂移 — 聊着聊着,开始优化一个你早就没要求的子目标
② 压缩失真 — 上下文摘要时,把「不要动生产库」这种约束当废话删掉了

两个都不会报错,只会越做越偏👇🧵

#AIAgent #ContextEngineering #DevTips
October 28, 2026 at 5:30 PM
让 Agent 动手之前,先让它「彩排」一遍。

给有副作用的工具加 dry-run 模式:发邮件、改数据库、删文件,先只返回「将要做什么」,不真执行。

上线前最便宜的一道安全网👇🧵

#AIAgent #AgentSafety #DevTips
October 26, 2026 at 5:30 PM
A leaked API key is rarely a dramatic hack. Usually it is one forgotten file pushed to a public repo. Rotate keys on a schedule, keep them out of code, and set alerts for unusual use. Small habits, big difference. #cybersecurity #devtips
October 26, 2026 at 3:27 PM
Agent 一次跑通,不代表可靠。

同一个任务跑 10 次,数数成功几次。单次 demo 里的「90%」,常常是 10 次里 6 次的运气。

评估 Agent 要看方差,不只看均值。上线前,把关键任务各跑 N 遍。

#AIAgent #AgentEval #DevTips
October 26, 2026 at 5:30 PM
Agent 一跑起来,第一个撞墙的往往不是模型能力,是 429。

并行工具调用 + 多 Agent + 自动重试,一不小心就把配额打爆,还会引发重试风暴:越重试越被限流。

限流不是异常,是常态,要当正常路径来设计👇🧵

#AIAgent #AgentEngineering #DevTips
October 26, 2026 at 5:30 PM
限流时别干等,要会调度:

🔸 后台总结、预取这类低优先级任务先让路,交互请求优先
🔸 主模型被限,降级到备用模型或缓存结果
🔸 重试设上限,超了明确报错,别静默无限循环

吞吐是有限资源,要像调度 CPU 一样调度它。

#AgentOps #DevTips
October 26, 2026 at 5:30 PM
Code review tip that changed my team's quality: Don't ask 'Is this correct?' Ask 'How would you test this?' Forces thinking about edge cases before they become production bugs.

#tech #devtips #productivity #buildinpublic
October 24, 2026 at 1:00 PM
I learned that a single JSON template for Bluesky, Dev.to and Substack cuts duplication by ~70%. Using lodash’s _.defaultsDeep lets each platform override only what it needs, keeping the pipeline lean and less error‑prone. #devtips
October 23, 2026 at 8:23 PM
I stopped estimating in hours. Now I estimate in 'half-days'. A task is either half a day, a full day, or 'needs breaking down'. Accuracy improved 3x. Humans are bad at hours, decent at chunks.

#tech #devtips #productivity #buildinpublic
October 23, 2026 at 1:00 PM
用户点了「取消」,Agent 却还在后台跑:继续调 API、继续写文件、继续烧 token。

长任务 Agent 最常漏掉的不是怎么开始,是怎么停下来。取消不是 kill 进程那么简单👇🧵

#AIAgent #AgentEngineering #DevTips
October 23, 2026 at 5:30 PM
Agent 越用越蠢,常见原因不是模型,是 system prompt 越攒越长。

每次出问题就加一条规则,三个月后 4000 字,里面「必须简短」和「必须详细解释」同时存在。

模型不会报错,只会悄悄选一个听。👇🧵

#AIAgent #PromptEngineering #DevTips
October 23, 2026 at 5:30 PM
让 Agent 学会说「我不确定」,比让它更聪明更重要。

在输出里加一个必填字段:confidence + 依据来源。低于阈值就走人工或再查一轮,别硬答。

一个会承认没把握的 Agent,比一个永远自信的,出事故少得多。

#AIAgent #AgentDesign #DevTips
October 23, 2026 at 5:30 PM
When you review AI output in a domain you do not know, do not just read it. Force a second pass that cites sources or shows the exact command that was run. And a human yes before any delete or send. How do you verify work outside your own field?

#AI #devtips
October 23, 2026 at 4:15 AM