feat: bootstrap documentation site (#252)

Signed-off-by: Aaron <29749331+aarnphm@users.noreply.github.com>
Signed-off-by: Aaron Pham <29749331+aarnphm@users.noreply.github.com>
Signed-off-by: GutZuFusss <leon.ikinger@googlemail.com>
Co-authored-by: GutZuFusss <leon.ikinger@googlemail.com>
This commit is contained in:
Aaron Pham
2023-09-12 12:28:29 -04:00
committed by GitHub
parent 7d128b8959
commit fddd0bf95e
115 changed files with 9118 additions and 3822 deletions

4
.eslintignore Normal file
View File

@@ -0,0 +1,4 @@
**/*.js
/*.ts
dist/
node_modules/

105
.eslintrc.cjs Normal file
View File

@@ -0,0 +1,105 @@
const TAILWIND_CONFIG = {
extends: ['plugin:tailwindcss/recommended'],
rules: {
'tailwindcss/classnames-order': 'off', // conflicts with prettier-plugin-tailwindcss
'tailwindcss/enforces-negative-arbitrary-values': 'error',
'tailwindcss/enforces-shorthand': 'error',
'tailwindcss/migration-from-tailwind-2': 'error',
'tailwindcss/no-custom-classname': 'error'
}
}
/** @type {import('eslint').Linter.Config} */
module.exports = {
root: true,
reportUnusedDisableDirectives: true,
ignorePatterns: ['next-env.d.ts'],
overrides: [
// Rules for all files
{
files: '**/*.{js,jsx,cjs,mjs,ts,tsx,cts,mts}',
extends: ['eslint:recommended', 'plugin:@typescript-eslint/recommended', 'plugin:import/typescript', 'prettier'],
plugins: ['import', 'unicorn'],
rules: {
'prefer-object-has-own': 'error',
'logical-assignment-operators': ['error', 'always', { enforceForIfStatements: true }],
'no-else-return': ['error', { allowElseIf: false }],
'no-lonely-if': 'error',
'prefer-destructuring': ['error', { VariableDeclarator: { object: true } }],
'import/no-duplicates': 'error',
'no-negated-condition': 'off',
'unicorn/no-negated-condition': 'error',
'prefer-regex-literals': ['error', { disallowRedundantWrapping: true }],
'object-shorthand': ['error', 'always'],
'unicorn/prefer-regexp-test': 'error',
'unicorn/no-array-for-each': 'error',
'@typescript-eslint/prefer-for-of': 'error',
// todo: enable
'@typescript-eslint/no-explicit-any': 'off',
'@typescript-eslint/no-non-null-assertion': 'off',
'@typescript-eslint/no-var-requires': 'off',
'@typescript-eslint/ban-ts-comment': 'off'
}
},
// Rules for React files
{
files: '{docs}/**',
extends: ['plugin:react/recommended', 'plugin:react/jsx-runtime', 'plugin:react-hooks/recommended', 'plugin:@next/next/recommended'],
rules: {
'react/prop-types': 'off',
'react/no-unknown-property': ['error', { ignore: ['jsx'] }],
'react-hooks/exhaustive-deps': 'error',
'react/self-closing-comp': 'error',
'no-restricted-syntax': [
'error',
{
// ❌ useMemo(…, [])
selector: 'CallExpression[callee.name=useMemo][arguments.1.type=ArrayExpression][arguments.1.elements.length=0]',
message: "`useMemo` with an empty dependency array can't provide a stable reference, use `useRef` instead."
},
{
// ❌ z.object(…)
selector: 'MemberExpression[object.name=z] > .property[name=object]',
message: 'Use z.strictObject is more safe.'
}
],
'react/jsx-filename-extension': ['error', { extensions: ['.tsx', '.jsx'], allow: 'as-needed' }],
'react/jsx-curly-brace-presence': 'error',
'react/jsx-boolean-value': 'error'
},
settings: {
react: { version: 'detect' }
}
},
// Rules for TypeScript files
{
files: '**/*.{ts,tsx,cts,mts}',
extends: [
// TODO: fix errors
// 'plugin:@typescript-eslint/recommended-requiring-type-checking'
],
parserOptions: {
project: ['docs/tsconfig.json', 'tsconfig.json']
},
rules: {
'@typescript-eslint/no-unnecessary-type-assertion': 'error',
'@typescript-eslint/consistent-type-imports': 'error',
'@typescript-eslint/non-nullable-type-assertion-style': 'error',
'@typescript-eslint/prefer-optional-chain': 'error'
}
},
// ⚙️ Docs
{
...TAILWIND_CONFIG,
files: 'docs/**',
settings: {
tailwindcss: {
config: 'docs/tailwind.config.js',
callees: ['cn'],
whitelist: ['dash-ring', 'theme-1', 'theme-2', 'theme-3', 'theme-4']
},
next: { rootDir: 'docs' }
}
}
]
}

1
.github/INFRA.md vendored
View File

@@ -7,6 +7,7 @@
OpenLLM uses a GitHub Action to run all CI/CD workflows. It also use [pre-commit.ci](https://pre-commit.ci/) to run CI for all pre-commit hooks.
The folder structure of this are as follow:
```prolog
.
├── CODEOWNERS # Code owners

View File

@@ -3,22 +3,22 @@ on:
workflow_dispatch:
push:
branches:
- "main"
- 'main'
tags:
- "*"
- '*'
paths:
- ".github/workflows/build-embedding.yml"
- "openllm-python/src/openllm/**"
- "openllm-core/src/openllm_core/**"
- "openllm-client/src/openllm_client/**"
- '.github/workflows/build-embedding.yml'
- 'openllm-python/src/openllm/**'
- 'openllm-core/src/openllm_core/**'
- 'openllm-client/src/openllm_client/**'
pull_request:
branches:
- "main"
- 'main'
paths:
- ".github/workflows/build-embedding.yml"
- "openllm-python/src/openllm/**"
- "openllm-core/src/openllm_core/**"
- "openllm-client/src/openllm_client/**"
- '.github/workflows/build-embedding.yml'
- 'openllm-python/src/openllm/**'
- 'openllm-core/src/openllm_core/**'
- 'openllm-client/src/openllm_client/**'
types: [labeled, opened, synchronize, reopened]
# https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#defaultsrun
defaults:
@@ -188,7 +188,7 @@ jobs:
- name: Sign the released image
if: ${{ github.event_name != 'pull_request' }}
env:
COSIGN_EXPERIMENTAL: "true"
COSIGN_EXPERIMENTAL: 'true'
run: echo "${{ steps.meta.outputs.tags }}" | xargs -I {} cosign sign --yes {}@${{ steps.build-and-push.outputs.digest }}
- name: Run Trivy in GitHub SBOM mode and submit results to Dependency Graph
uses: aquasecurity/trivy-action@fbd16365eb88e12433951383f5e99bd901fc618f # ratchet:aquasecurity/trivy-action@master

View File

@@ -3,22 +3,22 @@ on:
workflow_dispatch:
push:
branches:
- "main"
- 'main'
tags:
- "*"
- '*'
paths:
- ".github/workflows/build-embedding.yml"
- "openllm-python/src/openllm/**"
- "openllm-core/src/openllm_core/**"
- "openllm-client/src/openllm_client/**"
- '.github/workflows/build-embedding.yml'
- 'openllm-python/src/openllm/**'
- 'openllm-core/src/openllm_core/**'
- 'openllm-client/src/openllm_client/**'
pull_request:
branches:
- "main"
- 'main'
paths:
- ".github/workflows/build-embedding.yml"
- "openllm-python/src/openllm/**"
- "openllm-core/src/openllm_core/**"
- "openllm-client/src/openllm_client/**"
- '.github/workflows/build-embedding.yml'
- 'openllm-python/src/openllm/**'
- 'openllm-core/src/openllm_core/**'
- 'openllm-client/src/openllm_client/**'
types: [labeled, opened, synchronize, reopened]
env:
LINES: 120
@@ -184,7 +184,7 @@ jobs:
- name: Sign the released image
if: ${{ github.event_name != 'pull_request' }}
env:
COSIGN_EXPERIMENTAL: "true"
COSIGN_EXPERIMENTAL: 'true'
run: echo "${{ steps.meta.outputs.tags }}" | xargs -I {} cosign sign --yes {}@${{ steps.build-and-push.outputs.digest }}
- name: Run Trivy in GitHub SBOM mode and submit results to Dependency Graph
uses: aquasecurity/trivy-action@fbd16365eb88e12433951383f5e99bd901fc618f # ratchet:aquasecurity/trivy-action@master

View File

@@ -4,16 +4,16 @@ on:
push:
branches: [main]
tags:
- "*"
- '*'
paths:
- 'openllm-contrib/clojure/**'
- ".github/workflows/clojure-frontend.yml"
- 'contrib/clojure/**'
- '.github/workflows/clojure-frontend.yml'
pull_request:
types: [labeled, opened, synchronize, reopened]
branches: [main]
paths:
- 'openllm-contrib/clojure/**'
- ".github/workflows/clojure-frontend.yml"
- 'contrib/clojure/**'
- '.github/workflows/clojure-frontend.yml'
# https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#defaultsrun
defaults:
run:
@@ -114,7 +114,7 @@ jobs:
- name: Sign the released image
if: ${{ github.event_name != 'pull_request' }}
env:
COSIGN_EXPERIMENTAL: "true"
COSIGN_EXPERIMENTAL: 'true'
run: echo "${{ steps.meta.outputs.tags }}" | xargs -I {} cosign sign --yes {}@${{ steps.build-and-push.outputs.digest }}
- name: Run Trivy in GitHub SBOM mode and submit results to Dependency Graph
uses: aquasecurity/trivy-action@fbd16365eb88e12433951383f5e99bd901fc618f # ratchet:aquasecurity/trivy-action@master

View File

@@ -13,7 +13,7 @@ on:
type: string
outputs:
sucess:
description: "Whether the build is successful or not"
description: 'Whether the build is successful or not'
value: ${{ jobs.sucess-build.outputs.success }}
push:
branches: [main]
@@ -74,7 +74,7 @@ jobs:
strategy:
fail-fast: false
matrix:
directory: ["openllm-core", "openllm-python", "openllm-client"]
directory: ['openllm-core', 'openllm-python', 'openllm-client']
steps:
- uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac # ratchet:actions/checkout@v4
with:
@@ -105,11 +105,11 @@ jobs:
# Github Actions doesn't support pairing matrix values together, let's improvise
# https://github.com/github/feedback/discussions/7835#discussioncomment-1769026
buildplatform:
- [ubuntu-latest, linux-x86_64, ""]
- [macos-latest, macos-x86_64, "x86_64"]
- [macos-latest, macos-arm64, "arm64"]
- [macos-latest, macos-universal2, "universal2"]
directory: ["openllm-core", "openllm-python", "openllm-client"]
- [ubuntu-latest, linux-x86_64, '']
- [macos-latest, macos-x86_64, 'x86_64']
- [macos-latest, macos-arm64, 'arm64']
- [macos-latest, macos-universal2, 'universal2']
directory: ['openllm-core', 'openllm-python', 'openllm-client']
needs: get_commit_message
steps:
- uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac # ratchet:actions/checkout@v4
@@ -127,7 +127,7 @@ jobs:
config-file: pyproject.toml
env:
CIBW_PRERELEASE_PYTHONS: True
CIBW_ARCHS_MACOS: "${{ matrix.buildplatform[2] }}"
CIBW_ARCHS_MACOS: '${{ matrix.buildplatform[2] }}'
MYPYPATH: /project/typings
- name: Upload wheels as workflow artifacts
uses: actions/upload-artifact@a8a3f3ad30e3422c9c7b888a15615d19a852ae32 # ratchet:actions/upload-artifact@v3

View File

@@ -8,7 +8,7 @@ on:
# │ │ │ ┌───────────── month (1 - 12 or JAN-DEC)
# │ │ │ │ ┌───────────── day of the week (0 - 6 or SUN-SAT)
# │ │ │ │ │
- cron: "42 2 * * SUN-WED"
- cron: '42 2 * * SUN-WED'
# https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#defaultsrun
defaults:
run:
@@ -49,8 +49,8 @@ jobs:
GIT_COMMITTER_EMAIL: ${{ steps.import-gpg-key.outputs.email }}
BRANCH_NAME: cron/ratchet
with:
title: "ci: update lock actions [generated]"
commit-message: "cron: ratchet update"
title: 'ci: update lock actions [generated]'
commit-message: 'cron: ratchet update'
branch-suffix: timestamp
signoff: true
delete-branch: true

9
.gitignore vendored
View File

@@ -142,3 +142,12 @@ pyapp
.pdm-python
**/_version.py
# openllm-docs
.docs-checkout
quartz.git
public
prof
tsconfig.tsbuildinfo
.quartz-cache
private/

7
.npmrc Normal file
View File

@@ -0,0 +1,7 @@
strict-peer-dependencies=false
shell-emulator=true
engine-strict=true
save-exact=true
unsafe-perm=true
prefer-offline=true
prefer-workspace-packages=true

View File

@@ -1,6 +1,6 @@
ci:
autoupdate_schedule: weekly
skip: [changelog-dry-run, mypy, yapf, clj-kondo, pyright]
skip: [changelog-dry-run, mypy, yapf, clj-kondo, pyright, eslint, prettier]
autofix_commit_msg: "ci: auto fixes from pre-commit.ci\n\nFor more information, see https://pre-commit.ci"
autoupdate_commit_msg: 'ci: pre-commit autoupdate [pre-commit.ci]'
default_language_version:
@@ -31,6 +31,20 @@ repos:
types: [python]
exclude: ^(docs|tools|openllm-python/tests)
args: [--config=pyproject.toml]
- repo: https://github.com/pre-commit/mirrors-eslint
rev: v8.47.0
hooks:
- id: eslint
verbose: true
files: \.[jt]sx?$ # *.js, *.jsx, *.ts and *.tsx
types: [file]
- repo: https://github.com/pre-commit/mirrors-prettier
rev: v3.0.2
hooks:
- id: prettier
verbose: true
files: \.[jt]sx?$ # *.js, *.jsx, *.ts and *.tsx
types_or: [javascript, yaml, ts]
- repo: https://github.com/pre-commit/mirrors-mypy
rev: v1.5.1
hooks:
@@ -84,33 +98,33 @@ repos:
- repo: https://github.com/RobertCraigie/pyright-python
rev: v1.1.326
hooks:
- id: pyright
verbose: true
args: [--level, error]
exclude: |
(?x)^(
examples/.*|
tools/.*|
tests/.*|
openllm-python/src/openllm/playground/.*|
openllm-python/tests/.*|
openllm-client/src/openllm_client/pb.*|
.github/.*|
cz.py |
hatch_build.py
)$
additional_dependencies:
- openllm-client[grpc]
- bentoml[io]>=1.1.2
- transformers[agents,torch,tokenizers,accelerate]>=4.29.0
- peft
- safetensors
- optimum
- ghapi
- click==8.1.3
- bitsandbytes
- diffusers
- soundfile
- id: pyright
verbose: true
args: [--level, error]
exclude: |
(?x)^(
examples/.*|
tools/.*|
tests/.*|
openllm-python/src/openllm/playground/.*|
openllm-python/tests/.*|
openllm-client/src/openllm_client/pb.*|
.github/.*|
cz.py |
hatch_build.py
)$
additional_dependencies:
- openllm-client[grpc]
- bentoml[io]>=1.1.2
- transformers[agents,torch,tokenizers,accelerate]>=4.29.0
- peft
- safetensors
- optimum
- ghapi
- click==8.1.3
- bitsandbytes
- diffusers
- soundfile
- repo: meta
hooks:
- id: check-hooks-apply

13
.prettierignore Normal file
View File

@@ -0,0 +1,13 @@
public
node_modules
pnpm-lock.yaml
.cache
.docusaurus
build
.vercel
.next
pnpm-lock.yaml
openllm-python/tests
CHANGELOG.md
.github/CODE_OF_CONDUCT.md
LICENSE.md

8
.prettierrc Normal file
View File

@@ -0,0 +1,8 @@
{
"printWidth": 198,
"quoteProps": "as-needed",
"trailingComma": "none",
"tabWidth": 2,
"semi": false,
"singleQuote": true
}

View File

@@ -64,6 +64,7 @@ Before you can start developing, you'll need to set up your environment:
```
8. Enter a project's environment with.
```bash
hatch shell
```
@@ -114,6 +115,7 @@ After setting up your environment, here's how you can start contributing:
```bash
hatch run quality
```
4. Write tests that verify your feature or fix (see
[Writing Tests](#writing-tests) below).
5. Run all tests to ensure your changes haven't broken anything:
@@ -121,16 +123,19 @@ After setting up your environment, here's how you can start contributing:
```bash
hatch run tests:python
```
6. Commit your changes:
```bash
git commit -m "Add my feature"
```
7. Push your changes to your fork:
```bash
git push origin feature/my-feature
```
8. Submit a Pull Request on GitHub.
## Using a custom fork
@@ -198,6 +203,8 @@ See this [docs](/.github/INFRA.md) for more information on OpenLLM's CI/CD workf
See [ClojureScript UI's README.md](/openllm-contrib/clojure/README.md) for more information.
See [Documentation's README.md](/docs/README.md) for more information on running locally.
## Install from git archive install
```bash
@@ -251,6 +258,7 @@ simple rules:
- Added `LLM.func()`.
- `LLM.func()` now doesn't do X.Y.Z anymore when passed the _foobar_ argument.
- If you want to reference multiple issues, copy the news fragment to another
filename. _Towncrier_ will merge all news fragments with identical contents
into one entry with multiple links to the respective pull requests.

173
README.md
View File

@@ -223,16 +223,16 @@ You can specify any of the following Llama models by using `--model-id`.
- PyTorch (Default):
```bash
openllm start llama --model-id meta-llama/Llama-2-7b-chat-hf --backend pt
```
```bash
openllm start llama --model-id meta-llama/Llama-2-7b-chat-hf --backend pt
```
- vLLM (Recommended):
```bash
pip install "openllm[llama, vllm]"
openllm start llama --model-id meta-llama/Llama-2-7b-chat-hf --backend vllm
```
```bash
pip install "openllm[llama, vllm]"
openllm start llama --model-id meta-llama/Llama-2-7b-chat-hf --backend vllm
```
> [!NOTE]
> Currently when using the vLLM backend, quantization and adapters are not supported.
@@ -275,9 +275,9 @@ You can specify any of the following ChatGLM models by using `--model-id`.
- PyTorch (Default):
```bash
openllm start chatglm --model-id thudm/chatglm-6b --backend pt
```
```bash
openllm start chatglm --model-id thudm/chatglm-6b --backend pt
```
</details>
@@ -315,15 +315,15 @@ You can specify any of the following Dolly-v2 models by using `--model-id`.
- PyTorch (Default):
```bash
openllm start dolly-v2 --model-id databricks/dolly-v2-3b --backend pt
```
```bash
openllm start dolly-v2 --model-id databricks/dolly-v2-3b --backend pt
```
- vLLM:
```bash
openllm start dolly-v2 --model-id databricks/dolly-v2-3b --backend vllm
```
```bash
openllm start dolly-v2 --model-id databricks/dolly-v2-3b --backend vllm
```
> [!NOTE]
> Currently when using the vLLM backend, quantization and adapters are not supported.
@@ -365,16 +365,16 @@ You can specify any of the following Falcon models by using `--model-id`.
- PyTorch (Default):
```bash
openllm start falcon --model-id tiiuae/falcon-7b --backend pt
```
```bash
openllm start falcon --model-id tiiuae/falcon-7b --backend pt
```
- vLLM:
```bash
pip install "openllm[falcon, vllm]"
openllm start falcon --model-id tiiuae/falcon-7b --backend vllm
```
```bash
pip install "openllm[falcon, vllm]"
openllm start falcon --model-id tiiuae/falcon-7b --backend vllm
```
> [!NOTE]
> Currently when using the vLLM backend, quantization and adapters are not supported.
@@ -417,23 +417,23 @@ You can specify any of the following Flan-T5 models by using `--model-id`.
- PyTorch (Default):
```bash
openllm start flan-t5 --model-id google/flan-t5-large --backend pt
```
```bash
openllm start flan-t5 --model-id google/flan-t5-large --backend pt
```
- Flax:
```bash
pip install "openllm[flan-t5, flax]"
openllm start flan-t5 --model-id google/flan-t5-large --backend flax
```
```bash
pip install "openllm[flan-t5, flax]"
openllm start flan-t5 --model-id google/flan-t5-large --backend flax
```
- TensorFlow:
```bash
pip install "openllm[flan-t5, tf]"
openllm start flan-t5 --model-id google/flan-t5-large --backend tf
```
```bash
pip install "openllm[flan-t5, tf]"
openllm start flan-t5 --model-id google/flan-t5-large --backend tf
```
> [!NOTE]
> Currently when using the vLLM backend, quantization and adapters are not supported.
@@ -472,15 +472,15 @@ You can specify any of the following GPT-NeoX models by using `--model-id`.
- PyTorch (Default):
```bash
openllm start gpt-neox --model-id eleutherai/gpt-neox-20b --backend pt
```
```bash
openllm start gpt-neox --model-id eleutherai/gpt-neox-20b --backend pt
```
- vLLM:
```bash
openllm start gpt-neox --model-id eleutherai/gpt-neox-20b --backend vllm
```
```bash
openllm start gpt-neox --model-id eleutherai/gpt-neox-20b --backend vllm
```
> [!NOTE]
> Currently when using the vLLM backend, quantization and adapters are not supported.
@@ -525,16 +525,16 @@ You can specify any of the following MPT models by using `--model-id`.
- PyTorch (Default):
```bash
openllm start mpt --model-id mosaicml/mpt-7b-chat --backend pt
```
```bash
openllm start mpt --model-id mosaicml/mpt-7b-chat --backend pt
```
- vLLM (Recommended):
```bash
pip install "openllm[mpt, vllm]"
openllm start mpt --model-id mosaicml/mpt-7b-chat --backend vllm
```
```bash
pip install "openllm[mpt, vllm]"
openllm start mpt --model-id mosaicml/mpt-7b-chat --backend vllm
```
> [!NOTE]
> Currently when using the vLLM backend, quantization and adapters are not supported.
@@ -578,30 +578,30 @@ You can specify any of the following OPT models by using `--model-id`.
- PyTorch (Default):
```bash
openllm start opt --model-id facebook/opt-2.7b --backend pt
```
```bash
openllm start opt --model-id facebook/opt-2.7b --backend pt
```
- vLLM:
```bash
pip install "openllm[opt, vllm]"
openllm start opt --model-id facebook/opt-2.7b --backend vllm
```
```bash
pip install "openllm[opt, vllm]"
openllm start opt --model-id facebook/opt-2.7b --backend vllm
```
- TensorFlow:
```bash
pip install "openllm[opt, tf]"
openllm start opt --model-id facebook/opt-2.7b --backend tf
```
```bash
pip install "openllm[opt, tf]"
openllm start opt --model-id facebook/opt-2.7b --backend tf
```
- Flax:
```bash
pip install "openllm[opt, flax]"
openllm start opt --model-id facebook/opt-2.7b --backend flax
```
```bash
pip install "openllm[opt, flax]"
openllm start opt --model-id facebook/opt-2.7b --backend flax
```
> [!NOTE]
> Currently when using the vLLM backend, quantization and adapters are not supported.
@@ -643,15 +643,15 @@ You can specify any of the following StableLM models by using `--model-id`.
- PyTorch (Default):
```bash
openllm start stablelm --model-id stabilityai/stablelm-tuned-alpha-7b --backend pt
```
```bash
openllm start stablelm --model-id stabilityai/stablelm-tuned-alpha-7b --backend pt
```
- vLLM:
```bash
openllm start stablelm --model-id stabilityai/stablelm-tuned-alpha-7b --backend vllm
```
```bash
openllm start stablelm --model-id stabilityai/stablelm-tuned-alpha-7b --backend vllm
```
> [!NOTE]
> Currently when using the vLLM backend, quantization and adapters are not supported.
@@ -691,16 +691,16 @@ You can specify any of the following StarCoder models by using `--model-id`.
- PyTorch (Default):
```bash
openllm start startcoder --model-id bigcode/starcoder --backend pt
```
```bash
openllm start startcoder --model-id bigcode/starcoder --backend pt
```
- vLLM:
```bash
pip install "openllm[startcoder, vllm]"
openllm start startcoder --model-id bigcode/starcoder --backend vllm
```
```bash
pip install "openllm[startcoder, vllm]"
openllm start startcoder --model-id bigcode/starcoder --backend vllm
```
> [!NOTE]
> Currently when using the vLLM backend, quantization and adapters are not supported.
@@ -744,16 +744,16 @@ You can specify any of the following Baichuan models by using `--model-id`.
- PyTorch (Default):
```bash
openllm start baichuan --model-id baichuan-inc/baichuan-13b-base --backend pt
```
```bash
openllm start baichuan --model-id baichuan-inc/baichuan-13b-base --backend pt
```
- vLLM:
```bash
pip install "openllm[baichuan, vllm]"
openllm start baichuan --model-id baichuan-inc/baichuan-13b-base --backend vllm
```
```bash
pip install "openllm[baichuan, vllm]"
openllm start baichuan --model-id baichuan-inc/baichuan-13b-base --backend vllm
```
> [!NOTE]
> Currently when using the vLLM backend, quantization and adapters are not supported.
@@ -910,10 +910,10 @@ client.embed("I like to eat apples")
The following UIs are currently available for OpenLLM:
| UI | Owner | Type | Progress |
|-----------------------------------------------------------------------------------|-----------------------------------------------|----------------------|----------|
| [Clojure](https://github.com/bentoml/OpenLLM/blob/main/contrib/clojure/README.md) | [@GutZuFusss](https://github.com/GutZuFusss) | Community-maintained | 🔧 |
| TS | BentoML Team | | 🚧 |
| UI | Owner | Type | Progress |
| ----------------------------------------------------------------------------------------- | -------------------------------------------- | -------------------- | -------- |
| [Clojure](https://github.com/bentoml/OpenLLM/blob/main/openllm-contrib/clojure/README.md) | [@GutZuFusss](https://github.com/GutZuFusss) | Community-maintained | 🔧 |
| TS | BentoML Team | | 🚧 |
## ⚙️ Integrations
@@ -1068,6 +1068,7 @@ There are several ways to deploy your LLMs:
```bash
bentoml containerize <name:version>
```
This generates a OCI-compatible docker image that can be deployed anywhere
docker runs. For best scalability and reliability of your LLM service in
production, we recommend deploy with BentoCloud。

View File

@@ -100,6 +100,7 @@ _If you have any suggestions, feel free to give it on our discord server!_
import os, sys
import orjson, bentoml
```
This is partially to make it easier to work with merge-conflicts, and easier
for IDE to navigate context definition.

View File

@@ -1,5 +1,5 @@
#!/usr/bin/env bash
GIT_ROOT="$(git rev-parse --show-toplevel)"
cd "$GIT_ROOT" || exit 1
find . -type f -iname "*.so" -exec \rm -f {} \;
find . -type d -name "node_modules" -exec \rm -rf "{}" \;
find . -type f -iname "*.so" -exec rm -f {} \;
find . -type d -iname "node_modules" -exec rm -rf "{}" \;

9
docs/README.md Normal file
View File

@@ -0,0 +1,9 @@
# OpenLLM Documentation
Powered by [Nextra](https://nextra.site)
## Development
```bash
pnpm i && pnpm dev
```

View File

@@ -0,0 +1,30 @@
import { ArrowRightIcon } from '@components/icons'
import cn from 'clsx'
import { motion } from 'framer-motion'
import Link from 'next/link'
import type { ReactNode } from 'react'
import styles from './style.module.css'
export function Feature({ large, centered, children, lightOnly, className, href, index, ...props }) {
return (
<motion.div
initial={{ opacity: 0 }}
whileInView={{ opacity: 1 }}
viewport={{ once: true, margin: '-20px' }}
transition={{ duration: Math.min(0.25 + index * 0.2, 0.8) }}
className={cn(styles.feature, large && styles.large, centered && styles.centered, lightOnly && styles['light-only'], className)}
{...props}
>
{children}
{href ? (
<Link className={styles.link} href={href} target="_blank">
<ArrowRightIcon width="1.5em" />
</Link>
) : null}
</motion.div>
)
}
export function Features({ children }: { children: ReactNode }) {
return <div className={styles.features}>{children}</div>
}

View File

@@ -0,0 +1,135 @@
.feature {
position: relative;
padding: 1.5rem 1.75rem;
color: #000;
background-color: white;
overflow: hidden;
border-radius: 1.78em;
}
.feature.large {
grid-column: span 2;
}
.feature.centered {
text-align: center;
}
.feature h3 {
position: relative;
font-size: 34px;
font-size: min(34px, max(4vw, 24px));
font-weight: 600;
line-height: 1.25;
letter-spacing: -0.02rem;
z-index: 2;
}
:global(.dark) .feature:not(.light-only) {
color: #fff;
background-color: #202020;
}
.feature {
box-shadow:
0 8px 16px rgb(0 0 0 / 8%),
0 1px 2px rgb(0 0 0 / 4%),
0 0 0 1px rgb(0 0 0 / 3%);
transition: box-shadow 0.3s ease;
}
:global(.dark) .feature {
box-shadow: 0 0 0 1px rgb(82 82 82 / 60%);
}
.feature .link {
position: absolute;
right: 1em;
bottom: 1em;
z-index: 2;
width: 2.5em;
height: 2.5em;
background-color: rgb(0 0 0 / 39%);
backdrop-filter: blur(10px);
border-radius: 50%;
display: flex;
justify-content: center;
align-items: center;
color: rgba(255, 255, 255, 0.9);
box-shadow:
0 0 0 2px rgb(154 154 154 / 56%),
0 0 30px rgb(0 0 0 / 10%);
transition: all 0.2s ease;
-webkit-user-drag: none;
}
@media (hover: hover) {
.feature .link {
opacity: 0;
}
.feature:hover .link {
opacity: 1;
}
.feature .link:hover {
transform: scale(1.05);
color: rgba(255, 255, 255, 1);
background-color: rgba(64, 64, 64, 0.39);
box-shadow:
0 0 0 2px rgba(220, 220, 220, 0.56),
0 0 30px rgb(0 0 0 / 10%);
}
.feature .link:active {
transform: scale(1);
color: rgba(255, 255, 255, 0.8);
background-color: rgba(22, 22, 22, 0.39);
box-shadow:
0 0 0 2px rgba(178, 178, 178, 0.56),
0 0 30px rgb(0 0 0 / 10%);
}
}
.features {
display: grid;
grid-template-columns: repeat(3, 1fr);
grid-gap: 2em;
font-feature-settings: initial;
}
.feature :global(.show-on-mobile) {
display: none;
}
@media screen and (max-width: 1024px) {
.feature {
max-width: 80vw;
width: 100%;
}
.feature.large {
grid-column: span 1;
}
.features {
grid-template-columns: 1fr;
grid-gap: 3em;
justify-items: center;
}
.feature h3 {
font-size: 28px;
font-size: min(28px, max(4vw, 22px));
text-align: center;
}
}
@media screen and (max-width: 640px) {
.feature {
max-width: 460px;
width: 100%;
}
.feature.large {
grid-column: span 1;
}
.features {
grid-template-columns: 1fr;
grid-gap: 3em;
justify-items: center;
}
.feature h3 {
font-size: 34px;
font-size: min(34px, max(4vw, 22px));
text-align: center;
}
.feature :global(.show-on-mobile) {
display: block;
}
}

View File

@@ -0,0 +1,11 @@
<svg
xmlns="http://www.w3.org/2000/svg"
viewBox="0 0 20 20"
fill="currentColor"
>
<path
fill-rule="evenodd"
d="M12.293 5.293a1 1 0 011.414 0l4 4a1 1 0 010 1.414l-4 4a1 1 0 01-1.414-1.414L14.586 11H3a1 1 0 110-2h11.586l-2.293-2.293a1 1 0 010-1.414z"
clip-rule="evenodd"
/>
</svg>

After

Width:  |  Height:  |  Size: 301 B

View File

@@ -0,0 +1,13 @@
<svg
xmlns="http://www.w3.org/2000/svg"
fill="none"
viewBox="0 0 24 24"
stroke-width="1.5"
stroke="currentColor"
>
<path
stroke-linecap="round"
stroke-linejoin="round"
d="M21 7.5l-9-5.25L3 7.5m18 0l-9 5.25m9-5.25v9l-9 5.25M3 7.5l9 5.25M3 7.5v9l9 5.25m0-9v9"
/>
</svg>

After

Width:  |  Height:  |  Size: 294 B

View File

@@ -0,0 +1,13 @@
<svg
xmlns="http://www.w3.org/2000/svg"
fill="none"
viewBox="0 0 24 24"
stroke-width="1.5"
stroke="currentColor"
>
<path
stroke-linecap="round"
stroke-linejoin="round"
d="M9.53 16.122a3 3 0 00-5.78 1.128 2.25 2.25 0 01-2.4 2.245 4.5 4.5 0 008.4-2.245c0-.399-.078-.78-.22-1.128zm0 0a15.998 15.998 0 003.388-1.62m-5.043-.025a15.994 15.994 0 011.622-3.395m3.42 3.42a15.995 15.995 0 004.764-4.648l3.876-5.814a1.151 1.151 0 00-1.597-1.597L14.146 6.32a15.996 15.996 0 00-4.649 4.763m3.42 3.42a6.776 6.776 0 00-3.42-3.42"
/>
</svg>

After

Width:  |  Height:  |  Size: 551 B

View File

@@ -0,0 +1,13 @@
<svg
xmlns="http://www.w3.org/2000/svg"
fill="none"
viewBox="0 0 24 24"
stroke-width="1.5"
stroke="currentColor"
>
<path
stroke-linecap="round"
stroke-linejoin="round"
d="M6 6.878V6a2.25 2.25 0 012.25-2.25h7.5A2.25 2.25 0 0118 6v.878m-12 0c.235-.083.487-.128.75-.128h10.5c.263 0 .515.045.75.128m-12 0A2.25 2.25 0 004.5 9v.878m13.5-3A2.25 2.25 0 0119.5 9v.878m0 0a2.246 2.246 0 00-.75-.128H5.25c-.263 0-.515.045-.75.128m15 0A2.25 2.25 0 0121 12v6a2.25 2.25 0 01-2.25 2.25H5.25A2.25 2.25 0 013 18v-6c0-.98.626-1.813 1.5-2.122"
/>
</svg>

After

Width:  |  Height:  |  Size: 561 B

View File

@@ -0,0 +1,13 @@
<svg
xmlns="http://www.w3.org/2000/svg"
fill="none"
viewBox="0 0 24 24"
stroke-width="1.5"
stroke="currentColor"
>
<path
stroke-linecap="round"
stroke-linejoin="round"
d="M8.25 4.5l7.5 7.5-7.5 7.5"
/>
</svg>

After

Width:  |  Height:  |  Size: 234 B

View File

@@ -0,0 +1,13 @@
<svg
xmlns="http://www.w3.org/2000/svg"
fill="none"
viewBox="0 0 24 24"
stroke-width="1.5"
stroke="currentColor"
>
<path
stroke-linecap="round"
stroke-linejoin="round"
d="M2.25 15a4.5 4.5 0 004.5 4.5H18a3.75 3.75 0 001.332-7.257 3 3 0 00-3.758-3.848 5.25 5.25 0 00-10.233 2.33A4.502 4.502 0 002.25 15z"
/>
</svg>

After

Width:  |  Height:  |  Size: 339 B

View File

@@ -0,0 +1,13 @@
<svg
xmlns="http://www.w3.org/2000/svg"
fill="none"
viewBox="0 0 24 24"
stroke-width="1.5"
stroke="currentColor"
>
<path
stroke-linecap="round"
stroke-linejoin="round"
d="M17.25 6.75L22.5 12l-5.25 5.25m-10.5 0L1.5 12l5.25-5.25m7.5-3l-4.5 16.5"
/>
</svg>

After

Width:  |  Height:  |  Size: 280 B

View File

@@ -0,0 +1,5 @@
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 64 64" fill="currentColor">
<path
d="M60,36.75H55.25V30A4.26,4.26,0,0,0,51,25.75H33.25v-8.5H38A1.25,1.25,0,0,0,39.25,16V4A1.25,1.25,0,0,0,38,2.75H26A1.25,1.25,0,0,0,24.75,4V16A1.25,1.25,0,0,0,26,17.25h4.75v8.5H13A4.26,4.26,0,0,0,8.75,30v6.75H4A1.25,1.25,0,0,0,2.75,38V56A1.25,1.25,0,0,0,4,57.25H16A1.25,1.25,0,0,0,17.25,56V38A1.25,1.25,0,0,0,16,36.75H11.25V30A1.76,1.76,0,0,1,13,28.25H30.75v8.5H26A1.25,1.25,0,0,0,24.75,38V56A1.25,1.25,0,0,0,26,57.25H38A1.25,1.25,0,0,0,39.25,56V38A1.25,1.25,0,0,0,38,36.75H33.25v-8.5H51A1.76,1.76,0,0,1,52.75,30v6.75H48A1.25,1.25,0,0,0,46.75,38V56A1.25,1.25,0,0,0,48,57.25H60A1.25,1.25,0,0,0,61.25,56V38A1.25,1.25,0,0,0,60,36.75ZM27.25,5.25h9.5v9.5h-9.5Zm-12.5,49.5H5.25V39.25h9.5Zm22,0h-9.5V39.25h9.5Zm22,0h-9.5V39.25h9.5Z"
/>
</svg>

After

Width:  |  Height:  |  Size: 830 B

View File

@@ -0,0 +1,13 @@
<svg
xmlns="http://www.w3.org/2000/svg"
fill="none"
viewBox="0 0 24 24"
stroke-width="1.5"
stroke="currentColor"
>
<path
stroke-linecap="round"
stroke-linejoin="round"
d="M15 11.25l1.5 1.5.75-.75V8.758l2.276-.61a3 3 0 10-3.675-3.675l-.61 2.277H12l-.75.75 1.5 1.5M15 11.25l-8.47 8.47c-.34.34-.8.53-1.28.53s-.94.19-1.28.53l-.97.97-.75-.75.97-.97c.34-.34.53-.8.53-1.28s.19-.94.53-1.28L12.75 9M15 11.25L12.75 9"
/>
</svg>

After

Width:  |  Height:  |  Size: 444 B

View File

@@ -0,0 +1,13 @@
<svg
xmlns="http://www.w3.org/2000/svg"
fill="none"
viewBox="0 0 24 24"
stroke-width="1.5"
stroke="currentColor"
>
<path
stroke-linecap="round"
stroke-linejoin="round"
d="M19.5 14.25v-2.625a3.375 3.375 0 00-3.375-3.375h-1.5A1.125 1.125 0 0113.5 7.125v-1.5a3.375 3.375 0 00-3.375-3.375H8.25m0 12.75h7.5m-7.5 3H12M10.5 2.25H5.625c-.621 0-1.125.504-1.125 1.125v17.25c0 .621.504 1.125 1.125 1.125h12.75c.621 0 1.125-.504 1.125-1.125V11.25a9 9 0 00-9-9z"
/>
</svg>

After

Width:  |  Height:  |  Size: 486 B

View File

@@ -0,0 +1,13 @@
<svg
xmlns="http://www.w3.org/2000/svg"
fill="none"
viewBox="0 0 24 24"
stroke-width="1.5"
stroke="currentColor"
>
<path
stroke-linecap="round"
stroke-linejoin="round"
d="M15.75 17.25v3.375c0 .621-.504 1.125-1.125 1.125h-9.75a1.125 1.125 0 01-1.125-1.125V7.875c0-.621.504-1.125 1.125-1.125H6.75a9.06 9.06 0 011.5.124m7.5 10.376h3.375c.621 0 1.125-.504 1.125-1.125V11.25c0-4.46-3.243-8.161-7.5-8.876a9.06 9.06 0 00-1.5-.124H9.375c-.621 0-1.125.504-1.125 1.125v3.5m7.5 10.375H9.375a1.125 1.125 0 01-1.125-1.125v-9.25m12 6.625v-1.875a3.375 3.375 0 00-3.375-3.375h-1.5a1.125 1.125 0 01-1.125-1.125v-1.5a3.375 3.375 0 00-3.375-3.375H9.75"
/>
</svg>

After

Width:  |  Height:  |  Size: 670 B

View File

@@ -0,0 +1,5 @@
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 576 512" fill="currentColor">
<path
d="M64 32C64 14.3 49.7 0 32 0S0 14.3 0 32v96V384c0 35.3 28.7 64 64 64H256V384H64V160H256V96H64V32zM288 192c0 17.7 14.3 32 32 32H544c17.7 0 32-14.3 32-32V64c0-17.7-14.3-32-32-32H445.3c-8.5 0-16.6-3.4-22.6-9.4L409.4 9.4c-6-6-14.1-9.4-22.6-9.4H320c-17.7 0-32 14.3-32 32V192zm0 288c0 17.7 14.3 32 32 32H544c17.7 0 32-14.3 32-32V352c0-17.7-14.3-32-32-32H445.3c-8.5 0-16.6-3.4-22.6-9.4l-13.3-13.3c-6-6-14.1-9.4-22.6-9.4H320c-17.7 0-32 14.3-32 32V480z"
/>
</svg>

After

Width:  |  Height:  |  Size: 553 B

View File

@@ -0,0 +1,13 @@
<svg
xmlns="http://www.w3.org/2000/svg"
fill="none"
viewBox="0 0 24 24"
stroke-width="1.5"
stroke="currentColor"
>
<path
stroke-linecap="round"
stroke-linejoin="round"
d="M4.745 3A23.933 23.933 0 003 12c0 3.183.62 6.22 1.745 9M19.5 3c.967 2.78 1.5 5.817 1.5 9s-.533 6.22-1.5 9M8.25 8.885l1.444-.89a.75.75 0 011.105.402l2.402 7.206a.75.75 0 001.104.401l1.445-.889m-8.25.75l.213.09a1.687 1.687 0 002.062-.617l4.45-6.676a1.688 1.688 0 012.062-.618l.213.09"
/>
</svg>

After

Width:  |  Height:  |  Size: 490 B

View File

@@ -0,0 +1,13 @@
<svg
xmlns="http://www.w3.org/2000/svg"
fill="none"
viewBox="0 0 24 24"
stroke-width="1.5"
stroke="currentColor"
>
<path
stroke-linecap="round"
stroke-linejoin="round"
d="M4.5 12a7.5 7.5 0 0015 0m-15 0a7.5 7.5 0 1115 0m-15 0H3m16.5 0H21m-1.5 0H12m-8.457 3.077l1.41-.513m14.095-5.13l1.41-.513M5.106 17.785l1.15-.964m11.49-9.642l1.149-.964M7.501 19.795l.75-1.3m7.5-12.99l.75-1.3m-6.063 16.658l.26-1.477m2.605-14.772l.26-1.477m0 17.726l-.26-1.477M10.698 4.614l-.26-1.477M16.5 19.794l-.75-1.299M7.5 4.205L12 12m6.894 5.785l-1.149-.964M6.256 7.178l-1.15-.964m15.352 8.864l-1.41-.513M4.954 9.435l-1.41-.514M12.002 12l-3.75 6.495"
/>
</svg>

After

Width:  |  Height:  |  Size: 660 B

View File

@@ -0,0 +1,13 @@
<svg
xmlns="http://www.w3.org/2000/svg"
fill="none"
viewBox="0 0 24 24"
stroke-width="1.5"
stroke="currentColor"
>
<path
stroke-linecap="round"
stroke-linejoin="round"
d="M12 21a9.004 9.004 0 008.716-6.747M12 21a9.004 9.004 0 01-8.716-6.747M12 21c2.485 0 4.5-4.03 4.5-9S14.485 3 12 3m0 18c-2.485 0-4.5-4.03-4.5-9S9.515 3 12 3m0 0a8.997 8.997 0 017.843 4.582M12 3a8.997 8.997 0 00-7.843 4.582m15.686 0A11.953 11.953 0 0112 10.5c-2.998 0-5.74-1.1-7.843-2.918m15.686 0A8.959 8.959 0 0121 12c0 .778-.099 1.533-.284 2.253m0 0A17.919 17.919 0 0112 16.5c-3.162 0-6.133-.815-8.716-2.247m0 0A9.015 9.015 0 013 12c0-1.605.42-3.113 1.157-4.418"
/>
</svg>

After

Width:  |  Height:  |  Size: 670 B

View File

@@ -0,0 +1,8 @@
<svg viewBox="0 0 15 15" xmlns="http://www.w3.org/2000/svg">
<path
d="M14 11.0001V4.00006L1 4.00006L1 11.0001H14ZM15 4.00006V11.0001C15 11.5523 14.5523 12.0001 14 12.0001H1C0.447715 12.0001 0 11.5523 0 11.0001V4.00006C0 3.44778 0.447715 3.00006 1 3.00006H14C14.5523 3.00006 15 3.44778 15 4.00006ZM2 5.25C2 5.11193 2.11193 5 2.25 5H5.75C5.88807 5 6 5.11193 6 5.25V9.75C6 9.88807 5.88807 10 5.75 10H2.25C2.11193 10 2 9.88807 2 9.75V5.25ZM7.5 7C7.22386 7 7 7.22386 7 7.5C7 7.77614 7.22386 8 7.5 8H10.5C10.7761 8 11 7.77614 11 7.5C11 7.22386 10.7761 7 10.5 7H7.5ZM7 9.5C7 9.22386 7.22386 9 7.5 9H12.5C12.7761 9 13 9.22386 13 9.5C13 9.77614 12.7761 10 12.5 10H7.5C7.22386 10 7 9.77614 7 9.5ZM7.5 5C7.22386 5 7 5.22386 7 5.5C7 5.77614 7.22386 6 7.5 6H11.5C11.7761 6 12 5.77614 12 5.5C12 5.22386 11.7761 5 11.5 5H7.5Z"
fill="currentColor"
fill-rule="evenodd"
clip-rule="evenodd"
/>
</svg>

After

Width:  |  Height:  |  Size: 902 B

View File

@@ -0,0 +1,29 @@
export { default as FilesIcon } from './files.svg'
export { default as MarkdownIcon } from './markdown.svg'
export { default as TailwindIcon } from './tailwind.svg'
export { default as LinkIcon } from './link.svg'
export { default as LightningIcon } from './lightning.svg'
export { default as GlobeIcon } from './globe.svg'
export { default as PictureIcon } from './picture.svg'
export { default as CodeIcon } from './code.svg'
export { default as BrushIcon } from './brush.svg'
export { default as DropperIcon } from './dropper.svg'
export { default as StarsIcon } from './stars.svg'
export { default as FormulaIcon } from './formula.svg'
export { default as WarningIcon } from './warning.svg'
export { default as ChevronRightIcon } from './chevron-right.svg'
export { default as BoxIcon } from './box.svg'
export { default as GearIcon } from './gear.svg'
export { default as RowsIcon } from './rows.svg'
export { default as CardsIcon } from './cards.svg'
export { default as OneIcon } from './one.svg'
export { default as CloudIcon } from './cloud.svg'
export { default as TableIcon } from './table.svg'
export { default as FileIcon } from './file.svg'
export { default as NewsletterIcon } from './newsletter.svg'
export { default as ArrowRightIcon } from './arrow-right.svg'
export { default as SwitchIcon } from './switch.svg'
export { default as TerminalIcon } from './terminal.svg'
export { default as DiagramIcon } from './diagram.svg'
export { default as FolderTreeIcon } from './folder-tree.svg'
export { default as IdCardIcon } from './id-card.svg'

View File

@@ -0,0 +1,7 @@
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="currentColor">
<path
fill-rule="evenodd"
d="M14.615 1.595a.75.75 0 01.359.852L12.982 9.75h7.268a.75.75 0 01.548 1.262l-10.5 11.25a.75.75 0 01-1.272-.71l1.992-7.302H3.75a.75.75 0 01-.548-1.262l10.5-11.25a.75.75 0 01.913-.143z"
clip-rule="evenodd"
/>
</svg>

After

Width:  |  Height:  |  Size: 338 B

View File

@@ -0,0 +1,13 @@
<svg
xmlns="http://www.w3.org/2000/svg"
fill="none"
viewBox="0 0 24 24"
stroke-width="1.5"
stroke="currentColor"
>
<path
stroke-linecap="round"
stroke-linejoin="round"
d="M13.19 8.688a4.5 4.5 0 011.242 7.244l-4.5 4.5a4.5 4.5 0 01-6.364-6.364l1.757-1.757m13.35-.622l1.757-1.757a4.5 4.5 0 00-6.364-6.364l-4.5 4.5a4.5 4.5 0 001.242 7.244"
/>
</svg>

After

Width:  |  Height:  |  Size: 372 B

View File

@@ -0,0 +1,6 @@
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24">
<path
fill="currentColor"
d="M20.56 18H3.44C2.65 18 2 17.37 2 16.59V7.41C2 6.63 2.65 6 3.44 6h17.12c.79 0 1.44.63 1.44 1.41v9.18c0 .78-.65 1.41-1.44 1.41M6.81 15.19v-3.66l1.92 2.35l1.92-2.35v3.66h1.93V8.81h-1.93l-1.92 2.35l-1.92-2.35H4.89v6.38h1.92M19.69 12h-1.92V8.81h-1.92V12h-1.93l2.89 3.28L19.69 12Z"
/>
</svg>

After

Width:  |  Height:  |  Size: 388 B

View File

@@ -0,0 +1,13 @@
<svg
xmlns="http://www.w3.org/2000/svg"
fill="none"
viewBox="0 0 24 24"
stroke-width="1.5"
stroke="currentColor"
>
<path
stroke-linecap="round"
stroke-linejoin="round"
d="M12 7.5h1.5m-1.5 3h1.5m-7.5 3h7.5m-7.5 3h7.5m3-9h3.375c.621 0 1.125.504 1.125 1.125V18a2.25 2.25 0 01-2.25 2.25M16.5 7.5V18a2.25 2.25 0 002.25 2.25M16.5 7.5V4.875c0-.621-.504-1.125-1.125-1.125H4.125C3.504 3.75 3 4.254 3 4.875V18a2.25 2.25 0 002.25 2.25h13.5M6 7.5h3v3H6v-3z"
/>
</svg>

After

Width:  |  Height:  |  Size: 482 B

View File

@@ -0,0 +1,10 @@
<svg
xmlns="http://www.w3.org/2000/svg"
fill="currentColor"
stroke="none"
viewBox="-1 0 19 19"
>
<path
d="M16.417 9.6A7.917 7.917 0 1 1 8.5 1.683 7.917 7.917 0 0 1 16.417 9.6zM9.666 6.508H8.248L6.09 8.09l.806 1.103 1.222-.945v4.816h1.547z"
/>
</svg>

After

Width:  |  Height:  |  Size: 266 B

View File

@@ -0,0 +1,13 @@
<svg
xmlns="http://www.w3.org/2000/svg"
fill="none"
viewBox="0 0 24 24"
stroke-width="1.5"
stroke="currentColor"
>
<path
stroke-linecap="round"
stroke-linejoin="round"
d="M2.25 15.75l5.159-5.159a2.25 2.25 0 013.182 0l5.159 5.159m-1.5-1.5l1.409-1.409a2.25 2.25 0 013.182 0l2.909 2.909m-18 3.75h16.5a1.5 1.5 0 001.5-1.5V6a1.5 1.5 0 00-1.5-1.5H3.75A1.5 1.5 0 002.25 6v12a1.5 1.5 0 001.5 1.5zm10.5-11.25h.008v.008h-.008V8.25zm.375 0a.375.375 0 11-.75 0 .375.375 0 01.75 0z"
/>
</svg>

After

Width:  |  Height:  |  Size: 506 B

View File

@@ -0,0 +1,13 @@
<svg
xmlns="http://www.w3.org/2000/svg"
fill="none"
viewBox="0 0 24 24"
stroke-width="1.5"
stroke="currentColor"
>
<path
stroke-linecap="round"
stroke-linejoin="round"
d="M3.75 12h16.5m-16.5 3.75h16.5M3.75 19.5h16.5M5.625 4.5h12.75a1.875 1.875 0 010 3.75H5.625a1.875 1.875 0 010-3.75z"
/>
</svg>

After

Width:  |  Height:  |  Size: 322 B

View File

@@ -0,0 +1,13 @@
<svg
xmlns="http://www.w3.org/2000/svg"
fill="none"
viewBox="0 0 24 24"
stroke-width="1.5"
stroke="currentColor"
>
<path
stroke-linecap="round"
stroke-linejoin="round"
d="M9.813 15.904L9 18.75l-.813-2.846a4.5 4.5 0 00-3.09-3.09L2.25 12l2.846-.813a4.5 4.5 0 003.09-3.09L9 5.25l.813 2.846a4.5 4.5 0 003.09 3.09L15.75 12l-2.846.813a4.5 4.5 0 00-3.09 3.09zM18.259 8.715L18 9.75l-.259-1.035a3.375 3.375 0 00-2.455-2.456L14.25 6l1.036-.259a3.375 3.375 0 002.455-2.456L18 2.25l.259 1.035a3.375 3.375 0 002.456 2.456L21.75 6l-1.035.259a3.375 3.375 0 00-2.456 2.456zM16.894 20.567L16.5 21.75l-.394-1.183a2.25 2.25 0 00-1.423-1.423L13.5 18.75l1.183-.394a2.25 2.25 0 001.423-1.423l.394-1.183.394 1.183a2.25 2.25 0 001.423 1.423l1.183.394-1.183.394a2.25 2.25 0 00-1.423 1.423z"
/>
</svg>

After

Width:  |  Height:  |  Size: 802 B

View File

@@ -0,0 +1,6 @@
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24">
<path
fill="currentColor"
d="M7 18q-2.5 0-4.25-1.75T1 12q0-2.5 1.75-4.25T7 6h10q2.5 0 4.25 1.75T23 12q0 2.5-1.75 4.25T17 18Zm0-2h10q1.65 0 2.825-1.175Q21 13.65 21 12q0-1.65-1.175-2.825Q18.65 8 17 8H7Q5.35 8 4.175 9.175Q3 10.35 3 12q0 1.65 1.175 2.825Q5.35 16 7 16Zm0-1q1.25 0 2.125-.875T10 12q0-1.25-.875-2.125T7 9q-1.25 0-2.125.875T4 12q0 1.25.875 2.125T7 15Zm5-3Z"
/>
</svg>

After

Width:  |  Height:  |  Size: 450 B

View File

@@ -0,0 +1,13 @@
<svg
xmlns="http://www.w3.org/2000/svg"
fill="none"
viewBox="0 0 24 24"
stroke-width="1.5"
stroke="currentColor"
>
<path
stroke-linecap="round"
stroke-linejoin="round"
d="M3.375 19.5h17.25m-17.25 0a1.125 1.125 0 01-1.125-1.125M3.375 19.5h7.5c.621 0 1.125-.504 1.125-1.125m-9.75 0V5.625m0 12.75v-1.5c0-.621.504-1.125 1.125-1.125m18.375 2.625V5.625m0 12.75c0 .621-.504 1.125-1.125 1.125m1.125-1.125v-1.5c0-.621-.504-1.125-1.125-1.125m0 3.75h-7.5A1.125 1.125 0 0112 18.375m9.75-12.75c0-.621-.504-1.125-1.125-1.125H3.375c-.621 0-1.125.504-1.125 1.125m19.5 0v1.5c0 .621-.504 1.125-1.125 1.125M2.25 5.625v1.5c0 .621.504 1.125 1.125 1.125m0 0h17.25m-17.25 0h7.5c.621 0 1.125.504 1.125 1.125M3.375 8.25c-.621 0-1.125.504-1.125 1.125v1.5c0 .621.504 1.125 1.125 1.125m17.25-3.75h-7.5c-.621 0-1.125.504-1.125 1.125m8.625-1.125c.621 0 1.125.504 1.125 1.125v1.5c0 .621-.504 1.125-1.125 1.125m-17.25 0h7.5m-7.5 0c-.621 0-1.125.504-1.125 1.125v1.5c0 .621.504 1.125 1.125 1.125M12 10.875v-1.5m0 1.5c0 .621-.504 1.125-1.125 1.125M12 10.875c0 .621.504 1.125 1.125 1.125m-2.25 0c.621 0 1.125.504 1.125 1.125M13.125 12h7.5m-7.5 0c-.621 0-1.125.504-1.125 1.125M20.625 12c.621 0 1.125.504 1.125 1.125v1.5c0 .621-.504 1.125-1.125 1.125m-17.25 0h7.5M12 14.625v-1.5m0 1.5c0 .621-.504 1.125-1.125 1.125M12 14.625c0 .621.504 1.125 1.125 1.125m-2.25 0c.621 0 1.125.504 1.125 1.125m0 1.5v-1.5m0 0c0-.621.504-1.125 1.125-1.125m0 0h7.5"
/>
</svg>

After

Width:  |  Height:  |  Size: 1.4 KiB

View File

@@ -0,0 +1,13 @@
<svg
xmlns="http://www.w3.org/2000/svg"
fill="none"
viewBox="0 0 52 25"
stroke-width="3.25"
stroke="currentColor"
>
<path
stroke-linecap="round"
stroke-linejoin="round"
d="M25.517 0C18.712 0 14.46 3.382 12.758 10.146c2.552-3.382 5.529-4.65 8.931-3.805 1.941.482 3.329 1.882 4.864 3.432 2.502 2.524 5.398 5.445 11.722 5.445 6.804 0 11.057-3.382 12.758-10.145-2.551 3.382-5.528 4.65-8.93 3.804-1.942-.482-3.33-1.882-4.865-3.431C34.736 2.92 31.841 0 25.517 0zM12.758 15.218C5.954 15.218 1.701 18.6 0 25.364c2.552-3.382 5.529-4.65 8.93-3.805 1.942.482 3.33 1.882 4.865 3.432 2.502 2.524 5.397 5.445 11.722 5.445 6.804 0 11.057-3.381 12.758-10.145-2.552 3.382-5.529 4.65-8.931 3.805-1.941-.483-3.329-1.883-4.864-3.432-2.502-2.524-5.398-5.446-11.722-5.446z"
/>
</svg>

After

Width:  |  Height:  |  Size: 788 B

View File

@@ -0,0 +1,30 @@
<svg viewBox="0 0 256 256" xmlns="http://www.w3.org/2000/svg" stroke="currentColor">
<rect fill="none" height="256" width="256" />
<polyline
fill="none"
points="80 96 120 128 80 160"
stroke-linecap="round"
stroke-linejoin="round"
stroke-width="16"
/>
<line
stroke-linecap="round"
stroke-linejoin="round"
stroke-width="16"
x1="136"
x2="176"
y1="160"
y2="160"
/>
<rect
fill="none"
height="160"
rx="8.5"
stroke-linecap="round"
stroke-linejoin="round"
stroke-width="16.97"
width="192"
x="32"
y="48"
/>
</svg>

After

Width:  |  Height:  |  Size: 603 B

View File

@@ -0,0 +1,13 @@
<svg
xmlns="http://www.w3.org/2000/svg"
fill="none"
viewBox="0 0 24 24"
stroke-width="1.5"
stroke="currentColor"
>
<path
stroke-linecap="round"
stroke-linejoin="round"
d="M12 9v3.75m-9.303 3.376c-.866 1.5.217 3.374 1.948 3.374h14.71c1.73 0 2.813-1.874 1.948-3.374L13.949 3.378c-.866-1.5-3.032-1.5-3.898 0L2.697 16.126zM12 15.75h.007v.008H12v-.008z"
/>
</svg>

After

Width:  |  Height:  |  Size: 385 B

51
docs/globals.css Normal file
View File

@@ -0,0 +1,51 @@
@tailwind base;
@tailwind components;
@tailwind utilities;
body {
font-feature-settings:
'rlig' 1,
'calt' 1,
'kern' 1;
}
.home-content p {
margin-top: 1.5em;
line-height: 1.75em;
}
.home-content a {
--tw-ring-color: hsl(var(--nextra-primary-hue) 100% 50%/0.3);
--tw-text-opacity: 1;
text-underline-position: under;
text-decoration-line: underline;
text-decoration-thickness: from-font;
color: hsl(var(--nextra-primary-hue) 100% 50% / var(--tw-text-opacity));
}
figcaption {
font-size: 0.85rem;
line-height: 1.5rem;
display: block;
text-align: center;
margin-top: 0.5rem;
}
code.text-\[\.9em\] {
font-size: 14px;
}
@media screen and (max-width: 1200px) {
.home-content .hide-medium {
display: none;
}
}
@media screen and (max-width: 720px) {
.home-content p {
font-size: 0.9rem;
}
.home-content .hide-small {
display: none;
}
}

5
docs/next-env.d.ts vendored Normal file
View File

@@ -0,0 +1,5 @@
/// <reference types="next" />
/// <reference types="next/image-types/global" />
// NOTE: This file should not be edited
// see https://nextjs.org/docs/basic-features/typescript for more information.

24
docs/next.config.mjs Normal file
View File

@@ -0,0 +1,24 @@
import nextra from 'nextra'
const withNextra = nextra({
theme: 'nextra-theme-docs',
themeConfig: './theme.config.tsx',
latex: true,
defaultShowCopyCode: true
})
export default withNextra({
reactStrictMode: true,
webpack(config) {
const allowedSvgRegex = /components\/icons\/.+\.svg$/
const fileLoaderRule = config.module.rules.find((rule) => rule.test?.test('.svg'))
fileLoaderRule.exclude = allowedSvgRegex
config.module.rules.push({
test: allowedSvgRegex,
use: ['@svgr/webpack']
})
return config
}
})

44
docs/package.json Normal file
View File

@@ -0,0 +1,44 @@
{
"name": "@bentoml/openllm-docs",
"description": "📚 OpenLLM Documentation",
"license": "Apache-2.0",
"private": true,
"scripts": {
"dev": "next dev",
"build": "next build",
"start": "next start"
},
"repository": {
"type": "git",
"url": "git+https://github.com/bentoml/OpenLLM.git"
},
"author": "Aaron Pham <aarnphm@bentoml.com>",
"bugs": {
"url": "https://github.com/bentoml/OpenLLM/issues"
},
"homepage": "https://github.com/bentoml/OpenLLM#readme",
"dependencies": {
"@mdx-js/react": "*",
"@vercel/analytics": "*",
"@vercel/og": "0.5.11",
"clsx": "^2.0.0",
"next": "*",
"next-themes": "^0.2.1",
"nextra": "2.11.1",
"nextra-theme-docs": "2.11.1",
"react": "*",
"react-dom": "*"
},
"devDependencies": {
"@svgr/webpack": "*",
"@types/dedent": "^0.7.0",
"@types/node": "*",
"@types/react": "*",
"@types/react-dom": "*",
"autoprefixer": "^10.4.12",
"eslint": "*",
"postcss": "^8.4.23",
"tailwindcss": "^3.3.2",
"typescript": "*"
}
}

5
docs/pages/404.mdx Normal file
View File

@@ -0,0 +1,5 @@
import { NotFoundPage } from 'nextra-theme-docs'
# 404: Oops, page not found
<NotFoundPage />

5
docs/pages/_app.mdx Normal file
View File

@@ -0,0 +1,5 @@
import '../globals.css'
export default function App({ Component, pageProps }) {
return <Component {...pageProps} />
}

31
docs/pages/_meta.json Normal file
View File

@@ -0,0 +1,31 @@
{
"index": {
"type": "page",
"title": "Introduction",
"display": "hidden"
},
"docs": {
"type": "page",
"title": "Documentation"
},
"about": {
"type": "page",
"title": "About",
"theme": {
"typesetting": "article"
}
},
"changelog": {
"type": "page",
"title": "Changelog",
"href": "https://github.com/bentoml/OpenLLM/blob/main/CHANGELOG.md",
"newWindow": true
},
"404": {
"type": "page",
"theme": {
"timestamp": false,
"typesetting": "article"
}
}
}

38
docs/pages/about.mdx Normal file
View File

@@ -0,0 +1,38 @@
# About
OpenLLM was started at [BentoML](https://bentoml.com) to provide a simple
and easy to use interface for serving and deploying large language models (LLMs)
in production. With OpenLLM, you can run inference with any open-source LLMs, deploy models to the
cloud or on-premises, and build powerful AI applications. It supports a wide range of open-source LLMs and
offers flexible APIs with first-class support for BentoML and LangChain.
## Team
The project is currently maintained by [Aaron Pham](https://twitter.com/aarnphm_). You can check out
the full list of contributors on [GitHub](https://github.com/bentoml/OpenLLM/graphs/contributors).
## Credits
OpenLLM is powered by these incredible open-source projects:
- https://bentoml.com/
- https://huggingface.co/docs/transformers/index
- https://github.com/PanQiWei/AutoGPTQ
- https://github.com/huggingface/peft
The documentation is powered by [Nextra](https://nextra.site/).
## Design assets
Feel free to use any of the assets in your project. But please modify
the logo and don't use these logo to represent your product or project.
| Name | Description | Preview |
| :---------: | :----------------------------------------------: | :-----------------------------------: |
| Icon | Useful for favicons, app icons, link icons, etc. | ![OpenLLM icon](/favicon/favicon.svg) |
| Logo | Full OpenLLM logo | ![OpenLLM logo](/logo.svg) |
| Social Card | The OpenLLM social card | ![OpenLLM card](/og.png) |
## License
The OpenLLM project is licensed under the [Apache License 2.0](https://www.apache.org/licenses/LICENSE-2.0)

77
docs/pages/api/og.jsx Normal file
View File

@@ -0,0 +1,77 @@
/* eslint-env node */
import { ImageResponse } from '@vercel/og'
export const config = {
runtime: 'edge'
}
export default async function image(req) {
const { searchParams } = new URL(req.url)
const hasTitle = searchParams.has('title')
const title = hasTitle ? searchParams.get('title')?.slice(0, 100) : 'OpenLLM Documentation'
return new ImageResponse(
(
<div
style={{
height: '100%',
width: '100%',
display: 'flex',
flexDirection: 'column',
alignItems: 'flex-start',
justifyContent: 'center',
padding: 80,
backgroundColor: '#030303',
backgroundImage: 'radial-gradient(circle at 25px 25px, #333 2%, transparent 0%), radial-gradient(circle at 75px 75px, #333 2%, transparent 0%)',
backgroundSize: '100px 100px',
backgroundPosition: '-30px -10px',
fontWeight: 600,
color: 'white'
}}
>
<svg style={{ position: 'absolute', top: 70, left: 80 }} height="40" viewBox="0 0 373 60" xmlns="http://www.w3.org/2000/svg" fill="white">
<path d="m59.56,3.16c-.11-.35-.26-.69-.45-.99-.23-.37-.5-.71-.82-1-.05-.05-.11-.1-.16-.14-.39-.32-.83-.58-1.31-.76s-1-.27-1.55-.27H14.94c-.09,0-.18,0-.27,0-.03,0-.05,0-.08,0-.07,0-.13.01-.2.02-.03,0-.06,0-.08.01-.08.01-.15.02-.23.04-.01,0-.02,0-.03,0-.09.02-.17.04-.26.06-.02,0-.05.01-.07.02-.06.02-.12.04-.19.06-.03,0-.05.02-.08.03-.07.02-.13.05-.2.08-.02,0-.03.01-.05.02-.08.03-.16.07-.24.11-.02,0-.04.02-.06.03-.06.03-.12.06-.18.09-.02.01-.05.03-.07.04-.06.03-.12.07-.17.11-.02.01-.03.02-.05.03-.07.05-.14.1-.21.15-.01.01-.03.02-.04.03-.06.04-.11.09-.16.13-.02.02-.04.03-.06.05-.05.04-.1.09-.15.13-.02.01-.03.03-.05.04-.03.03-.05.05-.08.08,0,0,0,0,0,0L1.12,10.91c-.72.72-1.12,1.69-1.12,2.7v42.57c0,2.11,1.71,3.82,3.82,3.82h42.57c1.01,0,1.99-.4,2.7-1.12l9.52-11.05c.17-.19.33-.4.47-.62,0,0,.01-.02.02-.02.03-.04.05-.09.08-.13,0-.02.02-.03.03-.05.02-.04.04-.08.06-.12.01-.02.02-.04.03-.07.02-.04.04-.08.05-.12.01-.03.02-.05.03-.08.02-.04.03-.07.05-.11.01-.03.02-.06.03-.09.01-.04.03-.07.04-.11.01-.03.02-.06.03-.09.01-.04.02-.07.03-.11,0-.03.02-.07.03-.1,0-.03.02-.07.03-.1,0-.04.02-.07.02-.11,0-.03.02-.07.02-.1,0-.04.01-.08.02-.12,0-.03.01-.06.02-.1,0-.04.01-.08.02-.13,0-.03,0-.06.01-.09,0-.05,0-.1.01-.14,0-.03,0-.05,0-.08,0-.07,0-.15,0-.22V4.5h0c0-.47-.07-.91-.2-1.34Zm-4.3-1.81c.54,0,1.05.14,1.5.38.22.12.43.27.62.44.04.03.07.07.11.1.07.07.14.15.2.22.06.08.12.16.18.24.34.5.54,1.11.54,1.76v40.33c0,.09,0,.18-.01.27,0,.01,0,.02,0,.03,0,.08-.02.17-.03.25,0,.01,0,.02,0,.04-.02.08-.03.16-.06.24,0,0,0,.02,0,.03-.02.08-.05.16-.08.24,0,0,0,0,0,0-.1.26-.23.5-.38.71h0c-.05.08-.11.15-.17.22-.04.04-.07.08-.11.12,0,0,0,0,0,0-.04.04-.07.08-.11.11,0,0,0,0,0,0-.04.04-.08.07-.12.11,0,0,0,0,0,0-.21.18-.44.33-.7.45,0,0-.01,0-.02,0-.04.02-.09.04-.13.06-.01,0-.02,0-.04.01-.04.02-.08.03-.12.04-.02,0-.03.01-.05.02-.04.01-.07.02-.11.03-.02,0-.04.01-.05.02-.03,0-.07.02-.1.03-.02,0-.04,0-.06.01-.03,0-.07.01-.1.02-.02,0-.04,0-.06.01-.04,0-.07.01-.11.02-.02,0-.04,0-.06,0-.04,0-.08,0-.12.01-.02,0-.03,0-.05,0-.06,0-.11,0-.17,0H14.94c-.87,0-1.66-.35-2.23-.92-.14-.14-.27-.3-.38-.47-.28-.42-.47-.91-.52-1.44-.01-.11-.02-.21-.02-.32V4.5c0-.06,0-.12,0-.18,0-.02,0-.04,0-.06,0-.04,0-.08.01-.12,0-.02,0-.04,0-.06,0-.04.01-.07.02-.11,0-.02,0-.04.01-.06,0-.04.01-.07.02-.11,0-.02,0-.04.01-.06.01-.04.02-.08.03-.12,0-.01,0-.03.01-.04.03-.11.07-.22.12-.32,0,0,0,0,0,0,.02-.05.04-.1.07-.15,0,0,0-.02.01-.02.02-.04.04-.09.07-.13,0,0,0-.02.01-.03.02-.04.05-.08.08-.13,0,0,0-.01.01-.02.03-.05.06-.09.09-.14,0,0,0,0,0,0,.17-.24.38-.45.61-.63.2-.16.42-.29.65-.39,0,0,0,0,.01,0,.07-.03.15-.06.23-.09,0,0,.01,0,.02,0,.15-.05.31-.09.47-.12.01,0,.03,0,.04,0,.08-.01.15-.02.23-.03.01,0,.03,0,.04,0,.08,0,.16-.01.25-.01h40.33Z" />
<g>
<circle cx="40.54" cy="24.66" r="2.74" />
<circle cx="29.67" cy="24.66" r="2.74" />
</g>
<path
d="M 289.083 46.203 L 288.423 46.863 L 280.503 46.863 L 279.843 46.203 L 279.843 20.463 L 279.183 20.463 L 268.623 46.203 L 267.963 46.863 L 260.703 46.863 L 260.043 46.203 L 249.483 20.463 L 248.823 20.463 L 248.823 46.203 L 248.163 46.863 L 240.243 46.863 L 239.583 46.203 L 239.583 1.323 L 240.243 0.663 L 250.143 0.663 L 250.803 1.323 L 264.003 33.663 L 264.663 33.663 L 277.863 1.323 L 278.523 0.663 L 288.423 0.663 L 289.083 1.323 L 289.083 46.203 Z M 157.083 46.203 L 156.423 46.863 L 148.503 46.863 L 147.843 46.203 L 147.843 27.063 A 9.504 9.504 0 0 0 147.624 24.942 C 147.237 23.261 146.306 21.954 144.574 21.405 A 6.64 6.64 0 0 0 142.563 21.123 C 138.845 21.123 136.41 22.832 135.6 26.595 A 14.825 14.825 0 0 0 135.303 29.703 L 135.303 46.203 L 134.643 46.863 L 126.723 46.863 L 126.063 46.203 L 126.063 14.523 L 126.723 13.863 L 133.983 13.863 L 134.643 14.523 L 135.303 16.503 L 135.963 16.503 C 137.035 15.43 138.979 13.922 142.149 13.394 A 14.552 14.552 0 0 1 144.543 13.203 C 150.174 13.203 154.136 15.872 155.957 20.26 A 15.995 15.995 0 0 1 157.083 26.403 L 157.083 46.203 Z M 196.683 46.203 L 196.023 46.863 L 166.323 46.863 L 165.663 46.203 L 165.663 1.323 L 166.323 0.663 L 174.243 0.663 L 174.903 1.323 L 174.903 38.283 L 175.563 38.943 L 196.023 38.943 L 196.683 39.603 L 196.683 46.203 Z M 233.643 46.203 L 232.983 46.863 L 203.283 46.863 L 202.623 46.203 L 202.623 1.323 L 203.283 0.663 L 211.203 0.663 L 211.863 1.323 L 211.863 38.283 L 212.523 38.943 L 232.983 38.943 L 233.643 39.603 L 233.643 46.203 Z M 61.383 16.503 A 10.855 10.855 0 0 1 65.339 13.985 A 13.327 13.327 0 0 1 69.963 13.203 A 13.467 13.467 0 0 1 77.875 15.729 C 80.198 17.396 82.071 19.843 83.221 22.933 A 21.239 21.239 0 0 1 84.483 30.363 A 24.331 24.331 0 0 1 84.419 32.132 C 84.217 34.909 83.538 37.375 82.493 39.475 A 13.867 13.867 0 0 1 69.963 47.523 A 14.252 14.252 0 0 1 68.838 47.478 C 65.957 47.25 63.076 46.15 61.383 44.223 L 60.723 44.223 L 60.723 59.403 L 60.063 60.063 L 52.143 60.063 L 51.483 59.403 L 51.483 14.523 L 52.143 13.863 L 59.403 13.863 L 60.063 14.523 L 60.723 16.503 L 61.383 16.503 Z M 74.715 34.547 A 15.037 15.037 0 0 0 75.243 30.363 C 75.243 26.238 74.034 22.919 70.988 21.664 A 7.832 7.832 0 0 0 67.983 21.123 C 64.229 21.123 62.143 23.124 61.251 26.179 A 15.037 15.037 0 0 0 60.723 30.363 C 60.723 34.488 61.931 37.807 64.978 39.062 A 7.832 7.832 0 0 0 67.983 39.603 C 71.737 39.603 73.823 37.601 74.715 34.547 Z M 118.803 37.623 A 11.13 11.13 0 0 1 118.53 38.832 C 117.436 42.686 113.876 47.523 104.943 47.523 A 19.831 19.831 0 0 1 99.708 46.862 C 96.245 45.917 93.607 44.011 91.757 41.496 A 18.68 18.68 0 0 1 88.443 30.363 A 23.169 23.169 0 0 1 88.602 27.634 C 89.553 19.616 94.78 13.203 104.283 13.203 A 18.458 18.458 0 0 1 108.27 13.62 C 116.172 15.365 120.123 22.37 120.123 30.363 L 120.123 33.003 L 119.463 33.663 L 99.003 33.663 L 98.343 34.323 A 3.127 3.127 0 0 0 98.402 34.885 C 98.665 36.296 99.879 38.794 103.215 39.444 A 9.017 9.017 0 0 0 104.943 39.603 C 106.923 39.603 108.903 38.943 109.563 37.623 L 110.223 36.963 L 118.143 36.963 L 118.803 37.623 Z M 109.563 27.063 L 110.223 26.403 C 110.223 25.81 109.69 22.015 105.745 21.255 A 7.717 7.717 0 0 0 104.283 21.123 A 7.919 7.919 0 0 0 103.055 21.214 C 98.897 21.866 98.343 25.798 98.343 26.403 L 99.003 27.063 L 109.563 27.063 Z M 44.883 23.763 A 30.343 30.343 0 0 1 44.282 29.875 C 42.882 36.684 39.086 42.045 33.427 44.998 A 23.532 23.532 0 0 1 22.443 47.523 C 8.583 47.523 0.003 37.623 0.003 23.763 A 30.343 30.343 0 0 1 0.604 17.651 C 2.004 10.842 5.8 5.481 11.459 2.528 A 23.532 23.532 0 0 1 22.443 0.003 C 36.303 0.003 44.883 9.903 44.883 23.763 Z M 34.501 31.018 A 21.772 21.772 0 0 0 35.643 23.763 A 22.28 22.28 0 0 0 34.7 17.104 C 33.623 13.675 31.637 10.998 28.802 9.441 A 13.039 13.039 0 0 0 22.443 7.923 C 16.343 7.923 12.245 11.259 10.385 16.508 A 21.772 21.772 0 0 0 9.243 23.763 A 22.28 22.28 0 0 0 10.186 30.422 C 11.263 33.851 13.249 36.528 16.084 38.085 A 13.039 13.039 0 0 0 22.443 39.603 C 28.543 39.603 32.641 36.267 34.501 31.018 Z"
vectorEffect="non-scaling-stroke"
transform="translate(70, 2.5)"
/>
</svg>
<p
style={{
position: 'absolute',
bottom: 70,
left: 80,
margin: 0,
fontSize: 30,
letterSpacing: -1
}}
>
Fine-tune, serve and deploy LLMs in production.
</p>
<h1
style={{
fontSize: 82,
margin: '0 0 40px -2px',
lineHeight: 1.1,
textShadow: '0 2px 30px #000',
letterSpacing: -4,
backgroundImage: 'linear-gradient(90deg, #fff 40%, #aaa)',
backgroundClip: 'text',
'-webkit-background-clip': 'text',
color: 'transparent'
}}
>
{title}
</h1>
</div>
),
{
width: 1200,
height: 630
}
)
}

View File

@@ -0,0 +1,44 @@
{
"index": "Introduction",
"installation": "Installation",
"getting-started": "Getting Started",
"about-link": {
"title": "About OpenLLM",
"href": "/about"
},
"-- Models": {
"type": "separator",
"title": "Supported Models"
},
"supported-models": "Supported Models",
"add-new-model": "Adding a New Model",
"-- Advanced": {
"type": "separator",
"title": "Advanced"
},
"features": {
"display": "hidden",
"title": "Features"
},
"-- API Reference": {
"type": "separator",
"title": "API Reference"
},
"api": {
"display": "hidden"
},
"-- Ecosystem": {
"type": "separator",
"title": "More"
},
"bentocloud": {
"title": "☁️ BentoCloud ↗",
"href": "https://l.bentoml.com/bento-cloud",
"newWindow": true
},
"bentoml": {
"title": "🍱 BentoML ↗",
"href": "https://docs.bentoml.com/en/latest/",
"newWindow": true
}
}

View File

View File

@@ -0,0 +1,3 @@
{
"configuration": "openllm.LLMConfig"
}

View File

View File

View File

@@ -0,0 +1,3 @@
{
"fine-tune": ""
}

View File

View File

@@ -0,0 +1 @@
## Fine-tuning weights

View File

@@ -0,0 +1 @@
## Getting Started

View File

@@ -0,0 +1,3 @@
## OpenLLM
Hello world

View File

View File

@@ -0,0 +1 @@
## Integrations

View File

3
docs/pages/index.mdx Normal file
View File

@@ -0,0 +1,3 @@
---
title: 'OpenLLM - Fine-tune, serve, deploy LLMs in production'
---

9
docs/postcss.config.js Normal file
View File

@@ -0,0 +1,9 @@
// If you want to use other PostCSS plugins, see the following:
// https://tailwindcss.com/docs/using-with-preprocessors
/** @type {import('postcss').Postcss} */
module.exports = {
plugins: {
tailwindcss: {},
autoprefixer: {}
}
}

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.4 KiB

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.7 KiB

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.3 KiB

View File

@@ -0,0 +1,9 @@
<?xml version="1.0" encoding="utf-8"?>
<browserconfig>
<msapplication>
<tile>
<square150x150logo src="/mstile-150x150.png"/>
<TileColor>#00aba9</TileColor>
</tile>
</msapplication>
</browserconfig>

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 507 B

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 640 B

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 15 KiB

View File

@@ -0,0 +1,24 @@
<?xml version="1.0" encoding="UTF-8"?>
<svg id="Layer_2" data-name="Layer 2" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 243.27 100">
<defs>
<style>
.cls-1 {
fill: #fff;
}
</style>
</defs>
<g id="Layer_1-2" data-name="Layer 1">
<g>
<path class="cls-1" d="m243.27,7.5c0-4.13-3.36-7.5-7.5-7.5H25.43c-1.97,0-3.76.76-5.1,2.01h0S1.87,18.18,1.87,18.18c-1.2,1.2-1.87,2.82-1.87,4.51v70.94c0,3.52,2.85,6.37,6.37,6.37h214.07c1.69,0,3.31-.67,4.51-1.87l16.14-18.15h0c1.34-1.36,2.18-3.22,2.18-5.28V7.5Zm-7.5,72.46H25.43c-2.89,0-5.25-2.36-5.25-5.25V7.5c0-1.95,1.07-3.66,2.66-4.56.76-.44,1.65-.69,2.59-.69h210.34c2.89,0,5.25,2.36,5.25,5.25v67.21c0,1.83-.94,3.44-2.37,4.38-.83.55-1.82.87-2.88.87Z"/>
<g>
<path class="cls-1" d="m67.4,53.9h-12.62l-.37-.37v-25.23l.37-.37h11.88c3.71,0,7.42,1.86,7.42,6.68,0,2.63-1.08,4.82-3.71,5.57v.37c2.97.74,4.45,2.89,4.45,6.31,0,5.2-3.71,7.05-7.42,7.05Zm-1.48-21.52h-5.94l-.37.37v5.2l.37.37h5.94c2.23,0,2.97-1.48,2.97-2.97,0-1.89-.74-2.97-2.97-2.97Zm0,10.39h-5.94l-.37.37v5.94l.37.37h5.94c2.67,0,3.71-1.11,3.71-3.34s-1.04-3.34-3.71-3.34Z"/>
<path class="cls-1" d="m95.48,46.48h-11.5l-.37.37c0,.74.74,2.97,3.71,2.97,1.15,0,2.19-.37,2.6-1.11l.37-.37h4.45l.37.37c-.37,2.23-2.23,5.57-7.79,5.57-6.35,0-9.28-4.45-9.28-9.65s2.97-9.65,8.91-9.65,8.91,4.45,8.91,9.65v1.48l-.37.37Zm-8.54-7.05c-2.97,0-3.34,2.56-3.34,2.97l.37.37h5.94l.37-.37c0-.41-.37-2.97-3.34-2.97Z"/>
<path class="cls-1" d="m112.16,53.9l-.37-.37v-10.76c0-1.89-.74-3.34-2.97-3.34-2.67,0-4.08,1.41-4.08,4.82v9.28l-.37.37h-4.45l-.37-.37v-17.81l.37-.37h4.08l.37.37.37,1.11h.37c.71-.71,2.23-1.86,4.82-1.86,4.45,0,7.05,2.97,7.05,7.42v11.13l-.37.37h-4.45Z"/>
<path class="cls-1" d="m129.37,49.45h3.34l.37.37v3.71l-.37.37h-3.34c-3.34,0-6.31-1.52-6.31-5.57v-8.16l-.37-.37h-2.6l-.37-.37v-3.71l.37-.37h2.6l.37-.37v-3.34l.37-.37h4.45l.37.37v3.34l.37.37h4.08l.37.37v3.71l-.37.37h-4.08l-.37.37v8.16c0,.74.37,1.11,1.11,1.11Z"/>
<path class="cls-1" d="m144.79,54.28c-5.53,0-9.28-3.71-9.28-9.65s3.75-9.65,9.28-9.65,9.28,3.71,9.28,9.65-3.75,9.65-9.28,9.65Zm0-14.84c-2.67,0-4.08,1.78-4.08,5.2s1.41,5.2,4.08,5.2,4.08-1.78,4.08-5.2-1.41-5.2-4.08-5.2Z"/>
<path class="cls-1" d="m158.67,28.12h4.75l6.54,18.47c.81,2.26,1.15,3.37,1.15,3.37h.07s.34-1.11,1.15-3.37l6.64-18.47h4.72v25.79h-3.2v-22.15h-.1s-.4,1.32-1.38,4.04l-6.51,18.1h-2.97l-6.34-18.1c-.91-2.7-1.38-4.04-1.38-4.04h-.1v22.15h-3.03v-25.79Z"/>
<path class="cls-1" d="m190.84,28.12h3.13v22.99h12.81v2.8h-15.94v-25.79Z"/>
</g>
</g>
</g>
</svg>

After

Width:  |  Height:  |  Size: 2.5 KiB

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 15 KiB

View File

@@ -0,0 +1,7 @@
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 59.76 60">
<path d="m59.56,3.16c-.11-.35-.26-.69-.45-.99-.23-.37-.5-.71-.82-1-.05-.05-.11-.1-.16-.14-.39-.32-.83-.58-1.31-.76s-1-.27-1.55-.27H14.94c-.09,0-.18,0-.27,0-.03,0-.05,0-.08,0-.07,0-.13.01-.2.02-.03,0-.06,0-.08.01-.08.01-.15.02-.23.04-.01,0-.02,0-.03,0-.09.02-.17.04-.26.06-.02,0-.05.01-.07.02-.06.02-.12.04-.19.06-.03,0-.05.02-.08.03-.07.02-.13.05-.2.08-.02,0-.03.01-.05.02-.08.03-.16.07-.24.11-.02,0-.04.02-.06.03-.06.03-.12.06-.18.09-.02.01-.05.03-.07.04-.06.03-.12.07-.17.11-.02.01-.03.02-.05.03-.07.05-.14.1-.21.15-.01.01-.03.02-.04.03-.06.04-.11.09-.16.13-.02.02-.04.03-.06.05-.05.04-.1.09-.15.13-.02.01-.03.03-.05.04-.03.03-.05.05-.08.08,0,0,0,0,0,0L1.12,10.91c-.72.72-1.12,1.69-1.12,2.7v42.57c0,2.11,1.71,3.82,3.82,3.82h42.57c1.01,0,1.99-.4,2.7-1.12l9.52-11.05c.17-.19.33-.4.47-.62,0,0,.01-.02.02-.02.03-.04.05-.09.08-.13,0-.02.02-.03.03-.05.02-.04.04-.08.06-.12.01-.02.02-.04.03-.07.02-.04.04-.08.05-.12.01-.03.02-.05.03-.08.02-.04.03-.07.05-.11.01-.03.02-.06.03-.09.01-.04.03-.07.04-.11.01-.03.02-.06.03-.09.01-.04.02-.07.03-.11,0-.03.02-.07.03-.1,0-.03.02-.07.03-.1,0-.04.02-.07.02-.11,0-.03.02-.07.02-.1,0-.04.01-.08.02-.12,0-.03.01-.06.02-.1,0-.04.01-.08.02-.13,0-.03,0-.06.01-.09,0-.05,0-.1.01-.14,0-.03,0-.05,0-.08,0-.07,0-.15,0-.22V4.5h0c0-.47-.07-.91-.2-1.34Zm-4.3-1.81c.54,0,1.05.14,1.5.38.22.12.43.27.62.44.04.03.07.07.11.1.07.07.14.15.2.22.06.08.12.16.18.24.34.5.54,1.11.54,1.76v40.33c0,.09,0,.18-.01.27,0,.01,0,.02,0,.03,0,.08-.02.17-.03.25,0,.01,0,.02,0,.04-.02.08-.03.16-.06.24,0,0,0,.02,0,.03-.02.08-.05.16-.08.24,0,0,0,0,0,0-.1.26-.23.5-.38.71h0c-.05.08-.11.15-.17.22-.04.04-.07.08-.11.12,0,0,0,0,0,0-.04.04-.07.08-.11.11,0,0,0,0,0,0-.04.04-.08.07-.12.11,0,0,0,0,0,0-.21.18-.44.33-.7.45,0,0-.01,0-.02,0-.04.02-.09.04-.13.06-.01,0-.02,0-.04.01-.04.02-.08.03-.12.04-.02,0-.03.01-.05.02-.04.01-.07.02-.11.03-.02,0-.04.01-.05.02-.03,0-.07.02-.1.03-.02,0-.04,0-.06.01-.03,0-.07.01-.1.02-.02,0-.04,0-.06.01-.04,0-.07.01-.11.02-.02,0-.04,0-.06,0-.04,0-.08,0-.12.01-.02,0-.03,0-.05,0-.06,0-.11,0-.17,0H14.94c-.87,0-1.66-.35-2.23-.92-.14-.14-.27-.3-.38-.47-.28-.42-.47-.91-.52-1.44-.01-.11-.02-.21-.02-.32V4.5c0-.06,0-.12,0-.18,0-.02,0-.04,0-.06,0-.04,0-.08.01-.12,0-.02,0-.04,0-.06,0-.04.01-.07.02-.11,0-.02,0-.04.01-.06,0-.04.01-.07.02-.11,0-.02,0-.04.01-.06.01-.04.02-.08.03-.12,0-.01,0-.03.01-.04.03-.11.07-.22.12-.32,0,0,0,0,0,0,.02-.05.04-.1.07-.15,0,0,0-.02.01-.02.02-.04.04-.09.07-.13,0,0,0-.02.01-.03.02-.04.05-.08.08-.13,0,0,0-.01.01-.02.03-.05.06-.09.09-.14,0,0,0,0,0,0,.17-.24.38-.45.61-.63.2-.16.42-.29.65-.39,0,0,0,0,.01,0,.07-.03.15-.06.23-.09,0,0,.01,0,.02,0,.15-.05.31-.09.47-.12.01,0,.03,0,.04,0,.08-.01.15-.02.23-.03.01,0,.03,0,.04,0,.08,0,.16-.01.25-.01h40.33Z" fill="currentColor"/>
<g>
<circle class="cls-1" cx="40.54" cy="24.66" r="2.74" fill="currentColor"/>
<circle class="cls-1" cx="29.67" cy="24.66" r="2.74" fill="currentColor"/>
</g>
</svg>

After

Width:  |  Height:  |  Size: 2.9 KiB

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.0 KiB

View File

@@ -0,0 +1,33 @@
<?xml version="1.0" standalone="no"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 20010904//EN"
"http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.dtd">
<svg version="1.0" xmlns="http://www.w3.org/2000/svg"
width="894.000000pt" height="894.000000pt" viewBox="0 0 894.000000 894.000000"
preserveAspectRatio="xMidYMid meet">
<metadata>
Created by potrace 1.14, written by Peter Selinger 2001-2017
</metadata>
<g transform="translate(0.000000,894.000000) scale(0.100000,-0.100000)"
fill="#000000" stroke="none">
<path d="M2110 8925 c-123 -28 -239 -89 -326 -171 -37 -36 -181 -167 -225
-205 -41 -36 -173 -154 -259 -233 -25 -22 -86 -77 -135 -121 -50 -44 -94 -85
-100 -91 -5 -6 -75 -69 -155 -140 -126 -112 -343 -308 -376 -339 -6 -5 -44
-39 -84 -75 -41 -36 -99 -87 -129 -114 -129 -114 -206 -201 -239 -269 -67
-138 -62 135 -61 -3427 0 -3570 -5 -3291 62 -3430 44 -90 160 -206 248 -248
137 -66 -142 -61 3415 -61 2298 -1 3257 2 3300 10 75 14 173 59 236 109 27 21
123 125 214 232 91 106 178 207 193 223 23 25 159 184 237 275 12 14 84 97
160 186 77 88 159 184 184 213 25 30 50 59 55 65 6 6 50 58 100 116 49 58 92
107 95 110 3 3 48 55 100 115 52 61 105 121 118 134 64 67 152 227 168 304 2
10 6 28 11 40 4 12 7 1410 8 3107 1 2370 -2 3100 -11 3151 -38 204 -172 383
-358 473 -165 81 130 74 -3311 74 -2435 0 -3092 -3 -3135 -13z m6290 -214
c154 -53 274 -184 310 -341 11 -44 13 -658 13 -3095 0 -1672 -3 -3062 -7
-3090 -12 -76 -66 -183 -122 -242 -65 -67 -117 -100 -205 -128 l-72 -23 -3061
0 c-3328 0 -3108 -3 -3225 56 -110 55 -211 187 -240 312 -7 30 -11 1039 -11
3100 0 3359 -4 3123 60 3236 72 126 211 219 350 236 14 2 1402 3 3085 2 l3060
-1 65 -22z"/>
<path d="M4362 5664 c-149 -30 -257 -125 -308 -272 -29 -83 -27 -189 5 -272
85 -222 343 -326 558 -225 209 100 292 352 184 562 -79 155 -265 242 -439 207z"/>
<path d="M5980 5664 c-86 -20 -139 -47 -195 -99 -92 -86 -133 -185 -130 -310
11 -406 532 -549 751 -207 137 213 42 501 -196 597 -58 23 -173 33 -230 19z"/>
</g>
</svg>

After

Width:  |  Height:  |  Size: 1.9 KiB

View File

@@ -0,0 +1,19 @@
{
"name": "",
"short_name": "",
"icons": [
{
"src": "/android-chrome-192x192.png",
"sizes": "192x192",
"type": "image/png"
},
{
"src": "/android-chrome-512x512.png",
"sizes": "512x512",
"type": "image/png"
}
],
"theme_color": "#ffffff",
"background_color": "#ffffff",
"display": "standalone"
}

14
docs/public/logo.svg Normal file
View File

@@ -0,0 +1,14 @@
<svg viewBox="0 0 373 60" xmlns="http://www.w3.org/2000/svg" fill="currentColor">
<path d="m59.56,3.16c-.11-.35-.26-.69-.45-.99-.23-.37-.5-.71-.82-1-.05-.05-.11-.1-.16-.14-.39-.32-.83-.58-1.31-.76s-1-.27-1.55-.27H14.94c-.09,0-.18,0-.27,0-.03,0-.05,0-.08,0-.07,0-.13.01-.2.02-.03,0-.06,0-.08.01-.08.01-.15.02-.23.04-.01,0-.02,0-.03,0-.09.02-.17.04-.26.06-.02,0-.05.01-.07.02-.06.02-.12.04-.19.06-.03,0-.05.02-.08.03-.07.02-.13.05-.2.08-.02,0-.03.01-.05.02-.08.03-.16.07-.24.11-.02,0-.04.02-.06.03-.06.03-.12.06-.18.09-.02.01-.05.03-.07.04-.06.03-.12.07-.17.11-.02.01-.03.02-.05.03-.07.05-.14.1-.21.15-.01.01-.03.02-.04.03-.06.04-.11.09-.16.13-.02.02-.04.03-.06.05-.05.04-.1.09-.15.13-.02.01-.03.03-.05.04-.03.03-.05.05-.08.08,0,0,0,0,0,0L1.12,10.91c-.72.72-1.12,1.69-1.12,2.7v42.57c0,2.11,1.71,3.82,3.82,3.82h42.57c1.01,0,1.99-.4,2.7-1.12l9.52-11.05c.17-.19.33-.4.47-.62,0,0,.01-.02.02-.02.03-.04.05-.09.08-.13,0-.02.02-.03.03-.05.02-.04.04-.08.06-.12.01-.02.02-.04.03-.07.02-.04.04-.08.05-.12.01-.03.02-.05.03-.08.02-.04.03-.07.05-.11.01-.03.02-.06.03-.09.01-.04.03-.07.04-.11.01-.03.02-.06.03-.09.01-.04.02-.07.03-.11,0-.03.02-.07.03-.1,0-.03.02-.07.03-.1,0-.04.02-.07.02-.11,0-.03.02-.07.02-.1,0-.04.01-.08.02-.12,0-.03.01-.06.02-.1,0-.04.01-.08.02-.13,0-.03,0-.06.01-.09,0-.05,0-.1.01-.14,0-.03,0-.05,0-.08,0-.07,0-.15,0-.22V4.5h0c0-.47-.07-.91-.2-1.34Zm-4.3-1.81c.54,0,1.05.14,1.5.38.22.12.43.27.62.44.04.03.07.07.11.1.07.07.14.15.2.22.06.08.12.16.18.24.34.5.54,1.11.54,1.76v40.33c0,.09,0,.18-.01.27,0,.01,0,.02,0,.03,0,.08-.02.17-.03.25,0,.01,0,.02,0,.04-.02.08-.03.16-.06.24,0,0,0,.02,0,.03-.02.08-.05.16-.08.24,0,0,0,0,0,0-.1.26-.23.5-.38.71h0c-.05.08-.11.15-.17.22-.04.04-.07.08-.11.12,0,0,0,0,0,0-.04.04-.07.08-.11.11,0,0,0,0,0,0-.04.04-.08.07-.12.11,0,0,0,0,0,0-.21.18-.44.33-.7.45,0,0-.01,0-.02,0-.04.02-.09.04-.13.06-.01,0-.02,0-.04.01-.04.02-.08.03-.12.04-.02,0-.03.01-.05.02-.04.01-.07.02-.11.03-.02,0-.04.01-.05.02-.03,0-.07.02-.1.03-.02,0-.04,0-.06.01-.03,0-.07.01-.1.02-.02,0-.04,0-.06.01-.04,0-.07.01-.11.02-.02,0-.04,0-.06,0-.04,0-.08,0-.12.01-.02,0-.03,0-.05,0-.06,0-.11,0-.17,0H14.94c-.87,0-1.66-.35-2.23-.92-.14-.14-.27-.3-.38-.47-.28-.42-.47-.91-.52-1.44-.01-.11-.02-.21-.02-.32V4.5c0-.06,0-.12,0-.18,0-.02,0-.04,0-.06,0-.04,0-.08.01-.12,0-.02,0-.04,0-.06,0-.04.01-.07.02-.11,0-.02,0-.04.01-.06,0-.04.01-.07.02-.11,0-.02,0-.04.01-.06.01-.04.02-.08.03-.12,0-.01,0-.03.01-.04.03-.11.07-.22.12-.32,0,0,0,0,0,0,.02-.05.04-.1.07-.15,0,0,0-.02.01-.02.02-.04.04-.09.07-.13,0,0,0-.02.01-.03.02-.04.05-.08.08-.13,0,0,0-.01.01-.02.03-.05.06-.09.09-.14,0,0,0,0,0,0,.17-.24.38-.45.61-.63.2-.16.42-.29.65-.39,0,0,0,0,.01,0,.07-.03.15-.06.23-.09,0,0,.01,0,.02,0,.15-.05.31-.09.47-.12.01,0,.03,0,.04,0,.08-.01.15-.02.23-.03.01,0,.03,0,.04,0,.08,0,.16-.01.25-.01h40.33Z" />
<g>
<circle cx="40.54" cy="24.66" r="2.74" />
<circle cx="29.67" cy="24.66" r="2.74" />
</g>
<path
d="M 277.203 46.203 L 276.543 46.863 L 271.263 46.863 L 270.603 46.203 L 270.603 14.523 L 269.943 14.523 L 256.743 46.203 L 256.083 46.863 L 250.143 46.863 L 249.483 46.203 L 236.283 14.523 L 235.623 14.523 L 235.623 46.203 L 234.963 46.863 L 229.683 46.863 L 229.023 46.203 L 229.023 1.323 L 229.683 0.663 L 236.943 0.663 L 237.603 1.323 L 252.783 38.283 L 253.443 38.283 L 268.623 1.323 L 269.283 0.663 L 276.543 0.663 L 277.203 1.323 L 277.203 46.203 Z M 149.163 46.203 L 148.503 46.863 L 143.223 46.863 L 142.563 46.203 L 142.563 27.063 C 142.563 24.156 142.071 20.363 138.11 19.382 A 8.93 8.93 0 0 0 135.963 19.143 C 131.036 19.143 128.419 21.319 127.638 26.51 A 26.058 26.058 0 0 0 127.383 30.363 L 127.383 46.203 L 126.723 46.863 L 121.443 46.863 L 120.783 46.203 L 120.783 14.523 L 121.443 13.863 L 126.063 13.863 L 126.723 14.523 L 127.383 17.163 L 128.043 17.163 A 9.62 9.62 0 0 1 131.066 14.582 A 11.514 11.514 0 0 1 136.623 13.203 A 16.563 16.563 0 0 1 140.917 13.721 C 146.911 15.328 149.163 20.52 149.163 27.063 L 149.163 46.203 Z M 113.523 37.623 A 10.534 10.534 0 0 1 110.493 43.788 C 109.205 45.077 107.529 46.115 105.488 46.766 A 16.942 16.942 0 0 1 100.323 47.523 C 93.105 47.523 88.353 44.13 86.069 38.821 A 21.4 21.4 0 0 1 84.483 30.363 A 25.097 25.097 0 0 1 84.83 26.131 C 86.082 18.83 90.762 13.203 99.663 13.203 A 17.952 17.952 0 0 1 103.701 13.639 C 107.917 14.61 110.854 17.138 112.65 20.533 A 21.076 21.076 0 0 1 114.843 30.363 L 114.843 32.343 L 114.183 33.003 L 92.403 33.003 L 91.743 33.663 A 5.259 5.259 0 0 0 91.749 33.899 C 91.819 35.446 92.605 40.378 98.162 41.398 A 11.967 11.967 0 0 0 100.323 41.583 C 102.386 41.583 104.448 41.18 105.881 39.43 A 6.823 6.823 0 0 0 106.923 37.623 L 107.583 36.963 L 112.863 36.963 L 113.523 37.623 Z M 106.923 27.723 L 107.583 27.063 C 107.583 25.297 107.058 20.378 101.789 19.338 A 10.968 10.968 0 0 0 99.663 19.143 A 11.608 11.608 0 0 0 98.143 19.239 C 93.018 19.916 91.959 24.027 91.777 26.259 A 9.964 9.964 0 0 0 91.743 27.063 L 92.403 27.723 L 106.923 27.723 Z M 187.443 46.203 L 186.783 46.863 L 158.403 46.863 L 157.743 46.203 L 157.743 1.323 L 158.403 0.663 L 163.683 0.663 L 164.343 1.323 L 164.343 40.263 L 165.003 40.923 L 186.783 40.923 L 187.443 41.583 L 187.443 46.203 Z M 223.083 46.203 L 222.423 46.863 L 194.043 46.863 L 193.383 46.203 L 193.383 1.323 L 194.043 0.663 L 199.323 0.663 L 199.983 1.323 L 199.983 40.263 L 200.643 40.923 L 222.423 40.923 L 223.083 41.583 L 223.083 46.203 Z M 57.423 17.163 A 9.62 9.62 0 0 1 60.446 14.582 A 11.514 11.514 0 0 1 66.003 13.203 A 16.933 16.933 0 0 1 67.185 13.244 C 75.692 13.839 80.523 20.893 80.523 30.363 C 80.523 40.263 75.243 47.523 66.003 47.523 A 13.102 13.102 0 0 1 65.404 47.509 C 62.739 47.387 60.76 46.465 59.469 45.543 C 58.677 44.949 58.017 44.289 57.423 43.563 L 56.763 43.563 L 56.763 59.403 L 56.103 60.063 L 50.823 60.063 L 50.163 59.403 L 50.163 14.523 L 50.823 13.863 L 55.443 13.863 L 56.103 14.523 L 56.763 17.163 L 57.423 17.163 Z M 73.495 34.537 A 18.852 18.852 0 0 0 73.923 30.363 C 73.923 27.559 73.44 25.257 72.547 23.484 A 7.597 7.597 0 0 0 65.343 19.143 C 60.063 19.143 56.763 22.443 56.763 30.363 A 22.943 22.943 0 0 0 56.951 33.405 C 57.72 39.138 60.798 41.583 65.343 41.583 A 7.579 7.579 0 0 0 71.926 38.294 C 72.628 37.272 73.158 36.017 73.495 34.537 Z M 18.324 47.305 C 6.613 45.782 0.003 36.425 0.003 23.763 C 0.003 13.747 4.139 5.799 11.664 2.161 A 23.046 23.046 0 0 1 21.783 0.003 A 26.817 26.817 0 0 1 25.242 0.221 C 36.953 1.744 43.563 11.101 43.563 23.763 C 43.563 33.779 39.427 41.727 31.902 45.365 A 23.046 23.046 0 0 1 21.783 47.523 A 26.817 26.817 0 0 1 18.324 47.305 Z M 7.808 15.823 A 24.607 24.607 0 0 0 6.603 23.763 A 25.23 25.23 0 0 0 7.586 31.014 C 8.831 35.154 11.245 38.312 14.755 40.057 A 15.628 15.628 0 0 0 21.783 41.583 C 28.938 41.583 33.679 37.792 35.759 31.703 A 24.607 24.607 0 0 0 36.963 23.763 A 25.23 25.23 0 0 0 35.98 16.512 C 34.736 12.373 32.322 9.214 28.812 7.469 A 15.628 15.628 0 0 0 21.783 5.943 C 14.629 5.943 9.887 9.734 7.808 15.823 Z"
vectorEffect="non-scaling-stroke"
stroke="currentColor"
strokeWidth="0.05"
transform="translate(80, 2.5)"
/>
</svg>

After

Width:  |  Height:  |  Size: 6.9 KiB

BIN
docs/public/og.png Normal file
View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 27 KiB

9
docs/tailwind.config.js Normal file
View File

@@ -0,0 +1,9 @@
/** @type {import('tailwindcss').Config} */
module.exports = {
content: ['./pages/**/*.{js,ts,jsx,tsx,mdx}', './components/**/*.{js,ts,jsx,tsx}', './theme.config.tsx'],
theme: {
extend: {}
},
plugins: [],
darkMode: 'class'
}

132
docs/theme.config.tsx Normal file
View File

@@ -0,0 +1,132 @@
import React from 'react'
import { useRouter } from 'next/router'
import { useConfig } from 'nextra-theme-docs'
import type { DocsThemeConfig } from 'nextra-theme-docs'
const openllmUrl = 'https://openllm.community'
const logo = (
<span>
<svg height="20" viewBox="0 0 373 60" xmlns="http://www.w3.org/2000/svg" fill="currentColor">
<path d="m59.56,3.16c-.11-.35-.26-.69-.45-.99-.23-.37-.5-.71-.82-1-.05-.05-.11-.1-.16-.14-.39-.32-.83-.58-1.31-.76s-1-.27-1.55-.27H14.94c-.09,0-.18,0-.27,0-.03,0-.05,0-.08,0-.07,0-.13.01-.2.02-.03,0-.06,0-.08.01-.08.01-.15.02-.23.04-.01,0-.02,0-.03,0-.09.02-.17.04-.26.06-.02,0-.05.01-.07.02-.06.02-.12.04-.19.06-.03,0-.05.02-.08.03-.07.02-.13.05-.2.08-.02,0-.03.01-.05.02-.08.03-.16.07-.24.11-.02,0-.04.02-.06.03-.06.03-.12.06-.18.09-.02.01-.05.03-.07.04-.06.03-.12.07-.17.11-.02.01-.03.02-.05.03-.07.05-.14.1-.21.15-.01.01-.03.02-.04.03-.06.04-.11.09-.16.13-.02.02-.04.03-.06.05-.05.04-.1.09-.15.13-.02.01-.03.03-.05.04-.03.03-.05.05-.08.08,0,0,0,0,0,0L1.12,10.91c-.72.72-1.12,1.69-1.12,2.7v42.57c0,2.11,1.71,3.82,3.82,3.82h42.57c1.01,0,1.99-.4,2.7-1.12l9.52-11.05c.17-.19.33-.4.47-.62,0,0,.01-.02.02-.02.03-.04.05-.09.08-.13,0-.02.02-.03.03-.05.02-.04.04-.08.06-.12.01-.02.02-.04.03-.07.02-.04.04-.08.05-.12.01-.03.02-.05.03-.08.02-.04.03-.07.05-.11.01-.03.02-.06.03-.09.01-.04.03-.07.04-.11.01-.03.02-.06.03-.09.01-.04.02-.07.03-.11,0-.03.02-.07.03-.1,0-.03.02-.07.03-.1,0-.04.02-.07.02-.11,0-.03.02-.07.02-.1,0-.04.01-.08.02-.12,0-.03.01-.06.02-.1,0-.04.01-.08.02-.13,0-.03,0-.06.01-.09,0-.05,0-.1.01-.14,0-.03,0-.05,0-.08,0-.07,0-.15,0-.22V4.5h0c0-.47-.07-.91-.2-1.34Zm-4.3-1.81c.54,0,1.05.14,1.5.38.22.12.43.27.62.44.04.03.07.07.11.1.07.07.14.15.2.22.06.08.12.16.18.24.34.5.54,1.11.54,1.76v40.33c0,.09,0,.18-.01.27,0,.01,0,.02,0,.03,0,.08-.02.17-.03.25,0,.01,0,.02,0,.04-.02.08-.03.16-.06.24,0,0,0,.02,0,.03-.02.08-.05.16-.08.24,0,0,0,0,0,0-.1.26-.23.5-.38.71h0c-.05.08-.11.15-.17.22-.04.04-.07.08-.11.12,0,0,0,0,0,0-.04.04-.07.08-.11.11,0,0,0,0,0,0-.04.04-.08.07-.12.11,0,0,0,0,0,0-.21.18-.44.33-.7.45,0,0-.01,0-.02,0-.04.02-.09.04-.13.06-.01,0-.02,0-.04.01-.04.02-.08.03-.12.04-.02,0-.03.01-.05.02-.04.01-.07.02-.11.03-.02,0-.04.01-.05.02-.03,0-.07.02-.1.03-.02,0-.04,0-.06.01-.03,0-.07.01-.1.02-.02,0-.04,0-.06.01-.04,0-.07.01-.11.02-.02,0-.04,0-.06,0-.04,0-.08,0-.12.01-.02,0-.03,0-.05,0-.06,0-.11,0-.17,0H14.94c-.87,0-1.66-.35-2.23-.92-.14-.14-.27-.3-.38-.47-.28-.42-.47-.91-.52-1.44-.01-.11-.02-.21-.02-.32V4.5c0-.06,0-.12,0-.18,0-.02,0-.04,0-.06,0-.04,0-.08.01-.12,0-.02,0-.04,0-.06,0-.04.01-.07.02-.11,0-.02,0-.04.01-.06,0-.04.01-.07.02-.11,0-.02,0-.04.01-.06.01-.04.02-.08.03-.12,0-.01,0-.03.01-.04.03-.11.07-.22.12-.32,0,0,0,0,0,0,.02-.05.04-.1.07-.15,0,0,0-.02.01-.02.02-.04.04-.09.07-.13,0,0,0-.02.01-.03.02-.04.05-.08.08-.13,0,0,0-.01.01-.02.03-.05.06-.09.09-.14,0,0,0,0,0,0,.17-.24.38-.45.61-.63.2-.16.42-.29.65-.39,0,0,0,0,.01,0,.07-.03.15-.06.23-.09,0,0,.01,0,.02,0,.15-.05.31-.09.47-.12.01,0,.03,0,.04,0,.08-.01.15-.02.23-.03.01,0,.03,0,.04,0,.08,0,.16-.01.25-.01h40.33Z" />
<g>
<circle cx="40.54" cy="24.66" r="2.74" />
<circle cx="29.67" cy="24.66" r="2.74" />
</g>
<path
d="M 277.203 46.203 L 276.543 46.863 L 271.263 46.863 L 270.603 46.203 L 270.603 14.523 L 269.943 14.523 L 256.743 46.203 L 256.083 46.863 L 250.143 46.863 L 249.483 46.203 L 236.283 14.523 L 235.623 14.523 L 235.623 46.203 L 234.963 46.863 L 229.683 46.863 L 229.023 46.203 L 229.023 1.323 L 229.683 0.663 L 236.943 0.663 L 237.603 1.323 L 252.783 38.283 L 253.443 38.283 L 268.623 1.323 L 269.283 0.663 L 276.543 0.663 L 277.203 1.323 L 277.203 46.203 Z M 149.163 46.203 L 148.503 46.863 L 143.223 46.863 L 142.563 46.203 L 142.563 27.063 C 142.563 24.156 142.071 20.363 138.11 19.382 A 8.93 8.93 0 0 0 135.963 19.143 C 131.036 19.143 128.419 21.319 127.638 26.51 A 26.058 26.058 0 0 0 127.383 30.363 L 127.383 46.203 L 126.723 46.863 L 121.443 46.863 L 120.783 46.203 L 120.783 14.523 L 121.443 13.863 L 126.063 13.863 L 126.723 14.523 L 127.383 17.163 L 128.043 17.163 A 9.62 9.62 0 0 1 131.066 14.582 A 11.514 11.514 0 0 1 136.623 13.203 A 16.563 16.563 0 0 1 140.917 13.721 C 146.911 15.328 149.163 20.52 149.163 27.063 L 149.163 46.203 Z M 113.523 37.623 A 10.534 10.534 0 0 1 110.493 43.788 C 109.205 45.077 107.529 46.115 105.488 46.766 A 16.942 16.942 0 0 1 100.323 47.523 C 93.105 47.523 88.353 44.13 86.069 38.821 A 21.4 21.4 0 0 1 84.483 30.363 A 25.097 25.097 0 0 1 84.83 26.131 C 86.082 18.83 90.762 13.203 99.663 13.203 A 17.952 17.952 0 0 1 103.701 13.639 C 107.917 14.61 110.854 17.138 112.65 20.533 A 21.076 21.076 0 0 1 114.843 30.363 L 114.843 32.343 L 114.183 33.003 L 92.403 33.003 L 91.743 33.663 A 5.259 5.259 0 0 0 91.749 33.899 C 91.819 35.446 92.605 40.378 98.162 41.398 A 11.967 11.967 0 0 0 100.323 41.583 C 102.386 41.583 104.448 41.18 105.881 39.43 A 6.823 6.823 0 0 0 106.923 37.623 L 107.583 36.963 L 112.863 36.963 L 113.523 37.623 Z M 106.923 27.723 L 107.583 27.063 C 107.583 25.297 107.058 20.378 101.789 19.338 A 10.968 10.968 0 0 0 99.663 19.143 A 11.608 11.608 0 0 0 98.143 19.239 C 93.018 19.916 91.959 24.027 91.777 26.259 A 9.964 9.964 0 0 0 91.743 27.063 L 92.403 27.723 L 106.923 27.723 Z M 187.443 46.203 L 186.783 46.863 L 158.403 46.863 L 157.743 46.203 L 157.743 1.323 L 158.403 0.663 L 163.683 0.663 L 164.343 1.323 L 164.343 40.263 L 165.003 40.923 L 186.783 40.923 L 187.443 41.583 L 187.443 46.203 Z M 223.083 46.203 L 222.423 46.863 L 194.043 46.863 L 193.383 46.203 L 193.383 1.323 L 194.043 0.663 L 199.323 0.663 L 199.983 1.323 L 199.983 40.263 L 200.643 40.923 L 222.423 40.923 L 223.083 41.583 L 223.083 46.203 Z M 57.423 17.163 A 9.62 9.62 0 0 1 60.446 14.582 A 11.514 11.514 0 0 1 66.003 13.203 A 16.933 16.933 0 0 1 67.185 13.244 C 75.692 13.839 80.523 20.893 80.523 30.363 C 80.523 40.263 75.243 47.523 66.003 47.523 A 13.102 13.102 0 0 1 65.404 47.509 C 62.739 47.387 60.76 46.465 59.469 45.543 C 58.677 44.949 58.017 44.289 57.423 43.563 L 56.763 43.563 L 56.763 59.403 L 56.103 60.063 L 50.823 60.063 L 50.163 59.403 L 50.163 14.523 L 50.823 13.863 L 55.443 13.863 L 56.103 14.523 L 56.763 17.163 L 57.423 17.163 Z M 73.495 34.537 A 18.852 18.852 0 0 0 73.923 30.363 C 73.923 27.559 73.44 25.257 72.547 23.484 A 7.597 7.597 0 0 0 65.343 19.143 C 60.063 19.143 56.763 22.443 56.763 30.363 A 22.943 22.943 0 0 0 56.951 33.405 C 57.72 39.138 60.798 41.583 65.343 41.583 A 7.579 7.579 0 0 0 71.926 38.294 C 72.628 37.272 73.158 36.017 73.495 34.537 Z M 18.324 47.305 C 6.613 45.782 0.003 36.425 0.003 23.763 C 0.003 13.747 4.139 5.799 11.664 2.161 A 23.046 23.046 0 0 1 21.783 0.003 A 26.817 26.817 0 0 1 25.242 0.221 C 36.953 1.744 43.563 11.101 43.563 23.763 C 43.563 33.779 39.427 41.727 31.902 45.365 A 23.046 23.046 0 0 1 21.783 47.523 A 26.817 26.817 0 0 1 18.324 47.305 Z M 7.808 15.823 A 24.607 24.607 0 0 0 6.603 23.763 A 25.23 25.23 0 0 0 7.586 31.014 C 8.831 35.154 11.245 38.312 14.755 40.057 A 15.628 15.628 0 0 0 21.783 41.583 C 28.938 41.583 33.679 37.792 35.759 31.703 A 24.607 24.607 0 0 0 36.963 23.763 A 25.23 25.23 0 0 0 35.98 16.512 C 34.736 12.373 32.322 9.214 28.812 7.469 A 15.628 15.628 0 0 0 21.783 5.943 C 14.629 5.943 9.887 9.734 7.808 15.823 Z"
vectorEffect="non-scaling-stroke"
stroke="currentColor"
strokeWidth="0.25"
transform="translate(80, 2.5)"
/>
</svg>
</span>
)
const theme: DocsThemeConfig = {
project: {
link: 'https://github.com/bentoml/OpenLLM'
},
editLink: { text: 'Edit this page on GitHub →' },
feedback: { content: 'Question? Send us your feedback →', labels: 'feedback' },
docsRepositoryBase: 'https://github.com/bentoml/OpenLLM/tree/main/docs',
chat: {
link: 'https://l.bentoml.com/join-openllm-discord'
},
logo,
head: function useHead() {
const { frontMatter, title } = useConfig()
// TODO: support locale
// https://nextjs.org/docs/pages/api-reference/functions/use-router
const { route } = useRouter()
const socialCard = route === '/' || !title ? `${openllmUrl}/og.png` : `${openllmUrl}/api/og?title=${title}`
const ogDescription = frontMatter.description || 'Fine-tune, serve and deploy LLMs in production'
return (
<>
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<meta httpEquiv="Content-Language" content="en" />
<meta name="description" content={ogDescription} />
<meta name="twitter:card" content="summary_large_image" />
<meta name="twitter:image" content={socialCard} />
<meta name="twitter:site:domain" content="openllm.community" />
<meta name="twitter:url" content="https://openllm.community" />
<meta name="og:title" content={title ? title + ' | OpenLLM' : 'OpenLLM'} />
<meta name="og:image" content={socialCard} />
<meta name="og:description" content={ogDescription} />
<meta name="apple-mobile-web-app-title" content="OpenLLM" />
<link rel="apple-touch-icon" sizes="180x180" href="/favicon/apple-touch-icon.png" />
<link rel="icon" type="image/png" sizes="32x32" href="/favicon/favicon-32x32.png" />
<link rel="icon" type="image/png" sizes="16x16" href="/favicon/favicon-16x16.png" />
<link rel="icon" type="image/svg+xml" href="/favicon/favicon.svg" />
<link rel="icon" type="image/x-icon" href="/favicon/favicon.ico" />
<link rel="icon" href="/favicon/favicon-dark.svg" type="image/svg+xml" media="(prefers-color-scheme: dark)" />
<link rel="icon" href="/favicon/favicon-dark.ico" type="image/x-icon" media="(prefers-color-scheme: dark)" />
<link rel="android-chrome" type="image/png" sizes="192x192" href="/favicon/android-chrome-192x192.png" />
<link rel="android-chrome" type="image/png" sizes="512x512" href="/favicon/android-chrome-512x512.png" />
<link rel="manifest" href="/favicon/site.webmanifest" />
<link rel="mask-icon" href="/favicon/safari-pinned-tab.svg" color="#000000" />
<meta name="msapplication-config" content="/favicon/browserconfig.xml" />
<meta name="msapplication-square150x150logo" content="/favicon/mstile-150x150.png" />
<meta name="msapplication-TileColor" content="#ffffff" />
</>
)
},
search: {
placeholder: 'Search website...'
},
toc: {
float: true
},
sidebar: {
titleComponent({ title, type }) {
if (type === 'separator') {
return <span className="cursor-default">{title}</span>
}
return <>{title}</>
},
defaultMenuCollapseLevel: 1,
toggleButton: true
},
gitTimestamp({ timestamp }) {
const { locale } = useRouter()
return (
<>
'last updated on '
<time dateTime={timestamp.toISOString()}>
{timestamp.toLocaleDateString(locale, {
day: 'numeric',
month: 'long',
year: 'numeric'
})}
</time>
</>
)
},
useNextSeoProps() {
const { asPath } = useRouter()
if (['/', '/docs'].includes(asPath)) {
return { titleTemplate: 'OpenLLM' }
}
return { titleTemplate: `%s | OpenLLM` }
},
footer: {
text: (
<div className="flex w-full items-center justify-between">
<div>© {new Date().getFullYear()} OpenLLM project</div>
<a href="https://vercel.com?utm_source=openllm" target="_blank" rel="noopener noreferrer">
<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 212 44" className="h-8" width="212">
<rect width="212" height="44" fill="#000" rx="8"></rect>
<path
fill="#fff"
d="M60.438 15.227V26.5h1.406v-4.023h2.836c2.117 0 3.625-1.493 3.625-3.602 0-2.148-1.477-3.648-3.61-3.648h-4.257zm1.406 1.25h2.484c1.633 0 2.531.851 2.531 2.398 0 1.492-.93 2.352-2.53 2.352h-2.485v-4.75zm11.5 10.171c2.399 0 3.883-1.656 3.883-4.359 0-2.71-1.484-4.36-3.883-4.36-2.398 0-3.883 1.65-3.883 4.36 0 2.703 1.485 4.36 3.883 4.36zm0-1.21c-1.594 0-2.492-1.157-2.492-3.149 0-2 .898-3.148 2.492-3.148 1.594 0 2.492 1.148 2.492 3.148 0 1.992-.898 3.148-2.492 3.148zm15.954-7.36h-1.352l-1.656 6.735h-.125l-1.883-6.735h-1.29l-1.882 6.735h-.125l-1.656-6.735h-1.36l2.36 8.422h1.36l1.874-6.516h.125l1.883 6.516h1.367l2.36-8.422zm4.523 1.04c1.336 0 2.227.984 2.258 2.476h-4.64c.101-1.492 1.039-2.477 2.382-2.477zm2.219 5.202c-.352.742-1.086 1.14-2.172 1.14-1.43 0-2.36-1.054-2.43-2.718v-.062h6.055v-.516c0-2.617-1.383-4.234-3.656-4.234-2.313 0-3.797 1.718-3.797 4.367 0 2.664 1.46 4.351 3.797 4.351 1.844 0 3.156-.89 3.547-2.328H96.04zm3.242 2.18h1.344v-5.219c0-1.187.93-2.047 2.211-2.047.266 0 .75.047.86.078V17.97a5.77 5.77 0 00-.672-.04c-1.117 0-2.086.579-2.336 1.4h-.125v-1.25h-1.281V26.5zm8.899-7.383c1.336 0 2.227.985 2.258 2.477h-4.641c.102-1.492 1.04-2.477 2.383-2.477zm2.219 5.203c-.352.742-1.086 1.14-2.172 1.14-1.43 0-2.359-1.054-2.43-2.718v-.062h6.055v-.516c0-2.617-1.383-4.234-3.656-4.234-2.313 0-3.797 1.718-3.797 4.367 0 2.664 1.461 4.351 3.797 4.351 1.844 0 3.156-.89 3.547-2.328H110.4zm6.36 2.328c1.164 0 2.164-.554 2.695-1.492h.125V26.5h1.281V14.734h-1.343v4.672h-.118c-.476-.922-1.468-1.476-2.64-1.476-2.141 0-3.539 1.718-3.539 4.36 0 2.648 1.382 4.358 3.539 4.358zm.312-7.507c1.524 0 2.477 1.218 2.477 3.148 0 1.945-.946 3.148-2.477 3.148-1.539 0-2.461-1.18-2.461-3.148 0-1.96.93-3.148 2.461-3.148zm14.462 7.507c2.133 0 3.531-1.726 3.531-4.359 0-2.648-1.391-4.36-3.531-4.36-1.156 0-2.18.571-2.641 1.477h-.125v-4.672h-1.344V26.5h1.282v-1.344h.125c.531.938 1.531 1.492 2.703 1.492zm-.313-7.507c1.539 0 2.453 1.18 2.453 3.148 0 1.969-.914 3.148-2.453 3.148-1.531 0-2.484-1.203-2.484-3.148s.953-3.148 2.484-3.148zm6.04 10.406c1.492 0 2.164-.578 2.882-2.531l3.29-8.938h-1.43l-2.305 6.93h-.125l-2.312-6.93h-1.453l3.117 8.43-.157.5c-.351 1.015-.773 1.383-1.546 1.383-.188 0-.399-.008-.563-.04V29.5c.188.031.422.047.602.047zm17.391-3.047l3.898-11.273h-2.148l-2.813 8.921h-.132l-2.836-8.921h-2.227l3.938 11.273h2.32zm8.016-7.18c1.164 0 1.93.813 1.969 2.078h-4.024c.086-1.25.899-2.078 2.055-2.078zm1.984 4.828c-.281.633-.945.985-1.906.985-1.273 0-2.094-.89-2.141-2.313v-.101h5.969v-.625c0-2.696-1.461-4.313-3.898-4.313-2.477 0-4.016 1.727-4.016 4.477s1.516 4.414 4.031 4.414c2.016 0 3.446-.969 3.797-2.524h-1.836zm3.547 2.352h1.938v-4.938c0-1.195.875-1.976 2.133-1.976.328 0 .843.055.992.11v-1.798c-.18-.054-.524-.085-.805-.085-1.101 0-2.023.625-2.258 1.468h-.132v-1.328h-1.868V26.5zm13.501-5.672c-.203-1.797-1.532-3.047-3.727-3.047-2.57 0-4.078 1.649-4.078 4.422 0 2.813 1.516 4.469 4.086 4.469 2.164 0 3.508-1.203 3.719-2.992h-1.844c-.203.89-.875 1.367-1.883 1.367-1.32 0-2.117-1.047-2.117-2.844 0-1.773.789-2.797 2.117-2.797 1.063 0 1.703.594 1.883 1.422h1.844zm5.117-1.508c1.164 0 1.93.813 1.969 2.078h-4.024c.086-1.25.899-2.078 2.055-2.078zm1.985 4.828c-.282.633-.946.985-1.907.985-1.273 0-2.093-.89-2.14-2.313v-.101h5.968v-.625c0-2.696-1.461-4.313-3.898-4.313-2.477 0-4.016 1.727-4.016 4.477s1.516 4.414 4.032 4.414c2.015 0 3.445-.969 3.796-2.524h-1.835zm3.625 2.352h1.937V14.648h-1.937V26.5zM23.325 13l9.325 16H14l9.325-16z"
></path>
<path stroke="#5E5E5E" d="M43.5 0v44"></path>
</svg>
</a>
</div>
)
}
}
export default theme

13
docs/tsconfig.json Normal file
View File

@@ -0,0 +1,13 @@
{
"extends": "../tsconfig.json",
"compilerOptions": {
"baseUrl": ".",
"paths": {
"@components/*": ["components/*"],
"react": ["./node_modules/@types/react"],
"react-dom": ["./node_modules/@types/react-dom"]
}
},
"include": ["next-env.d.ts", "**/*.ts", "**/*.tsx"],
"exclude": ["node_modules"]
}

View File

@@ -1,6 +1,6 @@
service: "service:svc"
service: 'service:svc'
include:
- "*.py"
- '*.py'
python:
packages:
- openllm
packages:
- openllm

View File

@@ -10,10 +10,6 @@ llm_runner = openllm.Runner(model, llm_config=llm_config)
svc = bentoml.Service(name="llm-service", runners=[llm_runner])
@svc.on_startup
def download(_: bentoml.Context):
llm_runner.download_model()
@svc.api(input=bentoml.io.Text(), output=bentoml.io.Text())
async def prompt(input_text: str) -> str:
answer = await llm_runner.generate.async_run(input_text)

View File

@@ -1,13 +1,14 @@
# LangChain + BentoML + OpenLLM
Run it locally:
```bash
export BENTOML_CONFIG_OPTIONS="api_server.traffic.timeout=900 runners.traffic.timeout=900"
bentoml serve
```
Build Bento:
```bash
bentoml build
```

View File

@@ -12,8 +12,8 @@
# See the License for the specific language governing permissions and
# limitations under the License.
service: "service:svc"
service: 'service:svc'
include:
- "*.py"
- '*.py'
python:
requirements_txt: ./requirements.txt

View File

@@ -1,7 +1,7 @@
# LangChain + BentoML + OpenLLM
Run it locally:
```bash
export SERPAPI_API_KEY="__Your_SERP_API_key__"
export BENTOML_CONFIG_OPTIONS="api_server.traffic.timeout=900 runners.traffic.timeout=900"
@@ -9,6 +9,7 @@ bentoml serve
```
Build Bento:
```bash
bentoml build
```

View File

@@ -1,5 +1,5 @@
service: "service:svc"
service: 'service:svc'
include:
- "*.py"
- '*.py'
python:
requirements_txt: "./requirements.txt"
requirements_txt: './requirements.txt'

View File

@@ -33,6 +33,7 @@ quality = [
"check-stubs",
"bash ./tools/mirror.sh",
"- pre-commit run --all-files",
"- pnpm format",
]
setup = [
"pre-commit install",
@@ -89,6 +90,7 @@ write-summary-report = "python tools/write-coverage-report.py"
detached = true
[envs.ui.scripts]
server = "openllm start {args:flan-t5} --working-dir {root:uri} --cors --debug"
docs = "cd docs && pnpm dev"
clojure = ["bash openllm-contrib/clojure/run-clojure-ui.sh"]
[envs.ci]
detached = true

View File

@@ -4,14 +4,13 @@
<i></i>
</div>
<img width="2880" alt="Screenshot 2023-08-16 at 03 34 34" src="https://github.com/bentoml/OpenLLM/assets/29749331/e0204483-7dc5-4694-be86-6ab554e7f992">
<br/>
## Installation
## Installation
The recommended way to run this UI is via the docker container:
The recommended way to run this UI is via the docker container:
```bash
docker run --rm -p 8420:80 ghcr.io/bentoml/openllm-ui-clojure:0.2.25
@@ -32,26 +31,26 @@ hatch run ui:clojure
Access the UI at http://localhost:8420
### Connecting a REPL
The REPL is the most important tool for developing Clojure applications.
It is highly recommended to use *Visual Studio Code* + *Calva* for development of this project. Being able to evaluate code directly in the editor is a huge productivity boost and rich comments not only are an excellent way to document code, there are also a lot of useful ones in this codebase, i.e. for clearing persistent storage, dispatching various events and more.
It is highly recommended to use _Visual Studio Code_ + _Calva_ for development of this project. Being able to evaluate code directly in the editor is a huge productivity boost and rich comments not only are an excellent way to document code, there are also a lot of useful ones in this codebase, i.e. for clearing persistent storage, dispatching various events and more.
That being said, if you prefer to use a different editor, the information on how to connect a REPL to the running shadow-cljs instance can be found in the [REPL section](https://shadow-cljs.github.io/docs/UsersGuide.html#_repl_2) of the shadow-cljs documentation. The nREPL port is printed to the console when starting the watch build and can also be found in the `.shadow-cljs/nrepl.port` file.
### VS Code + Calva:
To connect a REPL to the running shadow-cljs instance using *VS Code* + *Calva*, open the command palette (`Ctrl+Shift+P`) and search for "Calva: Connect to a running REPL server in the project" or use the shortcut `Ctrl+Shift+C & Ctrl+Shift+C`.
To connect a REPL to the running shadow-cljs instance using _VS Code_ + _Calva_, open the command palette (`Ctrl+Shift+P`) and search for "Calva: Connect to a running REPL server in the project" or use the shortcut `Ctrl+Shift+C & Ctrl+Shift+C`.
Then, select "shadow-cljs" from the dropdown menu. Another dropdown menu will appear, select ":app" from that menu. You should now be connected to the running shadow-cljs instance.
> [!NOTE]
> Here is a list of keyboard shortcuts for Calva:
> * `Ctrl+Shift+C & Enter` - Load/Evaluate current namespace & load it's dependencies
> * `Ctrl+Enter` - Evaluate current form
> * `Ctrl+Alt+C & C` - Evaluate current form into a comment
>
> - `Ctrl+Shift+C & Enter` - Load/Evaluate current namespace & load it's dependencies
> - `Ctrl+Enter` - Evaluate current form
> - `Ctrl+Alt+C & C` - Evaluate current form into a comment
For more information on Calva, please consider reading the [Calva documentation](https://calva.io/finding-commands/).

Some files were not shown because too many files have changed in this diff Show More