mirror of
https://github.com/coder/coder.git
synced 2026-09-24 15:04:27 +08:00
chore: link to audit docs and add prompt attribution tooltip on AI Bridge sessions page (#23969)
*Disclaimer: implemented by a Coder Agent using Claude Opus 4.6* ## Summary Two changes on the AI Bridge sessions page (`/aibridge/sessions/<session>`): 1. **Updated header subtitle and link** — replaced the generic "Centralized auditing for LLM usage across your organization. More about AI Governance" with auditing-specific copy and a link to the [AI Bridge audit docs](https://coder.com/docs/ai-coder/ai-bridge/audit). 2. **Added prompt attribution tooltip** — each user prompt now shows an info icon with a tooltip explaining that prompt origin cannot be reliably determined (human vs. agent), linking to the [attribution docs](https://coder.com/docs/ai-coder/ai-bridge/audit#human-vs-agent-attribution). ## Changes | File | What changed | |------|-------------| | `AIBridgeSessionsLayout.tsx` | Updated subtitle text and link target | | `SessionTimeline.tsx` | Added `InfoIcon` + `Tooltip` next to the "Prompt" label in `ThreadItem` | <img width="954" height="318" alt="image" src="https://github.com/user-attachments/assets/db3ca443-cb0f-426a-8457-4625c82fd6ba" /> --------- Signed-off-by: Danny Kopping <danny@coder.com>
This commit is contained in:
@@ -19,13 +19,14 @@ const AIBridgeSessionsLayout: FC<PropsWithChildren> = () => {
|
||||
</div>
|
||||
</PageHeaderTitle>
|
||||
<PageHeaderSubtitle>
|
||||
Centralized auditing for LLM usage across your organization.{" "}
|
||||
Review and audit AI activity, token usage, and prompt history across
|
||||
sessions.{" "}
|
||||
<Link
|
||||
href={docs("/ai-coder/ai-governance")}
|
||||
href={docs("/ai-coder/ai-bridge/audit")}
|
||||
className="ml-auto"
|
||||
target="_blank"
|
||||
>
|
||||
More about AI Governance
|
||||
Learn how to audit AI sessions
|
||||
</Link>
|
||||
</PageHeaderSubtitle>
|
||||
</PageHeader>
|
||||
|
||||
@@ -323,8 +323,34 @@ const ThreadItem: FC<ThreadItemProps> = ({ thread, initiator }) => {
|
||||
<div className="flex-grow flex flex-col gap-1">
|
||||
{thread.prompt && (
|
||||
<>
|
||||
<div className="text-sm text-content-secondary font-normal my-1">
|
||||
<div className="text-sm text-content-secondary font-normal my-1 flex items-center gap-1">
|
||||
Prompt
|
||||
<TooltipProvider>
|
||||
<Tooltip>
|
||||
<TooltipTrigger asChild>
|
||||
<InfoIcon className="size-icon-xs p-0.5 text-content-secondary" />
|
||||
</TooltipTrigger>
|
||||
<TooltipContent
|
||||
className="max-w-96 text-sm font-normal"
|
||||
align="start"
|
||||
side="top"
|
||||
>
|
||||
<p className="text-content-secondary m-0 mb-1">
|
||||
Prompt origin cannot be reliably determined. This may
|
||||
have been authored by a human or generated by an agent.{" "}
|
||||
</p>
|
||||
<Link
|
||||
href={docs(
|
||||
"/ai-coder/ai-bridge/audit#human-vs-agent-attribution",
|
||||
)}
|
||||
target="_blank"
|
||||
className="text-sm"
|
||||
>
|
||||
Learn about human vs. agent attribution
|
||||
</Link>
|
||||
</TooltipContent>
|
||||
</Tooltip>
|
||||
</TooltipProvider>
|
||||
</div>
|
||||
<p className="text-sm text-content-secondary font-normal bg-surface-secondary leading-relaxed rounded-md p-3 overflow-auto m-0 text-pretty">
|
||||
{thread.prompt}
|
||||
@@ -332,7 +358,6 @@ const ThreadItem: FC<ThreadItemProps> = ({ thread, initiator }) => {
|
||||
</>
|
||||
)}
|
||||
</div>
|
||||
|
||||
{/* right column: details */}
|
||||
<PromptTable
|
||||
className="lg:max-w-64 flex-shrink-0 w-full lg:w-auto"
|
||||
|
||||
Reference in New Issue
Block a user