Skip to content

Commit 6991c82

Browse files
committed
Update README
1 parent 8e9d281 commit 6991c82

File tree

1 file changed

+29
-1
lines changed

1 file changed

+29
-1
lines changed

README.md

Lines changed: 29 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
[![License: AGPL v3](https://img.shields.io/badge/License-AGPL%20v3-blue.svg)](https://www.gnu.org/licenses/agpl-3.0)
44

5-
`ottodocs` is a command-line tool written in Go that uses GPT-3 to automatically generate or add inline documentation for your code. It can parse a git repository or an individual file and create markdown documentation or add inline comments. The tool requires an OpenAI API key to function.
5+
`ottodocs` is a command-line tool written in Go that uses GPT-3 (and GPT-4 once the API is available) to automatically generate or add inline and markdown documentation for your code. It can parse a git repository or an individual file and create markdown documentation or add inline comments. The tool requires an [OpenAI API key](https://platform.openai.com/account/api-keys) to function.
66

77
`ottodocs` utilizes the `just` command runner for building and running tasks, making it easy to use and maintain.
88

@@ -19,6 +19,34 @@ cd ottodocs
1919
just build # will output binary to bin/otto. Copy the file to a directory in your PATH
2020
```
2121

22+
## Getting Started
23+
24+
First, you need to create an OpenAI API Key. If you do not already have an OpenAI account, you can create a new one and get some free credits to try it out. Once you have an account, you can create an API key by going to the [API Keys tab](https://platform.openai.com/account/api-keys) in your account settings.
25+
26+
Once you have an API key, you can log in to ottodocs by running the following command:
27+
28+
```sh
29+
otto login
30+
```
31+
32+
Optionally you can pass the API key as an argument to the command:
33+
34+
```sh
35+
otto login -p $OPENAI_API_KEY
36+
```
37+
38+
Once that is complete, you can start generating documentation by running the following command:
39+
40+
```sh
41+
otto docs <path to repo or file>
42+
```
43+
44+
Or for a single file, you can run:
45+
46+
```sh
47+
otto doc -f <path to file>
48+
```
49+
2250
## Usage
2351

2452
For detailed usage instructions, please refer to the [documentation](docs/otto.md).

0 commit comments

Comments
 (0)