Skip to main content

LlamaIndex Llms Integration: Aliyun-PaiEas

The llama-index-llms-paieas package contains LlamaIndex integrations building applications with models on Aliyun PAI-EAS(Elastic Algorithm Service) (Chinese Version)LLM inference service.

The Elastic Algorithm Service (EAS) is a model online service platform that allows you to deploy models as online reasoning services or AI-Web applications with one click. It provides functions such as elastic scaling and blue-green deployment, which can support you to obtain high-concurrency and stable online algorithm model services at a lower resource cost. In addition, EAS also provides functions such as resource group management, version control, and resource monitoring, which facilitates you to apply model services to your business. EAS is suitable for a variety of AI reasoning scenarios such as real-time synchronous reasoning and near-real-time asynchronous reasoning, and has the capabilities of a complete operation and maintenance monitoring system.

PAI EAS's LLM Service

This example goes over how to use LlamaIndex to interact with and develop LLM-powered systems using the PAI-EAS LLM service endpoints.

With this endpoint, you'll be able to connect to various open-source LLM, such as:

Installation

pip install llama-index-llms-paieas

Setup

To get started:

  1. Create a free account with Aliyun PAI EAS and login.

  2. Refer the guide(https://help.aliyun.com/zh/pai/use-cases/deploy-llm-in-eas?spm=a2c4g.11186623.0.0.63de3c57Ef3r3C#f3ef8927ec4l2), on the EAS page, click Deploy LLM Service.

  3. Under the Basic Information, on the Public Address Call tab, click View Call Information, and get the service token PAIEAS_API_KEY and access address PAIEAS_API_BASE.

  4. Copy and save the service token as PAIEAS_API_KEY and access address as PAIEAS_API_BASE.

import os

os.environ["PAIEAS_API_KEY"] = your_service_token
os.environ["PAIEAS_API_BASE"] = your_access_address

Working with API Catalog

from llama_index.llms.paieas import PaiEas
from llama_index.core.llms import ChatMessage, MessageRole

llm = PaiEas()

messages = [
    ChatMessage(
        role=MessageRole.SYSTEM, content=("You are a helpful assistant.")
    ),
    ChatMessage(
        role=MessageRole.USER,
        content=("What is Alibaba Cloud?"),
    ),
]

llm.chat(messages)

Metadata

Release files for llama-index-llms-paieas 0.6.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for llama-index-llms-paieas 0.6.1
File Size Uploaded Provenance Actions
llama_index_llms_paieas-0.6.1.tar.gz 4.6 kB Without provenance Details for llama_index_llms_paieas-0.6.1.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for llama-index-llms-paieas 0.6.1
File Interpreter ABI Platform Actions
llama_index_llms_paieas-0.6.1-py3-none-any.whl Python 3 none any Details for llama_index_llms_paieas-0.6.1-py3-none-any.whl

Total release size: 8.8 kB

Release files / llama_index_llms_paieas-0.6.1.tar.gz

Download URL llama_index_llms_paieas-0.6.1.tar.gz
Size 4.6 kB
Tags Source
SHA-256 checksum
How to use checksums
5d23d0e1abf8d182c29105a0a75057f7dbaa132e38b033e9ae2123355e7eccf1
BLAKE2b-256 checksum
How to use checksums
f87e480726f0cf2cb88714410a990f4719145891351c7d4cea57799dfa107c46
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.12.7 {"installer":{"name":"uv","version":"0.12.7","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release files / llama_index_llms_paieas-0.6.1-py3-none-any.whl

Download URL llama_index_llms_paieas-0.6.1-py3-none-any.whl
Size 4.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
63c9436c73d1f9dfc72bd640901c06923ce4aadacad9107bf17673a95efcb10b
BLAKE2b-256 checksum
How to use checksums
f8d8617bb546188794421ac8685cbafec257dc05c8d18dab6684df376a89a8f5
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.12.7 {"installer":{"name":"uv","version":"0.12.7","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Security for llama-index-llms-paieas 0.6.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page