LogoLogo
Sign inVisit bito.aiVideo Library
  • 👋Welcome to Bito
  • 🆕Getting started
  • 🛡️Privacy and security
  • 🤖AI Code Review Agent
    • Overview
    • Key features
    • Supported programming languages and tools
    • Install/run using Bito Cloud
      • Guide for GitHub
      • Guide for GitHub (Self-Managed)
      • Guide for GitLab
      • Guide for GitLab (Self-Managed)
      • Guide for Bitbucket
      • Integrate the AI Code Review Agent into the CI/CD pipeline
      • Create or customize an Agent instance
      • Clone an Agent instance
      • Delete unused Agent instances
    • Install/run as a self-hosted service
      • Prerequisites
      • CLI vs webhooks service
      • Install/run via CLI
      • Install/run via webhooks service
      • Install/run via GitHub Actions
      • Agent Configuration: bito-cra.properties File
    • Available commands
    • Chat with AI Code Review Agent
    • Implementing custom code review rules
    • Excluding files, folders, or branches with filters
    • Code review analytics
    • FAQs
  • Other Bito AI tools
    • IDE extension
      • Quick Overview
      • Installation guide
        • Installing on Visual Studio Code
        • Installing on JetBrain IDEs
        • Vim/Neovim Plugin
      • Upgrading Bito plugin
      • AI Chat in Bito
        • Keyboard shortcuts
        • Chat session history
        • Share chat session
        • Appearance settings
        • Open Bito in a new tab or window
        • Use cases and examples
      • Templates
        • Standard templates
        • Custom prompt templates
        • Diff view
      • AI that Understands Your Code
        • Overview
        • How it Works?
        • Available Keywords
        • Example Questions
        • How does Bito Understand My Code?
        • Using in Visual Studio Code
        • Using in JetBrains IDEs
        • Managing Index Size
        • FAQs
      • AI Code Completions
        • Overview
        • How it works?
        • Enable/disable settings
        • Accept/reject suggestions
        • Keyboard shortcuts
        • Supported programming languages
        • Use cases and examples
      • Basic/Advanced AI models
      • Wingman Coding Agent
        • Key features
        • Supported tools
        • Getting started
    • Bito CLI
      • Overview
      • Install or uninstall
      • Configuration
      • How to use?
      • Available commands
      • FAQs
    • Google Chrome extension
  • Help
    • 🧠Bito's AI stack
      • Embeddings
      • Vector databases
      • Indexing
      • Generative AI
      • Large Language Models (LLM)
      • LLM tokens
      • LLM parameters
      • Retrieval Augmented Generation (RAG)
      • Prompts
      • Prompt engineering
    • 👥Account and settings
      • Creating a Bito account
      • Workspace
      • Managing workspace members
      • Setting AI output language
      • Managing user access levels
      • Access key
    • 💳Billing and plans
      • Overview
      • Payment methods
      • Managing workspace plan
      • Pay for additional workspace members
      • Advanced AI requests usage
      • Billing history
      • Billing details
      • Security
      • Refund policy
      • Discounts
    • ⚒️Support and questions
      • Getting support
      • Troubleshooting
      • Is it GPT-4?
  • 🆕Changelog
  • External Links
    • Git
    • Github Issues
    • Github Discussions
    • Bito.ai
    • VS Code Marketplace
    • JetBrain Marketplace
Powered by GitBook
LogoLogo

Bito Inc. (c) 2025

On this page
  • Creating a Custom Prompt Template
  • Editing or Deleting a Custom Template
  • Using a Custom Template

Was this helpful?

Export as PDF
  1. Other Bito AI tools
  2. IDE extension
  3. Templates

Custom prompt templates

PreviousStandard templatesNextDiff view

Last updated 4 months ago

Was this helpful?

🤯 Sick of typing out long prompts every time? 😩 Bito's got your back! Now, create custom prompt templates for all your frequently used prompts and save yourself some stress.

With "Create Prompt Template," you can create and save custom prompt templates for use in your IDE. By defining a custom template with a template name and prompt, Bito can execute the prompt as is on the selected code. With this feature, you can save time and streamline your workflow by quickly executing frequently used prompts without inputting them manually each time.

The custom prompt templates feature and standard prompt templates are located below the chatbox.

Here is a quick overview of the Custom Prompt Templates in Bito

Creating a Custom Prompt Template

  1. Open Bito Plugin in your IDE

  2. Below the chatbox, click on "New Template".

  1. Enter the "Template Name" and "Prompt" for your custom template. You can use {{%code%}} as a macro to insert the selected code in your prompt. If this macro is not used, Bito will insert the selected code at the end of your prompt. Next, select the "Output Format". You currently have two options:

    1. Display in Bito panel (Default)

    2. Output in diff view

  1. Click on "Create Template" to save your new custom template. All custom templates will appear below the chatbox alongside standard templates. You can create up to four custom templates.

Tips: Creating a good AI prompt is an iterative process. We recommend you iterate various options and check the output to ensure your satisfaction. Here are some helpful hints:

  1. Add instruction in the template to enclose any code output in triple backticks (```). This will ensure that the code is formatted in a code block in the output.

  2. Write clear and specific instructions. If you want output in a specific format, ask to structure the output in that format.

  3. Specify the steps to complete the task. A clearly defined set of steps allows the model to think and work out a solution before generating the output.

  4. Custom templates require selecting code in IDE. Bito replaces all instances of the {{%code%}} in the template with the selected code. If no {{%code%}} macro is found, the selected code is appended to the end of the code.

Example 1: OWASP Security Issue

Your task is to analyze the code given below: {{%code%}}. The code needs to be analyzed for the top 10 security vulnerabilities defined by OWASP. If no vulnerability is found, the output should be "No Issue Found". If any issue is found, identify all instances of the code. The output should include a list of all issues and the fixed code in the following format. The code should be enclosed in the three backticks.

Issues: List of Issues

Code: Fixed code enclosed in three back ticks

Editing or Deleting a Custom Template

You can edit or remove the templates anytime by clicking on the three dots over the template that you want to edit or remove. Note that you can edit or remove the standard templates provided by Bito.

Using a Custom Template

  1. Select any code that you want to execute the prompt.

  2. Run the Custom Template by clicking it in the Bito Templates panel or from the IDE context menu.

  3. Bito starts generating output

Here’s an example of how to execute prompts using your custom templates.

Let’s say you want to create a custom template to add a comment describing the logic behind the code. Here's how you can do it:

  1. Below the chatbox, click on "New template".

  2. Enter a name for your custom template, e.g. "Add Comment"

  3. In the "Prompt" field, enter the following: "Please add a comment describing the logic behind the code. " and then click on "Create Template" to save your new custom template

  1. Now, select the code to which you want to comment and click on the "Add Comment" template.

  1. Bito adds the selected code at the end of the prompt and executes it via Bito AI.

Bito Custom Prompt Template
Create Prompt Template Feature
My custom templates
Edit/Remove my custom templates