You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
by [Juan Altmayer Pizzorno](https://jaltmayerpizzorno.github.io) and [Emery Berger](https://emeryberger.com)
6
8
at UMass Amherst's [PLASMA lab](https://plasma-umass.org/).
@@ -19,36 +21,41 @@ To generate tests, it first measures your suite's coverage using [SlipCover](htt
19
21
It then selects portions of the code that need more testing (that is, code that is uncovered).
20
22
CoverUp then engages in a conversation with an [LLM](https://en.wikipedia.org/wiki/Large_language_model),
21
23
prompting for tests, checking the results to verify that they run and increase coverage (again using SlipCover), and re-prompting for adjustments as necessary.
22
-
Finally, CoverUp checks that the new tests integrate well, attempting to resolve any issues it finds.
24
+
Finally, CoverUp optionally checks that the new tests integrate well, attempting to resolve any issues it finds.
23
25
24
-
## Installing CoverUp
26
+
For technical details and a complete evaluation, see our arXiv paper, [_CoverUp: Coverage-Guided LLM-Based Test Generation_](https://arxiv.org/abs/2403.16218) ([PDF](https://github.com/plasma-umass/CoverUp/blob/main/CoverUp-arxiv-2403.16218.pdf)).
25
27
28
+
## Installing CoverUp
26
29
CoverUp is available from PyPI, so you can install simply with
27
30
```shell
28
31
$ python3 -m pip install coverup
29
32
```
30
33
31
-
Currently, CoverUp requires an [OpenAI account](https://platform.openai.com/signup) to run (we plan to support local models in the near future).
32
-
Your account will also need to have a [positive balance](https://platform.openai.com/account/usage).
33
-
Create an [API key](https://platform.openai.com/api-keys) and store its "secret key" (usually a
34
+
### LLM model access
35
+
CoverUp can be used with OpenAI, Anthropic or AWS Bedrock models; it requires that the
36
+
access details be defined as shell environment variables: `OPENAI_API_KEY`,
37
+
`ANTHROPIC_API_KEY` or `AWS_ACCESS_KEY_ID`/`AWS_SECRET_ACCESS_KEY`/`AWS_REGION_NAME`, respectively.
38
+
39
+
For example, for OpenAI you would create an [account](https://platform.openai.com/signup), ensure
40
+
it has a [positive balance](https://platform.openai.com/account/usage) and then create an
41
+
an [API key](https://platform.openai.com/api-keys), storing its "secret key" (usually a
34
42
string starting with `sk-`) in an environment variable named `OPENAI_API_KEY`:
35
43
```shell
36
44
$ export OPENAI_API_KEY=<...your-api-key...>
37
45
```
38
46
39
47
## Using CoverUp
40
-
41
-
If your module's source code is in `src` and your tests in `tests`, you can run CoverUp as
48
+
If your module is named `mymod`, its sources are under `src` and the tests under `tests`, you can run CoverUp as
0 commit comments