Compare commits

...

10 Commits

Author SHA1 Message Date
josc146
d33dff7723 release v1.7.0 2024-02-22 01:10:01 +09:00
josc146
771027211a chore 2024-02-22 01:05:52 +09:00
josc146
94fe71b49c change AVOID_PENALTY to \n only 2024-02-22 01:04:05 +09:00
josc146
fafd9f7f6e upgrade to rwkv 0.8.25 2024-02-21 23:50:05 +08:00
josc146
85b10993ec update manifest.json 2024-02-12 14:30:36 +08:00
Guillermo Marcus
11f1d66383 fix typo in requirements.txt 2024-02-06 19:59:50 +08:00
josc146
38e89aec18 update README 2024-02-06 12:21:05 +08:00
josc146
3e336830a3 chore 2024-02-06 12:19:12 +08:00
josc146
a1ae71d221 fix /update-config can make the default value of unclearly specified fields invalid by passing in None fields 2024-02-05 22:27:02 +08:00
github-actions[bot]
0703993bfd release v1.6.9 2024-02-05 04:44:24 +00:00
18 changed files with 2381 additions and 107 deletions

1
.gitignore vendored
View File

@@ -19,7 +19,6 @@ __pycache__
/cmd-helper.bat /cmd-helper.bat
/install-py-dep.bat /install-py-dep.bat
/backend-python/wkv_cuda /backend-python/wkv_cuda
/backend-python/rwkv*
*.exe *.exe
*.old *.old
.DS_Store .DS_Store

View File

