Skip to content

Commit

Permalink
WIP: add DeepSeek guide (#84)
Browse files Browse the repository at this point in the history
  • Loading branch information
johnymontana authored Jan 25, 2025
1 parent 1f7b60d commit cd6418c
Show file tree
Hide file tree
Showing 2 changed files with 71 additions and 0 deletions.
4 changes: 4 additions & 0 deletions mint.json
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,10 @@
"modus/error-handling"
]
},
{
"group": "How-To Guides",
"pages": ["modus/deepseek-model"]
},
{
"group": "API Reference",
"pages": [
Expand Down
67 changes: 67 additions & 0 deletions modus/deepseek-model.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
---
title: Using DeepSeek
description: "Use the DeepSeek Models with your Modus app"
mode: "wide"
"og:title": "Using DeepSeek - Modus"
---

DeepSeek is an AI lab that has developed and released a series of open source
LLMs that are notable for both their performance and cost-efficiency. By using a
Mixture-of-Experts (MoE) system that utilizes only 37 billion of the models' 671
billion parameters for any task, the DeepSeek-R1 model is able to achieve best
in class performance at a fraction of cost of inference on other comparable
models. In this guide we review how to leverage the DeepSeek models using Modus.

## Options for using DeepSeek with Modus

There are two options for invoking DeepSeek models in your Modus app:

1. [Use the distilled DeepSeek model hosted by Hypermode](#using-the-distilled-deepseek-model-hosted-by-Hypermode)
Hypermode hosts and makes available the distilled DeepSeek model which can be
used by Modus apps developed locally and deployed to Hypermode
2. [Use the DeepSeek API with your Modus app](#using-the-deepseek-api-with-modus)
Access DeepSeek models hosted on the DeepSeek platform by configuring a
DeepSeek connection in your Modus app and using your DeepSeek API key

## Using the distilled DeepSeek model hosted by Hypermode

TODO: explain what a distilled model is

```json modus.json
"deepseek-r1-distill": {
"sourceModel": "deepseek-ai/DeepSeek-R1-Distill-Llama-8B",
"provider": "hugging-face",
"connection": "hypermode"
}
```

## Using the DeepSeek API with Modus

```json modus.json
{
"$schema": "https://schema.hypermode.com/modus.json",
"endpoints": {
"default": {
"type": "graphql",
"path": "/graphql",
"auth": "bearer-token"
}
},
"models": {
"deepseek-chat": {
"sourceModel": "deepseek-chat",
"connection": "deepseek",
"path": "v1/chat/completions"
}
},
"connections": {
"deepseek": {
"type": "http",
"baseUrl": "https://api.deepseek.com/",
"headers": {
"Authorization": "Bearer {{API_TOKEN}}"
}
}
}
}
```

0 comments on commit cd6418c

Please sign in to comment.