codestral

codestral is an R package that provides an RStudio addin for interacting with Mistral AI models using their API. It supports both Fill-in-the-Middle (FIM) code completion and chat functionality.

Features

Installation

You can install the development version from GitHub:

# install.packages("pak")
# pak::pak("urbs-dev/codestral")
install.packages("codestral", repos = c('https://urbs-dev.r-universe.dev', 'https://cloud.r-project.org'))

Getting Started

For detailed usage instructions and examples, please refer to the codestral-introduction vignette.

Quick Setup

  1. Get your API keys from Mistral AI Platform
  2. Initialize the package:
library(codestral)
codestral_init(mistral_apikey = "your-api-key-here", codestral_apikey = "your_codestral-api-key-here")
  1. Use the RStudio addin "Codestral code completion" to interact with the models

Documentation

library(codestral)
vignette("codestral-introduction")

License

This package is licensed under the MIT License. See LICENSE for details.