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
1 change: 1 addition & 0 deletions extensions/reddog/INTERFACE.md
Original file line number Diff line number Diff line change
Expand Up @@ -307,6 +307,7 @@ Model and context routing:
- Principal/synthesis default: `z-ai/glm-5.2`.
- Adversarial critic default: `deepseek/deepseek-v4-pro`.
- Implementation critic default: `moonshotai/kimi-k2.7-code`.
- Long-horizon reasoning critic default: `moonshotai/kimi-k3` with mandatory `max` reasoning, no temperature parameter, and a receipt-recorded 4096-token critic budget.
- REGULAR smoke/simple prompts auto-route to `openrouter_single` with the GLM principal and `wsp_holo` HoloIndex grounding (no Fusion panel, Skillz, or git).
- Context is not a 012-facing selector; it is resolved from WSP_15 tier.
- Skillz/Wardrobe/Rolodex/OpenClaw/Hermes discovery is context only. RedDog may recommend a governed handoff, but this extension cannot execute it.
Expand Down
8 changes: 8 additions & 0 deletions extensions/reddog/ModLog.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,14 @@

# ModLog - RedDog Extension

## 2026-07-18 - REDDOG_FUSION_KIMI_K3_PHASE1 (OpenRouter critic integration, 0.4.1)

- Added the verified OpenRouter slug `moonshotai/kimi-k3` to the default manual Fusion panel while retaining Kimi K2.7 Code for implementation comparison and capacity fallback.
- Kimi K3 requests use its published mandatory `max` reasoning contract, omit the unsupported temperature field, and use a receipt-recorded 4096-token critic budget validated by the live compatibility smoke.
- Review packets continue to bind the exact requested panel model IDs; no mutable `kimi-latest` alias is used.
- Version 0.4.0 -> 0.4.1 (package.json + EXTENSION_VERSION + README + interface + contract tests).
- WSP_15: Complexity 3 + Importance 4 + Deferability 4 + Impact 4 = 15 (P1).

## 2026-07-16 - REDDOG_PRODUCT_IDENTITY_AND_THIN_CLIENT_0_4_0 (product identity migration, 0.4.0)

- Renamed the extension folder and product identity from the legacy Foundups Fusion Worker / Foundups(R)Agent surface to RedDog.
Expand Down
13 changes: 7 additions & 6 deletions extensions/reddog/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# RedDog

Version: 0.4.0
Version: 0.4.1

This local Cursor/VS Code extension opens the RedDog resident FoundUps architect thin client as an editor webview tab.

Expand All @@ -13,7 +13,7 @@ Command:
Default panel:

- Principal/synthesis: `z-ai/glm-5.2`
- Critics: `deepseek/deepseek-v4-pro` and `moonshotai/kimi-k2.7-code`
- Critics: `deepseek/deepseek-v4-pro`, `moonshotai/kimi-k2.7-code`, and `moonshotai/kimi-k3`

## RedDog and the Recursive 0102 DAE Ecosystem

