# Architecture

## High-level Infrastructure

The Orange system receives invocation requests from applications with specific models and datasets.&#x20;

First, it invokes the model specified in the invocation request by sending a request to the service set up by the **Model Provider (MP).** &#x20;

Next, based on the selected [**Data Provider**](/glossary.md#data-provider) **(DP)** and [**dataset**](/glossary.md#datasets), the system fetches data using an interface provided by them. After the calculation is complete and a result is generated, the system stores the result temporarily till it is fetched by the application.

{% hint style="info" %}
The system processes model invocation requests in the form of **tasks.** Each task corresponds to an individual [**Decentralized Identifier**](/glossary.md#did) **(DID)** **or wallet address.** Refer to the [**integration guide here**](/developers/within-your-system.md) for details.
{% endhint %}

The application can then proceed to fetch the result in its raw form (data object), or send a request to export it in the form of a verifiable credential or NFT.&#x20;

The following figure illustrates how the different components that make up the Orange system are connected and interact with each other.

![](/files/PGmg0IqmD0WbykCporZM)

Let's go over each component individually.

#### GraphQL API Server

The interface for applications to interact with the Orange system. It serves the following purposes:

* Fetching details of registered [**Model Providers**](/glossary.md#model-provider) **(MP)** and [**Data Providers**](/glossary.md#data-provider) **(DP)**
* Fetching details on publicly available models and datasets
* Sending calculation requests
* Fetching the generated results

#### DP Manager

A service module that **DPs** primarily interact with. The **DP manager** performs the following functions:

* Preliminary verification and docking
* Data interface invocation to fetch and query data

#### MP Manager

A service module that **MPs** primarily interact with. Enables the following features:

* Preliminary verification and docking
* Execution request handling
  * **WASM based:** Fetches a binary file for the model and performs service execution in an integrated execution environment
  * **Custom:** Invokes a standalone server deployed by the **MP** for service execution. Invocation via a **RESTful/RPC API**.

#### Dispatcher

A service module that basically handles all the requests from applications. It interacts with other components to perform a number of functions:

* Fetches data from a specified **DP** after receiving a data request
* Sends execution requests to a specified **MP** after receiving calculation requests
* Sends the results generated by the **MP** to the **reputation minting service** for further processing

#### Reputation Minting Service

A service that takes the calculation results produced by **MPs** and generates a specified form of verifiable proof. Some examples would be:

* Verifiable Credentials
* NFTs

**Blockchain**

Represents the ledger network where records are maintained. For instance,

* Record of a verifiable credential issued to a [**DID**](/glossary.md#did)
* Deploying NFT contracts that mint tokens based on the reputation assessment reports received from the Orange system


---

# 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.orangeprotocol.io/design/architecture.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.
