Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
brunneis authored Oct 11, 2024
1 parent 9a1b826 commit d2d41d9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,13 +42,13 @@ for chunk in grok.stream('Who are you?', model_id='grok-2'):
print(chunk, end='', flush=True)
```

## Generate Image
## Generate Images

### JPEG binary
```python
image_data = grok.image('An astronaut riding a horse.')

with open('sunset.jpg', 'wb') as f:
with open('image.jpg', 'wb') as f:
f.write(image_data)
```

Expand Down

0 comments on commit d2d41d9

Please sign in to comment.