PS: ดู https://github.com/unit-mesh/unit-eval สำหรับการปรับแต่งที่เกี่ยวข้องกับการสร้างรหัสและการสร้างเอกสาร:
คำสั่ง: ชุดข้อมูลและ Lora Binary ที่จัดทำโดยโครงการนี้ทั้งหมดถูกสร้างขึ้นโดย OpenAI หรือเผยแพร่ออนไลน์ เรามีเพียงบทเรียนที่เกี่ยวข้องกับการฝึกอบรมแบบจำลองและผลที่ตามมาทั้งหมดที่เกิดจากเนื้อหาการฝึกอบรมที่แท้จริงของผู้ใช้คือความรับผิดชอบของผู้ใช้เอง
สำหรับวิศวกรเราสามารถเห็นผลกระทบของแบบจำลองภาษาขนาดใหญ่เช่น CHATGPT อย่างชัดเจนและทำให้เราได้ทำการวิจัยเกี่ยวกับการปรับปรุงประสิทธิภาพการวิจัยและพัฒนาของ AI - ได้รับการฝึกฝนหลายวิธีที่ใช้ในการศึกษาประสิทธิภาพการวิจัยและพัฒนาของ Llama Lora และ Chatglm Lora
โครงการนี้เป็นผลการวิจัยของเรารวมถึงการแนะนำวิดีโอรูปแบบที่ผ่านการฝึกอบรมรหัสการฝึกอบรมข้อมูลการฝึกอบรมและบันทึกบางอย่างในระหว่างกระบวนการฝึกอบรม
ดูการเปิดตัวสำหรับการฝึกอบรม Lora
สมุดบันทึกการฝึกอบรม:
วิดีโอออนไลน์ของ Llama ซีรีส์:
วิดีโอ chatglm ซีรีส์ออนไลน์:
สารบัญ:
การแปลงข้อมูลที่เกี่ยวข้องมีอยู่ที่: https://github.com/unit-mesh/minions-data-prepare
PS: หากคุณต้องการการสร้างรหัสที่ดีขึ้นขอแนะนำให้ใช้: https://huggingface.co/salesforce/codegen-16b-mono
เราใช้คลาวด์ GPU ที่จัดทำโดย OpenBayes: https://openbayes.com/console/signup?r=phodal_uvxu
สามารถใช้โมเดล OpenBayes ได้:
แผนงาน:
ขอบคุณ: AIOS Club สำหรับคีย์ Openai ขอบคุณ OpenBayes สำหรับ Cloud GPU
การปรับปรุงประสิทธิภาพการรับรู้ของ AI ขึ้นอยู่กับมาตรฐานของประสิทธิภาพการวิจัยและพัฒนาและการแยกแต่ละขั้นตอนให้ดีที่สุดเท่าที่จะทำได้
เพื่อให้ผลการฝึกอบรมมีความแม่นยำมากขึ้นเราได้แบ่งขั้นตอนการพัฒนาซอฟต์แวร์โดยละเอียดเพื่อให้แน่ใจว่าแต่ละขั้นตอนให้ผลลัพธ์ที่แม่นยำซึ่งจะผลักดันผลลัพธ์ที่แม่นยำ นี่คือตัวอย่างของส่วนเล็ก ๆ ของกระบวนการโดยละเอียดที่เรามีในการแยกก่อน:
เราจำเป็นต้องแยกมันออกเป็นแต่ละขั้นตอนให้เล็กที่สุดเท่าที่จะเป็นไปได้การให้อาหารในแต่ละขั้นตอนการกลั่นเพื่อให้ AI สร้างเอฟเฟกต์ repeater ที่ยิ่งใหญ่ที่สุด
โทดอส
เราใช้คำแนะนำง่าย ๆ และให้พวกเขาให้มากที่สุดเท่าที่จะเป็นไปได้สำหรับการรวมเข้ากับเครื่องมืออย่างง่ายดาย ดังนี้:
ฟังก์ชั่นที่สอดคล้องกันแนะนำ:
การตัดสินจากผลการทดสอบเมื่อจำนวนข้อมูลเพิ่มขึ้นตัวอย่างเช่นกรณีการใช้รหัส 20,000 กรณีเป็น "สมาร์ท" มากกว่า 10,000 กรณีการใช้รหัส
แนวคิดพื้นฐาน:
ดังที่แสดงด้านล่าง:

