Skip to content

feat: Jev-backed decision layer (decide) with shadow-first router, skill rerank and SDD judge comparison - #854

Closed
getappz wants to merge 7 commits into
masterfrom
task/701-jev-client-module-provider-key-resolutio
Closed

getappz wants to merge 7 commits into
masterfrom
task/701-jev-client-module-provider-key-resolutio

Conversation

@getappz

@getappz getappz commented Oct 5, 2026

Copy link
Copy Markdown
Owner

Starting your task — checking worktree state and remaining scope.
Work appears complete — now checking for review feedback.
Found 4 review findings to address — now verifying each against the code.
Verified the four findings — now planning the minimal fixes.
Plan set — starting with the vault session lookup fix.
Base URL validation added — now fixing the router shadow labels.
Correcting an edit slip, then applying the shadow label fix.
Router fixed — now preserving the skill baseline in shadow mode.
Hook updated — adding a regression test for the baseline.
All four fixes in — now running verification.
Targeted tests pass — now running the full workspace suite.
Clippy flagged dead code from the refactor — restructuring to keep the API clean.
Clippy and format are clean — running the full test suite.
One test failed — checking whether it's related to my changes.
Failure is pre-existing and unrelated — committing the fixes.
Addressed all 4 CodeRabbit findings on PR #851 (Jev decide layer) and committed as 50f4fed on the task branch:

  • Vault KDF in hooks: new vault::get_secret_session (keyring DEK only, never Argon2id); ask_within uses it, ask/ping keep full lookup.
  • Base-URL guard: AGENTFLARE_JEV_BASE_URL validated (HTTPS any host, HTTP loopback-only with exact host match rejecting 127.0.0.1.evil/@evil/userinfo); new DecideError::Config (logged fallback, never silent). No new deps.
  • Router shadow labels: Jev side now logs effective target (haiku/none/opus-only-if-nudge-fires) matching baseline_label.
  • Skill baseline: hook fetches the true 3-result set separately when reranking is on; new pick_with_baseline; default path byte-identical.

Tests: targeted decide/router/rerank/judge suites pass (20+40 tests, incl. 4 new tests); cargo fmt --check and full clippy (-D warnings) clean. Full cargo test --workspace: 2433 passed, 1 failed — the failure (mcp_prompts::optimize_review_returns_full_skill_body) reproduces on the clean tree without my changes, so it's pre-existing and unrelated.

Concern: the skill double-fetch adds one extra find_skills (with embeddings) per hook invocation, but only when AGENTFLARE_JEV_SKILLS is set — acceptable for the opt-in shadow path.


Opened by opencode on flared:51bb8de6c33b for item #338 via agentflare.

…pen ask(), vault-aware credentials, decide ping (#701)

Agentflare-Agent: claude-code_2-1-288_harness
Agentflare-Branch: task/701-jev-client-module-provider-key-resolutio
Agentflare-Item: 701
Agentflare-Session: b333d2f1-8f5b-4379-883f-eadf5c7238dc
…nostic in 'decide ping' (#702)

Agentflare-Agent: claude-code_2-1-288_harness
Agentflare-Branch: task/701-jev-client-module-provider-key-resolutio
Agentflare-Item: 701
Agentflare-Session: b333d2f1-8f5b-4379-883f-eadf5c7238dc
…ev with shadow logging and keyword fallback (#703)

Agentflare-Agent: claude-code_2-1-288_harness
Agentflare-Branch: task/701-jev-client-module-provider-key-resolutio
Agentflare-Item: 701
Agentflare-Session: b333d2f1-8f5b-4379-883f-eadf5c7238dc
…t tail, claude config) for model routing

Agentflare-Agent: claude-code_2-1-288_harness
Agentflare-Branch: task/701-jev-client-module-provider-key-resolutio
Agentflare-Item: 701
Agentflare-Session: b333d2f1-8f5b-4379-883f-eadf5c7238dc
…via AGENTFLARE_JEV_SKILLS) with fail-open fallback (#704)

Agentflare-Agent: claude-code_2-1-288_harness
Agentflare-Branch: task/701-jev-client-module-provider-key-resolutio
Agentflare-Item: 701
Agentflare-Session: b333d2f1-8f5b-4379-883f-eadf5c7238dc
…pt-in AGENTFLARE_JEV_JUDGE=shadow) (#705)

Agentflare-Agent: claude-code_2-1-288_harness
Agentflare-Branch: task/701-jev-client-module-provider-key-resolutio
Agentflare-Item: 701
Agentflare-Session: b333d2f1-8f5b-4379-883f-eadf5c7238dc
… in hooks, base-URL guard, router labels, skill baseline)

Agentflare-Agent: opencode
Agentflare-Branch: task/701-jev-client-module-provider-key-resolutio
Agentflare-Item: 701
@coderabbitai

coderabbitai Bot commented Oct 5, 2026 •

Copy link
Copy Markdown

Warning

Review limit reached

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

Next included review available in 16 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used all 2 included reviews currently available. Your 51 included PR review attempts over the past 7 days set your current allowance at 2 reviews per hour.

Learn how review limits work.

Review configuration:

⚙️ Run configuration
  • Configuration used: Repository: getappz/agentflare/.coderabbit.yaml
  • Review profile: CHILL
  • Plan: Essentials
  • Run ID: c3fba768-40de-44ac-bf71-5318af6f5030
📥 Commits

Reviewing files that changed from the base of the PR and between 0d08b9b and 50f4fed.

📒 Files selected for processing (19)
  • src/agent_model.rs
  • src/cli/decide.rs
  • src/cli/mod.rs
  • src/decide/client.rs
  • src/decide/mod.rs
  • src/decide/provider.rs
  • src/decide/shadow.rs
  • src/decide/types.rs
  • src/dev_vars.rs
  • src/hook.rs
  • src/main.rs
  • src/optimize/jev_router.rs
  • src/optimize/mod.rs
  • src/optimize/runtime.rs
  • src/skill_rerank.rs
  • src/vault.rs
  • src/work_item_pipeline.rs
  • src/work_item_pipeline/judge_shadow.rs
  • src/work_item_pipeline/judge_shadow_tests.rs
  • Autopilot · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Comment @coderabbitai help to get the list of available commands.

@getappz

getappz commented Oct 5, 2026

Copy link
Copy Markdown
Owner Author

supervisor — merge conflict

This PR now conflicts with its base branch and can't be merged automatically. Rebase or merge the base branch in and resolve the conflicts, then push.

(Set auto_resolve_conflicts = true under [review_sweep] in .agentflare/config.toml -- project or user-home -- to have an agent attempt this automatically instead.)

1 similar comment
@getappz

getappz commented Oct 5, 2026

Copy link
Copy Markdown
Owner Author

supervisor — merge conflict

This PR now conflicts with its base branch and can't be merged automatically. Rebase or merge the base branch in and resolve the conflicts, then push.

(Set auto_resolve_conflicts = true under [review_sweep] in .agentflare/config.toml -- project or user-home -- to have an agent attempt this automatically instead.)

@getappz

getappz commented Oct 5, 2026

Copy link
Copy Markdown
Owner Author

Closing as superseded. #851 was squash-merged at 06:27Z with its own fix commit (54c79c1) covering the same four review findings (session-only vault lookup in hooks, base-URL validation, effective router labels, shadow rerank baseline). This branch carries a parallel implementation (50f4fed, pushed 06:48Z) that forked from 39caa29 before that fix existed, so it re-includes all of #851 and conflicts with master. No unique behaviour found worth porting.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant