AI-powered terminal that speaks human
A revolutionary terminal experience where you can type commands OR ask in natural language. Berto is your AI assistant that understands both traditional shell commands and conversational requests.
- ๐ง AI-Powered: Ask naturally - "show me files", "create a folder", "help me find something"
- โก Real Commands: Execute actual shell commands on your machine (local) or simulated environment (remote)
- ๐ Hybrid Mode: Works seamlessly both locally and on remote deployments (Vercel)
- ๐จ Beautiful UI: Modern, responsive terminal interface with proper theming
- ๐ฑ Mobile Friendly: Optimized touch experience for mobile devices
- ๐ Smart Context: AI understands your current directory and available files
- ๐ฏ Inline Input: Clean, authentic terminal feel with proper prompt alignment
- Node.js 18+
- pnpm (recommended) or npm
- OpenAI API key
# Clone the repository
git clone https://github.com/kemenystudio/berto.git
cd berto
# Install dependencies (use pnpm for best results)
pnpm install
# Set up environment variables
cp .env.example .env.local
# Add your OPENAI_API_KEY to .env.local
# Start development server
pnpm devCreate a .env.local file with:
OPENAI_API_KEY=your-openai-api-key-hereAsk Berto anything in plain English:
- "show me the files in this folder" โ runs
ls - "create a project folder and call it 'bananas'" โ runs
mkdir bananas - "help me find all text files" โ runs
find . -name "*.txt" - "what's in my home directory?" โ runs
ls ~
All standard shell commands work perfectly:
ls -la # List files with details
cat filename.txt # Read file contents
mkdir new-folder # Create directory
cd Documents # Change directory
pwd # Show current directory
grep "text" *.txt # Search in filesTry these built-in commands:
help- See all available commands and tipshack- Start an immersive AI-powered cyber hacker challengeclear- Clear the terminal screen
Experience Berto's interactive cyber security challenge:
hack # Start the challenge
cd intel # Navigate to intel directory
cat CODE_1.dat # Find your first access code
cat ../matrix.dat # Decode the matrix for CODE_2
cd ../vault # Enter the final vault challengeFeatures:
- ๐ต๏ธ Immersive Story: Realistic hacker scenario with classified files
- ๐ Progressive Puzzles: Find 3 access codes through different challenges
- ๐งญ Full Navigation: Complete
cdsupport for directory exploration - ๐ค AI-Generated Content: Dynamic hints and responses
- ๐ฏ Educational: Learn real terminal commands while playing
- ๐ฅ๏ธ Native Performance: Direct access to your local filesystem
- โก Real Commands: Execute actual shell commands on your machine
- ๐ Instant Feedback: No network delays, immediate responses
- ๐ Simulated Environment: Virtual filesystem for safe command execution
- ๐ค AI-Enhanced: Intelligent command interpretation and responses
- ๐ก๏ธ Secure: Sandboxed environment prevents system access
- GPT-4 Powered: Natural language understanding and command generation
- Context Aware: Understands your current directory and available files
- Smart Suggestions: Provides helpful tips and alternative commands
- Connect your repository to Vercel
- Set environment variables in Vercel dashboard:
OPENAI_API_KEY: Your OpenAI API key
- Deploy - Vercel will automatically build and deploy
The project is configured with:
- โ
vercel.jsonwith proper pnpm configuration - โ Optimized build settings
- โ API routes with appropriate timeouts
- โ Edge runtime compatibility
For other deployment platforms, ensure:
- Node.js 18+ runtime
- Environment variables are set
- Build command:
pnpm build - Start command:
pnpm start
berto/
โโโ app/ # Next.js app router
โ โโโ api/ # API routes
โ โ โโโ ai/ # AI command processing
โ โ โโโ execute/ # Command execution
โ โโโ layout.tsx # Root layout
โ โโโ page.tsx # Main page
โโโ src/ # Source code
โ โโโ components/ # React components
โ โ โโโ ui/ # Shadcn/ui components
โ โ โโโ terminal.tsx # Main terminal component
โ โโโ services/ # Core services
โ โ โโโ ai-interpreter.ts
โ โ โโโ shell-executor.ts
โ โ โโโ hybrid-filesystem.ts
โ โ โโโ environment-detector.ts
โ โโโ hooks/ # Custom React hooks
โ โโโ lib/ # Utilities
โ โโโ types/ # TypeScript definitions
โ โโโ commands/ # Command definitions
โ โโโ styles/ # CSS styles
โโโ config/ # Configuration files
โโโ public/ # Static assets
โโโ [config files] # Next.js, TypeScript, etc.
- AI Interpreter: Processes natural language and converts to commands
- Shell Executor: Executes commands safely in both environments
- Hybrid Filesystem: Manages files in local/remote contexts
- Environment Detector: Determines runtime environment
- Frontend: Next.js 15, React 19, TypeScript
- Styling: Tailwind CSS, Shadcn/ui components
- AI: OpenAI GPT-4, Vercel AI SDK
- Icons: Lucide React
- Package Manager: pnpm (recommended)
- File Operations: Enhanced file manipulation commands
- Git Integration: Direct git command support
- Theme Customization: Multiple terminal themes
- Command History: Persistent command history
- Tab Completion: Smart command completion
- Session Management: Multiple terminal sessions
- โ
Full Directory Navigation: Fixed
cdcommand support in remote/simulated environments - ๐ต๏ธ Intel Directory: Added interactive intel files with mission briefings and classified documents
- ๐ Progressive Puzzle System: Complete 3-stage access code discovery
- ๐ฏ Improved UX: Better error handling and helpful guidance for players
- ๐ค AI Integration: Dynamic content generation for hints and responses
- v1.1.0: Added natural language processing and AI command interpretation
- v1.0.0: Initial release with basic terminal functionality
Contributions are welcome! Please:
- Fork the repository
- Create a feature branch
- Make your changes
- Add tests if applicable
- Submit a pull request
MIT License - see LICENSE file for details.
- Built with Next.js, React, and OpenAI
- UI components powered by Radix UI and Tailwind CSS
- Terminal experience inspired by modern CLI tools