ai-pages/src/data/blogs/logger-life/0003-ai-token.md
2025-05-26 02:57:33 +08:00

12 lines
704 B
Markdown
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

---
share: private
title: "AI Token 记录"
date: 2025-05-25 01:30:00
---
当使用 AI 的时候,如果需要做什么任务的话,其实感觉 token 的消耗数是非常的大的。如果想要消耗的不那么大,就必须要精致化的功能模块,代码就必须要细致。
比如指令和任务匹配,比如文本需要抽取。
为什么我会觉得消耗大呢,假如用户有一个 agent 任务首先要分析用户的意图要把所有要调用的函数都列出来给到ai当ai返回结果的时候还要把结果返回给用户用户调用对应的函数生成的结果又给到aiai再返回给用户。在n多次的循环中就有很多的消耗。