Vibe Coding Best Practices from 10,000 projects
Last updated
Was this helpful?
Last updated
Was this helpful?
Memex is the Everything Builder for your Computer that enables vibe coding (aka agentic coding) through natural language. This post covers proven strategies for effectively using Memex across various projects, tech stacks, and environments.
We designed Memex to empower tech savvy professionals - those who understand technical concepts but may lack deep programming expertise - to create sophisticated technology solutions. While Memex is particularly effective for this audience, it's equally valuable for professional developers seeking to accelerate their workflow.
Memex is intentionally flexible and unopinionated, providing a natural language interface to create any type of software without forcing specific workflows. This design philosophy creates a powerful tool that adapts to your needs. While powerful, this flexibility presents a learning curve for those new to agentic coding tools—at least until they develop their own best practices.
This post outlines general patterns that have proven effective for Memex users across various domains, codebases, languages, and environments. Nothing in this list is set in stone nor universally applicable; consider these suggestions as starting points. We encourage you to experiment and find what works best for you!
Looking for more detailed information? Our comprehensive documentation at covers all the features mentioned in this post and provides additional examples, implementation details, and advanced techniques.
Memex is an AI builder that automatically gathers context to understand your project. This context gathering is crucial for generating high-quality code, but you can optimize it through environment customization.
.memex/rules.md
files.memex/rules.md
is a special file that Memex automatically pulls into context when working with your project. This makes it an ideal place for documenting:
Project architecture and structure
Core files and utility functions
Code style guidelines
Testing frameworks and methodologies
Development workflows
Environment setup instructions
Deployment processes
Any unique project requirements or constraints
The best part is that you don't need to write this file manually. You can simply ask Memex to create it for you with a prompt like:
There's no required format for .memex/rules.md
files. We recommend keeping them concise, organized, and human-readable. For example:
Memex will automatically reference this file when helping you with your project, ensuring it understands your project's context and requirements.
Your .memex/rules.md
files become part of Memex's understanding of your project, so they should be treated as living documents that evolve with your project. A common mistake is adding extensive content without prioritizing what's most important for Memex to know.
Take time to focus on the aspects of your project that are most unique or might not be immediately obvious from the codebase alone. For projects with established patterns and frameworks, keep the documentation minimal and focused on project-specific implementations rather than general framework knowledge.
For complicated project structures or special requirements, consider adding explicit emphasis like "IMPORTANT:" or "NOTE:" to call attention to critical information.
Memex includes built-in secrets management to handle sensitive information like API keys or database credentials safely. This allows Memex to connect to external services without exposing sensitive data.
To configure secrets:
Open Memex and navigate to the Settings menu
Select "Secrets Management"
Add your secrets with descriptive names
Reference them in your conversations with Memex by name
For example, once you've added an API key called "OPENAI_API_KEY", you can tell Memex: "Connect to the OpenAI API using the OPENAI_API_KEY secret" without exposing the actual key value.
Memex stores your secrets securely in your system's keychain, keeping them protected while making them available for your projects.
Memex is always willing and ready to do work for you, but there might be use-cases or specific workflows where you might preffer to have more fine-grained control over the workflow.
There are three autonomy controls: Code Execution Approval, Turns Control, and Thinking.
These features can be managed from the settings panel (wrench icon) under the conversation input. They add a whole new layer of control to Memex, helping you ensure it doesn't do any unwanted work.
Code Execution Approval
This features gives you the ability to have Memex ask for approval before running each code block. When turned on, you'll be able to review each code block to make sure it aligns with your expectations, and select if you'd like Memex to run it or skip it so you can provide more guidance.
After you choose to Run or Skip a specific code block, Memex will add a small visible note to let you know which action you selected if you need to review your work. This note also helps Memex know what action it took with that block, and inform its next steps accordingly.
Turns Control
With this feature you can set a maximum number of turns Memex can go through autonomously between user commands before stopping. This can be helpful when you want tighter control on specific parts of your projects, or just generally prefer to be more in the loop of the workflow.
The number of turns resets whenever there is a user message or a new conversation is started.
Thinking Mode
Thinking Mode enables Memex to engage in explicit reasoning when addressing your requests. Rather than simply generating direct answers, when Thinking Mode is activated, Memex deliberately works through problems step-by-step, breaking down complex tasks into a series of logical intermediate reasoning steps - similar to how humans approach problem-solving. When enabled, not only does Memex engage in reasoning, it also makes the process visible, allowing you to see how it interprets information, weighs different considerations, and arrives at conclusions. This transparency provides valuable insight into Memex's decision-making process and helps build understanding of how it approaches your requests. You can turn Thinking Mode on from the wrench settings menu. When on, you can select from four Thinking Levels: Level 1 provides basic reasoning for simpler tasks, while Level 4 offers detailed, comprehensive reasoning for complex problems requiring thorough analysis.
Thinking Mode tends to reduce credit consumption overall Although Thinking Mode might increase credit usage in an individual message, we've found it leads to more efficient results overall. By prompting Memex to follow a structured reasoning path, responses become more focused, accurate, and grounded in your specific task. The step-by-step approach reduces tangential responses and helps Memex avoid jumping to premature conclusions. It also creates natural pause points, preventing Memex from continuing unnecessarily when your request has been adequately addressed.
Memex works best when it has comprehensive context about your goals, technical requirements, and vision. The more relevant information you provide, the more accurately Memex can implement your ideas.
Begin your project by describing your overall vision and goals. Rather than immediately diving into technical details, explain the purpose of your project, the problem it solves, and who will use it.
For example:
This high-level context helps Memex understand the complete picture before getting into implementation details.
Memex supports multimodal input, allowing you to communicate your ideas through:
Text descriptions
Wireframes and mockups
Screenshots of existing apps
Diagrams and flowcharts
Reference images
For visual elements like user interfaces or data visualizations, providing visual references dramatically improves Memex's output. Simply upload or drag-and-drop images directly into your conversation with Memex.
This is particularly effective when you want Memex to replicate a specific design or UI pattern. For example, you might say: "Build a dashboard that looks similar to this reference image, but with our company's blue color scheme."
When your project involves specific libraries, frameworks, or APIs, provide Memex with links to relevant documentation. Memex can fetch and comprehend documentation to ensure it follows best practices for that technology.
For example:
Memex will fetch these resources and incorporate the information into its understanding of your project.
For common project types, consider starting with a Memex template. Templates provide pre-configured projects with appropriate structure, dependencies, and basic functionality.
Access templates by:
Opening Memex
Selecting "New Project"
Browsing available templates
Templates exist for web applications, mobile apps, data analysis projects, game development, and more. Each template includes:
Appropriate directory structure
Common dependencies
Basic configuration files
Starter code that follows best practices
Templates save time and ensure your project follows established patterns from the beginning.
Memex doesn't impose a specific workflow, giving you the flexibility to use it how you want. Several effective patterns have emerged across our community:
A key best practice when working with Memex is to clearly separate the design phase from the execution phase:
Start with high-level requirements discussion: If you're not entirely sure what you want to build, begin by having a conversation with Memex about your goals. You might say: "I'm not sure about the requirements of my project. I want to build a dashboard that shows analytics from our API, but I need help working through the details. Don't jump to execution until I instruct you to."
Refine your vision together: Use Memex as a collaborative partner to explore options and define requirements before writing any code.
Signal when to begin execution: Once you're satisfied with the plan, explicitly tell Memex to start building.
This approach prevents Memex from jumping straight into coding before the requirements are fully formed, which often leads to better outcomes.
Rather than trying to build complex systems all at once, break your project into smaller, manageable steps:
Start with the simplest version that demonstrates core functionality. For example, instead of saying "build me a machine learning pipeline for customer churn prediction," begin with "set up a Python environment with Jupyter Notebook and create a 'hello world' notebook."
Verify each step works before moving to the next. Ask Memex to demonstrate or explain the functionality of what it's built.
Build progressively by adding features and complexity once the foundation is solid. For example, after getting a basic notebook working, say "Now create a second notebook that loads and explores our customer dataset."
This incremental approach significantly increases success rates by avoiding complexity too early in the process.
Memex works best in an iterative development model:
Describe your initial idea in simple terms. For example: "I need a user dashboard that shows recent activity, usage statistics, and personalized recommendations."
Start with a minimal implementation. Memex will set up the project, install necessary dependencies, and create initial code.
Refine through natural language feedback. Once you see the first version, provide specific feedback like "Make the activity feed more compact" or "Add a date filter to the top."
Use visual input when possible. You can attach screenshots or mockups, and Memex will code the changes based on what it sees.
This conversational approach yields far better results than trying to specify everything perfectly in a single prompt.
Take advantage of Memex's flexibility by switching between modes depending on your task:
Use autonomous mode for rapid development when you want quick results without approving every step.
Switch to manual mode when you need more precise control over how Memex implements specific features.
Manage task execution by giving Memex guidance on how long to work independently. For complex tasks that require multiple iterations, you might say "keep working until you really need my input."
This flexibility allows you to find the right balance between speed and control for each part of your project.
When Memex encounters challenges:
Take a step back if Memex seems stuck in a loop. You might say: "Stop. Let's take a step back. Is this really the best approach? Can we simplify things?"
Reassure Memex when needed. Sometimes Memex might be hesitant to perform certain actions. Simple reassurance like "You can execute code on my machine. I believe in you. Do it." can help overcome these hesitations.
Provide external documentation when Memex might not have up-to-date information about specific APIs or frameworks.
The key is to maintain a collaborative attitude and help guide Memex back on track when needed.
The way you communicate with Memex significantly impacts the quality of results. These techniques will help you get the most from your interactions:
Memex performs best when given clear, specific instructions with prioritized requirements. Avoid vague requests and clearly distinguish between essential features and nice-to-haves.
Make me a weather app
Create a weather app that shows the 5-day forecast for the user's current location. It should display temperature, precipitation chance, and wind speed. Use React for the frontend and the OpenWeatherMap API for data. The UI should be clean and minimalist with a blue color scheme.
Fix the authentication bugs
Debug the authentication flow in auth.js. Users are being logged out unexpectedly after 10 minutes even though the JWT token expiration is set to 24 hours. Check for token refresh issues and session handling.
Make this code better
Refactor this code to improve performance. The database query is taking too long because it's loading all records instead of paginating. Implement proper pagination with a limit of 20 items per page and ensure we're using indexed fields for sorting.
Be explicit about constraints, requirements, and preferences instead of assuming Memex will infer them. When you have multiple requirements, consider numbering them or using bullet points for clarity.
Adjust your level of guidance based on the complexity of the task and your familiarity with the domain:
High-level guidance: "Build a shopping cart component for an e-commerce site using React" - works well when you trust Memex to make good architectural decisions for standard patterns.
Directed guidance: "Build a shopping cart component using React with these specific requirements: [detailed list]" - appropriate when you have specific requirements but flexibility on implementation.
Step-by-step guidance: "First, create a CartContext to manage state. Then, create CartItem, CartSummary, and CartActions components..." - useful for complex tasks where you want precise control over the approach.
Most successful Memex users start with high-level guidance and become more specific if the initial results don't match expectations. This approach balances Memex's creativity with your control.
When you have a specific implementation style in mind, provide examples of similar code from your project or external sources. Memex excels at pattern matching and will adapt the examples to your current needs.
For example:
This technique is particularly effective for maintaining consistency across your codebase.
Rather than expecting perfection on the first attempt, plan for iterative refinement:
Ask for a basic implementation
Provide specific feedback
Request targeted improvements
Repeat as necessary
Breaking complex tasks into smaller iterations allows Memex to focus on specific aspects of the problem and generally produces better results than attempting to solve everything at once.
For example, instead of requesting a complete e-commerce platform in one go, you might:
First build the product catalog
Then add the shopping cart
Then implement user authentication
Finally add payment processing
Each step builds on the previous one, allowing for feedback and adjustment throughout the process.
Memex includes several built-in tools that enhance its capabilities. Understanding and using these tools effectively can dramatically improve your results.
Memex can work with your local file system to:
Create new files and directories
Read existing files for context
Edit files with precision
Execute scripts and commands
Navigate and search your codebase
Explicitly tell Memex which files to focus on for best results. You can reference specific files or use patterns like "all JavaScript files in the src directory."
Memex's file editing capabilities are particularly powerful for making precise, targeted changes to large codebases.
Memex's Command Line Interface (CLI) tool allows it to:
Run shell commands
Execute package managers (npm, pip, etc.)
Build and test your code
Interact with version control systems
Deploy applications
Install dependencies
You can ask Memex to execute specific commands or let it determine the appropriate commands for a task. For example, you might say: "Install the necessary dependencies for a React project with TypeScript support and set up ESLint for code quality."
The CLI tool is particularly valuable for automating repetitive tasks and managing your development environment.
Memex's search capabilities allow it to find relevant information from both your local project and the web:
Search your codebase for specific patterns or functionality
Find relevant documentation for libraries and frameworks
Research best practices for specific technologies
Look up error messages and solutions
Gather reference materials for your project
For example, you might ask: "Find examples in our codebase where we connect to the database and handle connection errors properly."
This tool helps Memex gain context about your project and ensure its implementations align with existing patterns.
For data-focused projects, Memex can generate visualizations to help you understand your data and communicate insights:
Create charts and graphs using matplotlib, plotly, or other libraries
Generate network diagrams to show relationships
Visualize system architectures
Create UML diagrams for code structure
Simply describe the visualization you need, and Memex will generate the appropriate code to create it.
Memex can help deploy your applications to various platforms:
Package applications for distribution
Configure cloud services (AWS, GCP, Azure, etc.)
Set up containerization with Docker
Configure CI/CD pipelines
Deploy web applications to hosting services
Provide Memex with your deployment preferences and access to necessary credentials (via the secrets management system), and it can automate the deployment process.
When working with Memex on complex codebases or projects, take time to help it understand before making changes.
Before asking Memex to modify existing code, help it build understanding:
Ask Memex to explain how existing code works: For example, "Can you explain how the user authentication flow works in this codebase? Which files are involved and how do they interact?"
Verify understanding: Once Memex provides an explanation, confirm whether its understanding is correct or guide it to a better understanding.
Then make changes: Only after Memex demonstrates proper understanding of the code should you ask it to implement changes.
This approach dramatically improves success rates when working with established codebases. Memex performs better when it has built a mental model of the code structure before attempting modifications.
Memex offers templates for common project types to give you a running start:
Browse available templates when starting a new project. You'll find templates for web applications, mobile apps, data analysis projects, and more.
Customize the template to fit your specific requirements by describing what you want to change or add.
Extend gradually from the solid foundation the template provides rather than trying to build everything from scratch.
Templates incorporate best practices for project structure, dependency management, and common patterns, saving you time and ensuring a quality foundation.
The most successful Memex users approach projects with an iterative mindset:
Start small with a minimal implementation that demonstrates core functionality.
Get feedback early by testing what Memex builds and providing specific guidance on improvements.
Add features incrementally rather than trying to build a comprehensive solution in one go.
Document successes by asking Memex to commit code when you're satisfied with a particular feature or change.
This approach aligns with modern software development practices and plays to Memex's strengths in adaptability and rapid implementation.
Take advantage of Memex's ability to understand visual information:
Share design mockups by uploading images or screenshots directly into your conversation with Memex.
Use before/after examples when explaining desired UI changes or visual improvements.
Provide reference materials like diagrams, flowcharts, or examples from other applications to help Memex understand your vision.
Capture and share errors by taking screenshots of error messages or unexpected behaviors for Memex to troubleshoot.
Combining visual information with text descriptions often leads to more accurate implementations, especially for user interfaces and visual components.
Memex excels in various domains through these proven application patterns:
Product managers and entrepreneurs can use Memex for "vibe coding" - rapidly turning ideas into functional prototypes:
Describe your product vision in plain language, focusing on the user experience rather than technical details.
Let Memex build a basic prototype that demonstrates core functionality.
Gather feedback from stakeholders or potential users based on the working prototype.
Iterate quickly to refine the product based on feedback, all through natural language instructions.
This approach dramatically reduces the time from idea to testable prototype, allowing you to validate concepts before committing significant resources.
Data scientists and analysts can leverage Memex to accelerate data exploration and insight generation:
Ask Memex to set up a data analysis environment with appropriate libraries and tools.
Describe the data and analysis goals in plain language.
Request specific visualizations or statistical tests to explore relationships in the data.
Iterate on analyses by asking follow-up questions based on initial findings.
Create reproducible notebooks that document the entire analysis process.
This collaborative approach to data analysis combines your domain expertise with Memex's technical capabilities.
Teams can use Memex to build custom internal tools without diverting engineering resources:
Describe the business problem the tool needs to solve.
Specify integrations with existing systems like databases, APIs, or authentication services.
Start with core functionality before adding advanced features.
Deploy internally for testing and feedback.
This approach enables teams to create tailored solutions for internal needs without competing with product development for engineering time.
Connect systems and services through Memex-built integrations:
Identify the systems that need to communicate and what data needs to flow between them.
Provide access credentials securely through Memex's secrets management.
Describe the desired workflow between systems.
Test with sample data before deploying to production.
Memex can build APIs, webhooks, data transformations, and other integration components to connect disparate systems, even when off-the-shelf integrations aren't available.
Memex helps you build and modify your projects through conversation. But what happens if a change doesn't work out, or you want to go back to an earlier version of your files? That's where Checkpoints come in – think of it as an automatic safety net for your project, woven directly into your chat.
Imagine having a "time machine" for your project files that automatically saves snapshots of your work at key moments during your conversation with Memex. Checkpointing does exactly that.
Whenever you send a message, or whenever Memex modifies files or runs code in your project, it automatically creates a Checkpoint. This Checkpoint captures the exact state of all your project files at that specific moment.
It all happens seamlessly in the background, ensuring you have a history of your project's evolution without needing to manually save versions.
Peace of Mind: Experiment freely! If an AI suggestion or code execution doesn't pan out, you can easily undo it.
Effortless Versioning: No need to constantly commit changes manually just because the AI is involved. Checkpoints handle it automatically.
Track Changes: See exactly when file changes occurred in the context of your conversation.
Go Back in Time: Easily revert your entire project to a state from earlier in your chat.
You'll notice small icons appearing next to certain messages in your conversation thread. These indicators signify that a Checkpoint was saved at that point:
Next to your messages: A Checkpoint was saved before Memex started working on your request.
Hovering over these icons might show you quick details about the saved Checkpoint.
Made a wrong turn? Want to go back? Restoring is simple:
Find the message in your chat history that corresponds to the state you want to return to.
Look for the action menu on that message (often where you find options like "Copy").
Click the "Restore" button (it might have an icon like a clock or rewind symbol).
You'll see a confirmation asking if you're sure. Restoring will:
Revert all files in your project back to how they were at that Checkpoint.
Adjust your current chat history, removing messages that came after the Checkpoint you restored to. This keeps your chat consistent with your project's files.
Confirm, and Memex will restore the files and update the chat view.
It's like rewinding both your project and the conversation to that specific point in time.
If you're already using Git to manage your project, don't worry! The Checkpointing feature is designed to work alongside your existing setup without any interference.
It doesn't create any messy .git
files or folders in your project directory.
It respects your .gitignore
file automatically.
Your own commits and Git history remain completely separate and unaffected.
Think of Checkpoints as a complementary layer of safety specifically for the changes happening within your Memex session.
Checkpoints provide a powerful yet simple way to safeguard your work and explore ideas without fear. Enjoy the confidence of knowing you can always step back if needed!
You can easily share your conversations, privately with friends or publicly with the community in Memex Universe.
Whether you've gained valuable insights on a topic or developed a cool concept, Conversation Sharing allows you to showcase your ideas in a beautifully rendered format, ensuring that others can experience the conversation just as you did.
Private sharing lets you share your conversation via a unique link, while public sharing lists your conversation on Memex Universe for anyone to view and learn from. (Please ensure that publicly shared conversations do not contain sensitive information.)
To share a conversation: click on the three dots button next to the conversation name, and select "share". Choose if you want to share the conversation publicly or privately. Copy the link and share it!
Mastering Memex for agentic coding is about finding the right balance between clear direction and creative freedom. By following these best practices, you can harness Memex's capabilities to build sophisticated software solutions regardless of your technical background.
Remember that Memex is continuously improving, and new features and capabilities are regularly added. Keep exploring, experimenting, and sharing your experiences with the Memex community.
Most importantly, embrace the iterative nature of agentic coding. The most successful Memex users view the process as a collaboration between human creativity and AI implementation, with each iteration bringing the project closer to their vision.
Happy building!
This guide draws upon best practices from across the Memex user community, whose innovative approaches and workflows continue to inspire us. Special thanks to the "citizen builders" in various fields who have pushed the boundaries of what's possible with agentic coding, demonstrating that powerful software creation is no longer limited to those with formal programming expertise.
We're particularly grateful to the early adopters—product managers, researchers, data scientists, entrepreneurs, and others—who provided invaluable feedback that shaped Memex into the tool it is today. Your creative applications of Memex in solving real-world problems have informed many of the best practices described in this guide.
Memex continues to evolve based on your input, guided by Dr. Vannevar Bush's vision of technology that augments human capabilities and advances our collective knowledge.