---
title: "octopus-question-frame — Mova code model"
description: "Mova code model of tools/octopus/src/frame.rs: components with their labels, obernants and the model text."
url: "https://groupants.elamur.ai/free/en/mova/tools/octopus/src/frame.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/octopus/src/frame.rs.groupant/>

# octopus-question-frame

The groupant beside tools/octopus/src/frame.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/octopus/src/frame.rs`](https://github.com/ElamurAI/mova-free/blob/main/tools/octopus/src/frame.rs)
- **source SHA-256:** `62945bac3dc679ae…`
- **repository folder:** [`tools/octopus/src/frame.rs.groupant`](https://github.com/ElamurAI/mova-free/tree/main/tools/octopus/src/frame.rs.groupant)
- **repository commit:** `855da7bd4a7b`

> **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 source derived | [Forward](#forward) |
| **ast** | partial | `syntax.json` |
| **composition** | partial source derived | [Composition](#composition) |
| **cost** | partial source derived | [Cost](#cost) |
| **descriptant** | partial source derived | [Descriptant](#descriptant) |
| **invariant** | partial source derived | [Invariant](#invariant) |
| **tests** | finite native checks | [checks](#checks) |

## 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 | source derived finite checked | [behavior_complement](#behavior-complement) |
| `reverse_reconstruction` | reverse_reconstruction | source derived finite checked | [reverse_reconstruction](#reverse-reconstruction) |

## Model text


### model

## Deputy question frame — source-bound model

### Descriptant

`frame.rs` reads the deputy's own role frame from the native UD tree of one sentence: the mood (imperative,
modal_request, polar, wh, declarative), the subject node and the verb node. `world::ans::parse_question` reads story
wh-questions token by token and leaves the verb slot empty for "Is Crab running normally?" or "Could you start Eel?"
(«subj crab running normally | verb -»); the deputy needs the roles, so it reads them from the parse.

### Forward

root r = the node with head 0. Wh if one of the first two words is a wh-word: verb = r, subject = nsubj(r).
ModalRequest if the first word is an AUX modal (can, could, would, will) and the second is «you»: subject = «you»,
verb = the VERB «you» hangs on, else r. Polar if the first word is any other AUX: verb = r and subject = nsubj(r) when
r is predicate-like (VERB, ADJ, -ing NOUN) with a subject; for a present-tense question whose root is a NOUN/PROPN
(the copula's subject read as root), repaired: verb = the first later acl/amod/xcomp dependent that is predicate-like
(«Is the documenter running?», «Is Eel busy?»), or the -ing root itself with its preceding compound as subject
(«Is the Nautilus running?»); otherwise verb = r and subject = nsubj(r) or the preceding compound («Is Opus busy?»).
Imperative if r is a bare VB without a subject; Declarative otherwise. `text` = `mood[ repaired] | subj «phrase» |
verb lemma`.

### Invariant

subject ≠ verb when both exist; a repaired frame names both; a past-tense polar question (first AUX tagged VBD) is
never repaired, so its reading stays as parsed and the deputy keeps refusing history questions.

### Cost

O(n) passes over at most 160 words; no model call.

### Composition

`lib.rs` records the frame in every observation (`deputy_frame`). In `resolve`, a repaired polar frame removes the
subject noun from the predicates and makes the recovered verb the checked clause head; a polar frame also marks
inversion when the auxiliary hangs on a name inside the subject. The world frame stays recorded as
`native_question_frame` for comparison.

### behavior_complement

Not read: embedded questions («whether Eel is running» stays a complement clause of the request), coordination of
several predicates, passive voice, questions without inversion («Eel is running?»), negation (refused later by the
resolver), tense beyond the VBD check, and any repair other than subject-as-root. A frame is no proof that the parse
is right; it constrains only which node may serve as the request head.

### reverse_reconstruction

Many sentences share one frame (word order, determiners, adverbs, politeness words are dropped), so from a frame
only the compatible set of sentences with that mood, subject phrase and verb lemma is recoverable, never the text.

### checks

#### Checks (2026-11-04)

Unit tests on the native parses (en.bin 0.4) of real refused prompts: polar verb slot, subject-as-root repair (documenter, Eel busy, Nautilus compound), compound subject, modal request; negative controls: past-tense copula and noun-predicate polar not repaired, declarative and imperative moods. Disabling the repair turns the unit and the native deputy test red (restored).
