Skip to content

Releases

LastLight 0.3.1

Choose a tag to compare

@github-actions github-actions released this 23 Oct 12:44
b2f1ca3

LastLight 0.3.1 — Maintenance release

LastLight 0.3.1 is a conservative maintenance release. The installed library
retains the same offline retrieval and answer/refusal behavior as 0.3.0.
The public Python API and Python >=3.10 compatibility are unchanged.

Changes

  • Added a read-only v4 dataset readiness check to the source repository.
    It verifies the external benchmark's document and labeled-query counts,
    language and answerability breakdown, Git commit, and SHA-256 fingerprints.
    The check fails closed when the available data does not match the required v4
    dataset instead of silently substituting an older dataset.
  • Added source-tree tooling for a controlled comparison of separately installed
    LastLight 0.2.2 and 0.3.0 versions on identical data, using the external
    benchmark's metrics unchanged.
  • Added a separate deterministic audit for answerable queries whose expected
    document ranks first but the library refuses, recording the public decision
    evidence and refusal metadata.
  • Added offline regression tests and GitHub Actions support for the v4
    readiness/preflight tools.
  • Added an English-language 0.4.0 implementation and release-validation
    roadmap.
  • Updated README installation instructions and dynamic PyPI/GitHub release
    badges so users can discover the published package version.

The research tools are available in the GitHub source repository under
tools/. They are not runtime modules or CLI entry points in the PyPI
wheel
, and they do not change the benchmark repository.

Evaluation limitations

At the time of this release, the public lastlight-bench checkout has 32
documents and 160 labeled queries, whereas the requested corpus v4 contains
44 documents and 240 queries. Therefore the v4 baseline, controlled
comparison, and 0.4.0 engineering targets remain unverified
. Neither new
accuracy nor safety nor latency improvements are claimed for 0.3.1.

Safety disclaimer: LastLight only retrieves locally supplied text and applies
deterministic heuristic acceptance checks. It cannot establish private,
real-time, future, or privileged facts. Verify any operational instructions
with qualified authorities and authoritative local guidance.

Install

python -m pip install --upgrade lastlight==0.3.1

LastLight 0.3.0

Choose a tag to compare

@github-actions github-actions released this 23 Oct 11:12
33c44df

LastLight 0.3.0

This release separates raw ranking from a configurable, auditable acceptance
policy and adds deterministic, offline hybrid retrieval.

Highlights:

  • BM25/lexical RRF hybrid without direct numeric score fusion.
  • Configurable section/chunk bounds, preserved source paths and heading provenance.
  • Public per-backend calibration policy and explainable, bounded evidence scores.
  • Machine-readable refusal codes, with backward-compatible legacy reasons.
  • More candidate verification when adaptive accuracy has available resources.
  • English/Spanish normalization and stable offline search.

No additional runtime dependencies. Python >=3.10 remains supported.

Safety disclaimer: LastLight only retrieves local text and evaluates heuristic
signals. It cannot verify real-time, confidential, privileged or future facts.

The independent lastlight-bench project has not been modified. In the
pre-release external diagnostic, BM25 answerable recall improved relative
to 0.2.2, while false acceptance also increased, so this release does
not claim to meet the original refusal or precision objectives. Consumers
should inspect evidence and refusal codes and perform their own validation
for critical applications.

LastLight 0.2.2

Choose a tag to compare

@github-actions github-actions released this 23 Oct 09:56
a16c726

LastLight 0.2.2

LastLight 0.2.2 introduces an evidence-aware refusal and answer-calibration policy, independently of lastlight-bench. Search ranking remains unchanged; acceptance becomes a separate, auditable step.

