This directory contains example projects demonstrating various features and use cases of the Modelence framework.
A chat application showcasing AI integration with Modelence. Features authentication UI, React Query integration, and real-time AI-powered conversations.
Key Features:
- AI chat functionality using
@modelence/ai - User authentication with
@modelence/auth-ui - React Query for data management
- React Router for navigation
A full-featured data API example demonstrating REST endpoint creation, MongoDB integration, and comprehensive testing.
Key Features:
- MongoDB database integration
- RESTful API endpoints
- Jest unit testing
- Zod schema validation
A minimal Modelence project template with the essential setup. Perfect starting point for new projects.
Key Features:
- Basic Modelence configuration
- React and React Router setup
- Tailwind CSS styling
A comprehensive todo application built with Next.js and Modelence, demonstrating full-stack development patterns.
Key Features:
- Next.js integration with
@modelence/next - React Query for state management
- Zod for data validation
- Modern React 19
An advanced example showcasing custom build configuration with Vite and tsup, along with AI SDK integration.
Key Features:
- Custom Vite build setup
- AI SDK with OpenAI integration
- Email functionality with
@modelence/resend - Advanced TypeScript configuration
Demonstrates integration with Voyage AI for embeddings and semantic search capabilities.
Key Features:
- Voyage AI embeddings integration
- MongoDB for vector storage
- React Query for data fetching
- Semantic search implementation
An experimental playground for testing and prototyping Modelence features.
Key Features:
- Minimal dependencies
- Quick experimentation environment
- Standard Modelence dev setup
Each example project can be run independently:
cd <project-name>
npm install
npm run devBuild for production:
npm run build
npm startAll projects support these standard commands:
npm run dev- Start development servernpm run build- Build for productionnpm start- Run production buildnpm test- Run tests (where configured)
This repository includes a utility script to update package versions across all example projects simultaneously.
The update-package.sh script allows you to update any package to a specific version or to the latest version across all examples.
./update-package.sh <package-name> <version>Example:
./update-package.sh modelence 0.6.21This will:
- Update the package version in each project's
package.json - Run
npm installin each project to updatepackage-lock.jsonandnode_modules - Skip projects that don't use the specified package
- Provide a summary of successes, skips, and failures
./update-package.sh <package-name>Example:
./update-package.sh modelenceThis will install the latest available version of the package in all applicable projects.
- Automatic project discovery: Finds all projects with
package.jsonautomatically - Smart skipping: Only updates projects that actually use the specified package
- Color-coded output: Easy-to-read success, warning, and error messages
- Summary report: Shows total successes, skips, and failures
- Cross-platform: Works on both macOS and Linux
Update core Modelence package across all examples:
./update-package.sh modelence 0.7.0Update React to latest:
./update-package.sh reactUpdate a Modelence plugin to a specific version:
./update-package.sh @modelence/react-query 1.0.3