Implementing E-government Processes Distribution with Transparency using Multi-Agent Systems

E-government processes need transparency in order to allow citizens to understand and access valuable information in a democratic society. In this article, we present a multi-agent system (MAS) to process distribution that implements transparency characteristics. We demonstrate that the MAS paradigm stresses the organizational operating environment and the information systems alignment, being adequate to maintain process transparency. The Tropos agent-oriented software development methodology is used to define the soft goals of agents. The MAS architecture and the prototype were defined, implemented using JADE Framework and illustrated with lawsuits distribution data from the Superior Labor Court of Brazil.


Introduction
The open information flow is highlighted by e-government processes, which aim to collaborate with democracy, where engaged citizens are able to understand and access available information [Holzner and Holzner 2006].This emerging demand deals with transparency in government processes and services provided directly to citizens.Recently, transparency has gained increasing interest either by citizens or organizations.The way government operates and provides its services has been recognized as an important topic to citizens.Public organizations have been charged in their ability to provide transparency on its operations, performance and results [Fung et al. 2007].
In the public context, access to information allows to create a democratic society with participative citizens, providing them with tools to understand and use available information and beginning to coin a critical thinking about information and services.In this sense, organizational transparency has been investigated in order to add social values related to characteristics such as auditability, adaptability, accessibility, usability, understanding, correctness, consistency, dependability, among others.
A good example for process transparency to citizens is related to the automatic distribution of judicial processes (lawsuits), which nowadays occurs by sorting algorithms.According to the Brazilian National Council of Justice (Conselho Nacional de Justiça -CNJ), only in 2013, more than one million lawsuits were processed by the Brazilian Electronic Judicial Process System (Sistema de Processo Judicial Eletrônico -Considering the presented problems, this paper presents the implementation of transparency characteristics on government services through the use of a Multi-Agent System (MAS).The multi-agent paradigm is suitable for the analysis, design and construction of software solutions for complex systems, since they represent a natural abstraction mechanism to decompose and organize such systems [Jennings 2001].For Castro et al. (2001), organizational information systems have a better operating environment when understood in terms of its agents, responsibilities, goals, tasks and resources, while its construction is conceived as a collection of software, modules, data structures and interfaces.It is argued that this mismatch between the organizational operating environment and their information systems would be one of the factors for the low quality of systems and the frequent failure of development projects.Thus, to solve these problems, information systems should be organized in the same way as companies.This paper presents the construction of a MAS to address the problem of lawsuit distribution, using Tropos methodology [Bresciani et al. 2004] and JADE -Java Agent Development Framework [Bellifemine et al. 1999].
The paper is organized as follows: in Section 2, the research overview is presented to provide foundation for our proposal; in Section 3, the research method is described, including the transparency characteristics applied in the project, the design 1 http://www.conjur.com.br/2014-fev-12/cnj-demite-servidores-tj-ma-fraude-distribuicao-processos 2 http://www.conjur.com.br/2014-out-25/entravista-damares-medina-coelho-advogada-pesquisadora 3 http://www2.ana.gov.br/Paginas/imprensa/noticia.aspx?List=ccb75a86-bd5a-4853-8c76-cc46b7dc89a1&ID=11622 4 http://www.conjur.com.br/2014-dez-10/chefe-procuradoria-criminal-sp-promete-transparencia The lawsuit is an instrument with a purpose of making effective the rights and guarantees of citizens.It is subordinated to various principles of law, such as the legality, the efficiency and the Natural Judge.According to Delgado (2005), the principle of Natural Judge is a guarantee presented in all the constitutions of cultured people, reflecting the concern of not to allow anyone to be prosecuted or judged except by judges that form part of the judiciary and are invested with judicial powers fixed and limited by the Higher Law.The scope of the principle is to prohibit a justice of privilege or exception, by ensuring that all citizens have their disputes heard by legal judges, judges invested in its functions in accordance with the constitutional requirements.
The process distribution is the act that defines the judging organ responsible for leading and judge a particular court case.It is one of the key elements for the smooth and correct progress of the lawsuit and the impartiality of decisions, since it seeks to preserve the guarantee of natural judge.
The Brazilian Justice Power has many branches and courts with different levels of jurisdictions.The Labor Justice, one of these branches, is divided in three stages of hierarchy which are called instances.The first instance is composed by Labor Courts, the second by Regional Labor Courts and the third instance is the TST.The TST primary function is to standardize the Brazilian labor law.The instance where a process should be started depends on the matter to be dealt (processual class).After the sentence, it's possible to appeal to a higher instance court, contesting the decision made, until the process finishes and there are no more appeals.
The simplified flow of lawsuits at TST is presented in Figure 1.A process starts at TST with the delivery of an initial petition, which can be made in person presenting the document at TST's protocol department or virtually using the Integrated System for Electronic Document Protocol and Flow (Sistema Integrado de Protocolização e Fluxo de Documentos Eletrônicos -eDOC).When started in a lower instance of jurisdiction and an appel is made contesting the decision of a Regional Labor Court, a process arrives electronically through a data network using a software called Processual Parts ALBUQUERQUE, D. J.; NUNES, V. T.; RALHA, C. G.; CAPPELLI, C. Implementing E-government Processes Distribution with Transparency using Multi-Agent Systems iSys -Revista Brasileira de Sistemas de Informação, Rio de Janeiro, vol.9, No. 1, pp. 118-138, 2016 Delivery System (Sistema de Remessa de Peças Processuais -eRemessa).In some cases, the physical parts of a process can be requested [CSJT 2010].Considering the flow of lawsuits presented in Figure 1, note the activities related to each step: • arrival -for each lawsuit, information treatment is carried out (some are incorrect or absent) and its class is identified; • distribution of lawsuits -performed following a set of rules, some determined by the TST's internal regiment and others following department of distributions practices and work procedures; • judgment of the decision -performed by a judging organ, which can be a single judge or a collegiate, i.e., a group of ministers, depending on the class of the process; • publication of the decision -made, but in some cases, the sentence can still be contested by appealing to the TST or the Federal Supreme Court (Supremo Tribunal Federal -STF).
The general rules for process distribution are contained in the Law 13,105 of March 16, 2015 (Civil Process Code -CPC) 6 .The article 284 of this Law says that all processes are subject to registration and may be distributed where there is more than one judge.Article 5 (Sections XXXVII and LIII, from the Federal Constitution of 1988) states that where there is more than one judging organ, with concurrent jurisdiction, it is imposed an equal and alternating distribution among judges, and it also must be observed abstract, general and objectives aspects in order to avoid a designation on an ad hoc basis.Article 289 of CPC also says that the distribution can be monitored by the interested party, by his/her attorney, a prosecutor and the public defender.
To preserve the principle of Natural Judge, the judge's impartiality in the exercise of its function must be guaranteed, and it is his/her duty to declare impeded or suspect, if applicable.The causes of impediments and suspicion are determined in Articles 134 and 138 of the CPC.A judge may be considered unable to judge certain process for various reasons: (i) when it has already proofed a sentence in another jurisdiction degree; (ii) when he/she is part of the process himself/herself, his spouse or partner, or relative, consanguineous or similar, straight or collateral, up to the third degree; (iii) when presumptive heir, grantee or employer of any of the parties involved.
As for suspicion, a judge is considered suspect by his/her partiality when a close friend or capital enemy of any of the interested parties, receiving gifts of the parties, advise any of parties about the cause or where the judge declare suspicion for reasons of intimate venue.When the suspicion or impediment of the judge occurs, the process is to be redistributed and it is considered null and void the acts carried out by the magistrate.Thus, a lawsuit distribution system must implement these functional requirements.
All of those issues and how they affect the TST lawsuit should be common knowledge among all the parties involved (and everybody who has an interest).Therefore, the concept of transparency is discussed in Section 2.2 considering the context of the lawsuit distribution process (Section 2.1.1).

Lawsuit Distribution
The computational engine that currently automates the TST Electronic Judicial Process System, receives lawsuits, regardless of the class to which they belong, and distribute them after protocol registration and procedures for its complete identification.Currently, the applications that control and execute lawsuits distribution reside almost entirely in procedures and functions stored in TST's database management systems.They were developed partly following rules defined by the Court's Internal Rules, but they were mostly built to meet existing working practices of the administrative departments that perform the activities of lawsuits assessment and distribution.
At the beginning, the system was developed to handle the distribution of physical case files (the collection of documents that compose the lawsuit), since the electronic lawsuits were not a reality at that time.In this context, there was a need for a single distribution activity to deal with a large quantity of lawsuits.In order to make possible to solve common problems, it separates lawsuits in batches and prepare and join several terms.There was created the concept of the preparation for distribution that allows the operation of the distribution activity at a later date.Only when the distribution is finished, the information of the selected judging organ becomes public, by updating the history of rapporteurs and bureaucratic procedures in the database.
With the implementation of the electronic process, distribution is now carried out for each new lawsuit, although the preparation for distribution step has been kept in the work process, due to the need to review and checking by the administrative department.
For the system to work properly, the system manager must keep manually updated tables in databases with information about judges, judging organs, chairs of judging organs, succession chain of judges on the chairs, processual classes, competence of judging organs in relation to each class, reasons when withdrawing the process from the distribution step, impediments of the magistrates in relation to the parties involved in a process, its lawyers and others.This activity is carried out completely manually and there is no standard procedure for its implementation.
Therefore, for a process to be ready for distribution, it must meet a series of rules, such as: (i) the process must be in the distribution line and distribution department -it may not have been removed from the distribution line or be in the views of the lawyer; (ii) the process class is of Court's jurisdiction and there are competent and unhindered judging organs; (iii) absence of irregularities in the CNPJ (the National Corporate Registration) and CPF (National Individual Registration) information; (iv) absence of pending petitions; and (v) identification of correlated processes.Currently, the system performs the lottery process distribution by sorting among the magistrates considered able.The current system also makes use of compensation rules promoting the distribution in equal amounts by the judging organs, chair and processual classes, and taking into account distributions previously taken, reallocations and their cancellations.

Transparency
According to Cappelli and Leite (2010), "Transparency is a concept to information disclosure, having been used in different settings, mostly related to empowering of citizens with regard to their rights".Moreover, organizational transparency establishes a set of aspects that suggest the existence of policies, procedures and technologies to provide access, use, quality, understanding and auditability of processes and information [Cappelli 2009].Transparency may improve organizational processes and information view, while providing opportunities for knowledge about those, reducing the possibility of omission of information from and about the processes, enabling control over the products and services, facilitating research, and increasing trust between organizations and society.
In this regard, "A wave of transparency policies has swept across Latin America over the last decade or so.Among budget and legislative transparency provisions, political finance disclosure, and open-data portals, freedom of information (FOI) laws occupy a unique space."[Michener 2015].
In Brazil, the Access to Information Law (law nº 12.527, 2011) (Law nº 131, 2009) has encouraged active transparency, which caused a growing availability of information about public organizations in their institutional sites.Michener (2015) analyzed the jure and de facto strength of Latin American FOI regimes and shows that is a lot to be done in this area, from different perspectives such ad political, sociological, anthropological, and technological.It is truly an open invitation for researchers to address gaps in data and methods on FOI.
The concept of transparency, at first, seems a simple idea.However, it requires for its practice a deepening of its semantics, the existence of methods that make it possible to establish its efficiency and systematically in organizations.In addition, instruments that allow monitoring, if the way it is established in a particular organization attends to both strategy organization as the needs of society [Harrison et al. 2011].
In this context, Aalst (2009) argues that information technology (IT) has changed business process within and between enterprises, in the sense that work processes are increasingly being conducted under the supervision of information systems.Therefore, transparency is seen as a non-functional requirement (NFR) that processes and information systems should consider when they are being elicited, designed and implemented.Thus, transparency is seen as a quality issue that is orthogonal to the software functionality, i.e., "having transparency or not having transparency will not impact what the software does" [Cappelli and Leite 2010].It spreads this characteristic through different functional parts of a process and an information system.Therefore, Cappelli (2009) deals with the problem of implementing and evaluating transparency in organizational processes and information, by constructing a definition and systematization for transparency in the social context through a transparency catalog.Cappelli and Leite (2010) proposed the Transparency SIG (Softgoal Interdependency Graph) that aims to define an NFR catalogue [Chung et al. 2000], and to systematize the incorporation of transparency characteristics in organizational processes.The Transparency SIG is composed of nodes and links as presented in Figure 2, where nodes are the transparency characteristics to be implemented and links represent the type of contribution (break, hurt, unknown, help and make).For each characteristic, a set of operationalization and mechanisms was proposed in order to orient the introduction of transparency aspects in organizational processes.As an example, we present in Table 1 the characteristic of traceability according to Cappelli (2009).One of the aims of the Brazilian Strategy of Digital Governance (Estratégia de Governança Digital -EGD) is to provide transparency on digital interactions (through egovernment services) between citizens and the Government.It consists of democratizing the access to information, broaden discussions and streamline the delivery of public services with focus on efficiency and effectiveness of government functions.In order to assure these, one of the requirements society demands is that organizations assure that not only their computerized information are transparent, but also their computerized processes [Cappelli and Leite 2010].In this sense, the application of transparency to information systems is a new and important concern when designing software that processes information and interface with people.In Section 2.3, we discuss the use of MAS designed through the use a goaloriented approach, in order to support the implementation of software with transparency requirements.

Multi-Agent Systems
MAS research integrates aspects of artificial intelligence and distributed systems for the solution of complex problems, making use of autonomous deliberative agents.According to Wooldridge (2009), a MAS consists of several intelligent agents interacting with each other within an environment in order to achieve goals.For an agent to be considered intelligent, it should be autonomous, present communication, cooperation and reasoning skills, must have planning mechanisms to perform their actions and be flexible to changes in the environment.Also, it should be able to provide services and achieve individual and/or organizational goals.
In this regard, MAS provide an interesting way to simulate societies, which may help to shed some light on various kinds of social processes [Wooldridge 2009].MAS can represent real-world problems in its natural complexity, which cannot usually be solved by individual agents without cognition.One can say that a MAS is formed by entities that compose the parts of a complex system.These parts are represented by independent elements, with different characteristics, which can be modeled on an individual basis, where the understanding of each entity can only be done by the integrated set of parts, where the principle of interaction between entities in a dynamic, distributed and heterogeneous environment is essential.
The design of how agents interact with each other and with the environment is essential to understand and define the level of collaboration, negotiation, clarity, integrity, accountability, traceability, and other transparency characteristics necessary when automating a business process related to a public service.
Nevertheless, when treating transparency characteristics, it is important to note that one cannot say that something has or does not have some transparency characteristic.According to Cappelli and Leite (2010), we need to use a less objective judgment, like "almost transparent", "transparent enough" or "little transparent".This qualitative judgement led to the characterization of non-functional requirements as softgoals, since softgoals are goals without clear-cut criteria.Soft-goals are used for qualitative reasoning about process aims.According to Soffer and Wand (2005), while goals can be satisfied by a process, soft-goals by their nature are said to be satisficed (related to search for a satisfactory solution rather than an optimal one) [Simon 1981].
Related to agent goals, there is the agent-oriented software engineering (AOSE) domain of study with many methodologies to help the design of agent based systems.According to Bresciani et al. (2004), an explicit representation of goals and plans in agent oriented programming provides the flexibility needed in order to deal with intrinsic complexity of applications.To do that, they proposed an AOSE methodology called Tropos, which is driven by requirements and seeks to support the different phases of the development of agent-based systems.This methodology adopts the framework I* (ISTAR -Intentional STrategic Actor Relationships modeling) that employs concepts such as actors, agents, positions, roles, social dependencies, goals, tasks and resources [Yu et al. 2011].In this research we have used Tropos to design and model the MAS solution approach.

Related Work
Research on technologies applied to e-government has been increasing in the last few years focusing on several different domains of research such software engineering, knowledge engineering, interoperability at all levels (from semantic to technological), human-interface experience, social networks, and business processes [Vitvar et al. 2010].Approaches for different purposes have been proposed in order to apply MAS technology to e-government systems.Most of them cite the importance to promote transparency as one of their main goals along with the prevention of corruption.According to Halter et al. (2009), the lack of transparency is considered one of the factors that promote corruption.
As an example, a research focusing on data-mining techniques addressed by a multi-agent approach to detect the formation of cartels in Brazil was proposed by Ralha and Silva (2012).In Ambekar et al. (2015), authors proposed a framework using MAS for the managing of Indian Public Distribution System of food.
It is a fact that the introduction of information and communication technologies (ICTs) has improved transparency and access to information [Bertot et al. 2010].But none of them focus the subject in a systematic way, neither on how to implement it in process through ICTs that automate them.Serrano and Leite (2011) proposed an approach to capture requirements patterns through argumentation by identifying on argumentation graphs NFR operationalization of software transparency characteristics7.But the research focuses on applying transparency in software, while our research focus on applying transparency in the process itself.
In summary, our approach enhances the presented solutions since it provides a systematic way of introducing transparency characteristics to computerized government processes.Also, it provides transparency not only to the process and information to users (citizens, magistrates, organs and any interested part), but also to the application that supports its execution.Moreover, it might provide IT teams with a better system and process understanding for an easy evolution.

Materials and Methods
This section presents the materials and methods used in the research, including in Section 3.1 an overview of the research method.In Section 3.2 we present the chosen transparency characteristics used for the lawsuits distribution system.Section 3.3 describes the design model and Section 3.4 the architecture for the proposed solution.The prototype is presented in Section 3.5 and a simple view of its benefits for the lawsuit distribution activity flow is discussed in Section 3.6.ALBUQUERQUE, D. J.; NUNES, V. T.; RALHA, C. G.; CAPPELLI, C. Implementing E-government Processes Distribution with Transparency using Multi-Agent Systems iSys -Revista Brasileira de Sistemas de Informação, Rio de Janeiro, vol.9, No. 1, pp. 118-138, 2016

Research Method
This research aims to analyze and evaluate evidence if transparency characteristics can be implemented using a MAS.The research method used in this research is shown in Figure 3.This paper introduces the first achievements of this research and, therefore, its evaluation conduction was performed through the use of simple assessment in order to identify first impressions on the research viability.
During problem perception, the current TST lawsuit distribution was analyzed and the problems reported internally and through papers from national electronic law and justice magazines 8. Related work was also analyzed so as to discuss the problem and existing approaches.The theory analysis was performed in order to investigate and correlate the problems to organizational transparency definition and requirements and also to the potentials that the use of a MAS approach could bring to support their implementation.

Figure 3. Research Method
The modeling and design solution is the first contribution on this research aiming to establish how requirements are set considering the use of an agent-oriented approach.An early requirements Tropos model was designed to represent the relationship among the agents and intended goals.A prototype implementation using JADE was performed and a preliminary evaluation and analysis was made.

Selected Transparency Characteristics
According to Figure 2, there are five groups of transparency characteristics that have a varying degree of dependency relation to each other.Although the Transparency SIG was compared by Cappelli (2009) to a structured of levels of a maturity model (from the left to the right), the SIG does not advocate the need for full achievement of all the characteristics of a particular branch of the tree so one can move on to attend to the next one.It explains only that there is a strong dependency between the groups of ALBUQUERQUE, D. J.; NUNES, V. T.; RALHA, C. G.; CAPPELLI, C. Implementing E-government Processes Distribution with Transparency using Multi-Agent Systems iSys -Revista Brasileira de Sistemas de Informação, Rio de Janeiro, vol.9, No. 1, pp. 118-138, 2016 characteristics where the implementation of a feature can help or harm the implementation of another.
A branch of the Transparency SIG related to the characteristic of understandability was selected as shown in Figure 4. Understandability is the quality/ability to achieve the meaning and the sense making comprehensible processes, information and systems.The reason for choosing this specific branch is due to the fact that when a process is meaningfully understood, it can be built upon to acquire further understanding, it is usually versatile in different situations and facilitates analysis, faultfinding and evolution which is one of the first desires of the TST.Table 2 shows the definition and possible operationalization of the five characteristics that aims to satisfice the understandability goal according to Cappelli (2009).

Definition
The ability to express a great deal in just a few words (be summarized) For each one of the five characteristics, a set of implementation mechanisms (non-functional software requirements) was proposed (see Table 3) to be considered in requirements and design phase.

NFR
• An agent might not be redundant in relation to any other.
• An agent must have a clear purpose and be useful to the application as a whole.
• Each agent name must me intuitive and describes exactly what object it represents.
• Each module must be able to inform objectively the current status of its execution and information been handled.
• The knowledge model must be unique and known to all.

Composability
NFR • It must be known which part of the knowledge model each agent is aware and manipulate.
• Each operating part/agent and interface model may ensure they relate to each other.

NFR
• The architecture is to be modularized.
• Each agent must represent strictly one instance of a real object (one magistrate, department, etc.).
• Each part/agent must be independent.
• Each part/agent must have an associated standard designed in architecture.
The relationship among agents and other parts of the application must be well defined and described.• The knowledge model needs to specify each concepts and its relationship.

NFR
• Each module needs to have a specific responsibility and do strictly as specified knowing the steps it is supposed to perform and interfaces to other modules.• Each part/agent that has the same purpose and behavior must have the ability to be replicated when necessary.
• The Architecture must allow for evolution through the rapid configuration or exclusion of all the agents types.For example, it shall permit the rapid inclusion of new judges, new judging organs, or the exclusion of a protocol agent that will not be used anymore.

NFR
• The Architecture must plan each agent/part in an independent way but with clear interface standards.
• Each internal and external dependency among parts/agents of the application must be known.
• Each dependency among parts/agents of the application must me consistent.

Design Model
During requirements phase, we seek to understand the problem by comprehending the organizational context in which the system to be developed will be deployed [Bresciani et al. 2004].During this phase, we modelled the requirements of stakeholders such as social actors, who depend on each other and have reached goals of intent, perform tasks and provide resources.Figure 5 shows the early requirements for a MAS for lawsuits distribution.At this stage, three actors (red circles) were identified: the Protocol Agent (PA), the Distribution Agent (DA) and the Magistrate Agent (MA).Each agent must achieve defined hard-goals represented by the rounded boxes (green) and soft-goals represented as clouds (beige).Each agent access specific databases to reason on information related to its goals.The Protocol Agents (PAs) identify from lawsuits database, which lawsuits require distribution, obtaining the necessary information to carry out this activity.They must have the intelligence to identify, for example, when a process is related to others so that they can be distributed to the same judging organ.Information obtained by the PA will be passed on to Distribution Agents (DAs), when requested by them.It is up to PAs to update the processes database with information about the progress of processes (direct the process for a specific department) from distribution information received from the distribution agents.
The Magister Agents (MAs) identify information about a magistrate, such as competences, impediments and suspicions.This information is necessary to distribute the lawsuits properly and might be passed on to DAs when requested.MAs have the intelligence to find new impediments and suspicions regarding a magistrate even though the respective one does not provide them.As an example, a MA could find out that a magistrate is related to one persons involved in the lawsuit.
The DAs get information on lawsuits for distribution from the PAs and apply distribution rules considering also the information obtained from the MAs.They should do it in a way to promote understandability, which contributes to transparency.So agents need to implement characteristics as conciseness, composability, decomposability, extensibility and dependability.
The SMA prototype makes use of the JADE framework.JADE is a middleware for the development of agents that support FIPA9 specifications [Bellifemine et al. 1999].The platform includes two special agents (agent management system -AMS and directory facilitator -DF) that are automatically activated at startup.The AMS controls the platform, dealing with the creation, completion and other stages of the agents' life cycle.The DF is an agent that provides a directory service (yellow pages) for disclosure of which agents and services are available on the platform.Figure 6 shows the relationship among the agents on the platform using Tropos methodology.Note that there are several PAs (PA1, PA2, ..., PAn), where each one is specialized in treating lawsuits from each Regional Courts, applying specific rules for each case, e.g., PA TRT1 interfaces with Regional Court of Rio de Janeiro to obtain the lawsuits from this region.If necessary, a PA may request a DA to initialize the processes distribution.
Note also, there are several MAs (MA1, MA2, MA3, ..., MAn), each one representing one magistrate in the court.In addition, there may be several DAs (DA1, DA2, ..., DAn), each one using specific distribution rules for each lawsuit class.As an example, DA HC handles habeas corpus lawsuits and DA WM handles Writ of Mandamus.The distribution process can occur automatically, with the DAs performing their tasks on a scheduled basis, or in an automated mode from the receipt of PA For each of the understandability characteristics, Table 5 shows how the requirements described in Table 2 is designed in the proposed architecture.

Extensibility
NFR o) Each agent has a set of unique and goal-oriented steps to act and a set of information to handle.
p) The AMS is the agent responsible for managing the creation and coordination of all agents.q) It is possible to create a new PA, DA or MA and introduce into the architecture without stopping procedures in course.

