This page describes how to run OpenChat Playground (OCP) with Foundry Local integration.
-
Get the repository root.
# bash/zsh REPOSITORY_ROOT=$(git rev-parse --show-toplevel)
# PowerShell $REPOSITORY_ROOT = git rev-parse --show-toplevel
-
Make sure the Foundry Local server is up and running with the following command.
foundry service start
-
Download the Foundry Local model. The default model OCP uses is
phi-4-mini.foundry model download phi-4-mini
Alternatively, if you want to run with a different model, say
qwen2.5-7b, other than the default one, download it first by running the following command.foundry model download qwen2.5-7b
Make sure to follow the model MUST be selected from the CLI output of
foundry model list. -
Make sure you are at the repository root.
cd $REPOSITORY_ROOT
-
Run the app.
# bash/zsh dotnet run --project $REPOSITORY_ROOT/src/OpenChat.PlaygroundApp -- \ --connector-type FoundryLocal
# PowerShell dotnet run --project $REPOSITORY_ROOT\src\OpenChat.PlaygroundApp -- ` --connector-type FoundryLocal
Alternatively, if you want to run with a different model, say
qwen2.5-7b, make sure you've already downloaded the model by running thefoundry model download qwen2.5-7bcommand.# bash/zsh dotnet run --project $REPOSITORY_ROOT/src/OpenChat.PlaygroundApp -- \ --connector-type FoundryLocal \ --alias qwen2.5-7b
# PowerShell dotnet run --project $REPOSITORY_ROOT\src\OpenChat.PlaygroundApp -- ` --connector-type FoundryLocal ` --alias qwen2.5-7b
-
Open your web browser, navigate to
http://localhost:5280, and enter prompts.