Skip to content

Commit

Permalink
docs: Add emoji and 10th anniversary message to bmai.md
Browse files Browse the repository at this point in the history
  • Loading branch information
mbailey committed Jan 13, 2025
1 parent 2b76361 commit 5bdcf9f
Showing 1 changed file with 27 additions and 25 deletions.
52 changes: 27 additions & 25 deletions docs/bmai.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,12 @@
# bmai - Generate BMA commands from natural language
# 🤖 bmai - Generate BMA commands from natural language

> 🎉 **Experimental Feature Release - January 13, 2025**
> Released to celebrate Bash-my-AWS's 10th Anniversary! 🎂
> Using AI to help create the next decade of AWS CLI wizardry ✨
The `bmai` command helps generate bash-my-aws functions from natural language descriptions using AI. It reads the project's conventions and generates compliant functions that follow the established patterns.

## Prerequisites
## 📋 Prerequisites

- Install and configure [llm](https://github.com/simonw/llm)
```bash
Expand All @@ -13,31 +17,29 @@ The `bmai` command helps generate bash-my-aws functions from natural language de
llm keys set openai
```

## Usage
## 🚀 Usage

```bash
source ~/.bash-my-aws/lib/extras/bmai
bmai "list s3 buckets"
```

## Features
## Features

- Generates authentic bash-my-aws functions from natural language descriptions
- Follows established conventions and patterns
- Creates functions that integrate with existing BMA commands
- Saves generated functions for review
- 🗣️ Generates authentic bash-my-aws functions from natural language descriptions
- 📘 Follows established conventions and patterns
- 🔄 Creates functions that integrate with existing BMA commands
- 💾 Saves generated functions for review

## Installation
## 🔧 Installation

The `bmai` command is included in the extras directory:

```bash
source ~/.bash-my-aws/lib/extras/bmai
```

## Examples

*Note: BMA's `buckets` command already does this.*
## 💡 Examples

```bash
# Generate a command to list S3 buckets
Expand All @@ -63,22 +65,22 @@ s3-buckets() {
```

Generated functions are saved to:
`~/.bash-my-aws/contrib/ai/slop/`
`~/.bash-my-aws/contrib/ai/slop/` 📁

## How It Works
## ⚙️ How It Works

1. Takes a natural language description as input
2. Reads the project's CONVENTIONS.md file
3. Uses AI to generate a compliant function
4. Saves output to a file for review
5. Displays the generated function
1. 📝 Takes a natural language description as input
2. 📖 Reads the project's CONVENTIONS.md file
3. 🧠 Uses AI to generate a compliant function
4. 💾 Saves output to a file for review
5. 📺 Displays the generated function

The generated functions follow BMA conventions including:
- Standard argument handling
- Integration with skim-stdin
- Consistent output formatting
- Proper error handling
- Clear documentation and examples
- 🎯 Standard argument handling
- 🔄 Integration with skim-stdin
- 📊 Consistent output formatting
- ⚠️ Proper error handling
- 📚 Clear documentation and examples

Note: The example above shows the author's original response after realizing how simple and elegant the S3 bucket listing function could be while still following all conventions.
> 🗒️ Note: The example above shows the author's original response after realizing how simple and elegant the S3 bucket listing function could be while still following all conventions.

0 comments on commit 5bdcf9f

Please sign in to comment.