semvec/pypi-packages huggingface dataset:
dsa-structures 0.0.1
Easy-to-use data structures package for students
Requires Python: >=3.7

# dsa-structures

This package provides simple and student-friendly implementations of basic Data Structures in Python.

Included structures:
- Linked List
- Doubly Linked List
- Stack
- Queue

## Installation

Install the package from PyPI:

pip install dsa-structures

## Usage Example

from dsa_structures import LinkedList

ll = LinkedList()
ll.append(10)
ll.append(20)
ll.append(30)

print(ll.display())  # Output: [10, 20, 30]
ofdcomparer 1.6.16
Библиотека для сравнивания ФД из ФН и ОФД

Библиотека для сравнивания ФД из ФН и ОФД
## Установка библиотеки
```cmd
pip install ofdcomparer
```

#### Сравнивание документов
```python
from ofdcomparer.dto10 import DTO10Helper
from ofdcomparer.compare_ffd import ComparerOfd

dto10 = DTO10Helper()
comparer_ofd = ComparerOfd(dto10=dto10)

# эталонный офд
etalon = {
    "1018": "112233445573",
    "1020": 1,
    "1031": 0,
    "1037": "0000000001047959",
    "1041": "9999078945337305",
    "1054": 1,
    "1055": 1,
    "1059": [
        {
            "1023": 1,
            "1030": "НДС. Крем от бородавок \"Жабка\" 20%",
            "1043": 1,
            "1079": 1,
            "1199": 1,
            "1212": 1
        }
    ],
    "1081": 1,
    "1102": 0.17,
    "1209": 2,
    "1215": 0,
    "1216": 0,
    "1217": 0,
    "fiscalDocumentType": "receipt",
    "short": False
}

# Словарь изменений, необходимых внести в эталонный ФД перед сравнением
changes = {
    "1081": 0,  # сумма по чеку (БСО) безналичными
    "1031": 1,  # сумма по чеку (БСО) наличными
    "1054": 1,  # признак расчета (1 - приход)
    "1209": 4,  # ффд
    "1021": None,  # кассир
    "1037": None,  # регистрационный номер ККТ
    "1041": None,  # заводской номер фискального накопителя
    "1042": None,  # номер чека за смену
}

# получаем последний фискальный документ по номеру 
fd_from_fn = dto10.get_fd_from_fn(fd=dto10.get_last_fiscal_document_number())
# получаем ФД с ОФД по номеру ФН и РНМ и сравниваем с ФД с ФН
assert comparer_ofd.compare_etalon_fn_ofd(etalon=etalon, changes=changes, fd=fd_from_fn,
                              ofd='taxcom')
```

Для использования Таксом ОФД требуются переменные среды: TAXCOM_INTEGRATOR_ID, TAXCOM_LOGIN, TAXCOM_PASSWORD
unimax_sampling 1.0.0
Implementation of the UniMax sampling method for effective language sampling for multilingual pretraining
Requires Python: >=3.12

# UniMax

