• v1.0.4 70b0cf08ee

    Release v1.0.4
    test / pytest (push) Successful in 1m20s
    docker-image / build-and-push (push) Successful in 5m6s
    Stable

    tliu93 released this 2026-06-01 21:36:23 +02:00 | 1 commits to main since this release

    Highlights

    This release adds three major capabilities:

    • Alembic-based database migrations
    • LLM settings and an OpenAI-compatible client
    • Basic AI-powered search

    AI search is implemented as query expansion plus local LIKE search. It only sends the user’s search query to the LLM,
    not the inventory contents.

    New Features

    Database Migrations

    • Added Alembic as the official schema migration system.
    • Added an idempotent migration command:

    python -m app.migrate

    • Supports:

      • Creating schema for an empty database
      • Adopting an existing legacy three-table database as the V1 baseline
      • Upgrading managed databases to head
      • Failing closed when an unmanaged schema does not match the expected baseline
    • App startup now performs read-only schema verification and refuses to start if the database is not at the expected
      revision.

    LLM Settings

    • Added a /settings page.

    • Added support for:

      • LLM master toggle
      • Base URL
      • Model name
      • API key
      • AI search toggle
      • Optional extra AI-search domain hints
    • Added a connection test action.

    • API keys are not echoed back in the UI.

    • Leaving the API key field blank keeps the existing key.

    • Changing the Base URL requires entering a fresh API key.

    AI Search

    • Added an “AI Smart Search” action to the search page.

    • The action is visible only when LLM is configured and AI search is enabled.

    • AI search expands the user’s query through the LLM, then searches Box, Item, and SubItem name / note fields using
      the original query plus expanded terms.

    • Search results show the expanded terms when AI search is active.

    • LLM failures fall back to normal search and show a friendly error message.

    • Empty or invalid LLM output falls back to normal search without breaking the page.

    Upgrade Notes

    This release introduces Alembic. The database must be migrated before the app starts, otherwise startup will fail
    closed.

    Recommended deployment flow:

    Back up data/app.db first

    docker compose pull web
    docker compose run --rm web python -m app.migrate
    docker compose up -d

    For local development:

    python -m app.migrate
    python -m pytest tests/ -q

    Data and Security

    • Added the app_settings table for LLM configuration.
    • API keys are stored in plaintext in the database by design, but are not displayed in the UI.
    • AI search sends only the search query and prompt context to the configured LLM endpoint.
    • Inventory contents, notes, and images are not sent to the LLM by AI search.
    • OCR, image recognition, vector search, and semantic indexing are not included in this release.

    Tests

    The release adds and updates tests for migrations, settings, the LLM client, and AI search.

    Validation result:

    226 passed

    Known Limitations

    • AI search v1 is not vector or semantic search; it is LLM query expansion plus local fuzzy matching.
    • LLM output must satisfy the JSON string-array contract. Invalid output is treated as an empty expansion.
    • Docker startup does not automatically run migrations. Deployments must explicitly run python -m app.migrate.
    Downloads