Dependability
NFR r) Each agent corresponds to a specific resource or object of the world: a judge, a protocol system or distribution department.s) Each agent has its own implementation rules and interface patterns.t) Each dependency among agents is clear by their responsibility and position in the process of lawsuits at TST.

The prototype
To achieve its goals, agents must perform their related tasks.In JADE, agents perform tasks from their behavior specification (subclasses of Behavior), which will be executed in stages.For example, in the proposed prototype, the Distribution Agent (DA) shall perform tasks as: registration in the Director Facilitator (DF); identification of Protocol Agents (PAs) and Magistrate Agents (MA); classification of lawsuits; obtainment of processes for distribution; and process distribution.For some tasks, the agents will need to interact with other agents in the platform.This is achieved through the exchange of asynchronous messages among the agents involved, as an example shown in the sequence diagram of Figure 8.Note that the Directory Facilitator is represented by DF, the DA HC (Habeas Corpus) as HC, the PA Regional Court of TRT by TRT01/TRT04 and the MA Magistrate by MVTN/MDJSA.According to Castro et al. (2001), implementing a MAS is inherently difficult.For this reason, many implementation platforms have been proposed to simplify the development of MAS.But a common problem that developers encounter is to make JADE agents interact with their respective graphical interfaces and vice versa (Castro et al., 2006).A prototype was developed in Java using Swing technology to build a graphical interface and simulation.Figure 9 shows a running example of the system with a simulation with two PAs (TRT01 and TRT04), two MAs (MVTN and MDJSA), one DA HC and 37 lawsuits (7 distributed and 30 awaiting distribution).ALBUQUERQUE, D. J.; NUNES, V. T.; RALHA, C. G.; CAPPELLI, C. Implementing E-government Processes Distribution with Transparency using Multi-Agent Systems iSys -Revista Brasileira de Sistemas de Informação, Rio de Janeiro, vol.9, No. 1, pp. 118-138, 2016 In this prototype, PAs are responsible for identifying lawsuits waiting for distribution in a local database.In a real environment, it is expected that this agent perform their activities more autonomously and independently, directly interacting with legacy information systems, web services or database management systems.In Figure 9 prototype, there are two PAs with its respective GUIs (bottom right corner).The lawsuits are identified by its unique number as regulated by CNJ and a code with two letters that indicates the class of the lawsuit.
The MAs GUI (located at left part of Figure 9) was designed to register impediments and competence of magistrates.They also show the received lawsuits by the magistrate.In a non-simulated environment, they should also get this information in an automated way from searches in the organization's databases.
At first, to DAs, graphical interfaces are not required, since their operation could be completely autonomous with predefined behaviors.As an example, the agent could carry out their tasks according to a schedule or from messages received from other agents.But for simulation purposes, the prototype was designed with a graphical interface to trigger the distribution process task and give transparency to the distribution process since all its actions are recorded in an event log.

