A powerful AI-driven tool that transforms any topic into engaging social media content for LinkedIn, Twitter, and Instagram. The app researches your topic using web search and generates platform-optimized posts using Google's Gemini AI.
- Frontend: https://cheerful-khapse-605f71.netlify.app/
- Backend API: https://ai-post-generator-agent.onrender.com
- AI-Powered Research: Automatically searches the web for latest information about your topic
- Multi-Platform Content: Generates optimized posts for LinkedIn, Twitter, and Instagram
- Smart Summarization: Creates concise research summaries before generating posts
- Platform-Specific Optimization:
- LinkedIn: Professional and informative tone
- Twitter: Under 280 characters, punchy and engaging
- Instagram: Friendly tone with emojis
- Beautiful UI: Modern glassmorphism design with smooth animations
- One-Click Copy: Easy clipboard functionality for all generated posts
- Responsive Design: Works seamlessly on desktop and mobile devices
- HTML5 with modern semantic structure
- CSS3 with advanced animations and glassmorphism effects
- Vanilla JavaScript for interactive functionality
- Responsive Design with mobile-first approach
- Node.js with Express.js framework
- Google Gemini AI API for content generation
- Tavily Search API for web research
- CORS enabled for cross-origin requests
- Node.js (v14 or higher)
- npm or yarn package manager
- Google Gemini API key
- Tavily Search API key
Create a .env file in your backend directory:
GOOGLE_API_KEY=your_google_gemini_api_key_here
TAVILY_API_KEY=your_tavily_search_api_key_here
PORT=3000- Clone the repository:
git clone https://github.com/Jitugandhare/Ai-Post-Generator-Agent.git
cd Ai-Post-Generator-Agent/agent- Install dependencies:
npm install- Required packages:
npm install express axios body-parser cors dotenv- Start the server:
npm start
# or for development
node index.jsThe backend will be available at http://localhost:3000
- The frontend is a single HTML file that can be opened directly in a browser
- For development, you can use a local server:
# Using Python
python -m http.server 8000
# Using Node.js http-server
npx http-serverGenerates social media posts for a given topic.
Request Body:
{
"topic": "Latest AI trends"
}Response:
{
"summary": "Research summary with key bullet points...",
"rawPosts": {
"linkedin": "Professional LinkedIn post content...",
"twitter": "Engaging Twitter post content...",
"instagram": "Fun Instagram caption with emojis..."
},
"polishedPosts": "Refined and optimized posts..."
}- Glassmorphism UI with backdrop blur effects
- Animated particles floating in the background
- Platform-specific colors for each social media card
- Smooth hover effects and micro-interactions
- Loading states with spinner animations
- Error handling with user-friendly messages
- Auto-focus on topic input field
- Enter key support for quick post generation
- Copy to clipboard functionality with visual feedback
- Responsive grid layout that adapts to screen size
- Input: User enters a topic they want to create posts about
- Research: Backend searches the web using Tavily API for latest information
- Summarization: Google Gemini AI creates a concise summary of findings
- Generation: AI generates platform-specific posts based on the research
- Polish: Posts are refined to match each platform's optimal tone and format
- Display: Frontend shows the research summary and all generated posts
- Copy: Users can easily copy posts to their clipboard for immediate use
- Visit Google AI Studio
- Create a new API key
- Add it to your
.envfile asGOOGLE_API_KEY
- Sign up at Tavily
- Get your API key from the dashboard
- Add it to your
.envfile asTAVILY_API_KEY
- Professional tone and language
- Informative and business-focused content
- Suitable for professional networking
- Maximum 280 characters
- Engaging and punchy content
- Uses relevant hashtags when appropriate
- Casual and friendly tone
- Emoji usage for visual appeal
- Engaging captions that encourage interaction
- Connect your GitHub repository to Netlify
- Deploy the
index.htmlfile - The frontend is now live!
- Connect your GitHub repository to Render
- Set up environment variables in Render dashboard
- Deploy the Node.js application
- Update the frontend API endpoint to your deployed backend URL
- Fork the repository
- Create your feature branch (
git checkout -b feature/AmazingFeature) - Commit your changes (
git commit -m 'Add some AmazingFeature') - Push to the branch (
git push origin feature/AmazingFeature) - Open a Pull Request
This project is licensed under the MIT License - see the LICENSE file for details.
- Google Gemini AI for powerful content generation
- Tavily for comprehensive web search capabilities
- The open-source community for inspiration and tools
If you encounter any issues or have questions, please:
- Check the existing issues on GitHub
- Create a new issue with detailed information
- Include error messages and steps to reproduce
β Star this repository if you found it helpful! β