Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
18 commits
Select commit Hold shift + click to select a range
69cf4a8
feat(paseo-omp): tag quota accounts with plan and organization
Nov 16, 2026
8fee928
fix(paseo-omp): show account badges beside the account name
Nov 16, 2026
4e3c63a
test(paseo-omp): expose accessibility labels from the react-native te…
Nov 16, 2026
0453354
feat(paseo-omp): show and switch the session's account and tag OMP lo…
Nov 16, 2026
5cabeec
fix(paseo-omp): name the session's account for bundled omp agents ins…
Nov 16, 2026
9909ae7
fix(paseo-omp): drop the session card and give each account a visible…
Nov 16, 2026
eab33ee
fix(paseo-omp): drop redundant notices from the quota popover
Nov 16, 2026
ae26ffd
fix(paseo-omp): show the in-use account's usage in the quota pill wit…
Nov 16, 2026
902632b
feat(paseo-omp): draw provider brand marks in the quota pill and popover
Nov 16, 2026
7090206
feat(paseo-omp): lay OMP account cards out in one to three columns wi…
Nov 16, 2026
340b43b
feat(paseo-omp): mark each OMP account card with its provider
Nov 16, 2026
4058833
fix(paseo-omp): give OMP account cards a fixed width that wraps
Nov 16, 2026
14bab7f
fix(paseo-omp): right-align the IN USE badge like the Switch button
Nov 16, 2026
8277368
docs(paseo-omp): use a placeholder organization in the account tag ex…
Nov 16, 2026
c55430b
fix(paseo-omp): scope session accounts to the agent's store and match…
Nov 16, 2026
a1f9a26
fix(paseo-omp): mark a provider's only login in use and close two acc…
Nov 16, 2026
55a5c47
fix(paseo-omp): show ONLY LOGIN for a provider's sole credential inst…
Nov 16, 2026
b94de92
fix(paseo-omp): show IN USE and ONLY LOGIN for accounts without a name
Nov 16, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions paseo-omp/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,9 @@ paseo plugin ls paseo-omp

