semvec/pypi-packages huggingface dataset:
llama-index-embeddings-gigachat 0.4.1
llama-index embeddings gigachat integration
Requires Python: <4.0,>=3.9

# LlamaIndex Embeddings Integration: GigaChat

GigaChat Embedding provides a way to generate embeddings for text and documents using the GigaChat API within the llama_index library.

To learn more about GigaChat and embedding principles, visit https://developers.sber.ru/docs/ru/gigachat/api/embeddings?tool=api

## Installation

```bash
pip install gigachat
pip install llama-index-embeddings-gigachat
```

## Usage

```python
from llama_index.embeddings.gigachat import GigaChatEmbedding
```

**Initialization Parameters:**

- `auth_data`: GigaChat authentication data.
- `scope`: The scope of your GigaChat API access. Use "GIGACHAT_API_PERS" for personal use or "GIGACHAT_API_CORP" for corporate use.

```python
embeddings = GigaChatEmbedding(
    auth_data="YOUR_AUTH_DATA",
    scope="GIGACHAT_API_CORP",
)
```

## Example

See the [example notebook](https://github.com/run-llama/llama_index/tree/main/docs/docs/examples/embeddings/gigachat.ipynb) for a detailed walkthrough of using GigaChat embeddings with LlamaIndex.
llama-index-embeddings-deepinfra 0.4.1
llama-index embeddings deepinfra integration
Requires Python: <4.0,>=3.9

# LlamaIndex Embeddings Integration: Deepinfra

With this integration, you can use the Deepinfra embeddings model to get embeddings for your text data.
Here is the link to the [embeddings models](https://deepinfra.com./models/embeddings).

First, you need to sign up on the [Deepinfra website](https://deepinfra.com/) and get the API token.
You can copy model_ids over the model cards and start using them in your code.

## Installation

```bash
pip install llama-index llama-index-embeddings-deepinfra
```

## Usage

```python
from dotenv import load_dotenv, find_dotenv
from llama_index.embeddings.deepinfra import DeepInfraEmbeddingModel

# Load environment variables
_ = load_dotenv(find_dotenv())

# Initialize model with optional configuration
model = DeepInfraEmbeddingModel(
    model_id="BAAI/bge-large-en-v1.5",  # Use custom model ID
    api_token="YOUR_API_TOKEN",  # Optionally provide token here
    normalize=True,  # Optional normalization
    text_prefix="text: ",  # Optional text prefix
    query_prefix="query: ",  # Optional query prefix
)

# Example usage
response = model.get_text_embedding("hello world")

# Batch requests
texts = ["hello world", "goodbye world"]
response = model.get_text_embedding_batch(texts)

# Query requests
response = model.get_query_embedding("hello world")


# Asynchronous requests
async def main():
    text = "hello world"
    response = await model.aget_text_embedding(text)


if __name__ == "__main__":
    import asyncio

    asyncio.run(main())
```
llama-index-embeddings-databricks 0.4.1
llama-index embeddings databricks integration
Requires Python: <4.0,>=3.9

# LlamaIndex Embeddings Integration: Databricks

This integration adds support for embedding models hosted on the databricks platform via serving endpoints. The API follows the specifications of OpenAI, so this integration simply adapts the `llama-index-embeddings-openai` integration and internally uses the `openai` Python API library, too.

The signature furthermore aligns with the existing Databricks LLM integration with respect to the naming of the `model`, `api_key` and `endpoint` variables to ensure a smooth user experience.

## Installation

```
pip install llama-index
pip install llama-index-embeddings-databricks
```

## Usage

Passing the `api_key` and `endpoint` directly as arguments:

```python
import os
from llama_index.core import Settings
from llama_index.embeddings.databricks import DatabricksEmbedding

# Set up the DatabricksEmbedding class with the required model, API key and serving endpoint
embed_model = DatabricksEmbedding(
    model="databricks-bge-large-en",
    api_key="<MY TOKEN>",
    endpoint="<MY ENDPOINT>",
)
Settings.embed_model = embed_model

# Embed some text
embeddings = embed_model.get_text_embedding(
    "The DatabricksEmbedding integration works great."
)
```

Using environment variables:

```
export DATABRICKS_TOKEN=<MY TOKEN>
export DATABRICKS_SERVING_ENDPOINT=<MY ENDPOINT>
```

```python
import os
from dotenv import load_dotenv
from llama_index.core import Settings
from llama_index.embeddings.databricks import DatabricksEmbedding

load_dotenv()
# Set up the DatabricksEmbedding class with the required model, API key and serving endpoint
embed_model = DatabricksEmbedding(model="databricks-bge-large-en")
Settings.embed_model = embed_model

# Embed some text
embeddings = embed_model.get_text_embedding(
    "The DatabricksEmbedding integration works great."
)
```
llama-index-embeddings-cloudflare-workersai 0.4.1
llama-index embeddings Cloudflare Workers AI integration
Requires Python: <4.0,>=3.9

# LlamaIndex Embeddings Integration: Cloudflare Workers AI

Cloudflare Workers AI provides text embedding service for Cloudflare users. You can find a full list of available models from its document
https://developers.cloudflare.com/workers-ai/models/#text-embeddings

To learn more about Cloudflare Workers AI in general, visit https://developers.cloudflare.com/workers-ai/

## Example

```shell
pip install llama-index-embeddings-cloudflare-workersai
```

```py
from llama_index.embeddings.cloudflare_workersai import CloudflareEmbedding

my_account_id = "example_account_id"
my_api_token = "example_token"

my_embed = CloudflareEmbedding(
    account_id=my_account_id,
    auth_token=my_api_token,
    model="@cf/baai/bge-base-en-v1.5",
)

embeddings = my_embed.get_text_embedding("Why sky is blue")

embeddings_batch = my_embed.get_text_embedding_batch(
    ["Why sky is blue", "Why roses are red"]
)
```

For more detailed example of installation and usage, please refer to the [Jupyter Notebook example](https://docs.llamaindex.ai/en/stable/examples/embeddings/cloudflare_workersai/).
llama-index-embeddings-azure-inference 0.4.1
Integration for model supporting Azure AI model inference API in llama-index
Requires Python: <4.0,>=3.9

# LlamaIndex Embeddings Integration: Azure AI model inference

The integration package `llama-index-embeddings-azure-inference` brings support for embedding models deployed in Azure AI, including Azure AI studio and Azure Machine Learning, to the `llama_index` ecosystem. Any model endpoint supporting the [Azure AI model inference API](https://aka.ms/azureai/modelinference) can be used with this integration.

For details and examples about how to use this integration, see [Getting starting with LlamaIndex and Azure AI](https://aka.ms/azureai/llamaindex).

## Changelog

- **0.2.4**:

  - Introduce `api_version` parameter in the `AzureAIEmbeddingsModel` class to allow overriding of the default value.
  - Introduce support for [Azure AI model inference service](https://aka.ms/aiservices/infernece) which requires `azure-ai-inference>=1.0.0b5`.
llama-index-embeddings-autoembeddings 0.2.1
llama-index embeddings AutoEmbeddings integration
Requires Python: <4.0,>=3.9

# LlamaIndex Embeddings Integration: AutoEmbeddings

AutoEmbeddings is a very useful module available within [Chonkie](https://docs.chonkie.ai) that can initialize several different embeddings providers within one single interface:

- OpenAI
- Model2Vec
- Cohere
- Jina AI
- Sentence Transformers

You can install it with:

```bash
pip install llama-index-embeddings-autoembeddings
```

And then you can use it in your scripts as:

```python
from llama_index.embeddings.autoembeddings import ChonkieAutoEmbedding

embedder = ChonkieAutoEmbedding(model_name="all-MiniLM-L6-v2")
vector = embedder.get_text_embedding(
    "The quick brown fox jumps over the lazy dog."
)
print(vector)
```

If you want to use it with a non-local embeddings provider, you should declare the API key as an environment variable:

```python
from llama_index.embeddings.autoembeddings import ChonkieAutoEmbedding
import os

os.environ["OPENAI_API_KEY"] = "YOUR-API-KEY"
embedder = ChonkieAutoEmbedding(model_name="text-embedding-3-large")
vector = embedder.get_text_embedding(
    "The quick brown fox jumps over the lazy dog."
)
print(vector)
```
llama-index-embeddings-alibabacloud-aisearch 0.3.1
llama-index embeddings alibabacloud_aisearch integration
Requires Python: <4.0,>=3.9

# LlamaIndex Embeddings Integration: Alibabacloud_Aisearch

## Installation

```
pip install llama-index-embeddings-alibabacloud-aisearch
```

## Usage

For further details, please visit [text-embedding-api-details](`https://help.aliyun.com/zh/open-search/search-platform/developer-reference/text-embedding-api-details`).

You can specify the `endpoint` and `aisearch_api_key` in the constructor, or set the environment variables `AISEARCH_ENDPOINT` and `AISEARCH_API_KEY`.

```python
from llama_index.embeddings.alibabacloud_aisearch import (
    AlibabaCloudAISearchEmbedding,
)

embed_model = AlibabaCloudAISearchEmbedding()
embedding = embed_model.get_query_embedding("llama-index")
print(len(embedding))

# embeddings = embed_model.get_text_embedding_batch(
#     ["科学技术是第一生产力", "opensearch产品文档"], show_progress=True
# )
```
llama-index-embeddings-alephalpha 0.4.1
llama-index embeddings alephalpha integration
Requires Python: <4.0,>=3.9

# LlamaIndex Embeddings Integration: Aleph Alpha

This README provides an overview of integrating Aleph Alpha's semantic embeddings with LlamaIndex. Aleph Alpha's API enables the generation of semantic embeddings from text, which can be used for downstream tasks such as semantic similarity and models like classifiers.

## Features

- **Semantic Embeddings:** Generate embeddings for text prompts using Aleph Alpha models.
- **Model Selection:** Utilize the latest version of specified models for generating embeddings.
- **Representation Types:** Choose from `symmetric`, `document`, and `query` embeddings based on your use case.
- **Compression:** Option to compress embeddings to 128 dimensions for faster comparison.
- **Normalization:** Retrieve normalized embeddings to optimize cosine similarity calculations.

## Installation

```bash
pip install llama-index-embeddings-alephalpha
```

## Usage

```python
from llama_index.embeddings.alephalpha import AlephAlphaEmbedding
```

1. **Request Parameters:**

   - `model`: Model name (e.g., `luminous-base`). The latest model version is used.
   - `representation`: Type of embedding (`symmetric`, `document`, `query`).
   - `prompt`: Text or multimodal prompt to embed. Supports text strings or an array of multimodal items.
   - `compress_to_size`: Optional compression to 128 dimensions.
   - `normalize`: Set to `true` for normalized embeddings.

2. **Advanced Parameters:**
   - `hosting`: Datacenter processing option (`aleph-alpha` for maximal data privacy).
   - `contextual_control_threshold`, `control_log_additive`: Control attention parameters for advanced use cases.

## Response Structure

- `model_version`: Model name and version used for inference.
- `embedding`: List of floats representing the generated embedding.
- `num_tokens_prompt_total`: Total number of tokens in the input prompt.

## Example

See the [example notebook](../../../docs/examples/embeddings/alephalpha.ipynb) for a detailed walkthrough of using Aleph Alpha embeddings with LlamaIndex.

## API Documentation

For more detailed API documentation and available models, visit [Aleph Alpha's API Docs](https://docs.aleph-alpha.com/api/semantic-embed/).
llama-index-callbacks-opik 1.2.1
llama-index callbacks Opik Comet integration
Requires Python: <4.0,>=3.9

# LlamaIndex Callbacks Integration: Opik

```shell
pip install llama-index-callbacks-opik
```

This integration allows you to get one-click observability of your LlamaIndex RAG pipelines on [Opik](https://comet.com/site/products/opik/?utm_medium=docs&utm_source=llamaindex&utm_campaign=opik).

The simplest way to get started and try out Opik is to signup on our [cloud instance](https://comet.com/signup?from=llm?utm_medium=docs&utm_source=llamaindex&utm_campaign=opik).
You can then get you API key from the quickstart page or the user menu and start logging !

You can initialize globally using

```python
from llama_index.core import set_global_handler

# You should provide your OPIK API key and Workspace using the following environment variables:
# OPIK_API_KEY, OPIK_WORKSPACE
set_global_handler("opik")
```

or:

```python
from llama_index.core import Settings
from llama_index.core.callbacks import CallbackManager
from opik.integrations.llama_index import LlamaIndexCallbackHandler

opik_callback_handler = LlamaIndexCallbackHandler()
Settings.callback_manager = CallbackManager([opik_callback_handler])
```
llama-index-callbacks-literalai 1.3.1
llama-index callbacks literalai integration
Requires Python: <4.0,>=3.9

# LlamaIndex Callbacks Integration: Literal AI

This integration allows you to get one-click observability of your LlamaIndex RAG pipelines on [Literal AI](https://literalai.com/).

The simplest way to get started and try out Literal AI is to signup on our [cloud instance](https://cloud.getliteral.ai/).
You can then navigate to **Settings**, grab your API key, and start logging !
llama-index-callbacks-langfuse 0.4.1
llama-index callbacks langfuse integration
Requires Python: <4.0,>=3.9

# LlamaIndex Callbacks Integration: Langfuse

[Langfuse](https://langfuse.com/docs) is an open source LLM engineering platform to help teams collaboratively debug, analyze and iterate on their LLM Applications. With the Langfuse integration, you can seamlessly track and monitor performance, traces, and metrics of your LlamaIndex application. Detailed traces of the LlamaIndex context augmentation and the LLM querying processes are captured and can be inspected directly in the Langfuse UI.

#### Usage Pattern

```python
from llama_index.core import set_global_handler

# Make sure you've installed the 'llama-index-callbacks-langfuse' integration package.

# NOTE: Set your environment variables 'LANGFUSE_SECRET_KEY', 'LANGFUSE_PUBLIC_KEY' and 'LANGFUSE_HOST'
# as shown in your langfuse.com project settings.

set_global_handler("langfuse")
```

![langfuse-tracing](https://static.langfuse.com/llamaindex-langfuse-docs.gif)
llama-index-callbacks-agentops 0.4.1
llama-index instrumentation agentops integration
Requires Python: <4.0,>=3.9

# LlamaIndex Callback Integration: Agentops

```shell
pip install llama-index-callbacks-agentops
```

To integrate AgentOps into your agent workflow,
simply import and initialize an `AgentOpsHandler`,
as demonstrated below. Note that all keyword arguments
anticipated by AgentOps' `AOClient` can be provided
to this client using the same keyword arguments in
`init()`.

You can initialize globally using

```python
from llama_index.core import set_global_handler

set_global_handler("agentops", api_key="...")
```

or:

```python
from llama_index.callbacks.agentops import AgentOpsHandler

AgentOpsHandler.init(api_key="...")
```
seriallll 0.1.3
Add your description here
Requires Python: >=3.8

# seriallll

A small, modest Python helper for talking to serial ports. Works elsewhere via [pyserial].

* Connect with optional retries (including “retry forever”)
* Auto-reconnect on I/O errors (e.g., cable unplug/replug)
* Simple, thread-safe read/write helpers
* Tiny API, single dependency

## Installation

```bash
pip install seriallll
# or
uv add seriallll 
```

## Quick start

```python
from seriallll import SerialClient

client = SerialClient(
    port=None,           # None for auto-discover a macOS USB serial port
    baudrate=115200,
    max_retries=-1,      # retry forever on initial connect
    auto_reconnect=True, # reconnect on I/O errors
)

client.connect()
client.write_line("hello")
print(client.readline(timeout=1.0))
client.close()
```

### Reading lines

```python
line = client.readline(timeout=2.0)  # returns b"...\\n" or b"" on timeout
```

### Raw read / write

```python
client.write(b"\x01\x02\x03")
chunk = client.read(64, timeout=0.2)
```

### Callbacks (optional)

```python
def on_reconnect(c):
    print("Reconnected to", c.port)

client = SerialClient(port=None, on_reconnect=on_reconnect)
```

## macOS notes

* Auto-discovery looks for `/dev/tty.usb*` (and falls back to `/dev/tty.*`).
* DTR (data terminal ready pin) is asserted on (re)connect, which some boards expect on macOS.

## API surface

* `SerialClient.connect() / close()`
* `SerialClient.write(data) / write_line(line, newline=b"\n")`
* `SerialClient.read(size=1, timeout=None)`
* `SerialClient.read_until(terminator=b"\n", timeout=None, max_bytes=None)`
* `SerialClient.readline(timeout=None, max_bytes=None)`
* Properties: `port`, `is_open`

## Troubleshooting

* **No port found**: pass `--port` explicitly (check `ls /dev/tty.*` on macOS).
* **Time out reading**: increase `timeout` or use `read_until/readline`.
* **Flaky cable/adapter**: keep `auto_reconnect=True`.

---

[pyserial]: https://pyserial.readthedocs.io/
ubt-runtime 0.4.0
Shared pyarmor runtime for ubTrace python packages
Requires Python: ~=3.12

# Shared ubCode pyarmor runtime

Shared pyarmor runtime as per
https://pyarmor.readthedocs.io/en/latest/reference/man.html#pyarmor-gen-runtime

# Build shared runtime

Call

	rye run runtime:generate

# Register pyarmor license

Pyarmor needs a license to run. It must be registered on the individual machines and in the CI.
Call

	rye run license:register

to register the license on the current machine. It will check if the license is already registered and
register it if not.

# codesign for macOS

When building the package on Linux, the codesign command is not available:

	WARNING  codesign command failed with:
	[Errno 2] No such file or directory: 'codesign'

Check how to fix this issue, either by postponing the codesign command to a MacOS user or by generating
the whole runtime package on MacOS.