Reference · Enterprise CLI

Enterprise CLI

Enterprise adds source inspection, record preparation, A–E experiment control, final approval, and agent query routing to the Rust corec command.

Packaging and invocation

Customers invoke corec. The licensed package includes a private Rust executable that corec discovers as its Enterprise implementation. COREC_EE_BIN can select a non-default extension location for development or controlled packaging.

shellCoreCortex Enterprise
corec strategy list
corec corpus classify --help
corec schema advise --help
corec dataset prepare --help
corec design --help
corec manifest --help
corec query --help

Inspect the customer strategy inventory

The base Enterprise build reports the four Core chunkers and an empty optionalPacks list. An enablement adds the packs selected for the customer's datasets. Dataset materialization checks this inventory, and its receipt binds each Stage B configuration to an available processor.

CommandPurposePrimary output
corec strategy listShow Core strategies and optional packs enabled in this buildStrategyInventory JSON
corec strategy describe <pack-id>Inspect compatibility, licensing, record types, processors, versions, and configuration schemaChunkingStrategyPackDescriptor JSON

Understand the source corpus

All three commands treat the source as immutable. Exploration hashes distinct values and omits examples by default. Enrichment adds explicit derived fields and keeps their origin visible.

CommandRequired inputsPrimary output
corec corpus classify--input JSONL|Parquet, --output directoryclassification.json and candidate dataset partitions
corec corpus explore--input JSONL|Parquet, --output fileFieldProfile JSON; --include-examples is optional
corec corpus enrich--input structured JSONL|Parquet, --output JSONLDeterministically enriched rows with provenance

JSONL and Parquet support

Enterprise reads source exports in JSONL or Apache Parquet. Classification, exploration, deterministic enrichment, schema advice, and canonical dataset preparation use the same Rust source reader for both formats. Parquet values and explicit nulls are preserved through Arrow record batches.

Reviewable and portable outputs remain JSON or JSONL: canonical records, schema registries, golden judgments, ranked results, misses, and evaluation reports. corec dataset prepare-batch consumes canonical records.jsonl and emits bounded API request parts. This gives analysts inspectable evidence while allowing source teams to deliver efficient columnar exports.

shellCoreCortex Enterprise
corec corpus classify --input exports/documents.parquet --output engagement/00-classification
corec corpus explore --input exports/documents.parquet --output engagement/02-profile.json
corec schema advise --input exports/documents.parquet --name reference-documents --output engagement/03-advice.json
corec dataset prepare --input exports/documents.parquet --schema engagement/04-registered-schema.json --name reference-documents --provider customer-export --observed-at 2026-08-26T00:00:00Z --allow group:reader --output engagement/05-dataset
StageAccepted inputProduced artifact
Classify / exploresource.jsonl or source.parquetClassification JSON, partitions, and field profile JSON
Enrich / advisestructured JSONL or ParquetEnriched JSONL and pipeline advice JSON
Dataset preparesource JSONL or ParquetCanonical records.jsonl plus dataset.json
Prepare batchCanonical records.jsonlrequest.json parts and integrity receipts
Golden and evalReviewable JSONLFragments, judgments, results, misses, and reports

Advise and approve schema

CommandRequired inputsPrimary output
corec schema advise--input, --name, --outputPipelineAdvice with proposed identity, text, types, attributes, and transforms
corec schema register--suggestion, --registry, --approved-byAppend-only registry revision; optional --output registered schema

Prepare and ingest datasets

Preparation requires an explicit access decision for every record set. It never infers reader permissions from customer fields. The resulting requests remain portable across adapter implementations.

CommandKey optionsPrimary output
corec dataset prepare--input, --schema, --name, --provider, --observed-at, plus --allow repeated or --publicCanonical records.jsonl and dataset manifest
corec dataset chunk--input, --output, --strategy, optional --configurationReviewable fragment JSONL and a hashed ChunkingRun receipt
corec dataset prepare-batch--input, --name, --configuration-revision, --mapping-fingerprint, --outputBackend-neutral request parts, hashes, and prepared manifest
corec dataset ingestPrepared batch plus canonical database and adapter settingsDurable application and projection receipt
corec dataset ingest-demo--database-url, --config, --batch, --design-configuration, --outputStarter-only PostgreSQL and memory-projection receipt
corec validate-batchPrepared request JSONOffline public-contract validation

Create review candidates and run evaluations

The evaluators are public Core commands because their evidence contracts should remain independently inspectable. Enterprise prepares and coordinates the experiment workflow around them.

CommandPurposeGate evidence
corec golden generateBuild candidate judgments from exact materialized fragmentsStable fragment IDs; candidates remain unreviewed
corec eval retrievalScore BM25 or supplied lexical, semantic, or hybrid rankingsHit@K, misses, expected-empty behavior, configuration and projection-receipt binding
corec eval generationScore answers, citations, facts, abstention, and supplied faithfulnessQuality, faithfulness, abstention, model and judge identities

Control stages A through E

record-result also accepts --converter-audit, --chunk-audit, --ingestion-evidence, --generation-report, and --latency-ms. Ingestion evidence is mandatory for A–C candidates and for D, where it must be the exact selected C receipt.

CommandPurposeEvidence requirement
corec design initValidate a declared search space and plan Stage A--search-space, --output
corec design record-resultAttach one evaluator result to a planned experiment--state, --experiment-id, --retrieval-report, --results; audits and receipts as applicable
corec design advanceSelect the stage winner and plan the next experimentsComplete equal-sample results for the active stage
corec design audit-convertersRecord concrete converter provenance and representative review--fragments, --requested-converter, --reviewed-by, repeated --representative
corec design audit-chunksMeasure exact token and split distributions--fragments, --output
corec design finalizeBind the A–D optimum to full Stage E reportsExact selected configuration, ready ingestion receipt, receipt-bound retrieval, and optional corpus report
corec design demo-stagesExercise controller wiring with the shipped synthetic fixtureArtifacts are labeled synthetic_demo

Emit the certification manifest

Add --corpus-report for a multi-collection corpus. The result is certified only when every immutable gate passes; otherwise it is blocked and carries actionable reasons.

shellCoreCortex Enterprise
corec manifest emit \
  --classification <classification.json> \
  --sample-review <sample-review.json> \
  --profile <profile.json> \
  --advice <advice.json> \
  --schema-registry <schema-registry.jsonl> \
  --dataset <dataset.json> \
  --ingestion <applied-receipt.json> \
  --judgments <reviewed.jsonl> \
  --design-decision <design-decision.json> \
  --retrieval-report <report.json> \
  --generation-report <generation-report.json> \
  --certified-by <principal> \
  --retrieval-target 0.55 \
  --faithfulness-target 0.80 \
  --qualified-answer-target 0.80 \
  --output <manifest.json>

Route agent queries

Optional flags are --dataset for dataset scope, --filters for a JSON object, --global-search for an explicit global scope, and --output for durable JSON. The routing decision can select lexical, hybrid, or bounded graph followed by evidence retrieval. Relationship intent always carries requiresAgentReview: true.

shellCoreCortex Enterprise
corec query route \
  "Which authorities connect these two matters?" \
  --filters ./request-scope.json \
  --output ./routing-decision.json

Artifact and security rules

  • Input exports remain read-only and carry SHA-256 identity into derived artifacts.
  • Every command writes to an explicit file or directory and produces machine-readable JSON or JSONL.
  • Access uses explicit --allow principals or --public; customer fields never silently become permissions.
  • Secrets stay in ignored environment files or a secret manager.
  • Canonical records, reviewed judgments, and certification evidence remain independent of a vector or graph backend.
Continue readingAgent skills→