Technology

AI and Physical Security: How Grupo Code transformed its operations with AWS Generative AI

AI and Physical Security: How Grupo Code transformed its operations with AWS Generative AI. Read more on CodeBlog!

05/26/2025

Heitor Cunha

Operating in private security requires precision, legal compliance, and clear communication — especially in environments with high variability in internal rules, such as residential condominiums and corporate buildings. For Grupo Code, these challenges were directly linked to the productivity, reputation, and legal security of its operations. 

With multiple units served, the difficulty in dealing with lengthy, often confusing documents, combined with high turnover among work shifts, directly impacted the quality of the service provided, putting the company's compliance and reputation at risk.

Faced with this scenario, Grupo Code decided to leverage an innovative solution: the application of Generative Artificial Intelligence integrated with WhatsApp, the company's main communication channel. The result? A new level of efficiency, engagement, and operational compliance.

About the client:

Grupo Code is a Brazilian company operating in the private security sector, offering services such as access control, concierge, cleaning, and armed and unarmed surveillance. With more than 200 employees distributed across various clients, the company serves everything from individual buildings to large residential condominiums with more than 300 units.

Authorized by the Federal Police to operate in the security field, Grupo Code faces complex challenges related to the standardization of operational procedures, especially regarding compliance with specific internal rules for each client.

Client's Challenge:

One of the main challenges identified by Grupo Code lies in the high variability of internal rules and regulations between different buildings and condominiums. These documents, which are often long and difficult to interpret, cause confusion among employees, especially those working in concierge and cleaning roles, who are frequently reassigned to different locations. The absence of a clear mechanism for interpreting and communicating these rules generates operational risks, reputational damage, and dissatisfaction among residents.

Another critical point involves case logbooks, which are required by law and inspected by the Federal Police. Incident descriptions, which carry legal weight, frequently lack objectivity, clarity, and completeness, even after internal training. This represents a legal and operational risk for both Grupo Code and its clients.

Partner's Solution:

To solve these issues, a project based on generative artificial intelligence was implemented, aimed at supporting employees in understanding and properly applying the specific rules of each property.

The solution also provides support in drafting incident reports in a clear, standardized, and legally valid manner. All features are integrated within WhatsApp, the company's main internal communication tool, which facilitates daily adoption and usability of the tool.

The solution's architecture was developed using native AWS services, highlighted by the use of Amazon Bedrock, which integrates the Claude Sonnet v3.7 models (for natural language generation) and Amazon Titan (for vectorizing regulatory documents).

Orchestration is handled by a Node.js application hosted on AWS Fargate, while storage is managed via Amazon RDS with pgvector, enabling semantic searches in vectorized documents. To process voice messages sent via WhatsApp, Amazon Transcribe was adopted, ensuring precise transcription in Brazilian Portuguese. Integration with WhatsApp was done through Meta's official API, essential for securing user adoption. 

The RAG (Retrieval-Augmented Generation) approach was chosen for its capability to combine contextual searches in document bases with natural language response generation, maintaining accuracy and scalability. During the initial testing phase, different families of language models were evaluated, such as LLaMA and Haiku, but Claude Sonnet v3.5 showed superior performance in comprehension and clarity, and was subsequently updated to version 3.7.

Results and Benefits:

The solution went into production and quickly showed significant results. In just one month, the virtual assistant (named “Mara”) processed thousands of interactions and helped in writing hundreds of incident reports. About 70% of employees spontaneously mentioned the assistant's usefulness in internal satisfaction surveys, and there was a 40% increase in the number of legal incident logs – an outstanding step forward in terms of compliance and documentation.

Furthermore, the solution demonstrated a high level of user engagement, with users sending more than 30 improvement suggestions in the first month. The only goal not fully achieved was response time optimization. Despite testing faster models, the decision was made to prioritize response quality, especially in situations demanding legal precision. To mitigate this point, pre-configured quick responses are being implemented for urgent scenarios.

Finally, Grupo Code represents an exemplary case of generative AI application in a compliance- and trust-sensitive sector, such as private security.

The solution created for Grupo Code is a concrete example of how emerging technologies can solve real problems in critical sectors. By combining features such as contextual understanding of rules, natural language generation, and integration with everyday tools like WhatsApp, the solution transformed the way employees interpret policies and log incidents.

The benefits go beyond automation: there was a significant increase in the quality of legal logs, improved team satisfaction, and better adherence to standards. Despite challenges like response times, the focus on precision and reliability established "Mara" as an essential assistant for the operation.

The experience of Grupo Code shows that, with strategy and well-applied technology, it is possible to modernize a traditional and highly regulated sector like private security — without losing sight of accountability, trust, and the human factor.

Shall we talk?

Select a date on our calendar and speak directly with one of our technology experts.

Shall we talk?

Select a date on our calendar and speak directly with one of our technology experts.

Shall we talk?

Select a date on our calendar and speak directly with one of our technology experts.

Shall we talk?

Select a date on our calendar and speak directly with one of our technology experts.

All Rights Reserved - CodeBit

São Paulo - SP

(11) 3014-2103

171 Paulista Ave, 4th floor, Bela Vista, São Paulo - SP

Franca - SP

(11) 3014-2103

5860 Emílio Paludeto Ave.
Vila Hípica, Franca - SP

Orlando - FL

+1 (980) 890-0026

7345 W Sand Lake Rd Ste 210 Office 2546

All Rights Reserved - CodeBit

São Paulo - SP

(11) 3014-2103

171 Paulista Ave, 4th floor, Bela Vista, São Paulo - SP

Franca - SP

(11) 3014-2103

5860 Emílio Paludeto Ave.
Vila Hípica, Franca - SP

Orlando - FL

+1 (980) 890-0026

7345 W Sand Lake Rd Ste 210 Office 2546

All Rights Reserved - CodeBit

São Paulo - SP

(11) 3014-2103

171 Paulista Ave, 4th floor, Bela Vista, São Paulo - SP

Franca - SP

(11) 3014-2103

5860 Emílio Paludeto Ave.
Vila Hípica, Franca - SP

Orlando - FL

+1 (980) 890-0026

7345 W Sand Lake Rd Ste 210 Office 2546