Changes

  • Separates document relevance, passage evidence sufficiency, answer confidence, and the final accept/refuse decision.
  • Adds strategy-specific lexical and bm25 calibration with balanced and conservative profiles. BM25 scores and lexical scores are never numerically combined. Score margin alone or retrieval confidence HIGH never authorizes an answer.
  • Computes query coverage using original query terms, corpus document frequencies (IDF-like weights), negations, constraints, entities and discriminative terms. Matches in selected passages matter separately from document-level terms.
  • Requires type-compatible local passage evidence for quantities, time, identity, prohibitions and enumerations. Prefer substantive passages over Markdown headings and citation-only snippets.
  • Conservatively refuses unverifiable live/current/future states and private, credential, certification and clinical-authority questions.
  • In adaptive, retains resource-driven backend selection and optionally uses lexical top-1 identity agreement to flag uncertainty when BM25 is primary, without score fusion.
  • Exposes LastLight(knowledge, strategy="bm25", decision_profile="conservative"), detailed decision telemetry, and retrieval metadata separating the requested backend, selected backend, and decision profile.
  • Adds a fully synthetic, isolated internal calibration cohort and explicit threshold documentation in docs/decision_calibration.md.

Compatibility and limitations

search() continues to expose the same retrieval results and ranking score semantics. The default decision_profile="balanced" preserves the supported public API, but some formerly accepted results may now return refusals when evidence is insufficient. The policy is deterministic and standard-library-only, not probabilistic entailment or proof of factual correctness.

Calibration tests are not a substitute for untouched final evaluation. This release does not claim a measured improvement on lastlight-bench; validate false-acceptance rate, answerable recall and top-1 retrieval separately using independent held-out data.

Validation

The core GitHub Actions matrix exercises Python 3.10, 3.11 and 3.12, packaged wheel/sdist builds, and installed-library smoke checks, plus the isolated synthetic calibration tests. No modifications to lastlight-bench.

LastLight 0.2.1

Choose a tag to compare

@github-actions github-actions released this 21 Oct 11:47
e8268a2

LastLight 0.2.1

LastLight 0.2.1 is a maintenance release focusing on trustworthy offline
answer decisions and hardened local audit metadata. The retrieval algorithms,
knowledge pack format and built-in emergency guidance are unchanged.

