本仓库托管了SwanLab的官方文档,基于vitepress。
很简单!只需要增添或修改Markdown文件,提交他们,创建一个PR就可以。
- 克隆本仓库
git clone https://github.com/SwanHubX/SwanLab-Docs
- 安装环境
npm add -D vitepress
- 本地开发,在项目根目录运行:
npm run docs:dev
- 打包与预览
npm run docs:build
npm run docs:preview
SwanLab Official Documentation | SwanLab官方文档
Home Page: https://docs.swanlab.cn
Ultralytics YOLO目标检测的案例。
class LLMSwanLabCallback(SwanLabCallback):
def on_epoch_end(self, args, state, control, **kwargs):
test_text_list = []
for index, row in test_df.iterrows():
instruction = row['instruction']
input_value = row['input']
messages = [
{"role": "system", "content": f"{instruction}"},
{"role": "user", "content": f"{input_value}"}
]
response = predict(messages, model, tokenizer)
messages.append({"role": "assistant", "content": f"{response}"})
result_text = f"{messages[0]}\n\n{messages[1]}\n\n{messages[2]}"
test_text_list.append(swanlab.Text(result_text, caption=response))
swanlab.log({"Prediction": test_text_list}, step=state.global_step)
swanlab仓库的README也同步一下
SwanLab Version:
Platform:
SwanLab Version:
Platform:
和swift框架的集成方法和与HuggingFace Transformers一样
增加0.3.15中的torchtune集成指引
添加关于swanlab与accelerate
库的集成文档。
添加方式:
npm run docs:dev
开启文档开发模式/.vitepress/config.mts
下的如下部分添加一行HuggingFace Accelerate
,这里的作用是在官方文档的侧边栏增加一个链接;其中text代表标题,link则是文档markdown的名称 {
text: '⚡️ 集成',
// collapsed: false,
items: [
{ text: 'Argparse', link:'integration/integration-argparse' },
...
{ text: 'HuggingFace Accelerate', link:'integration/integration-huggingface-accelerate'}
...
{ text: 'ZhipuAI', link: 'integration/integration-zhipuai'},
]
},
zh/guide_cloud/integration
下创建一个integration-huggingface-accelerate.md
,然后参考其他文档格式写Markdown即可改进内容:
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.