{"id":29092140,"url":"https://github.com/tushar98644/wordsy","last_synced_at":"2026-04-28T12:03:40.642Z","repository":{"id":301031941,"uuid":"1007955088","full_name":"Tushar98644/wordsy","owner":"Tushar98644","description":null,"archived":false,"fork":false,"pushed_at":"2025-08-15T08:13:17.000Z","size":1213,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-08-15T10:08:49.593Z","etag":null,"topics":["cloudflare","mem0","nextjs15","shadcn","tailwindcss","typescript","vercel-ai-sdk"],"latest_commit_sha":null,"homepage":"https://wordsy-chat.vercel.app","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Tushar98644.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2025-06-24T19:47:07.000Z","updated_at":"2025-08-15T08:13:20.000Z","dependencies_parsed_at":"2025-08-15T10:18:42.166Z","dependency_job_id":null,"html_url":"https://github.com/Tushar98644/wordsy","commit_stats":null,"previous_names":["tushar98644/chatgpt","tushar98644/wordsy"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/Tushar98644/wordsy","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Tushar98644%2Fwordsy","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Tushar98644%2Fwordsy/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Tushar98644%2Fwordsy/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Tushar98644%2Fwordsy/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Tushar98644","download_url":"https://codeload.github.com/Tushar98644/wordsy/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Tushar98644%2Fwordsy/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":278277880,"owners_count":25960430,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-04T02:00:05.491Z","response_time":63,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cloudflare","mem0","nextjs15","shadcn","tailwindcss","typescript","vercel-ai-sdk"],"created_at":"2025-06-28T07:02:42.717Z","updated_at":"2025-10-04T06:44:09.238Z","avatar_url":"https://github.com/Tushar98644.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"Wordsy\n==============\n\nA modern, responsive chat application built with Next.js, React, and TypeScript. Features real-time messaging, file uploads, user authentication, and a clean modular architecture.\n\n🚀 Features\n-----------\n\n*   **Real-time Chat**: Instant messaging with smooth user experience\n    \n*   **File Upload**: Support for file attachments with Cloudinary integration\n    \n*   **User Authentication**: Secure authentication with Clerk\n    \n*   **Responsive Design**: Mobile-first design with collapsible sidebar\n    \n*   **Message Management**: Edit and delete messages\n    \n*   **Memory Integration**: AI-powered chat with Mem0 integration\n    \n*   **Modern UI**: Clean, dark theme with smooth animations\n\nLive Demo\n--------------------------------\n\n[Wordsy](https://wordsy-chat.vercel.app/)\n\n🛠️ Tech Stack\n--------------\n\n*   **Frontend**: Next.js 14, React 18, TypeScript\n    \n*   **Styling**: Tailwind CSS\n    \n*   **Authentication**: Clerk\n    \n*   **Database**: MongoDB\n    \n*   **File Storage**: Cloudinary\n    \n*   **AI**: Google Generative AI\n    \n*   **Memory**: Mem0\n    \n*   **Package Manager**: Bun\n    \n\n📋 Prerequisites\n----------------\n\nBefore you begin, ensure you have the following installed:\n\n*   [Bun](https://bun.sh/) (latest version)\n    \n*   [Node.js](https://nodejs.org/) (18+ recommended)\n    \n*   [Git](https://git-scm.com/)\n    \n\n🏗️ Installation \u0026 Setup\n------------------------\n\n### 1\\. Clone the Repository\n\n```\ngit clone https://github.com/Tushar98644/wordsy.git\n```\n\n### 2\\. Install Dependencies\n\n```\nbun install\n```\n\n### 3\\. Environment Configuration\n\nCreate a .env.local file in the root directory and add the following environment variables:\n\n```\nNEXT_PUBLIC_CLERK_PUBLISHABLE_KEY=\nCLERK_SECRET_KEY=\nMEM0_API_KEY=\nCLOUDINARY_CLOUD_NAME=\nCLOUDINARY_API_KEY=\nCLOUDINARY_API_SECRET=\nGOOGLE_GENERATIVE_AI_API_KEY=\nMONGODB_URI=\nNEXT_PUBLIC_BASE_URL=\n```\n\n### 4\\. Set Up Required Services\n\n#### Clerk Authentication\n\n1.  Sign up at [Clerk.com](https://clerk.com/)\n    \n2.  Create a new application\n    \n3.  Copy the publishable key and secret key to your .env.local\n    \n\n#### Cloudinary (File Storage)\n\n1.  Sign up at [Cloudinary.com](https://cloudinary.com/)\n    \n2.  Get your cloud name, API key, and API secret from the dashboard\n    \n3.  Add them to your .env.local\n    \n\n#### MongoDB Database\n\n1.  **Local MongoDB**: Install MongoDB locally or use MongoDB Compass\n    \n2.  **MongoDB Atlas**: Create a free cluster at [MongoDB Atlas](https://www.mongodb.com/atlas)\n    \n3.  Add the connection string to your .env.local\n    \n\n#### Google Generative AI\n\n1.  Go to [Google AI Studio](https://aistudio.google.com/)\n    \n2.  Create an API key\n    \n3.  Add it to your .env.local\n    \n\n#### Mem0 (Optional)\n\n1.  Sign up at [Mem0.ai](https://mem0.ai/)\n    \n2.  Get your API key\n    \n3.  Add it to your .env.local\n    \n\n### 5\\. Start the Development Server\n\n```\nbun dev  \n```\n\nThe application will be available at [http://localhost:3000](http://localhost:3000)\n\n📁 Project Structure\n--------------------\n\n```\nsrc\n│   ├── app\n│   │   ├── api                              # Versioned API routes \n│   │   │   └── v1\n│   │   │       ├── chat\n│   │   │       │   └── route.ts\n│   │   │       ├── chats\n│   │   │       │   ├── create\n│   │   │       │   │   └── route.ts\n│   │   │       │   ├── list\n│   │   │       │   │   └── route.ts\n│   │   │       │   ├── messages\n│   │   │       │   │   └── route.ts\n│   │   │       │   └── route.ts\n│   │   │       ├── memory\n│   │   │       │   └── route.ts\n│   │   │       ├── recall\n│   │   │       │   └── route.ts\n│   │   │       └── upload\n│   │   │           └── route.ts\n│   │   ├── chat                             # Chat page \n│   │   │   └── page.tsx\n│   │   ├── globals.css\n│   │   ├── landing                          # Landing page\n│   │   │   └── page.tsx\n│   │   ├── layout.tsx\n│   │   ├── page.tsx\n│   │   └── sign-in                          # Sign in page\n│   │       └── page.tsx\n│   ├── components                           # Components grouped by feature\n│   │   ├── chat-window\n│   │   │   ├── chat-area.tsx\n│   │   │   ├── chat-interface.tsx\n│   │   │   ├── empty-state.tsx\n│   │   │   ├── header.tsx\n│   │   │   ├── main-content.tsx\n│   │   │   ├── mobile-sidebar-toggle.tsx\n│   │   │   ├── mobile-sidebar.tsx\n│   │   │   └── top-controls.tsx\n│   │   ├── icons                             # Custom Icons\n│   │   │   ├── GptsIcon.tsx\n│   │   │   ├── LibraryIcon.tsx\n│   │   │   ├── LogoIcon.tsx\n│   │   │   ├── NewChatIcon.tsx\n│   │   │   ├── SearchIcon.tsx\n│   │   │   ├── SettingsIcon.tsx\n│   │   │   └── SoraIcon.tsx\n│   │   ├── input                             # Input components\n│   │   │   ├── chat-control.tsx\n│   │   │   ├── chat-input.tsx\n│   │   │   ├── editing-banner.tsx\n│   │   │   ├── file-card.tsx\n│   │   │   ├── file-preview.tsx\n│   │   │   ├── loading-indicator.tsx\n│   │   │   ├── submit-button.tsx\n│   │   │   └── voice-control.tsx\n│   │   ├── login-form.tsx\n│   │   ├── messages                           # Message components\n│   │   │   ├── document-file.tsx\n│   │   │   ├── file-attachment.tsx\n│   │   │   ├── image-file.tsx\n│   │   │   ├── message-action.tsx\n│   │   │   ├── message-container.tsx\n│   │   │   ├── message-content.tsx\n│   │   │   ├── message-files.tsx\n│   │   │   └── message.tsx\n│   │   ├── sidebar                            # Sidebar components\n│   │   │   ├── bottom-section.tsx\n│   │   │   ├── chat-item.tsx\n│   │   │   ├── chat-list.tsx\n│   │   │   ├── quick-actions.tsx\n│   │   │   ├── sidebar.tsx\n│   │   │   └── top-section.tsx\n│   │   ├── ui                                # External UI components \n│   │   │   ├── button.tsx\n│   │   │   └── input.tsx\n│   │   └── welcome-modal.tsx\n│   ├── config                                # Configuration files for services\n│   │   ├── cloudinary-config.ts\n│   │   └── gemini.ts\n│   ├── context                               # Contexts for the application\n│   │   ├── chat-context.tsx\n│   │   └── ui-context.tsx\n│   ├── hooks                                 # Custom hooks for the application\n│   │   ├── index.ts \n│   │   ├── useAutoScroll.ts\n│   │   ├── useChatInput.ts\n│   │   ├── useChatManager.ts\n│   │   ├── useClickOutside.ts\n│   │   ├── useChats.ts\n│   │   ├── useFileUpload.ts\n│   │   ├── useKeyboardHandlers.ts\n│   │   ├── useMessageActions.ts\n│   │   ├── useMessageContainer.ts\n│   │   └── useMobileSidebar.ts\n│   ├── lib                                    # Major business logic\n│   │   ├── chat\n│   │   │   ├── chat-service.ts\n│   │   │   ├── memory-service.ts\n│   │   │   └── message-processor.ts\n│   │   ├── cloudinary.ts\n│   │   ├── db.ts\n│   │   ├── memory\n│   │   │   ├── client.ts\n│   │   │   ├── service.ts\n│   │   │   └── validation.ts\n│   │   ├── memory.ts\n│   │   └── utils.ts\n│   ├── middleware.ts                          # Auth middleware (Clerk) \n│   ├── models                                 # MongoDB models\n│   │   └── chat.ts\n│   ├── types                                  # TypeScript types\n│   │   ├── chat.ts\n│   │   ├── file.ts\n│   │   ├── index.ts\n│   │   ├── input.ts\n│   │   ├── memory.ts\n│   │   └── message.ts\n│   └── utils                                  # Utility functions\n│       ├── chatApi.ts\n│       ├── clipboard.ts\n│       ├── file.ts\n│       └── memory.ts\n```\n\n🎯 Usage\n--------\n\n1.  **Sign Up/Login**: Use Clerk authentication to create an account\n    \n2.  **Start Chatting**: Type messages in the input field\n    \n3.  **Upload Files**: Click the attachment button to upload files\n    \n4.  **Mobile Navigation**: Use the hamburger menu on mobile devices\n    \n5.  **Message Actions**: Edit or delete your messages using the action buttons\n    \n\n🔧 Development\n--------------\n\n### Available Scripts\n\n```\n# Start development server  bun dev  \n# Build for production  bun run build  \n# Start production server  bun start  \n# Run type checking  bun run type-check  \n# Run linting  bun run lint   \n```\n\n### Code Organization\n\n*   **Contexts**: React Context for state management (no prop drilling)\n    \n*   **Components**: Modular, reusable UI components\n    \n*   **Hooks**: Custom hooks for business logic\n    \n*   **TypeScript**: Full type safety throughout the application\n    \n\n🚀 Deployment\n-------------\n\n### Vercel (Recommended)\n\n1.  Push your code to GitHub\n    \n2.  Import your repository on [Vercel](https://vercel.com/)\n    \n3.  Add your environment variables in the Vercel dashboard\n    \n4.  Deploy!\n    \n\n### Other Platforms\n\nThe application can be deployed on any platform that supports Next.js:\n\n*   Netlify\n    \n*   Railway\n    \n*   DigitalOcean App Platform\n    \n*   AWS Amplify\n    \n\n🔐 Environment Variables Guide\n------------------------------\n\n| Variable | Description | Required | Example |\n|----------|-------------|----------|---------|\n| NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY | Clerk public key | ✅ | pk_test_... |\n| CLERK_SECRET_KEY | Clerk secret key | ✅ | sk_test_... |\n| MEM0_API_KEY | Mem0 AI memory API key | ⚠️ | mem0_... |\n| CLOUDINARY_API_KEY | Cloudinary API key | ✅ | 123456789... |\n| CLOUDINARY_API_SECRET | Cloudinary API secret | ✅ | abc123... |\n| GOOGLE_GENERATIVE_AI_API_KEY | Google AI API key | ✅ | AIza... |\n| MONGODB_URI | MongoDB connection string | ✅ | mongodb://... |\n| NEXT_PUBLIC_BASE_URL | Application base URL | ✅ | http://localhost:3000 |\n\n🐛 Troubleshooting\n------------------\n\n### Common Issues\n\n1. **Dependencies not installing**\n    \n    ```\n    rm -rf node_modules\n    rm bun.lockb\n    ```\n    ```\n    bun install\n    ```\n    \n2.  **Environment variables not loading**\n    \n    *   Ensure `.env.local` is in the root directory\n        \n    *   Restart the development server after changes\n        \n    *   Check for typos in variable names\n        \n3.  **Database connection issues**\n    \n    *   Verify MongoDB is running (if using local)\n        \n    *   Check MongoDB URI format\n        \n    *   Ensure network access for MongoDB Atlas\n        \n4.  **Authentication not working**\n    \n    *   Verify Clerk keys are correct\n        \n    *   Check domain settings in Clerk dashboard\n        \n    *   Ensure `NEXT_PUBLIC_BASE_URL` matches your domain\n        \n\n📝 Contributing\n---------------\n\n1.  Fork the repository\n    \n2.  Create a feature branch `git checkout -b feature/amazing-feature`\n    \n3.  Commit your changes `git commit -m 'Add amazing feature'`\n    \n4.  Push to the branch `git push origin feature/amazing-feature`\n    \n5.  Open a Pull Request\n    \n\n📄 License\n----------\n\nThis project is licensed under the MIT License - see the [LICENSE](https://github.com/Tushar98644/wordsy/blob/main/LICENSE) file for details.\n\n🤝 Support\n----------\n\nIf you have any questions or need help with setup, please:\n\n1.  Check the troubleshooting section above\n    \n2.  Search existing issues on GitHub\n    \n3.  Create a new issue with detailed information\n    \n\nBuilt with ❤️ using Next.js, vercel AI sdk, Clerk, MongoDB, Cloudinary, Google Gemini, Mem0, TypeScript","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftushar98644%2Fwordsy","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftushar98644%2Fwordsy","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftushar98644%2Fwordsy/lists"}