WEB ATELIER (UDIT) Β· Learning by doing, with theory, practice and shared reflection
AI-Assisted Development: A Practical Guide
URL: https://ruvebal.github.io/web-atelier-udit/methodology/en/ai-practical-guide/
By RubΓ©n Vega BalbΓ‘s, PhD Β· 2026-01-03
π Table of Contents
- Philosophy: AI for Human Better Living
- Critical Considerations: The Broader Impact of AI
- The Docs-First Methodology
- The Prompt Architecture
- Implementation Reports
- MCP: The New Standard
- Practical Workflows
- The AI Ethics Protocol
- Quick Reference
- Mastery Progression
- π Related Resources
βAI is not the destination. AI is the compass that helps us navigate toward human flourishing.β
AI Assistance Disclosure: This guide was developed using the docs-first methodology it describes. Plans, prompts, and implementation reports were documented throughout. The pedagogy is grounded in classroom experience and critical reflection on AIβs role in education.
Philosophy: AI for Human Better Living
The Core Principle
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β β
β AI exists to AMPLIFY human intent, not replace it. β
β β
β Every AI interaction should answer: β
β β Does this help me understand more? β
β β Does this help me create something of value? β
β β Does this free me to focus on what matters? β
β β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
The Tao Developerβs AI Relationship
| Mindset | Practice |
|---|---|
| AI as Apprentice | You are the master; AI proposes, you decide |
| AI as Mirror | Use AI to reflect on your own thinking |
| AI as Amplifier | Let AI handle the mechanical; you handle the meaningful |
| AI as Teacher | Ask AI to explain, not just do |
| AI as Pair | Collaborate, critique, iterate together |
The Human Flourishing Test
Before every AI-assisted project, ask:
- Will this app reduce suffering or increase joy?
- Am I learning through this process, or just copying?
- Will future-me thank present-me for this work?
Critical Considerations: The Broader Impact of AI
Understanding What Youβre Using
Before leveraging AI assistants, understand the fundamentals:
How LLMs (Large Language Models) Work:
- Trained on massive text corpora from the internet
- Predict next tokens based on statistical patterns
- Have no true understanding, reasoning, or consciousness
- Can hallucinate (generate plausible but false information)
- Reflect biases present in training data
Current Technology Landscape:
- Models: GPT-4, Claude, Gemini, Llama, Mistral
- Interfaces: Chat (ChatGPT, Claude.ai), IDE integration (Copilot, Cursor), APIs
- Protocols: MCP (Model Context Protocol) for tool integration
Environmental Impact
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β π CLIMATE CONSIDERATIONS β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€
β β
β Training GPT-4 β 50,000 kg COβ (β 5 transatlantic β
β flights per passenger) β
β β
β Each query consumes energy. Ask intentionally. β
β β
β Consider: β
β β Is this query necessary? β
β β Could I find this in documentation? β
β β Am I using AI for learning or laziness? β
β β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
Data Privacy & Security
| Risk | Mitigation |
|---|---|
| Data leakage | Never paste API keys, passwords, personal data |
| Code exposure | Assume prompts may be logged/used for training |
| Client confidentiality | Anonymize sensitive business logic |
| GDPR/Privacy laws | Donβt process personal data through AI |
Tech Industry Concentration
Be aware of the monopolistic dynamics in AI:
- Chip manufacturing: NVIDIA dominates GPU market; TSMC manufactures most advanced chips
- Cloud infrastructure: AWS, Azure, GCP control AI compute
- Model development: Concentrated in few well-funded companies
- Data: Training requires massive datasets, favoring incumbents
Why this matters for developers:
- Vendor lock-in risks
- Dependency on proprietary systems
- Ethical implications of supporting concentration
- Consider open-source alternatives (Llama, Mistral, local models)
Ethical Frameworks
Our AI usage aligns with established ethical guidelines:
ACM Code of Ethics (Association for Computing Machinery):
- Contribute to society and human well-being
- Avoid harm
- Be honest and trustworthy
- Be fair and take action not to discriminate
- Respect privacy
- Honor confidentiality
UNESCO Recommendation on the Ethics of AI (2021):
- Proportionality: AI should not exceed what is necessary
- Safety and security: Prevent harm throughout lifecycle
- Fairness and non-discrimination: Promote social justice
- Sustainability: Assess environmental impact
- Right to privacy: Protect personal data
- Human oversight: Humans must remain in control
- Transparency and explainability: Understand AI decisions
- Responsibility and accountability: Clear attribution of responsibility
π References:
The Docs-First Methodology
The Two-Phase Approach (Non-Negotiable)
For any non-trivial task, AI interactions must follow:
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β THE TWO-PHASE APPROACH β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€
β β
β PHASE 1: PLANNING β
β βββββββββββββββββ β
β β Request AI to generate a development plan β
β β Document in ./docs/plan1.md, plan2.md, etc. β
β β Review and approve before proceeding β
β β
β PHASE 2: IMPLEMENTATION β
β βββββββββββββββββββββββ β
β β Only after plan is documented β
β β AI implements according to plan β
β β Generate implementation report β
β β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
Why this matters:
- Intentional architecture: Prevents aimless code generation
- Consciousness: Forces you to think before coding
- Audit trail: Documents decisions for future reference
- Learning: Planning teaches you to break down problems
- Debugging: At 2 AM, youβll thank yourself for the documentation
What Counts as βNon-Trivialβ?
| Trivial (no plan needed) | Non-trivial (plan required) |
|---|---|
| Fix a typo | Add a new feature |
| Adjust a color value | Refactor a module |
| Update a dependency | Implement authentication |
| Add a comment | Create a new component |
| Simple CSS adjustment | Change data architecture |
Rule of thumb: If it takes more than 15 minutes or touches multiple files, create a plan.
The Complete Workflow
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β THE DOCS-FIRST WORKFLOW β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€
β β
β 1. CREATE THE PLAN (docs/plan-feature-name.md) β
β βββ Confluence-style implementation plan β
β βββ Phases, outcomes, success criteria β
β β
β 2. GENERATE PROMPTS (one per phase) β
β βββ Each phase gets a tailored prompt β
β βββ Prompt includes context, constraints, output β
β β
β 3. EXECUTE WITH REPORTS β
β βββ AI generates implementation β
β βββ AI generates implementation report β
β βββ Human reviews, approves, commits β
β β
β 4. ITERATE & DOCUMENT β
β βββ Update plan with learnings β
β βββ Build knowledge base for future projects β
β β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
Plan Document Template
Location: docs/plan-[feature-name].md
# Implementation Plan: [Feature Name]
> **Created**: [Date] > **Status**: Draft | In Progress | Complete
> **AI Model**: Claude/GPT-4/Copilot
---
## 1. Overview
### Objective
[What are we building and why?]
### Success Criteria
- [ ] Criterion 1
- [ ] Criterion 2
- [ ] Criterion 3
### Constraints
- Time: [X days/weeks]
- Tech: [Required stack]
- Dependencies: [External systems]
---
## 2. Phases
### Phase 1: [Name]
**Goal**: [Single sentence]
**Deliverables**:
- [ ] Deliverable 1
- [ ] Deliverable 2
**Prompt for this phase**:
> [To be generated]
**Implementation Report**:
> [To be filled after execution]
---
## 3. Architecture Decisions
| Decision | Rationale | Alternatives Considered |
| -------- | --------- | ----------------------- |
| [Choice] | [Why] | [Other options] |
---
## 4. Learnings & Retrospective
[Fill after completion]
The Prompt Architecture
Prompt Anatomy
A well-structured prompt has layers:
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β LAYER 1: ROLE & CONTEXT β
β "You are a senior React developer helping me build..." β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€
β LAYER 2: KNOWLEDGE β
β "Here is the current codebase structure: [tree]" β
β "Here are relevant files: [contents]" β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€
β LAYER 3: TASK β
β "Implement [specific feature] following [pattern]" β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€
β LAYER 4: CONSTRAINTS β
β "Must use TypeScript, must not break existing tests" β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€
β LAYER 5: OUTPUT FORMAT β
β "Provide: 1) Code, 2) Explanation, 3) Report" β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
Prompt Patterns Library
1. The Explainer Prompt
Purpose: Understand existing code or concepts
Explain [concept/code] as if teaching a junior developer.
Include:
1. What it does
2. Why it exists
3. How it works step by step
4. Common pitfalls
5. Best practices
2. The Architect Prompt
Purpose: Design before implementing
I need to implement [feature].
Before writing code, please:
1. Propose 2-3 architectural approaches
2. Compare trade-offs of each
3. Recommend one with rationale
4. Outline the implementation steps
Do not write code yetβI want to understand the design first.
3. The Reviewer Prompt
Purpose: Critical analysis of code
Review this code critically:
[paste code]
Analyze for:
1. Correctness
2. Security vulnerabilities
3. Performance issues
4. Maintainability concerns
5. Suggested improvements
Be harsh but constructive.
4. The Rubber Duck Prompt
Purpose: Debug by explaining
I have a bug. Let me explain what I expect vs. what happens:
Expected: [description]
Actual: [description]
Code: [paste]
Don't give me the answer immediately.
Ask me questions that help ME discover the bug.
5. The Report Generator Prompt
Purpose: Document completed work
Based on the changes we just made:
Generate an implementation report including:
1. Summary of what was implemented
2. Files changed and why
3. Key decisions made
4. Potential issues or tech debt
5. Testing recommendations
6. Handoff notes for the next developer/phase
Implementation Reports
Why Reports Matter
Every AI-assisted implementation should produce a human-readable report documenting:
- What happened β Concrete changes made
- Why it happened β Decisions and rationale
- What was learned β Insights for future
- Whatβs next β Handoff information
The Report Cycle
βββββββββββββββββββββ
β ASK AI TO DO β
β something β
ββββββββββ¬βββββββββββ
β
βΌ
βββββββββββββββββββββ
β AI IMPLEMENTS + β
β GENERATES REPORT β
ββββββββββ¬βββββββββββ
β
βΌ
βββββββββββββββββββββ
β HUMAN REVIEWS β
β code + report β
ββββββββββ¬βββββββββββ
β
ββββββ΄βββββ
β β
βΌ βΌ
APPROVE REQUEST
& COMMIT CHANGES
β β
β ββββΊ (iterate)
β
βΌ
βββββββββββββββββββββ
β UPDATE PLAN DOC β
β with learnings β
βββββββββββββββββββββ
Report Templates
Quick Report (for small changes)
## Change: [Brief description]
**Files**: `src/component.tsx`, `src/utils.ts`
**Type**: Feature | Bugfix | Refactor
**Tested**: [ ] Manual [ ] Unit [ ] Integration
**Summary**: [1-2 sentences]
**AI-Assisted**: Yes/No
**Human Verified**: Yes/Pending
Full Report (for phases/features)
## Implementation Report: [Feature Name]
### 1. Summary
[2-3 sentences describing what was accomplished]
### 2. Changes Made
| File | Type | Description |
| --------- | -------- | --------------------- |
| `src/...` | Added | New component for... |
| `src/...` | Modified | Updated to support... |
### 3. Architecture Decisions
| Decision | Why | Alternatives |
| ------------ | --------------------------------- | -------------- |
| Used Zustand | Simpler than Redux for this scale | Context, Redux |
### 4. How It Works
[Brief explanation of the implementation]
### 5. Testing
- [x] Manual testing in browser
- [x] Unit tests for utilities
- [ ] E2E test (TODO)
### 6. Known Issues / Tech Debt
- [ ] Need to add error boundary
- [ ] Performance optimization for list
### 7. Next Steps
1. Wire to backend API
2. Add loading states
3. Write E2E test
### 8. Learning Notes
[What did I learn from this implementation?]
MCP: The New Standard
What is MCP (Model Context Protocol)?
MCP is an open standard for connecting AI models to external tools and data sources.
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β MCP ARCHITECTURE β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€
β β
β [AI Model] βββJSON-RPCβββΊ [MCP Server] β
β β β β
β β βββ Tools (write ops) β
β β βββ Resources (read) β
β β βββ Prompts (templates) β
β β β
β βββ Makes requests like: β
β "read file X" β
β "run command Y" β
β "query database Z" β
β β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
MCP Concepts
| Concept | Description | Example |
|---|---|---|
| Server | Exposes capabilities to AI | filesystem, database, API |
| Tool | Write operation | create_file, run_command |
| Resource | Read operation | read_file, list_directory |
| Root | Permission boundary | /project directory only |
| Prompt | Reusable template | βcode reviewβ, βexplainβ |
Why MCP Matters for You
- Standardization β One protocol, many tools
- Control β Define exactly what AI can access
- Auditability β All tool calls are logged
- Security β Capability-based permissions
MCP in Your Workflow
Traditional workflow:
Copy code β Paste into AI β Copy response β Paste back
β Context loss, manual effort, no audit trail
MCP workflow:
AI reads your files directly β Proposes changes β You approve
β
Full context, automated, auditable, controlled
Setting Up MCP (Claude Desktop Example)
// ~/.config/claude/claude_desktop_config.json
{
"mcpServers": {
"filesystem": {
"command": "npx",
"args": ["-y", "@anthropic/mcp-server-filesystem", "/path/to/project"]
}
}
}
MCP Best Practices
| Practice | Rationale |
|---|---|
| Scope roots narrowly | Only give access to project directories |
| Prefer resources over tools | Read-only is safer than write |
| Audit tool calls | Log what AI does in your codebase |
| Approve destructive ops | Never auto-run deletes or deploys |
Practical Workflows
Workflow 1: New Feature Development
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β WORKFLOW: New Feature β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€
β β
β 1. CREATE PLAN β
β βββ docs/plan-feature-name.md β
β βββ Define phases, success criteria β
β β
β 2. ASK AI TO REVIEW PLAN β
β βββ "Review this plan for gaps or risks" β
β βββ Iterate until solid β
β β
β 3. FOR EACH PHASE: β
β βββ Generate phase prompt β
β βββ AI implements + reports β
β βββ Human reviews, tests, approves β
β βββ Commit with descriptive message β
β β
β 4. RETROSPECTIVE β
β βββ Update plan with learnings β
β βββ Note patterns for reuse β
β β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
Workflow 2: Bug Investigation
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β WORKFLOW: Bug Investigation β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€
β β
β 1. DESCRIBE THE BUG β
β βββ Expected vs. actual behavior β
β βββ Steps to reproduce β
β β
β 2. ASK AI TO HELP INVESTIGATE (not fix) β
β βββ "What could cause this? Ask me questions." β
β βββ Let AI guide your debugging β
β β
β 3. IDENTIFY ROOT CAUSE (together) β
β βββ You confirm the hypothesis β
β βββ You understand WHY it happens β
β β
β 4. IMPLEMENT FIX β
β βββ AI proposes fix β
β βββ You verify it addresses root cause β
β βββ AI generates report β
β β
β 5. DOCUMENT β
β βββ Add to knowledge base β
β βββ Prevent similar bugs β
β β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
Workflow 3: Learning a New Concept
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β WORKFLOW: Learning β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€
β β
β 1. STATE WHAT YOU WANT TO LEARN β
β βββ "I want to understand [concept]" β
β β
β 2. ASK FOR EXPLANATION β
β βββ "Explain like I'm a junior developer" β
β βββ "What are the common misconceptions?" β
β β
β 3. ASK FOR MINIMAL EXAMPLE β
β βββ "Show me the smallest working example" β
β βββ Type it yourself (no copy-paste) β
β β
β 4. BREAK IT β
β βββ "What happens if I do X wrong?" β
β βββ Deliberately cause errors β
β β
β 5. TEACH BACK β
β βββ Explain the concept to AI β
β βββ "Is my understanding correct?" β
β β
β 6. DOCUMENT β
β βββ Write notes in your own words β
β βββ Add to personal knowledge base β
β β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
The AI Ethics Protocol
The Non-Negotiables
| Rule | Why It Matters |
|---|---|
| Understand every line | You are responsible for your code |
| Document AI usage | Transparency builds trust |
| No secrets in prompts | API keys, passwords, personal data |
| Verify security | AI doesnβt know your threat model |
| Cite in deliverables | Academic and professional integrity |
β οΈ README AI Disclosure Requirement
MANDATORY: Every repository using AI assistance MUST include a visible AI usage disclosure in the
README.mdfile.
## π€ AI Assistance Disclosure
This project was developed with AI assistance (Claude/GPT-4/Copilot).
**AI was used for:**
- [List specific uses: code generation, debugging, documentation, etc.]
**Human verification:**
- All code has been reviewed and understood by the author
- Security implications have been assessed
- The author takes full responsibility for the final implementation
**Methodology:** [Link to docs-first plans if applicable]
Why this matters:
- Academic integrity: Transparent disclosure prevents plagiarism accusations
- Professional ethics: Future employers and collaborators deserve honesty
- Learning accountability: You must understand what you submit
- Legal clarity: AI-generated code has complex IP implications
π¨ Repositories without AI disclosure that contain AI-generated code may be flagged for academic integrity review.
The Documentation Standard
// β
Good AI documentation
/**
* Formats price in cents to currency string.
* @ai-assisted Claude suggested using Intl.NumberFormat
* for i18n support. Verified against MDN.
*/
function formatPrice(cents: number): string {
return new Intl.NumberFormat('en-US', {
style: 'currency',
currency: 'USD',
}).format(cents / 100);
}
// β Bad: No indication of AI assistance
function formatPrice(cents) {
return new Intl.NumberFormat('en-US', {
style: 'currency',
currency: 'USD',
}).format(cents / 100);
}
The Verification Checklist
Before accepting AI-generated code:
- I can explain what this code does
- I understand WHY itβs written this way
- I have tested it manually
- I have checked for security issues
- I have verified edge cases
- I have considered accessibility
- I have documented the AI assistance
Quick Reference
Directory Structure for AI-Assisted Projects
project/
βββ docs/
β βββ plans/ # Implementation plans
β β βββ plan-auth.md
β β βββ plan-cart.md
β βββ reports/ # Implementation reports
β β βββ 2025-01-15-auth-phase1.md
β β βββ 2025-01-16-auth-phase2.md
β βββ prompts/ # Reusable prompts
β β βββ code-review.md
β β βββ explain-code.md
β βββ learnings/ # Knowledge base
β βββ react-patterns.md
β βββ security-notes.md
βββ src/ # Your code
βββ tests/
The Essential Commands
# Create plan document
touch docs/plans/$(date +%Y-%m-%d)-feature-name.md
# Create report after AI session
touch docs/reports/$(date +%Y-%m-%d)-phase-name.md
# Git commit with AI disclosure
git commit -m "feat: add auth flow (AI-assisted: Claude)"
The Essential Prompts
Start a session:
βIβm working on [project]. Hereβs my plan in docs/plan.md. Letβs implement Phase [N].β
Request a report:
βGenerate an implementation report for what we just did.β
End a session:
βSummarize what we accomplished and whatβs next.β
Mastery Progression
Level 1: Apprentice
- Use AI for explanations and simple code generation
- Copy-paste workflow
- Learning to ask good questions
Level 2: Practitioner
- Docs-first methodology
- Structured prompts with context
- Request and review implementation reports
- Beginning MCP integration
Level 3: Craftsperson
- Full MCP workflow with tool integration
- Build reusable prompt libraries
- Teach others your methodology
- Contribute to open source AI tooling
Level 4: Master
- Design AI-augmented systems
- Create organizational AI policies
- Mentor other developers
- Shape the ethics of AI in development
π Related Resources
| Resource | Description |
|---|---|
| The Tao of AI Development | ι Philosophical addendum on ethics, craftsmanship, and the eternal struggle against garbage code |
| Web Atelier Methodology | Core pedagogy and course structure |
| Atelier Prompt Collection | Curated prompts for web development |
| Portfolio Template Brief | Example project using this methodology |
| ACM Code of Ethics | Professional ethics guidelines |
| UNESCO AI Ethics | International framework for AI ethics |
βThe goal is not to replace your thinking with AI, but to amplify your thinking through AIβso that you may build things that matter for a better human living.β
Authorship: RubΓ©n Vega BalbΓ‘s, PhD (UDIT) Β· ORCID: 0000-0001-6862-9081 License: Content CC BY-NC-SA 4.0
Critical Coding for a Better Living.