A modern web application that helps product managers, developers, and analysts understand and compare LLM model pricing across different providers like OpenRouter and TogetherAI.
- Multi-Provider Support: Compare pricing across OpenRouter and TogetherAI
- Real-time Search: Instant filtering by model name and provider
- Smart Sorting: Sortable table columns for easy comparison
- Responsive Design: Works seamlessly on desktop, tablet, and mobile
- Smooth Animations: Beautiful loading states and transitions
- Provider Filtering: Easy switching between providers
- Frontend: React with Vite
- UI Framework: Material UI (MUI)
- Database: Supabase
- Styling: CSS Modules with MUI theming
- Data Management: React Query
- CSV Processing: Papa Parse
- Node.js (v18 or higher)
- npm or yarn package manager
- Supabase account
git clone <repository-url>
cd llmcostguide
npm installCreate a .env file in the root directory:
# Supabase Configuration
VITE_SUPABASE_URL=your_supabase_project_url
VITE_SUPABASE_ANON_KEY=your_supabase_anon_key
# Application
VITE_APP_NAME=LLMCostGuide
VITE_APP_VERSION=1.0.0- Create a new project in your Supabase dashboard
- Run the database schema from
LLMCostGuide_Technical_Specification.md - Configure any necessary RLS policies
npm run devThe app will start on http://localhost:5173
src/
βββ components/ # React components
β βββ common/ # Shared components
β βββ layout/ # Layout components
β βββ providers/ # Provider-specific components
β βββ pricing/ # Pricing-related components
β βββ admin/ # Admin components
βββ hooks/ # Custom hooks
βββ services/ # API and business logic
βββ utils/ # Utility functions
βββ styles/ # Global styles and themes
βββ assets/ # Static assets
The application uses Supabase as the backend with the following main table:
| Column | Type | Description |
|---|---|---|
id |
UUID | Unique identifier |
model_name |
VARCHAR(255) | Model name |
provider |
VARCHAR(100) | Provider name |
context_limit |
INTEGER | Context window size |
input_price_per_1M_tokens |
DECIMAL | Input token price |
output_price_per_1M_tokens |
DECIMAL | Output token price |
caching_price_per_1M_tokens |
DECIMAL | Caching token price |
model_type |
VARCHAR(50) | Text/Images/Videos/Embeddings |
added_on |
TIMESTAMP | Creation date |
context_window |
VARCHAR(50) | Human-readable context size |
description |
TEXT | Model description |
is_active |
BOOLEAN | Active status |
- Provider Selector: Dropdown to filter by provider
- Search Bar: Real-time search across model names and providers
- Pricing Table: Comprehensive table with all pricing information
- Sorting: Click column headers to sort data
- Loading States: Smooth skeleton animations
- Responsive Design: Mobile-friendly card layout
- Model Name: Clickable model identifier
- Provider: Provider badge and name
- Context: Context window size (e.g., "8K", "32K")
- Input Price: Cost per 1K input tokens
- Output Price: Cost per 1K output tokens
- Caching Price: Cost per 1K cached tokens
- Type: Model type (Text/Images/Videos/Embeddings)
- Added On: Date model was added to database
The application supports manual CSV import for updating model data:
model_name,provider,context_limit,input_price,output_price,caching_price,model_type,context_window,description
gpt-4,OpenRouter,8192,0.03,0.06,0.015,Text,8K,OpenAI GPT-4 model
llama-2-70b,TogetherAI,4096,0.0009,0.0009,0,Text,4K,Meta LLaMA 2 70B- OpenRouter: https://openrouter.ai/models
- TogetherAI: https://www.together.ai/pricing
# Start development server
npm run dev
# Build for production
npm run build
# Preview production build
npm run preview
# Lint code (when configured)
npm run lint
# Format code (when configured)
npm run formatWhen creating new components:
- Follow the naming convention:
ComponentName/ComponentName.jsx - Use CSS Modules for styling:
ComponentName.module.css - Add proper TypeScript interfaces
- Include loading and error states
- Ensure responsive design
- Add accessibility attributes
The project uses React Testing Library for component testing:
# Run tests
npm test
# Run tests in watch mode
npm test -- --watch
# Run tests with coverage
npm test -- --coverage- Connect your Git repository to Vercel
- Set environment variables in Vercel dashboard
- Deploy
- Connect your Git repository to Netlify
- Set build command:
npm run build - Set publish directory:
dist - Add environment variables
VITE_SUPABASE_URL=your_production_supabase_url
VITE_SUPABASE_ANON_KEY=your_production_supabase_key- Supabase Row Level Security (RLS) policies
- Input validation for all user inputs
- CSV file validation and sanitization
- CORS configuration for API endpoints
- Chrome (v80+)
- Firefox (v75+)
- Safari (v13+)
- Edge (v80+)
- Fork the repository
- Create a feature branch:
git checkout -b feature/amazing-feature - Commit your changes:
git commit -m 'feat: Add amazing feature' - Push to the branch:
git push origin feature/amazing-feature - Open a Pull Request
This project is licensed under the MIT License - see the LICENSE file for details.
- Supabase for the backend infrastructure
- Material UI for the component library
- OpenRouter and TogetherAI for providing pricing data
If you have any questions or suggestions, please open an issue in the repository.
LLMCostGuide - Making LLM pricing transparent and accessible for everyone.