相关推荐
Cursor SDK:用 TypeScript 声明式构建可调试、可复用的 AI Agent
Agent 是现代 AI 应用的核心抽象,其本质是具备感知、决策与执行能力的程序化智能体;实现原理依赖于类型安全的工具编排、状态生命周期管理与 LLM 调用链路控制;技术价值在于将非确定性 AI 行为转化为可测试、可版本化、可协作的工程资产;典型应用场景包括自动化代码审查、智能文档生成、多步骤业务流程编排等;而 Cursor SDK 正是以 TypeScript 为契约语言、以 SDK 为集成桥梁,让开发者能像编写 React 组件一样定义 Agent 行为——真正实现‘写代码即造 Agent’,显著降低
Cannot read property ‘match‘ of undefined
match语法 string.match(RegExp) 检查是否获取到了string,我这边报错的原因在于string没有获取到,返回的是一个undefined值。 排查后还需要检查传入的参数是否为RegExp对象,如果不是,需要先把参数转换为RegExp对象。转换方法如下: var reg = new RegExp(searchContent);//将searchContent转换为RegExp对象 searchText.match(reg)//拿reg做match的传入参数 ...
CLI驱动的AI开发工作流:从终端命令到CI集成的工程实践
CLI(命令行接口)是将大模型能力深度融入软件开发生命周期的核心载体,其本质是可脚本化、可版本化、可管道化的AI客户端。它基于标准HTTP协议调用LLM API,通过本地配置实现上下文编排、Token预算控制与错误码标准化处理,技术价值在于打破网页聊天框的交互局限,让AI能力像git或npm一样成为开发者每日依赖的基础设施。典型应用场景包括自动化代码审查、智能调试辅助、上下文感知的代码生成,以及CI/CD流水线中的AI增强型质量门禁。本文聚焦Claude CLI、Codex CLI与Gemini CLI三类
npm ERR! Cannot read property ‘match‘ of undefined 错误处理
npm ERR! Cannot read property 'match' of undefined 错误处理
Trae代理工具实战:用Go打造可路由AI模型网关
AI编程助手Trae本质上是一个遵循OpenAI API协议的智能前端客户端,其核心价值在于协议兼容性与可扩展性。通过在HTTP层构建轻量级反向代理,开发者能绕过厂商锁定,实现本地Ollama、远程Anthropic及OpenAI等多源模型的统一接入与动态路由。该方案不修改客户端、不逆向逻辑,仅依赖标准HTTP转发与响应体实时转换,兼顾安全性、可观测性与工程落地性。尤其适合需要私有化部署、混合模型调度或调试API通信链路的技术人员,是当前AI IDE增强生态中兼具实用性与教学价值的关键中间件。
Cursor 2026深度解析:Composer Agent与.cursorrules协同工作流
AI编程助手已从代码补全工具演进为可编程的协作者操作系统。其核心在于上下文感知的持久化会话、规则驱动的执行沙盒与多智能体协同编排三大原理——前者实现意图精准理解,后者保障生成结果可控可信,而编排机制则支撑复杂工程任务的系统性解决。技术价值体现在显著降低PR评审耗时、提升首次提交通过率、内化团队工程规范;典型应用场景包括微服务接口适配、跨仓库SDK维护、高可靠性支付网关开发等中高级工程师日常。本文聚焦Cursor 2026中真正改变工作流的Composer Agent与.cursorrules深度协同实践。
报错:Cannot read property ‘match‘ of undefined的解决方法
npm报错:Cannot read property 'match' of undefined的解决方法
前端开发:npm install 报错npm ERR! Cannot read property ‘extraneous‘ of undefined的解决方法
前言 项目为了上基线,把本地项目编译之后的node_modules文件和dist文件都删掉了,然后上完基线之后,重新编译本地项目代码,结果初始化项目失败,提示无法读取未定义的“外部”属性,原因就是上一次编译的项目包没有处理干净造成的报错,那么本篇博文就来分享一下相关的解决方法。 报错提示 在删除本地项目编译生成的node_modules文件夹,然后重新编译项目:npm install 然后项目报错,报错信息如下所示: admin@MacBook-Pro Project % npm instal
npm ERR! Cannot read property ‘match‘ of undefined
vue
一文了解向量数据库在RAG中扮演的角色
向量数据库:AI新纪元的基石。探索如何通过这一创新技术优化RAG,提高语言模型的信息处理能力
别怕,“卷积”其实很简单
首先给大家讲一个关于卷积的小故事:小明是杭州某互联网大厂的员工,每天996十分辛苦,但小明最近爱上了打台球,经常不在工位。这天,小明的主管让小明改一个需求,小明却到楼下找产品部小丽打台球去了,被主管发现,他非常气愤,扇了小明一巴掌(注意,这就是输入信号,脉冲)。于是小明脸上会渐渐地(贱贱地)鼓起来一个包,小明的脸就是一个系统,而鼓起来的包就是小明的脸对巴掌的响应。好,这样就和信号系统建立起来意义对应的联系。
npm i报错npm ERR! Cannot read property match of undefined
今天在使用taro下载taro-ui插件时报错,报错后吧node-modules删除,然后npm i后报错 PS F:\WorkFolder\myApp> npm i npm ERR! Cannot read property 'match' of undefined npm ERR! A complete log of this run can be found in: npm ERR! C:\Users\ykuser\AppData\Roaming\npm-cache\_logs\202
CAPL编程的催化剂——CAPLdll的实现
CANoe作为一款功能强大的总线开发及测试工具,不仅仅是因为其丰富的库函数,最重要的是其兼容了多种编程语言,可以实现灵活的开发,极大的解决了纯CAPL编程所带来的限制,如通过动态链接库(DLL)来实现复杂函数的编写,使其能够在CAPL中可以调用,下面将对DLL的实现进行分析。capldll.cpp这个文件初看相当复杂,从整体上来说,这段代码主要包含了两部分:自定义函数实现和回调函数定义,今天的主要任务是实现自定义函数,这里的函数定义与普通函数定义差不多,只是利用了CAPL的格式。在VS2017工程中打开。
Module build failed: TypeError: Cannot read property ‘match‘ of undefined at Object.解决
xxnpm ERR! Cannot read property 'match' of undefined 错误处理_Jane_96的博客-优快云博客跟往常一样运行npm install 的时候,突然报错。错误情况如下:npm ERR! Cannot read property 'match' of undefinednpm ERR! A complete log of this run can be found in:npm ERR! C:\Users\user\AppData\Roamin
深入理解HTTPS:从SSLHandshakeException到证书链验证的完整解析
本文深入解析了HTTPS握手过程中常见的SSLHandshakeException异常,特别是由证书链验证失败引发的CertPathValidatorException。文章从TLS握手流程、证书链验证的数学原理出发,详细剖析了Java中TrustManager的工作机制,并提供了针对证书链不完整、自签名证书等典型问题的系统化排查流程与实战解决方案。
告别‘报错马拉松’:一份保姆级的Ubuntu 20.04编译OpenWrt 15.05环境配置与问题修复清单
本文提供了一份详细的Ubuntu 20.04编译OpenWrt 15.05的环境配置与问题修复指南,帮助开发者告别‘报错马拉松’。从基础环境搭建到典型报错分类与修复方案,再到高阶问题的深度修复,全面覆盖编译过程中可能遇到的各类问题,并提供自动化补丁脚本和Docker环境固化方案,确保编译过程高效顺畅。
Node.js模块测试实战:用Mocha+assert构建轻量可验证质检线
在模块化开发中,Node.js模块的质量保障核心在于可验证的独立行为——这要求测试机制必须具备确定性、隔离性与低侵入性。Mocha作为专注BDD/TDD的测试框架,配合Node.js内置的assert模块,形成零抽象、高透明的断言体系,天然适配纯逻辑型工具模块(如CSV解析、定价引擎)的验证需求。其轻量启动(127ms级)、清晰错误定位(严格相等/深度比较/异常捕获)及环境友好性(免Babel/Webpack),显著降低CI耗时与调试成本。本文基于真实项目排错经验,详解如何用describe/it组织行为契
Python实现稳态传热传质的偏微分方程求解
通过这种方法,我们可以求解更复杂的传热传质问题,并对系统的温度和浓度分布进行分析和优化。稳态传热传质是一个重要的工程问题,涉及到物质在空间中的分布以及热量和质量的传递。每次迭代中,我们使用上一次迭代的温度值来计算下一次迭代的温度值。该图显示了平板内部各点的温度分布,其中中心温度为T1,边界温度为T2。接下来,我们创建一个N x N的温度矩阵,并将边界条件初始化为边界温度T2。假设我们有一个矩形平板,其中心温度为T1,四个边界温度为T2。假设平板的长度为L,宽度为W,中心温度为T1,边界温度为T2。
Node.js单元测试实战:用Mocha和原生assert构建可靠测试体系
单元测试是保障Node.js应用质量的基础工程实践,其核心在于确定性、可调试性与契约一致性。Mocha作为轻量级测试框架,不封装断言逻辑,配合Node.js原生assert模块,提供无抽象层的严格相等(strictEqual)与深度相等(deepStrictEqual)能力,避免Jest等工具因序列化或Mock机制引入的不可控行为。这种组合在类型校验、Buffer字节比对、错误边界覆盖等关键场景中展现出更高可靠性与调试效率,特别适用于中大型项目、IoT协议解析及遗留系统渐进式测试补全。本文聚焦Mocha+a
【嘉立创EDA】PCB 多层板如何交换内层,4层板交换板层
本文使用嘉立创EDA,描述如何在PCB设计时,如何交换各个板层,特别是4层板需要交换内层时,应该如何操作,以供有需要的读者参考。
在Simulink中搭建一个基于IoT设备间通信协议栈的仿真模型
物联网(IoT)设备间的通信协议栈仿真对于理解不同层级的协议如何协同工作,以及优化网络性能至关重要。通过Simulink结合MATLAB的强大功能,我们可以模拟和分析从物理层到应用层的完整通信过程。下面详细介绍如何使用Simulink进行IoT设备间通信协议栈的仿真。
React动态加载与Hooks协同的工程化实践
动态组件加载是现代前端应用实现代码分割与首屏优化的核心技术,其本质是将模块加载这一异步过程与React渲染生命周期对齐。理解import()的Promise语义、Suspense的fallback机制及Hooks的同步执行约束,是避免Invalid hook call、hydration不一致和白屏问题的前提。本文聚焦React.lazy与自定义Hooks(如useAsyncEffect、useModuleCache)在中大型项目中的深度协同,覆盖超时控制、错误边界、缓存策略与SSR兼容等关键工程挑战,为构
深度学习工具包 DeepLearningToolbox
深度学习工具包Deprecation notice.-----This toolbox is outdated and no longer maintained.There are much better tools available for deep learning than this toolbox, e.g. [Theano](http://deeplearning.net/software/theano/), [torch](http://torch.ch/) or [tensorflow](http://www.tensorflow.org/)I would suggest you use one of the tools mentioned above rather than use this toolbox.Best, Rasmus.DeepLearnToolbox================A Matlab toolbox for Deep Learning.Deep Learning is a new subfield of machine learning that focuses on learning deep hierarchical models of data.It is inspired by the human brain's apparent deep (layered, hierarchical) architecture.A good overview of the theory of Deep Learning theory is[Learning Deep Architectures for AI](http://www.iro.umontreal.ca/~bengioy/papers/ftml_book.pdf)For a more informal introduction, see the following videos by Geoffrey Hinton and Andrew Ng.* [The Next Generation of Neural Networks](http://www.youtube.com/watch?v=AyzOUbkUf3M) (Hinton, 2007)* [Recent Developments in Deep Learning](http://www.youtube.com/watch?v=VdIURAu1-aU) (Hinton, 2010)* [Unsupervised Feature Learning and Deep Learning](http://www.youtube.com/watch?v=ZmNOAtZIgIk) (Ng, 2011)If you use this toolbox in your research please cite [Prediction as a candidate for learning deep hierarchical models of data](http://www2.imm.dtu.dk/pubdb/views/publication_details.php?id=6284)```@MASTERSTHESIS\{IMM2012-06284, author = "R. B. Palm", title = "Prediction as a candidate for learning deep hierarchical models of data", year = "2012",}```Contact: rasmusbergpalm at gmail dot comDirectories included in the toolbox-----------------------------------`NN/` - A library for Feedforward Backpropagation Neural Networks`CNN/` - A library for Convolutional Neural Networks`DBN/` - A library for Deep Belief Networks`SAE/` - A library for Stacked Auto-Encoders`CAE/` - A library for Convolutional Auto-Encoders`util/` - Utility functions used by the libraries`data/` - Data used by the examples`tests/` - unit tests to verify toolbox is workingFor references on each library check REFS.mdSetup-----1. Download.2. addpath(genpath('DeepLearnToolbox'));Example: Deep Belief Network---------------------```matlabfunction test_example_DBNload mnist_uint8;train_x = double(train_x) / 255;test_x = double(test_x) / 255;train_y = double(train_y);test_y = double(test_y);%% ex1 train a 100 hidden unit RBM and visualize its weightsrand('state',0)dbn.sizes = [100];opts.numepochs = 1;opts.batchsize = 100;opts.momentum = 0;opts.alpha = 1;dbn = dbnsetup(dbn, train_x, opts);dbn = dbntrain(dbn, train_x, opts);figure; visualize(dbn.rbm{1}.W'); % Visualize the RBM weights%% ex2 train a 100-100 hidden unit DBN and use its weights to initialize a NNrand('state',0)%train dbndbn.sizes = [100 100];opts.numepochs = 1;opts.batchsize = 100;opts.momentum = 0;opts.alpha = 1;dbn = dbnsetup(dbn, train_x, opts);dbn = dbntrain(dbn, train_x, opts);%unfold dbn to nnnn = dbnunfoldtonn(dbn, 10);nn.activation_function = 'sigm';%train nnopts.numepochs = 1;opts.batchsize = 100;nn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.10, 'Too big error');```Example: Stacked Auto-Encoders---------------------```matlabfunction test_example_SAEload mnist_uint8;train_x = double(train_x)/255;test_x = double(test_x)/255;train_y = double(train_y);test_y = double(test_y);%% ex1 train a 100 hidden unit SDAE and use it to initialize a FFNN% Setup and train a stacked denoising autoencoder (SDAE)rand('state',0)sae = saesetup([784 100]);sae.ae{1}.activation_function = 'sigm';sae.ae{1}.learningRate = 1;sae.ae{1}.inputZeroMaskedFraction = 0.5;opts.numepochs = 1;opts.batchsize = 100;sae = saetrain(sae, train_x, opts);visualize(sae.ae{1}.W{1}(:,2:end)')% Use the SDAE to initialize a FFNNnn = nnsetup([784 100 10]);nn.activation_function = 'sigm';nn.learningRate = 1;nn.W{1} = sae.ae{1}.W{1};% Train the FFNNopts.numepochs = 1;opts.batchsize = 100;nn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.16, 'Too big error');```Example: Convolutional Neural Nets---------------------```matlabfunction test_example_CNNload mnist_uint8;train_x = double(reshape(train_x',28,28,60000))/255;test_x = double(reshape(test_x',28,28,10000))/255;train_y = double(train_y');test_y = double(test_y');%% ex1 Train a 6c-2s-12c-2s Convolutional neural network %will run 1 epoch in about 200 second and get around 11% error. %With 100 epochs you'll get around 1.2% errorrand('state',0)cnn.layers = { struct('type', 'i') %input layer struct('type', 'c', 'outputmaps', 6, 'kernelsize', 5) %convolution layer struct('type', 's', 'scale', 2) %sub sampling layer struct('type', 'c', 'outputmaps', 12, 'kernelsize', 5) %convolution layer struct('type', 's', 'scale', 2) %subsampling layer};cnn = cnnsetup(cnn, train_x, train_y);opts.alpha = 1;opts.batchsize = 50;opts.numepochs = 1;cnn = cnntrain(cnn, train_x, train_y, opts);[er, bad] = cnntest(cnn, test_x, test_y);%plot mean squared errorfigure; plot(cnn.rL);assert(er<0.12, 'Too big error');```Example: Neural Networks---------------------```matlabfunction test_example_NNload mnist_uint8;train_x = double(train_x) / 255;test_x = double(test_x) / 255;train_y = double(train_y);test_y = double(test_y);% normalize[train_x, mu, sigma] = zscore(train_x);test_x = normalize(test_x, mu, sigma);%% ex1 vanilla neural netrand('state',0)nn = nnsetup([784 100 10]);opts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samples[nn, L] = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.08, 'Too big error');%% ex2 neural net with L2 weight decayrand('state',0)nn = nnsetup([784 100 10]);nn.weightPenaltyL2 = 1e-4; % L2 weight decayopts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samplesnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex3 neural net with dropoutrand('state',0)nn = nnsetup([784 100 10]);nn.dropoutFraction = 0.5; % Dropout fraction opts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samplesnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex4 neural net with sigmoid activation functionrand('state',0)nn = nnsetup([784 100 10]);nn.activation_function = 'sigm'; % Sigmoid activation functionnn.learningRate = 1; % Sigm require a lower learning rateopts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samplesnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex5 plotting functionalityrand('state',0)nn = nnsetup([784 20 10]);opts.numepochs = 5; % Number of full sweeps through datann.output = 'softmax'; % use softmax outputopts.batchsize = 1000; % Take a mean gradient step over this many samplesopts.plot = 1; % enable plottingnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex6 neural net with sigmoid activation and plotting of validation and training error% split training data into training and validation datavx = train_x(1:10000,:);tx = train_x(10001:end,:);vy = train_y(1:10000,:);ty = train_y(10001:end,:);rand('state',0)nn = nnsetup([784 20 10]); nn.output = 'softmax'; % use softmax outputopts.numepochs = 5; % Number of full sweeps through dataopts.batchsize = 1000; % Take a mean gradient step over this many samplesopts.plot = 1; % enable plottingnn = nntrain(nn, tx, ty, opts, vx, vy); % nntrain takes validation set as last two arguments (optionally)[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');```[](https://bitdeli.com/free "Bitdeli Badge")
OpenClaw + Qwen3.5 Plus 一键智能体部署实战
智能体(AI Agent)是大模型落地的关键范式,其核心在于大模型的工具调用(Tool Calling)能力与运行时框架的协议对齐。Qwen3.5 Plus 首次专为智能体场景优化,原生支持结构化 JSON 输出与精准函数名匹配;OpenClaw 作为轻量级智能体运行时,通过 Skill 机制实现技能即代码、上下文动态管理与热重载。二者协同构建了低门槛、高确定性的本地智能体开发闭环——无需 Docker 编排、不依赖云平台、规避环境配置陷阱,真正实现从零到 API 响应的分钟级验证。本文聚焦于 CLI 直连
visio安装包
Microsoft Office Visio 是一款专业的制图软件。利用经过更新的形状、协作工具和数据链接图表,创建专业级图表以简化复杂的信息。
精雕软件(JDpaint) 5.5 绿色版
精雕软件(JDpaint) 5.5 绿色版精雕软件(JDpaint) 5.5 绿色版精雕软件(JDpaint) 5.5 绿色版

440



被折叠的 条评论
为什么被折叠?