Design a User Story Mapping for ${domain} application based on your understanding. Here are the requirements:
1 . Your user story map should include only user tasks to demonstrate how users will interact with the application.
2 . Our user story map should be based on your understanding of the ${domain} application and its users, and should be
designed to address their needs and pain points.
3 . You may use any tools or formats you choose to create your user story map, but it should be easily shareable and
understandable by stakeholders.
4 . Your expression should be more concise and clear.
5 . Your return should be like as follows:
###
User Tasks:
1 . ...
###ตัวอย่างเอาท์พุท:
User Tasks:
1. Browse and search for animations and comics
2. View details of animations and comics
3. Create an account
4. Log in to the account
5. Add animations and comics to favorites
6. Download animations and comics
7. Share animations and comics with friends
8. Rate and review animations and comics
9. Create and upload animations and comics
10. Participate in online forums and discussions
为下面的需求编写用户故事:${domain} 应用的 ${story_name} 功能。 要求如下:
1 . 必须要考虑尽可能考虑各种异常场景,添加更多的 AC。
2 . 你的返回模板如下所示:
###
用户故事:可以选择宝贝出行服务
作为 莉莉妈
我想 在滴滴打车的手机客户端里选择宝贝出行服务
以便于 我能够带宝宝打车出行的时候打到有儿童座椅的车
AC 1: 莉莉妈可以选择宝贝出行服务
假设 xxx
当 xxx
于是 xxx
###ตัวอย่างเอาท์พุท:
用户故事:可以创建和上传动画和漫画
作为一个 Animation and Comics 应用的用户
我想要创建和上传动画和漫画
以便于我可以分享我的作品给其他用户
AC 1: 用户可以创建和上传动画和漫画
假设 用户已经登录到 Animation and Comics 应用
当 用户点击创建和上传动画和漫画按钮
于是 用户可以创建和上传动画和漫画
แนวคิดพื้นฐาน:

src/main PostService(PostRepository, UserRepository, ImageService)
- fields: postRepository:PostRepository, userRepository:UserRepository, userPosts:Set<Post>, imageService:ImageService
- methods: findAll(): List<Post>, addNewPost(Post): Post, saveImageToPost(String, MultipartFile, Post): int
รูปแบบ JSON ที่คาดหวัง:
ตัวอย่าง:
{"instruction":"Implement the method action","input":"com.thoughtworks.go.config.rules.AbstractDirective(DirectiveType, DirectiveType, String, String, String)n- fields: action:String, type:String, resource:String, configErrors:ConfigErrors, directiveType:DirectiveTypen- methods: validate(ValidationContext): void, isInvalid(String, List<String>): boolean, matchesAction(String): boolean, matchesType(Class<? extends Validatable>): boolean, matchesResource(String): boolean, errors(): ConfigErrors, addError(String, String): void, equals(Object): boolean, action(): String, type(): String, resource(): String, hashCode(): int, hasErrors(): boolean, getDirectiveType(): DirectiveType","output":"public abstract class AbstractDirective implements Directive {nn @ConfigAttribute(value = "action", optional = false)n protected String action;nn @ConfigAttribute(value = "type", optional = false)n protected String type;nn @ConfigValuen private String resource;nn private final ConfigErrors configErrors = new ConfigErrors();nn private DirectiveType directiveType;nn public AbstractDirective(DirectiveType allow) {n this.directiveType = allow;n }nn public AbstractDirective(DirectiveType allow, String action, String type, String resource) {n this.directiveType = allow;n this.action = action;n this.type = type;n this.resource = resource;n }nn @Overriden public String action() {n return this.action;n }n}n"}
ข้อมูลจำเพาะรูปแบบ:
包名.类名(类的构造类型)
- fields:成员变量集合(变量名:类型)
- methods:方法抽象集合(方法名(参数类型): 输出类型)
ผลลัพธ์:
com.thoughtworks.go.config.rules.AbstractDirective(DirectiveType, DirectiveType, String, String, String)
- fields: action:String, type:String, resource:String, configErrors:ConfigErrors, directiveType:DirectiveType
- methods: validate(ValidationContext): void, isInvalid(String, List<String>): boolean, matchesAction(String): boolean, matchesType(Class<? extends Validatable>): boolean, matchesResource(String): boolean, errors(): ConfigErrors, addError(String, String): void, equals(Object): boolean, action(): String, type(): String, resource(): String, hashCode(): int, hasErrors(): boolean, getDirectiveType(): DirectiveType
val javaProcessor = JavaProcessor (file.readText())
val shotClass = javaProcessor.toShortClass() ? : return @forEach
javaProcessor
.removePackage()
.removeAllImport()
.removeLicenseInfoBeforeImport()
javaProcessor.splitMethods().forEach { (key, value) ->
CodegenPrompt (
instruction = " Implement the method $key " ,
input = shotClass.toString(),
output = value
). let { prompt ->
val output = Json .encodeToString(prompt)
File ( " $targetPath${key} .json " ).writeText(output)
}
}ไอเดียพื้นฐาน

