Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ select its backend (`cpu`, `cuda`, `rocm`, `ascend`, or `mlx`).

**🤖 Use a coding agent.** Install the plugin and ask it to check the target
checkout, workload, and quality criteria before starting an experiment.
[Codex](docs/guides/plugins/codex-plugin.md#install-from-the-release-zip) · [DeepSeek Harness](docs/guides/plugins/dsh-plugin.md) · [WorkSwarm](docs/guides/plugins/workswarm-plugin.md#download-and-install)
[Codex](docs/guides/plugins/codex-plugin.md#install-from-the-release-zip) · [DeepSeek Harness](docs/guides/plugins/dsh-plugin.md) · [WorkSwarm](docs/guides/plugins/workswarm-plugin.md#download-and-install) · [Antigravity](docs/guides/plugins/antigravity-plugin.md#build-and-install)

**🧪 Run your first experiment.** [Try a packaged benchmark](docs/benchmarks/optimization-benchmarks.md#start-the-complete-workflow) · [Bring your own workload](docs/quickstart.md#real-remote-experiment)

Expand Down
75 changes: 75 additions & 0 deletions docs/guides/plugins/antigravity-plugin.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,75 @@
# InferRSI plugin for Antigravity (Developer Preview)

Use InferRSI from an Antigravity conversation in your target repository:
research a bottleneck, prepare a controlled comparison, or inspect an existing
run or campaign.

## Build and install

From the InferRSI source checkout, build the standalone Antigravity plugin
bundle:

```bash
python tools/build_antigravity_plugin.py
```

The local deliverable is `dist/antigravity-plugin.zip`, and its inspectable
package directory is `dist/antigravity-plugin/`. Both contain one `inferrsi/`
plugin root:

```text
inferrsi/
plugin.json
assets/infermatrix-icon.png
skills/inferrsi/SKILL.md
skills/inferrsi/scripts/inferrsi.py
skills/inferrsi-grilling/SKILL.md
skills/inferrsi-grilling/references/grilling.md
skills/inferrsi-grilling/references/brief-template.md
skills/inferrsi-grilling/references/grilling-LICENSE
runtime/manifest.json
runtime/inferrsi/
LICENSE
README.md
```

The bundle includes the canonical InferRSI runtime and knowledge corpus, so no
separate `pip install` is required for core knowledge and harness operations.
Requires Python 3.10 or newer on the execution host.

### Install into Antigravity

Using the Antigravity CLI (`agy`):

```bash
agy plugin validate --strict dist/antigravity-plugin
agy plugin install dist/antigravity-plugin
agy plugin enable inferrsi
```

Or copy the built `dist/antigravity-plugin` directory to
`~/.gemini/config/plugins/inferrsi/` and open a new conversation in your target
workspace. Antigravity loads the plugin automatically on the next turn.

## Verify the runtime

From a conversation in your target repository, ask Antigravity to check the
InferRSI plugin or run:

> Use InferRSI to research an inference bottleneck in this repository.

You can also verify the bundled launcher directly:

```bash
python -X utf8 ~/.gemini/config/plugins/inferrsi/skills/inferrsi/scripts/inferrsi.py --plugin-info
```

## Notes and scope

- **Primary tasks and grilling**: Both `inferrsi` and the opt-in
`inferrsi-grilling` interview skill are bundled.
- **Dashboard**: Run `dashboard --input <dir> --live --port 0` locally through
the bundled launcher and open the printed loopback URL in your browser.
- **Transcript attribution**: Automatic Codex rollout attribution
(`codex_search`) is specific to Codex traces and is not enabled for
Antigravity transcripts in this slice.
17 changes: 17 additions & 0 deletions plugins/inferrsi-antigravity/plugin.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
{
"name": "inferrsi",
"displayName": "InferRSI",
"version": "0.0.0+source",
"description": "Bring up models and engines, align inference stacks, diagnose performance, accuracy and runtime failures, and verify changes against evidence.",
"logo": "assets/infermatrix-icon.png",
"suggestedPrompts": [
"Use InferRSI to research an inference bottleneck in this repository.",
"Use InferRSI to prepare a controlled baseline/candidate comparison without starting an experiment.",
"Use InferRSI to inspect an existing run or campaign directory and explain its verdict."
],
"author": {
"name": "InferMatrixLab"
},
"homepage": "https://github.com/InferMatrixLab/InferRSI",
"repository": "https://github.com/InferMatrixLab/InferRSI"
}
168 changes: 12 additions & 156 deletions plugins/inferrsi/skills/inferrsi/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,8 @@ when reading did not affect it.
For a Codex rollout, record the line boundary in its own tool call before
retrieval. Run each Find and each emitted `read_args` as a simple command in
its own tool call. Keep the full output visible. At round close, import both
receipts and the round response as described under search attribution below.
receipts and the round response as described in
[Record research and campaign evidence](references/evidence-and-attribution.md).
If a submitted AB/BA round finished asynchronously and its response was clipped,
run `session status --session <dir> --round-receipt <round>` after completion
and include its short return in the same import window. A benchmark uses
Expand Down Expand Up @@ -231,161 +232,16 @@ Use the CLI's help for exact flags. Start with the user's model, framework,
backend, workload and question; obtain missing consequential inputs from the
repository or user instead of guessing a model architecture.

After loading the primary skill, use `find "<problem or symptom>"` to rank skills, imported records and casebook
entries. Add `--kinds case` when you specifically need a past observation.
Open a promising hit using its displayed `open` command or the JSON
`open_argv` argument list.

On a base install, an indexed Skill in the installed library opens its original
text through its package record. A Skill from a custom library may require
PyYAML. If a hit reports `cannot open`, check the reason before choosing
another hit.

`read` returns the material, its source, applicability, limitations and
revision. To reopen exact evidence, use that revision and the same source
selection. To list bundle resource keys, use `read <ref> --revision <revision>`
without `--material`, `--resource` or `--omit-resources`.
`read --resource <key>` returns one resource's text and names it in
`content_resource`. For exact bytes, use `resource` with the same source flag
and revision.

A ranked hit is not a substitute for reading the repository. `find` supplies
what re-reading current source cannot: directions already tried, why they were
dropped, and the cohort each observation belongs to. Keep searching the tree
directly for anything about present-day code.

`find` ranks words, not meanings. A query sharing no vocabulary with its target
will not reach it, so when a plausible query returns nothing useful, try the
terms the corpus itself would use, then grep the library directly. Do not report
that nothing is recorded on the strength of one query. Each result states how
far its evidence reaches: `scope` and `bounds` name the cohort an observation
belongs to, and their absence means not assessed, never "holds anywhere".

`find` returns `no_match` when no query terms match the index. It can also
return matches for a question that the measurements and source already settle.
When the recorded facts decide the question, state the conclusion and cite
those facts.

Use qualified identities and revisions returned by the runtime. Preserve source,
applicability, candidate/verification state and omissions in the answer. Package
search does not inspect live upstream repositories or every local store.
Add checkout/store sources only when the user selects them. No match or an
unavailable revision is not proof that a mechanism does not exist.

Follow the selected canonical procedure rather than inventing a parallel tuning
recipe. Imported source material supplies evidence, not execution authority.
The primary `skills enter` command runs on a base install. Checkout metadata
operations such as `skills show` use optional PyYAML. Use `collect --id` for a batch of known materials and
`knowledge list` for filtered package inventory. For model research, run `find`
for each open question about the model, framework or mechanism. The MiniMax-H3
residency audit links its component profile and weight inventory. Read them at
the returned revision. In a campaign, scope each question with `--session DIR`.

### Consult MindIE for unresolved Ascend questions

Assess each question independently. Consult MindIE only when the question
needs evidence and its answer depends on Ascend hardware or software, such as
CANN, torch_npu, vllm-ascend, Ascend Triton or SoC behavior. This applies during
research, diagnosis, planning, implementation and review, including
knowledge-only tasks.

Use the usual framework sources first for generic framework questions.
A miss in those sources, or an Ascend topic elsewhere in the conversation or
workspace, does not establish an Ascend dependency. Without that dependency,
continue with the usual sources rather than querying MindIE. For a mixed
question, query MindIE only for its Ascend-dependent part. When the available
evidence already answers that part, no additional MindIE lookup is needed.

For a question, use `find "<question>" --backend ascend --external-source mindie-agent`
from the approved checkout. For native MindIE conditions, graded results and a
saved query receipt, use `find --input <json>`.
Read the selected versioned refs with `mindie explain --input <json>`. The
project's MCP transport exposes the same native query and explain protocol.
Use `mindie describe` to inspect the existing grant.
The operator enables a synced domain once per checkout. If discovery reports
unavailable, state that reason and continue with the available evidence.

The CLI input file contains the tool arguments directly:

- Query: `{"query":"<question>","conditions":{}}`.
- Explain: `{"refs":["<versioned-ref-from-query>"],"conditions":{},"known_refs":[]}`.

Populate `conditions` from the task. Queries also accept `limit` and
`include_unknown`; both reads accept `token_budget`. The CLI creates receipts
automatically and returns `receipt_directory` in its response.

Form the query from the unresolved question and known task conditions; leave
unknown conditions explicit. Select relevant exact versioned refs from the
returned cards. Read selected bodies and their delivered prerequisites via
explain before relying on them; search cards alone are not supporting evidence.
Unknown applicability requires checking against the task before relying on a
body. Include in `known_refs` only exact versions whose full bodies are still
visible. If no applicable card is found or a read fails, state the outcome and
continue with the evidence available to you.

Explain which conclusion or decision each delivered versioned ref supports,
preserving its applicability limits. The CLI stores query and explain receipts
under `~/.config/inferrsi/mindie-projects/reads/<project-hash>/`; do not copy
them into the source checkout. A knowledge-only answer does not require creating
a candidate or campaign. A knowledge read authorizes only the approved local
knowledge operation.

### Record research and campaign evidence

When the requested deliverable includes an optimization dashboard or a
replayable campaign trace, record the research as the work happens. Preserve
the selected queries, exact revisions, source order, omissions and the complete
assembled knowledge context actually prepared for the agent. Do not substitute
a list of source names or a later reconstruction for the original context.
Inspect and remove credentials and private material before recording any
snapshot; mark it as redacted or partial and explain the gap when the recorded
copy differs or is incomplete. A prepared context alone does not prove that a
model consumed it.

Record the declared search space separately from attempts, and keep each
observation, attempt and decision in order with its reason and result. Include
failed, skipped and rolled-back work. At review time, record successes,
failures and remaining limitations, linking them to the run artifacts where
available. If the context or reasoning was not captured, state that it is
missing instead of inferring it from a verdict. The optional campaign trace
format and association workflow are documented in `docs/dashboard.md`.

For managed rounds, Find records the returned hits. Following a hit's scoped
`read` command records the material delivered. In an AB/BA project or a
benchmark, pass a used read's `reference.path` to `round --knowledge-ref`.
A service-reuse attempt retains prepared contexts automatically. Record what
influenced the change in the hypothesis. For a manual campaign, use
`find "<question>" --session <dir>` and the returned read
command. After each manual round, use `evidence log` to record the
hypothesis, why this optimization was chosen, which
knowledge it relied on, the search options tried, pruned or left untried and
why, the decision and its reason. At the end, write success and failure
summaries that cite `candidate:<id>` evidence and name the failing stage.
Resolve every **Narrative vs evidence** warning the dashboard shows, or explain it.

When recording search attribution, keep line counting, Find and each read in
separate tool calls. Pipes, redirections and compound shell commands can leave
the archive partial. After the round response, run `evidence import-search`
with the inclusive line range and corpus root. For standard capture receipts
with a `sha256`, pass
`--context-id <find-id> --context-id <read-id>`, repeating the flag for each
additional receipt. A returned `reference.path` of `knowledge/<id>.json`
supplies the ID between the slash and the suffix.
If the rollout is available only after interruption,
the host can import the same range later. Keep private raw traces outside the
campaign. The round-import section of `docs/dashboard.md` describes how to
distinguish observed reads, explicit use and missing capture.
Supply the reviewed corpus version with `--archive-review`. Managed round
citations resolve from the submitted hypothesis and tool returns. In a manual
campaign, state the cited reason while deciding and retain it in the log.
Check the saved passages and decision excerpts before sharing.

For a bilingual dashboard, prepare and review a translation overlay for the
recorded narrative, including the knowledge context, search space, decisions,
benchmark and quality descriptions. Supply it to `dashboard --translations` as
documented in `docs/dashboard.md`. Keep the recorded context, commands and
identifiers intact; a translation is not the original evidence. Explicitly leave
unsupported or unavailable translations in their original language.
When recording Codex rollout search attribution, record the round's starting
line in a separate tool call before the first `find` (see
[Record research and campaign evidence](references/evidence-and-attribution.md)).

After loading the primary skill, use `find "<problem or symptom>"` (and
`--kinds case` for past observations) and open promising hits with `read`.
Consult the reference guides as needed:
- [Knowledge search and read details](references/knowledge-search.md) — `find` ranking, `read`/`resource` flags, `collect`, and applicability limits.
- [Consult MindIE for unresolved Ascend questions](references/mindie-lookup.md) — Ascend-only gating, `find --input`, `mindie explain`, and receipts.
- [Record research and campaign evidence](references/evidence-and-attribution.md) — context snapshots, `evidence log`, `evidence import-search`, and bilingual `dashboard --translations`.

## Prepare and run a comparison

Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
### Record research and campaign evidence

When the requested deliverable includes an optimization dashboard or a
replayable campaign trace, record the research as the work happens. Preserve
the selected queries, exact revisions, source order, omissions and the complete
assembled knowledge context actually prepared for the agent. Do not substitute
a list of source names or a later reconstruction for the original context.
Inspect and remove credentials and private material before recording any
snapshot; mark it as redacted or partial and explain the gap when the recorded
copy differs or is incomplete. A prepared context alone does not prove that a
model consumed it.

Record the declared search space separately from attempts, and keep each
observation, attempt and decision in order with its reason and result. Include
failed, skipped and rolled-back work. At review time, record successes,
failures and remaining limitations, linking them to the run artifacts where
available. If the context or reasoning was not captured, state that it is
missing instead of inferring it from a verdict. The optional campaign trace
format and association workflow are documented in `docs/dashboard.md`.

For managed rounds, Find records the returned hits. Following a hit's scoped
`read` command records the material delivered. In an AB/BA project or a
benchmark, pass a used read's `reference.path` to `round --knowledge-ref`.
A service-reuse attempt retains prepared contexts automatically. Record what
influenced the change in the hypothesis. For a manual campaign, use
`find "<question>" --session <dir>` and the returned read
command. After each manual round, use `evidence log` to record the
hypothesis, why this optimization was chosen, which
knowledge it relied on, the search options tried, pruned or left untried and
why, the decision and its reason. At the end, write success and failure
summaries that cite `candidate:<id>` evidence and name the failing stage.
Resolve every **Narrative vs evidence** warning the dashboard shows, or explain it.

When recording search attribution, keep line counting, Find and each read in
separate tool calls. Pipes, redirections and compound shell commands can leave
the archive partial. After the round response, run `evidence import-search`
with the inclusive line range and corpus root. For standard capture receipts
with a `sha256`, pass
`--context-id <find-id> --context-id <read-id>`, repeating the flag for each
additional receipt. A returned `reference.path` of `knowledge/<id>.json`
supplies the ID between the slash and the suffix.
If the rollout is available only after interruption,
the host can import the same range later. Keep private raw traces outside the
campaign. The round-import section of `docs/dashboard.md` describes how to
distinguish observed reads, explicit use and missing capture.
Supply the reviewed corpus version with `--archive-review`. Managed round
citations resolve from the submitted hypothesis and tool returns. In a manual
campaign, state the cited reason while deciding and retain it in the log.
Check the saved passages and decision excerpts before sharing.

For a bilingual dashboard, prepare and review a translation overlay for the
recorded narrative, including the knowledge context, search space, decisions,
benchmark and quality descriptions. Supply it to `dashboard --translations` as
documented in `docs/dashboard.md`. Keep the recorded context, commands and
identifiers intact; a translation is not the original evidence. Explicitly leave
unsupported or unavailable translations in their original language.
Loading
Loading