@@ -2,41 +2,16 @@
### Upgrades ### Upgrades
- web-rwkv-py 0.1.2 (Support V4, V5 and V6) https://github.com/cryscan/web-rwkv-py - rwkv 0.8.25 (fix v6 fp16i8)
- webgpu 0.3.13 https://github.com/cgisky1980/ai00_rwkv_server
### Features
- add markdown renderer switch
- allow loading conversation
- allow setting history message number
- expose penalty_decay, top_k
- add AVOID_PENALTY_TOKENS
- add [parse_api_log.py](https://github.com/josStorer/RWKV-Runner/blob/master/parse_api_log.py), this script can extract
formatted data from api.log
### Improvements
- improve macos experience
- improve fine-tune performance
- add better custom tokenizer support and tokenizer-midipiano.json
- improve path processing
- add EOS state cache point
- reduce package size
### Fixes ### Fixes
- fix WSL2 WindowsOptionalFeature: Microsoft-Windows-Subsystem-Linux -> VirtualMachinePlatform - fix /update-config can make the default value of unclearly specified fields invalid by passing in None fields
- fix finetune errorsMap ($modelInfo)
### Chores ### Chores
- update defaultPresets - change AVOID_PENALTY to \n only
- update defaultModelConfigs - chores
- rename manifest tag "Main" -> "Official"
- update manifest.json
- update Related Repositories
- other minor changes
## Install ## Install

View File

@@ -12,6 +12,7 @@ compatible with the OpenAI API, which means that every ChatGPT client is an RWKV
[![license][license-image]][license-url] [![license][license-image]][license-url]
[![release][release-image]][release-url] [![release][release-image]][release-url]
[![py-version][py-version-image]][py-version-url]
English | [简体中文](README_ZH.md) | [日本語](README_JA.md) English | [简体中文](README_ZH.md) | [日本語](README_JA.md)
@@ -31,6 +32,10 @@ English | [简体中文](README_ZH.md) | [日本語](README_JA.md)
[release-url]: https://github.com/josStorer/RWKV-Runner/releases/latest [release-url]: https://github.com/josStorer/RWKV-Runner/releases/latest
[py-version-image]: https://img.shields.io/pypi/pyversions/fastapi.svg
[py-version-url]: https://github.com/josStorer/RWKV-Runner/tree/master/backend-python
[download-url]: https://github.com/josStorer/RWKV-Runner/releases [download-url]: https://github.com/josStorer/RWKV-Runner/releases
[Windows-image]: https://img.shields.io/badge/-Windows-blue?logo=windows [Windows-image]: https://img.shields.io/badge/-Windows-blue?logo=windows

View File

@@ -12,6 +12,7 @@
[![license][license-image]][license-url] [![license][license-image]][license-url]
[![release][release-image]][release-url] [![release][release-image]][release-url]
[![py-version][py-version-image]][py-version-url]
[English](README.md) | [简体中文](README_ZH.md) | 日本語 [English](README.md) | [简体中文](README_ZH.md) | 日本語
@@ -31,6 +32,10 @@
[release-url]: https://github.com/josStorer/RWKV-Runner/releases/latest [release-url]: https://github.com/josStorer/RWKV-Runner/releases/latest
[py-version-image]: https://img.shields.io/pypi/pyversions/fastapi.svg
[py-version-url]: https://github.com/josStorer/RWKV-Runner/tree/master/backend-python
[download-url]: https://github.com/josStorer/RWKV-Runner/releases [download-url]: https://github.com/josStorer/RWKV-Runner/releases
[Windows-image]: https://img.shields.io/badge/-Windows-blue?logo=windows [Windows-image]: https://img.shields.io/badge/-Windows-blue?logo=windows

View File

@@ -11,6 +11,7 @@ API兼容的接口这意味着一切ChatGPT客户端都是RWKV客户端。
[![license][license-image]][license-url] [![license][license-image]][license-url]
[![release][release-image]][release-url] [![release][release-image]][release-url]
[![py-version][py-version-image]][py-version-url]
[English](README.md) | 简体中文 | [日本語](README_JA.md) [English](README.md) | 简体中文 | [日本語](README_JA.md)
@@ -30,6 +31,10 @@ API兼容的接口这意味着一切ChatGPT客户端都是RWKV客户端。
[release-url]: https://github.com/josStorer/RWKV-Runner/releases/latest [release-url]: https://github.com/josStorer/RWKV-Runner/releases/latest
[py-version-image]: https://img.shields.io/pypi/pyversions/fastapi.svg
[py-version-url]: https://github.com/josStorer/RWKV-Runner/tree/master/backend-python
[download-url]: https://github.com/josStorer/RWKV-Runner/releases [download-url]: https://github.com/josStorer/RWKV-Runner/releases
[Windows-image]: https://img.shields.io/badge/-Windows-blue?logo=windows [Windows-image]: https://img.shields.io/badge/-Windows-blue?logo=windows

View File

@@ -1,7 +1,7 @@
torch torch
torchvision torchvision
torchaudio torchaudio
rwkv==0.8.22 rwkv==0.8.25
langchain==0.0.322 langchain==0.0.322
fastapi==0.104.0 fastapi==0.104.0
uvicorn==0.23.2 uvicorn==0.23.2
@@ -22,4 +22,4 @@ PyMuPDF==1.23.5
python-multipart==0.0.6 python-multipart==0.0.6
Cython==3.0.4 Cython==3.0.4
cyac==1.9 cyac==1.9
torch_directml==0.1.13.1.dev230413 torch-directml==0.1.13.1.dev230413

View File

@@ -1,7 +1,7 @@
torch torch
torchvision torchvision
torchaudio torchaudio
rwkv==0.8.22 rwkv==0.8.25
langchain==0.0.322 langchain==0.0.322
fastapi==0.104.0 fastapi==0.104.0
uvicorn==0.23.2 uvicorn==0.23.2

View File

@@ -144,6 +144,7 @@ async def eval_rwkv(
return return
set_rwkv_config(model, global_var.get(global_var.Model_Config)) set_rwkv_config(model, global_var.get(global_var.Model_Config))
set_rwkv_config(model, body) set_rwkv_config(model, body)
print(get_rwkv_config(model))
response, prompt_tokens, completion_tokens = "", 0, 0 response, prompt_tokens, completion_tokens = "", 0, 0
for response, delta, prompt_tokens, completion_tokens in model.generate( for response, delta, prompt_tokens, completion_tokens in model.generate(
@@ -155,23 +156,27 @@ async def eval_rwkv(
if stream: if stream:
yield json.dumps( yield json.dumps(
{ {
"object": "chat.completion.chunk" "object": (
if chat_mode "chat.completion.chunk"
else "text_completion", if chat_mode
else "text_completion"
),
# "response": response, # "response": response,
"model": model.name, "model": model.name,
"choices": [ "choices": [
{ (
"delta": {"content": delta}, {
"index": 0, "delta": {"content": delta},
"finish_reason": None, "index": 0,
} "finish_reason": None,
if chat_mode }
else { if chat_mode
"text": delta, else {
"index": 0, "text": delta,
"finish_reason": None, "index": 0,
} "finish_reason": None,
}
)
], ],
} }
) )
@@ -193,23 +198,25 @@ async def eval_rwkv(
if stream: if stream:
yield json.dumps( yield json.dumps(
{ {
"object": "chat.completion.chunk" "object": (
if chat_mode "chat.completion.chunk" if chat_mode else "text_completion"
else "text_completion", ),
# "response": response, # "response": response,
"model": model.name, "model": model.name,
"choices": [ "choices": [
{ (
"delta": {}, {
"index": 0, "delta": {},
"finish_reason": "stop", "index": 0,
} "finish_reason": "stop",
if chat_mode }
else { if chat_mode
"text": "", else {
"index": 0, "text": "",
"finish_reason": "stop", "index": 0,
} "finish_reason": "stop",
}
)
], ],
} }
) )
@@ -225,20 +232,22 @@ async def eval_rwkv(
"total_tokens": prompt_tokens + completion_tokens, "total_tokens": prompt_tokens + completion_tokens,
}, },
"choices": [ "choices": [
{ (
"message": { {
"role": Role.Assistant.value, "message": {
"content": response, "role": Role.Assistant.value,
}, "content": response,
"index": 0, },
"finish_reason": "stop", "index": 0,
} "finish_reason": "stop",
if chat_mode }
else { if chat_mode
"text": response, else {
"index": 0, "text": response,
"finish_reason": "stop", "index": 0,
} "finish_reason": "stop",
}
)
], ],
} }

View File

@@ -86,23 +86,41 @@ def switch_model(body: SwitchModelBody, response: Response, request: Request):
if body.deploy: if body.deploy:
global_var.set(global_var.Deploy_Mode, True) global_var.set(global_var.Deploy_Mode, True)
if global_var.get(global_var.Model_Config) is None:
global_var.set( saved_model_config = global_var.get(global_var.Model_Config)
global_var.Model_Config, get_rwkv_config(global_var.get(global_var.Model)) init_model_config = get_rwkv_config(global_var.get(global_var.Model))
) if saved_model_config is not None:
merge_model(init_model_config, saved_model_config)
global_var.set(global_var.Model_Config, init_model_config)
global_var.set(global_var.Model_Status, global_var.ModelStatus.Working) global_var.set(global_var.Model_Status, global_var.ModelStatus.Working)
return "success" return "success"
def merge_model(to_model: BaseModel, from_model: BaseModel):
from_model_fields = [x for x in from_model.dict().keys()]
to_model_fields = [x for x in to_model.dict().keys()]
for field_name in from_model_fields:
if field_name in to_model_fields:
from_value = getattr(from_model, field_name)
if from_value is not None:
setattr(to_model, field_name, from_value)
@router.post("/update-config", tags=["Configs"]) @router.post("/update-config", tags=["Configs"])
def update_config(body: ModelConfigBody): def update_config(body: ModelConfigBody):
""" """
Will not update the model config immediately, but set it when completion called to avoid modifications during generation Will not update the model config immediately, but set it when completion called to avoid modifications during generation
""" """
print(body) model_config = global_var.get(global_var.Model_Config)
global_var.set(global_var.Model_Config, body) if model_config is None:
model_config = ModelConfigBody()
global_var.set(global_var.Model_Config, model_config)
merge_model(model_config, body)
print("Updated Model Config:", model_config)
return "success" return "success"

View File

@@ -552,7 +552,12 @@ class RWKV(MyModule):
elif ".ln_x" in x: # need fp32 for group_norm elif ".ln_x" in x: # need fp32 for group_norm
w[x] = w[x].float() w[x] = w[x].float()
else: else:
if (len(w[x].shape) == 2) and ("emb" not in x): if (
(len(w[x].shape) == 2)
and ("emb" not in x)
and ("_w1" not in x)
and ("_w2" not in x)
):
if WTYPE != torch.uint8: if WTYPE != torch.uint8:
w[x] = w[x].to(dtype=WTYPE) w[x] = w[x].to(dtype=WTYPE)
else: else:

File diff suppressed because it is too large Load Diff

View File

@@ -171,10 +171,17 @@ class PIPELINE:
all_tokens += [token] all_tokens += [token]
for xxx in occurrence: for xxx in occurrence:
occurrence[xxx] *= args.alpha_decay occurrence[xxx] *= args.alpha_decay
ttt = self.decode([token])
www = 1
if ttt in " \t0123456789":
www = 0
# elif ttt in '\r\n,.;?!"\':+-*/=#@$%^&_`~|<>\\()[]{},。;“”:?!()【】':
# www = 0.5
if token not in occurrence: if token not in occurrence:
occurrence[token] = 1 occurrence[token] = www
else: else:
occurrence[token] += 1 occurrence[token] += www
# print(occurrence) # debug # print(occurrence) # debug
# output # output

View File

@@ -22,7 +22,7 @@ class RWKV:
args = { args = {
"file": model_path, "file": model_path,
"turbo": True, "turbo": True,
"quant": 32 if "i8" in strategy else 0, "quant": 31 if "i8" in strategy else 0,
"quant_nf4": 26 if "i4" in strategy else 0, "quant_nf4": 26 if "i4" in strategy else 0,
"token_chunk_size": 32, "token_chunk_size": 32,
"lora": None, "lora": None,

View File

@@ -372,18 +372,20 @@ class TextRWKV(AbstractRWKV):
self.bot = "Assistant" self.bot = "Assistant"
self.END_OF_LINE = 11 self.END_OF_LINE = 11
self.AVOID_REPEAT_TOKENS = [] self.AVOID_REPEAT_TOKENS = set()
AVOID_REPEAT = "" AVOID_REPEAT = ""
for i in AVOID_REPEAT: for i in AVOID_REPEAT:
dd = self.pipeline.encode(i) dd = self.pipeline.encode(i)
assert len(dd) == 1 assert len(dd) == 1
self.AVOID_REPEAT_TOKENS += dd self.AVOID_REPEAT_TOKENS.add(dd[0])
self.AVOID_PENALTY_TOKENS = [] self.AVOID_PENALTY_TOKENS = set()
AVOID_PENALTY = "\n,.:,。:<>[]{}()/\\|;" # \n,.:?!,。:?!"“”<>[]{}/\\|;~`@#$%^&*()_+-=0123456789 AVOID_PENALTY = (
"\n" # \n,.:?!,。:?!"“”<>[]{}/\\|;~`@#$%^&*()_+-=0123456789
)
for i in AVOID_PENALTY: for i in AVOID_PENALTY:
dd = self.pipeline.encode(i) dd = self.pipeline.encode(i)
assert len(dd) == 1 assert len(dd) == 1
self.AVOID_PENALTY_TOKENS += dd self.AVOID_PENALTY_TOKENS.add(dd[0])
self.__preload() self.__preload()

View File

@@ -6430,7 +6430,7 @@
}, },
"node_modules/typescript": { "node_modules/typescript": {
"version": "5.0.4", "version": "5.0.4",
"resolved": "https://registry.npmmirror.com/typescript/-/typescript-5.0.4.tgz", "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.0.4.tgz",
"integrity": "sha512-cW9T5W9xY37cc+jfEnaUvX91foxtHkza3Nw3wkoF4sSlKn0MONdkdEndig/qPBWXNkmplh3NzayQzCiHM4/hqw==", "integrity": "sha512-cW9T5W9xY37cc+jfEnaUvX91foxtHkza3Nw3wkoF4sSlKn0MONdkdEndig/qPBWXNkmplh3NzayQzCiHM4/hqw==",
"dev": true, "dev": true,
"bin": { "bin": {

10
go.mod
View File

@@ -9,7 +9,7 @@ require (
github.com/minio/selfupdate v0.6.0 github.com/minio/selfupdate v0.6.0
github.com/nyaosorg/go-windows-su v0.2.1 github.com/nyaosorg/go-windows-su v0.2.1
github.com/ubuntu/gowsl v0.0.0-20230615094051-94945650cc1e github.com/ubuntu/gowsl v0.0.0-20230615094051-94945650cc1e
github.com/wailsapp/wails/v2 v2.7.1 github.com/wailsapp/wails/v2 v2.8.0
) )
require ( require (
@@ -38,9 +38,9 @@ require (
github.com/valyala/fasttemplate v1.2.2 // indirect github.com/valyala/fasttemplate v1.2.2 // indirect
github.com/wailsapp/go-webview2 v1.0.10 // indirect github.com/wailsapp/go-webview2 v1.0.10 // indirect
github.com/wailsapp/mimetype v1.4.1 // indirect github.com/wailsapp/mimetype v1.4.1 // indirect
golang.org/x/crypto v0.14.0 // indirect golang.org/x/crypto v0.18.0 // indirect
golang.org/x/exp v0.0.0-20230522175609-2e198f4a06a1 // indirect golang.org/x/exp v0.0.0-20230522175609-2e198f4a06a1 // indirect
golang.org/x/net v0.17.0 // indirect golang.org/x/net v0.20.0 // indirect
golang.org/x/sys v0.13.0 // indirect golang.org/x/sys v0.16.0 // indirect
golang.org/x/text v0.13.0 // indirect golang.org/x/text v0.14.0 // indirect
) )

20
go.sum
View File

@@ -79,20 +79,20 @@ github.com/wailsapp/go-webview2 v1.0.10 h1:PP5Hug6pnQEAhfRzLCoOh2jJaPdrqeRgJKZhy
github.com/wailsapp/go-webview2 v1.0.10/go.mod h1:Uk2BePfCRzttBBjFrBmqKGJd41P6QIHeV9kTgIeOZNo= github.com/wailsapp/go-webview2 v1.0.10/go.mod h1:Uk2BePfCRzttBBjFrBmqKGJd41P6QIHeV9kTgIeOZNo=
github.com/wailsapp/mimetype v1.4.1 h1:pQN9ycO7uo4vsUUuPeHEYoUkLVkaRntMnHJxVwYhwHs= github.com/wailsapp/mimetype v1.4.1 h1:pQN9ycO7uo4vsUUuPeHEYoUkLVkaRntMnHJxVwYhwHs=
github.com/wailsapp/mimetype v1.4.1/go.mod h1:9aV5k31bBOv5z6u+QP8TltzvNGJPmNJD4XlAL3U+j3o= github.com/wailsapp/mimetype v1.4.1/go.mod h1:9aV5k31bBOv5z6u+QP8TltzvNGJPmNJD4XlAL3U+j3o=
github.com/wailsapp/wails/v2 v2.7.1 h1:HAzp2c5ODOzsLC6ZMDVtNOB72ozM7/SJecJPB2Ur+UU= github.com/wailsapp/wails/v2 v2.8.0 h1:b2NNn99uGPiN6P5bDsnPwOJZWtAOUhNLv7Vl+YxMTr4=
github.com/wailsapp/wails/v2 v2.7.1/go.mod h1:oIJVwwso5fdOgprBYWXBBqtx6PaSvxg8/KTQHNGkadc= github.com/wailsapp/wails/v2 v2.8.0/go.mod h1:EFUGWkUX3KofO4fmKR/GmsLy3HhPH7NbyOEaMt8lBF0=
golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w=
golang.org/x/crypto v0.0.0-20210220033148-5ea612d1eb83/go.mod h1:jdWPYTVW3xRLrWPugEBEK3UY2ZEsg3UU495nc5E+M+I= golang.org/x/crypto v0.0.0-20210220033148-5ea612d1eb83/go.mod h1:jdWPYTVW3xRLrWPugEBEK3UY2ZEsg3UU495nc5E+M+I=
golang.org/x/crypto v0.0.0-20211209193657-4570a0811e8b/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= golang.org/x/crypto v0.0.0-20211209193657-4570a0811e8b/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4=
golang.org/x/crypto v0.14.0 h1:wBqGXzWJW6m1XrIKlAH0Hs1JJ7+9KBwnIO8v66Q9cHc= golang.org/x/crypto v0.18.0 h1:PGVlW0xEltQnzFZ55hkuX5+KLyrMYhHld1YHO4AKcdc=
golang.org/x/crypto v0.14.0/go.mod h1:MVFd36DqK4CsrnJYDkBA3VC4m2GkXAM0PvzMCn4JQf4= golang.org/x/crypto v0.18.0/go.mod h1:R0j02AL6hcrfOiy9T4ZYp/rcWeMxM3L6QYxlOuEG1mg=
golang.org/x/exp v0.0.0-20230522175609-2e198f4a06a1 h1:k/i9J1pBpvlfR+9QsetwPyERsqu1GIbi967PQMq3Ivc= golang.org/x/exp v0.0.0-20230522175609-2e198f4a06a1 h1:k/i9J1pBpvlfR+9QsetwPyERsqu1GIbi967PQMq3Ivc=
golang.org/x/exp v0.0.0-20230522175609-2e198f4a06a1/go.mod h1:V1LtkGg67GoY2N1AnLN78QLrzxkLyJw7RJb1gzOOz9w= golang.org/x/exp v0.0.0-20230522175609-2e198f4a06a1/go.mod h1:V1LtkGg67GoY2N1AnLN78QLrzxkLyJw7RJb1gzOOz9w=
golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg=
golang.org/x/net v0.0.0-20210505024714-0287a6fb4125/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= golang.org/x/net v0.0.0-20210505024714-0287a6fb4125/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
golang.org/x/net v0.0.0-20211112202133-69e39bad7dc2/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= golang.org/x/net v0.0.0-20211112202133-69e39bad7dc2/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
golang.org/x/net v0.17.0 h1:pVaXccu2ozPjCXewfr1S7xza/zcXTity9cCdXQYSjIM= golang.org/x/net v0.20.0 h1:aCL9BSgETF1k+blQaYUBx9hJ9LOGP3gAVemcZlf1Kpo=
golang.org/x/net v0.17.0/go.mod h1:NxSsAGuq816PNPmqtQdLE42eU2Fs7NoRIZrHJAlaCOE= golang.org/x/net v0.20.0/go.mod h1:z8BVo6PvndSri0LbOE3hAn0apkU+1YvI6E70E9jsnvY=
golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
golang.org/x/sys v0.0.0-20190916202348-b4ddaad3f8a3/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190916202348-b4ddaad3f8a3/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20191026070338-33540a1f6037/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191026070338-33540a1f6037/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
@@ -109,14 +109,14 @@ golang.org/x/sys v0.0.0-20220715151400-c0bba94af5f8/go.mod h1:oPkhp1MJrh7nUepCBc
golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20220908164124-27713097b956/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220908164124-27713097b956/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.6.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.6.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.13.0 h1:Af8nKPmuFypiUBjVoU9V20FiaFXOcuZI21p0ycVYYGE= golang.org/x/sys v0.16.0 h1:xWw16ngr6ZMtmxDyKyIgsE93KNKz5HKmMa3b8ALHidU=
golang.org/x/sys v0.13.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.16.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA=
golang.org/x/term v0.0.0-20201117132131-f5c789dd3221/go.mod h1:Nr5EML6q2oocZ2LXRh80K7BxOlk5/8JxuGnuhpl+muw= golang.org/x/term v0.0.0-20201117132131-f5c789dd3221/go.mod h1:Nr5EML6q2oocZ2LXRh80K7BxOlk5/8JxuGnuhpl+muw=
golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo=
golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
golang.org/x/text v0.13.0 h1:ablQoSUd0tRdKxZewP80B+BaqeKJuVhuRxj/dkrun3k= golang.org/x/text v0.14.0 h1:ScX5w1eTa3QqT8oi6+ziP7dTV1S2+ALU0bI+0zXKWiQ=
golang.org/x/text v0.13.0/go.mod h1:TvPlkZtksWOMsz7fbANvkp4WM8x/WCo/om8BMLbz+aE= golang.org/x/text v0.14.0/go.mod h1:18ZOQIKpY8NJVqYksKHtTdi31H5itFRjB5/qKTNYzSU=
golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=

View File

@@ -1,5 +1,5 @@
{ {
"version": "1.6.8", "version": "1.6.9",
"introduction": { "introduction": {
"en": "RWKV is an open-source, commercially usable large language model with high flexibility and great potential for development.\n### About This Tool\nThis tool aims to lower the barrier of entry for using large language models, making it accessible to everyone. It provides fully automated dependency and model management. You simply need to click and run, following the instructions, to deploy a local large language model. The tool itself is very compact and only requires a single executable file for one-click deployment.\nAdditionally, this tool offers an interface that is fully compatible with the OpenAI API. This means you can use any ChatGPT client as a client for RWKV, enabling capability expansion beyond just chat functionality.\n### Preset Configuration Rules at the Bottom\nThis tool comes with a series of preset configurations to reduce complexity. The naming rules for each configuration represent the following in order: device - required VRAM/memory - model size - model language.\nFor example, \"GPU-8G-3B-EN\" indicates that this configuration is for a graphics card with 8GB of VRAM, a model size of 3 billion parameters, and it uses an English language model.\nLarger model sizes have higher performance and VRAM requirements. Among configurations with the same model size, those with higher VRAM usage will have faster runtime.\nFor example, if you have 12GB of VRAM but running the \"GPU-12G-7B-EN\" configuration is slow, you can downgrade to \"GPU-8G-3B-EN\" for a significant speed improvement.\n### About RWKV\nRWKV is an RNN with Transformer-level LLM performance, which can also be directly trained like a GPT transformer (parallelizable). And it's 100% attention-free. You only need the hidden state at position t to compute the state at position t+1. You can use the \"GPT\" mode to quickly compute the hidden state for the \"RNN\" mode.<br/>So it's combining the best of RNN and transformer - great performance, fast inference, saves VRAM, fast training, \"infinite\" ctx_len, and free sentence embedding (using the final hidden state).", "en": "RWKV is an open-source, commercially usable large language model with high flexibility and great potential for development.\n### About This Tool\nThis tool aims to lower the barrier of entry for using large language models, making it accessible to everyone. It provides fully automated dependency and model management. You simply need to click and run, following the instructions, to deploy a local large language model. The tool itself is very compact and only requires a single executable file for one-click deployment.\nAdditionally, this tool offers an interface that is fully compatible with the OpenAI API. This means you can use any ChatGPT client as a client for RWKV, enabling capability expansion beyond just chat functionality.\n### Preset Configuration Rules at the Bottom\nThis tool comes with a series of preset configurations to reduce complexity. The naming rules for each configuration represent the following in order: device - required VRAM/memory - model size - model language.\nFor example, \"GPU-8G-3B-EN\" indicates that this configuration is for a graphics card with 8GB of VRAM, a model size of 3 billion parameters, and it uses an English language model.\nLarger model sizes have higher performance and VRAM requirements. Among configurations with the same model size, those with higher VRAM usage will have faster runtime.\nFor example, if you have 12GB of VRAM but running the \"GPU-12G-7B-EN\" configuration is slow, you can downgrade to \"GPU-8G-3B-EN\" for a significant speed improvement.\n### About RWKV\nRWKV is an RNN with Transformer-level LLM performance, which can also be directly trained like a GPT transformer (parallelizable). And it's 100% attention-free. You only need the hidden state at position t to compute the state at position t+1. You can use the \"GPT\" mode to quickly compute the hidden state for the \"RNN\" mode.<br/>So it's combining the best of RNN and transformer - great performance, fast inference, saves VRAM, fast training, \"infinite\" ctx_len, and free sentence embedding (using the final hidden state).",
"zh": "RWKV是一个开源且允许商用的大语言模型灵活性很高且极具发展潜力。\n### 关于本工具\n本工具旨在降低大语言模型的使用门槛做到人人可用本工具提供了全自动化的依赖和模型管理你只需要直接点击运行跟随引导即可完成本地大语言模型的部署工具本身体积极小只需要一个exe即可完成一键部署。\n此外本工具提供了与OpenAI API完全兼容的接口这意味着你可以把任意ChatGPT客户端用作RWKV的客户端实现能力拓展而不局限于聊天。\n### 底部的预设配置规则\n本工具内置了一系列预设配置以降低使用难度每个配置名的规则依次代表着设备-所需显存/内存-模型规模-模型语言。\n例如GPU-8G-3B-CN表示该配置用于显卡需要8G显存模型规模为30亿参数使用的是中文模型。\n模型规模越大性能要求越高显存要求也越高而同样模型规模的配置中显存占用越高的运行速度越快。\n例如当你有12G显存但运行GPU-12G-7B-CN配置速度比较慢可降级成GPU-8G-3B-CN将会大幅提速。\n### 关于RWKV\nRWKV是具有Transformer级别LLM性能的RNN也可以像GPT Transformer一样直接进行训练可并行化。而且它是100% attention-free的。你只需在位置t处获得隐藏状态即可计算位置t + 1处的状态。你可以使用“GPT”模式快速计算用于“RNN”模式的隐藏状态。\n因此它将RNN和Transformer的优点结合起来 - 高性能、快速推理、节省显存、快速训练、“无限”上下文长度以及免费的语句嵌入(使用最终隐藏状态)。" "zh": "RWKV是一个开源且允许商用的大语言模型灵活性很高且极具发展潜力。\n### 关于本工具\n本工具旨在降低大语言模型的使用门槛做到人人可用本工具提供了全自动化的依赖和模型管理你只需要直接点击运行跟随引导即可完成本地大语言模型的部署工具本身体积极小只需要一个exe即可完成一键部署。\n此外本工具提供了与OpenAI API完全兼容的接口这意味着你可以把任意ChatGPT客户端用作RWKV的客户端实现能力拓展而不局限于聊天。\n### 底部的预设配置规则\n本工具内置了一系列预设配置以降低使用难度每个配置名的规则依次代表着设备-所需显存/内存-模型规模-模型语言。\n例如GPU-8G-3B-CN表示该配置用于显卡需要8G显存模型规模为30亿参数使用的是中文模型。\n模型规模越大性能要求越高显存要求也越高而同样模型规模的配置中显存占用越高的运行速度越快。\n例如当你有12G显存但运行GPU-12G-7B-CN配置速度比较慢可降级成GPU-8G-3B-CN将会大幅提速。\n### 关于RWKV\nRWKV是具有Transformer级别LLM性能的RNN也可以像GPT Transformer一样直接进行训练可并行化。而且它是100% attention-free的。你只需在位置t处获得隐藏状态即可计算位置t + 1处的状态。你可以使用“GPT”模式快速计算用于“RNN”模式的隐藏状态。\n因此它将RNN和Transformer的优点结合起来 - 高性能、快速推理、节省显存、快速训练、“无限”上下文长度以及免费的语句嵌入(使用最终隐藏状态)。"
@@ -15,6 +15,26 @@
} }
], ],
"models": [ "models": [
{
"name": "RWKV-x060-World-1B6-v2-20240208-ctx4096.pth",
"desc": {
"en": "RWKV-6 Global Languages 1.6B v2",
"zh": "RWKV-6 全球语言 1.6B v2",
"ja": "RWKV-6 グローバル言語 1.6B v2"
},
"size": 3199845663,
"SHA256": "5c9c877fb60a65cab269af175328b6aaf16d02b8b09738923254f9986e5dc440",
"lastUpdated": "2024-02-08T17:56:51",
"url": "https://huggingface.co/BlinkDL/rwkv-6-world/blob/main/RWKV-x060-World-1B6-v2-20240208-ctx4096.pth",
"downloadUrl": "https://huggingface.co/BlinkDL/rwkv-6-world/resolve/main/RWKV-x060-World-1B6-v2-20240208-ctx4096.pth",
"tags": [
"Official",
"RWKV-6",
"Global",
"CN",
"JP"
]
},
{ {
"name": "RWKV-5-World-0.1B-v1-20230803-ctx4096.pth", "name": "RWKV-5-World-0.1B-v1-20230803-ctx4096.pth",
"desc": { "desc": {