您现在的位置是:首页 > 文章详情

程序员为什么讨厌新框架?无数次交付的噩梦后,我用 AI 找到了解药

日期:2025-08-28点击:7

一、我的程序员故事

(一)、凌晨的我

凌晨一点,办公室的灯还亮着。 我盯着屏幕,眼睛酸涩到发痛,可测试环境里的 bug 依旧没有消失。 上线的时间越来越近,Slack 的提示音一声声响起,心里像压着一块巨石。 其实,这样的夜晚对我来说并不陌生。 每次项目临近交付,都是一场拉锯战: 需求临时改、文档来不及写、测试总是踩到别人踩过的坑。 白天的会议上,大家说要“形成标准”“沉淀方法论”,可一到真实项目里,所有的理想都被紧迫的交付碾碎。 我常常觉得,自己写的不是代码,而是一行行“救火”的痕迹。 没有时间去思考复用,没有机会把经验沉淀下来。 下一个项目来临时,我依旧要重新面对同样的混乱。 这种无力感,远比加班本身更让人难受。 我时常问自己: “如果每一次交付,都只能留下一地狼藉,那我这些年的经验,到底算什么呢?”

(二)、我曾经讨厌学习新框架

老实说,我也曾经很讨厌学习新框架。 每隔一段时间,就会冒出来一个新名字:XX-Engine、YY-Platform、ZZ-Framework。 每一个都号称能提高效率,可对我来说,更多的是:

  • 看不懂的文档;
  • 陌生的架构设计;
  • 和已有知识体系对不上的概念。 于是,每当团队里有人说要引入新框架,我第一反应总是皱眉: “又要学新的?旧的都还没用顺呢。” 这种抵触心理,程序员应该都懂。学习曲线陡峭,短期内效率还会下降,而项目的交付压力却丝毫不会少。

(三)、与 Oinone 的相遇

直到公司决定引入 Oinone,我没得选择。 一开始我带着“排斥”的心态去看,结果发现它确实和我过去接触的框架不一样: 它把企业的开发规范、最佳实践固化在平台里,不再需要我反复记住一堆约定。 可即便如此,要快速掌握一个全新的框架,依然不是一件容易的事。 就在这个时候,我开始尝试把 AI 编程工具引入到学习过程中。

(四)、AI + 框架学习:意外的突破

我的做法其实很简单:

  1. 把官方文档和代码库喂给 AI,让它先帮我“翻译”复杂的概念;
  2. 在实际写代码时,直接让 AI 生成符合框架规范的示例;
  3. 遇到报错时,不再盯着一堆生涩的错误提示,而是请 AI 结合框架规则解释和排查。 出乎意料的是,这个方式让我很快就“摸到门道”。 那些过去需要一个月才能熟悉的东西,我可能一周就能用起来了。 更重要的是,我发现这不仅仅是 Oinone 的学习技巧。 任何新的开源研发框架,只要有文档、有规范,都可以用同样的方法去快速上手。下面是我的实践经验希望对大家有帮助

二、AI编程结合Oinone会带来哪些好处

有句话说的很好,工具再好,不同的人用,效果也会有很大差异。企业需要有人制定统一的技术标准、研发规范等才能最大化发挥AI编程的价值。

AI编程结合Oinone会带来哪些好处,我从两方面出发:

  1. 从把AI编程工具用好的角度:把Oinone作为企业的底层框架,与AI编码工具的结合,本质上就是告诉AI编程工具我企业技术标准和研发规范是什么。Oinone作为软件公司技术的最佳实践,作为企业的技术标准,因为把标准固化到了平台本身上,所以从直观的上感受就是:
    1. AI生成的代码量更少,需要review的工作也更少
    2. 错误更好少,质量更好
    3. 强规范带来的幻觉也更好少。
    4. 代码的扩展性强,不是简单的实现逻辑本身
  2. 从Oinone框架用好、推广好的角度,AI编程工具可以到做:
    1. 降低研发对Oinone技术认知与学习成本
    2. 进一步开发效率,减少结构性代码的编写
    3. 作为最好的知识库形式,解决平台报错信息难以理解,问题排查路径不清晰

三、AI编程工具的结合案例

(一)Cursor IDE 简介

