Skip to content

Commit 083e33a

Browse files
authored
📦 chore: Bump librechat-data-provider and @librechat/data-schemas (#77)
* chore: bump librechat-data-provider 0.8.505, @librechat/data-schemas 0.0.53 Bumps the data-provider and data-schemas patch versions to pick up the upstream changes merged since 0.8.503 / 0.0.52. Notable user-visible additions surfaced automatically by the schema-driven UI: modelSpecs conversation_starters (upstream #13710), interface.retainAgentFiles, interface.sharedLinks, interface.mcpServers.configureObo, baseEndpoint titleTiming, agentsEndpoint skills.maxCatalogSkills, custom endpoint reasoningFormat/reasoningKey. Three follow-on type fixes were needed to consume the new versions: role.ts adds a PERMISSION_TYPE_SCHEMA entry for the new PermissionTypes.SHARED_LINKS enum value (upstream #13051). CapabilityPanel.tsx casts cap to BaseSystemCapability in the implication lookup since the union tightened past plain string. server/config.ts drops the AppService call in parseImportedYaml (it was returning an AppConfig wrapper while the consumer ImportYamlDialog expects the flat config) and widens the appConfig return to Record<string, ConfigValue>. The widening also sidesteps a type-identity collision introduced by the data-schemas tsdown migration (upstream #13578), which ships dual .d.cts/.d.mts declaration bundles that get nominally distinct under moduleResolution: bundler. * 🌐 chore: Localize new config fields and sections from 0.8.505 / 0.0.53 bump The librechat-data-provider 0.8.505 and @librechat/data-schemas 0.0.53 bump in 09f214e surfaced new schema fields that rendered as raw com_config_field_* keys in the admin panel UI. Added English labels for every new field flagged by the localization-coverage test, plus singular array-item labels where needed. Labels follow the existing terse sentence-case style (e.g. softDefault becomes "Soft default", titleTiming becomes "Title timing"). Routed the two new top-level sections to tabs in SECTION_META so they no longer fall through to the catch-all "Other" tab: messageFilter to Features (alongside webSearch, summarization, memory) since it is a runtime user-message filtering feature, and skillSync to System (alongside rateLimits, balance, transactions) since it is a scheduled background sync. * 🌐 chore: Expand PII label, add com_endpoint_prompt_cache strings Relabel com_config_field_pii from "PII" to "Personally Identifiable Information" since the parent section "Message filter" already provides the filter context. Add com_endpoint_prompt_cache (label) and com_endpoint_anthropic_prompt_cache (description) so the promptCache boolean parameter renders with a real title and explanation instead of raw i18n keys. These label keys are referenced by librechat-data-provider's Anthropic and Bedrock parameter settings (present in the package since at least 0.8.502); the admin panel locale was just missing the entries. * 🪟 fix: Stop flattening single-child object wrappers in config form FieldRenderer was passing isSoleField=true whenever the current level had exactly one field and one group, which suppressed the inner field's ConfigRow label and left the parent NestedGroup label as the only label visible. For wrappers like agents.skills = { maxCatalogSkills } and fileConfig.skills = { fileSizeLimit }, that surfaced a bare number input under a generic "Skills" header, with no way to tell which limit it was. Drop the isSoleField flattening at this site so single-child object wrappers render the inner field's label inside the parent group ("Skills > Max catalog skills: [input]"). The alwaysShowLabels prop that EndpointsRenderer used to opt out of the flattening becomes redundant, so remove it from the FieldRendererProps interface, the FieldRenderer signature, and the EndpointsRenderer call site. * ✅ test: Add skillSync SAMPLE_OVERRIDES for config.test round-trip The 0.8.505 schema additions surfaced two fields whose generic control-derived sample values fail the real configSchema safeParse: skillSync.github.intervalMinutes (number) has a min-5 constraint (SKILL_SYNC_MIN_INTERVAL_MINUTES); the default sample value of 1 was rejected. skillSync.github.sources (array of objects) needs a fully-formed source entry that satisfies the GitHub source schema's id/owner/repo/paths required fields plus either credentialKey or token, since the .refine() check on the source object rejects bare strings or partial objects. Add both as path-specific overrides in SAMPLE_OVERRIDES so the config.test.ts control->value->safeParse round-trip stays green. * 🛡️ fix: Surface SHARED_LINKS permission in role editor The 0.8.505 bump added PermissionTypes.SHARED_LINKS to PERMISSION_TYPE_SCHEMA so defaultPermissions() now seeds role payloads with a sharedLinks section, but RolePermissionsPanel only renders types listed in its local PERMISSION_TYPE_ORDER and SHARED_LINKS was absent there. The result was an editable bit baked into the role payload with no UI surface to toggle it. Add PermissionTypes.SHARED_LINKS after SKILLS in PERMISSION_TYPE_ORDER so the panel renders the new multi-permission card (CREATE / SHARE / SHARE_PUBLIC). Add com_perm_type_SHARED_LINKS and com_perm_desc_SHARED_LINKS locale entries to label the card; the description stops short of "use" since the upstream sharedLinksPermissionsSchema has no USE bit. * 🌐 chore: Add com_cap_*_sharedlinks locale keys for SHARED_LINKS capabilities The 0.0.53 bump added READ_SHARED_LINKS and MANAGE_SHARED_LINKS to SystemCapabilities and bucketed both under the content category in CAPABILITY_CATEGORIES. The admin panel's Grants page renders capability labels via com_cap_<verb>_<value-after-colon>, so the new capabilities surfaced as raw com_cap_read_sharedlinks and com_cap_manage_sharedlinks strings on the grants page. Add the four matching locale entries (read and manage labels plus their _desc variants) so the new capabilities render with proper names. Wording mirrors the existing skills entries since both sit in the same content category. * 🪟 fix: Gate MCP obo and proxy fields to HTTP transports The 0.8.505 bump added obo and proxy to the MCP server schema, but only for sse and streamable-http transports. The websocket and stdio variants type obo as ZodOptional<ZodUndefined> (i.e. must stay unset) and omit proxy entirely. McpServersRenderer's visibility filter had no HTTP-only bucket; both fields fell through to the unconditional else branch and rendered in the Advanced section for every transport. An admin filling either out on stdio or websocket then hit a confusing leaf-level safeParse rejection without a transport-aware explanation. Introduce HTTP_ONLY_FIELDS and HTTP_TRANSPORTS sets that mirror REMOTE_ONLY_FIELDS / REMOTE_TRANSPORTS but exclude websocket, and gate the new obo and proxy keys through them. websocket and stdio now only see the fields their transport variant actually accepts. * 🛡️ fix: Add CONFIGURE_OBO to MCP_SERVERS permission schema The 0.8.505 bump added Permissions.CONFIGURE_OBO to mcpServersPermissionsSchema upstream, but PERMISSION_TYPE_SCHEMA[MCP_SERVERS] still only exposed USE/CREATE/SHARE/SHARE_PUBLIC. RolePermissionsPanel iterates PERMISSION_TYPE_SCHEMA exclusively, so the new CONFIGURE_OBO toggle never rendered, was never set, and was never sent in the role-save payload. The LibreChat API enforces this capability on MCP create/update routes, so admins effectively could not grant it to any role. Append Permissions.CONFIGURE_OBO to the MCP_SERVERS entry and add com_perm_CONFIGURE_OBO using the existing sentence-case-after-first style ("Configure on-behalf-of"). Also realign the com_config_field_configureObo config-field label from "Configure On-Behalf-Of" to "Configure on-behalf-of" for cross-UI consistency.
1 parent e1aa213 commit 083e33a

13 files changed

Lines changed: 121 additions & 40 deletions

File tree

bun.lock

Lines changed: 4 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
},
2323
"dependencies": {
2424
"@clickhouse/click-ui": "0.2.0-rc.4",
25-
"@librechat/data-schemas": "^0.0.51",
25+
"@librechat/data-schemas": "^0.0.53",
2626
"@tailwindcss/vite": "^4.1.18",
2727
"@tanstack/react-devtools": "0.10.0",
2828
"@tanstack/react-query": "5.95.2",
@@ -41,7 +41,7 @@
4141
"i18next-browser-languagedetector": "^8.2.1",
4242
"input-otp": "^1.4.2",
4343
"js-yaml": "^4.1.1",
44-
"librechat-data-provider": "^0.8.502",
44+
"librechat-data-provider": "^0.8.505",
4545
"lucide-react": "^0.545.0",
4646
"prom-client": "^15.1.3",
4747
"react": "^19.2.0",

src/components/access/RolePermissionsPanel.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ const PERMISSION_TYPE_ORDER: PermissionTypes[] = [
1313
PermissionTypes.MCP_SERVERS,
1414
PermissionTypes.REMOTE_AGENTS,
1515
PermissionTypes.SKILLS,
16+
PermissionTypes.SHARED_LINKS,
1617
PermissionTypes.BOOKMARKS,
1718
PermissionTypes.MULTI_CONVO,
1819
PermissionTypes.TEMPORARY_CHAT,

src/components/configuration/FieldRenderer.tsx

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1164,7 +1164,6 @@ export function FieldRenderer({
11641164
pendingResets,
11651165
schemaDefaults,
11661166
showConfiguredOnly,
1167-
alwaysShowLabels,
11681167
}: t.FieldRendererProps) {
11691168
const localize = useLocalize();
11701169
const values =
@@ -1267,7 +1266,7 @@ export function FieldRenderer({
12671266
pendingResets={pendingResets}
12681267
schemaDefaults={schemaDefaults}
12691268
showConfiguredOnly={showConfiguredOnly}
1270-
isSoleField={!alwaysShowLabels && fields.length === 1 && groups.length === 1}
1269+
isSoleField={false}
12711270
/>
12721271
);
12731272
})}

src/components/configuration/configMeta.ts

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,11 @@ export const SECTION_META: Record<
9393
descriptionKey: 'com_config_section_summarization_desc',
9494
tab: 'features',
9595
},
96+
messageFilter: {
97+
titleKey: 'com_config_section_messageFilter',
98+
descriptionKey: 'com_config_section_messageFilter_desc',
99+
tab: 'features',
100+
},
96101

97102
fileConfig: {
98103
titleKey: 'com_config_section_file_config',
@@ -174,6 +179,11 @@ export const SECTION_META: Record<
174179
descriptionKey: 'com_config_section_transactions_desc',
175180
tab: 'system',
176181
},
182+
skillSync: {
183+
titleKey: 'com_config_section_skillSync',
184+
descriptionKey: 'com_config_section_skillSync_desc',
185+
tab: 'system',
186+
},
177187
};
178188

