Plannet - LLM-Powered Planning Assistant
Plannet is a command-line tool that helps you stay on top of your workload and backlog from where you work, the command line.
You can bring your own LLM, or use ours at https://www.plannet.dev/
Features
- π€ LLM integration for content generation
- π« Optional Jira integration
- π¨ Rich terminal UI for ticket selection
- βοΈ Configurable to bring your own model
- π Clipboard integration with customizable behavior
Installation
Prerequisites
- Go 1.19 or later
- A Jira account (optional)
- Access to an LLM API endpoint
Quick Install
# Download the latest release for your platform
# For macOS (Intel):
curl -L https://github.com/plannet-dev/plannet/releases/latest/download/plannet-darwin-amd64 -o plannet
# For macOS (Apple Silicon):
curl -L https://github.com/plannet-dev/plannet/releases/latest/download/plannet-darwin-arm64 -o plannet
# For Linux:
curl -L https://github.com/plannet-dev/plannet/releases/latest/download/plannet-linux-amd64 -o plannet
# For Windows:
curl -L https://github.com/plannet-dev/plannet/releases/latest/download/plannet-windows-amd64.exe -o plannet.exe
# Add to PATH based on your operating system:
# For macOS/Linux:
# Option 1: Move to /usr/local/bin (recommended)
sudo mv plannet /usr/local/bin/
# Option 2: Add to PATH in your shell configuration
# For bash/zsh (add to ~/.bashrc or ~/.zshrc):
export PATH=$PATH:$(pwd)
# For fish (add to ~/.config/fish/config.fish):
set -gx PATH $PATH (pwd)
# For Windows:
# Option 1: Move to a directory in your PATH (e.g., C:\Windows)
move plannet.exe C:\Windows\
# Option 2: Add directory to PATH
# 1. Open System Properties > Advanced > Environment Variables
# 2. Under "User variables", find and select "Path"
# 3. Click "Edit" and add the directory containing plannet.exe
# 4. Click "OK" to save
# Verify installation
plannet --version
Building from Source
# Clone the repository
git clone https://github.com/plannet-ai/plannet.git
cd plannet
# Install dependencies
go mod download
# Build the binary
./build.sh
Configuration
Create a .plannetrc file in your home directory with the following structure:
{
"base_url": "http://localhost:1234/v1/completions",
"model": "your-model-name",
"system_prompt": "Optional system prompt to guide the LLM",
"headers": {
"Authorization": "Bearer your-token"
},
"jira_url": "https://your-instance.atlassian.net",
"jira_token": "your-jira-token",
"jira_user": "your-email@company.com",
"copy_preference": "ask-every-time"
}
Configuration Fields
-
Required Fields:
base_url: The LLM API endpoint
model: The model identifier to use
headers: API authentication headers
-
Optional Fields:
system_prompt: A prompt that guides the LLM's behavior
jira_url: Your Jira instance URL
jira_token: Your Jira API token
jira_user: Your Jira username/email
copy_preference: How to handle clipboard copying (options: ask-every-time, ask-once, copy-automatically, do-not-copy)
Usage
Basic Usage
# Generate content with a custom prompt
plannet --prompt "Generate a test plan for a login feature"
# Use the generate command
plannet generate "Generate a test plan for a login feature"
# Use Jira integration (if configured)
plannet jira list
# Show version information
plannet --version
# Enable debug mode
plannet --debug
Using with Jira
When Jira integration is configured, Plannet will:
- Fetch your assigned tickets
- Present an interactive selection interface
- Use the selected ticket's information to generate content
- Optionally append your custom prompt
Output Management
- Generated content is displayed in the terminal
- Option to copy output to clipboard
- Color-coded output for better readability
- Configurable clipboard behavior
Development
Project Structure
.
βββ main.go # Application entry point
βββ cmd/ # Command implementations using Cobra
β βββ root.go # Root command definition
β βββ jira.go # Jira-related commands
β βββ track.go # Work tracking commands
β βββ generate.go # Content generation command
β βββ ... # Other command files
βββ config/ # Configuration management
β βββ config.go # Configuration struct and functions
β βββ copy_preference.go # Clipboard preference handling
β βββ config_test.go # Configuration tests
βββ llm/ # LLM interaction
β βββ generator.go # LLM request handling
βββ output/ # Output management
β βββ output.go # Output display and clipboard handling
βββ build/ # Build output directory
βββ build.sh # Build script
βββ test_track.sh # Test script for tracking feature
Note: The src/ directory contains an old implementation that is no longer used. See src/README.md for details.
Adding New Features
- Create a new command file in the
cmd/ directory
- Add your command to the root command in
cmd/root.go
- Update the README.md with new features
Running Tests
go test ./...
Contributing
- Fork the repository
- Create a feature branch
- Make your changes
- Submit a pull request
License
This project is licensed under the MIT License - see the LICENSE file for details.
Acknowledgments
Plannet
Plannet is a command-line tool for managing your daily tasks and projects. It integrates with various services like Jira and LLMs to help you stay organized and productive.
Features
- Task management with ticket prefixes
- Jira integration for viewing and creating tickets
- LLM integration for getting help with tasks
- Git integration for managing branches
- Secure storage for API tokens
- Rate limiting for API calls
- Input validation and file path sanitization
Installation
Prerequisites
- Go 1.21 or later
- Git (optional, for git integration)
Building from Source
- Clone the repository:
git clone https://github.com/plannet-ai/plannet.git
cd plannet
- Build the project:
go build
- Add plannet to your PATH:
# For bash/zsh (add to ~/.bashrc or ~/.zshrc)
export PATH=$PATH:$(pwd)
# For fish (add to ~/.config/fish/config.fish)
set -gx PATH $PATH (pwd)
Usage
Initial Setup
Run the initialization command to set up your configuration:
plannet init
This will guide you through setting up:
- Ticket prefixes for your projects
- Editor preferences
- Git integration settings
- Jira integration
- LLM integration
Managing Tasks
Create a new task:
plannet task "Implement user authentication"
List your tasks:
plannet list
Jira Integration
View your Jira tickets:
plannet jira list
View a specific ticket:
plannet jira view PROJ-123
Create a new ticket:
plannet jira create
LLM Integration
Start an interactive session with the LLM:
plannet llm
Send a single prompt:
plannet llm --prompt "How do I implement rate limiting in Go?"
Configuration
The configuration file is stored at ~/.plannetrc. It contains your preferences and settings for various integrations.
Security
Plannet implements several security features:
- Secure storage for API tokens using AES-GCM encryption
- Rate limiting for API calls to prevent abuse
- Input validation to prevent injection attacks
- File path sanitization to prevent path traversal attacks
Contributing
Contributions are welcome! Please feel free to submit a Pull Request.
License
This project is licensed under the MIT License - see the LICENSE file for details.