Catalog PyPI
Back to packageRELEASE DETAILS

0.1.0

PyPI

acty-gigachat

GigaChat executor for acty

gigachatlangchainsessionstelemetryworkflow
Published5 Apr 2026
Direct dependencies11
Transitive dependenciesNot calculated

README

Version 0.1.0 documentation

acty-gigachat

acty-gigachat provides a GigaChatExecutor implementation for Acty. It adapts langchain-gigachat chat models to the Acty executor interface and adds session-aware behavior for GigaChat prefix-caching workflows.

Install

pip install acty-gigachat

For local development:

pip install -e .[dev]

Usage

import asyncio

from acty import ActyEngine, EngineConfig
from acty_gigachat import GigaChatExecutor
from langchain_gigachat.chat_models import GigaChat


async def main() -> None:
    model = GigaChat(credentials="YOUR_AUTHORIZATION_KEY", verify_ssl_certs=False)
    engine = ActyEngine(
        executor=GigaChatExecutor(model=model),
        config=EngineConfig(primer_workers=1, follower_workers=1),
    )
    try:
        submission = await engine.submit_group(
            "demo",
            {"input": "Hello!", "invoke_kwargs": {"temperature": 0.2}},
            [],
        )
        if submission.primer is not None:
            result = await submission.primer
            print(result.output)
    finally:
        await engine.close()


asyncio.run(main())

Payloads may provide messages, input, or prompt. The executor forwards an optional invoke_kwargs dictionary to the model.

Session Handling

GigaChatExecutor uses the GigaChat SDK session_id_cvar context variable to control the X-Session-ID header during model calls.

  • if Job.context["cache"]["provider_ref"] is present, the executor reuses it
  • otherwise, it creates a per-group fallback session id
  • session-invalid failures rotate to a new session id
  • transient failures reuse the current session id

This makes the executor suitable for Acty cache flows where a primer attaches a provider reference and followers reuse it later.

Telemetry

The executor can enrich the active OpenTelemetry/OpenInference LLM span with:

  • Acty correlation identifiers
  • bounded input message attributes
  • cached prompt token usage when the model response exposes it

This is enabled by default and respects the configured telemetry privacy gates.

Development

  • tests live under tests/
  • the repo includes unit tests, session lifecycle tests, and Acty engine integration coverage for telemetry, retry, and TTL/session rotation behavior
  • the package depends directly on both acty and acty-core because it imports symbols from both at runtime

Downloads & popularity

Awaiting observations

No metric observations yet

Download counts and popularity will appear here as the collector receives them.

Declared dependencies 12

Native requirements
11 direct targetsNot calculated transitive count
Package / targetRequirementRelationship
acty-core
Environment
{
  "extras": "",
  "marker": null,
  "requires_python": ">=3.12",
  "evaluation": "NOT_EVALUATED"
}
acty-core<0.2.0,>=0.1.0runtime
acty
Environment
{
  "extras": "",
  "marker": null,
  "requires_python": ">=3.12",
  "evaluation": "NOT_EVALUATED"
}
acty<0.2.0,>=0.1.0runtime
langchain-gigachat
Environment
{
  "extras": "",
  "marker": null,
  "requires_python": ">=3.12",
  "evaluation": "NOT_EVALUATED"
}
langchain-gigachat>=0.3.12runtime
acty
Environment
{
  "extras": "",
  "marker": "extra == \"dev\"",
  "requires_python": ">=3.12",
  "evaluation": "NOT_EVALUATED"
}
acty<0.2.0,>=0.1.0; extra == "dev"runtime
build
Environment
{
  "extras": "",
  "marker": "extra == \"dev\"",
  "requires_python": ">=3.12",
  "evaluation": "NOT_EVALUATED"
}
build>=1.2.2; extra == "dev"runtime
gigachat
Environment
{
  "extras": "",
  "marker": "extra == \"dev\"",
  "requires_python": ">=3.12",
  "evaluation": "NOT_EVALUATED"
}
gigachat>=0.1.43; extra == "dev"runtime
httpcore
Environment
{
  "extras": "",
  "marker": "extra == \"dev\"",
  "requires_python": ">=3.12",
  "evaluation": "NOT_EVALUATED"
}
httpcore>=1.0.9; extra == "dev"runtime
httpx
Environment
{
  "extras": "",
  "marker": "extra == \"dev\"",
  "requires_python": ">=3.12",
  "evaluation": "NOT_EVALUATED"
}
httpx>=0.28.1; extra == "dev"runtime
opentelemetry-sdk
Environment
{
  "extras": "",
  "marker": "extra == \"dev\"",
  "requires_python": ">=3.12",
  "evaluation": "NOT_EVALUATED"
}
opentelemetry-sdk>=1.39.0; extra == "dev"runtime
pytest-asyncio
Environment
{
  "extras": "",
  "marker": "extra == \"dev\"",
  "requires_python": ">=3.12",
  "evaluation": "NOT_EVALUATED"
}
pytest-asyncio>=1.3.0; extra == "dev"runtime
pytest
Environment
{
  "extras": "",
  "marker": "extra == \"dev\"",
  "requires_python": ">=3.12",
  "evaluation": "NOT_EVALUATED"
}
pytest>=9.0.0; extra == "dev"runtime
twine
Environment
{
  "extras": "",
  "marker": "extra == \"dev\"",
  "requires_python": ">=3.12",
  "evaluation": "NOT_EVALUATED"
}
twine>=5.1.1; extra == "dev"runtime

Distribution files

2 collected
acty_gigachat-0.1.0-py3-none-any.whl

bdist_wheel · 9.57 KB · Python py3

Source file
acty_gigachat-0.1.0.tar.gz

sdist · 15.84 KB · Python source

Source file

Repository

PENDING
conspol/acty-gigachat

Shared repository data · GitHub

License detected in repository
Not collected

Metadata history

Meaningful changes
Current collected state Current

Observed since 20 Oct, 18:43 UTC

No superseded metadata states collected. Unchanged observations do not create new revisions.

Record identity

package_version:691eb804426c9ffa8948e571a022f2cd3dddd445cdfb95167eb8866c4dd93aba

Other collected versions

View all collected versions →