diff --git a/README.md b/README.md index c37ead4..caeeedf 100644 --- a/README.md +++ b/README.md @@ -1,43 +1,43 @@ # Chat-DBT -## MVP +## Usage -- [ ] Implement the options into the web interface - - [ ] confirm - - [ ] automatic corrections - - [ ] keep-context -- [ ] Use `inquirer` instead of `prompts` (has an editor prompt, a yes/no/other prompt, and seems easier to tweak to implement history) -- [ ] Arrow up/down to get the previous queries - - [ ] CLI - - [ ] Web UI: https://mantine.dev/core/autocomplete/ -- [ ] Editable SQL query before confirmation (and keep the modifications in the history) -- [ ] Editable SQL query after an error (and keep the modifications in the history) -- [ ] Changesets + publish -- [ ] Complete this readme +```sh +npx chat-dbt [options] +npx chat-dbt --help +``` + +### Command-line interface + +```sh +npx chat-dbt --database postgres://user:password@localhost:5432/postgres --key [your-openai-key] --org [your-openai-org] +``` -## Post-release +### Web interface -Library -Stats eg time per request, tokens used, etc +```sh +npx chat-dbt web --database postgres://user:password@localhost:5432/postgres --key [your-openai-key] --org [your-openai-org] +``` -- [ ] Web interface in dark/light mode -- [ ] Add CI tests for both the CLI and the web interface -- [ ] Nice to have (but complicated): when the context is preserved, allow queries from previous data e.g. "translate the previous result into french" -- [ ] `--hide-sql` -- [ ] `--hide-result` -- [ ] Input from stdin/output to stdout (combined with the above) -- [ ] Output sql (on success) to file -- [ ] Output result to file -- [ ] Verbose level, timestamps etc -- [ ] Comment the code +### Use a `.env` file + + + +### Use another OpenAI model -## Done + -- [x] Change the terminology "retries" to "ask-corrections" -- [x] Add a `--confirm` option to prompt the user before executing the query -- [x] Add a `--model` option to choose the OpenAI model -- [x] Spinner -- [x] Manual requests for corrections +### Ask for confirmation before executing the SQL query + + + +### Keep context between queries + + + +### Change the format of the result + + ## Development @@ -66,4 +66,34 @@ pnpm run dev:web ### Use the CLI -TODO nodemon + + +## Roadmap + +- [ ] Implement the options into the web interface + - [ ] confirm + - [ ] automatic corrections + - [ ] keep-context +- [ ] Use `inquirer` instead of `prompts` (has an editor prompt, a yes/no/other prompt, and seems easier to tweak to implement history) +- [ ] Arrow up/down to get the previous queries + - [ ] CLI + - [ ] Web UI: https://mantine.dev/core/autocomplete/ +- [ ] Editable SQL query before confirmation (and keep the modifications in the history) +- [ ] Editable SQL query after an error (and keep the modifications in the history) +- [ ] Changesets + publish +- [ ] Complete this readme + +### Post-release + +- [ ] Use the npm package as a library +- [ ] Statistics e.g. time per request, tokens used, etc +- [ ] Web interface in dark/light mode +- [ ] Add CI tests for both the CLI and the web interface +- [ ] Nice to have (but complicated): when the context is preserved, allow queries from previous data e.g. "translate the previous result into french" +- [ ] `--hide-sql` +- [ ] `--hide-result` +- [ ] Input from stdin/output to stdout (combined with the above) +- [ ] Output sql (on success) to file +- [ ] Output result to file +- [ ] Verbose level, timestamps etc +- [ ] Comment the code diff --git a/shared/README.md b/shared/README.md new file mode 100644 index 0000000..b785c03 --- /dev/null +++ b/shared/README.md @@ -0,0 +1,3 @@ +# Shared code + +Code used by both the CLI and the Web interface