Open the **OMP** sidebar to review the provider-profile contract, choose which composer pills appear, browse and edit native scalar settings, manage OMP-native plugins, verify runtime health, and generate a bounded support report under **Help**. The same tabs, including Accounts, MCPs, and Composer, are available in the workspace OMP panel, which adds a workspace-only Security tab. Then create an agent and select **OMP Plugin**; on a new install, [enable it](#plugin-provider-opt-in) and restart the daemon first. Its optional **MCP** composer control runs OMP-native management commands in the current session; setup questions and authorization stay in that chat timeline, where OAuth can open in a workspace-scoped Paseo Browser or on the current device. While OMP subagents run, a row under each `task` card in the conversation lets you steer or stop one of them; this needs OMP 18.4.9 or newer. Composer pill preferences are shared by clients connected to the same host; normal use requires no other plugin-specific settings.

Open the **Accounts** tab of the **OMP** sidebar to see the logins in OMP's own credential store with their usage and banked resets, add a login through OMP's own sign-in, sign one out, spend a banked reset, and steer OMP's balancing: prefer a login, keep part of its quota in reserve, and set what OMP does at a limit. Steering is written to OMP's own config. See [OMP accounts](docs/configuration.md#omp-accounts).
Open the **Accounts** tab of the **OMP** sidebar to see the logins in OMP's own credential store with their usage and banked resets, add a login through OMP's own sign-in, sign one out, spend a banked reset, and steer OMP's balancing: prefer a login, keep part of its quota in reserve, and set what OMP does at a limit. Each login shows plan and organization badges from its usage report, such as **Business**, **Pro Lite**, **Personal** or an organization name, and the label drops OMP's parenthesized organization once a badge shows it. Steering is written to OMP's own config. See [OMP accounts](docs/configuration.md#omp-accounts).

The quota popover groups recorded limits by provider and OMP account, showing an available recorded email or, when absent, the Copilot account ID (GitHub username) across that account's windows. Duplicate and unnamed accounts receive numbers in opaque account-key order, so changing usage does not swap their numbers; accounts are still displayed by highest usage. Duplicate-name suffixes stay visible when long emails truncate, and a lone unnamed account needs no heading. Copilot accounts also show **GitHub** or **GHE · host**, using the enterprise URL in OMP's recorded account key; unrecognized keys show neither. Only a server-side SHA-256 hash of the account key reaches the client. **CURRENT PROVIDER** identifies the session's provider, not its active account. Provider summary percentages show the highest recorded usage across that provider's accounts.
The quota popover groups recorded limits by provider and OMP account, showing an available recorded email or, when absent, the Copilot account ID (GitHub username) across that account's windows. Duplicate and unnamed accounts receive numbers in opaque account-key order, so changing usage does not swap their numbers; accounts are still displayed by highest usage, and a divider separates each account. Duplicate-name suffixes stay visible when long emails truncate, and a lone unnamed account needs no heading. Copilot accounts also show **GitHub** or **GHE · host**, using the enterprise URL in OMP's recorded account key; unrecognized keys show neither. Badges beside each account name show the plan (such as **Business** or **Pro Lite**) and organization name from OMP's cached usage report for that account; an Anthropic organization named after the account's email shows as **Personal**, and accounts without a cached plan or organization show no badge. Only a server-side SHA-256 hash of the account key reaches the client. The popover marks the login the session uses: a live OMP Plugin session answers through its OMP runtime (`get_logout_accounts`); any other OMP session, including Paseo's bundled **omp** provider, is matched through the session id Paseo stored for the agent to the pin OMP recorded (`session:sticky:<provider>:<session id>`, kept 30 days past its last use). Both read the agent's own store: a named-profile agent never reads the daemon default store, and an agent Paseo cannot look up gets no account marks. That account leads the current provider marked **IN USE**, and every other login linked to recorded usage has an accent **Switch** button at the end of its name row, which sends `/session pin OAuth credential #<id>` to the session, so the switch and OMP's reply appear in the chat timeline. A login that is the provider's only stored credential, API keys included, shows **ONLY LOGIN** in that spot instead of **Switch**; being the only stored login does not prove use, since an environment or explicit key can still serve the session, so it gets **IN USE** only when OMP reports or recorded it. A login without recorded usage has no row, so it cannot be switched to from the popover. A login links to recorded usage by OMP's identity rule: the organization must match, including being absent on both sides, then the email decides, else the account id. Only a provider whose single login and single usage account both lack any identity, organization included (Copilot), links without one. A session that has not yet sent a request to the provider has no recorded pin; its linked logins can still be switched to and **CURRENT PROVIDER** identifies only the provider. The composer pill shows the provider icon and the highest recorded usage of the account in use, such as **19%**; its tooltip names the provider and that account. When the account in use is unknown or has no recorded usage, the pill shows the highest usage across the provider's accounts and its tooltip says **all accounts**. Reset countdowns a day or more away show days and hours, such as **resets 14d 21h**.

Open the **MCPs** tab of the **OMP** sidebar to list the MCP servers OMP connects to, add one by URL or command, test, enable, disable or remove it, and sign a remote server in through your browser, like **Accounts** does for logins. See [OMP MCP servers](docs/configuration.md#omp-mcp-servers).

Expand Down Expand Up @@ -67,7 +67,7 @@ At startup the plugin discovers directory names under `~/.omp/profiles/` (or `PI

Separate provider identities let the model picker request the correct profile catalog before an agent exists. Existing `omp-plugin` and bundled `omp` agents retain their provider; they are not migrated automatically. Profile names use OMP's lowercase grammar, including dotted names such as `team.prod`.

The OMP sidebar and memory panel expose an explicit store selector. Settings, plugins, quota, history, memory and diagnostics use that selection, and profile-agent popovers derive it from the provider ID. OMP-compatible XDG data and state roots are honored when a migrated profile uses them. Default-provider views are labelled **Daemon default store**; changing `providerOptions.command` on the default provider does not make those views profile-aware. Workspace configuration remains project-scoped, with the selected profile supplying inherited settings. Hub records are daemon-wide. The RPCs also accept an explicit absolute `store.agentDir` for custom stores; it is mutually exclusive with `store.profile`.
The OMP sidebar and memory panel expose an explicit store selector. Settings, plugins, quota, history, memory and diagnostics use that selection, and profile-agent popovers derive it from the provider ID. OMP-compatible XDG data and state roots are honored when a migrated profile uses them. Default-provider views are labelled **Daemon default store**, except the quota popover, which names only a profile or custom store; changing `providerOptions.command` on the default provider does not make those views profile-aware. Workspace configuration remains project-scoped, with the selected profile supplying inherited settings. Hub records are daemon-wide. The RPCs also accept an explicit absolute `store.agentDir` for custom stores; it is mutually exclusive with `store.profile`.

Profile selection is request-local: concurrent clients cannot change each other's process environment or cached results. Settings edits affect the selected store immediately.

Expand Down
85 changes: 66 additions & 19 deletions paseo-omp/client/omp-accounts-section.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import {
useToast,
} from "@getpaseo/plugin/client/ui";
import { useMutation, useQuery, useQueryClient } from "@tanstack/react-query";
import { type ReactNode, useRef, useState } from "react";
import { type ReactElement, type ReactNode, useRef, useState } from "react";
import { Pressable, Text, View } from "react-native";
import {
cancelOmpAccountLogin,
Expand Down Expand Up @@ -41,6 +41,7 @@ import {
} from "./omp-accounts-state";
import type { OmpConfigStyles } from "./omp-config-styles";
import { ompStoreKey } from "./omp-store-state";
import { providerIcon } from "./provider-brand";
import { quotaResetLabel, quotaSeverityFromFraction } from "./quota-state";

type Theme = PluginSurfaceProps["theme"];
Expand Down Expand Up @@ -189,11 +190,30 @@ function AccountCard({
const reserveShown = reserveOptions(account, defaultReservePct);
const age = usageAgeLabel(account);
return (
<View style={styles.card}>
<View style={[styles.card, { flex: 1 }]}>
<View style={styles.cardHeader}>
<Text numberOfLines={1} style={[styles.cardTitle, { flexShrink: 1 }]}>
{account.label}
</Text>
<View
style={{
flexDirection: "row",
alignItems: "center",
flexWrap: "wrap",
gap: 6,
flexShrink: 1,
}}
>
{/* Cards wrap into columns away from their provider heading, so each names its own. */}
<Icon icon={providerIcon(account.provider)} size={16} color={theme.colors.foreground} />
<Text numberOfLines={1} style={[styles.cardTitle, { flexShrink: 1 }]}>
{account.label}
</Text>
{account.tags.map((tag) => (
<View key={tag} style={styles.chip}>
<Text numberOfLines={1} style={styles.chipText}>
{tag}
</Text>
</View>
))}
</View>
{account.resets ? (
<View style={styles.chip}>
<Text style={styles.chipText}>{resetsLabel(account.resets)}</Text>
Expand Down Expand Up @@ -260,6 +280,28 @@ function AccountCard({
);
}

/** Fixed account card width: wide enough for the label, badges and the reserve picker on one row. */
const ACCOUNT_CARD_WIDTH = 440;
const ACCOUNT_GRID_GAP = 10;

/**
* Fixed-width account cards that wrap, as many to a row as the page fits, instead of each card
* stretching across the page. Nothing is measured, so resizing never flips the column count back.
* A page narrower than one card shrinks the card to the page.
*/
function AccountGrid({ children }: { children: ReactElement[] }) {
return (
<View style={{ flexDirection: "row", flexWrap: "wrap", gap: ACCOUNT_GRID_GAP }}>
{children.map((child) => (
// Each wrapper takes its card's key, so a removed login never shifts another card's state.
<View key={child.key} style={{ width: ACCOUNT_CARD_WIDTH, maxWidth: "100%" }}>
{child}
</View>
))}
</View>
);
}

type SettingRow = {
path: OmpAccountsSettingPath;
label: string;
Expand Down Expand Up @@ -821,27 +863,32 @@ export function OmpAccountsSection({
) : null}
{groups.map(({ provider, accounts: logins }) => (
<View key={provider.id} style={{ gap: 8 }}>
<Text style={styles.cardTitle}>{provider.name}</Text>
<View style={{ flexDirection: "row", alignItems: "center", gap: 8 }}>
<Icon icon={providerIcon(provider.id)} size={18} color={theme.colors.foreground} />
<Text style={styles.cardTitle}>{provider.name}</Text>
</View>
{view?.balance
.filter((preview) => preview.provider === provider.id)
.map((preview) => (
<Text key={preview.model} style={styles.collectionSummary}>
{balanceLine(preview)}
</Text>
))}
{logins.map((account) => (
<AccountCard
key={accountKey(account)}
account={account}
theme={theme}
styles={styles}
defaultReservePct={defaultReserve}
saving={steer.isPending}
onRemove={() => setPending({ kind: "remove", account })}
onRedeem={() => setPending({ kind: "reset", account })}
onSteer={(change) => steer.mutate({ kind: "account", account, ...change })}
/>
))}
<AccountGrid>
{logins.map((account) => (
<AccountCard
key={accountKey(account)}
account={account}
theme={theme}
styles={styles}
defaultReservePct={defaultReserve}
saving={steer.isPending}
onRemove={() => setPending({ kind: "remove", account })}
onRedeem={() => setPending({ kind: "reset", account })}
onSteer={(change) => steer.mutate({ kind: "account", account, ...change })}
/>
))}
</AccountGrid>
</View>
))}
{view?.installed && view.fetchedAt !== null ? (
Expand Down
31 changes: 31 additions & 0 deletions paseo-omp/client/provider-brand.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
import type { PluginIcon } from "@getpaseo/plugin/client";
import antigravitySvg from "../shared/provider-icons/antigravity.svg";
import claudeSvg from "../shared/provider-icons/claude.svg";
import codexSvg from "../shared/provider-icons/codex.svg";
import copilotSvg from "../shared/provider-icons/copilot.svg";
import grokSvg from "../shared/provider-icons/grok.svg";

// Paseo's provider brand icons are host-internal: a host icon name such as "claude" fails button
// validation and draws nothing through `Icon`. The same marks ship here as inline SVG that paints
// with `currentColor`, so the host tints them like any icon; other providers use Lucide.
const BRAND_ICONS: Record<string, PluginIcon> = {
anthropic: { svg: claudeSvg },
"antigravity-cli": { svg: antigravitySvg },
"github-copilot": { svg: copilotSvg },
"google-antigravity": { svg: antigravitySvg },
openai: { svg: codexSvg },
"openai-codex": { svg: codexSvg },
xai: { svg: grokSvg },
"xai-oauth": { svg: grokSvg },
};

const LUCIDE_ICONS: Record<string, string> = {
azure: "Cloud",
cursor: "MousePointer2",
};

/** The provider's brand mark when known, else the Lucide icon closest to it, else a gauge. */
export function providerIcon(provider: string | null): PluginIcon {
if (!provider) return "Gauge";
return BRAND_ICONS[provider] ?? LUCIDE_ICONS[provider] ?? "Gauge";
}
5 changes: 3 additions & 2 deletions paseo-omp/client/provider-icon.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@ import type { PluginButtonIconProps } from "@getpaseo/plugin/client";
import { Icon } from "@getpaseo/plugin/client/ui";
import type { ComponentType } from "react";
import { View } from "react-native";
import { type QuotaSeverity, quotaProviderIconName } from "./quota-state";
import { providerIcon } from "./provider-brand";
import type { QuotaSeverity } from "./quota-state";

export function quotaProviderIcon(
provider: string | null,
Expand All @@ -19,7 +20,7 @@ export function quotaProviderIcon(
: color;
return (
<View style={{ width: size, height: size, alignItems: "center", justifyContent: "center" }}>
<Icon name={quotaProviderIconName(provider)} size={size} color={severityColor} />
<Icon icon={providerIcon(provider)} size={size} color={severityColor} />
</View>
);
}
Expand Down
Loading
Loading