Skip to content

test(evals): add cross-system Slack customer flow - #749

Merged
elie222 merged 2 commits into
mainfrom
evaluate-era-by-eon
Sep 6, 2026
Merged

elie222 merged 2 commits into
mainfrom
evaluate-era-by-eon

Conversation

@elie222

@elie222 elie222 commented Sep 6, 2026 •

Copy link
Copy Markdown
Owner

Why

The eval suite did not verify a realistic inbound messaging task that requires grounding an answer across multiple business systems and returning it to the original conversation. This adds that coverage without making local or CI verification depend on Slack, Salesforce, Zendesk, Era, or another hosted service.

What changed

  • Extended the deterministic team-chat emulator into a complete provider-neutral messaging surface and configured it as Slack for the scenario.
  • Added synthetic Salesforce and Zendesk records with a similar-name distractor, read-only tools, and shared tool/provider identifiers.
  • Added a live eval case that links a bot, receives a colleague question, requires the matching account and support records, and grades the reply sent to the originating Slack thread.
  • Added an offline Pi replay through the real API, database, run, tool, messaging-mirror, and outbound-delivery paths, and wired it into the integration lane.
  • Documented the 16th eval and the fixture policy: keep compact synthetic conformance data with the code; put future large corpora in digest-pinned versioned artifacts; do not copy third-party data without clear compatible terms.

Testing

  • pnpm check
  • pnpm test (3,472 passed; 156 skipped)
  • pnpm test:integration (all 19 isolated suites passed)
  • pnpm test:evals --list
  • Changed-file Biome check

A live model trial was not run locally because it requires an inference-provider credential. The deterministic Pi replay exercises the complete orchestration path. Repository-wide pnpm lint still reports existing diagnostics in files unchanged by this PR; every changed source file passes Biome.

Summary by CodeRabbit

  • New Features

    • Added evaluation coverage for customer-support workflows using Salesforce and Zendesk data.
    • Added Slack-style conversation testing with inbound messages, threaded replies, and delivery verification.
    • Added checks that responses are grounded in retrieved records, avoid unsupported facts, and prevent unintended external writes.
    • Expanded the evaluation suite to 16 scenarios, including GitHub release monitoring.
  • Documentation

    • Updated evaluation guidance for synthetic fixtures, reproducible scenarios, and versioned large datasets.

@vercel

vercel Bot commented Sep 6, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

1 Skipped Deployment
Project Deployment Actions Updated
rakazo-www Skipped Skipped Sep 6, 2026 10:45pm UTC

Request Review

@coderabbitai

coderabbitai Bot commented Sep 6, 2026 •

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Team

Run ID: df742b09-49ba-4722-8312-3a7bfcc626e3

📥 Commits

Reviewing files that changed from the base of the PR and between 536f622 and 093730d.

📒 Files selected for processing (2)
  • packages/adapters/src/messaging-team-chat-emulator.test.ts
  • packages/adapters/src/messaging-team-chat-emulator.ts

Included review availability: Your plan provides up to 8 included reviews per hour; 4 remain after this review.


📝 Walkthrough

Walkthrough

The change adds Slack-style messaging emulation to evaluation trials, introduces Salesforce and Zendesk customer-support fixtures and tools, adds a grounded Slack reply evaluation case, and runs it in the integration suite.

Changes

Customer-support evaluation

Layer / File(s) Summary
Messaging emulator surface
packages/adapters/src/messaging-team-chat-emulator.ts, packages/adapters/src/messaging-team-chat-emulator.test.ts
The emulator now implements MessagingSurface, supports configurable providers and capabilities, handles inbound events, records outbound messages, validates threads, and exposes messaging descriptors.
Service fixtures and evaluation case
packages/testkit/src/evals/service-contract.ts, packages/testkit/src/evals/services.ts, packages/testkit/src/evals/cases.ts, packages/testkit/src/evals/evals.test.ts, packages/testkit/src/evals/cli.test.ts
The eval adds Salesforce and Zendesk read tools, synthetic fixtures, messaging evidence, fallback-tool checks, and the slack-customer-update case.
Messaging trial execution
packages/testkit/src/evals/runner.ts, packages/testkit/src/cli/evals.ts
Trials link Slack-style messages, execute service calls, capture messaging evidence, and wait for delivery.
Integration execution and coverage
packages/testkit/src/eval-customer-support.postgres.test.ts, packages/testkit/src/cli/harness.ts
The Postgres-backed integration test runs the scripted customer-support evaluation, and the integration harness includes the suite.
Evaluation verification guidance
docs/agent-verification.md
The documentation describes 16 cases and repository requirements for synthetic evaluation data and reproducible grading inputs.

