ui-mode

ui-mode is a cursor rule for Cursor from Tencent-RTC/agent-skills. It costs 1,784 tokens per session, scanned C, original, MIT.

A conditional interface rule for projects whose session configuration enables the official RoomKit or full UI mode. It also defines a shortcut for new medical video-consultation projects.

In plain words
What is it for?
Use it when checking UI-mode settings, generating supported interfaces, or starting a new medical consultation project that should use the bundled template.
Why use it?
It ensures the right interface-generation workflow is used for the configured project mode and avoids incompatible setup steps for the medical template.

Cursor rule for Cursor

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add rules/tencent-rtc/agent-skills/ui-mode
Clone the repo
git clone --depth 1 https://github.com/Tencent-RTC/agent-skills

Made for: Cursor.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for ui-mode

README.md
[![agentmods](https://agentmods.dev/badge/rules/tencent-rtc/agent-skills/ui-mode.svg)](https://agentmods.dev/rules/tencent-rtc/agent-skills/ui-mode)
Your own site
<a href="https://agentmods.dev/rules/tencent-rtc/agent-skills/ui-mode"><img src="https://agentmods.dev/badge/rules/tencent-rtc/agent-skills/ui-mode.svg" alt="Measured on agentmods" height="20"></a>
Per session 1,784 This file is loaded in full into every session.
When invoked 1,784 The same file — it is already loaded in full.
Security scan C 1 finding. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.01784 $0.01784
Opus 5 $0.00892 $0.00892
Sonnet 5 $0.00357 $0.00357
Haiku 4.5 $0.00178 $0.00178

Measured 3d ago against content hash e40545d5b6b3, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade C, and why

ui-mode scanned grade C with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 3d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Hidden instructionshighPrompt injection

Directives inside HTML comments, invisible characters or bidirectional overrides are read by the model and not by the person reviewing the file.

<!-- DO NOT EDIT — generated from ai-instructions/ by skills/trtc/room-builder/tools/render_ai_instructions.py. Edit the source markdown and re-run the renderer instead. -->
.cursor/rules/ui-mode.mdc · 159 lines

How it starts

The opening of the file, as written. The whole thing — 159 lines — stays where its author put it; the contents beside it link to each section on GitHub.

When this rule applies

Only when .trtc-session.yaml at the repo root has ui_mode: official-roomkit or ui_mode: full-ui. If the file is missing, or ui_mode is unset / null / headless, this rule does not apply — fall back to whatever the tool's default behavior is.

Medical new-project shortcut

When the user request is for medical online consultation (for example 1v1-video-consultation, remote diagnosis, online medical consultation, doctor-patient video visit) and the task is to generate a brand-new project rather than integrate into an existing app, bypass the normal full-ui theme workflow entirely. Do not run trtc_prepare_ui.py, do not generate Vue SFCs by hand, and do not run UI or medical verifiers.

Instead, directly copy the bundled medical template project:

skills/trtc/room-builder/templates/scenarios/medical-consultation/

to the user's local target project directory, preserving the project exactly as packaged. In the handoff or integration notes, tell the customer to use pnpm install for dependencies and pnpm dev for local development. Do not recommend npm install / npm run dev; this medical template starts much slower with npm and can show a blank first screen for a while.

This shortcut applies only to brand-new medical consultation projects. Existing project integration still follows the normal scenario / official-roomkit / full-ui rules below.

This is a terminal path. After choosing the bundled medical template, do not enter the scenario/topic slice workflow, do not show a scenario capability table, do not describe the project as a general-conference slice plan, and do not ask about per-step auto-advance. Copy the template, mark the session completed, and stop.

This is an internal execution rule, not user-facing copy. When explaining the choice or reporting progress to the customer, do not mention "shortcut", "bypass", "normal UI mode", "theme workflow", "CLAUDE.md", or any internal rule file. Say that you are creating a complete 1v1 video consultation project from the bundled medical template, and explain only the outcome and next commands (pnpm install, pnpm dev).

Read the full file on GitHub · 159 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 3d ago First seen · 159 lines · 1,784 tokens per session scan C e40545d5b6b3

Subscribe to this mod's changes

ui-mode is a cursor rule published in the GitHub repository Tencent-RTC/agent-skills (12 stars, last pushed 13d ago), licensed MIT. It adds 1,784 tokens to every session, about $0.0089 per session on Opus 5. A static security scan graded it C with 1 finding (hidden instructions). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.