home/coding/prompt-and-context-engineering-2

Prompt And Context Engineering

GPTClaudeDeepSeek··1,359 copies·updated 2026-07-14
prompt-and-context-engineering-2.prompt
# 1.1 Prompt & Context Engineering

**🌐 Language:** **English** · [Українська](./1.1-prompt-and-context-engineering.ua.md)

**Block:** Foundations
**Practice project:** [`phaser-memory-cards-MFE`](https://github.com/smnvsergii/phaser-memory-cards-MFE) — a Phaser 3 + Vite + TypeScript memory game that also runs as a microfrontend inside a Game Hub shell.

> Goal of this note: show *how* I structure prompts, feed context, and refine iteratively — using real tasks from the game, not toy examples.

---

## What this block covers

| Skill | One-line definition |
|-------|---------------------|
| Prompt structure | Giving the model a role, a goal, constraints, and the expected output format instead of a vague request. |
| Passing context | Deciding *what* slice of the codebase the model needs to see, and feeding exactly that — no more, no less. |
| Iterative refinement | Treating the first answer as a draft and steering it with targeted follow-ups instead of restarting. |

---

## 1. Prompt structure

A weak prompt describes a wish. A strong prompt describes a **role, a goal, hard constraints, and the output format**.

### Anti-pattern (vague)

when to use it

Community prompt sourced from the open-source GitHub repo smnvsergii/ai-driven-frontend (MIT). A "Prompt And Context Engineering" style prompt — adapt the placeholders and specifics to your task. Imported as-is and not independently retested here, so check the output before relying on it.

tags

codingcommunitydeveloper

source

smnvsergii/ai-driven-frontend · MIT