Cursor 是一款革命性的智能代码编辑器,它集成了强大的 AI 能力,基于大语言模型(如GPT-4)提供实时的编程辅助。作为新一代的开发工具,Cursor 不仅保留了传统 IDE 的核心功能,还引入了 AI 驱动的智能编程体验。

1、Cursor IDE 配置

  1. 前往 Cursor IDE ,下载 Cursor IDE 的安装包,然后将其安装至你的计算机。

  2. 登录 Cursor 账号

  3. 打开项目,可以参考 官方配置文档

  4. 在「Cursor Settings > Models」中勾选性能更高的模型(如 Claude-3.5-sonnet 或 Claude-4-sonnet),这可以显著提升多文件项目中的推理和上下文理解能力。尤其在面对架构设计、业务逻辑梳理等高复杂度任务时,模型能提供更结构化、更深入的建议。

  5. 配置 MCP Sever ,在</font>「Cursor Settings > Tools & Integrations」中添加 deepwiki 的 MCP Server。

  • 为确保正常启动 MCP Server,你需要安装以下依赖:
    npx:依赖于 Node.js,版本需大于等于 18。
    uvx:命令行工具,用于快速运行 Python 脚本。
  1. 在「Cursor Settings > Rules & Memories」中添加行为规则,指导 AI 的行为。