Estimated code review effort: 4 (Complex) | ~45 minutes

Merge Risk: ⚪ Minimal · up to 09373

This adds a Slack-style customer-support evaluation with synthetic Salesforce and Zendesk data and verifies threaded, grounded replies. No merge-blocking current-head risk remains.

Sequence Diagram(s)

sequenceDiagram
  participant ScenarioRunner
  participant MessagingTeamChatEmulator
  participant EvalApp
  participant EvalServices
  ScenarioRunner->>MessagingTeamChatEmulator: Emit Slack inbound message
  MessagingTeamChatEmulator->>EvalApp: Deliver inbound event
  EvalApp->>EvalServices: Request Salesforce and Zendesk records
  EvalApp->>MessagingTeamChatEmulator: Send grounded thread reply
  ScenarioRunner->>MessagingTeamChatEmulator: Wait for outbound delivery
Loading
🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 16.67% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 12 functions across 11 files. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly and concisely describes the main change: adding an eval for a cross-system Slack customer flow.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
  • Fix all pre-merge checks with AI
✨ Finishing Touches 💡 1
📝 Generate docstrings 💡
  • Create stacked PR
  • Commit on current branch

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

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

@greptile-apps

greptile-apps Bot commented Sep 6, 2026 •

Copy link
Copy Markdown
Contributor

Greptile Summary

The PR adds a deterministic cross-system customer-support evaluation that receives a Slack-style message, retrieves matching Salesforce and Zendesk records, and delivers a grounded response to the originating thread.

  • Expands the team-chat emulator into a provider-neutral messaging surface.
  • Adds synthetic Salesforce and Zendesk fixtures, tools, grading criteria, and an offline PostgreSQL integration replay.
  • Updates the eval CLI, integration lane, tests, and documentation for the 16-case suite.

Confidence Score: 5/5

The PR appears safe to merge.

No blocking failure remains.

Important Files Changed

Filename Overview
packages/adapters/src/messaging-team-chat-emulator.ts Implements the complete messaging surface and now correctly treats unsupported typing and foreign-provider threads as no-ops.
packages/testkit/src/evals/runner.ts Wires deterministic inbound messaging, bot linking, run discovery, outbound-delivery waiting, and messaging evidence into eval trials.
packages/testkit/src/evals/cases.ts Adds the Slack customer-update scenario and grades cross-system reads, grounded content, thread delivery, distractor avoidance, and read-only behavior.
packages/testkit/src/evals/services.ts Adds coherent synthetic Salesforce and Zendesk providers, tools, records, and similar-name distractors.
packages/testkit/src/eval-customer-support.postgres.test.ts Adds an offline replay through the API, database, agent runtime, tool execution, messaging mirror, and outbound delivery paths.

Sequence Diagram

sequenceDiagram
    participant Colleague as Slack colleague
    participant Messaging as Messaging emulator
    participant App as Rakazo API / agent
    participant SF as Salesforce emulator
    participant ZD as Zendesk emulator

    Colleague->>Messaging: Ask about Fairhaven Robotics
    Messaging->>App: Emit inbound DM
    App->>SF: Search account and list opportunities
    SF-->>App: Owner, renewal stage, and next step
    App->>ZD: Search organization and list tickets
    ZD-->>App: Urgent SSO ticket and latest update
    App->>Messaging: Send grounded response to origin thread
    Messaging-->>Colleague: Record outbound Slack reply
Loading

Reviews (2): Last reviewed commit: "fix(evals): preserve best-effort typing ..." | Re-trigger Greptile

Comment thread packages/adapters/src/messaging-team-chat-emulator.ts
@github-actions

github-actions Bot commented Sep 6, 2026

Copy link
Copy Markdown
Contributor

Playwright screenshots

No new feature frames; gallery is suite-vs-main drift.

Open screenshot gallery · Dashboard · CI run

Updated for commit 093730d.

@elie222
elie222 merged commit 95245d3 into main Sep 6, 2026
17 of 18 checks passed
@elie222
elie222 deleted the evaluate-era-by-eon branch September 6, 2026 22:53

This branch was previously deployed

1 inactive deployment
Preview — 093730df Deployed Sep 6, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant