This document provides comprehensive reference for all StudyBuddy CLI commands, options, and usage patterns.
./studybuddy.sh <command> <topic> [options]
<command>: One ofsummarize,research,explain<topic>: The topic or concept to process (use quotes for multi-word topics)[options]: Command-specific and global options
./studybuddy.sh summarize "machine learning"
./studybuddy.sh research "quantum computing" --depth DETAILED
./studybuddy.sh explain "neural networks" --format MARKDOWN --lang ENThese options are available for all commands:
Specify the output language.
- Values:
ES(Spanish),EN(English) - Default:
ES(Spanish) - Example:
--lang EN
Display help information for the command.
- Usage: Can be used with any command or globally
- Examples:
./studybuddy.sh --help- General help./studybuddy.sh summarize --help- Command-specific help
Generate structured educational summaries of topics.
./studybuddy.sh summarize "<topic>" [--level <level>] [--lang <language>]--level <level>
- Description: Difficulty level for the summary
- Values:
BEGINNER- Basic explanations with simple examplesINTERMEDIATE- More depth with practical examplesADVANCED- Detailed analysis with complex concepts
- Default:
BEGINNER
# Basic beginner summary in Spanish (default)
./studybuddy.sh summarize "artificial intelligence"
# Intermediate level in English
./studybuddy.sh summarize "machine learning" --level INTERMEDIATE --lang EN
# Advanced level summary
./studybuddy.sh summarize "deep learning" --level ADVANCEDThe summary includes:
- Title: Formatted topic title
- Topic: Original topic
- Level: Difficulty level
- Language: Output language
- Summary: Main content explanation
- Key Concepts: Important concepts list
- Examples: Practical examples
- Practical Applications: Real-world applications
Conduct comprehensive academic research on topics.
./studybuddy.sh research "<topic>" [--depth <depth>] [--lang <language>]--depth <depth>
- Description: Research depth and detail level
- Values:
BASIC- General overview with key pointsDETAILED- In-depth analysis with multiple perspectives and sources
- Default:
BASIC
# Basic research in Spanish (default)
./studybuddy.sh research "blockchain technology"
# Detailed research in English
./studybuddy.sh research "quantum computing" --depth DETAILED --lang EN
# Basic research on Spanish topic
./studybuddy.sh research "inteligencia artificial" --depth BASICThe research includes:
- Title: Research topic
- Depth: Research depth level
- Language: Output language
- Overview: General summary
- Key Findings: Main research findings
- Sources: Reference sources
- Related Topics: Connected concepts
Provide clear explanations of specific concepts.
./studybuddy.sh explain "<concept>" [--format <format>] [--lang <language>]--format <format>
- Description: Output format style
- Values:
PLAIN- Plain text without special formattingMARKDOWN- Markdown formatted with headers, lists, emphasis
- Default:
MARKDOWN
# Markdown explanation in Spanish (default)
./studybuddy.sh explain "neural networks"
# Plain text explanation in English
./studybuddy.sh explain "photosynthesis" --format PLAIN --lang EN
# Markdown explanation with specific language
./studybuddy.sh explain "redes neuronales" --format MARKDOWN --lang ESThe explanation includes:
- Title: Concept name
- Language: Output language
- Explanation: Detailed concept explanation
- Examples: Illustrative examples
- Related Concepts: Connected topics
All commands output directly to the console with:
- Colored status messages: Green for success, red for errors
- Clean formatting: Structured output without debug information
- Progress indicators: Loading messages during processing
When using --format MARKDOWN, output includes:
- Headers (
#,##,###) - Bold text (
**bold**) - Lists (
-,1.) - Code blocks (when relevant)
When using --format PLAIN, output includes:
- Simple text structure
- Basic organization
- No special markdown syntax
StudyBuddy CLI uses standard exit codes:
- 0: Success
- 1: General error (invalid arguments, API issues)
- 2: Invalid command usage
Set these in your .env file:
# Required
ANTHROPIC_API_KEY=your_api_key_here
# Optional
STUDYBUDDY_DEFAULT_LOCALE=es # Default language (es/en)
EMBABEL_MODELS_DEFAULT_LLM=claude-3-5-haiku-latest
EMBABEL_AI_ANTHROPIC_TEMPERATURE=0.3
EMBABEL_AI_ANTHROPIC_MAX_TOKENS=2000The default language is Spanish (ES). To change the default:
- Set
STUDYBUDDY_DEFAULT_LOCALE=enin.env - Or always specify
--lang ENin commands
1. API Key Not Found
Error: Anthropic API key not configured
- Solution: Create
.envfile withANTHROPIC_API_KEY=your_key
2. Invalid Command
Unknown command: sumary
- Solution: Check command spelling:
summarize,research,explain
3. Missing Topic
Error: Topic is required
- Solution: Provide topic in quotes:
"machine learning"
4. Invalid Options
Invalid level: beginer
- Solution: Use exact values:
BEGINNER,INTERMEDIATE,ADVANCED
For debugging issues:
- Check help:
./studybuddy.sh --help - Verify setup: Ensure Java 21+ and API key are configured
- Test connection: Try a simple command first
- Check logs: Look for error messages in output
- Command help:
./studybuddy.sh <command> --help - Global help:
./studybuddy.sh --help - Documentation: Check README.md for setup
StudyBuddy CLI can be used in scripts:
#!/bin/bash
# Generate multiple summaries
topics=("machine learning" "artificial intelligence" "neural networks")
for topic in "${topics[@]}"; do
echo "Generating summary for: $topic"
./studybuddy.sh summarize "$topic" --level INTERMEDIATE
echo "---"
done# Research multiple topics
./studybuddy.sh research "quantum computing" --depth DETAILED > quantum_research.md
./studybuddy.sh research "blockchain" --depth DETAILED > blockchain_research.md
./studybuddy.sh research "machine learning" --depth DETAILED > ml_research.md# Same topic in different languages
./studybuddy.sh summarize "artificial intelligence" --lang EN > ai_summary_en.md
./studybuddy.sh summarize "artificial intelligence" --lang ES > ai_summary_es.mdFor more information, see the main README.md documentation.