Skip to content

Ade Chat Terminal Guidance#676

Merged
arul28 merged 1 commit into
mainfrom
ade/ade-ade-skill-guidance-stuff-7791933f
Jun 30, 2026
Merged

Ade Chat Terminal Guidance#676
arul28 merged 1 commit into
mainfrom
ade/ade-ade-skill-guidance-stuff-7791933f

Conversation

@arul28

@arul28 arul28 commented Jun 30, 2026

Copy link
Copy Markdown
Owner

Summary

Describe the change.

What Changed

Key files and behaviors.

Validation

How you tested.

Risks

Anything to watch.

ADE   Open in ADE  ·  ade/ade-ade-skill-guidance-stuff-7791933f branch  ·  PR #676

Summary by CodeRabbit

  • New Features

    • Added clearer handling for chat actions tied to a specific session, including automatic use of the caller’s active chat session when appropriate.
  • Bug Fixes

    • Prevented users from accessing or sending messages in other chat sessions.
    • Kept explicit chat actions available for external CLI callers when no chat session is bound.
  • Documentation

    • Clarified when to use ADE-connected terminals versus the CLI’s own shell commands.

Greptile Summary

This PR tightens ADE chat action scoping and updates the related agent guidance. The main changes are:

  • Session-bound non-CTO callers are limited to their own chat for chat.readTranscript and chat.sendMessage.
  • Unbound external CLI callers can still pass an explicit chat session ID.
  • Tests cover cross-chat denial, own-chat defaulting, and unbound external access.
  • Agent skill and feature docs clarify when to use ADE chat-attached terminals versus normal shell tooling.

Confidence Score: 0/5

No code issues were identified in the reviewed changes.

The changes are narrowly scoped, include targeted tests for the chat session access behavior, and documentation updates align with the implementation.

T-Rex T-Rex Logs

What T-Rex did

  • Captured base and head command captures with full command, working directory, exit code, and identical startup failure, plus the harness used for the requested scenarios.
  • Compared before and after chat-terminal-guidance logs, capturing the base commit transcript and missing checks before, and the head commit transcript with passing checks after, across repository routing, CLI session guidance, terminal inspect/control guidance, and chat action references.

View all artifacts

T-Rex Ran code and verified through T-Rex

Reviews (1): Last reviewed commit: "Fix chat action scoping and ADE CLI guid..." | Re-trigger Greptile

@vercel

vercel Bot commented Jun 30, 2026

Copy link
Copy Markdown

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

1 Skipped Deployment
Project Deployment Actions Updated (UTC)
ade Ignored Ignored Jun 30, 2026 9:51pm

@coderabbitai

coderabbitai Bot commented Jun 30, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 676c0ce1-d530-48b1-9dec-636f62b1f59d

📥 Commits

Reviewing files that changed from the base of the PR and between 9174dcf and 2dd46d2.

⛔ Files ignored due to path filters (3)
  • docs/ARCHITECTURE.md is excluded by !docs/**
  • docs/features/agents/README.md is excluded by !docs/**
  • docs/features/chat/README.md is excluded by !docs/**
📒 Files selected for processing (3)
  • apps/ade-cli/src/adeRpcServer.test.ts
  • apps/ade-cli/src/adeRpcServer.ts
  • apps/desktop/resources/agent-skills/ade-cli-control-plane/SKILL.md

📝 Walkthrough

Walkthrough

Adds authorization scoping for non-CTO callers invoking chat ADE actions (readTranscript, sendMessage), introducing a chatAccessDenied helper and scopeChatAdeActionArgs function that validate or default sessionId against the caller's bound chatSessionId. Adds corresponding test coverage and updates SKILL.md guidance on terminal usage.

Changes

Chat ADE Action Scoping

Layer / File(s) Summary
Chat access denial and scoping logic
apps/ade-cli/src/adeRpcServer.ts
Adds chatAccessDenied() to throw method-not-found errors and scopeChatAdeActionArgs() to validate/default sessionId against the caller's chat session, wired into run_ade_action for non-CTO callers on chat domain actions.
Authorization test coverage
apps/ade-cli/src/adeRpcServer.test.ts
Extends the PTY/terminal scoping test with chat-session denial/allow assertions and adds a new test confirming unbound external CLI callers retain access to explicit chat actions.
Terminal usage guidance
apps/desktop/resources/agent-skills/ade-cli-control-plane/SKILL.md
Clarifies that ordinary repo commands should not use chat-attached ADE terminals, and restricts ade terminal ... to existing ADE-owned sessions.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~25 minutes

Possibly related PRs

  • arul28/ADE#247: Both PRs modify adeRpcServer.ts around chatSessionId identity resolution that feeds this PR's chat ADE action scoping logic.

Suggested labels

desktop

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. 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 is relevant to the PR, covering ADE chat terminal guidance and the related chat scoping changes.
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.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch ade/ade-ade-skill-guidance-stuff-7791933f

Warning

There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure.

🔧 SkillSpector (2.3.7)
apps/desktop/resources/agent-skills/ade-cli-control-plane/SKILL.md

SkillSpector returned invalid JSON output


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.

@mintlify

mintlify Bot commented Jun 30, 2026

Copy link
Copy Markdown

Preview deployment for your docs. Learn more about Mintlify Previews.

Project Status Preview Updated (UTC)
ade-ac1c6011 🟢 Ready View Preview Jun 30, 2026, 9:54 PM

💡 Tip: Enable Workflows to automatically generate PRs for you.

@greptile-apps

greptile-apps Bot commented Jun 30, 2026

Copy link
Copy Markdown

T-Rex pricing update — T-Rex was free through June 2026. Effective July 1, 2026, T-Rex adds 2 credits on top of the standard 1-credit review (3 total). T-Rex settings

@arul28

arul28 commented Jun 30, 2026

Copy link
Copy Markdown
Owner Author

@copilot review but do not make fixes

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