Lawsuit Distribution Activity Flow
Figure 10 shows a simplified level of the transparency that the distribution process acquires when the characteristics, operationalization and implementation mechanisms are specified for the lawsuit distribution system.
Note in Figure 10 that the PAs receive lawsuits from different judicial organs and for each of them information on their arrival is logged in the database.They analyze

Figure 1 .
Figure 1.The simplified flow of lawsuits at TST.

Figure 5 .
Figure 5. Early requirements for the Lawsuits Distribution.
agent (PA1, PA2, ..., PAn, DA1, DA2, ..., DAn, MA1, MA2, MA3, ..., MAn) has a specific responsibility and behavior.b) Each agent represents a specific resource or object of the world.Ex.: MA1 = Magistrate João da Silva, DA2 = Criminal Lawsuits c) The name of MA agents is composed by the name initials of the Magistrate each represents.Ex.: Magistrate João da Silva = MJS d) The name of PA agents is composed by the number of Regional Court of TRT that sends lawsuits to be distributed and analyzed.Ex.: TRT1, TRT 4 e) The name of DA agents is composed by the name of the lawsuit class.Ex.: DA HC (Habeas Corpus).f) Each agent has a set of unique and goal-oriented steps to act and a set of information to handle.Currently they keep keep track of communication among agents.Composability NFR g) Each agent knows its own steps and interface with other agents, triggering agents' actions or being trigged.h) Each agent has its own knowledge model and interfaces with other agents knowledge model to interact.i) All actions are logged and it is possible to compose the entire distribution process instance from agents' execution and interaction.Decomposability NFR j) Each agent decomposes the distribution process into a specific, independent and unique set of steps.k) Each agent represents a specific resource or object of the world.Ex.: MA1 = Magistrate João da Silva, DA2 = Criminal Lawsuits.l) Each agent represents an instance of a DA, PA or MA.m) Each of the relations PA-DA, MA-DA, PA-Eletronic Judicial Process, DA-Eletronic Judicial Process, MA-Eletronic Judicial Process, DF-PA, DF-DA, DF-MA, AMS-PA, AMS-DA and AMS-MA was specified.n) The knowledge model of each agent specifies not only the concepts it handles but also the relation among them.

Figure 9 .
Figure 9. GUI interface designed for interaction with agents.