diff --git a/configure/ols-configuring-openshift-lightspeed.adoc b/configure/ols-configuring-openshift-lightspeed.adoc index a7057e26313a..3f3c800757f1 100644 --- a/configure/ols-configuring-openshift-lightspeed.adoc +++ b/configure/ols-configuring-openshift-lightspeed.adoc @@ -36,3 +36,5 @@ include::modules/ols-tokens-and-token-quota-limits.adoc[leveloffset=+1] include::modules/ols-activating-token-quota-limits.adoc[leveloffset=+2] include::modules/ols-about-postgresql-persistence.adoc[leveloffset=+1] include::modules/ols-enabling-postgresql-persistence.adoc[leveloffset=+2] +include::modules/ols-about-mcp-server.adoc[leveloffset=+1] +include::modules/ols-enabling-mcp-server.adoc[leveloffset=+2] diff --git a/modules/ols-about-mcp-server.adoc b/modules/ols-about-mcp-server.adoc new file mode 100644 index 000000000000..20f0934893b1 --- /dev/null +++ b/modules/ols-about-mcp-server.adoc @@ -0,0 +1,13 @@ +// Module included in the following assemblies: +// * lightspeed-docs-main/configure/ols-configuring-openshift-lightspeed.adoc + +:_mod-docs-content-type: CONCEPT +[id="about-mcp-server_{context}"] += About Model Context Protocol (MCP) server + +A Model Context Protocol (MCP) server is a program that implements the Model Context Protocol. The protocol creates a secure intermediary between a large language model (LLM) and external resources, such as data sources or software applications. Using the protocol, an MCP server provides a standardized way for an LLM to increase context by requesting and receiving real-time updates from external resources. This functionality transforms the LLM from a static knowledge base into a dynamic system that uses real-time information to answer questions or complete actions. + +:FeatureName: MCP server +include::snippets/technology-preview.adoc[] + +MCP server is disabled by default. To enable the functionality, add the `spec.featureGate.MCPServer` specification to the `OLSConfig` custom resource (CR). \ No newline at end of file diff --git a/modules/ols-enabling-mcp-server.adoc b/modules/ols-enabling-mcp-server.adoc new file mode 100644 index 000000000000..e79770e45a1b --- /dev/null +++ b/modules/ols-enabling-mcp-server.adoc @@ -0,0 +1,69 @@ +// Module included in the following assemblies: +// * lightspeed-docs-main/configure/ols-configuring-openshift-lightspeed.adoc + +:_mod-docs-content-type: PROCEDURE +[id="ols-enabling-mcp-server_{context}"] += Enabling MCP server + +Enable the Model Context Protocol (MCP) server so that a large language model (LLM) can securely access an external tool, such as a database or API, and obtain real-time updates. + +.Prerequisites + +* You have installed the the {ols-long} Operator. + +* You have configured a large language model provider. + +* You have deployed the {ols-long} service. + +.Procedure + +. Open the {ols-long} `OLSconfig` custom resource (CR) file by running the following command: ++ +[source,terminal] +---- +$ oc edit olsconfig cluster +---- + +. Add `MCPServer` to the `spec.ols.featureGates` specification file and include the MCP server information. ++ +[source,yaml] +---- +apiVersion: ols.openshift.io/v1alpha1 +kind: OLSConfig +metadata: + name: cluster +spec: + featureGate: + - MCPServer <1> + mcpServers: + - name: mcp-server-1 <2> + streamableHTTP: + url: http://localhost:8080/mcp <3> + timeout: 30 + sseReadTimeout: 10 + headers: + - Authorization: Bearer + - Content-Type: application/json + - Accept: application/json + enableSSE: true + - name: mcp-server-2 + streamableHTTP: + url: http://localhost:8080/mcp + timeout: 30 <4> + sseReadTimeout: 10 <5> + headers: + - Authorization: Bearer + - Content-Type: application/json + - Accept: application/json + enableSSE: true <6> +---- +<1> Specifies the MCPServer functionality. +<2> Specifies the name of the MCP server. +<3> Specifies the URL path that the MCP server uses to communicate. +<4> Specifies the time that the MCP server has to respond to a query. If the client does not receive a query within the time specified, the MCP server times out. In this example, the timeout is 30 seconds. +<5> Specifies the amount of time a client waits for new data from a Server-Sent Events (SSE) connection. If the client does not receive data within that time, the client closes the connection. +<6> When you set `enableSSE` to true the MCP server establishes a one-way channel that the MCP server uses to push updates to the client whenever the server has new information. The default setting is `false`. + +. Click *Save*. ++ +The save operation saves the file and applies the changes so that the MCP server is available to the {ols-long} service. \ No newline at end of file