Train the Assistant

VFS Federation Studio 1.1.5 · Offline help

Prepare assistant CSV and JSON data

Make three independent inputs: training questions, benchmark questions, and reviewed answers. This page gives copy-ready examples and the exact Studio fields that use them.

1. Make a trusted data folder

New-Item -ItemType Directory -Force C:\VFS-AI\data | Out-Null

Save the following files as UTF-8. In Notepad, use Save as type: All files so Windows does not add .txt.

2. Create training.csv

The header must be exactly utterance,intent. Use one user question per row. Quote text containing a comma or quote. Each intent needs at least two training rows.

utterance,intent
"How do I add a file to a VFS image?",vfs_build
"Which build option maps a host file?",vfs_build
"What does a Monk fallback rule do?",monk_policy
"When is a Monk rule evaluated?",monk_policy

Intent names begin with a letter and may contain letters, numbers, dots, underscores, and hyphens. Keep one meaning per intent. The same normalized question cannot have two different intents.

3. Create benchmark.csv independently

The benchmark uses the same columns, but its questions must not be copied or lightly duplicated from training. It must cover every training intent.

utterance,intent
"What command packages local content as Federation Image v2?",vfs_build
"Explain the policy phase used after exact resolution",monk_policy
Why separate? Training rows teach the classifier. Benchmark rows measure questions it did not train on. Reusing a normalized training question is rejected as leakage.
Specialist-agent admission: this two-row sample only demonstrates the file format. A signed reconfiguration agent needs at least 8 independent benchmark rows, must meet the workspace accuracy floor, and must stay within its regression limit. Later versions under the same agent ID preserve the accepted labels and benchmark digest so the comparison remains meaningful.

What Studio rechecks from the retained branch bundle

Signing does not make the CSV claims trustworthy by itself. Before signing or Chronicle registration, Studio opens the actual training.csv, benchmark.csv, and model.json bytes and requires all of the following:

A mismatch stops the bundle before trust or accuracy policy can make it acceptable. Correct the source data and train into a new directory; do not edit a signed bundle.

4. Create knowledge.json

Knowledge contains the reviewed answer shown after an intent is recognized. Every training intent needs at least one article.

{
  "schema": "vfs-perl-nn-knowledge",
  "version": 1,
  "name": "My reviewed VFS help",
  "articles": [
    {
      "id": "vfs-build-basics",
      "title": "Build a VFS image",
      "intent": "vfs_build",
      "answer": "Map each virtual path to one reviewed host file, then run the VFS build command.",
      "tags": ["VFS", "build"],
      "queries": ["How do I package a file?"]
    },
    {
      "id": "monk-policy-basics",
      "title": "Understand Monk fallback",
      "intent": "monk_policy",
      "answer": "Fallback rules are considered only after the earlier resolution conditions permit that phase.",
      "tags": ["Monk", "policy"],
      "queries": ["What is a fallback rule?"]
    }
  ]
}

Optional specialist action recipes

A specialist knowledge article may add workspace_actions: an array of 1 to 64 exact, reviewed Chronicle action objects. Each object contains only kind, payload, and reason. The classifier retrieves the stored recipe; it does not synthesize IDs, names, or paths from the question. The Perl response exposes the array as proposal-only data and never executes it.

"workspace_actions": [
  {
    "kind": "rename_project",
    "payload": {
      "project_id": "exact-project-uuid-from-the-workspace",
      "name": "Production Federation"
    },
    "reason": "Use the reviewed production-facing root name."
  }
]

Permitted families cover project, source, mount, collision, and build-profile configuration. Shell/code execution, arbitrary writes, trust decisions, Monk-policy changes, proposal resolution, build, and release actions are not part of the schema. See the complete agent reconfiguration walkthrough before authoring a recipe.

5. Point Studio at the files

  1. Open AI Workbench… and choose Edit settings….
  2. On Datasets, put C:\VFS-AI\data\training.csv under Training sources, C:\VFS-AI\data\knowledge.json under Knowledge JSON, and C:\VFS-AI\data\benchmark.csv under Benchmark sources. Put one source path per line.
  3. On Security, set Workspace root to C:\VFS-AI. All three files must stay below this trusted root.
  4. Choose Apply settings, choose a configuration path such as C:\VFS-AI\assistant-config.json, then choose Save JSON.
  5. Choose Run preflight. Correct every error before training.

6. Understand what this small sample proves

The sample is useful for learning the file formats and preflight. It is not a releasable replacement for the package’s main assistant. A main candidate must retain all required Perl, VFS, Monk, Loom, Spindle, runtime, agent, and general-help intents and must pass the configured accuracy, macro-F1, and per-intent recall gates. Narrow data belongs in a specialist branch.

Accepted record formats

FormatShapeUse
CSVExactly utterance,intentEasiest to edit in a spreadsheet or text editor.
JSONA records array, or a vfs-perl-nn-training wrapper containing itGood for generated datasets.
JSONL / NDJSONOne {"utterance":"…","intent":"…"} object per nonblank lineGood for append-oriented tooling.

Preflight checklist