Context Generation
Context is the foundation of effective AI assistance. Bootspring automatically generates a CLAUDE.md file that captures everything your AI assistant needs to know about your project.
Why Context Matters#
Without context, AI assistants give generic advice. With context, they provide tailored guidance specific to your project's tech stack, conventions, and patterns.
Without Context#
You: "Create a form component"
AI: "Here's a generic React form..." (may not match your patterns)
With Context#
You: "Create a form component"
AI: "Based on your Next.js 14 project using React Hook Form, Zod,
and Tailwind, here's a form following your existing patterns..."
What Gets Generated#
The CLAUDE.md file contains:
Project Overview#
Tech Stack#
Project Structure#
Conventions#
Commands#
Guidelines#
How Detection Works#
Bootspring scans your project to detect:
Framework Detection#
| Files Detected | Framework |
|---|---|
next.config.* + app/ | Next.js 14 (App Router) |
next.config.* + pages/ | Next.js (Pages Router) |
vite.config.* | Vite + React/Vue |
gatsby-config.* | Gatsby |
remix.config.* | Remix |
nuxt.config.* | Nuxt |
angular.json | Angular |
Database Detection#
| Files Detected | Database |
|---|---|
prisma/schema.prisma | Prisma |
drizzle.config.* | Drizzle |
typeorm.config.* | TypeORM |
mongoose in package.json | MongoDB |
Auth Detection#
| Files/Packages | Provider |
|---|---|
jose | JWT sessions |
next-auth | NextAuth |
@auth0/nextjs-auth0 | Auth0 |
@supabase/auth-helpers | Supabase |
Testing Detection#
| Files Detected | Framework |
|---|---|
vitest.config.* | Vitest |
jest.config.* | Jest |
playwright.config.* | Playwright |
cypress.config.* | Cypress |
Generating Context#
Initial Generation#
When you initialize Bootspring:
This creates CLAUDE.md automatically.
Manual Regeneration#
Regenerate anytime:
Or ask your AI assistant:
Regenerate the CLAUDE.md context file.
Force Regeneration#
Override existing context:
Customizing Context#
Custom Sections#
Add team-specific information in bootspring.config.js:
Excluding Files#
Prevent certain files from being analyzed:
Explicit Stack#
Override auto-detection:
Include Extra Files#
Include additional context sources:
When to Regenerate#
Regenerate your context when:
| Change | Impact |
|---|---|
| New dependencies added | Stack detection |
| Project structure changed | Structure section |
| New coding standards | Conventions section |
| New team members | Custom guidelines |
| Major feature added | Project overview |
| Config files changed | Various sections |
Best Practices#
1. Commit CLAUDE.md#
This ensures all team members share the same context.
2. Review Generated Content#
After generation, review for accuracy:
- Is the tech stack correct?
- Are conventions captured?
- Any missing patterns?
3. Add Domain Knowledge#
Help AI understand your business:
4. Keep It Updated#
Set a reminder to regenerate:
- After sprints
- Before major features
- When onboarding team members
5. Don't Over-Include#
Keep context focused. Too much information can confuse AI assistants.
Viewing Context#
Via CLI#
Via AI Assistant#
Show me the current project context.
Via File#
Simply open CLAUDE.md in your editor.
Troubleshooting#
Context Not Generated#
- Check you're in project root
- Ensure package.json exists
- Run with verbose:
bootspring generate --verbose
Wrong Stack Detected#
Override in config:
Context Too Large#
Add exclusions:
Missing Conventions#
Add custom sections for team-specific conventions.
Related#
- Understanding Context - Getting started guide
- bootspring_generate - Generation tool reference
- Configuration - Full config options