From d4a1944c5ffdf44b9ba1edb284ed924d841effb2 Mon Sep 17 00:00:00 2001 From: John Christopher McAlpine Date: Sat, 11 Mar 2023 19:01:35 -0500 Subject: [PATCH] add deps to opam file and instructions to README --- README.md | 12 +++++++----- openai.opam | 12 +++++++++++- 2 files changed, 18 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index 7a47ccd..375505c 100644 --- a/README.md +++ b/README.md @@ -9,19 +9,21 @@ This OCaml package is automatically generated by the [OpenAPI Generator](https:/ ## Requirements. -OCaml 4.x +OCaml >4 ## Installation Please run the following commands to build the package `openapi`: +I haven't bothered to put this in the public OPAM repo just yet since I'm not sure if it's ready for prime time. + ```sh -opam install ppx_deriving_yojson cohttp ppx_deriving cohttp-lwt-unix pin ocaml-migrate-parsetree 1.3.1 -eval $(opam env) -dune build +opam pin add openai . ``` ## Getting Started -TODO +Your openai API key should go in the `OPENAI_API_KEY` environment variable. + +Please see the example for basic usage of the chat completion API. Other API's are not dissimilar. diff --git a/openai.opam b/openai.opam index 0419953..412bfc0 100644 --- a/openai.opam +++ b/openai.opam @@ -14,5 +14,15 @@ license: "" homepage: "" bug-reports: "" dev-repo: "" -depends: [ "ocaml" "ocamlfind" ] +depends: [ + "ocaml" + "ocamlfind" + "ppx_deriving_yojson" + "ppx_deriving.show" + "ppx_deriving.eq" + "ppx_deriving.ord" + "ppx_deriving.std" + "ez_api.ppx" + "lwt_ppx" +] build: ["dune" "build" "-p" name] \ No newline at end of file