semvec/pypi-packages huggingface dataset:
chorey 0.1.0
Asynchronous, Type-Safe Python Pipeline Framework
License: MIT
Requires Python: >=3.11

# Chorey: The Asynchronous, Type-Safe Python Pipeline Framework 🚀

**Chorey** is a modern, lightweight, and highly testable framework for building complex data and control flows in Python. It allows you to chain asynchronous functions, manage shared state, implement conditional routing, and handle concurrency, **all while preserving end-to-end type safety**.


## Key Features ✨

- **Asynchronous by Design** ⚡️: Built on `asyncio` for efficient, non-blocking I/O-bound tasks.
- **Intuitive Chaining**  🔗: Construct complex workflows using a fluent `.next()` API.
- **Advanced Control Flow**  🚦: Built-in support for concurrent execution (`.branch()`) and conditional logic (`.route()`).
- **Resilience**  🛡️: Configure automatic retries and custom failure callbacks for any step.
- **Type Safety** ✅: **Chorey**'s biggest selling point: **enforces strict type contracts between all pipeline stages**.
- **Visualization**  📊: Automatically generate **Mermaid diagrams** for visual inspection and debugging.

## Quick Start  🏁

### Installation  🛠️

```bash
pip install chorey
# or with cli tools
pip install chorey[cli]
```

### Example Pipeline  🧑‍💻

Define a pipeline by chaining asynchronous functions with the `step` factory:

```python
from chorey import step
from dataclasses import dataclass
import asyncio

@dataclass
class User:
    id: int
    name: str

async def fetch_user(user_id: int) -> User:
    # Simulate API call
    return User(id=user_id, name="Jane Doe")

async def welcome_user(user: User) -> str:
    return f"Welcome, {user.name}!"

# Define the pipeline chain
pipeline = step(fetch_user).next(welcome_user)

if __name__ == "__main__":
    result = asyncio.run(pipeline.feed(42))
    print(result) # Output: Welcome, Jane Doe!
```

## Documentation  📚

For comprehensive guides on shared context, routing, branching, and CLI usage, please visit the [Official Chorey Documentation](https://anwitars.github.io/chorey). Currently the code documentation is not reliable, so please refer to the docs for the most accurate information.

## Roadmap 🛤️

This is the first iteration of **Chorey**. Other than documentation, I do not have more plans yet, as I am currently collecting feedback. If you have any feature requests or ideas, - until I set up a more formal process on GitHub - please [email me](mailto:anwitarsbusiness@gmail.com?subject=chorey%3A%20).

---

© 2025 anwitars | Licensed under the MIT License
llama-index-vector-stores-azurepostgres 0.2.0
AI framework integrations for Azure Database for PostgreSQL
License: MIT
Keywords: azure, database, llamaindex, postgresql, vectorstore

# llama-index-vector-stores-azurepostgresql

Azure PostgreSQL Vector Store integration for [LlamaIndex](https://github.com/run-llama/llama_index).

This package provides an integration for using Azure Database for PostgreSQL as a vector store backend with LlamaIndex, supporting advanced vector search capabilities (including pgvector, DiskANN, and hybrid search).

## Features

- Store and query vector embeddings in Azure PostgreSQL
- Support for pgvector and DiskANN extensions
- Metadata filtering
- Seamless integration with LlamaIndex's core abstractions

## Installation

You can install the package and its dependencies using [uv](https://github.com/astral-sh/uv), pip, or poetry:

```bash
uv pip install .
# or
pip install .
# or
poetry install
```

**Dependencies:**

- `llama-index`
- `psycopg` (PostgreSQL driver)
- `azure-identity` (for Azure authentication)

## Usage Example

```python
import sys

sys.path.insert(0, "/path/to/llama-index-vector-stores-azurepostgresql")

from llama_index.vector_stores.azurepostgresql.base import AzurePGVectorStore
from llama_index.core import (
    SimpleDirectoryReader,
    StorageContext,
    VectorStoreIndex,
)
from llama_index.llms.azure_openai import AzureOpenAI
from llama_index.embeddings.azure_openai import AzureOpenAIEmbedding

# Set up your Azure OpenAI and PostgreSQL connection details
llm = AzureOpenAI(...)
embed_model = AzureOpenAIEmbedding(...)

vector_store = AzurePGVectorStore.from_params(
    database="postgres",
    host="<your-host>.postgres.database.azure.com",
    port=5432,
    table_name="my_table",
    embed_dim=1536,
    pg_diskann_kwargs={
        "pg_diskann_operator_class": "vector_cosine_ops",
        "pg_diskann_max_neighbors": 32,
        "pg_diskann_l_value_ib": 100,
        "pg_diskann_l_value_is": 100,
        "pg_diskann_iterative_search": True,
    },
)

storage_context = StorageContext.from_defaults(vector_store=vector_store)
documents = SimpleDirectoryReader("./data").load_data()
index = VectorStoreIndex.from_documents(
    documents, storage_context=storage_context
)
query_engine = index.as_query_engine()
response = query_engine.query("Your query here")
print(response)
```

## Development

- To run tests:
  ```bash
  make test
  ```
- To build the package:
  ```bash
  uv build
  ```

## License

This project is licensed under the terms of the Apache 2.0 license.