# FastLine

## Introduction

The **GBS FastLine** is a software application for authentication in waiting lines. It uses facial recognition quickly and accurately to identify people more efficiently than the document-checking process performed by a human operator. Using FastLine, it is possible to recognize, identify, and register individuals in a queue automatically.

This manual is updated for FastLine version 1.5.1.

### Application Versions

GBS FastLine is available in two versions:

#### Desktop Standalone

This version is for full use in a desktop environment, without the need for external tools or requirements.

{% hint style="warning" %}
GBS FastLine was designed as a service, and its desktop version is recommended for testing, validation, and proof-of-concept procedures, or for trivial use cases.
{% endhint %}

{% hint style="info" %}
In this document, this version will be referred to only as **Desktop**.
{% endhint %}

#### Services

In this version, GBS FastLine is provided as a service and must be controlled by an external application through its API. This version also provides means for external supervision.

### Software License

GBS FastLine requires a software license to operate. The license is not tied to any hardware address (such as a MAC Address) and does not expire. The license must be installed in: `C:\ProgramData\Griaule`, according to the instructions in the license manual.

{% hint style="info" %}
If more assistance is needed, contact Griaule support.
{% endhint %}

### FastLine Installation and Initial Configuration

The FastLine installer has a configuration tab, *GBDS Settings*:

![GBS Fast Line Installer](/files/56a0616b9a38cbfead2b1fdaefc546ba927093ef)

#### GBDS Settings

**GBDS URL Address**

GBDS server address URL. Example: `http://192.168.0.1:8085`.

**Username and Password**

Credentials used by FastLine for authentication in GBDS.

## User Interface

### Starting the Application

When starting FastLine, the *Initial Screen* will be displayed:

![GBS Fast Line Main Page](/files/38dfa375c3e8574ed21f9fa029814c0e01eeab2a)

### Adding Profiles to the Database

This section shows how to populate the local database.

#### Retrieving from GBDS

The form *Load base from GBDS*, shown below, can be used to retrieve profiles from GBDS. Profiles can be filtered by biographical keys. If the filter is left empty, all available profiles will be imported.

![GBDS filter](/files/27e210bdec3edf74a3fff041ccc7f9dbcb442ab0)

#### Local Registration

The button **Capture Photo** allows the user to register a new person in the local database. When this option is selected, the image capture window will open:

![GBS FastLine Capture Image Screen](/files/df230fddfa3b861fa7f50ba1f5431993a7dd9839)

The version *Desktop* allows registration by capturing live images, or by importing already saved image files.

The version *Services* allows registration by importing image files, but not by live capture. This version is focused on external uses, for which a database already populated with profiles is expected.

### Viewing Profiles

The profile list is displayed in the sidebar, and shows all profiles available for detection. The number of profiles is shown at the top of the list.

![Local database](/files/07b9a3ecb121944996081b7c6988a27e98384fea)

The size of the displayed list can be changed in the application settings. Hovering the mouse cursor over a profile shows its photo. Profiles can be selected or deselected by clicking them.

### Deleting Profiles

To delete one or more profiles, select them by clicking in the profile list and press the button **Delete**.

{% hint style="warning" %}
Once a profile is deleted, it cannot be recovered.
{% endhint %}

### Application Settings

To configure the application, click **Settings** on the main page:

![GBS FastLine Settings Screen](/files/2dae6b39ea86407295a56158161215ff806ab438)

On this screen, the user can configure how detection works, as well as the camera that will be used.

## Default Workflow

The default workflow for using FastLine is as follows:

1. Log in
2. Populate the database
3. Start detection
4. End detection
5. Check the results
6. Export the PDF with the results.

## Detection

### Detection Screen

The *Detection Screen* is the core of GBS FastLine. On this screen, the user can view the images captured by the camera, as well as the already identified and unidentified people.

![GBS FastLine Detection Screen](/files/b26c43d80f1c62b875fc2dbff6093a6b273236cf)

#### Performing Detections

Detections can be started through the interface in the version *Desktop*, or through the API, in the *Services*version. Once started, the application will begin recognition through the configured camera. Each time a frame from the live image matches a profile in the database, the event will be logged and a notification may be sent (depending on the application settings).

Each profile can be recognized only once: When a profile is recognized, it is removed from the *watch list*.

It is possible to detect more than one face at a time, reduce the camera detection area, specify other camera resolutions, switch between cameras, change the identification threshold, and other features through the application settings.

Detections are performed in *detection sessions*, a concept discussed below.

#### Detection Session

Every detection process must occur within a Detection Session; these sessions can be created by the user through the interface or the API. Once created, sessions can be started, paused, resumed, and ended. While not ended, sessions can have their settings and data changed. Once ended, the session generates a detection report that can no longer be changed.

A *Detection Session* can be seen as a report being written. When complete, it becomes an immutable detection report, ensuring data consistency.

Each detection session has its own *UUID* (Universal Unique Identifier, in English, *Universal Unique Identifier*), called **SGUID** (Global Session Unique Identifier, in English, *Session Global Unique Identifier*)

### List of Identified

The *List of Identified* shows the people who matched the registered people since the beginning of the session:

![GBS FastLine Detected People List](/files/0c2c070f8adc1c02480c23b1011a8ce9bcb8e736)

### List of Unidentified

The *List of Unidentified* shows the people who did not match the registered people since the beginning of the session:

![GBS FastLine Unidentified People List](/files/5d9182ee7ae623cf7ac4aa2ca723c0b6a55f66e6)

### Results Report

The user can see the session status on the *Report Screen*:

![GBS FastLine Report Screen](/files/4399a7e6018437ffb084f6f4a23229827ac258c7)

Once the detection session ends, the detection list becomes an immutable report. The report is automatically saved in a PDF or JSON file. The report format and the location where it is saved are determined in the application settings. In version *Desktop*, the application can be configured to automatically show the report when the session ends.

![Export as PDF Button](/files/719040a0ba42390f9d4cbd0b0ec0f50dccf9817a)

#### Generating a Report While Running

You can generate a report while FastLine is running. This partial report is only available if the configuration parameter `savePdfRunning` is set to `true` in the file `config.properties`. When this parameter is `true`, a button called Export as PDF will appear on the detection screen. You can click the button to generate the report.

![Export as PDF Button](/files/a8fdd0748c21da3804c2ea7cc82d513a8f3e9ad5)

## External Notification

When FastLine detects a face, it will display the acquired face image and the reference face image. Other information, such as the person's name and score, is also displayed. The matching information can also be sent to a given URL through the configuration `desktopStandalone.notifyUrl`.

To modify the setting, go to the FastLine folder, access the file `conf/config.properties` and change the parameter `desktopStandalone.notifyUrl` to the URL that will be notified.

After FastLine performs a match, it will display the information in the interface and notify the configured URL with the following JSON:

```json
{
	"id": "FastLine001",
	"status": "MATCH",
	"matchSummary": {
		"referencePerson": {
			"template": "BYTEARRAY",
			"tguid": "29D99G74-BF97-4714-B78E-1A3A49DDF782",
			"name": "John Doe",
			"document": "88418861092",
			"key": "CPF",
			"profileImageByteArray": "BYTEARRAY"
		},
		"score": 95.29505,
		"timestamp": "2022-08-08_08.08.08_BRT",
		"queryImage": "BYTEARRAY"
	}
}
```

{% hint style="info" %}
Note that the values of `profileImageByteArray`, `template` and `queryImage` will be byte arrays in base64 format.
{% endhint %}

The JSON fields are:

* id: FastLine ID, defined by the configuration `desktopStandalone.notifyId`.
* status: Indicates whether there was a match or not. It can return `MATCH` or `NOT_MATCH`. When it returns the value `NOT_MATCH`, the JSON will not have a `matchSummary`.
* template: Image template ByteArray in GBDS.
* tguid: Unique transaction ID in GBDS.
* name: Person's name. If no biographical information is available, this field may be blank.
* document: value of the key defined in the field `key`.
* key: Person's key in GBDS.
* profileImageByteArray: Image ByteArray in GBDS.
* score: Match score.
* timestamp: Match timestamp.
* queryImage: ByteArray of the image captured by FastLine.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.griaule.com/gbs/en/applications/fastline.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
