Giter VIP home page Giter VIP logo

likuisuper / auto-dev Goto Github PK

View Code? Open in Web Editor NEW

This project forked from unit-mesh/auto-dev

0.0 0.0 0.0 1.93 MB

AutoDev 是一款 Intellij IDEA 的 LLM/AI 辅助编程插件。AutoDev 能够与您的需求管理系统(例如 Jira、Trello、Github Issue 等)直接对接。在 IDE 中,您只需简单点击,AutoDev 会根据您的需求自动为您生成代码。您所需做的,仅仅是对生成的代码进行质量检查。

Home Page: https://ide.unitmesh.cc/

License: Mozilla Public License 2.0

Java 0.24% Kotlin 99.76%

auto-dev's Introduction

AutoDev

Build Version Downloads

AutoDev 是一款高度自动化的 AI 辅助编程工具。AutoDev 能够与您的需求管理系统(例如 Jira、Trello、Github Issue 等)直接对接。在 IDE 中,您只需简单点击,AutoDev 会根据您的需求自动为您生成代码。您所需做的,仅仅是对生成的代码进行质量检查。

与 GitHub Copilot 差异:

特征 GitHub Copilot AutoDev
LLM训练 经过大模型训练,结果更加准确 引入 ChatGPT 或自己训练,结果不是那么准确
返回结果 一次返回多个结果 一次返回一个完整的方法
返回类型 返回一个完整的类 返回一个完整的方法
支持语言 支持多种语言 仅支持Java
支持功能 生成代码、生成注释、生成测试用例等 生成代码、寻找bug、生成注释等
开源 不开源 开源

结论:AutoDev 的唯一优势是开源,GitHub Copilot 完胜。

Todos

  • Languages Support by PSI
    • Java
  • Languages Support by LSP
    • Kotlin
    • TypeScript
  • DevTi Protocol
    • format 1: devti://story/github/1102
  • Intelli code change
    • Endpoint modify suggestions
    • Controller Suggestion
      • import all common imports
    • Service Suggestion
    • Repository Suggestion
  • Code AI
    • Generate code
    • Add comments
    • Code Suggestions
    • Find bug...
    • Explain code by selection
    • Trace Exception
  • Chat with IDE
    • Generate test
    • 实现:重现 xx 功能, devti:/chat/feature
    • 重构:重构 xx 方法
    • 替换:替换 xx 方法devti:/refactor/method
  • Custom LLM Server
  • Telemetry Server
    • Accept
    • Reject
    • Feedback
  • Context Engineering
    • Open Tabs
    • Related Files
    • with DependencyContext
      • parse Gradle for dependencies

Usage

  1. Install
    • method 1. Install from JetBrains Plugin Repository: AutoDev
    • method 2. Download plugin from release page: release and install plugin in your IDE
  2. configure GitHub Token (optional) and OpenAI config in Settings -> Tools -> DevTi

Copilot mode

  1. click as you want:

Copilot Mode

AutoCRUD mode

  1. add // devti://story/github/1 comments in your code.
  2. configure GitHub repository for Run Configuration.
  3. click AutoDev button in the comments' left.

Token Configure:

Token Configure

Run Screenshots:

AutoDev

Output Screenshots:

AutoDev

Custom OpenAI proxy example

Custom Config

原理

AutoDev 处理过程:

  1. 对接了需求系统,从需求系统中获取到需求文档
  2. 根据需求文档,自动分析需求,并完善需求文档
  3. 根据完善后的需求,寻找最适合的 Endpoint,即 Controller
  4. 根据 Endpoint,自动生成 Controller 代码
  5. 根据 Controller 代码,自动生成 Service 代码
  6. 根据 Service 代码,自动生成 Repository 代码

Development

  1. git clone https://github.com/unit-mesh/AutoDev.git
  2. open in IntelliJ IDEA
  3. ./gradlew runIde

LSP Json RPC

{
  "range": {
    "start": {
      "line": 0,
      "column": 0
    },
    "end": {
      "line": 0,
      "column": 0
    }
  },
  "text": "",
  "language": "xxx",
  "uuid": "xxx"
}

API Spec

authorization: Bearer ${token}

{
  "auto_complete": {
    "instruction": "",
    "input": ""
  },
  "auto_comment": {
    "instruction": "",
    "input": ""
  },
  "code_review": {
    "instruction": "",
    "input": ""
  },
  "find_bug": {
    "instruction": "",
    "input": ""
  }
}

then return:

{
  "instruction": "implementation the method",
  "input": "xxxx",
  "output": "xxxx"
}

How Copilot works?

  • IDE with InlaysAction (extends EditorAction)
  • send RPC to JSON RPC
  • WASM with TreeSitter
  • Return to IDE

License

ChatUI based on: https://github.com/Cspeisman/chatgpt-intellij-plugin

@Thoughtworks AIEEL Team. This code is distributed under the MPL 2.0 license. See LICENSE in this directory.

auto-dev's People

Contributors

phodal avatar yugasun avatar actions-user avatar imneov avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.