parent
694100e2fb
commit
0d0e5e5dc3
@ -0,0 +1,8 @@
|
|||||||
|
from swarms.models import Dalle3
|
||||||
|
|
||||||
|
dalle3 = Dalle3(
|
||||||
|
openai_api_key=""
|
||||||
|
)
|
||||||
|
task = "A painting of a dog"
|
||||||
|
image_url = dalle3(task)
|
||||||
|
print(image_url)
|
@ -0,0 +1,12 @@
|
|||||||
|
from swarms.models.gpt4v import GPT4Vision
|
||||||
|
|
||||||
|
|
||||||
|
gpt4vision = GPT4Vision(openai_api_key="")
|
||||||
|
|
||||||
|
img = "https://upload.wikimedia.org/wikipedia/commons/thumb/0/0d/VFPt_Solenoid_correct2.svg/640px-VFPt_Solenoid_correct2.svg.png"
|
||||||
|
|
||||||
|
task = "What is this image"
|
||||||
|
|
||||||
|
answer = gpt4vision.run(task, img)
|
||||||
|
|
||||||
|
print(answer)
|
@ -1,7 +0,0 @@
|
|||||||
from swarms.models.gpt4v import GPT4Vision
|
|
||||||
|
|
||||||
gpt4vision = GPT4Vision(api_key="")
|
|
||||||
task = "What is the following image about?"
|
|
||||||
img = "https://cdn.openai.com/dall-e/encoded/feats/feats_01J9J5ZKJZJY9.png"
|
|
||||||
|
|
||||||
answer = gpt4vision.run(task, img)
|
|
Loading…
Reference in new issue