上一页 1 ··· 9 10 11 12 13 14 15 16 17 ··· 499 下一页
摘要: history 是浏览器环境中所支持的一个对象,该对象用于管理当前创建最近访问过的 URL 历史记录,所有的 URL 会被存储在一个名为 histroy 的对象里面,回头就可以通过 JS 脚本调用 history 对象的方法从而控制浏览器前进或者后退。 例如打开浏览器,新创建一个标签页会话,然后在控 阅读全文
posted @ 2025-07-16 14:24 Zhentiw 阅读(84) 评论(0) 推荐(0)
摘要: Overriding a function lets you wrap a third-party method with your own logic while still invoking its original behavior. Example code: const unmountAp 阅读全文
posted @ 2025-07-15 13:50 Zhentiw 阅读(11) 评论(0) 推荐(0)
摘要: import { ollama } from "ollama-ai-provider"; import { generateObject, generateText } from "ai"; import { z } from "zod"; import { globby } from "globb 阅读全文
posted @ 2025-07-05 19:06 Zhentiw 阅读(17) 评论(0) 推荐(0)
摘要: import { ollama } from "ollama-ai-provider"; import { generateObject } from "ai"; import { z } from "zod"; import { globby } from "globby"; import { p 阅读全文
posted @ 2025-07-05 18:55 Zhentiw 阅读(14) 评论(0) 推荐(0)
摘要: import { ollama } from "ollama-ai-provider"; import { generateObject } from "ai"; import { z } from "zod"; import { parseArgs } from "node:util"; cons 阅读全文
posted @ 2025-07-05 18:40 Zhentiw 阅读(27) 评论(0) 推荐(0)
摘要: Run: ollama run gemma3 import { ollama } from "ollama-ai-provider"; import { generateObject } from "ai"; import { z } from "zod"; const model = ollama 阅读全文
posted @ 2025-07-05 18:37 Zhentiw 阅读(40) 评论(0) 推荐(0)
摘要: LLM,Large Language Model,大语言模型。 🤔思考: LLM 和 AI 这个词是完全等价的?或者说 AI 就是 LLM 么? LLM 仅仅是 AI 的一个分支。 任何能够使机器模仿人类行为的技术,都可以称之为人工智能技术。 人工智能下面有很多的分支,其中一个就是机器学习。 人类 阅读全文
posted @ 2025-07-05 18:20 Zhentiw 阅读(92) 评论(0) 推荐(0)
摘要: 准备工作 本地模型 模型分为两种: 1.专有模型:闭源模型 OpenAI GPT4 Cluade 优点:强大的商业支持 缺点:付费、数据的隐私 2.开源模型(学习阶段) 微软:Phi Meta:Llama deepseek 不需要联网 安装Ollama Ollama:模型平台,可以安装各种模型:Qw 阅读全文
posted @ 2025-07-05 18:18 Zhentiw 阅读(35) 评论(0) 推荐(0)
摘要: 通过前面的代码,其实我们已经完成了从模板AST到Javascript AST的转换 const ast = parse(template); transform(ast); 那接下来,我们只需要再根据Javascript AST生成具体的js代码就行了,比如再执行下面的函数: generate(as 阅读全文
posted @ 2025-06-27 13:41 Zhentiw 阅读(22) 评论(0) 推荐(0)
摘要: 我们现在已经有了模板AST,那么根据之前的顺序,我们现在需要把模板AST转化为JSAST。 要知道,模板AST是对模板的描述,那么JSAST就是对JS代码的描述。 也就是说,我们最终希望得到的代码是下面这样的: function render(){ return h('div',[ h('p','V 阅读全文
posted @ 2025-06-27 13:34 Zhentiw 阅读(23) 评论(0) 推荐(0)
上一页 1 ··· 9 10 11 12 13 14 15 16 17 ··· 499 下一页