A GPT-based autonomous multi-agent AI app using Next.js, LangChain.js, and LangGraph.js to research and recommend Instagram posts based on user queries and personalities extracted from user’s historical Instagram data via Instagram Basic Display API.
https://github.com/user-attachments/assets/ac1850e2-0119-4531-9f9c-2422ac40f48d
First give this repo a ✨✨ star ✨✨ for good luck. 😉
Since GPT-Instagram works with your historical Instagram Posts Information to extract your style you need to follow this guide to get your Instagram Access Token to extract data via Instagram Basic Display API.
Follow these guide to setup your Facebook App to get access to Instagram Basic Display API.
You can generate Your token from facebook app dashboard at now at 'Instagram Basic Display > Basic Display'. It should look something like this.
Click on 'Generate Token' to get your IG Access Token.
.env file. env.example explains it pretty well.| KEY | DESCRIPTION |
|---|---|
| OPENAI_API_KEY | Your OpenAI API key from https://openai.com/index/openai-api/ |
| TAVILY_API_KEY | Tavily Search API key from https://tavily.com/#api |
| DATABASE_URL | Postgres DB URL |
| IG_ACCESS_TOKEN | Your Instagram Access Token |
| NEXT_PUBLIC_BASE_URL | Deployment URL(only https to work with Instagram API) |
Since GPT-Instagram uses Drizzle ORM make sure to run yarn then yarn generate & yarn migrate before you run the project to create your DB.
Finally run yarn dev to run the Application.
This app was done for Tavily AI Intern Application. This is just a toy project don't expect any further updates.
$ claude mcp add gpt-instagram \
-- python -m otcore.mcp_server <graph>