docs(8.0): Phase F — deep clean across 21 docs

Aligned every public doc to the 8.0 contract: filesystem + memory adapters
only, vector index provider terminology (config.vector with recall +
quantization + persistMode knobs), no cloud storage adapters, no closed-
source product names.

Tier 1 — heavier rewrites:
- docs/architecture/storage-architecture.md
- docs/architecture/data-storage-architecture.md
- docs/architecture/distributed-storage.md DELETED — content was 100%
  cloud-coordination examples with no 8.0 substance.
- docs/guides/distributed-system.md DELETED — same reason; no inbound refs.
- docs/SCALING.md rewritten for single-node guidance.
- docs/PLUGINS.md, docs/augmentations/{COMPLETE-REFERENCE,README}.md:
  HnswProvider→VectorIndexProvider, hnsw→vector key.
- docs/PERFORMANCE.md, docs/BATCHING.md cloud-detection + sharding
  sections replaced with single-node vector tuning + filesystem framing.

Tier 2 — surgical renames + cloud-section deletions:
- architecture/{index,initialization-and-rebuild,overview}.md
- transactions.md, DEVELOPER_LEARNING_PATH.md
- vfs/{VFS_API_GUIDE,COMMON_PATTERNS}.md
- api/README.md, guides/{inspection,import-flow}.md

Tier 3 — light edits:
- docs/README.md, architecture/augmentation-system-audit.md

MIGRATION-V3-TO-V4.md untouched (internal migration doc, no stale terms).
This commit is contained in:
David Snelling 2026-06-09 16:13:35 -07:00
parent 2626ab8d62
commit adda1570f3
22 changed files with 570 additions and 2658 deletions

View file

@ -80,17 +80,16 @@ const brain = new Brainy({
}
})
// ✅ Pattern 2: Cloud storage (production)
// ✅ Pattern 2: Filesystem (production default)
const brain = new Brainy({
storage: {
type: 's3',
bucket: 'my-vfs-data',
region: 'us-west-2'
type: 'filesystem',
rootDirectory: '/var/lib/brainy'
}
})
// ✅ Pattern 3: Auto-detection (recommended)
const brain = new Brainy() // Automatically chooses best storage
const brain = new Brainy() // Picks filesystem on Node, memory in browser
```
## 🔍 Search Patterns
@ -563,7 +562,7 @@ function vfsMiddleware() {
| ❌ **Avoid These Patterns** | ✅ **Use These Instead** |
|---------------------------|------------------------|
| Manual tree filtering | `vfs.getDirectChildren()` |
| Memory storage for files | Filesystem or cloud storage |
| Memory storage for files | Filesystem (snapshot off-site for backup) |
| Sequential file operations | Parallel processing with limits |
| Manual relationship tracking | Built-in `vfs.addRelationship()` |
| Loading entire directories | Paginated/lazy loading |

View file

@ -632,60 +632,20 @@ VFS works with all built-in Brainy storage adapters:
// Memory (testing/development)
const brain = new Brainy({ storage: { type: 'memory' } })
// Filesystem (local development)
// Filesystem (production default)
const brain = new Brainy({
storage: {
type: 'filesystem',
path: './brainy-data'
rootDirectory: './brainy-data'
}
})
// S3-compatible storage (production)
const brain = new Brainy({
storage: {
type: 's3',
bucket: 'my-bucket',
region: 'us-east-1'
}
})
// Cloudflare R2 (production)
const brain = new Brainy({
storage: {
type: 'r2',
accountId: 'your-account-id',
bucket: 'my-bucket'
}
})
// Google Cloud Storage (production)
const brain = new Brainy({
storage: {
type: 'gcs',
bucket: 'my-bucket',
projectId: 'my-project'
}
})
// Azure Blob Storage (production)
const brain = new Brainy({
storage: {
type: 'azure',
accountName: 'myaccount',
containerName: 'my-container'
}
})
// OPFS (browser-native persistence)
const brain = new Brainy({ storage: { type: 'opfs' } })
// TypeAware storage (optimized for entity types)
const brain = new Brainy({ storage: { type: 'typeaware' } })
// All work identically with VFS
// Both work identically with VFS
const vfs = new VirtualFileSystem(brain)
```
For off-site backup of the filesystem artifact, snapshot `rootDirectory` from your scheduler (`gsutil rsync`, `aws s3 sync`, `rclone`, `tar`).
**Custom Storage Adapters:** Redis, PostgreSQL, and other databases can be added via the [extension system](../api/EXTENSIBILITY.md). See `src/config/extensibleConfig.ts` for examples.
### Best Practices