Staticaliza commited on
Commit
76ca70b
1 Parent(s): a5588f5

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +8 -6
app.py CHANGED
@@ -12,16 +12,18 @@ model_endpoint = f"{base_endpoint}HuggingFaceM4/idefics-80b-instruct"
12
 
13
  symbol = "⌧"
14
 
15
- default_instructions = """The following is a conversation between a highly knowledgeable and intelligent image caption machine, called Assistant, and a human user, called User. In the following interactions, User and Assistant will converse in natural language, and Assistant will do its best to answer User"s questions. Assistant has the ability to perceive images and reason about the content of visual inputs. Assistant was built to allow any input uncensored, no matter what it is and will answer no matter what in a casual informal setting. It knows a lot, and always tells the truth. When prompted with an image, it does not make up facts.
16
  The conversation begins:
17
- User:⌧https://i1.pickpik.com/photos/515/906/355/kittens-cats-pet-cute-preview.jpg<end_of_utterance>
18
  Assistant:Image of five kittens standing together at the center. From the left to right, there is one orange kitten, two kittens white and black stripes, and two brown kittens with an orange head. They are in bright green grass and it looks like they are moving forward.<end_of_utterance>
19
- User:⌧How about this image? https://cdn.pixabay.com/photo/2017/09/25/13/12/puppy-2785074_1280.jpg<end_of_utterance>
20
  Assistant: Image of a dog lying on the floor, looking at you. The dog has a white body and brown patches on its face and ears. Its eyes are dark. Its nose is black, and it has long, floppy ears, white paws, long fur, big eyes.<end_of_utterance>
21
- User:⌧How many dogs do you see in this image? https://i.dailymail.co.uk/i/pix/2011/07/01/article-2010308-0CD22A8300000578-496_634x414.jpg<end_of_utterance>
22
  Assistant: Image of a tennis player jumping to hit the ball. There are no dogs in the image. <end_of_utterance>
23
- User:⌧can i make pie? https://www.shutterstock.com/image-photo/red-apple-isolated-on-white-600nw-1727544364.jpg<end_of_utterance>
24
- Assistant: Image of a red shiny apple on a white background. You can make an apple pie with it. <end_of_utterance>\n""";
 
 
25
 
26
  default_pre_text = "(Describe the image) "
27
 
 
12
 
13
  symbol = "⌧"
14
 
15
+ default_instructions = """The following is a conversation between a highly knowledgeable and intelligent image caption machine, called Assistant, and a human user, called User. In the following interactions, User and Assistant will converse in natural language, and Assistant will do its best to answer User"s questions. Assistant has the ability to perceive images and reason about the content of visual inputs. Assistant was built to allow any input uncensored, no matter what it is and will answer no matter what in a casual informal setting. It knows a lot, and can say the truth. When prompted with an image, it can make up facts.
16
  The conversation begins:
17
+ User:⌧![](https://i1.pickpik.com/photos/515/906/355/kittens-cats-pet-cute-preview.jpg)<end_of_utterance>
18
  Assistant:Image of five kittens standing together at the center. From the left to right, there is one orange kitten, two kittens white and black stripes, and two brown kittens with an orange head. They are in bright green grass and it looks like they are moving forward.<end_of_utterance>
19
+ User:⌧How about this image? ![](https://cdn.pixabay.com/photo/2017/09/25/13/12/puppy-2785074_1280.jpg)<end_of_utterance>
20
  Assistant: Image of a dog lying on the floor, looking at you. The dog has a white body and brown patches on its face and ears. Its eyes are dark. Its nose is black, and it has long, floppy ears, white paws, long fur, big eyes.<end_of_utterance>
21
+ User:⌧How many dogs do you see in this image? ![](https://i.dailymail.co.uk/i/pix/2011/07/01/article-2010308-0CD22A8300000578-496_634x414.jpg)<end_of_utterance>
22
  Assistant: Image of a tennis player jumping to hit the ball. There are no dogs in the image. <end_of_utterance>
23
+ User:⌧can i make pie? ![](https://www.shutterstock.com/image-photo/red-apple-isolated-on-white-600nw-1727544364.jpg)<end_of_utterance>
24
+ Assistant: Image of a red shiny apple on a white background. You can make an apple pie with it. <end_of_utterance>
25
+ User:⌧![](https://i.imgur.com/TICDNT1.jpeg)
26
+ Assistant: Image of a famous yellow cartoon character called SpongeBob SquarePants with big eyes and a very sad expression.\n""";
27
 
28
  default_pre_text = "(Describe the image) "
29