Skip to main content

File Structure

braito/
src/
cli/
index.ts ← entry point, argument parsing
commands/
scan.ts
generate.ts
watch.ts
mcp.ts
ui.ts

core/
config/
loadConfig.ts
defaults.ts
configSchema.ts ← Zod validation schema

scanner/
scanRepository.ts
discoverFiles.ts

ast/
parseFile.ts
analyzerRegistry.ts
types.ts ← LanguageAnalyzer interface
analyzers/
ts/
extractImports.ts
extractExports.ts
extractSymbols.ts
extractHooks.ts
extractEnvUsage.ts
extractApiCalls.ts
extractComments.ts
extractDynamicImports.ts
python/
pythonAnalyzer.ts
go/
goAnalyzer.ts

graph/
buildDependencyGraph.ts
buildReverseDependencyGraph.ts
resolveImportPath.ts
loadBundlerAliases.ts
detectCycles.ts

git/
getFileHistory.ts
getCoChangedFiles.ts
getGitSignals.ts

tests/
findRelatedTests.ts
loadCoverage.ts

cache/
computeHash.ts
cacheStore.ts
isNoteStale.ts
analysisStore.ts

llm/
synthesizeFileNote.ts
retry.ts
provider/
factory.ts
anthropic.ts
openai.ts
ollama.ts
types.ts

output/
buildBasicNote.ts
buildIndex.ts
writeJsonNote.ts
writeMarkdownNote.ts
writeIndexNote.ts
diffNotes.ts

utils/
logger.ts
progress.ts
concurrentMap.ts

types/
project.ts
ai-note.ts
schema-version.ts

vscode-extension/
src/
extension.ts
noteReader.ts
hoverProvider.ts
decorationProvider.ts
notePanel.ts
package.json
tsconfig.json

tests/
ast/
cache/
cli/
config/
e2e/
git/
graph/
llm/
mcp/
output/
scanner/
tests/
utils/

docs/
assets/
braito.png
ARCHITECTURE.md
DOMAIN_MODEL_AND_SCHEMA.md
FILE_STRUCTURE.md
LLM_STRATEGY.md
PROJECT_DESCRIPTION.md
RECOMMENDATIONS.md
ai-notes.config.example.ts.md

.github/
workflows/
ai-notes.yml

.ai-notes/ ← generated, do not edit manually
cache/ ← generated, do not edit manually

ai-notes.config.ts
package.json
tsconfig.json
bun.lockb
CLAUDE.md
README.md
README.pt-BR.md
CHANGELOG.md
TODO.md

Layer rules

src/cli

Responsible only for orchestrating commands and user input. No business logic.

src/core

All business rules live here. Each subdirectory is a self-contained module.

src/core/ast

Modular by language. Add a new language by implementing LanguageAnalyzer and registering in analyzerRegistry.ts.

src/core/llm

Separate: provider, synthesizer, retry logic. Providers are swappable without changing the pipeline.

src/core/output

All output formats are isolated here.

.ai-notes/ and cache/

Generated by the tool. Never edit manually — they are regenerated on each run.