Fixes

  • Consistent calibrated refusals in the CLI (#98): JSON, source summaries,
    JSONL batch output, field guides and --fail-on-refusal now use the same
    deterministic acceptance decision as the Python API and human-readable
    LastLight.answer(). A weakly covered, ambiguous medium-confidence match
    no longer slips through those older output pathways.
  • Reliable index integrity checks (#99): rejects malformed or incomplete
    index entries, invalid SHA-256 digests, duplicate paths, invalid version
    types and contradictory document counts before declaring an audit index valid.
  • Finite adaptive energy budgets (#100): CLI rejects NaN and infinite
    values at argument parsing rather than feeding them to the retrieval policy.

CI and publishing

  • Add a guarded release-PR workflow (#101) that builds, validates and uploads
    releases to PyPI using Trusted Publishing when an intentional
    [publish-pypi] commit reaches main.
  • Retain manual GitHub Release publication support, protected pypi
    environment and isolated wheel checks.
  • Keep the offline core evaluation and unit/integration checks on Python
    3.10, 3.11 and 3.12.

Compatibility

  • Python 3.10+; standard library runtime, without network or LLM dependencies.
  • No changes to Pack Format v1, public Python method signatures, or retrieval
    scoring. Answer acceptance may be more conservative for ambiguous queries
    in CLI outputs, to match the previously shipped calibrated decision policy.
  • This release does not independently verify scientific or emergency
    advice in third-party knowledge packs.

Install

python -m pip install --upgrade lastlight==0.2.1

LastLight v0.2.0

Choose a tag to compare

@github-actions github-actions released this 05 Oct 17:09
8979407

LastLight 0.2.0

LastLight 0.2.0 makes the answer boundary more explicit and auditable. Retrieval scores remain unchanged, but the runtime now uses additional deterministic evidence before deciding whether a retrieved passage should be returned as an answer.

Highlights

  • Adds a confidence/refusal v2 decision layer that combines the winning result's existing retrieval confidence with query-term coverage and the score margin to the runner-up from the same search.
  • Keeps clear HIGH matches at HIGH, while allowing near-tied strong candidates to be downgraded to MEDIUM instead of overstating certainty.
  • Refuses weakly covered MEDIUM matches when another acceptable candidate is nearly tied, reporting insufficient_confidence through the existing public refusal contract.
  • Adds public DecisionMetadata with the decision reason, winner score, runner-up score, margin, ratio, query coverage, query terms, and matched terms.
  • Adds LastLight.explain() and the public QueryExplanation contract for audit UIs, regression tests, and incident reproduction.
  • Includes the same decision metadata directly on QueryResult, so normal integrations can inspect why an answer was accepted or refused without making a second query.
  • Routes LastLight.answer() through the same calibrated decision boundary as query(), preventing human-readable and structured APIs from disagreeing.
  • Adds focused regressions for clear winners, ambiguous high-confidence matches, weak ambiguous medium-confidence matches, and no-match refusals.
  • Extends installed-wheel CI checks to cover the new public contracts and explain() behavior.

Decision semantics

The new layer does not mix lexical and BM25 numeric score scales. Margin and ratio are calculated only between results returned by one retrieval execution using one selected strategy.

The rules are intentionally conservative:

  1. no retrieved source remains no_matching_knowledge;
  2. a top result with retrieval confidence LOW remains a refusal;
  3. a clear HIGH result remains HIGH;
  4. two nearly tied HIGH results with limited query coverage may return the winner as MEDIUM;
  5. a MEDIUM winner with both poor query coverage and a nearly tied acceptable runner-up is refused as insufficient_confidence.

search() remains the raw retrieval boundary and preserves each strategy's existing score and confidence. The new calibration applies at the answer boundary used by query() and answer().

Explainability

from lastlight import LastLight

engine = LastLight("pack.zip", strategy="bm25")
explanation = engine.explain("How long will food stay cold during a power outage?")

print(explanation.decision.accepted)
print(explanation.decision.confidence)
print(explanation.decision.reason)
print(explanation.decision.query_coverage)
print(explanation.decision.score_margin)
print(explanation.decision.matched_terms)

The explanation is entirely local and deterministic. No telemetry, model call, persistent database, or network service is introduced.

Compatibility

Knowledge Pack Format v1 is unchanged. search(), query(), answer(), plan(), pack inspection, validation, and provenance APIs remain available. QueryResult gains an optional decision field at the end of the dataclass contract for source compatibility with existing keyword and positional construction patterns.

Python 3.10, 3.11, and 3.12 remain supported. The runtime remains dependency-free outside the Python standard library.

Upgrade

python -m pip install --upgrade lastlight

LastLight v0.1.5

Choose a tag to compare

@github-actions github-actions released this 27 Sep 23:21
ca82db9

LastLight 0.1.5

LastLight 0.1.5 is a runtime-hardening and retrieval-efficiency release focused on predictable public API failures, safer local packs, and better adaptive/BM25 behavior across real hardware.

Highlights

  • Rejects an explicitly empty pack collection instead of silently falling back to the built-in/default knowledge source.
  • Validates adaptive energy and memory budgets at the stable LastLight boundary and reports invalid values through ConfigurationError.
  • Validates provenance freshness windows at the public boundary instead of leaking internal ValueError behavior.
  • Stops treating every arm64/aarch64 host as low-resource solely because of CPU architecture, so Apple Silicon and server-class ARM64 machines can use BM25 when no real constraint is active. Termux, 32-bit ARM, survival mode, explicit budgets, and low battery continue to trigger the conservative path.
  • Applies the same Markdown document-count, per-document size, and aggregate-size limits to directory packs that already protect ZIP packs.
  • Rejects malformed runtime knowledge-source types through the public PackError hierarchy instead of exposing tuple()/pathlib TypeError exceptions.
  • Reuses query-independent BM25 corpus statistics across repeated queries against unchanged content, with deterministic invalidation when ranked content changes.
  • Removes superseded evaluation artifacts after the core regression corpus moved into the installed lastlight.evaluation package.

Compatibility

The runtime remains Python-standard-library-only and supports Python 3.10, 3.11, and 3.12. Pack Format v1 is unchanged. Existing LastLight.query(), search(), answer(), plan(), pack inspection, validation, and provenance contracts remain available.

The BM25 optimization does not introduce a persistent index or stale-pack policy: repositories may still reload local documents, while query-independent ranking preparation is reused only when the ordered corpus content is equivalent.

Upgrade

python -m pip install --upgrade lastlight

LastLight v0.1.4

Choose a tag to compare

@edujbarrios edujbarrios released this 25 Sep 10:45

LastLight 0.1.4 is a focused reliability and public-contract hardening release.

Highlights

  • Preserves mounted pack name, version, source, and path on search results when a single explicit knowledge pack is used.
  • Validates public top_k values consistently across search(), query(), answer(), and plan() instead of silently coercing invalid limits.
  • Fails fast with PackError when the public LastLight facade receives a missing, empty, or unsupported explicit knowledge source.
  • Prevents adaptive query-risk terms from matching inside unrelated words.
  • Rejects invalid chunking limits instead of allowing non-terminating chunk generation.
  • Handles valid JSON indexes with malformed top-level shapes without crashing.
  • Keeps directory pack manifests inside the pack root, including symlink escape protection, and applies the same manifest size limit used for ZIP packs.
  • Aligns directory and ZIP Markdown discovery for case-insensitive .md extensions and hidden metadata paths.
  • Clears stale session context when the user starts a new topic, so a refused standalone query cannot leak the previous topic into a later short follow-up.
  • Matches safety triage rules on token and phrase boundaries instead of raw substrings, avoiding false triggers such as gas inside Vegas.
  • Isolates adaptive retrieval decision metadata per execution context so concurrent users of one engine do not observe another request's plan.

The low-level repository and application-factory primitives remain available for internal tooling, while stricter validation is enforced at the stable public library boundary.

The runtime remains stdlib-only, the Pack Format v1 schema is unchanged, and no network connection is required once the Python package and knowledge packs are local.

Install / upgrade

python -m pip install --upgrade lastlight

LastLight v0.1.3

Choose a tag to compare

@github-actions github-actions released this 23 Sep 21:38
c89e478

Core-hardening release for the LastLight Python library.

Highlights:

  • packaged core evaluation suite with answerable and expected-refusal cases
  • CI regression gates for retrieval and refusal quality
  • LastLight Knowledge Pack Format v1 (format_version: 1)
  • canonical pack-relative document paths and stable directory/ZIP fingerprint inputs
  • safer ZIP loading with traversal, duplicate-member and size protections
  • malformed pack reads exposed through the public PackError hierarchy
  • no new runtime dependencies; the runtime remains Python stdlib-only

LastLight v0.1.2

Choose a tag to compare

@github-actions github-actions released this 23 Sep 13:51
5bdf411

Library-hardening release built from PRs #45 through #49.

Highlights:

  • stable public search-result contracts and explicit configuration errors
  • public knowledge-pack inspection, validation and provenance APIs
  • machine-readable refusal reasons and richer adaptive resource metadata
  • cleaner out-of-domain retrieval by pruning generic LOW-confidence matches
  • PEP 561 typed-package support with public Literal contracts
  • CI coverage across Python 3.10, 3.11 and 3.12
  • no runtime dependency additions

LastLight v0.1.1

Choose a tag to compare

@github-actions github-actions released this 23 Sep 13:07
476278b

Patch release focused on the library-first public experience.

Highlights:

  • clearer practical Python-library examples in the README
  • first demo now shows actionable severe-bleeding retrieval
  • retrieval comparison now uses a useful power-outage food-safety question
  • packaged-wheel CI verifies the documented lexical, BM25, adaptive and refusal behavior
  • no runtime dependency changes