From 8d3d3df1dd902aca9be3da9a02f4d1e3ba9c4a6b Mon Sep 17 00:00:00 2001 From: Varshith Date: Sun, 28 Jul 2024 16:14:27 +0530 Subject: [PATCH] update readme --- README.md | 26 +++++++++++++++++++++++++- 1 file changed, 25 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index d4284e19..2054fd22 100644 --- a/README.md +++ b/README.md @@ -111,7 +111,7 @@ The native way to access models running on exo is using the exo library with pee exo starts a ChatGPT-like WebUI (powered by [tinygrad tinychat](https://github.com/tinygrad/tinygrad/tree/master/examples/tinychat)) on http://localhost:8000 -For developers, exo also starts a ChatGPT-compatible API endpoint on http://localhost:8000/v1/chat/completions. Example with curl: +For developers, exo also starts a ChatGPT-compatible API endpoint on http://localhost:8000/v1/chat/completions. Example with curls: ```sh curl http://localhost:8000/v1/chat/completions \ @@ -123,6 +123,30 @@ curl http://localhost:8000/v1/chat/completions \ }' ``` +```sh +curl http://localhost:8000/v1/chat/completions \ + -H "Content-Type: application/json" \ + -d '{ + "model": "llava-1.5-7b-hf", + "messages": [ + { + "role": "user", + "content": [ + { + "type": "text", + "text": "What are these?" + }, + { + "type": "image", + "image": "http://images.cocodataset.org/val2017/000000039769.jpg" + } + ] + } + ], + "temperature": 0.0 + }' +``` + ## Debugging Enable debug logs with the DEBUG environment variable (0-9).