179189
/** Sections omitted from the UI entirely (legacy fields pending removal from the schema). */

src/components/configuration/sections/EndpointsRenderer.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -567,7 +567,7 @@ function ProviderSection({
567567
<MultiAccordion.Item id={`section-${path}`} value={path} title={title}>
568568
{hasPrioritySplit ? (
569569
<>
570-
<FieldRenderer fields={priorityChildren} {...rendererProps} alwaysShowLabels />
570+
<FieldRenderer fields={priorityChildren} {...rendererProps} />
571571
{restChildren.length > 0 && (
572572
<NestedGroup
573573
label={localize('com_config_more_settings')}

src/components/configuration/sections/McpServersRenderer.tsx

Lines changed: 14 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,8 @@ const TRANSPORT_FIELDS: Record<string, string[]> = {
2323
const ALL_TRANSPORT_KEYS = new Set(Object.values(TRANSPORT_FIELDS).flat());
2424
const REMOTE_ONLY_FIELDS = new Set(['requiresOAuth', 'apiKey', 'oauth', 'oauth_headers']);
2525
const REMOTE_TRANSPORTS = new Set(['sse', 'streamable-http', 'http', 'websocket']);
26+
const HTTP_ONLY_FIELDS = new Set(['obo', 'proxy']);
27+
const HTTP_TRANSPORTS = new Set(['sse', 'streamable-http', 'http']);
2628

2729
const REQUIRED_BY_TRANSPORT: Record<string, Set<string>> = {
2830
stdio: new Set(['command', 'args']),
@@ -428,6 +430,10 @@ function McpEntryFields({
428430
if (currentTransportFields.has(field.key)) {
429431
visibleKeys.add(field.key);
430432
}
433+
} else if (HTTP_ONLY_FIELDS.has(field.key)) {
434+
if (HTTP_TRANSPORTS.has(currentType)) {
435+
visibleKeys.add(field.key);
436+
}
431437
} else if (REMOTE_ONLY_FIELDS.has(field.key)) {
432438
if (isRemote) {
433439
visibleKeys.add(field.key);
@@ -646,7 +652,6 @@ function CreateMcpServerDialog({
646652
);
647653
}
648654

649-
650655
export function McpServersRenderer(props: t.FieldRendererProps) {
651656
const {
652657
fields,
@@ -667,7 +672,9 @@ export function McpServersRenderer(props: t.FieldRendererProps) {
667672
const path = parentPath;
668673
const entryPrefix = `${path}.`;
669674
const baseValue = getValue(path, parentValue ?? EMPTY_RECORD);
670-
const baseRecord: Record<string, t.ConfigValue> = isPlainObject(baseValue) ? baseValue : EMPTY_RECORD;
675+
const baseRecord: Record<string, t.ConfigValue> = isPlainObject(baseValue)
676+
? baseValue
677+
: EMPTY_RECORD;
671678

672679
const editsByEntry = useMemo(() => {
673680
const map = new Map<string, Array<{ segments: string[]; value: t.ConfigValue }>>();
@@ -709,9 +716,7 @@ export function McpServersRenderer(props: t.FieldRendererProps) {
709716
seedIndex = i;
710717
}
711718
}
712-
const subsequentLeaves = leafEdits
713-
.slice(seedIndex + 1)
714-
.filter((e) => e.segments.length > 0);
719+
const subsequentLeaves = leafEdits.slice(seedIndex + 1).filter((e) => e.segments.length > 0);
715720
if (subsequentLeaves.length === 0) {
716721
return seedFromDelete ? undefined : seed;
717722
}
@@ -1038,18 +1043,17 @@ const McpEntryRow = memo(function McpEntryRowImpl({
10381043
value={displayValue}
10391044
onValueChange={handleWholeEntryChange}
10401045
onRemove={isReadOnly || isLockedIdentity ? undefined : () => onRemove(entryKey)}
1041-
onRename={isReadOnly || isLockedIdentity ? undefined : (renamed) => onRename(entryKey, renamed)}
1046+
onRename={
1047+
isReadOnly || isLockedIdentity ? undefined : (renamed) => onRename(entryKey, renamed)
1048+
}
10421049
disabled={isReadOnly}
10431050
defaultExpanded={justAdded}
10441051
renderFields={renderEntryFields}
10451052
/>
10461053
);
10471054
});
10481055

1049-
function lookupLeaf(
1050-
obj: unknown,
1051-
segments: string[],
1052-
): t.ConfigValue | undefined {
1056+
function lookupLeaf(obj: unknown, segments: string[]): t.ConfigValue | undefined {
10531057
let cursor: unknown = obj;
10541058
for (const seg of segments) {
10551059
if (!cursor || typeof cursor !== 'object' || Array.isArray(cursor)) return undefined;

src/components/grants/CapabilityPanel.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -155,7 +155,7 @@ export function CapabilityPanel({ capabilities, onChange, disabled }: t.Capabili
155155
v &&
156156
(
157157
CapabilityImplications[k as BaseSystemCapability] ?? []
158-
).includes(cap),
158+
).includes(cap as BaseSystemCapability),
159159
)?.[0]
160160
?.replace(/:/g, '_') ?? cap.replace(/:/g, '_')
161161
}`,

src/constants/role.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,7 @@ export const PERMISSION_TYPE_SCHEMA: Record<PermissionTypes, Permissions[]> = {
4040
Permissions.CREATE,
4141
Permissions.SHARE,
4242
Permissions.SHARE_PUBLIC,
43+
Permissions.CONFIGURE_OBO,
4344
],
4445
[PermissionTypes.REMOTE_AGENTS]: [
4546
Permissions.USE,
@@ -53,6 +54,7 @@ export const PERMISSION_TYPE_SCHEMA: Record<PermissionTypes, Permissions[]> = {
5354
Permissions.SHARE,
5455
Permissions.SHARE_PUBLIC,
5556
],
57+
[PermissionTypes.SHARED_LINKS]: [Permissions.CREATE, Permissions.SHARE, Permissions.SHARE_PUBLIC],
5658
};
5759

5860
export function defaultPermissions(): t.RolePermissions {

src/locales/en/translation.json

Lines changed: 64 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -654,6 +654,57 @@
654654
"com_config_field_allowedAddresses_item": "address",
655655
"com_config_field_includeDomains_item": "domain",
656656
"com_config_field_excludeDomains_item": "domain",
657+
"com_config_field_agent_ids": "Agent IDs",
658+
"com_config_field_agent_ids_item": "agent ID",
659+
"com_config_field_allowSelf": "Allow self",
660+
"com_config_field_buildInfo": "Build info",
661+
"com_config_field_cacheRead": "Cache read",
662+
"com_config_field_cacheWrite": "Cache write",
663+
"com_config_field_code": "Code",
664+
"com_config_field_completion": "Completion",
665+
"com_config_field_configureObo": "Configure on-behalf-of",
666+
"com_config_field_contextCost": "Context cost",
667+
"com_config_field_contextUsage": "Context usage",
668+
"com_config_field_conversation_starters": "Conversation starters",
669+
"com_config_field_conversation_starters_item": "starter",
670+
"com_config_field_currency": "Currency",
671+
"com_config_field_customPatterns": "Custom patterns",
672+
"com_config_field_customPatterns_item": "pattern",
673+
"com_config_field_forward_audience_on_refresh": "Forward audience on refresh",
674+
"com_config_field_github": "GitHub",
675+
"com_config_field_guardrailConfig": "Guardrail",
676+
"com_config_field_guardrailIdentifier": "Guardrail identifier",
677+
"com_config_field_guardrailVersion": "Guardrail version",
678+
"com_config_field_hideBadgeRow": "Hide badge row",
679+
"com_config_field_intervalMinutes": "Interval (minutes)",
680+
"com_config_field_isTemporary": "Is temporary",
681+
"com_config_field_maxCatalogSkills": "Max catalog skills",
682+
"com_config_field_maxInputTokens": "Max input tokens",
683+
"com_config_field_messageFilter": "Message filter",
684+
"com_config_field_obo": "On-Behalf-Of",
685+
"com_config_field_pii": "Personally Identifiable Information",
686+
"com_config_field_proxy": "Proxy",
687+
"com_config_field_rate": "Rate",
688+
"com_config_field_reasoningFormat": "Reasoning format",
689+
"com_config_field_reasoningKey": "Reasoning key",
690+
"com_config_field_regex": "Regex",
691+
"com_config_field_retainAgentFiles": "Retain agent files",
692+
"com_config_field_retentionMode": "Retention mode",
693+
"com_config_field_runOnStartup": "Run on startup",
694+
"com_config_field_sensitive": "Sensitive",
695+
"com_config_field_sharedLinks": "Shared links",
696+
"com_config_field_showOnLanding": "Show on landing",
697+
"com_config_field_skillSync": "Skill sync",
698+
"com_config_field_softDefault": "Soft default",
699+
"com_config_field_sources": "Sources",
700+
"com_config_field_sources_item": "source",
701+
"com_config_field_starterPatterns": "Starter patterns",
702+
"com_config_field_starterPatterns_item": "pattern",
703+
"com_config_field_streamProcessingMode": "Stream processing mode",
704+
"com_config_field_subagents": "Subagents",
705+
"com_config_field_titleTiming": "Title timing",
706+
"com_config_field_tokenConfig": "Token configuration",
707+
"com_config_field_trace": "Trace",
657708
"com_config_section_fileStrategies": "File strategies",
658709
"com_config_section_fileStrategies_desc": "Configure file handling strategies per endpoint",
659710
"com_config_section_cloudfront": "CloudFront",
@@ -664,10 +715,16 @@
664715
"com_config_section_imageOutputType_desc": "Format for generated image output",
665716
"com_config_section_includedTools": "Included tools",
666717
"com_config_section_includedTools_desc": "Tools explicitly included for availability",
718+
"com_config_section_messageFilter": "Message filter",
719+
"com_config_section_messageFilter_desc": "Filter or block patterns in user messages",
667720
"com_config_section_secureImageLinks": "Secure image links",
668721
"com_config_section_secureImageLinks_desc": "Enable secure, authenticated image URL delivery",
722+
"com_config_section_skillSync": "Skill sync",
723+
"com_config_section_skillSync_desc": "Periodically pull skill definitions from external sources",
669724
"com_config_section_summarization": "Summarization",
670725
"com_config_section_summarization_desc": "Configure conversation summarization behavior",
726+
"com_endpoint_prompt_cache": "Prompt cache",
727+
"com_endpoint_anthropic_prompt_cache": "Cache stable prompt context (system messages, tools, long inputs) at the API to reduce per-request input tokens on Anthropic models",
671728
"com_auth_title": "Admin Panel",
672729
"com_auth_email_label": "Email",
673730
"com_auth_email_placeholder": "admin@example.com",
@@ -903,6 +960,7 @@
903960
"com_perm_desc_MCP_SERVERS": "Connect and manage MCP tool servers",
904961
"com_perm_desc_REMOTE_AGENTS": "Connect and manage remote agent endpoints",
905962
"com_perm_desc_SKILLS": "Create, share, and use agent skills",
963+
"com_perm_desc_SHARED_LINKS": "Create and share conversation share links",
906964
"com_perm_desc_PEOPLE_PICKER": "Control visibility of users, groups, and roles",
907965
"com_perm_type_BOOKMARKS": "Bookmarks",
908966
"com_perm_type_PROMPTS": "Prompts",
@@ -919,6 +977,7 @@
919977
"com_perm_type_MCP_SERVERS": "MCP servers",
920978
"com_perm_type_REMOTE_AGENTS": "Remote agents",
921979
"com_perm_type_SKILLS": "Skills",
980+
"com_perm_type_SHARED_LINKS": "Shared links",
922981
"com_perm_USE": "Use",
923982
"com_perm_CREATE": "Create",
924983
"com_perm_UPDATE": "Update",
@@ -930,6 +989,7 @@
930989
"com_perm_VIEW_GROUPS": "View groups",
931990
"com_perm_VIEW_ROLES": "View roles",
932991
"com_perm_SHARE_PUBLIC": "Share publicly",
992+
"com_perm_CONFIGURE_OBO": "Configure on-behalf-of",
933993
"com_help_title": "Help",
934994
"com_help_subtitle": "Documentation, guides, and support resources",
935995
"com_help_resources": "Resources",
@@ -1000,6 +1060,8 @@
10001060
"com_cap_manage_prompts": "Manage prompts",
10011061
"com_cap_read_skills": "Read skills",
10021062
"com_cap_manage_skills": "Manage skills",
1063+
"com_cap_read_sharedlinks": "Read shared links",
1064+
"com_cap_manage_sharedlinks": "Manage shared links",
10031065
"com_cap_read_assistants": "Read assistants",
10041066
"com_cap_manage_assistants": "Manage assistants",
10051067
"com_cap_desc_access_admin": "Full admin panel access",
@@ -1020,6 +1082,8 @@
10201082
"com_cap_desc_manage_prompts": "Create, edit, and delete prompts",
10211083
"com_cap_desc_read_skills": "View skill configurations",
10221084
"com_cap_desc_manage_skills": "Create, edit, and delete skills",
1085+
"com_cap_desc_read_sharedlinks": "View shared conversation links",
1086+
"com_cap_desc_manage_sharedlinks": "Manage shared conversation links",
10231087
"com_cap_desc_read_assistants": "View assistant configurations",
10241088
"com_cap_desc_manage_assistants": "Create, edit, and delete assistants",
10251089
"com_access_denied_title": "Access denied",

0 commit comments

Comments
 (0)