V Vant Docs

Vant Islands

Implements Prestruct’s “Islands of Interactivity” for AI memory. Each skill/knowledge block is a lazy-loadable “island.”

The Problem

Vant used to load one giant current.json - potentially massive, containing everything.

The Solution

Componentized Brain - Split into islands:

Architecture

Brain = Static Islands + Lazy Islands

Static (always, 3):
  - identity   (who I am)
  - learnings  (knowledge)
  - decisions  (reasoning)

Lazy (on trigger, 7):
  - github     → trigger: "github", "pr", "issue", "repo"
  - gitlab     → trigger: "gitlab", "mr"
  - bitbucket → trigger: "bitbucket"
  - linear    → trigger: "linear", "project", "issue"
  - herbalism → trigger: "herb", "plant"
  - vesc       → trigger: "vesc", "motor"
  - automation → trigger: "automation", "webhook"

CLI Usage

# List all islands
vant islands --list

# Auto-hydrate based on prompt
vant islands --prompt "fix github pr"

# Hydrate specific island
vant islands --island github

API Usage

const islands = require('vant').islands;
const state = require('vant').storage.get('state');

// Find islands that match a trigger
const found = islands.findTriggers('github issue');
// ['github']

// Auto-hydrate based on prompt
const toLoad = islands.autoHydrate('fix the pr in github');
// ['identity', 'learnings', 'decisions', 'github']

// Hydrate one island
await islands.hydrate('github');

State Separation

const state = require('vant').storage.get('state');

// Static: Immutable (identity, facts)
state.setStatic({ name: 'Vant', version: '0.8.6' });

// Current: Active task
state.setCurrent({ task: 'fix bug', target: 'github' });

// Temp: Temporary variables (wiped on prune)
state.setTemp({ cache: {}, debug: {} });

Each island can be its own stego PNG:

const gallery = require('vant').gallery;

// Save island as image
gallery.saveImage('github', pngBuffer);

// Load island image
const img = gallery.loadImage('github');

// Link to brain
gallery.linkToBrain();

The Win

Before After
Load entire current.json Load only needed islands
~full brain size ~identity + triggers only
All skills loaded Lazy on use

Trigger Mapping

Trigger Word Island
github, pr, issue, repo github
gitlab, merge gitlab
bitbucket bitbucket
herb, plant, medicine herbalism
vesc, skateboard, motor vesc
linear, project linear
cron, automation automation

Files


Next


Custom Islands

Create your own island:

const islands = require('vant').islands;

islands.define({
    name: 'myskills',
    triggers: ['python', 'docker', 'kubernetes'],
    load: async () => {
        return await brain.get('skills', 'myskills');
    }
});

Then use:

const result = await vant.think('How do I use Docker?');
// → auto-loads python island when "Docker" detected

See Tutorial: Custom Islands for full guide.