Expand Down Expand Up @@ -144,7 +144,7 @@ Output is prefixed with a visible **RedDog Routing** block (tier, effort, mode,
| Claim | Status |
| --- | --- |
| Principal default `z-ai/glm-5.2` | OBSERVED |
| Critics default DeepSeek V4 Pro + Kimi K2.7 Code | OBSERVED |
| Critics default DeepSeek V4 Pro + Kimi K2.7 Code + Kimi K3 | OBSERVED |
| 012 work focus -> 0102 WSP task prompt | OBSERVED |
| Review packet work_focus_digest + wsp_prompt_digest | OBSERVED |
| WORK_FOCUS_NOT_AUTHORITY | OBSERVED |
Expand Down Expand Up @@ -191,12 +191,13 @@ The lead is configurable. Use Cursor settings or workspace/user settings:
"reddog.leadModel": "z-ai/glm-5.2",
"reddog.panelModels": [
"deepseek/deepseek-v4-pro",
"moonshotai/kimi-k2.7-code"
"moonshotai/kimi-k2.7-code",
"moonshotai/kimi-k3"
]
}
```

The extension uses up to four panel models. RedDog defaults to GLM-5.2 as principal, DeepSeek V4 Pro as adversarial critic, and Kimi K2.7 Code as implementation critic.
The extension uses up to four panel models. RedDog defaults to GLM-5.2 as principal, DeepSeek V4 Pro as adversarial critic, Kimi K2.7 Code as implementation critic, and Kimi K3 as a long-horizon reasoning critic. Kimi K3 uses OpenRouter's explicit `moonshotai/kimi-k3` slug; its request omits unsupported temperature, records mandatory `max` reasoning, and uses a 4096-token critic budget because lower budgets did not produce quorum-usable final output in the live compatibility smoke. The review packet records the actual per-panel token budgets.

## Bounded Repo Context

Expand Down Expand Up @@ -224,6 +225,6 @@ vsce package --no-dependencies
From Cursor:

1. Open Command Palette.
2. Run `Extensions: Install from VSIX...` and select the generated `reddog-0.4.0.vsix` (or current package version).
2. Run `Extensions: Install from VSIX...` and select the generated `reddog-0.4.1.vsix` (or current package version).
3. Do not use workspace-extension install for normal operation; install the VSIX and reload the window.
4. Run `RedDog: Open` from Command Palette or the three-dot command list.
2 changes: 1 addition & 1 deletion extensions/reddog/ROADMAP.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

## Status

Phase: RedDog 0.4.0 resident architect thin-client surface.
Phase: RedDog 0.4.1 resident architect thin-client surface.

Current implementation:

Expand Down
6 changes: 3 additions & 3 deletions extensions/reddog/extension.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ const crypto = require('crypto');
const path = require('path');
const fs = require('fs');

const EXTENSION_VERSION = '0.4.0';
const EXTENSION_VERSION = '0.4.1';
const REDDOG_EXTENSION_ID = 'foundups.reddog';
const REDDOG_LEGACY_EXTENSION_ID = 'foundups.foundups-fusion-worker';
const REDDOG_CONFIG_NAMESPACE = 'reddog';
Expand Down Expand Up @@ -3817,7 +3817,7 @@ function appendValidationFailureContent(content, validationState) {
const DEFAULT_FUSION_WORKER = {
title: 'RedDog',
lead: 'z-ai/glm-5.2',
panel: ['deepseek/deepseek-v4-pro', 'moonshotai/kimi-k2.7-code']
panel: ['deepseek/deepseek-v4-pro', 'moonshotai/kimi-k2.7-code', 'moonshotai/kimi-k3']
};

const REDDOG_ARCHITECT_SYSTEM_PROMPT = [
Expand Down Expand Up @@ -5129,7 +5129,7 @@ function activate(context) {
const installState = detectRedDogInstallState(context);
if (installState.stale_install_detected) {
vscode.window.showWarningMessage(
'RedDog 0.4.0 detected a legacy Foundups Fusion Worker install. Keep only one RedDog extension active after migration.'
'RedDog 0.4.1 detected a legacy Foundups Fusion Worker install. Keep only one RedDog extension active after migration.'
);
}
context.subscriptions.push(
Expand Down
8 changes: 5 additions & 3 deletions extensions/reddog/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "reddog",
"displayName": "RedDog - FoundUps Architect",
"description": "Open the RedDog resident 0102 architect thin client for FoundUps.",
"version": "0.4.0",
"version": "0.4.1",
"publisher": "foundups",
"icon": "icon.png",
"engines": {
Expand Down Expand Up @@ -68,7 +68,8 @@
"type": "array",
"default": [
"deepseek/deepseek-v4-pro",
"moonshotai/kimi-k2.7-code"
"moonshotai/kimi-k2.7-code",
"moonshotai/kimi-k3"
],
"items": {
"type": "string"
Expand All @@ -94,7 +95,8 @@
"type": "array",
"default": [
"deepseek/deepseek-v4-pro",
"moonshotai/kimi-k2.7-code"
"moonshotai/kimi-k2.7-code",
"moonshotai/kimi-k3"
],
"items": {
"type": "string"
Expand Down
7 changes: 7 additions & 0 deletions extensions/reddog/tests/TestModLog.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,12 @@
# Foundups(R)Agent TestModLog

## 2026-07-18 - REDDOG_FUSION_KIMI_K3_PHASE1

- Asserted the 0.4.1 package/runtime version lock and default Kimi K3 panel membership.
- Asserted the bridge emits Kimi K3 requests with mandatory `max` reasoning, without temperature, and with the 4096-token panel budget.
- Retained Kimi K2.7 Code coverage so the default panel can compare the two Kimi generations.
- Reconciled the stale resident-session contract assertion with the already-shipped durable AgentDB runtime symbol; production resident code was not changed.

## 2026-07-09 - REDDOG_EXTENSION_TO_WRE_OPERATIONAL_SPINE_DRYRUN_WIRE_PHASE1 (WRE-DRY-001..WRE-DRY-010)

| ID | Asserts |
Expand Down
23 changes: 14 additions & 9 deletions extensions/reddog/tests/verify_extension_contract.js
Original file line number Diff line number Diff line change
Expand Up @@ -198,8 +198,8 @@ function assertFusionRedactionGateFails(contextText, expectedReason, label) {
assertFusionRedactionGateBlocks(contextText, expectedReason, label);
}

assert.strictEqual(pkg.version, '0.4.0', 'package version must be 0.4.0');
includes(extensionJs, "const EXTENSION_VERSION = '0.4.0'", 'extension build mismatch');
assert.strictEqual(pkg.version, '0.4.1', 'package version must be 0.4.1');
includes(extensionJs, "const EXTENSION_VERSION = '0.4.1'", 'extension build mismatch');
assert.strictEqual(pkg.name, 'reddog', 'package id must be canonical RedDog in 0.4.0');
assert.strictEqual(pkg.displayName, 'RedDog - FoundUps Architect', 'display name must be canonical RedDog');
includes(JSON.stringify(pkg), 'RedDog: Open', 'canonical command title must use RedDog');
Expand All @@ -219,7 +219,7 @@ includes(extensionJs, 'REDDOG_STAGE_ACTIONS', 'structured stage map missing');
includes(extensionJs, 'REDDOG_PROGRESS_ACTIONS', 'progress regex fallback missing');
includes(extensionJs, 'function matchReddogProgress', 'matchReddogProgress missing');
includes(extensionJs, 'function formatElapsed', 'formatElapsed missing');
includes(readme, 'Version: 0.4.0', 'README version mismatch');
includes(readme, 'Version: 0.4.1', 'README version mismatch');
includes(extensionJs, 'function buildBridgePythonEnv', 'bridge Python UTF-8 env helper missing');
includes(extensionJs, 'PYTHONIOENCODING', 'bridge must set PYTHONIOENCODING=utf-8');
includes(extensionJs, 'PYTHONUTF8', 'bridge must set PYTHONUTF8=1');
Expand Down Expand Up @@ -270,6 +270,10 @@ includes(bridgePy, 'messages = [{"role": "system", "content": _system_prompt(pay
includes(bridgePy, 'base_system = _system_prompt(payload)', 'manual panel system prompt missing');
includes(bridgePy, 'GLM_PRINCIPAL_MODEL = "z-ai/glm-5.2"', 'bridge GLM principal missing');
includes(bridgePy, 'DEEPSEEK_CRITIC_MODEL = "deepseek/deepseek-v4-pro"', 'bridge DeepSeek V4 critic missing');
includes(bridgePy, 'KIMI_PANEL_MODEL = "moonshotai/kimi-k3"', 'bridge Kimi K3 critic missing');
includes(bridgePy, 'KIMI_K3_PANEL_MAX_TOKENS = 4096', 'Kimi K3 critic budget missing');
includes(bridgePy, 'body["reasoning"] = {"effort": "max"}', 'Kimi K3 max-reasoning request contract missing');
includes(bridgePy, '"panel_max_tokens": panel_max_tokens', 'Kimi K3 actual panel budget receipt missing');

includes(iface, 'SPECIFIED_NOT_IMPLEMENTED', 'interface truth boundary missing');
includes(iface, 'WSP_15 Priority', 'interface priority contract missing');
Expand Down Expand Up @@ -408,6 +412,7 @@ includes(iface, '012 Work Focus to 0102 WSP Task Prompt', 'INTERFACE work focus
includes(roadmap, 'REDDOG_BRIDGE_HARDENING_PHASE1', 'bridge hardening roadmap slice missing');
includes(extensionJs, 'Routing: Auto via WSP_15', 'auto routing label missing');
includes(extensionJs, 'deepseek/deepseek-v4-pro', 'DeepSeek V4 Pro critic default missing');
includes(extensionJs, 'moonshotai/kimi-k3', 'Kimi K3 critic default missing');
includes(extensionJs, 'z-ai/glm-5.2', 'GLM 5.2 principal default missing');
includes(extensionJs, 'openrouter_fusion_alias', 'OpenRouter Fusion alias path must remain implemented');
assert(!extensionJs.includes('<select id="mode"'), 'Mode must not be a 012-facing dropdown');
Expand Down Expand Up @@ -1087,7 +1092,7 @@ assert.strictEqual(spinePreview.dry_run_only, true, 'WRE preview must be dry-run
assert.strictEqual(spinePreview.candidate_work_order_emitted, true, 'WRE preview emits typed candidate shape');
assert(spinePreview.governed_work_order_candidate, 'WRE preview must include governed work-order candidate');
assert(/^rdog-wo-[a-f0-9]{16}$/.test(spinePreview.governed_work_order_candidate.work_order_id), 'candidate work_order_id shape');
assert.strictEqual(spinePreview.governed_work_order_candidate.red_dog_instance_id, 'foundups-agent-0.4.0', 'candidate must bind extension version');
assert.strictEqual(spinePreview.governed_work_order_candidate.red_dog_instance_id, 'foundups-agent-0.4.1', 'candidate must bind extension version');
assert.strictEqual(spinePreview.governed_work_order_candidate.repo_permission_snapshot.source, 'extension_runtime_candidate', 'candidate must not forge permission source');
assert.strictEqual(spinePreview.governed_work_order_candidate.repo_permission_snapshot.permission_level, 'needs_verification', 'candidate must fail closed on permission');
assert.deepStrictEqual(spinePreview.governed_work_order_candidate.allowed_paths, [
Expand Down Expand Up @@ -2579,7 +2584,7 @@ const recallTargets = orchestrator.inferRecallTargetPaths(extAcc001Prompt);
assert(recallTargets.includes(fixtures.EXT_ACC_001_TARGET_PATH), 'EXT-ACC-001 prompt must map to extension.js');

const extensionSnippet = orchestrator.readBoundedTargetSnippet(root, fixtures.EXT_ACC_001_TARGET_PATH, 24000);
includes(extensionSnippet.content, "const EXTENSION_VERSION = '0.4.0'", 'target snippet must include extension.js source');
includes(extensionSnippet.content, "const EXTENSION_VERSION = '0.4.1'", 'target snippet must include extension.js source');
assert(extensionSnippet.chars > 0, 'target snippet chars must be nonzero');
assert.strictEqual(extensionSnippet.omitted_reason, 'none', 'extension.js snippet must not be omitted');

Expand All @@ -2593,7 +2598,7 @@ assert.strictEqual(safeResolve.ok, true, 'extension.js must resolve inside works
const targetSection = orchestrator.buildTargetRecallContentSection(root, extAcc001Prompt, 24000);
includes(targetSection.text, '### Target recall content', 'target recall section header missing');
includes(targetSection.text, fixtures.EXT_ACC_001_TARGET_PATH, 'target recall must cite extension.js path');
includes(targetSection.text, "const EXTENSION_VERSION = '0.4.0'", 'target recall must include source snippet');
includes(targetSection.text, "const EXTENSION_VERSION = '0.4.1'", 'target recall must include source snippet');
assert.strictEqual(targetSection.meta.target_content_included, true, 'target_content_included must be true when snippets present');
assert(targetSection.meta.target_content_chars > 0, 'target_content_chars must be > 0');

Expand All @@ -2605,7 +2610,7 @@ assert.strictEqual(wsp97Excerpt.meta.wsp97_excerpt_included, true, 'wsp97_excerp
const boundedContext = orchestrator.buildBoundedRepoContext('wsp_holo_skillz', extAcc001Prompt);
includes(boundedContext.text, '### Target recall content', 'bounded context must include target recall section');
includes(boundedContext.text, fixtures.EXT_ACC_001_TARGET_PATH, 'bounded context must include extension.js path');
includes(boundedContext.text, "const EXTENSION_VERSION = '0.4.0'", 'bounded context must include source snippet');
includes(boundedContext.text, "const EXTENSION_VERSION = '0.4.1'", 'bounded context must include source snippet');
includes(boundedContext.text, '### WSP protocol excerpt (bounded)', 'WSP_97 task must include protocol excerpt');
includes(boundedContext.text, 'WSP 97: System Execution Prompting Protocol', 'bounded context must include WSP_97 excerpt body');
assert.strictEqual(boundedContext.holoindex_scorecard.target_content_included, true, 'scorecard target_content_included must be true');
Expand Down Expand Up @@ -3484,7 +3489,7 @@ vscodeMock.extensions.getExtension = (id) => (
id === 'foundups.foundups-fusion-worker'
? { id, packageJSON: { version: '0.3.68' } }
: id === 'foundups.reddog'
? { id, packageJSON: { version: '0.4.0' } }
? { id, packageJSON: { version: '0.4.1' } }
: undefined
);
const duplicateDetectedState = orchestrator.detectRedDogInstallState({
Expand All @@ -3502,7 +3507,7 @@ includes(extensionJs, "reddogConfigValue('enableResidentArchitectSession'", 'RAS
includes(extensionJs, 'function runResidentArchitectSessionBridge', 'RAS-001: resident session extension bridge missing');
includes(extensionJs, 'resident_architect_session_result', 'RAS-001: resident session result must attach to review packet');
includes(extensionJs, 'buildResidentArchitectSessionSection', 'RAS-001: Copy MD resident session section missing');
includes(residentArchitectBridgePy, 'run_reddog_readonly_audit_research_decision_e2e', 'RAS-002: bridge must delegate to resident E2E runtime');
includes(residentArchitectBridgePy, 'run_reddog_resident_architect_durable_agentdb_cycle', 'RAS-002: bridge must delegate to resident durable runtime');
includes(residentArchitectBridgePy, 'explicit_resident_architect_session_requested', 'RAS-002: bridge must require explicit request');
includes(residentArchitectBridgePy, 'no_holoindex_reindex_performed', 'RAS-002: bridge must surface no-reindex attestation');
includes(residentArchitectBridgePy, 'no_repo_mutation_performed', 'RAS-002: bridge must surface no-repo-mutation attestation');
Expand Down
7 changes: 7 additions & 0 deletions modules/ai_intelligence/ai_gateway/INTERFACE.md
Original file line number Diff line number Diff line change
Expand Up @@ -162,6 +162,13 @@ enabled automatically by `main.py` and does not perform verification, promotion,
PatternMemory writes, HoloIndex mutation, runtime binding, command execution, or
repository mutation.

OpenRouter candidates use provider `openrouter` and an exact model ID such as
`moonshotai/kimi-k3`. The provider is available only through explicit configured
gateway assignments and allowlisting; it is not inserted into normal fallback
routing. Kimi K3 remains an AutoResearch candidate until signed benchmark and
promotion evidence authorizes a production binding. Its configured provider
records separate input/output token prices for bounded cost-gate estimates.

The campaign execution bootstrap accepts this runner only through the explicit
`configured_gateway` mode, an outside-repo prompt-record file, an explicit
provider allowlist, an outside-repo output-evidence JSONL path, and the
Expand Down
27 changes: 27 additions & 0 deletions modules/ai_intelligence/ai_gateway/ModLog.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,32 @@
# AI Gateway Module Change Log

## [2026-07-18] - Kimi K3 OpenRouter AutoResearch Candidate

**Who:** 0102 Codex
**Type:** Model Candidate / Configured Gateway Wiring
**Slice:** MODEL_AUTORESEARCH_OPENROUTER_KIMI_K3_PHASE1

**What:** Added Kimi K3 to the static candidate catalog and enabled the existing
configured AutoResearch gateway to target exact OpenRouter model assignments.

**Why:** The combination harness and campaign loop were already implemented, but
`AIGatewayConfiguredModelCaller` could not execute an OpenRouter candidate. This
prevented governed held-out comparison of Kimi K3 with RedDog's existing panel.

**Truth Boundary:**
- IMPLEMENTED: explicit `openrouter` provider, exact `moonshotai/kimi-k3`
candidate metadata, mandatory-max-reasoning request shape, 4096-token default,
separate input/output cost accounting, catalog and caller tests.
- NOT IMPLEMENTED: automatic fallback to OpenRouter, automatic promotion,
implicit candidate-pool mutation, or bypass of benchmark/verifier receipts.

**WSP References:** WSP 15, WSP 22, WSP 50, WSP 84, WSP 97.

**WSP_15 Score:** Complexity 3 + Importance 4 + Deferability 4 + Impact 4 =
15 (P1).

---

## [2026-07-17] - Model AutoResearch Cycle Feedback Chain Main Preflight

**Who:** 0102 Codex
Expand Down
8 changes: 8 additions & 0 deletions modules/ai_intelligence/ai_gateway/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,14 @@ answers, promote models, mutate catalogs, write PatternMemory, re-index
HoloIndex, execute commands, mutate the repository, or bind RedDog runtime
defaults.

The configured gateway includes an explicit `openrouter` provider for governed
candidate assignments such as `moonshotai/kimi-k3`. OpenRouter remains absent
from ordinary AI Gateway fallback routing; an AutoResearch candidate pool and
provider allowlist must name it explicitly. Kimi K3 is cataloged as a candidate,
not a champion, until held-out benchmark and promotion receipts prove it.
Configured-runner cost estimates include its separate input and output token
rates so the existing per-sample cost gate can reject over-budget results.

`src/model_autoresearch_campaign_execution_artifact_supply_bootstrap.py` can
use this runner only when `REDDOG_MODEL_AUTORESEARCH_CAMPAIGN_RUNNER_MODE` is
set to `configured_gateway`, prompt records are supplied from outside the repo,
Expand Down
Loading
Loading