Bits Code

Ce produit n'est pas pris en charge par le site Datadog que vous avez sélectionné. ().
Cette page n'est pas encore disponible en français, sa traduction est en cours.
Si vous avez des questions ou des retours sur notre projet de traduction actuel, n'hésitez pas à nous contacter.

Overview

Bits Code is a generative AI coding assistant that uses Datadog observability data to automatically diagnose and fix issues in your code. It integrates with source code providers to create production-ready pull or merge requests, then iterates on changes using CI logs and developer feedback.

A tab titled 'Sessions' shows a text field with suggestions underneath

Each time Bits Code investigates an issue or generates a fix, it creates a session, which captures the agent’s analysis, actions, and any resulting code changes across supported Datadog products. Set up automations to have Bits Code run sessions on a schedule or in response to signals from other Datadog products, such as a new APM Recommendation or flaky test.

To get started with Bits Code, set up a source code integration and complete any additional configuration. Then, start your first session.

Learn how your Bits Code usage is billed on AI Credits.

Sessions

A session captures a segment of work with Bits Code, including its analysis and code changes. Start, view, and manage your sessions at Bits AI > Bits Code > Sessions.

A session showing a Bits AI summary and task list on the left and a code diff on the right

Start a session

After completing setup, do one of the following to start a Bits Code session:

A session can also be created when another Bits AI agent (like Bits Chat or Bits Investigation) hands off a coding task to Bits Code.

View and manage sessions

On Sessions, view your past sessions in the My Sessions panel. A session appears here if you initiated it or interacted with it in some way, like participating in the conversation or creating an associated PR or MR.

Click a session to view its details and continue working with Bits Code. To remove a session from your My Sessions list, click (Archive for everyone) or (Unwatch session).

Supported source code providers

Bits Code supports the following source code providers:

The following plans are not supported:

Supported Datadog products

Bits Code can suggest code improvements within several Datadog products, including the following:

ProductCapabilities
APMProposes code changes for relevant APM Recommendations
Bits InvestigationGenerates code remediations based on Bits Investigations
Bits ChatSuggests code changes arising from Bits Chat conversations
Cloud CostGenerates code changes for Cloud Cost Recommendations
Error TrackingDiagnoses issues and generates code fixes on-demand or autonomously
Code SecurityRemediates SAST vulnerabilities, IaC vulnerabilities, and SCA vulnerabilities (individually or in bulk)
Test OptimizationProvides code fixes for flaky tests and verifies that tests remain stable
Continuous ProfilerProvides code changes for Automated Analysis insights
ContainersProvides code changes for Kubernetes Remediations

Key capabilities

Code fixes and optimizations surfaced by Datadog products

Across supported Datadog products, use Bits Code to implement optimizations and fixes—for example, Cloud Cost Recommendations, Error Tracking issues, and SAST vulnerabilities. In certain products, Bits Chat explores and investigates issues, then hands off its findings to Bits Code to implement a code change.

A button labeled with the text 'Fix with Bits.'

You can manually prompt Bits Code to implement changes for a certain finding, or configure an automation so that it does so autonomously.

General coding tasks

Use the freeform prompt field at Sessions to work with Bits Code on general coding tasks.

Automations

Automations run Bits Code sessions automatically, on a schedule or in response to signals from Datadog products like Error Tracking, APM, or Code Security. After a session completes, Bits Code delivers the results as a pull or merge request (optionally in draft mode) or a Slack notification.

You can build automations from triggers (a product finding, a custom prompt, a schedule, or a combination) and configure one or more outputs. Datadog-provided templates are also available to help you get started. Create and manage automations at Bits AI > Bits Code > Automations.

Custom agent skills and instructions

Bits Code can use custom skills defined in your repository. It discovers skills formatted like <skill-name>/SKILL.md in .claude/skills/, .codex/skills/, and .gemini/skills/ directories. Skills should contain YAML name and description frontmatter keys.

Bits Code automatically invokes appropriate skills based on their name and description values, and you can encourage use by mentioning skills in your custom instructions file. You can also prompt Bits Code to use a certain skill directly.

Bits Code also ingests custom instructions defined in your repository and Bits Code settings.

Pull or merge request collaboration

Bits Code integrates with source code providers to:

  • Create pull or merge requests, generating titles and descriptions based on your repository’s pull or merge request template
  • Iterate on pull requests in response to comments (GitHub only); mention @Datadog in a comment to prompt Bits for updates
  • Monitor CI logs and fix failures

Bits Code never auto-merges PRs or MRs. See all the PRs or MRs that Bits Code is working on in Bits AI > Bits Code > Sessions.

Limitations

  • Bits Code is an AI product, which means it can make mistakes. Use best practices when reviewing and testing agent-generated code.
  • Bits Code does not support multi-repository investigations.
  • When using GitLab, mentioning @Datadog in a comment to prompt Bits for updates is not supported.

Further reading