Skip to content

Latest commit

 

History

History
151 lines (110 loc) · 3.91 KB

File metadata and controls

151 lines (110 loc) · 3.91 KB

Huddle Command System

Huddle includes a powerful command system similar to Claude Code's slash commands. Commands start with / and provide quick actions and shortcuts.

Built-in Commands

  • /help - Show all available commands
  • /help <command> - Show detailed help for a specific command
  • /clear - Clear the current discussion messages
  • /info - Show information about the current discussion and system status
  • /export [format] - Export current discussion (formats: markdown, json, txt)
  • /quit - Quit Huddle (same as pressing 'q' or Ctrl+C)

Custom Commands

You can create your own commands by adding Markdown files to .huddle/commands/.

Command Structure

---
description: Brief description of what the command does
usage: /command <arg1> [optional_arg]
args: ["arg1", "optional_arg"]
---

Your command content here.

You can use variables like:
- $1, $2, etc. for command arguments
- $DISCUSSION for current discussion title
- $USER for current user
- $TIME for current time
- $DATE for current date

You can also include bash commands by prefixing lines with $:

$ echo "This will run as a shell command"
$ ls -la

Example Commands

The system creates example commands automatically:

/status - Shows system status and runs system commands

---
description: Show system status and current time
usage: /status
---

# System Status

**Current Time:** $TIME $DATE
**Active Discussion:** $DISCUSSION
**User:** $USER

$ uptime
$ df -h

/brainstorm <topic> - Starts a brainstorming session

---
description: Start a brainstorming session on a topic
usage: /brainstorm <topic>
args: ["topic"]
---

Let's brainstorm ideas for: **$1**

Here are some initial thoughts to get us started:

1. What are the key challenges with $1?
2. Who is the target audience?
3. What resources do we need?
4. What's the timeline?

What other aspects of $1 should we explore?

/summarize - Asks bots to summarize the current discussion

---
description: Summarize the current discussion
usage: /summarize
---

Can you provide a summary of our discussion "$DISCUSSION" so far? Please include:

- Key points discussed
- Decisions made  
- Action items
- Next steps

Command Types

Commands can behave in different ways:

  1. Message Commands - The command content becomes a user message that bots respond to
  2. System Commands - Show information or perform actions (like /clear, /info)
  3. Mixed Commands - Can include both text content and system commands

Variables

Available variables in custom commands:

  • $1, $2, $3, etc. - Command line arguments
  • $DISCUSSION - Current discussion title
  • $DISCUSSION_ID - Current discussion ID
  • $USER - Current user name ("You")
  • $TIME - Current time (HH:MM format)
  • $DATE - Current date (YYYY-MM-DD format)

Shell Commands

Lines starting with $ are executed as shell commands and their output is included in the response:

Check disk space:
$ df -h

Show current directory:
$ pwd

List files:
$ ls -la

Usage Tips

  1. Test commands - Use /help <command> to see how your custom commands will work
  2. Keep it simple - Commands are meant to be quick shortcuts
  3. Use descriptive names - Make command names memorable and clear
  4. Document your commands - Use the description field to explain what each command does
  5. Organize by purpose - Group related commands with consistent naming

Examples in Practice

/help                           # Show all commands
/brainstorm mobile app          # Start brainstorming session
/status                         # Check system status  
/clear                          # Clear current chat
/export markdown                # Export as markdown
/summarize                      # Get discussion summary

The command system makes Huddle more powerful by allowing you to create custom workflows and shortcuts tailored to your team's needs.