# Structuring Codebases for AI, Claude Code in GitHub, Scale Acquired! Granola Cafe, AI Rules and More MCP Page: https://stenobird.com/podcast/you-ve-been-a-bad-agent-7334728/structuring-codebases-for-ai-claude-code-in-github-scale-acquired-granola-cafe-ai-rules-and-more-mcp Text version: https://stenobird.com/podcast/you-ve-been-a-bad-agent-7334728/structuring-codebases-for-ai-claude-code-in-github-scale-acquired-granola-cafe-ai-rules-and-more-mcp.md Podcast: [You've Been a Bad Agent](https://stenobird.com/podcast/you-ve-been-a-bad-agent-7334728) Published: 2025-06-12T08:01:03+00:00 Episode link: https://share.transistor.fm/s/82181cce Audio file: https://media.transistor.fm/82181cce/ad5f58a3.mp3 Processing state: processed JSON: https://stenobird.com/v1/public/podcasts/you-ve-been-a-bad-agent-7334728/episodes/structuring-codebases-for-ai-claude-code-in-github-scale-acquired-granola-cafe-ai-rules-and-more-mcp Duration seconds: 3826 ## Resource To leverage AI coding agents effectively, you must move beyond simple file access and focus on structuring codebases with clear boundaries and trace-based context. The discussion explores how tools like Claude Code and MCP servers can be optimized through better documentation and rule-based instructions. ## Highlights - Main idea: Effective AI coding requires structuring codebases with clear boundaries and high-signal documentation to prevent model confusion - Practical takeaway: Use compact representations of key code transactions (traces) to teach agents which functions and files are critical to core logic - Failure mode: Models struggle with 'cleaning up' after themselves, necessitating strict rule files (like cursor-rules) to prevent unused variables and messy refactors - Technical insight: Using URL-based secrets in MCP servers can bypass the complexities and broken implementations of standard OAuth flows in AI clients - Tooling trend: The rise of subagents in tools like Shippie allows for parallel processing of complex coding tasks across different parts of a codebase ## Topics Claude Code, Model Context Protocol, AI Coding Agents, Software Architecture, MCP Servers, Codebase Refactoring, Developer Tooling, Automated Migrations ## Chapters - 1:00 — Tech Industry Drama & Meta's Scale Acquisition: A discussion on the implications of Meta's 49% stake in Scale AI and the strategic importance of data distribution. - 11:00 — Codebase Structure for Parallelization: Exploring how separating testing frameworks, UI components, and logic allows for better parallel processing in AI-driven development. - 15:00 — Automating Migrations with Claude Code: Using Claude Code and custom utility libraries to automate large-scale version migrations and codebase updates. - 20:00 — Stateful AI Tools and Gitli: Discussing the emergence of stateful development tools and the utility of Gitli for managing developer workflows. - 30:00 — Solving Authentication in MCP Servers: Analyzing the Supermemory MCP approach to using URL-based secrets to avoid broken OAuth and Bearer token implementations. - 44:00 — Enforcing Strict Coding Standards via Rules: The necessity of using rule files to prevent models from introducing unused variables and unoptimized code. - 53:00 — Context-Aware Agents and Trace-Based Learning: The future of coding agents: providing models with traces of key transactions to improve understanding of complex logic flows. ## Actions - request_transcript: `POST https://stenobird.com/v1/public/podcasts/you-ve-been-a-bad-agent-7334728/episodes/structuring-codebases-for-ai-claude-code-in-github-scale-acquired-granola-cafe-ai-rules-and-more-mcp/transcription-requests` — Idempotently request low-priority transcript generation for this episode. - read_markdown: `GET https://stenobird.com/podcast/you-ve-been-a-bad-agent-7334728/structuring-codebases-for-ai-claude-code-in-github-scale-acquired-granola-cafe-ai-rules-and-more-mcp.md` — Read the agent-friendly Markdown representation of this episode resource. A page view does not enqueue transcription. Agents should invoke `request_transcript` explicitly when they need this episode processed. ## Transcript Full transcripts are not published on public pages unless there is a clear rights basis.