Marco Beretta
29f6ec6eae
🙈 feat: Config Option to Hide Response Feedback Buttons ( #15085 )
...
* feat: add interface option to hide response feedback buttons
Adds `interface.feedback` to librechat.yaml. When set to false, the
thumbs up/thumbs down buttons are removed from the message action row
and the feedback endpoint rejects writes with 403, so deployments that
do not consume the data can stop collecting it. Defaults to true.
* refactor: hoist the feedback gate out of the message row and into typed middleware
Reading startup config inside HoverButtons put a query observer and two Recoil
subscriptions on every message row, and rows never unmount, so the cost grew
with the conversation. Resolve the flag once per chat in useChatHelpers and
carry it on TMessageChatContext; useMessageActions withholds handleFeedback
when it is off, which the action row already treats as "no feedback controls".
The flag now stays false until the config resolves, so a disabled deployment
never flashes controls whose writes are rejected.
Move the server-side policy into requireFeedbackEnabled under packages/api so
the route keeps no policy of its own.
* test: stub the feedback gate in specs that replace the api package
The messages router now imports requireFeedbackEnabled, and express rejects an
undefined handler at require time, so every spec that mocks @librechat/api
wholesale has to carry the export.
2026-08-21 11:16:44 -04:00
Dustin Healy
af795be0c2
🪢 feat: Langfuse Fanout Connection Setting ( #14108 )
...
Docker Dev Branch Images Build / build (Dockerfile, lc-dev, node) (push) Waiting to run
Docker Dev Branch Images Build / build (Dockerfile.multi, lc-dev-api, api-build) (push) Waiting to run
GitNexus Index / index (push) Waiting to run
GitNexus Index / post-index (push) Blocked by required conditions
* feat: encrypt tenant Langfuse secret in admin config
Add generic per-field secret encryption to the admin config layer: registered
secret paths (langfuse.secretKey) are encrypted with encryptV3 on write and a
non-secret fingerprint companion is stored. Admin config reads (base + per
principal) redact registered secrets so they are never returned; the fingerprint
is kept so the UI can show which key is configured.
The Langfuse fanout read path decrypts the tenant secret before export. Adds
secretKeyFingerprint to langfuseConfigSchema and tests for the encrypt/redact
policy.
* fix(api): secure admin config secret handling
* fix(api): preserve encrypted langfuse config secrets
* fix(api): couple config secret fingerprint deletion
* fix(api): read langfuse fanout collector url from env
* fix(api): display langfuse secret key hint
* fix(api): remove langfuse secret fingerprint breadcrumbs
* fix(api): use langfuse destination keys for tenant config
* fix(api): remove langfuse config compatibility fallbacks
* refactor(api): simplify langfuse secret helpers
* refactor(api): simplify langfuse config secret handling
* feat: in-app Langfuse connection settings panel
Add a discoverable, admin-gated Langfuse connection panel inside LibreChat
Settings (Dify-style): enable toggle, host, public key, masked write-only secret,
configured-key fingerprint, and a test-connection action. Backed by a dedicated
/api/admin/langfuse/connection endpoint that encrypts the secret at rest, returns
metadata plus fingerprint on read, and validates credentials. Builds on the
per-field encryption and fanout decrypt from the langfuse-config-encryption branch.
* refactor: align Langfuse secret field to CustomUserVars pattern
Use the established SecretInput plus Set/Unset state pill (com_ui_set/com_ui_unset)
from the MCP CustomUserVars UI for the saved-secret state, instead of a bespoke
masked input.
* fix: drop em dash from saved-secret placeholder
* feat: show loading state on Langfuse test connection button
* feat: gate in-app Langfuse settings on fanout config and admin role
* test: align Langfuse connection spec with SecretInput refactor
* feat(langfuse): refine tenant connection controls
* fix(admin): refine Langfuse connection verification
* fix(langfuse): refine tenant connection settings
* fix(langfuse): simplify export enablement controls
* fix(langfuse): validate tenant export configuration
* fix(langfuse): align startup fanout gate
* fix(admin): time out Langfuse verification
* fix(ui): rename Langfuse connection setting
* fix(admin): enforce Langfuse config capability
* feat(langfuse): require explicit tenant export activation
* feat(langfuse): support single-tenant connection settings
* fix(i18n): remove obsolete integrations label
* fix(langfuse): authenticate ingestion verification
* fix(langfuse): validate public key independently
* fix(langfuse): localize connection errors
* perf(config): skip Langfuse checks for non-admins
* fix(langfuse): preserve trace sampling for feedback
* test(langfuse): fix feedback sampling fixture
* fix(langfuse): align secret preview field
* fix(langfuse): harden connection settings state
* fix(langfuse): preserve trace destination state
* fix(langfuse): enforce tenant-wide routing invariants
* fix(langfuse): preserve verified connection invariants
* fix(langfuse): preserve stable project identity
* fix(langfuse): warm project identity asynchronously
---------
Co-authored-by: Ravi Kumar L <ravi.lazar@clickhouse.com>
Co-authored-by: Danny Avila <danny@librechat.ai>
2026-07-29 18:33:10 -04:00