---
title: "mova-whale-main — Mova code model"
description: "Mova code model of tools/whale/src/main.rs: components with their labels, obernants and the model text."
url: "https://groupants.elamur.ai/free/en/mova/tools/whale/src/main.rs.groupant/"
---
Elamur: [Mova](https://md.mova.elamur.ai/free/en/) · [Dictionary](https://md.dictionary.elamur.ai/free/en/) · [Research](https://md.research.elamur.ai/free/en/) · **Groupants**

This page as HTML: <https://groupants.elamur.ai/free/en/mova/tools/whale/src/main.rs.groupant/>

# mova-whale-main

The groupant beside tools/whale/src/main.rs in the Mova repository: what the code computes, what it never does, how to go back from its outputs, its invariants, cost and checks.

## Facts

- **kind:** groupant
- **status:** partial source bound model
- **source:** [`tools/whale/src/main.rs`](https://github.com/ElamurAI/mova-free/blob/main/tools/whale/src/main.rs)
- **source SHA-256:** `50de8a43b077949e…`
- **repository folder:** [`tools/whale/src/main.rs.groupant`](https://github.com/ElamurAI/mova-free/tree/main/tools/whale/src/main.rs.groupant)
- **repository commit:** `48f2e6f74146`

> **Implementation material.** A Mova code model describes this code at one source revision: partial models, finite checks and their stated scope. It is not a reviewed general exposition, and its labels are shown as written, never raised.

## Components

| component | label | where |
|---|---|---|
| **approximant** | partial | [Forward approximant](#forward-approximant) |
| **ast** | partial | `syntax.json` |
| **composition** | partial | [Composition](#composition) |
| **cost** | partial | [Cost](#cost) |
| **descriptant** | present | [Descriptant](#descriptant) |
| **invariant** | partial | [Invariant](#invariant) |
| **tests** | finite evidence | `tests.md` |

## Obernants

The typed relations around the forward model: the behaviour complement (what the code never does), the reverse reconstruction (every input compatible with an output) and specialised views.

| id | type | label | where |
|---|---|---|---|
| `behavior_complement` | behavior_complement | partial source derived model | [behavior_complement](#behavior-complement) |
| `reverse_reconstruction` | reverse_reconstruction | partial source derived model | [reverse_reconstruction](#reverse-reconstruction) |

## Model text


### Descriptant

mova-whale CLI dispatching subcommands over one absolute JSON configuration. Source: `tools/whale/src/main.rs`. Public, domain-agnostic: concrete prompts, schemas, gate parameters and deployments come from pinned configuration.

### Forward approximant

Parse `COMMAND CONFIG [--once]`, require an absolute CONFIG path, load bounded JSON, dispatch to whale/swarm/agent/roles entry points, print JSON results, return failure with the error text.

### Invariant

Unknown commands, extra arguments and relative configuration paths are refused before any effect.

### Cost

O(config bytes) plus the selected entry point.

### Composition

Executable used by pool and swarm children (`whale`, `whale-research`, `whale-swarm`).

### behavior_complement

Excluded: relative CONFIG, unknown commands, trailing arguments other than --once. Evidence status: source-derived model with finite checks, not a proof.

### reverse_reconstruction

A printed result identifies the entry point; the configuration is not recoverable from output. No unique inverse is claimed.

### Epoch 2026-11-04 (Whales in English)

Epoch 2026-11-04: serve CONFIG DEPUTY_CONFIG SOCKET and ask SOCKET ID [urgent] before the CONFIG subcommands.

### Epoch 2026-11-04 (Whales reading papers)

Epoch 2026-11-04 (Whales reading papers): `paper CONFIG [--no-terminal]` (one Whale, one paper; asks through MovaTerminal or journals only) and `paper-check CONFIG...` (no shared run root or terminal profile, session, owner marker or root).

### Epoch 2026-11-04 (learning Whales)

learn CONFIG [--no-terminal] (one Whale learns on one paper until its description passes), batch-plan CONFIG and batch CONFIG [--no-terminal] (one paper per Whale per batch, closed at its deadline).

### Epoch 2026-11-04

New commands: `learn CONFIG --replay ROOT...`, `learn-report STATE_ROOT...`, `extraction-check TEXT...` (WHALE_PROSE=1 adds prose words).

### tests.md


Indirect through pool/swarm fake executables; no direct CLI test.

Command: cargo test --manifest-path tools/whale/Cargo.toml --offline --locked (74 tests, fake teachers/executables; two identical runs on 2026-11-03).
These are finite fixtures; no live run, model call or deployment was exercised.

2026-11-04: cargo test --manifest-path tools/whale/Cargo.toml --offline --locked with MOVA_OCTOPUS_TEST_MODEL=$MOVA_DATA/download/0/0.4/en.bin (unit tests incl. 5 service tests, 2 realizer tests, 3 length-gate tests; 2 English tests: 18 prompts, 10 refusals, a served end-to-end run with the real mova-whale child and a fake Codex executable; two identical runs on 2026-11-04)

2026-11-04: cargo test --manifest-path tools/whale/Cargo.toml --offline --locked with MOVA_OCTOPUS_TEST_MODEL=$MOVA_DATA/download/0/0.4/en.bin (paper/terminal/reader unit tests; tests/terminal_adapter.rs against a fake bash LLM in a private tmux server; Mova-only dry run on five CC BY 4.0 papers, two byte-identical runs; 2026-11-04)

2026-11-04: learn and batch-plan run on five open-licensed papers (scratch roots, no live terminal).
