If you find this repository helpful or interesting, please consider giving it a star! β and Follow Me for cool Projects
- It helps others discover the project.
- It motivates the me to keep improving it.
- It supports open-source development!
If you want to contribute, feel free to fork the repository and submit a pull request. Also, donβt forget to star the repo!
Thanks for your support! β€
Tale Tailor is a revolutionary full-stack platform that brings together cutting-edge AI story generation with vibrant social media features, creating a dynamic ecosystem for storytellers and readers alike. Create, collaborate, share, and experience stories in ways never before possible!
Transform your ideas into captivating narratives with our advanced AI engine:
- Emotion Selection: Set the emotional tone of your story (happy, sad, suspenseful, scary, etc.)
- Theme Selection: Choose from genres like fantasy, mystery, sci-fi, romance, horror, and more
- Length Customization: Create short stories, medium-length tales, or epic sagas
- Plot Twists: Opt for unexpected turns that keep readers on the edge of their seats
- Character Development: Specify number of characters and their relationships
- Situational Prompts: Start with a specific scenario and watch the AI expand it into a full story
Express yourself through our intuitive story creation tools:
- Public/Private Options: Choose whether to share your story with the world or keep it personal
- Word Count Tracking: Monitor your story's length as you write
- Custom Cover Images: Each story gets a unique cover image based on its title
Create together with friends, family, or new connections:
- Collaboration Invitations: Invite others to contribute to your story
- Collaborative Editing: Work together until the story is ready for publication
- Permission Management: Control who can edit your collaborative stories
- Publication Control: Once published, stories become read-only for collaborators
- Contribution Tracking: See who wrote what in collaborative works
Experience stories in a completely immersive way:
- Mood-Based Interfaces: The entire UI adapts to match your story's emotional tone
- Romantic Stories: Soft pink backgrounds with heart motifs
- Horror Tales: Dark mode with spooky elements
- Adventure Narratives: Vibrant earth tones with exploration themes
- Each Emotion Unique: Every emotional category has its own color scheme and visual elements
| Emotion | Theme Preview |
|---|---|
| Romantic | ![]() |
| Horror | ![]() |
| Adventure | ![]() |
Find your next favorite story with our advanced discovery features:
- Story Feed: Browse public stories in a familiar social media format
- Search Functionality: Find stories by title, author, or content
- Filter System: Sort by emotion, length, theme, and more
- Trending Section: Discover the most popular stories on the platform
- Similar Stories: Get recommendations based on your reading history
Connect with a community of storytellers and readers:
- Like System: Show appreciation for stories you enjoy
- View Tracking: See how many people have read your stories
- User Profiles: Customize your profile with bio and profile picture
Make stories accessible to everyone:
- One-Click Translation: Translate stories into multiple languages
- Text-to-Speech: Listen to stories with natural-sounding narration
- PDF Export: Download stories as beautifully formatted documents
- Reading Time Estimates: Know how long a story will take to read
Secure and personalized experience:
- Email Verification: Secure signup with OTP verification
- Profile Customization: Add your bio, profile picture, and more
- Story Collection: All your stories in one place
- Activity Tracking: See your interactions across the platform
- Account Settings: Manage your preferences and privacy options
Powerful tools for platform management:
- User Management: Block/unblock users when necessary
- Content Moderation: Review and manage reported content
- Analytics Dashboard: Monitor platform metrics and growth
- Story Management: Feature exceptional stories or remove inappropriate content
- System Health Monitoring: Keep the platform running smoothly
- Backend: Django (Python)
- Frontend: HTML, CSS, JavaScript
- Database: PostgreSQL
- AI Integration: HuggingFace Falcon-7b-instruct model
- External APIs: Unsplash (images), Google Translator, gTTS (text-to-speech)
tile-tailor/
βββ authentication/ # User authentication, profiles, admin controls
βββ Mystory/ # Core story models and functionality
βββ aistory/ # AI story generation features
βββ static/ # CSS, JS, images
β βββ css/ # Stylesheets with emotional themes
β βββ js/ # JavaScript files
β βββ images/ # Static images and assets
βββ templates/ # HTML templates
βββ manage.py # Django management script
- Python 3.8+
- Django 4.0+
- PostgreSQL
-
Clone the repository
git clone https://github.com/yourusername/tail-tailor.git cd tail-tailor -
Create and activate virtual environment
python -m venv venv venv\Scripts\activate
-
Install dependencies
pip install -r requirements.txt
-
Set up environment variables Create a
.envfile in the root directory with the following variables:SECRET_KEY=your_django_secret_key DEBUG=True DATABASE_URL=postgresql://user:password@localhost/tailtailor HUGGINGFACE_API_KEY=your_huggingface_api_key UNSPLASH_ACCESS_KEY=your_unsplash_access_key EMAIL_HOST=smtp.example.com EMAIL_PORT=587 [email protected] EMAIL_HOST_PASSWORD=your_email_password -
Apply migrations
python manage.py migrate
-
Create superuser
python manage.py createsuperuser
-
Run the development server
python manage.py runserver
-
Access the application Open your browser and go to
http://127.0.0.1:8000/
User: Authentication and profile informationStory: Central story content and metadataStoryLike: Tracks likes on storiesStoryView: Records story viewsCollaborationInvite: Manages collaboration invitationsProfile: Extended user profile information
- AI story generation flow
- Story creation and editing
- Collaborative storytelling
- Social interaction features
- Translation and accessibility functions
def generate_story(prompt):
API_URL = "https://api-inference.huggingface.co/models/tiiuae/falcon-7b-instruct"
headers = {"Authorization": f"Bearer {access_token}"}
payload = {
"inputs": prompt,
"parameters": {
"max_length": 700,
"temperature": 0.9,
"top_p": 0.95,
"repetition_penalty": 1.2,
}
}
response = requests.post(API_URL, headers=headers, json=payload)
if response.status_code == 200:
data = response.json()
return data[0]["generated_text"]
else:
return "Error: Couldn't generate story."def emotion_theme(request):
theme_class = 'theme-neutral'
theme_emoji = 'π'
story_id = request.resolver_match.kwargs.get('story_id')
if story_id:
from Mystory.models import Story
try:
story = Story.objects.get(id=story_id)
emotions = story.emotions.lower() if story and story.emotions else ''
theme_map = {
'happy': {'class': 'theme-happy', 'emoji': 'π'},
'sad': {'class': 'theme-sad', 'emoji': 'π’'},
'romantic': {'class': 'theme-romantic', 'emoji': 'β€οΈ'},
'thriller': {'class': 'theme-thriller', 'emoji': 'π±'},
# Additional emotions...
}
if ',' in emotions:
primary_emotion = emotions.split(',')[0].strip()
theme_data = theme_map.get(primary_emotion, {'class': 'theme-neutral', 'emoji': 'π'})
else:
theme_data = theme_map.get(emotions, {'class': 'theme-neutral', 'emoji': 'π'})
theme_class = theme_data['class']
theme_emoji = theme_data['emoji']
except Story.DoesNotExist:
pass
return {
'theme_class': theme_class,
'theme_emoji': theme_emoji
}We welcome contributions to make Tail Tailor even better!
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add some amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
- Github: https://github.com/sayyedrabeeh/
- linkdin: http
- Email: [email protected]
Developed with β€οΈRABI for Story Enthusiasts
















