Skip to content

Latest commit

 

History

History
83 lines (72 loc) · 5.17 KB

CHANGELOG.md

File metadata and controls

83 lines (72 loc) · 5.17 KB

Changelog

All notable changes to this project are documented in this file.

The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.

Nothing yet.

0.1.0 - 2026-09-02

Initial release, targeting tensic.ai server 1.6 and newer.

Added

  • Tensic / AsyncTensic clients with identical APIs: env-based configuration (TENSIC_URL, TENSIC_API_KEY), API-key or username/password (Tensic.login, TOTP aware) authentication, Tensic.ldap_login() / AsyncTensic.ldap_login() for instances with LDAP authentication enabled (POST /ldap, the same cookie session as login(), no TOTP step), timeouts, retries with back-off and Retry-After support, with_options(), bring-your-own httpx client, TENSIC_LOG=debug logging.
  • client.chat: send, stream (typed SSE events, resume via last_event_id, error frames raised as ChatStreamError), stop, upload_attachment, get_asset, conversation() helper with turn history, automatic Idempotency-Key on non-streaming turns.
  • client.knowledge: text/URL/file/bulk ingestion, semantic search, source listing, chunk inspection, deletion, reset, sync and re-embed jobs.
  • client.projects with sub-resources: prompts, secrets, routines, widgets, logs, conversations, analytics, evals, memory, comments, guards, custom tools, webhooks, integrations; plus iter() auto-paging and find(name).
  • client.teams, client.users (with api_keys), client.llms, client.embeddings, client.tools, client.statistics, client.templates, client.image, client.audio, client.settings, client.classifiers, client.image_generators, client.speech_to_text, client.invitations, client.examples, client.news, client.search(), client.whoami(), client.version(), and client.health(probe="ready"|"live") addressing either container probe route (GET /health/ready, GET /health/live).
  • client.direct: OpenAI-compatible chat completions (sync/async, streaming ChatCompletionStream), completions, embeddings, models, image generation, audio transcription/translation, moderations, plus client.openai_base_url for the official openai package.
  • WidgetClient / AsyncWidgetClient for widget-key access (config, chat, stream).
  • Typed exception hierarchy (tensicai.errors) parsing the tensic error envelope, legacy detail shapes and the OpenAI error shape, exposing request_id, retry_after and rate limit headers.
  • Lenient dataclass models under tensicai.types (unknown fields kept in .extra), Page / ProjectsPage pagination helpers, py.typed.
  • The request-side type aliases used by the SDK's own signatures are public, so typed wrapper code never reaches into a private module: FileInput, FileContent, AttachmentInput, Timeout, TimeoutOrNotGiven, NotGiven, NotGivenOr and Probe are exported from tensicai and tensicai.types, and the wire-value literal aliases (Splitter, IngestMethod, Privacy, TemplateVisibility) each live in exactly one domain type module.
  • image= is validated client-side: a str is a base64 payload or an http(s)/data: URL and is never read from disk, so a filename raises ValueError pointing at Path(...) before any request rather than sending the model a name it cannot see. bytes and a pathlib.Path are base64-encoded for you. client.image.generate(image=...) is stricter still — that endpoint decodes rather than fetches, so it takes base64, a data: URL, bytes or a Path, but not an http(s) URL.
  • Runnable examples under examples/, GitHub Actions CI (Python 3.10–3.14) and a PyPI Trusted Publishing release workflow.

Packaging

  • Two declared runtime dependencies: httpx>=0.25,<1 and anyio>=3.5. anyio is imported directly by the async client (retry back-off sleeps, threaded file reads for Path/file-object uploads) and is declared in its own right rather than relied on transitively through httpx/httpcore.
  • PyPI metadata: authors names team.blue (pedro.dias@team.blue) with the individual under maintainers; the license is the PEP 639 expression Apache-2.0 with no deprecated License :: classifier; Programming Language :: Python :: 3 :: Only is declared. The project URLs are Documentation (the README), Repository, Issues, Architecture (docs/INTERNALS.md, the contributor guide) and Changelog — every link points at a host we control, never at the parked tensic.cloud domain.
  • The sdist ships .github/ and Makefile alongside tests/, so the test suite it carries passes from an extracted sdist and the make targets CONTRIBUTING.md documents run there.
  • CI and the release workflow install with uv sync --locked, so a uv.lock that no longer matches pyproject.toml fails the run instead of being silently re-resolved.
  • publish.yml runs ruff, mypy and the full test suite before building, so a tag push cannot upload to PyPI ahead of (or despite) a red CI run.