> ## Documentation Index
> Fetch the complete documentation index at: https://docs.bigdata.com/llms.txt
> Use this file to discover all available pages before exploring further.

# MarkdownLinkFormatter

<Warning>
  We are sunsetting our SDKs and will no longer add new features, security patches, bug fixes, or technical support for them. To access the latest capabilities and ongoing improvements, we encourage you to migrate to our [RESTful API](/api-rest/introduction).

  SDK support will officially end on **December 31, 2026**. On this date, the underlying endpoints used by the SDKs and related documentation will be decommissioned.

  To avoid any disruption to your services, please ensure your migration is complete by that date.

  For migration assistance, please contact us at [support@bigdata.com](mailto:support@bigdata.com).
</Warning>

Formatter for inline attributions in chat messages that uses Markdown links.

## Methods

### `__init__(headline_length=None, skip_empty_urls=True)`

Initialize the MarkdownLinkInlineAttributionFormatter.

**Parameters:**

<ParamField query="headline_length" type="int">
  The maximum length of the headline to be displayed in the link.
</ParamField>

<ParamField query="skip_empty_urls" type="bool">
  Whether to skip sources with empty URLs.
</ParamField>

### `format(index, source)`

Format an inline attribution as a Markdown link.

**Parameters:**

<ParamField query="index" type="int" required>
  The index of the attribution within the list of attributions.
</ParamField>

<ParamField query="source" type="ChatSource" required>
  The inline attribution to format: [ChatSource](./chatSource)
</ParamField>

**Returns:**

A string representing the formatted attribution as a Markdown link.

<RequestExample>
  ```python Example theme={null}
  # Import classes from the bigdata-client Python SDK        
  from bigdata_client import Bigdata
  from bigdata_client.models.chat import MarkdownLinkFormatter
  formatter = MarkdownLinkFormatter()

  # Log in to Bigdata
  bigdata = Bigdata("YOUR_USERNAME", "YOUR_PASSWORD")

  # Create a new chat with the Markdown formatter
  chat = bigdata.chat.new("Pfizer company analysis", formatter=formatter)

  # First question
  response = chat.ask("Evaluate the experience and reputation of the management team of Pfizer in 2024?", streaming=True)
  print(f"\nQuestion:\n - {response.question}")
  print(f"\nAnswer:")
  for streamingChatInteraction in response:
      print(streamingChatInteraction, end="")
  ```
</RequestExample>
