Skip to content

[EuiMarkdownFormat] Renderer misinterprets Salesforce API object #9404

@abhishek-deshmukh-el

Description

@abhishek-deshmukh-el

Reported by

ElasticGPT team + Elastic Salesforce team (internal user)

Describe the bug

ElasticGPT's chat UI misinterprets Salesforce API object and field names as Markdown formatting. Salesforce uses underscores (_) and double underscores (__) extensively in its naming conventions (e.g. SBQQ__OrderProductBookings__c, SBQQ__Subscription__c, SBQQ__ShippingAccount__c). Because Markdown treats _ as italic and __ as bold delimiters, the UI renders the text between underscores as bold or italic, or strips the underscores entirely.

The behavior is inconsistent — sometimes the names render correctly, but most often they are mangled. This makes it very difficult to trust or copy-paste API names from ElasticGPT responses.

Impact and severity

Severity: High — Salesforce is used heavily at Elastic and these API name references appear in virtually every conversation about Salesforce code, integrations, and data models. When names are incorrectly rendered, users must guess the intended identifier, leading to errors in downstream code and configuration. There is no reliable workaround; manually wrapping names in backticks when prompting does not guarantee the LLM response will also use backticks.

Environment and versions

  • EUI version: 113.0.0 @elastic/eui (EuiMarkdownFormat)
  • React version: 18.x
  • Kibana version (if applicable): N/A
  • Browser: All (Chrome, Firefox, Safari, Edge)
  • Operating System: All

Minimum reproducible sandbox

Not applicable — the issue occurs within the ElasticGPT chat UI MarkdownRenderer component which wraps EuiMarkdownFormat. The root cause is that EuiMarkdownFormat (powered by remark/unified) correctly follows the Markdown spec, but Salesforce naming conventions collide with Markdown's emphasis syntax.

To Reproduce

Order the following Salesforce fields:

SBQQ__OrderProductBookings__c
SBQQ__Subscription__c
SBQQ__ShippingAccount__c

Steps to reproduce the behavior:

  1. Open the ElasticGPT chat UI
  2. Send a prompt that will elicit Salesforce API names in the response, e.g. "What fields are on the SBQQ__Subscription__c object?"
  3. Observe the response — text between __ delimiters is rendered as bold or italic
  4. In some cases the underscores are removed entirely, making the identifier unrecognizable (e.g. SBQQ__OrderProductBookings__c becomes "SBQQ OrderProductBookings c")

Expected behavior

Salesforce-style API names (e.g. SBQQ__OrderProductBookings__c, Custom_Field__c, OpportunityLineItem.SBQQ__QuoteLine__c) should be displayed verbatim with all underscores preserved. Ideally they should render in a monospace/code font since they are technical identifiers.

Screenshots (Optional)

See attached video demonstrating the issue — the LLM response contains Salesforce field names that are rendered with bold formatting instead of displaying the raw API name with underscores.

Screen.Recording.2026-02-23.at.8.27.38.PM.mov

Additional context (Optional)

Common Salesforce naming patterns affected:

  • Managed package prefixes: SBQQ__FieldName__c
  • Custom fields: Account.Custom_Field__c
  • Custom objects: My_Custom_Object__c
  • Relationship fields: SBQQ__Quote__r
  • Custom metadata: My_Setting__mdt

This is a UI-layer rendering issue. The LLM itself returns the correct text — the problem occurs when the MarkdownRenderer component passes the raw content to EuiMarkdownFormat, which parses __ as bold markers per the Markdown specification.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No fields configured for Bug.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions