How I redesigned PersonLens around people, images and workflows without rewriting its recognition engine
Four months ago, I published Managing Persons in Photo Collections. The New Desktop App Is Ready.
The project began in autumn 2025 with relatively simple educational experiments in face recognition, using folders of reference images. In a little over a year, those experiments evolved into a desktop system for managing a knowledge base of known people, maintaining face and body encoding banks, reviewing recognition results interactively and curating reference images. Alongside the knowledge base, a JSON Schema-driven database developed to store identity information and other useful metadata about those same people.
This growing functionality, supported by worker threads and isolated processes, required a robust architecture. An earlier overhaul brought the knowledge base and Persons DB under the coordination of a central Person-Service, laying the foundation for the current application.
Functionally and technically, the application had grown up. Its user interface, however, was beginning to show its history. Each new capability had brought another dialog: adding or renaming people, editing reference images, rebuilding encodings or maintaining database records. Each tool did its job, but working with a single person often meant moving between windows and sometimes looking up the same person in another list.
The interface still reflected the order in which I had developed the functionality rather than the way I actually used it. It was time to rethink the GUI.
The goal was not simply a darker or more modern theme. I wanted to select a person, inspect their images and available evidence, make a change and move on without losing context. After a series of small, tested releases, the result is the new Persons Workbench. Now completed and user-accepted after still more intensive testing.
This article describes the design decisions, interaction changes and engineering challenges involved in modernizing a mature PyQt6 application while preserving its underlying behaviour. It is also, for now, the final instalment in a series of fourteen articles. The accompanying overview, traces that journey from the beginning.

Figure 1. From separate management dialogs to the integrated Persons Workbench, with the KB Gallery active.
Note: In this article, real people’s faces and names in illustrations have been intentionally obscured to protect privacy
The problem wasn’t a missing feature
PersonLens already had a broad collection of tools. It could compare faces and body characteristics, present likely recognition candidates, collect human review decisions, manage reference images, assess knowledge-base health and detect duplicate images. The structured Persons DB used a JSON Schema to define person attributes and generate their editing interface.
I also noticed a more fundamental mismatch. The database had become visually prominent, while the purpose of PersonLens is to manage people in photo collections. The database supplies valuable metadata, but the workflow starts with the person’s images.
In my intended way of working, each recognition profile has a corresponding database record. The normal Add Person workflow creates the knowledge-base content and encodings, then offers to open a prefilled metadata editor if a corresponding record does not yet exist. Saving that record completes the association. A separate consistency-check and repair facility helps identify mismatches between the database, knowledge base and related folders.
That observation became the central design decision. Organize the interface around the selected person and their images, not around the internal subsystem responsible for the current operation.
A person-centred Workbench
The new Workbench has two main areas. On the left is a searchable, sortable roster of people, with portraits, names and configurable metadata columns. On the right is the selected person’s workspace, organized into four tabs: Profile, KB Gallery, KB Assessment and Overview.
The selected person provides the shared context for these views. The roster combines recognition profiles with structured database information and supports horizontal scrolling and column rearrangement. When no person is selected, the detail area presents a neutral state rather than implicitly selecting another profile.
For tasks requiring more room, Focus Details hides the roster and expands the workspace. Previous and Next allow navigation through the current filtered and sorted list without returning to the roster. Show Roster restores the split view.
A common toolbar provides Add Person, Rename, Remove, Edit Images and Re-encode. These are now integrated workflows rather than separate everyday destinations. The Open Folders menu also provides direct access to the selected person’s knowledge-base folder and associated photo-collection folder. That may sound like a minor addition, but when managing local media, quick access to the actual files matters.
Profile: the database in its supporting role
The Profile tab exposes structured attributes from the Persons DB through a schema-aware form. Existing records can be edited without leaving the Workbench, while validation, conflict detection and unsaved-edit protection remain in place.

Figure 2. Profile tab selected with the DB Roster visible.

Figure 3. Profile tab selected in Focus Detail mode.
The Advanced DB Editor remains available for more extensive database administration. Integrating normal profile editing into the Workbench does not mean every advanced database operation needs to become part of the everyday interface.
The standalone Browse Persons DB has also received a visual makeover. Its portrait and name a frozen identity area while metadata columns scroll horizontally. Compact column widths and filter controls make better use of the available space without sacrificing the browser’s dedicated sorting, filtering and folder-navigation capabilities.
KB Gallery: images first
The KB Gallery is perhaps the clearest expression of the redesign. It displays the selected person’s knowledge-base reference images as thumbnails, with larger previews of the original image and an isolated face crop. The crop is a temporary inspection result, not a new reference image written back to the knowledge base.
Selecting an image can initiate preview decoding and face analysis. Resizing the window, by contrast, scales already-loaded preview data. It does not initiate another analysis or discard the selected image or pending management edits. A reference image can also be designated as the preferred source for the person’s portrait, with the option to return to automatic portrait selection.
The layout went through several iterations. Initially, the gallery worked correctly, but its previews were too constrained and left a surprising amount of unused space on larger displays. We adjusted the sizing policies and preview limits, then tested the results at different window sizes. It was a useful reminder that a GUI can be functionally correct and still not feel quite right.

Figure 4 KB Gallery with the roster visible, showing an original reference image and its face-crop preview.

Figure 5. Knowledge Base Assessment with Focus Details enabled.
KB Assessment: one guided workflow, multiple tools
Reference quality is more complicated than selecting attractive or sharp photographs. Useful references need adequate quality and variation and must be relevant to the intended person. Sharpness and similarity scores can help prioritize review, but technical quality is not proof of identity.
The KB Assessment tab connects the existing analysis and curation tools into a six-stage workflow: Gallery, Collection, Identity, Shortlist, Curation and Encoding.
Collection and identity-consistency assessments provide evidence for reviewing the reference set. The shortlist helps identify suitable encoding candidates, while curation supports explicit human decisions. Controlled reference encoding has a separate review and confirmation step before a selected set of references is used to rebuild encodings.
Simply displaying the workflow does not launch every analysis. Assessment operations require explicit action, and their results are treated as evidence for human review rather than definitive verdicts.
One of the final visual refinements placed the recommended next assessment action above the broader stage map. This gave the immediate task greater prominence without hiding any of the individual tools.

Figure 6. Knowledge Base Assessment, showing the guided workflow and reference-image findings.
Overview: what do I know, and what should I do next?
The Overview tab brings together available information for the selected person: profile summary, data source, reference-image count, face and body embedding counts, provenance and recognition readiness. It also displays recent Workbench activity from the current session.
In the final layout, the recommended next action appears before the supporting technical information. When opening a person’s workspace, I want to know whether something needs attention before reading an inventory of the available data.
The Overview is a read-only composition of existing information. It is not another hidden trigger for recognition or assessment.
Replacing a dialog is more than a presentation update
At first glance, integrating management actions into the Workbench seems straightforward. A toolbar button opens an inline panel, the panel calls a service and the roster updates. But the original dialogs also provided boundaries around individual operations. Moving those operations into a persistent workspace introduces new opportunities for unintended state changes.
Consider Editing Images. A user selects reference images, stages additions and removals, and opens a confirmation dialog. During that time, another program might modify or remove a source file. Applying the original plan blindly could mean acting on outdated information.
To address this, the Workbench captures the proposed inputs, checks source revisions and revalidates the operation before execution. For image updates, the worker repeats relevant checks under the service operation lock. These checks are designed to reject stale inputs, not to prevent every possible external filesystem change.
Rename Person is similarly more involved than changing a label. It must coordinate the person’s knowledge-base folder, encoding labels and database record, and optionally rename the external photo-collection folder. Remove Person requires explicit confirmation, preserves external photos by default and uses transactional staging to support rollback when an operation fails. Re-encoding must not silently substitute a different set of references for those the user confirmed.
The principle behind these workflows is that the new GUI should reuse proven service behaviour rather than recreate it in widget callbacks. The Workbench must act as an enhanced controller of the existing operations. It preserves selection context, gathers user intent, asks for confirmation, and displays progress and results. Services and workers remain responsible for the actual operations.
Native dependencies also deserve special consideration. A failure in a face-processing library should not unnecessarily bring down the Qt event loop. PersonLens isolates sensitive preview and portrait operations in child processes where appropriate, while background workers handle other computational tasks. Preserving these boundaries was a requirement of the redesign.
The Gallery offers a small example of the separation between computational work and presentation. Its resize logic scales cached source pixmaps rather than decoding the file again or requesting another face analysis:
def _scale_previews(self):
if self._stopping: return
for label, source in ((self.preview, self._original_image), (self.crop_preview, self._crop_image)):
if source.isNull(): continue
size = label.contentsRect().size()
if size.width() > 0 and size.height() > 0:
label.setPixmap(source.scaled(size, Qt.AspectRatioMode.KeepAspectRatio,
Qt.TransformationMode.SmoothTransformation))PythonListing 1. The PersonKBImageGallery.Scale_previews method illustrates the boundary between cached preview presentation and background image processing
Incremental refactoring instead of a big rewrite
The modernization was carried out through a continuous sequence of small releases. We consolidated navigation and person context, improved the roster and detail layout, integrated the Gallery, assessments and Overview, and brought selected-person management and folder navigation into the Workbench. The standalone database browser received its own visual modernization, and specialist tools were organized under Administrator.
Each change was kept as narrow as practical. Structural and unit tests checked technical contracts, while native Windows acceptance tests assessed real Qt behaviour, worker interactions and visual proportions. Some issues only became apparent when resizing the application or switching between split and focused views.
The tests were fast enough to run regularly, but automated success is not considered equivalent to human visual acceptance. Conversely, a successful manual scenario does not prove that every failure, cancellation or rollback condition has been individually witnessed. We maintained set of separate evidence and retirement audits to take that into account.
AI-assisted coding played a role throughout the process. It helped inspect existing code, propose targeted patches, develop contract tests and keep changes bounded. But a mature application cannot be reliably modernized through code generation alone. The valuable cycle was to inspect, patch, test, observe and correct. I performed the native acceptance checks and made the decisions about which behaviour and visual proportions were acceptable.
There were mistakes and false starts, especially around layouts and assumptions about legacy behaviour. Working in small increments made those mistakes easier to recover from and helped maintain a known-good, committed baseline.
Why old interfaces are still there
If the Workbench replaces everyday management dialogs, why not delete those dialogs immediately?
Functional acceptance and formal retirement are different decisions. The five principal Workbench management operations have been exercised and accepted in native Windows scenarios. However, the project’s formal retirement audits still require individually recorded evidence for specific conditions, including cancellation, freshness, concurrency, failures and rollback.
For now, the original dialogs remain accessible through Administrator. They are no longer the preferred everyday route, but retaining them avoids unnecessary risk while the formal evidence remains incomplete.
Some tools should remain independent regardless of retirement certification. The Advanced DB Editor serves broader database administration. Browse Persons DB supports dedicated metadata exploration. Rebuilding the encoding bank for the entire knowledge base is a specialized maintenance operation, distinct from re-encoding a selected person.
The goal was a coherent primary interface, not the elimination of every specialist tool.
What changed and what didn’t
I can now select a person, review their reference images, inspect or edit metadata, assess the knowledge base, manage images and initiate re-encoding without repeatedly switching between unrelated dialogs. The layout responds better to available screen space, and the same visual identity follows the person across the Workbench and the modernized database browser.
Behind the presentation changes, the recognition concepts remain familiar: a local knowledge base, face and body evidence, human review of uncertain results and explicit curation before changing reference material. The database is still schema-driven. The makeover did not redesign the underlying knowledge-base or encoding-bank formats.
PersonLens remains a local-first desktop application intended for controlled photo collections. It is not designed as a surveillance platform. Recognition similarities and image-quality scores do not establish identity; human judgement remains central to the workflow.
Lessons learned
Looking back, the most valuable change was conceptual. Once the person and their images became the organizing principle, many layout decisions followed naturally. The roster became navigation, the Gallery became inspection, the Profile became supporting metadata and the assessment tools became a guided route to improving the reference set.
Three architectural rules proved particularly valuable:
- Design around the user’s object of work. Internal modules and database tables are not necessarily the right units for navigation.
- Preserve service boundaries when replacing UI. A new screen should not bypass safeguards that took years to accumulate.
- Make analysis explicit and state visible. Users should know when an operation is pending, when evidence is stale and when they are about to commit a change.
As mentioned above this old rule of thumb ‘ think big, works small’ still applies: Modernize incrementally and test the native application. A layout that looks correct in code may still feel wrong at a real window size.
The Person Workbench is now the principal GUI in PersonLens and the modernization phase is functionally complete. Future work on recognition quality, knowledge-base management and performance can build on a much clearer interface.
Using the new Application
The updated version is intended for distribution as a ZIP archive containing the Python source package, configuration and schema templates, dependency information and setup instructions. The internal hdw_person_lens package structure is retained; there is no need to flatten the source tree or rewrite its imports.
A Windows executable could also support external, editable schema and configuration files, but producing and testing such a distribution is a separate deployment task. For now, distributing the source keeps customization transparent and makes it easier for readers to adapt the application to their own collections.
The underlying knowledge-base and database workflows remain familiar. The earlier article, Managing Persons in Photo Collections — The New Desktop App Is Ready, provides the background for setting up a knowledge base and customizing a database schema. For the new release, follow the accompanying README for the current Python environment, dependencies and package-aware launch instructions.
A final thought
The original project asked whether we could recognize familiar people in a photo collection. The next stage asked how to manage the knowledge base reliably. This makeover addresses a third question: how do we make all that capability understandable and practical to use every day?
That, more than a new collection of widgets, is what the Persons Workbench has achieved.