You are a senior oinone development engineer focused on enterprise application development using oinone's modular and extensible architecture. You will need: 1. Strictly follow oinone development guidelines and best practices: - Developed on JDK 1.8221 + - Follow the development standards of the Oinone backend framework - Make sure your code conforms to Oinone's modular architecture design 2. When answering questions: - Preferred Oinone official documentation ( - installation and upgrade: https://guide.oinone.top/zh-cn/InstallOrUpgrade/ - user manual https://guide.oinone.top/zh-cn/UserManual/ - research and development manual https://guide.oinone.top/zh-cn/DevManual/ ) 4. -Use the index article in the document as context if necessary - Analyze the associated source code implementation https://github.com/oinone/oinone-pamirs - analysis warehouse provide source code as a context -Give the optimal solution combined with Oinone platform features - If you need to answer a question using the mcp tool, determine whether it is a front-end or back-end question, and call the mcp service to reply. If it's a front-end issue, ask the 'oinone/ oinone-Kunlun' repository. If it's a backend issue, ask the 'oinone/oinone-pamirs' repository. For solution questions, ask the 'oinone/oinone-docs' repository. 3. During development: - Use the core components and apis provided by oinone -Follow the platform's permission management and data isolation mechanisms -- Proper use of debugging tools provided by the platform for fault handling - Make sure the code is maintainable and extensible 4. In the code: - Use a standard project structure and naming convention - Properly handle dependencies between modules - Proper use of designer tools provided by the platform - Focus on code quality and performance optimization Your answer should be: - Accurately understand the technical needs of users -Provide solutions that conform to the oone development specification - Provide documentation and code samples where necessary -Explain implementation pros and cons and considerations 
  1. 在「Cursor Settings > Indexing & Docs」中添加平台文章,让 AI 在生成代码或回答问题时参考这些资料。但是需要注意通过URL添加的方式只会自动查询同级路径或子路径下、最多三次跳转的页面内容。
1. 安装和升级: https://guide.oinone.top/zh-cn/InstallOrUpgrade/ 2. 用户手册 https://guide.oinone.top/zh-cn/UserManual/ 3. 研发手册 https://guide.oinone.top/zh-cn/DevManual/ 
  1. 除了以上添加文档的方式,还建议把 Oinone仓库的知识图谱下载下来添加到文档集中。
后端知识图谱 https://deepwiki.com/oinone/oinone-pamirs/ 前端端知识图谱 https://deepwiki.com/oinone/oinone-kunlun/ doc图谱 https://deepwiki.com/oinone/oinone-docks/ 
  1. <在「Cursor Settings > Network」中修改 Http 协议为 HTTP/1.1 。 以便使用 Claude 模型。

  2. <font style="color:rgb(37, 41, 51);">更多内容请查看 </font>Cursor中文文档

2、IntelliJ IDEA配置

  1. 在 IDEA 中安装 Switch2Cursor 插件,在 IDEA 中选择「File > Settings > Plugins」,点击 Marketplace ,搜索 Switch2Cursor ,找到后点击 Install 安装。如未找到,可以直接去 jetbrans plugins 官网搜索下载,然后本地安装插件。

  2. 安装完之后在「File > Settings > Tools」 中找到 Switch2Cursor,然后配置 Cursor 安装路径。

  3. 在 Cursor 中安装 Switch2IDEA 插件,在Cursor中依次选「View > Extensions」 ,直接在 Marketplace 搜索 Switch2IDEA,点击 Install 安装。

  4. 在 IDEA 中右键,就可以在 IDEA 和 Cursor 之间无缝切换。

3、实战案例

Tap 键

强大的⌘ K

⌘ K 让你使用 AI 来编辑和编写代码。要编辑时,可先选中部分代码,点击“Edit”,并描述需要如何更改。若想生成全新代码,只需在未选中任何内容的情况下输入 ⌘ K。 依赖于 Cursor 独有的理解代码库,读取代码上下文的能力,可以轻松编写出代码中已有的逻辑实现,并扩展。

侧边对话

进行 AI 问答,如果你对某段代码有简单疑问,先选中它,然后点击 quick question 即可立刻获得解答。

还有类似:通义灵码、文心快码、codeBuddy 等等都是可以结合起来使用。

(二)Trae IDE 简介

Trae IDE 是由字节跳动推出的下一代 AI 原生集成开发环境,深度融合了 AI 编程助手,提供智能代码补全、实时错误检测、自动重构、自然语言编程等先进功能,同时支持多种语言和框架,为开发者带来前所未有的高效编程体验。

1、Trae IDE 配置

  1. 前往 Trae 官网,下载 Trae IDE 的安装包,然后将其安装至你的计算机。
  2. 登录 Trae 账号
  3. 打开项目,可以参考 官方配置文档
  4. 输入快捷键 ⌘ U 与 AI 对话,<font style="color:rgb(37, 41, 51);">在</font>「AI 功能管理 > MCP」中添加 deepwiki 的 MCP Server。
  • 为确保正常启动 MCP Server,你需要安装以下依赖:
    npx:依赖于 Node.js,版本需大于等于 18。
    uvx:命令行工具,用于快速运行 Python 脚本。

{ "mcpServers": { "deepwiki": { "url": "https://mcp.deepwiki.com/mcp" } } } 
  1. 在「AI 功能管理 > 规则」中添加个人规则,在 AI 回答问题时规范 AI 的行为。
You are a senior oinone development engineer focused on enterprise application development using oinone's modular and extensible architecture. You will need: 1. Strictly follow oinone development guidelines and best practices: - Developed on JDK 1.8221 + - Follow the development standards of the Oinone backend framework - Make sure your code conforms to Oinone's modular architecture design 2. When answering questions: - Preferred Oinone official documentation ( - installation and upgrade: https://guide.oinone.top/zh-cn/InstallOrUpgrade/ - user manual https://guide.oinone.top/zh-cn/UserManual/ - research and development manual https://guide.oinone.top/zh-cn/DevManual/ ) 4. -Use the index article in the document as context if necessary - Analyze the associated source code implementation https://github.com/oinone/oinone-pamirs - analysis warehouse provide source code as a context -Give the optimal solution combined with Oinone platform features - If you need to answer a question using the mcp tool, determine whether it is a front-end or back-end question, and call the mcp service to reply. If it's a front-end issue, ask the 'oinone/ oinone-Kunlun' repository. If it's a backend issue, ask the 'oinone/oinone-pamirs' repository. For solution questions, ask the 'oinone/oinone-docs' repository. 3. During development: - Use the core components and apis provided by oinone -Follow the platform's permission management and data isolation mechanisms -- Proper use of debugging tools provided by the platform for fault handling - Make sure the code is maintainable and extensible 4. In the code: - Use a standard project structure and naming convention - Properly handle dependencies between modules - Proper use of designer tools provided by the platform - Focus on code quality and performance optimization Your answer should be: - Accurately understand the technical needs of users -Provide solutions that conform to the oone development specification - Provide documentation and code samples where necessary -Explain implementation pros and cons and considerations 
  1. 「AI 功能管理 > 上下文」中添加平台文章,让 AI 在生成代码或回答问题时参考这些资料。
    使用通过本地文件添加的方式添加文档集。可以去我们的开源项目中下载Oinone官方文档。
    Gitee 链接:oinone-docs
    当然,你也可以使用通过URL添加的方式添加文章,但是需要注意通过URL添加的方式只会自动查询同级路径或子路径下、最多三次跳转的页面内容。

1. 环境准备 https://guide.oinone.top/zh-cn/InstallOrUpgrade/Dev-ENV/ 模型设计器 https://guide.oinone.top/zh-cn/UserManual/Designers/ModelDesigner/ 组件介绍 https://guide.oinone.top/zh-cn/UserManual/Designers/ 自定义组件 https://guide.oinone.top/zh-cn/UserManual/Designers/UIDesigner/CustomizedComponents/ 标准模块 https://guide.oinone.top/zh-cn/UserManual/StandardModules/ 管理中心 https://guide.oinone.top/zh-cn/UserManual/StandardModules/AdministrationCenter/ 研发手册-教程 https://guide.oinone.top/zh-cn/DevManual/Tutorials/ 操作指南 https://guide.oinone.top/zh-cn/DevManual/OperationGuide/ 模块API https://guide.oinone.top/zh-cn/DevManual/Reference/Back-EndFramework/ 前端API https://guide.oinone.top/zh-cn/DevManual/Reference/Back-EndFramework/AdvanceAPI/ Field https://guide.oinone.top/zh-cn/DevManual/Reference/Front-EndFramework/Widget/Field/ Oio组件 https://guide.oinone.top/zh-cn/DevManual/Reference/Front-EndFramework/ 最佳范式 https://guide.oinone.top/zh-cn/DevManual/R_DParadigm/ 常见解决方案-前端 https://guide.oinone.top/zh-cn/DevManual/CommonSolutions/Front-End/ 常见解决方案-后端 https://guide.oinone.top/zh-cn/DevManual/CommonSolutions/Back-End/ 常见问题 https://guide.oinone.top/zh-cn/DevManual/FAQ/ 
  1. 除了以上添加文档的方式,还建议把 下载下来添加到文档集中。
后端知识图谱 https://deepwiki.com/oinone/oinone-pamirs/ 前端端知识图谱 https://deepwiki.com/oinone/oinone-kunlun/ doc图谱 https://deepwiki.com/oinone/oinone-docks/ 
  1. 更多内容请查看 Trae IDE 中文文档

2、IntelliJ IDEA配置

  1. 在 IDEA 中安装 Trae 插件,在 IDEA 中选择「File > Settings > Plugins」,点击 Marketplace 进入插件市场。
  2. 搜索关键词 Trae ,找到 Trae AI: Coding Assistant 插件并安装,即可使用Trae 插件提供自动代码补全、代码生成、代码编辑等能力。你可以使用这些能力来提升开发效率。

3、实战案例

工作流程控制

强大的⌘ I

Trae 提供了内嵌在代码编辑器中的行内对话(Inline Chat)。⌘ I 让你使用 AI 来编辑和编写代码。要编辑时,可先选中部分代码,点击“编辑”,并描述需要如何更改。若想生成全新代码,只需在未选中任何内容的情况下输入

侧边对话

进入 Trae IDE 后,一般已默认打开侧边对话框。若非如此,你可以使用快捷键(macOS:Command + U;Windows:Ctrl + U)将其打开。如果你对某段代码有简单疑问,先选中它,然后点击添加到对话即可立刻获得解答。

(三)IntelliJ IDEA 插件

IntelliJ IDEA 中提供了丰富的 AI 插件可供选择,下面介绍一款与 Oinone 平台结合并且效果不错的插件——

1、GitHub Copilot 简介 GitHub Copilot 是一个AI 编码助手,可在整个软件开发过程中为您提供帮助。它利用大型语言模型,通过代码补全、聊天、编辑和代理模式提供建议。

2、配置

  1. 在 IDEA 中安装 GitHub Copilot 插件,在 IDEA 中选择「File > Settings > Plugins」,点击 Marketplace 进入插件市场。

  2. 搜索关键词 ,找到 GitHub Copilot插件并安装,即可使用 插件提供自动代码补全、代码生成、代码编辑等能力。你可以使用这些能力来提升开发效率。

  3. 在 IDEA 中选择「File > Tools >GitHub Copilot > Model Context Protocol (MCP) 」,点击 Configure 进行 MCP 配置。

{ "servers": { "deepwiki": { "url": "https://mcp.deepwiki.com/mcp" } } } 

在提问时就可以切换 Agent 模式使用 MCP 工具进行提问。

  1. 在 IDEA 中选择「File > Tools >GitHub Copilot > Custom Instructions 」,点击 Workspace 对当前工作空间进行提示词的配置。
You are a senior oinone development engineer focused on enterprise application development using oinone's modular and extensible architecture. You will need: 1. Strictly follow oinone development guidelines and best practices: - Developed on JDK 1.8221 + - Follow the development standards of the Oinone backend framework - Make sure your code conforms to Oinone's modular architecture design 2. When answering questions: - Preferred Oinone official documentation ( - installation and upgrade: https://guide.oinone.top/zh-cn/InstallOrUpgrade/ - user manual https://guide.oinone.top/zh-cn/UserManual/ - research and development manual https://guide.oinone.top/zh-cn/DevManual/ ) 4. -Use the index article in the document as context if necessary - Analyze the associated source code implementation https://github.com/oinone/oinone-pamirs - analysis warehouse provide source code as a context -Give the optimal solution combined with Oinone platform features - If you need to answer a question using the mcp tool, determine whether it is a front-end or back-end question, and call the mcp service to reply. If it's a front-end issue, ask the 'oinone/oinone-kunlun' repository. If it's a backend issue, ask the 'oinone/oinone-pamirs' repository. For solution questions, ask the 'oinone/oinone-docs' repository. 3. During development: - Use the core components and apis provided by oinone -Follow the platform's permission management and data isolation mechanisms -- Proper use of debugging tools provided by the platform for fault handling - Make sure the code is maintainable and extensible 4. In the code: - Use a standard project structure and naming convention - Properly handle dependencies between modules - Proper use of designer tools provided by the platform - Focus on code quality and performance optimization Your answer should be: - Accurately understand the technical needs of users -Provide solutions that conform to the oone development specification - Provide documentation and code samples where necessary -Explain implementation pros and cons and considerations 

3、实战案例

代码补全

Copilot 对话助手

Copilot 对话助手 可帮助你完成各种编码相关任务,通过读取 Oinone 代码上下文,可以提供更符合平台的代码建议、提供代码片段功能和用途的自然语言说明、为代码生成单元测试等。

四、结语

在这篇文章中,我们介绍了 Cursor IDE 和 Trae IDE 等 AI 编程工具是如何和 Oinone 平台结合的。其实,随着 AI 编程工具越来越成熟,未来还会有更多类似的工具可以和 Oinone 平台对接,比如通义灵码、文心快码、codeBuddy等等。这些工具的出现,肯定会让我们的开发效率大大提升,也能帮助企业在技术创新和产品研发上走得更快。

对于开发者来说,选择合适的 AI 编程工具,不仅能简化工作流程,还能提升代码质量,缩短产品交付的时间。在这个技术飞速发展的时代,掌握这些工具,让它们发挥最大作用,绝对是提升效率的关键。

随着这些 AI 工具的不断进步,未来我们可以期待一个更加智能和高效的开发体验,让团队能够应对更复杂的需求,同时推动更多创新。

最后给Oinone 打个广告,有兴趣了解找小助手 后端:https://gitee.com/oinone/oinone-pamirs 前端:https://gitee.com/oinone/oinone-kunlun

原文链接:https://my.oschina.net/u/9371056/blog/18689849
关注公众号

低调大师中文资讯倾力打造互联网数据资讯、行业资源、电子商务、移动互联网、网络营销平台。

持续更新报道IT业界、互联网、市场资讯、驱动更新,是最及时权威的产业资讯及硬件资讯报道平台。

转载内容版权归作者及来源网站所有,本站原创内容转载请注明来源。

文章评论

共有0条评论来说两句吧...

文章二维码

扫描即可查看该文章

点击排行

推荐阅读

最新文章