semvec/pypi-packages huggingface dataset:
langchain-milvus 0.3.3
An integration package connecting Milvus and LangChain
License: MIT
Requires Python: <4.0,>=3.10

# 🦜️🔗 LangChain Milvus

[![License](https://img.shields.io/badge/License-MIT-blue.svg)](https://opensource.org/licenses/MIT)
[![Twitter](https://img.shields.io/twitter/url/https/twitter.com/LangChainAI.svg?style=social&label=Follow%20%40LangChain)](https://x.com/LangChainAI)
[![Twitter](https://img.shields.io/twitter/url/https/twitter.com/milvusio.svg?style=social&label=Follow%20%40Milvus)](https://x.com/milvusio)

![](https://github.com/langchain-ai/langchain-milvus/blob/main/readme_img.png)

This repository contains the Milvus integration package for LangChain:

- [langchain-milvus](https://pypi.org/project/langchain-milvus/) - A powerful integration between LangChain and Milvus, enabling vector search and retrievers for AI applications.

## Overview

LangChain Milvus provides seamless integration between LangChain, a framework for building applications with large language models (LLMs), and Milvus, a powerful vector database designed for similarity search and AI applications. This integration enables efficient vector storage and retrieval for AI applications like semantic search, recommendation systems, and RAG (Retrieval Augmented Generation).

## Features

- **Vector Storage**: Store embeddings from any LangChain embedding model in Milvus
- **Similarity Search**: Perform efficient similarity searches on vector data
- **Hybrid Search**: Combine vector search with keyword search for improved results
- **Maximal Marginal Relevance**: Filter for diversity in search results
- **Multiple Vector Fields**: Support for multiple vector fields in a single collection
- **Sparse Embeddings**: Support for sparse vector embeddings
- **Built-in Functions**: Support for Milvus built-in functions like BM25
- **Async Support**: Full support for async operations and APIs

## Installation

```bash
pip install -U langchain-milvus
```

## Usage
- [Basic Usage](https://milvus.io/docs/basic_usage_langchain.md): Learn how to get started with basic vector operations in Milvus using LangChain.

- [Build RAG(Retrieval Augmented Generation)](https://milvus.io/docs/integrate_with_langchain.md): Discover how to build powerful RAG applications by combining LangChain with Milvus.

- [Full-text Search](https://milvus.io/docs/full_text_search_with_langchain.md): Explore how to implement full-text search capabilities using LangChain and Milvus.

- [Hybrid Search](https://milvus.io/docs/milvus_hybrid_search_retriever.md): Learn how to combine vector and keyword search for more accurate results.



## Contributing

Contributions are welcome! Please see [CONTRIBUTING.md](https://github.com/langchain-ai/langchain-milvus/blob/main/CONTRIBUTING.md) for guidelines.

## License

This project is licensed under the MIT License - see the [LICENSE](https://github.com/langchain-ai/langchain-milvus/blob/main/LICENSE) file for details.
dev-utils-jokerssd 0.5.2
Development utilities with structured logging
License: MIT
Requires Python: >=3.12

# Dev Utils

A collection of development utilities, starting with structured logging.

## Installation

```bash
pip install dev-utils-jokerssd
```

## Logging Utils

A powerful wrapper around `structlog` and Python's standard `logging` module to provide structured JSON logging with rotation, async writing, and easy configuration.

### Usage

```python
from dev_utils import LoggingUtils

# Basic Setup
logging_utils = LoggingUtils(
    log_file="app.log",
    log_level="INFO",
    print_output=True,
    json_formatter=True,
    binding_dict={"app_name": "my_app"}
)

logger = logging_utils.get_logger()

# Log something
logger.info("Application started", version="1.0.0")

# Exception logging
try:
    1 / 0
except ZeroDivisionError:
    logger.exception("Something went wrong")
```

### Features

-   **Structured JSON Logs**: By default, logs are formatted as JSON for easy parsing by log management tools.
-   **Async Logging**: Uses a background thread for file writing to avoid blocking the main execution path.
-   **Log Rotation**: Automatically rotates log files daily (default).
-   **Context Binding**: Bind global context variables (like `request_id` or `user_id`) to all logs.
-   **Standard API**: Compatible with standard python `logging` (mostly) and `structlog`.

## Lark Wrapper

A wrapper for interaction with Lark/Feishu Custom bots, providing strong typing and error handling.

### Usage

```python
from dev_utils.lark_wrapper import MsgBot, BotType, MsgType, BotStatus

# Initialize the bot
bot = MsgBot(
    chat_id="your-chat-id",
    url="https://open.larksuite.com/open-apis",
    api_name="bot/v2/hook/",
    bot_type=BotType.LARK
)

# Send a text message
response = bot.send_cust_bot_msg(
    message="Hello, World!",
    msg_type=MsgType.TEXT,
    title="Notification"
)

# Check response
if response.status == BotStatus.OK:
    print("Success:", response.msg)
else:
    print("Failed:", response.errors)
```

### Features

-   **Strong Typing**: Uses `BotStatus`, `BotType`, and `BotResponse` for predictable API interactions.
-   **Multi-Platform Support**: Extensible design (currently supports Lark).
-   **Async Support**: `async_send_msg` available for non-blocking operations.
-   **Rich Content**: Supports Post/Rich Text messages via `MsgType.POST`.