Skip to content

Commit c506691

Browse files
committed
README: add language to code blocks
1 parent 2418edf commit c506691

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

README.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -724,7 +724,7 @@ response.dig("choices", 0, "message", "content")
724724

725725
You can also capture the events for a job:
726726

727-
```
727+
```ruby
728728
client.finetunes.list_events(id: fine_tune_id)
729729
```
730730

@@ -916,7 +916,7 @@ response = client.assistants.modify(
916916

917917
You can delete assistants:
918918

919-
```
919+
```ruby
920920
client.assistants.delete(id: assistant_id)
921921
```
922922

@@ -985,7 +985,7 @@ client.runs.create(thread_id: thread_id,
985985

986986
To get the status of a Run:
987987

988-
```
988+
```ruby
989989
response = client.runs.retrieve(id: run_id, thread_id: thread_id)
990990
status = response['status']
991991
```
@@ -1077,7 +1077,7 @@ thread_id = response['thread_id']
10771077

10781078
You can include images in a thread and they will be described & read by the LLM. In this example I'm using [this file](https://upload.wikimedia.org/wikipedia/commons/7/70/Example.png):
10791079

1080-
```
1080+
```ruby
10811081
require "openai"
10821082

10831083
# Make a client
@@ -1188,7 +1188,7 @@ An example spec can be found [here](https://github.com/alexrudall/ruby-openai/bl
11881188

11891189
Here's how to get the chunks used in a file search. In this example I'm using [this file](https://css4.pub/2015/textbook/somatosensory.pdf):
11901190

1191-
```
1191+
```ruby
11921192
require "openai"
11931193

11941194
# Make a client
@@ -1405,7 +1405,7 @@ File.binwrite('demo.mp3', response)
14051405

14061406
HTTP errors can be caught like this:
14071407

1408-
```
1408+
```ruby
14091409
begin
14101410
OpenAI::Client.new.models.retrieve(id: "gpt-4o")
14111411
rescue Faraday::Error => e

0 commit comments

Comments
 (0)