Working with Existing Code & Best Practices

Use Cases:

  • Explain this function.
  • Refactor this code to improve performance.
  • Adapt this script using numpy.

Key insights:

  • Copilot uses what you have open.
  • It does NOT fully understand the whole repo automatically.

Tip: Open multiple relevant files.

Best practices

  • Boilerplate code.
  • Quick scripts.
  • Code exploration.

Limitation

  • Incorrect or hallucinated code → always review.
  • Security / sensitive data.
  • Hidden assumptions.

Copilot is not going to make you a better engineer, but it can make you way more efficient