`unimax_sampling` implements the UniMax sampling method introduced by [Chung et al. (2023)](#references). This method aims to balance language representation in multilingual large language models by explicitly capping the number of repeats over each language's corpus, thereby mitigating overfitting on tail languages while delivering more uniform coverage of head languages.

## Installation

```bash
# UniMax algorithm only
pip install unimax_sampling
# Including optional dependencies for the count-characters sub-command
pip install unimax_sampling[count]
```

## Programmatic Usage

```python
from unimax import unimax, count_characters

# (Optional) count characters in each dataset, only available when optional dependencies are installed via unimax_sampling[count]
character_counts = {}
for subset in ("swe_Latn", "fas_Arab", "ekk_Latn", "isl_Latn", "fao_Latn"):
    character_counts[subset.split("_")[0]] = count_characters("HuggingFaceFW/fineweb-2", subset)

# Compute UniMax distribution from available characters per language
character_counts = {
    "swe": 179955884499,
    "fas": 184595788282,
    "ekk": 42541080893,
    "isl": 10027573389,
    "fao": 549707867,
}

distribution = unimax(
    character_counts,
    character_budget=250_000_000_000,
    max_epochs=4,
)
```

**Output:**

```python
UniMaxDistribution(
    budgets={
        "fao": 2198831468,
        "isl": 40110293556,
        "ekk": 69230291658.66667,
        "swe": 69230291658.66666,
        "fas": 69230291658.66666,
    },
    epochs={
        "fao": 4.0,
        "isl": 4.0,
        "ekk": 1.627375003300828,
        "swe": 0.3847070177860806,
        "fas": 0.37503722215431134,
    },
    probabilities={
        "fao": 0.008795325872,
        "isl": 0.160441174224,
        "ekk": 0.2769211666346667,
        "swe": 0.27692116663466665,
        "fas": 0.27692116663466665,
    },
)
```

## Commandline Usage

For convenience, the package can be executed as a commandline utility

### Counting Characters

```bash
python -m unimax count-characters <dataset_path> <language_code> <output_json_file> [-c <dataset_configuration>] [-s <split>]
```

> [!NOTE]
> `count-characters` requires `unimax_sampling` to be installed via `pip install unimax_sampling[count]`

**Example:**

```bash
python -m unimax count-characters HuggingFaceFW/fineweb-2 fra french.json -c fra_Latn
```

### Calculating the UniMax Distribution

```bash
python -m unimax unimax <character_count_files> -c <character_budget> -m <max_epochs> [-r <language_codes>] [-o <distribution_json_file>]
```

**Example:**

```bash
python -m unimax unimax character_counts.json -c 250000000000 -m 4 -o distribution.json
```

## References

Hyung Won Chung, Xavier Garcia, Adam Roberts, Yi Tay, Orhan Firat, Sharan Narang, and Noah Constant. 2023. UniMax: Fairer and More Effective Language Sampling for Large-Scale Multilingual Pretraining. In The Eleventh International Conference on Learning Representations, ICLR 2023, Kigali, Rwanda.
pipecat-ai-bey 0.0.4
Generate real-time video avatars for your Pipecat AI agents with Beyond Presence
Requires Python: >=3.10
Keywords: webrtc, audio, video, ai

# Pipecat Beyond Presence Integration

Generate real-time video avatars for your Pipecat AI agents with [Beyond Presence](https://beyondpresence.ai).

**Maintainer:** Beyond Presence team ([@bey-dev](https://github.com/bey-dev))

## Installation

```bash
pip install pipecat-ai-bey
```

## Prerequisites

- [Beyond Presence API key](https://beyondpresence.ai)
- [Daily.co API key](https://www.daily.co/)
- API keys for STT/TTS/LLM services (e.g., OpenAI)

## Usage with Pipecat Pipeline

The `BeyTransport` integrates with the Beyond Presence platform to create conversational AI applications where a Beyond Presence avatar provides synchronized video and audio output while your bot handles the conversation logic.

```python
from pipecat_bey import BeyParams, BeyTransport

transport = BeyTransport(
    bot_name="Pipecat bot",
    session=session,
    bey_api_key=os.environ["BEY_API_KEY"],
    daily_api_key=os.environ["DAILY_API_KEY"],
    avatar_id="b9be11b8-89fb-4227-8f86-4a881393cbdb",  # Default "Ege" avatar
    room_url=os.environ["DAILY_ROOM_URL"],
    params=BeyParams(
        audio_in_enabled=True,
        audio_out_enabled=True,
        microphone_out_enabled=False,
        vad_analyzer=SileroVADAnalyzer(params=VADParams(stop_secs=0.2)),
    ),
)

pipeline = Pipeline([
    transport.input(),
    stt,
    context_aggregator.user(),
    llm,
    tts,
    transport.output(),
    context_aggregator.assistant(),
])
```

See [example.py](example.py) for a complete working example.

## Running the Example

1. Install dependencies:
   ```bash
   uv sync
   ```

2. Set up your environment

   ```bash
   cp env.example .env
   ```

3. Run:
   ```bash
   uv run python example.py
   ```

The bot will create a Daily room with a video avatar that responds to your voice.

## Compatibility

**Tested with Pipecat v0.0.89**

- Python 3.10+
- Daily transport (generic WebRTC support coming soon)

## License

BSD-2-Clause - see [LICENSE](LICENSE)

## Support

- Docs: https://docs.bey.dev
- Pipecat Discord: https://discord.gg/pipecat (`#community-integrations`)