Skip to main content

Quick Start

Get started quickly with Clarifai in a few simple steps




Clarifai provides an intuitive interface and a robust API designed to get you up and running quickly. In just a few simple steps or a few lines of code, you can bring your AI projects to life within minutes.

Set up Your Account or Log in

Create a new Clarifai account or log in to your existing one to start accessing the platform's powerful AI capabilities.

Try Out Our Community Models

We offer a diverse collection of Community models that you can browse, test, and integrate into your projects.

Step 1: Find a Model

You can easily find a model to use by heading to the homepage and exploring the Trending AI models section, which showcases popular and ready-to-use options.

After finding the model, click the TEST IN PLAYGROUND button in the bottom left corner of its information card.

For this example, we'll use the Llama-3.2-3B-Instruct model.

Alternatively, you can select the Playground option in the top navigation bar.

Step 2: Run Your Inference in Playground

You'll be taken to the Playground interface, which is a pre-authenticated testing environment that allows you to quickly interact with Clarifai's AI models without additional setup or authentication.

In the chat interface at the bottom of the Playground, enter your desired prompt to generate text with the selected model. Note that if the model supports image inputs as prompts, you can also upload images directly into the interface.

Alternatively, in the upper-left section of the Playground, you can choose the model you'd like to use for inference.

Then, click the arrow icon to submit your request.

The results will be streamed directly in the interface, allowing you to see the output in real time.

info
  • For this example, we're using the default settings for deployment (Clarifai Shared), inference parameters, and others. You can customize these settings as needed for more advanced use cases.

  • You can toggle the button in the upper-left section of the Playground to display ready-to-use API code snippets in various programming languages. Simply copy and use them in your project.

Call Your First Model With Our API

You can access the Clarifai API effortlessly using your preferred method:

  • SDKs – Quick integration with official client libraries.

  • CLI (Command Line Interface) – Manage tasks directly from the command line.

  • HTTP Requests – Use any programming language with REST API calls.

  • gRPC Clients – High-performance support for popular languages.

Step 1: Get a PAT Key

You need a PAT (Personal Access Token) key to authenticate your connection to the Clarifai platform. You can generate the PAT key in your personal settings page by navigating to the Security section.

Step 2: Install Your Preferred Client

pip install --upgrade clarifai

Step 3: Send an API Request

For this example, let's use the Llama-3.2-3B-Instruct model to generate text based on a given prompt.

from clarifai.client.model import Model

prompt = "What is the future of AI?"

model_url="https://clarifai.com/meta/Llama-3/models/Llama-3_2-3B-Instruct"

# Model Predict
model_prediction = Model(url=model_url, pat="YOUR_PAT_HERE").predict_by_bytes(prompt.encode(), input_type="text")

print(model_prediction.outputs[0].data.text.raw)
Output Example
The future of AI is a topic of much debate and speculation. While it's difficult to predict exactly what the future holds, here are some potential trends and developments that could shape the future of AI:

1. **Increased Integration with Other Technologies**: AI is likely to become even more integrated with other technologies such as blockchain, the Internet of Things (IoT), and 5G networks. This could lead to new applications and use cases that we cannot yet imagine.

2. **Advances in Explainability and Transparency**: As AI becomes more pervasive, there will be a growing need for explainability and transparency. This could involve the development of new techniques for interpreting and understanding AI decision-making processes.

3. **Rise of Edge AI**: Edge AI refers to the processing of AI tasks at the edge of the network, rather than in a centralized cloud. This could enable faster and more efficient AI processing, particularly in applications such as autonomous vehicles and smart cities.

4. **Increased Focus on Ethics and Fairness**: As AI becomes more influential, there will be a growing need to address issues of ethics and fairness. This could involve the development of new AI systems that are designed to be more transparent, explainable, and equitable.

5. **Potential for AI to Disrupt Traditional Industries**: AI has the potential to disrupt traditional industries such as healthcare, finance, and education. This could lead to significant job displacement and the need for workers to adapt to new roles and responsibilities.

6. **Advances in Natural Language Processing (NLP)**: NLP is a key area of research in AI, and it's likely that we'll see significant advances in this area over the coming years. This could enable AI systems to better understand and respond to human language, leading to more natural and intuitive interfaces.

7. **Increased Use of Reinforcement Learning**: Reinforcement learning is a type of machine learning that involves training AI systems through trial and error. This could enable AI systems to learn more efficiently and effectively, particularly in applications such as robotics and game playing.

8. **Potential for AI to Enhance Human Capabilities**: AI has the potential to enhance human capabilities, particularly in areas such as cognitive abilities and physical abilities. This could lead to significant improvements in productivity and quality of life.

Some potential timelines for these developments include:

* **2025**: Edge AI becomes more widespread, enabling faster and more efficient AI processing.
* **2030**: AI systems become more integrated with other technologies such as blockchain and IoT.
* **2035**: Advances in NLP lead


Congratulations — you've just get started with the Clarifai platform!