Skip to main content

AI Coding Cheatsheet

What works in May 2024 | Download PDF

First presented by Ray Myers at Mendercon 2024, questions and suggestions welcome as we flesh this out!

Low-Risk Code Gen

  • Human in the loop
  • Prototyping / Greenfield
  • Boilerplate
  • Test-Driven Development (Ping Pong “Pairing”)

Insight

  • Question answering (kinda)
  • Semantic Search on docs and code
  • Commit Messages / PR summary
  • Low-level doc generation
  • Troubleshooting help (stack traces)

Safe Modifications

  • Tool-assisted refactoring
  • Adding type-hints
  • Backfilling Tests
  • Dark launches
  • Formal Methods

Incantations

  • Command-line invocations
  • Regex (Regular Expressions)
  • LaTeX
  • Markup and styling
  • Repetitive edits

Hazards

  • LLM-output is untrusted
  • Vendor data risk
  • Magical thinking
  • Anthropomorphizing
  • Unsustainable practices
  • Ignoring the craft

Making It Better

  • Prompting
  • Small Steps
  • Tools / Feedback
  • RAG (Retrieval Augmented Generation)
  • Fine-tuning
  • Better models ($$$)

Learn More

Practical Examples

Going Deeper

Long Live The Mend

  • Kill It With Fire by Marianne Bellotti (Book | Talk)
  • Modern Software Engineering by Dave Farley
  • Working Effectively With Legacy Code by Michael Feathers