Spaces:
Runtime error
๐ค Agentic AI Blog Generator
This is an Agentic AI-powered blog generation system built using the uv framework and FastAPI. It supports multilingual blog generation in English, Tamil, and Sinhala, based on simple JSON input.
โจ Features
๐ Generates blog content in English, Tamil, or Sinhala.
โก FastAPI backend to handle blog requests.
๐ง Built using LangGraph and LangChain.
๐ Supports two separate Agentic Graphs:
- One for English blogs.
- One for Tamil and Sinhala blogs.
๐ฆ Easily configurable via
.envfile.๐ Cleanly managed with
requirements.txtanduvfor dependency management.
๐ง How to Use
โ Step 1: Clone the Repository
git clone https://github.com/yourusername/agentic-blog-generator.git
cd agentic-blog-generator
๐ Step 2: Install Dependencies
Ensure you have uv installed, then run:
uv add -r requirements.txt
๐ Step 3: Set Up Environment Variables
Create a .env file and include the following:
GROQ_API_KEY=your_groq_api_key
LANGCHAIN_API_KEY=your_langchain_api_key
โ๏ธ Step 4: Launch LangGraph Studio
To open the graph in LangGraph Studio, run:
langgraph dev
There are 2 graphs available:
- English Blog Graph
- Tamil & Sinhala Blog Graph
Modify the ./src/graphs/graph_builder.py file to select which graph to open.
๐ Run the App
After setting up your environment, start the FastAPI server with:
python app.py
โ๏ธ API Usage
Send a POST request to /blogs endpoint with one of the following formats:
โ๏ธ English Blog Generation
{
"topic": "The Future of Artificial Intelligence"
}
๐น๐ญ/๐ต๐ฌ Tamil or Sinhala Blog Generation
{
"topic": "เฎเฏเฎฑเฎฟเฎฉเฏ เฎฎเฏเฎคเฏเฎคเฏเฎคเฏเฎคเฏ เฎเฎฐเฏเฎจเฏเฎค เฎฎเฏเฎฉเฏเฎฉเฏ",
"language": "tamil"
}
{
"topic": "เทเทเถปเทเถฉ เถเถงเทเถปเถฑเทเทเถปเทเถถเทเถฑ เทเถปเทเทเถปเถบ",
"language": "sinhala"
}
๐ผ๏ธ Graph Visuals
English Blog Graph
Tamil & Sinhala Blog Graph
๐ Project Structure
.
โโโ app.py # Main FastAPI app
โโโ requirements.txt # Dependencies
โโโ .env # API keys (GROQ and LangChain)
โโโ src
โ โโโ graphs
โ โโโ graph_builder.py # Modify to open selected LangGraph
โโโ assets
โโโ english_graph.png
โโโ tamil_sinhala_graph.png
๐ Built With
๐ Credits
Created with โค๏ธ by Nivakaran S. โ built for multi-lingual blog automation.
โ Contribute
Feel free to fork, star, and contribute!
โ ๏ธ License
This project is licensed under the MIT License.

