Using Cloudera Copilot
You can use Cloudera Copilot to assist you in code generation and code completion thus providing flexibility and efficiency in the Cloudera AI workflows.
- Start a session within your project and select JupyterLab as your editor.
- 
                Click the  Jupyter AI Chat icon in the left navigation pane. Jupyter AI Chat icon in the left navigation pane.  
- 
                Start typing in the prompt and the Cloudera Copilot will assist you.For example, enter Help me write a fibonacci function. Example use cases for Cloudera Copilot: - Debugging/fixing code
- Code completion
- Explaining code or explaining errors
- Code generation
- Refer to  Jupyter AI
                                documentation for instructions on /ask /learn /fixand/generatecommands.
 
- 
                Magic commands: - In addition to using the chat interface, you can also use Cloudera Copilot by calling Magic Commands within your notebook. Magic commands are special lines of code that will make calls to a language model that you have configured.
- Example syntax: - %load_ext jupyter_ai_magics
- %%ai anthropic.claude-3-sonnet-20240229-v1:0
- def fibonacci(
 
- Finding model ID strings for magic commands. - The Amazon Bedrock models recommended for Cloudera Copilot are:
                            - anthropic.claude-3-5-sonnet-20241022-v2:0
- mistral.mixtral-8x7b-instruct-v0:1
- meta.llama3-1-70b-instruct-v1:0
- meta.llama3-1-405b-instruct-v1:0
- amazon.titan-embed-text-v2:0
 
- For Cloudera AI Inference service, the model IDstring will be of the form:- cloudera:<model_name>. Here, the- model_nameis the same- model IDfrom the Model Endpoints details page that you added when you configured Cloudera Copilot.
 
 
- The Amazon Bedrock models recommended for Cloudera Copilot are:
                            
 
