Skip to content

PiSharp 1.6.0.1

Latest

Choose a tag to compare

@github-actions github-actions released this 23 Nov 15:22
· 1 commit to main since this release
1a74a20

PiSharp 1.6.0.1

PiSharp 1.6.0.1 is a C#-only patch release on the unchanged Pi v1.6.0 and Pi Durable 1.6.0 baseline (faac585884ae2c013a6b1400f3e9e77f10b34bac). It expands the package set from 29 to 31 NuGet packages (29 libraries, the PiSharp.Cli global tool, and PiSharp.Templates), graduates seven Tier-1 [Experimental] API surfaces to stable, wires Pi Durable 1.6.0 signals and image fitting end-to-end across the hosts and custom workflows, adds JsonlStorage byte-offset indexing and ChordStore SQLite group commit, resolves the four-transport retry gap, and trims the PiSharp.Cli package size.

Package publication is recorded separately in compatibility/public-release.json; these notes do not claim complete upstream, live-provider, or all-platform parity.

Source and scope

  • Upstream baseline (unchanged): Pi v1.6.0, commit faac585884ae2c013a6b1400f3e9e77f10b34bac (compatibility/target.lock.json).
  • Preserved history: All historical source locks, inventories, applicability tables, acceptance records, model catalogs, and previousReleases entries (including published 1.6.0, 1.5.2, 1.5.0.1, and 1.5.0) remain unchanged.
  • Included pull requests since v1.6.0: #68, #69, #70, #71, #72, and #73.

Changes

