Skip to content

Disclose free model data collection#3606

Open
iscekic wants to merge 1 commit into
mainfrom
feat/free-model-data-indicators
Open

Disclose free model data collection#3606
iscekic wants to merge 1 commit into
mainfrom
feat/free-model-data-indicators

Conversation

@iscekic
Copy link
Copy Markdown
Contributor

@iscekic iscekic commented May 30, 2026

Show a clear data-collection indicator anywhere users choose or view free Kilo models.\n\nThis makes the free-model training/replay collection behavior visible before selection across web and mobile clients.

@iscekic iscekic self-assigned this May 30, 2026
@@ -0,0 +1,20 @@
export const FREE_MODEL_DATA_LABEL = 'Free - data collected';
export const FREE_MODEL_DATA_SHORT_LABEL = 'Data collected';
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

WARNING: FREE_MODEL_DATA_SHORT_LABEL is exported but never imported or used anywhere in the PR. If it has no planned consumer yet, remove it to avoid dead code. The linter's unused-exports check (pnpm check:unused) will flag this if run.

@@ -0,0 +1,20 @@
export const FREE_MODEL_DATA_LABEL = 'Free - data collected';
export const FREE_MODEL_DATA_SHORT_LABEL = 'Data collected';
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

WARNING: Same as the web counterpart — FREE_MODEL_DATA_SHORT_LABEL is exported but unused. Both files define it identically; if it is genuinely needed in the future, consider consolidating into a shared package rather than keeping two copies.

model.id === 'kilo-auto/free' ||
model.id.endsWith(':free') ||
model.id === 'openrouter/free' ||
(model.id.startsWith('openrouter/') &&
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

WARNING: The openrouter/*-alpha / openrouter/*-beta heuristic is purely ID-based and will produce false-positive data-collection indicators for any future OpenRouter alpha/beta model that is not actually free. The server already returns an isFree boolean — relying solely on that flag (and the :free suffix convention) would be more accurate and avoid flagging paid preview models. Consider removing the -alpha/-beta pattern and instead ensuring the API populates isFree for those models.

model.id === 'kilo-auto/free' ||
model.id.endsWith(':free') ||
model.id === 'openrouter/free' ||
(model.id.startsWith('openrouter/') &&
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

WARNING: Same false-positive risk as the web version — openrouter/*-alpha and openrouter/*-beta ID pattern is a heuristic, not a reliable signal. Prefer trusting the server-provided isFree flag exclusively.

return (
<Tooltip>
<TooltipTrigger asChild>
<Info className="h-3.5 w-3.5 shrink-0 text-yellow-500" />
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

SUGGESTION: FreeModelDataIcon uses <TooltipTrigger asChild> on a bare <Info> SVG icon, which has no tabIndex and is not inherently focusable. Keyboard users who navigate the button with Tab/Enter won't be able to discover the tooltip. Consider wrapping the icon in a <button> (or a <span tabIndex={0}> with an aria-label) so the tooltip is reachable without a mouse.

return (
<Tooltip>
<TooltipTrigger asChild>
<span className="inline-flex max-w-36 shrink-0 items-center gap-1 rounded-full border border-yellow-500/30 bg-yellow-500/10 px-1.5 py-0.5 text-[10px] font-medium text-yellow-600 dark:text-yellow-300">
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

SUGGESTION: FreeModelDataBadge renders a <span> as the tooltip trigger (asChild). A bare <span> is not focusable and cannot receive keyboard focus, so the tooltip content (the explanation of data collection) is inaccessible to keyboard-only and screen-reader users. Use a <button type="button"> or add tabIndex={0} and role="status" to expose the information accessibly.

@kilo-code-bot
Copy link
Copy Markdown
Contributor

kilo-code-bot Bot commented May 30, 2026

Code Review Summary

Status: 4 Issues Found | Recommendation: Address before merge

Executive Summary

The isFreeModelOption heuristic in both web and mobile disclosure modules will produce false-positive data-collection warnings for any future paid OpenRouter alpha/beta models, and the exported FREE_MODEL_DATA_SHORT_LABEL is dead code in both packages.

Overview

Severity Count
CRITICAL 0
WARNING 4
SUGGESTION 2
Issue Details (click to expand)

WARNING

File Line Issue
apps/web/src/components/shared/free-model-data-disclosure.ts 2 FREE_MODEL_DATA_SHORT_LABEL exported but unused — dead code
apps/mobile/src/lib/free-model-data-disclosure.ts 2 Same unused export in mobile counterpart
apps/web/src/components/shared/free-model-data-disclosure.ts 17 openrouter/*-alpha/-beta heuristic will false-positive on future paid preview models
apps/mobile/src/lib/free-model-data-disclosure.ts 13 Same false-positive heuristic in mobile counterpart

SUGGESTION

File Line Issue
apps/web/src/components/shared/ModelCombobox.tsx 442 FreeModelDataIcon tooltip trigger is a non-focusable SVG — inaccessible to keyboard users
apps/web/src/components/shared/ModelCombobox.tsx 453 FreeModelDataBadge tooltip trigger is a non-focusable <span> — inaccessible to keyboard users
Files Reviewed (18 files)
  • apps/web/src/components/shared/free-model-data-disclosure.ts — 2 warnings
  • apps/web/src/components/shared/free-model-data-disclosure.test.ts
  • apps/web/src/components/shared/ModelCombobox.tsx — 2 suggestions
  • apps/mobile/src/lib/free-model-data-disclosure.ts — 2 warnings
  • apps/mobile/src/lib/free-model-data-disclosure.test.ts
  • apps/mobile/src/app/(app)/agent-chat/model-picker.tsx
  • apps/mobile/src/components/agents/model-selector.tsx
  • apps/mobile/src/lib/hooks/use-available-models.ts
  • apps/web/src/app/(app)/claw/components/SettingsTab.tsx
  • apps/web/src/app/(app)/cloud/webhooks/[triggerId]/EditWebhookTriggerContent.tsx
  • apps/web/src/app/(app)/cloud/webhooks/new/CreateWebhookTriggerContent.tsx
  • apps/web/src/app/(app)/gastown/[townId]/rigs/[rigId]/settings/RigSettingsPageClient.tsx
  • apps/web/src/app/(app)/gastown/[townId]/settings/TownSettingsPageClient.tsx
  • apps/web/src/app/(app)/gastown/onboarding/OnboardingStepModel.tsx
  • apps/web/src/components/app-builder/AppBuilderChat.tsx
  • apps/web/src/components/app-builder/AppBuilderLanding.tsx
  • apps/web/src/components/cloud-agent-next/NewSessionPanel.tsx
  • apps/web/src/components/cloud-agent-next/hooks/useOrganizationModels.ts
  • apps/web/src/components/cloud-agent/CloudSessionsPage.tsx
  • apps/web/src/components/cloud-agent/hooks/useOrganizationModels.ts
  • apps/web/src/components/cloud-agent/profile-editor/KiloCommandsTab.tsx
  • apps/web/src/components/cloud-agent/profile-editor/ProfileAgentsTab.tsx
  • apps/web/src/components/integrations/DiscordIntegrationDetails.tsx
  • apps/web/src/components/integrations/LinearIntegrationDetails.tsx
  • apps/web/src/components/integrations/SlackIntegrationDetails.tsx

Fix these issues in Kilo Cloud


Reviewed by claude-sonnet-4.6 · 1,189,454 tokens

Review guidance: REVIEW.md from base branch main

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