You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+47Lines changed: 47 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -10,6 +10,7 @@ Meta AI is running Llama 3 LLM.
10
10
11
11
## Features
12
12
-**Prompt AI**: Send a message to the AI and get a response from Llama 3.
13
+
-**Image Generation**: Generate images using the AI. (Only for FB authenticated users)
13
14
-**Get Up To Date Information**: Get the latest information from the AI thanks to its connection to the internet.
14
15
-**Get Sources**: Get the sources of the information provided by the AI.
15
16
-**Streaming**: Stream the AI's response in real-time or get the final response.
@@ -124,3 +125,49 @@ for r in response:
124
125
...
125
126
{'message': "The Golden State Warriors' last game was against the Sacramento Kings on April 16, 2024, at the Golden 1 Center in Sacramento, California. The Kings won the game with a score of 118-94, with the Warriors scoring 22 points in the first quarter, 28 in the second, 26 in the third and 18 in the fourth quarter ¹.\n", 'sources': [{'link': 'https://sportradar.com/', 'title': 'Game Info of NBA from sportradar.com'}]}
126
127
```
128
+
129
+
**Generate Image**:
130
+
131
+
By default image generation is only available for FB authenticated users. If you go on https://www.meta.ai/ , and ask the AI to generate an image, you will be prompted to authenticate with Facebook.
132
+
So if you want to generate images using this library, you need to authenticate using your FB credentials.
133
+
134
+
**Note**: There seems to be higher rate limits for authenticated users. So only authenticate to generate images.
135
+
136
+
```python
137
+
from meta_ai_api import MetaAI
138
+
ai = MetaAI(fb_email="your_fb_email", fb_password="your_fb_password")
139
+
resp = ai.prompt(message="Generate an image of a tech CEO")
0 commit comments