New packages, telemetry, and Tier-1 graduation (#73)

  • PiSharp.Extensions.AI (new library package): bridges PiSharp transports and media embeddings with Microsoft.Extensions.AI (Microsoft.Extensions.AI.Abstractions >= 10.11.1):
    • PiChatClient : IChatClient adapts any PiSharp IChatTransport + ModelDescriptor with streaming text/reasoning/tool deltas, Gemini thoughtSignature / textSignature / redacted thinking preservation, originating model identity retention across mid-conversation ChatOptions.ModelId switches, inclusive UsageDetails.InputTokenCount mapping, service tiers, and Anthropic threads.
    • PiEmbeddingGenerator : IEmbeddingGenerator<string, Embedding<float>> adapts PiSharp.AI.Media embedding models.
    • ChatClientTransportAdapter : IChatTransport lets PiSharp.Agent and PiSharp.Durable consume any external Microsoft.Extensions.AI.IChatClient (e.g., Ollama, Azure AI Inference, custom proxies), retaining open text/thinking buffers on error or cancellation terminals and surfacing malformed tool arguments as protocol/stream errors.
    • DI registration extensions AddPiSharpChatClient and AddPiSharpEmbeddingGenerator.
  • PiSharp.Templates (new dotnet new template package): ships three CI-tested starter templates (pisharp-agent, pisharp-extension, pisharp-workflow) targeting net10.0.
  • DiagnosticsTelemetry (PiSharp.Telemetry): zero-dependency opt-in ITelemetry adapter mapping PiSharp spans, events, initial and late links, W3C traceparent/tracestate propagation (explicitly enforcing ActivityIdFormat.W3C), and counters/histograms directly to System.Diagnostics.ActivitySource and System.Diagnostics.Metrics.Meter. Covered by all 11 conformance groups in PiSharp.Telemetry.Tests.
  • Tier-1 [Experimental] graduation (Decision 0017): removes [Experimental] attributes from seven stable core diagnostic IDs:
    • PISHARP_SCHEMA001 (PiSharp.Contracts.Schema)
    • PISHARP_IDENTITY001 (ClientIdentity, ClientUserAgent, ClientAttribution, ClientIdentities)
    • PISHARP_TIERS001 (ServiceTiers, ServiceTier)
    • PISHARP_AI001 (StreamingJsonParser and tool-call argument streaming helpers)
    • PISHARP_AUTH001 (AuthEvent device-code confirmation hints)
    • PISHARP_EXEC001 (pi.exec buffer capture limits)
    • PISHARP_TOOLSEARCH001 (ToolSearchDocument.NamespaceText)
    • Tier-2 experimental packages (PISHARP_DURABLE001, PISHARP_AGENTS001, PISHARP_TELEMETRY001, PISHARP_CHORD001, PISHARP_ENV001, PISHARP_MEDIA001, PISHARP_TUI001) plus PISHARP_EXTUI001, PISHARP_CODEMODE001, and PISHARP_CATALOG001 remain experimental.

Durable 1.6.0 end-to-end wiring and storage performance (#72)

  • Signal delivery and host wiring: exposes POST /sessions/{id}/tasks/{taskId}/signal across PiSharp.Durable.Hosting, PiSharp.Durable.Server, PiSharp.Durable.Client, and PiSharp.Durable.Web, wires SubmissionDraft.Notify and InputOnAbort.Keep, adds opt-in FitImages support to the device host and Web Agent, and renders details.imageUnsupportedByModel and AgentModel.YieldAnswer across Durable TUI, Web Hub, and Web Agent.
  • PiSharp.CustomAgents workflow signals: workflows can pause durably on typed signals (WaitForSignal) and resume immediately on SendSignalAsync instead of polling on timers.
  • JsonlStorage byte-offset index and bounded LRU cache: avoids full-file rescans on repeated session reads while enforcing bounded cache reclamation and propagating caller cancellation cleanly on lazy reads.
  • ChordStore SQLite group commit: coalesces concurrent queued SQLite commits behind an active write into a single backend transaction.

Runtime and parity fixes (#71)

  • Four-transport retry classification (Decision 0016): retries transient connection failures (SocketException, HttpRequestException, HttpIOException, premature stream EOF, timeouts) on OpenAI Completions, Anthropic Messages, Google Generative AI / Vertex, and Mistral Conversations via a non-serialized [JsonIgnore] IsRetryableTransportFailure signal while preserving the exact sanitized user-facing errorMessage strings byte for byte.
  • Native PowerShell tool (PiSharp.Tools): adds an opt-in native PowerShell execution tool with safe Base64 script-block encoding and separate normalized argument budgeting.
  • FindTool anchoring parity: brings the explicit-policy FindTool / FdFindExecutor path-pattern anchoring and filtered exit-code handling into alignment with PiFindTool from Pi 1.6.0.
  • Native C# extension overrides and /reload diagnostics: omitReplacedExtensions now honors native C# extensions alongside Node extensions, and /reload surfaces re-resolution diagnostics consistently.

Packaging diet, distribution manifests, and verification (#69)

  • CLI tool packaging diet: strips native .pdb debug symbols and non-target RID native assets from PiSharp.Cli, enforced by an 80 MiB archive budget check in release.yml.
  • Standalone archives and package-manager manifests: adds tools/release/build-standalone-archives.ps1 and tools/release/generate-package-manifests.mjs to produce self-contained win-x64, linux-x64, and osx-arm64 archives plus Homebrew, Scoop, and Winget manifests (exercised via release.yml dry-run include_standalone=true).
  • Automated post-publish verification: adds tools/release/verify-published-release.ps1 and .github/workflows/verify-release.yml to verify all 31 published NuGet packages against GitHub Release assets and run a fresh external consumer check.

CI hygiene, codebase health, and contributor ergonomics (#68, #70)

  • Centralized third-party NuGet pins and security audit: consolidates third-party package versions into Directory.Build.props, adds the weekly security-audit.yml workflow, and keeps packages.lock.json byte-stable.
  • Website DX: adds build-time {{PISHARP_VERSION}} substitution (satteri-pisharp-version.mjs), /llms.txt, and expanded architecture, embedding, and telemetry documentation.
  • Codebase health and test reporting: extracts TUI ICU word-break tables into structured data, decomposes oversized source files, wires 20 previously unregistered exec.* tests into CI, adds TRX test summaries, and provides tools/bootstrap-sdk.ps1 / tools/bootstrap-sdk.sh for pinned .NET 10.0.401 local setup.

Compatibility and migration notes

  • No breaking changes to stable public APIs.
  • Tier-1 graduation is source-compatible: removing [Experimental] from the seven Tier-1 IDs eliminates compiler warnings for new consumers; existing <NoWarn> entries naming those IDs in downstream .csproj files continue to compile cleanly without warnings.
  • Exact sibling pinning: all 29 library packages pin sibling PiSharp.* dependencies at [1.6.0.1]. Update all referenced PiSharp.* packages together.
  • PiSharp.Extensions.AI dependency ranges: Microsoft.Extensions.AI.Abstractions (>= 10.11.1) and Microsoft.Extensions.DependencyInjection.Abstractions (>= 10.0.0) use inclusive minimums so consuming applications can install Microsoft.Extensions.AI middleware side-by-side without downgrade conflicts.

Validation status and limitations

  • Release-candidate qualification covers hosted PR CI across Linux, Windows, and macOS plus a manual release.yml dry run (version=1.6.0.1, include_standalone=true) exercising all four reusable validation gates (core, durable, gap-regressions, env-native), all 23 offline release suites, 31-package packing and admission validation, PiSharp.Templates smoke tests, CLI durable payload and 80 MiB budget checks, and standalone archive/manifest generation.
  • Known boundaries remain unchanged from 1.6.0: live provider accounts, real SSH hosts, physical macOS key input, and Windows PTY creation (ENOTSUP) are not qualified by offline CI. Tagging v1.6.0.1 and publishing to NuGet require explicit owner approval per Decision 0006.