Package Exports
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (recap.js) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
Recap.js
Record. Transcribe. Summarize.
🎤 A powerful CLI tool and TypeScript library for automated meeting notes, powered by OpenAI Whisper and GPT models.
✨ Features
- 🎙️ Record audio from your microphone with customizable settings
- 🎯 Transcribe speech to text using OpenAI Whisper or Google Gemini AI
- 📝 AI-powered summarization with multiple providers (OpenAI GPT, Google Gemini)
- 🔄 Multiple AI providers - Choose between OpenAI and Gemini or let Recap.js decide
- 📊 Provider comparison - Compare results from different AI providers side-by-side
- 📄 Multiple export formats (Markdown, JSON, Plain Text)
- 🔄 Complete workflows with a single command
- 💻 CLI and programmatic APIs for maximum flexibility
- 🎨 Beautiful terminal UI with progress indicators and colors
- ⚡ TypeScript-first with full type safety
🚀 Quick Start
Installation
npm install -g recap.js
Setup (Interactive Tutorial)
recapjs setup
This will:
- Show you exactly how to get API keys
- Guide you through the setup process step-by-step
- Save your preferences for daily use
- Test your configuration
Alternative: Manual Setup
# OpenAI (Higher quality, ~$0.006/minute)
export OPENAI_API_KEY="your-openai-api-key-here"
# Google Gemini (More cost-effective, ~$0.002/minute)
export GEMINI_API_KEY="your-gemini-api-key-here"
💡 Tip: Start with recapjs setup
- it includes a helpful tutorial for getting API keys!
Basic Usage
# First-time setup (saves your preferences)
recapjs setup
# Quick record with saved settings
recapjs quick-record --duration 300
# Traditional commands
recapjs process --duration 300 --provider gemini --output meeting-notes
recapjs transcribe meeting.wav --provider gemini --format json
recapjs summarize transcript.json --provider openai --style action-items
# Compare providers on the same audio
recapjs compare meeting.wav --style meeting-notes
# Configuration management
recapjs config show
recapjs config set provider gemini
recapjs config set style action-items
# Check provider status
recapjs providers
# Get audio file information
recapjs info meeting.wav
📖 CLI Commands
recapjs record
Record audio from your microphone.
recapjs record [options]
Options:
-o, --output <path> Output file path (default: "recording.wav")
-d, --duration <sec> Recording duration in seconds
-s, --sample-rate <hz> Sample rate (default: 16000)
--summarize Auto-transcribe and summarize after recording
--format <format> Export format: markdown|json|txt (default: "markdown")
--style <style> Summary style (default: "meeting-notes")
--provider <provider> AI provider: openai|gemini|auto (default: "auto")
--model <model> Specific model to use
Examples:
# Record for 5 minutes
recapjs record --duration 300 --output team-standup.wav
# Record and auto-summarize with action items using Gemini
recapjs record --duration 600 --summarize --style action-items --provider gemini
recapjs transcribe
Transcribe audio files to text.
recapjs transcribe <audio-file> [options]
Options:
-o, --output <path> Output file path
--format <format> Output format: json|txt|markdown (default: "json")
--language <lang> Audio language (e.g., en, es, fr)
--provider <provider> AI provider: openai|gemini|auto (default: "auto")
--model <model> Model to use (whisper-1, gemini-1.5-pro, etc.)
Examples:
# Transcribe to JSON with OpenAI Whisper
recapjs transcribe meeting.mp3 --provider openai --format json
# Transcribe Spanish audio with Gemini
recapjs transcribe reunion.wav --provider gemini --language es --format markdown
recapjs summarize
Generate AI-powered summaries from transcripts.
recapjs summarize <input-file> [options]
Options:
-o, --output <path> Output file path
--style <style> Summary style (default: "meeting-notes")
--format <format> Output format: markdown|json|txt (default: "markdown")
--provider <provider> AI provider: openai|gemini|auto (default: "auto")
--model <model> Model to use (gpt-3.5-turbo, gpt-4, gemini-1.5-pro, etc.)
Summary Styles:
action-items
- Focus on tasks and assignmentsmeeting-notes
- Traditional meeting minutes formatbullet-points
- Concise bullet-point summaryexecutive-summary
- High-level overview for leadershipdetailed
- Comprehensive analysis with context
Examples:
# Generate action items with Gemini
recapjs summarize transcript.json --provider gemini --style action-items
# Executive summary with GPT-4
recapjs summarize meeting.txt --provider openai --style executive-summary --model gpt-4
# Compare providers on the same transcript
recapjs compare meeting.wav --style executive-summary
recapjs process
Complete workflow: record → transcribe → summarize.
recapjs process [options]
Options:
-o, --output <base> Output file base name (default: "meeting")
-d, --duration <sec> Recording duration in seconds
--style <style> Summary style (default: "meeting-notes")
--format <format> Final output format (default: "markdown")
--provider <provider> AI provider: openai|gemini|auto (default: "auto")
--model <model> Model to use
--keep-intermediate Keep audio and transcript files
Examples:
# Complete 10-minute meeting workflow with Gemini
recapjs process --duration 600 --provider gemini --output board-meeting
# Generate action items and keep all files
recapjs process --style action-items --keep-intermediate
# Use specific models
recapjs process --provider openai --model gpt-4 --duration 300
recapjs compare
Compare AI providers on the same audio file.
recapjs compare <audio-file> [options]
Options:
--style <style> Summary style for comparison (default: "meeting-notes")
--output <path> Output directory for results (default: "./comparison-results")
Examples:
# Compare providers with meeting notes style
recapjs compare meeting.wav --style meeting-notes
# Compare with custom output directory
recapjs compare meeting.mp3 --output ./provider-comparison
recapjs providers
Show available AI providers and their configuration status.
recapjs providers
This command will show:
- ✅ Connected providers with available models
- ❌ Providers with connection issues
- ⚠️ Providers missing API keys
- 💡 Configuration tips
recapjs setup
Run the initial configuration wizard.
recapjs setup
Walks you through setting up API keys, default provider, export format, and summary style.
recapjs config
Manage persistent configuration settings.
recapjs config show # Display current configuration
recapjs config set <key> <value> # Set configuration value
recapjs config clear # Clear all configuration
Available config keys:
openai-key
- OpenAI API keygemini-key
- Gemini API keyprovider
- Default AI provider (openai|gemini)format
- Default export format (markdown|json|txt)style
- Default summary stylemodel
- Default AI model
recapjs quick-record
Quick record using your saved configuration preferences.
recapjs quick-record [options]
Options:
-d, --duration <seconds> Recording duration in seconds
-o, --output <path> Output file path
This command uses your saved defaults for provider, format, and style.
recapjs info
Show detailed information about audio files.
recapjs info <audio-file>
🛠️ Programmatic API
Use Recap.js in your Node.js applications:
import {
AudioRecorder,
UnifiedAIProvider,
GeminiTranscriber,
GeminiSummarizer,
DataExporter,
createRecapWorkflow,
} from 'recap.js';
// Complete workflow with multiple providers
const result = await createRecapWorkflow({
openaiApiKey: 'your-openai-key',
geminiApiKey: 'your-gemini-key',
provider: 'gemini', // or 'openai' or 'auto'
recordingOptions: {
outputPath: 'meeting.wav',
duration: 300, // 5 minutes
sampleRate: 16000,
},
summaryStyle: 'action-items',
exportFormat: 'markdown',
exportPath: 'meeting-summary.md',
});
if (result.success) {
console.log('Summary saved to:', result.data.exportPath);
console.log('Action items:', result.data.summary.action_items);
}
// Using the unified AI provider
const aiProvider = new UnifiedAIProvider('your-openai-key', 'your-gemini-key');
const recorder = new AudioRecorder();
const exporter = new DataExporter();
// Record audio
const recording = await recorder.startRecording({
outputPath: 'audio.wav',
duration: 180,
});
// Transcribe with auto provider selection
const transcript = await aiProvider.transcribeAudio({
inputPath: 'audio.wav',
provider: 'auto', // Let Recap.js choose the best provider
});
// Summarize with specific provider
const summary = await aiProvider.summarizeFromTranscript(transcript.data!, {
style: 'meeting-notes',
provider: 'gemini',
});
// Compare providers
const comparison = await aiProvider.compareProviders({
inputPath: 'audio.wav',
style: 'action-items',
});
if (comparison.success) {
console.log('OpenAI results:', comparison.data.openai);
console.log('Gemini results:', comparison.data.gemini);
}
// Export
await exporter.exportData({
data: summary.data!,
format: 'markdown',
outputPath: 'summary.md',
});
📋 Example Output
Meeting Summary (Markdown)
# Weekly Team Standup
**Date:** 2024-01-15
**Duration:** 23 minutes
**Summary Style:** meeting-notes
## Participants
- **Alice Johnson** (Team Lead)
- Discussed project timeline updates
- Reviewed Q1 objectives
- **Bob Smith** (Developer)
- Reported on API development progress
- **Carol Williams** (Designer)
- Presented new UI mockups
## Key Topics
- Q1 project roadmap review
- API development status
- UI/UX design updates
- Resource allocation for February
## Summary
The team reviewed progress on Q1 objectives and discussed upcoming deliverables. API development is on track with the authentication module completed. New UI designs were well-received and approved for implementation.
## Action Items
### High Priority
- [ ] **Complete user authentication API endpoints**
- **Assignee:** Bob Smith
- **Deadline:** January 20th
- [ ] **Finalize UI component library**
- **Assignee:** Carol Williams
- **Deadline:** January 25th
### Medium Priority
- [ ] **Update project documentation**
- **Assignee:** Alice Johnson
- **Deadline:** End of month
## Decisions Made
1. Approved new UI design direction for user dashboard
2. Decided to prioritize mobile responsiveness in February
3. Agreed to weekly design reviews starting next week
## Next Steps
1. Schedule design review sessions for next week
2. Begin mobile optimization planning
3. Update stakeholders on Q1 progress
---
_Generated by Recap.js on 1/15/2024, 2:30:15 PM_
⚙️ Configuration
Environment Variables
# AI Provider API Keys (at least one required)
OPENAI_API_KEY=your-openai-api-key
GEMINI_API_KEY=your-gemini-api-key
# or
GOOGLE_API_KEY=your-google-api-key
# Optional Configuration
RECAP_DEFAULT_PROVIDER=auto # auto|openai|gemini
RECAP_DEFAULT_MODEL=auto # or specific model names
RECAP_DEFAULT_FORMAT=markdown
RECAP_DEFAULT_STYLE=meeting-notes
Global CLI Options
# Set API keys via command line
recapjs --openai-key YOUR_KEY --gemini-key YOUR_KEY [command]
# Choose provider globally
recapjs --provider gemini [command]
# Check current configuration
recapjs providers
Audio Requirements
- Supported formats: WAV, MP3, M4A, FLAC, OGG, WebM, MP4
- Maximum file size: 25MB (OpenAI API limit)
- Recommended settings: 16kHz sample rate, mono channel
- Recording requirements: Microphone access, SoX for recording
💰 Cost Estimation
Recap.js supports multiple AI providers with different pricing:
OpenAI Pricing
- Whisper (transcription): $0.006 per minute
- GPT-3.5-turbo (summarization): ~$0.001-0.003 per meeting
- GPT-4 (summarization): ~$0.01-0.03 per meeting
Google Gemini Pricing
- Gemini 1.5 Pro (transcription): ~$0.002 per minute
- Gemini 1.5 Pro (summarization): ~$0.0005-0.002 per meeting
- Gemini 1.5 Flash (faster/cheaper): ~$0.0001-0.0005 per meeting
Example costs for a 30-minute meeting:
OpenAI (Whisper + GPT-3.5-turbo):
- Transcription: $0.18
- Summarization: ~$0.002
- Total: ~$0.18
Gemini (1.5 Pro):
- Transcription: ~$0.06
- Summarization: ~$0.001
- Total: ~$0.06
Compare costs:
recapjs info <audio-file> # Shows estimated costs for all providers
recapjs compare <audio-file> # Compare quality and costs side-by-side
🔧 Development
Prerequisites
- Node.js 16+
- TypeScript 5.2+
- SoX (for audio recording)
Setup
# Clone repository
git clone https://github.com/rollenasistores/recap.js.git
cd recap.js
# Install dependencies
npm install
# Build project
npm run build
# Run in development
npm run dev
# Run linting
npm run lint
# Format code
npm run format
Project Structure
src/
├── cli.ts # CLI entry point
├── index.ts # Library exports
├── types.ts # TypeScript interfaces
├── recorder.ts # Audio recording
├── transcriber.ts # Speech-to-text
├── summarizer.ts # AI summarization
├── exporter.ts # Export functionality
└── utils.ts # Utility functions
🤝 Contributing
We welcome contributions! Please see our Contributing Guide for details.
- Fork the repository
- Create a feature branch:
git checkout -b feature/amazing-feature
- Commit changes:
git commit -m 'Add amazing feature'
- Push to branch:
git push origin feature/amazing-feature
- Open a Pull Request
📄 License
This project is licensed under the MIT License - see the LICENSE file for details.
🆘 Support
🚀 Roadmap
- Speaker diarization (identify who said what)
- Real-time transcription and summarization
- Integration with calendar apps
- Custom AI prompts and templates
- Multi-language support enhancements
- Web interface for non-CLI users
- Integration with popular meeting platforms
Record. Transcribe. Summarize.