siyak_flutter 0.1.0
siyak_flutter: ^0.1.0 copied to clipboard
Context-aware translation for Flutter: a cache-first t() that never blocks, with background batching and a persistent LRU cache.
Changelog #
0.1.0 #
First packaging of the SIYAK Flutter client.
Siyak.init(apiKey:, endpoint:, target:)— no host ships inside the SDK;endpointis required.t()is synchronous and cache-first: a miss renders the source string now and repaints when the batch lands (translationRevision).translate()awaits one string throughPOST /v1/translate;t()misses go out debounced and batched throughPOST /v1/translate/batch.preload()pulls the approved bundle fromGET /v1/strings?target=…at startup.- Persistent LRU cache via
CacheStore(SharedPreferencesCacheStore,InMemoryCacheStore); a string already hydrated from disk is never charged a second time. - Typed failures park the session instead of hammering a metered connection, and surface as a
machine-readable code on
lastError— translations never fail visibly. - Oversize strings are truncated to the Worker's 500-character cap rather than rejected; control
and bidi-override characters are stripped before sending, and
</>from contexts.