Code 100x Faster with AI, Here's How (No Hype, FULL Process)

Cole MedinAbout 4 min readMar 31, 2025Watch original
THE SUMMARYAI-generated

Key Concepts

AI coding assistants, LLMs (Large Language Models), AI IDEs (Integrated Development Environments), MCP (Machine Communication Protocol) servers, Global Rules (system prompts), Planning and Task markdown files, Prompt Engineering, Testing (unit tests, mocking), Documentation, Version Control (Git), Docker, Deployment.

1. Golden Rules for Coding with AI

  • Use High-Level Markdown Documents: Employ planning, task, installation, and documentation files to provide context to the LLM.

  • Avoid Overwhelming the LLM:

    • Keep code files under 500 lines.
    • Start fresh conversations frequently.
    • Focus on one new feature or implementation per prompt.
  • Write Tests: Ask the AI to write tests after implementing each new feature.

  • Be Specific with Requests: Provide detailed context, including technologies, libraries, and desired output.

  • Write Docs and Comments: Have the LLM continuously update documentation and comments.

  • Implement Environment Variables Yourself: Do not trust the LLM with API keys or database security.

    • Example: The case of the developer who built a SAS with Cursor and got hacked due to trusting AI with security. "AI is not just an assistant it's the builder now." - Developer on March 15th. Two days later, the developer experienced hacks, API key misuse, and subscription bypasses.

2. Project Planning Phase

  • Create Planning and Task Files: Do this before writing any code.
    • Planning Document: Contains high-level vision, architecture, and constraints.
    • Task Document: Tracks completed and pending tasks, updated by the LLM.
  • Tool: Use chatbots like Claude Desktop for initial planning and file creation.
  • Example: Using Claude Desktop to create planning.md and task.md files for a Superbase MCP server.
  • Tip: Use multiple LLMs (e.g., via Global GPT) for planning and combine the results.

3. Global Rules (System Prompts)

  • Purpose: Provide high-level instructions to the AI coding assistant, avoiding repetitive prompting.
  • Example: Setting a global rule to always read the planning file at the start of a new conversation.
  • Implementation: Configure global or workspace-specific rules within the AI IDE (e.g., Windsurf's "Manage Memories").
  • Content: Include instructions on using markdown files, adhering to golden rules (file length, testing), style guidelines, and documentation practices.

4. Configuring MCP Servers

  • Purpose: Extend the AI IDE's capabilities with tools like web search and file system access.
  • Core Servers:
    • File System Server: Allows interaction with the file system beyond the current project.
    • Brave Search API: Enables web searches with AI-powered summarization of results.
    • Git Server: Facilitates version control and backups.
  • Example: Using the Git MCP server to create commits and save project states.
  • Additional Servers: Quadrant MCP server for long-term memory (RAG).
  • Configuration: Set up MCP servers within the AI IDE (e.g., Windsurf's "Configure MCP").

5. Initial Prompt and Project Start

  • Importance: The initial prompt sets the foundation for the entire project.
  • Specificity: Provide detailed documentation and examples.
  • Methods for Providing Examples and Documentation:
    • Built-in documentation features in AI IDEs (e.g., Windsurf's @MCP tag).
    • Web search via MCP servers (e.g., Brave API).
    • Manual provision of links to relevant repositories or documentation.
  • Example: Providing a link to a GitHub repo with an existing Python MCP server implementation.

6. Iterating on the Project

  • Golden Rule: Only ask for one change at a time to avoid overwhelming the LLM.
  • Example: Asking the LLM to create a README file and then separately asking it to create tests.

7. Testing

  • Importance: Ensures code quality and reliability.
  • Best Practices (incorporated into Global Rules):
    • Dedicated directory for tests.
    • Mocking calls to databases and LLMs.
    • Testing successful scenarios, error handling, and edge cases.
  • Example: Creating unit tests for each tool in the Superbase MCP server.

8. Deployment

  • Method: Use Docker (or similar) to package and deploy the application.
  • LLM Assistance: LLMs can generate Dockerfiles and provide deployment commands.
  • Example: Creating a Dockerfile for the Superbase MCP server and generating a README with deployment instructions.

9. Synthesis/Conclusion

The video presents a structured workflow for coding with AI, emphasizing the importance of clear planning, well-defined global rules, specific prompting, and continuous testing and documentation. By following this process, developers can leverage AI coding assistants to significantly enhance their productivity and build complex applications effectively. The Superbase MCP server example demonstrates the practical application of this workflow, showcasing how to go from ideation to deployment with AI assistance. The key takeaway is that AI coding assistants are powerful tools, but they require a strategic and disciplined approach to achieve consistent and high-quality results.

AI summaries can miss context or contain errors. Check important details against the original video.

Go a little deeper.

Have a question about this video? Load its transcript to open the video chat.