research-agency-csv-roundtrip

Research: agency CSV roundtrip — starter import/export

Metadata

Statusdone
Assignedagent-2375
Agent identity3184716484e6f0ea08bb13539daf07686ee79d440505f1fdf2de0357707034c3
Modelclaude:opus
Created2026-05-04T17:38:22.609744571+00:00
Started2026-05-04T18:38:52.552596226+00:00
Completed2026-05-04T18:44:53.170823616+00:00
Tagsagency,sync,research,federation, eval-scheduled
Eval score0.91
└ blocking impact0.94
└ completeness0.94
└ coordination overhead0.88
└ correctness0.92
└ downstream usability0.93
└ efficiency0.90
└ intent fidelity0.90
└ style adherence0.95

Description

Description

Agency distributes primitives via a 12-column starter CSV (primitives/starter.csv, columns per https://github.com/agentbureau/agency agency-primitive-extraction skill: type, name, description, quality, domain_specificity, domain, origin_instance_id, parent_content_hash, scope, parent_ids, generation, created_by). Workgraph stores per-primitive YAML files under .wg/agency/primitives/{components,outcomes,tradeoffs}/{hash}.yaml. Workgraph already has wg agency import (src/commands/agency_import.rs) and wg agency push/pull — investigate whether they accept agency starter CSV format and round-trip cleanly.

Specific things to investigate

  • Read src/commands/agency_import.rs end-to-end. What format does it accept today?
  • Does it understand: type discriminator column, quality, domain_specificity, domain (comma-separated), parent_ids (JSON list), generation, created_by enum?
  • Is there an export path? src/commands/agency_push.rs — does it emit CSV?
  • For each missing field on import, propose: defaults vs error vs ignore.
  • Verify import-manifest.yaml (saw at .wg/agency/import-manifest.yaml) — what does it track?
  • Round-trip test: take agency's starter.csv, import into wg, export, byte-diff against original. What changes? Why?

Deliverable

wg log entry with:

  • Current wg agency import CSV schema (cite agency_import.rs line ranges)
  • Diff vs agency 12-col schema
  • Concrete patch list: add columns, add parsers, add export path
  • Round-trip test plan (what files/fixtures, what equality predicate — byte-equal vs canonical-equal)
  • Note whether import is dependent on the hash-compat decision from research-agency-hash-compat (it almost certainly is)

Validation

  • Cites every line range in src/commands/agency_import.rs that handles a CSV column
  • Each of the 12 agency columns mapped to: handled / partial / missing in wg
  • Round-trip test fixture path proposed (tests/fixtures/agency-starter.csv or similar)
  • Documents the dependency on hash-compat (this work is gated on that decision)

Depends on

Required by

Log