闲社服务运行正常AI智能体自动化平台
中文
语言 / Language简体中文SelectedEnglish

选择显示语言

TestGPT-7B

maple77/TestGPT-7B

发布机构maple77

下载访问条件魔搭来源

模型介绍(Introduction) TestGPT-7B,是蚂蚁研发的测试域大模型。该模型以CodeLlama-7B为基座,进行了测试领域下游任务的微调,包含多语言测试用例生成、测试用例Assert补全。 TestGPT-7B, developed by Ant Group, is a large-scale model designed for software quality domains. Built upon the foundation of CodeLlama

文字对话
模型详情

模型介绍

中文整理

模型介绍(Introduction)

TestGPT-7B,是蚂蚁研发的测试域大模型。该模型以CodeLlama-7B为基座,进行了测试领域下游任务的微调,包含多语言测试用例生成、测试用例Assert补全。

TestGPT-7B, developed by Ant Group, is a large-scale model designed for software quality domains. Built upon the foundation of CodeLlama-7B, this model has undergone fine-tuning for downstream tasks, including multi-language test case generation and test case assertion completion.

依赖项(Requirements)

python>=3.8

pytorch>=2.0.0

CUDA 11.4

transformers==4.33.2

WEB服务

github: https://github.com/codefuse-ai/Test-Agent

cd Test-Agent

pip install -r requirements.txt

启动controller: python -m chat.server.controller

启动模型(如果不是M,英伟达选cuda): python -m chat.server.model worker --model-path ../models/huggingface/llm/codefuse-ai/TestGPT-7B --device mps

启动web服务: python -m chat.server.gradio testgpt

打开页面: http://127.0.0.1:7860

我本地试了一下,不是特别好用;可能这种代码大模型还是直接IDE插件比较直接

快速使用(QuickStart)

下面我们展示使用TestGPT-7B模型,进行测试用例生成、测试用例Assert补全的示例:

Below are examples of test case generation and test case assertion completion using the TestGPT-7B model:

Python\ndef add(lst):\n return sum([lst[i] for i in range(1, len(lst), 2) if lst[i]%2 == 0])\njava\n' \

# 'public class BooleanUtils {\n ' \

# 'public static boolean and(final boolean... array) {\n ' \

# 'ObjectUtils.requireNonEmpty(array, "array");\n ' \

# 'for (final boolean element : array) {\n ' \

# 'if (!element) {\n return false;\n }\n }\n ' \

# 'return true;\n }\n}\njava\n' \

# '@Test\npublic void testAnd withAllTrueInputs() {\n ' \

# 'boolean[] input = new boolean[] {true, true, true};\n ' \

# 'boolean result = BooleanUtils.and(input);\n}\n\n@Test\npublic void testAnd withOneFalseInput() {\n ' \

# 'boolean[] input = new boolean[] {true, false, true};\n ' \

# 'boolean result = BooleanUtils.and(input);\n}\n' \

# '

优先采用原作者提供的中文模型卡片;仅有英文说明时由闲社AI翻译整理。重要参数、许可证和商用范围请以原文为准。

你将获得什么

完整仓库方式包含该固定版本中的权重、配置、分词器及说明文件;指定版本方式只下载所选文件或整组分片。多模态模型的投影文件、配置等依赖,请按作者说明配齐。

完整仓库可能包含多个权重格式,因此需要的磁盘空间可能大于单一格式的模型大小。下载文件不等于完成模型部署。

使用前须知

运行环境

运行模型需要的设备、工具与依赖,以原作者说明为准。

授权范围

是否允许商用、修改和分发,请查看模型许可证。

闲社提供资料与镜像下载方法,不代表已运行模型或完成安全审计。下载的代码应先检查,再执行。

返回顶部