Skip to content

Commit 7afa19c

Browse files
committed
cleanup
1 parent 8f197a6 commit 7afa19c

File tree

1 file changed

+13
-26
lines changed

1 file changed

+13
-26
lines changed

README.md

+13-26
Original file line numberDiff line numberDiff line change
@@ -1,46 +1,33 @@
11
# Promptr
22

3-
Promptr is a CLI tool that lets you use plain English to instruct OpenAI LLM models to make changes to your codebase. <br /><br />
3+
Promptr is a CLI tool that lets you use plain English to instruct OpenAI LLM models to make changes to your codebase. Changes are applied directly to the files that you reference from your prompt.<br /><br />
44
## Usage
55

66
`promptr [options] -p "your instructions" <file1> <file2> <file3> ...`
7-
8-
<br />
97
<br />
108

11-
## Examples
12-
__Cleanup the code in a file__
13-
```bash
14-
$ promptr -p "Cleanup the code in src/index.js"
15-
```
16-
Promptr recognizes that the file `src/index.js` is referenced in the prompt, so the content of `src/index.js` is sent to the model along with the user's prompt.
17-
<br />The model's response is automatically applied to the relevant files.
18-
<br /><br />
19-
<br />
9+
I've found this to be a good workflow:
10+
- Commit any changes, so you have a clean working area.
11+
- Author your prompt in a file. The prompt should be specific clear instructions.
12+
- Make sure your prompt contains the relative paths of any files that are relevant to your instructions.
13+
- Use Promptr to execute your prompt. Provide the path to your prompt file using the `-p` option:
14+
`promptr -p my_prompt.txt`
2015

21-
__Alphabetize the methods in all of the javascript files__
22-
```bash
23-
$ promptr -p "Alphabetize the method names in all of these files" $(git ls-tree -r --name-only HEAD | grep ".js" | tr '\n' ' ')
24-
```
25-
The command above uses `git-tree`, `grep`, and `tr` to pass a list of javascript file paths to promptr.
16+
Promptr will apply the model's code directly to your files. Use your favorite git UI to inspect the results.
2617

2718
<br /><br />
2819

20+
<br />
21+
<br />
22+
23+
## Examples
24+
2925
The PR's below are good examples of what can be accomplished using Promptr. You can find links to the individual commits and the prompts that created them in the PR descriptions.
3026
- https://github.com/ferrislucas/promptr/pull/38
3127
- https://github.com/ferrislucas/promptr/pull/41
3228
<br /><br />
3329

34-
I've found this to be a good workflow:
35-
- Commit any changes, so you have a clean working area.
36-
- Author your prompt in a file. The prompt should be specific clear instructions.
37-
- Make sure your prompt contains the relative paths of any files that are relevant to your instructions.
38-
- Use Promptr to execute your prompt. Provide the path to your prompt file using the `-p` option:
39-
`promptr -p my_prompt.txt`
40-
41-
Promptr applies the model's response to your files. Use your favorite git UI to inspect the results.
4230

43-
<br /><br />
4431
## Templating
4532

4633
Promptr supports templating using [liquidjs](https://liquidjs.com/), which allows users to incorporate templating commands within their prompt files. This feature enhances the flexibility and reusability of prompts, especially when working on larger projects with repetitive patterns or standards.

0 commit comments

Comments
 (0)