แนวคิดการวิเคราะห์ไวยากรณ์:
src/main สำหรับแต่ละโครงการ หากไฟล์ทดสอบที่เกี่ยวข้องมีอยู่ในเวลาเดียวกันมันจะถูกดึงลงในชุดข้อมูล org.unitmesh.processor.TestClass(String, Int)
- fields: field1:String, field2:Int
- methods: method1(String, Int): String, method2(): Int
class TestProcessorTest {
@ Test
void test1 () {
}
@ Test
void test2 () {
}
}ในที่สุดข้อมูลที่สร้างขึ้นมีดังนี้:
{"classInfo": "com.thoughtworks.go.security.aesencrypter (AescipherProvider) n- ฟิลด์: encoder: base64.encoder, ตัวถอดรหัส: base64.decoder, cipherprovider: Aescipherprovider, ivprovider: ivprovider Candecrypt (String): Boolean, Encrypt (String): String, Decrypt (String): String, CreateSecretkeyspec (): Secretkeyspec "," TestMethod ":" Public Class Aesencrypttertest { n n n n n n CryptoException { n String Encrypt = Aesencryptter.Encrypt ("P@SSW0RD"); n assertThat (เข้ารหัส). Startswith ("aes"); n assertthat (Encrypt.split (":")).
สำหรับรหัสโดยละเอียดโปรดดู: test-to-code.py
ตัวอย่าง Propt ที่สร้างขึ้นล่าสุดมีดังนี้:
You are a programmer and implementation a method with TDD. Here are the requirements:
1 . According follows class information and tests code to write a method.
2 . Try you best to thinking corner case.
3 . You only return the code, no explain.
class information:
###
io.github.robwin.swagger.test.AbstractContractValidator()
- methods: findExpectedPaths(Swagger, SwaggerAssertionConfig): Map<String,Path>, getPathsIncludingBasePath(Swagger):
Map<String,Path>, getPathsWithPrefix(Swagger, String): Map<String,Path>, isBlankOrSlash(String): boolean
###
test code:
###
/ **
* Tests AbstractContractValidator.
* /
@ RunWith (Enclosed.class)
public class AbstractContractValidatorTest {
/ **
* Tests getPathsIncludingBasePath().
* /
public static class GetPathsIncludingBasePath {
@ Test
public void shouldReturnPathsPrefixedIfBasePathSet() {
// given
Swagger swagger = buildSwaggerFrom("/swagger.json");
// when
Map<String, Path> paths = new DummyValidator().getPathsIncludingBasePath(swagger);
// then
paths.entrySet().forEach(e -> assertThat(e.getKey(), startsWith(swagger.getBasePath())));
}
}
/ **
* Tests findExpectedPaths().
* /
public static class FindExpectedPaths {
}
private static class DummyValidator extends AbstractContractValidator {
}
}
###
ใช้ชุดข้อมูลที่มีอยู่รวมถึง:
อย่างไรก็ตามชุดรหัสทั้งสองนี้ไม่ได้มีคุณภาพสูง แต่มีให้บริการโดยทั่วไป
รูปแบบมีดังนี้:
instruction:
我想查找特定月份(monthly_id)下在某个日期(date)之前的所有费用(expense),以方便了解特定月份内的开销情况。
input:
data class ExpenseEntity(....)
output:
@Query("SELECT * FROM expense WHERE monthly_id = :recurringExpenseId AND date < :beforeDate")
suspend fun getAllExpensesForRecurringExpenseBeforeDate(recurringExpenseId: Long, beforeDate: LocalDate): List<ExpenseEntity>
evaluate("text to kotlin repository with class", "我想查询指定年龄的用户(User)的博客数量。n ###data class User(var age: Int,
val blogId: Int) data class Post(val title: String)###", 0.1, 0.75, 40, 4, 512)
@Query("SELECT COUNT(*) FROM User WHERE age = :age")
abstract fun getBlogCount(age: Int): Long
แนวคิดพื้นฐาน:
instruction และ input output โมฆะตัวอย่าง:
instruction: 介绍一下财通财通宝的基金管理人、基金托管人在履行各自职责的过程中,违反《基金法》?
(一)基金管理人、基金托管人在履行各自职责的过程中,违反《基金法》等法律法规的规定或者基金合同约定, 给基金财产或者基金份额持有人造成损害的,
应当分别对各自的行为依法承担赔偿责任;因共同行为给基金财产或者基金份额持有人造成损害的,应当承担连带赔偿责任,对 损失的赔偿,仅限于直接损失。
但是发生下列情况,当事人可以免责: 1.基金管理人及基金托管人按照中国证监会的规定或当时有效的法律法规的作为或不作为而造成的损失等;
2.基金管理人由于按照基金合同规定的投资原则而行使或不行使其投资权而造成的损失等; 3.不可抗力。
รถไฟ:
เวลาฝึกอบรม:
ความเป็นมาที่เกี่ยวข้อง:
เนื่องจากเป้าหมายของเราคือไม่ปรับโมเดลและสร้างแบบจำลองทั่วไป แต่เพื่อฝึก Lora เพื่อจุดประสงค์เฉพาะ ดังนั้นเราจึงไม่ได้เข้าร่วมข้อมูลใน Stanford Alpaca ดังนั้นเวลาที่ต้องใช้จะสั้นลง ตัวอย่างเช่นรหัสทดสอบ 8000+ ใช้เวลา 1 ชั่วโมงเท่านั้นและเรื่องราวของผู้ใช้ 3400+ ใช้เวลา 25 นาที
ผลการฝึกอบรม (LORA) มีอยู่ที่: https://github.com/unit-mesh/unit-minions/releases/tag/v0.0.1
print(evaluate("write test", """
public Set<String> listFilesUsingJavaIO(String dir) {
return Stream.of(new File(dir).listFiles())
.filter(file -> !file.isDirectory())
.map(File::getName)
.collect(Collectors.toSet());
}
""", 0.1, 0.75, 40, 4, 512))
## Output:
public class ListFilesUsingJavaIOTest {
@Test
public void shouldListFilesUsingJavaIO() {
Set<String> files = ListFilesUsingJavaIO.listFilesUsingJavaIO(new File("dir"));
assertThat(files, containsInAnyOrder("file1", "file2", "file3"));
}
}
ผลการฝึกอบรม (LORA) มีอยู่ที่: https://github.com/unit-mesh/unit-minions/releases/tag/v0.0.2
สังเกต:
--val_set_size 500--val_set_size 500--val_set_size 500ตัวอย่างเอาท์พุท :
print(evaluate("create Agile user story for following topic: ", "购买电影票", 0.1, 0.75, 40, 4, 512))
用户故事:可以购买电影票
作为一个电影票购买者
我想在购买电影票应用中购买电影票
以便于我可以购买电影票
AC 1: 电影票购买者可以在购买电影票应用中购买电影票
假设 电影票购买者已经登录购买电影票应用
当 电影票购买者点击“购买电影票”按钮
于是 电影票购买者可以在购买电影票应用中购买电影票
AC 2: 电影票购买者可以在购买电影票应用中查看购买记录
假设 电影票购买者已经登录购买电影票应用
当 电影票购买者点击“查看购买记录”按钮
于是 电影票购买者可以在购买电影票应用中查看购买记录
AC 3: 电影票购买者可以在购买电影票应用中查看购买记录
假设 电影票购买者已经登录购买电影票应用
当 电影票购买者点击“查看购买记录”按��
ผลการฝึกอบรม (LORA) มีอยู่ที่: https://github.com/unit-mesh/unit-minions/releases/tag/v0.0.3
ตัวอย่างเอาท์พุท :
print(evaluate("Implement the method rmFiles", "FileUtils:", 0.1, 0.75, 40, 4, 512))
public class FileUtils {
private FileUtils() {
}
public static void rmFiles(String path) {
File dir = new File(path);
File[] files = dir.listFiles();
if (files != null) {
for (File file : files) {
if (file.isFile()) {
file.delete();
} else if (file.isDirectory()) {
FileUtils.rmFiles(file.getAbsolutePath());
}
}
}
}
}
สคริปต์การแปลง: รหัส/ข้อความถึง sql.py
โดยตรงจาก: ชุดข้อมูล/sql/sql-train.jsonl
ตัวอย่างเอาท์พุท :
evaluate("text to sql", "谁是最美丽的人", 0.1, 0.75, 40, 4, 512)
evaluate("text to sql", "小明今年几岁", 0.1, 0.75, 40, 4, 512)
evaluate("text to sql", "What hand guard system is used with a gas piston commando?", 0.1, 0.75, 40, 4, 512)
รถไฟ:
ตัวอย่างที่ 1:
evaluate("Instruction: 创建用户故事nInput: 电影网站: 查看订单详情 nAnswer:")
Instruction: 创建用户故事
Input: 电影网站: 查看订单详情
Answer:
用户故事:可以查看订单详情
作为一个电影网站的用户
我想查看订单详情
以便于我可以了解订单的详细信息,如订单号、订单状态、订单内容等。
AC 1: 用户可以查看订单详情
假设 用户已经登录
当 用户点击查看订单详情按钮
于是 用户可以查看订单详情,包括订单号、订单状态、订单内容等。
AC 2: 用户可以查看订单详情
假设 用户没有登录
当 用户点击查看订单详情按钮
于是 用户被要求先登录,然后才能查看订单详情,包括订单号、订单状态、订单内容等。
ตัวอย่างที่ 2:
evaluate("Instruction: 创建用户故事nInput: 团购网站:用户注册nAnswer:")
Instruction: 创建用户故事
Input: 团购网站:用户注册
Answer:
团购网站的用户注册故事:
作为一个团购网站的用户
我想注册一个团购网站的用户账号
以便于我可以使用团购服务,如购买商品、服务等。
AC 1: 团购网站的用户注册账号
假设 用户输入了注册信息
当 用户提交注册信息
于是 用户可以成功注册一个团购网站的用户账号
AC 2: 团购网站的用户注册账号
假设 用户输入了错误的注册信息
当 用户提交注册信息
于是 用户可以被提示输入正确的注册信息,并重新提交注册信息