Compare commits

...

39 Commits
0.5.0 ... 0.5.4

Author SHA1 Message Date
zyxucp
cb0df4d4af update sk and km version 2024-10-23 18:03:21 +08:00
zyxucp
c810f85cea update nuget 2024-10-23 17:06:27 +08:00
zyxucp
6700b75684 update del icon 2024-10-23 09:40:15 +08:00
zyxucp
ab15dd6e99 add SecretKey search 2024-10-18 09:52:47 +08:00
zyxucp
13a4419705 update index 2024-10-14 14:10:04 +08:00
zyxucp
cf03465e23 Update README.zh.md 2024-10-06 10:35:45 +08:00
zyxucp
a441730508 Update README.md 2024-10-06 10:34:45 +08:00
zyxucp
6e30886bd2 Update README.md 2024-10-06 10:34:21 +08:00
zyxucp
bc2af42724 Update README.md 2024-10-06 10:31:35 +08:00
zyxucp
919fc5dea7 Update docker-compose.yml 2024-10-06 10:30:50 +08:00
zyxucp
9ab287fabd Update docker-compose.simple.yml 2024-10-06 10:30:36 +08:00
zyxucp
cf02efc2da update nuget 2024-10-05 18:33:30 +08:00
zyxucp
1c34ad5987 fix bug 2024-10-05 18:26:36 +08:00
zyxucp
4e8039703e Update README.zh.md 2024-09-29 10:57:48 +08:00
zyxucp
c2b97c7f82 Update README.md 2024-09-29 10:57:17 +08:00
zyxucp
1a621f5cbc Update docker-compose.yml 2024-09-29 10:54:39 +08:00
zyxucp
836f898ffe Update docker-compose.simple.yml 2024-09-29 10:54:11 +08:00
zyxucp
0a9a737709 Merge pull request #105 from AIDotNet/feature_0.5.1
Feature 0.5.1
2024-09-29 10:53:09 +08:00
zyxucp
0df8c74ec2 del sd 2024-09-29 10:52:27 +08:00
zyxucp
5e3ff74eaa update AntBlazor 2024-09-29 10:48:58 +08:00
zyxucp
7c49ff0a6c udpate exception 2024-09-29 10:43:44 +08:00
zyxucp
63f5267bca update 2024-09-29 10:41:09 +08:00
zyxucp
e0c35aac06 update style 2024-09-29 10:36:30 +08:00
zyxucp
27d52d3331 update nuget 2024-09-03 09:22:01 +08:00
zyxucp
e7b2c6e193 Merge branch 'main' of github.com:AIDotNet/AntSK 2024-09-02 09:37:45 +08:00
zyxucp
7600397b79 update style 2024-09-02 09:37:34 +08:00
zyxucp
874b8e5d7f Update LICENSE 2024-08-28 14:48:23 +08:00
zyxucp
3ac18086a1 Update README.zh.md 2024-08-28 12:41:04 +08:00
zyxucp
16049c7413 Update README.md 2024-08-28 12:40:37 +08:00
zyxucp
7bb7a41bb3 Update menu.json 2024-08-28 10:30:25 +08:00
zyxucp
6c37ed66b2 Update menu.json 2024-08-28 10:18:31 +08:00
zyxucp
bc86f96159 Update README.md 2024-08-27 23:43:01 +08:00
zyxucp
8eb09fb783 Update README.zh.md 2024-08-27 22:33:33 +08:00
zyxucp
eff5f69f0f fix 处理环境依赖导致rerank失败问题 2024-08-26 10:15:31 +08:00
zyxucp
e3f966d4f2 Merge branch 'main' of github.com:AIDotNet/AntSK 2024-08-23 18:08:55 +08:00
zyxucp
015f51b99c update KmsIdList length 2024-08-23 18:08:44 +08:00
zyxucp
cd66b61014 Update README.md 2024-08-20 10:23:49 +08:00
zyxucp
f0bef7d2fa Update docker-compose.simple.yml 2024-08-18 14:13:17 +08:00
zyxucp
de051b047d Update docker-compose.yml 2024-08-18 14:13:04 +08:00
45 changed files with 27434 additions and 675 deletions

View File

@@ -8,7 +8,7 @@
1.This project can be used for commercial purposes, but it has the right to prohibit you from using it if it violates the following provisions
2. Without authorization, you are not allowed to modify AntSK's logo and title information
3. Without authorization, you are not allowed to modify the copyright information at the bottom of the page
4. If you need authorization, you can contact WeChat: xuzeyu91
4. If you need authorization, you can contact WeChat: xuzeyu91 or Email:antskpro@qq.com
Apache 2.0 License

View File

@@ -86,7 +86,7 @@ version: '3.8'
services:
antsk:
container_name: antsk
image: registry.cn-hangzhou.aliyuncs.com/AIDotNet/antsk:v0.4.5
image: registry.cn-hangzhou.aliyuncs.com/AIDotNet/antsk:v0.5.0
ports:
- 5000:5000
networks:
@@ -103,9 +103,15 @@ networks:
antsk:
```
Taking this as an example, it means mounting the local D://model folder of Windows into the container /app/model. If so, the model address in your appsettings.json should be configured as
```
model/xxx.gguf
```
[LiteDockerCompose](https://github.com/AIDotNet/AntSK/blob/main/docker-compose.simple.yml)
The compact version is deployed with sqlite-disk by one click
[FullDockerCompose](https://github.com/AIDotNet/AntSK/blob/main/docker-compose.yml)
The full version uses pg+aspire
## 3⃣Some meanings of configuration file
```
@@ -145,11 +151,8 @@ DBConnection.ConnectionStrings
//The ConnectionString of Qdrant and AzureAISearch uses Endpoint | APIKey
KernelMemory.VectorDb
//Local model execution options: GPU and CPU. When using the online API, any option can be used.
LLamaSharp.RunType
//Local model path, used for quick selection of models under llama, as well as saving downloaded models.
LLamaSharp.FileDirectory
FileDir.DirectoryPath
//Default admin account password
Login
@@ -214,7 +217,7 @@ If you plan to use AntSK in commercial projects, you need to ensure that you fol
2. If you modify the software source code, you need to clearly indicate these modifications in the source code.
3. Meet the above four requirements
3. Meet the above requirements
## 💕 Special thanks
Helping enterprise AI application development, we recommend [AntBlazor](https://antblazor.com)
@@ -222,6 +225,8 @@ Helping enterprise AI application development, we recommend [AntBlazor](https://
## ☎Contact Me
If you have any questions or suggestions, please contact me through my official WeChat account. We also have a discussion group where you can send a message to join, and then I will add you to the group.
Additionally, you can also contact me via email: antskpro@qq.com
![Official WeChat Account](https://github.com/AIDotNet/AntSK/blob/main/images/gzh.jpg)
---

View File

@@ -112,9 +112,15 @@ networks:
antsk:
```
以这个为示例意思是把windows本地D://model的文件夹挂载进 容器内/app/model 如果是这样你的appsettings.json中的模型地址应该配置为
```
model/xxx.gguf
```
[LiteDockerCompose](https://github.com/AIDotNet/AntSK/blob/main/docker-compose.simple.yml)
精简版使用sqlite+disk向量模式简化部署配置
[FullDockerCompose](https://github.com/AIDotNet/AntSK/blob/main/docker-compose.yml)
完整版使用pg+aspire 功能更完整,配置文件需要参考如下配置含义进行配置
## 3⃣配置文件的一些含义
```
@@ -153,11 +159,8 @@ DBConnection.ConnectionStrings
//Qdrant 和AzureAISearch 的 ConnectionString 使用 Endpoint|APIKey
KernelMemory.VectorDb
//本地模型使用的运行方式 GUP CPU ,如果用在线API 这个随意使用一个即可
LLamaSharp.RunType
//本地模型路径用于在选择llama时可以快速选择目录下的模型以及保存下载的模型
LLamaSharp.FileDirectory
FileDir.DirectoryPath
//默认管理员账号密码
Login
@@ -220,7 +223,7 @@ DB我使用的是CodeFirst模式只要配置好数据库链接表结构是
2. 如果您修改了软件源代码,您需要在源代码中明确标明这些修改。
3. 满足以上四个要求
3. 满足以上要求
## 💕 特别感谢
助力企业级AI应用开发推荐使用 [AntBlazor](https://antblazor.com)
@@ -228,6 +231,9 @@ DB我使用的是CodeFirst模式只要配置好数据库链接表结构是
## ☎️联系我
如有任何问题或建议请通过以下方式关注我的公众号《许泽宇的技术分享》发消息与我联系我们也有AIDotnet交流群可以发送进群等消息然后我会拉你进交流群
另外您也可以通过邮箱与我联系antskpro@qq.com
![公众号](https://github.com/AIDotNet/AntSK/blob/main/images/gzh.jpg)
## 🌟 Star History

View File

@@ -3,9 +3,9 @@ version: '3.8'
services:
antsk:
container_name: antsk
image: registry.cn-hangzhou.aliyuncs.com/xuzeyu91/antsk:v0.4.5
image: registry.cn-hangzhou.aliyuncs.com/xuzeyu91/antsk:v0.5.2
# 如果需要pytorch环境需要使用下面这个镜像镜像比较大
# image: registry.cn-hangzhou.aliyuncs.com/xuzeyu91/antsk:p0.4.5
# image: registry.cn-hangzhou.aliyuncs.com/xuzeyu91/antsk:p0.5.2
ports:
- 5000:5000
networks:

View File

@@ -32,9 +32,9 @@ services:
- ./pg/data:/var/lib/postgresql/data
antsk:
container_name: antsk
image: registry.cn-hangzhou.aliyuncs.com/xuzeyu91/antsk:v0.4.5
image: registry.cn-hangzhou.aliyuncs.com/xuzeyu91/antsk:v0.5.2
# 如果需要pytorch环境需要使用下面这个镜像镜像比较大
# image: registry.cn-hangzhou.aliyuncs.com/xuzeyu91/antsk:p0.4.5
# image: registry.cn-hangzhou.aliyuncs.com/xuzeyu91/antsk:p0.5.2
ports:
- 5000:5000
networks:

View File

@@ -8,40 +8,42 @@
<NoWarn>CA1050,CA1707,CA2007,VSTHRD111,CS1591,RCS1110,CA5394,SKEXP0001,SKEXP0002,SKEXP0003,SKEXP0004,SKEXP0010,SKEXP0011,,SKEXP0012,SKEXP0020,SKEXP0021,SKEXP0022,SKEXP0023,SKEXP0024,SKEXP0025,SKEXP0026,SKEXP0027,SKEXP0028,SKEXP0029,SKEXP0030,SKEXP0031,SKEXP0032,SKEXP0040,SKEXP0041,SKEXP0042,SKEXP0050,SKEXP0051,SKEXP0052,SKEXP0053,SKEXP0054,SKEXP0055,SKEXP0060,SKEXP0061,SKEXP0101,SKEXP0102,KMEXP00</NoWarn>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="AntDesign.Charts" Version="0.5.5" />
<PackageReference Include="AntDesign.ProLayout" Version="0.19.7" />
<PackageReference Include="AntDesign.Charts" Version="0.5.6" />
<PackageReference Include="AntDesign.ProLayout" Version="0.20.3" />
<PackageReference Include="BlazorComponents.Terminal" Version="0.6.0" />
<PackageReference Include="Blazored.LocalStorage" Version="4.5.0" />
<PackageReference Include="pythonnet" Version="3.0.3" />
<PackageReference Include="pythonnet" Version="3.0.4" />
<PackageReference Include="Swashbuckle.AspNetCore" Version="6.7.0" />
<PackageReference Include="Swashbuckle.AspNetCore" Version="6.9.0" />
<PackageReference Include="AutoMapper" Version="8.1.0" />
<PackageReference Include="BCrypt.Net-Next" Version="4.0.3" />
<PackageReference Include="Markdig" Version="0.37.0" />
<PackageReference Include="Newtonsoft.Json" Version="$(NewtonsoftVersion)" />
<PackageReference Include="SqlSugarCore" Version="5.1.4.166" />
<PackageReference Include="System.Data.SQLite.Core" Version="1.0.118" />
<PackageReference Include="SqlSugarCore" Version="5.1.4.169" />
<PackageReference Include="System.Data.SQLite.Core" Version="1.0.119" />
<PackageReference Include="RestSharp" Version="$(RestSharpVersion)" />
<PackageReference Include="NPOI" Version="2.7.1" />
<PackageReference Include="Microsoft.SemanticKernel" Version="$(SKVersion)" />
<PackageReference Include="Microsoft.SemanticKernel.Core" Version="$(SKVersion)" />
<PackageReference Include="Microsoft.SemanticKernel.Plugins.Core" Version="$(SKVersion)-alpha" />
<PackageReference Include="Microsoft.KernelMemory.AI.OpenAI" Version="$(KMVersion)" />
<PackageReference Include="Microsoft.KernelMemory.AI.AzureOpenAI" Version="$(KMVersion)" />
<PackageReference Include="Microsoft.KernelMemory.Core" Version="$(KMVersion)" />
<PackageReference Include="Microsoft.KernelMemory.MemoryDb.Postgres" Version="$(KMVersion)" />
<PackageReference Include="Microsoft.KernelMemory.MemoryDb.Qdrant" Version="$(KMVersion)" />
<PackageReference Include="Microsoft.KernelMemory.MemoryDb.Redis" Version="$(KMVersion)" />
<PackageReference Include="Microsoft.KernelMemory.MemoryDb.AzureAISearch" Version="$(KMVersion)" />
<PackageReference Include="Serilog" Version="4.0.1" />
<PackageReference Include="Serilog" Version="4.1.0" />
<PackageReference Include="Serilog.Sinks.Console" Version="6.0.0" />
<PackageReference Include="Serilog.Sinks.File" Version="6.0.0" />
<PackageReference Include="Serilog.Extensions.Logging" Version="8.0.1-dev-10391" />
<PackageReference Include="Serilog.Settings.Configuration" Version="8.0.2" />
<PackageReference Include="Serilog.Settings.Configuration" Version="8.0.4" />
<PackageReference Include="Serilog.Sinks.Seq" Version="8.0.0" />
<PackageReference Include="Serilog.Sinks.OpenTelemetry" Version="4.0.0" />
<PackageReference Include="Serilog.Sinks.OpenTelemetry" Version="4.1.1" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\AntSK.LLamaFactory\AntSK.LLamaFactory.csproj" />

View File

@@ -1,4 +1,4 @@
using Amazon.Runtime.Internal.Util;

using Microsoft.Extensions.Logging;
using System;
using System.Collections.Generic;

View File

@@ -25,8 +25,6 @@ namespace AntSK.Domain.Domain.Model.Enum
BgeEmbedding = 7,
[Display(Name = "Bge Rerank")]
BgeRerank = 8,
[Display(Name = "StableDiffusion")]
StableDiffusion = 9,
[Display(Name = "Ollama")]
Ollama = 10,
@@ -44,7 +42,6 @@ namespace AntSK.Domain.Domain.Model.Enum
{
Chat = 1,
Embedding = 2,
Image=3,
Rerank=4
}
}

View File

@@ -1,5 +1,4 @@
using Amazon.Runtime.Internal.Util;
using AntSK.BackgroundTask;
using AntSK.BackgroundTask;
using AntSK.Domain.Domain.Interface;
using AntSK.Domain.Domain.Model;
using Microsoft.Extensions.DependencyInjection;

View File

@@ -6,6 +6,7 @@ using System.Linq;
using System.Text;
using System.Threading.Tasks;
using static Python.Runtime.Py;
using AntSK.Domain.Utils;
namespace AntSK.Domain.Domain.Other.Bge
{
@@ -65,7 +66,7 @@ namespace AntSK.Domain.Domain.Other.Bge
pyList.Append(item.ToPython()); // 将C# string转换为Python对象并添加到PyList中
}
PyObject result = model.compute_score(pyList, normalize: true);
return result.As<double>();
return result.ConvertToString().Trim('[').Trim(']').ConvertToDouble();
}
catch (Exception ex)
{

View File

@@ -1,4 +1,4 @@
using Microsoft.KernelMemory.AI.OpenAI;
using Microsoft.KernelMemory.AI;
using Python.Runtime;
using Serilog;
using System;

View File

@@ -1,7 +1,7 @@
using AntSK.Domain.Domain.Model.Constant;
using AntSK.Domain.Utils;
using Microsoft.Extensions.Logging;
using Microsoft.KernelMemory.AI.OpenAI;
using Microsoft.KernelMemory.AI;
using Microsoft.KernelMemory.Configuration;
using Microsoft.KernelMemory.DataFormats.Text;
using Microsoft.KernelMemory.Diagnostics;

View File

@@ -3,7 +3,7 @@ using AntSK.Domain.Domain.Model;
using AntSK.Domain.Utils;
using Microsoft.Extensions.Configuration;
using Microsoft.Extensions.Logging;
using Microsoft.KernelMemory.AI.OpenAI;
using Microsoft.KernelMemory.AI;
using Microsoft.KernelMemory.Configuration;
using Microsoft.KernelMemory.DataFormats.Text;
using Microsoft.KernelMemory.Diagnostics;

View File

@@ -10,7 +10,6 @@ using AntSK.Domain.Repositories;
using AntSK.Domain.Utils;
using AntSK.OCR;
using DocumentFormat.OpenXml.Drawing.Diagrams;
using LLama;
using Markdig;
using Microsoft.AspNetCore.Components;
using Microsoft.Extensions.Configuration;

View File

@@ -1,5 +1,4 @@
using Amazon.Runtime.Internal.Util;
using AntSK.Domain.Common.DependencyInjection;
using AntSK.Domain.Common.DependencyInjection;
using AntSK.Domain.Domain.Interface;
using AntSK.Domain.Domain.Model.Dto;
using AntSK.Domain.Options;

View File

@@ -75,6 +75,7 @@ namespace AntSK.Domain.Repositories
/// <summary>
/// 知识库ID列表
/// </summary>
[SugarColumn(ColumnDataType = "varchar(1000)")]
public string? KmsIdList { get; set; }
/// <summary>

View File

@@ -38,11 +38,6 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "AntSK.AppHost", "AntSK.AppH
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "AntSK.ServiceDefaults", "AntSK.ServiceDefaults\AntSK.ServiceDefaults.csproj", "{21AC6184-336E-475F-8975-80A39D59B0CC}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "解决方案项", "解决方案项", "{76407DD9-6F9D-401C-8A8C-4B6FEC03988A}"
ProjectSection(SolutionItems) = preProject
Directory.Build.props = Directory.Build.props
EndProjectSection
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU

View File

@@ -19,7 +19,7 @@
cursor:pointer;
border:none;
background-image: url('http://img.shields.io/github/stars/aidotnet/antsk?style=social');
width:88px;
width:90px;
height:20px;
}
</style>

View File

@@ -26,7 +26,7 @@
</ErrorBoundary>
</ChildContent>
<FooterRender>
<FooterView Copyright="2024 许泽宇的技术分享" Links="Links"></FooterView>
<FooterView Copyright="2024 AntSK版权所有" Links="Links"></FooterView>
</FooterRender>
</AntDesign.ProLayout.BasicLayout>
<SettingDrawer />
@@ -91,13 +91,6 @@
public LinkItem[] Links { get; set; } =
{
new LinkItem
{
Key = "许泽宇的技术分享",
Title = "许泽宇的技术分享",
Href = "./assets/gzh.jpg",
BlankTarget = true,
},
new LinkItem
{
Key = "antsk.cn",

View File

@@ -18,20 +18,13 @@
</div>
@Body
</div>
<FooterView Copyright="许泽宇的技术分享" Links="Links"></FooterView>
<FooterView Copyright="2024 AntSK版权所有" Links="Links"></FooterView>
</div>
@code
{
public LinkItem[] Links { get; set; } =
{
new LinkItem
{
Key = "许泽宇的技术分享",
Title = "许泽宇的技术分享",
Href = "./assets/gzh.jpg",
BlankTarget = true,
},
new LinkItem
{
Key = "antsk.cn",

View File

@@ -18,11 +18,11 @@
<FormItem Label="应用名称" LabelCol="LayoutModel._formItemLayout.LabelCol" WrapperCol="LayoutModel._formItemLayout.WrapperCol">
<Input Placeholder="请输入应用名称" @bind-Value="@context.Name" />
</FormItem>
<FormItem Label="图标" LabelCol="LayoutModel._formItemLayout.LabelCol" WrapperCol="LayoutModel._formItemLayout.WrapperCol">
@* <Input Placeholder="请输入图标" @bind-Value="@context.Icon" />
<a href="https://antblazor.com/zh-CN/components/icon" target="_blank">图标库</a> *@
@* <FormItem Label="图标" LabelCol="LayoutModel._formItemLayout.LabelCol" WrapperCol="LayoutModel._formItemLayout.WrapperCol">
<Input Placeholder="请输入图标" @bind-Value="@context.Icon" />
<a href="https://antblazor.com/zh-CN/components/icon" target="_blank">图标库</a>
<IconPicker @bind-Value="@context.Icon"></IconPicker>
</FormItem>
</FormItem> *@
<FormItem Label="类型" LabelCol="LayoutModel._formItemLayout.LabelCol" WrapperCol="LayoutModel._formItemLayout.WrapperCol">
<RadioGroup @bind-Value="context.Type" OnChange="OnAppTypeChange" TValue="string" ButtonStyle="RadioButtonStyle.Solid">
<Radio RadioButton Value="@AppType.chat.ToString()">会话应用</Radio>
@@ -61,18 +61,6 @@
<span>更发散</span>
</FormItem>
}
else
{
<FormItem Label="图片模型" LabelCol="LayoutModel._formItemLayout.LabelCol" WrapperCol="LayoutModel._formItemLayout.WrapperCol">
<Select DataSource="@_imageList"
@bind-Value="@context.ImageModelID"
ValueProperty="c=>c.Id"
LabelProperty="c=>'【'+c.AIType.ToString()+'】'+c.ModelDescription">
</Select>
<Button Type="@ButtonType.Link" OnClick="NavigateModelList">去创建</Button>
</FormItem>
}
@if (@context.Type == AppType.chat.ToString())
{
<FormItem Label="API插件列表" LabelCol="LayoutModel._formItemLayout.LabelCol" WrapperCol="LayoutModel._formItemLayout.WrapperCol">

View File

@@ -48,7 +48,6 @@ namespace AntSK.Pages.AppPage
private List<AIModels> _chatList;
private List<AIModels> _embedingList;
private List<AIModels> _rerankList;
private List<AIModels> _imageList;
protected override async Task OnInitializedAsync()
{
await base.OnInitializedAsync();
@@ -58,7 +57,7 @@ namespace AntSK.Pages.AppPage
_chatList = models.Where(p => p.AIModelType == AIModelType.Chat).ToList();
_embedingList = models.Where(p => p.AIModelType == AIModelType.Embedding).ToList();
_rerankList = models.Where(p => p.AIModelType == AIModelType.Rerank).ToList();
_imageList = models.Where(p => p.AIModelType == AIModelType.Image).ToList();
_functionService.SearchMarkedMethods();
foreach (var func in _functionService.Functions)

View File

@@ -29,7 +29,7 @@ namespace AntSK.Pages.AppPage
}
else
{
data = await _apps_Repositories.GetListAsync(p => p.Name.Contains(searchKey));
data = await _apps_Repositories.GetListAsync(p => p.Name.Contains(searchKey)|| p.SecretKey==searchKey);
}
list.AddRange(data);

View File

@@ -69,6 +69,20 @@
</Row>
<Divider><Title Level="3">功能特性</Title></Divider>
<Space Size=@(("10", "10" )) Wrap Align="start" Style="padding:10px">
<SpaceItem>
<Card Bordered="true" Title=@("👉🏻商业版") Hoverable="true" Style="height:260px;width:300px">
<Body>
<Text>● AntSKPro为商业版 <a href="https://antsk.cn" target="_blank">访问官网</a></Text>
<br>
<Text>● 开源版本请参见:</Text>
<a href="https://github.com/AIDotNet/AntSK" target="_blank">AntSK开源版</a>
<br>
<Text>● 如需商业版授权,请联系微信:</Text>
<b style="color:#1890ff">xuzeyu91</b>
<br>
</Body>
</Card>
</SpaceItem>
<SpaceItem>
<Card Bordered="true" Title=@("🍬语义内核") Hoverable="true" Style="height:260px;width:300px">
<Body>
@@ -152,20 +166,13 @@
</Card>
</SpaceItem>
<SpaceItem>
<Card Bordered="true" Title=@("❤项目最新进展") Hoverable="true" Style="height:260px;width:300px">
<Card Bordered="true" Title=@("❤关注我的公众号") Hoverable="true" Style="height:260px;width:300px">
<Body>
<Image Height="170" Src="./assets/gzh.jpg" />
</Body>
</Card>
</SpaceItem>
<SpaceItem>
<Card Bordered="true" Title=@("🥤项目赞助") Hoverable="true" Style="height:260px;width:300px">
<Body>
<Image Width="110" Src="./assets/zfb.png" />
<Image Width="110" Src="./assets/wx.png" />
</Body>
</Card>
</SpaceItem>
</Space>
</GridContent>

View File

@@ -17,11 +17,11 @@
<FormItem Label="知识库名称" LabelCol="LayoutModel._formItemLayout.LabelCol" WrapperCol="LayoutModel._formItemLayout.WrapperCol">
<Input Placeholder="请输入知识库名称" @bind-Value="@context.Name" />
</FormItem>
<FormItem Label="图标" LabelCol="LayoutModel._formItemLayout.LabelCol" WrapperCol="LayoutModel._formItemLayout.WrapperCol">
@* <Input Placeholder="请输入图标" @bind-Value="@context.Icon" />
<a href="https://antblazor.com/zh-CN/components/icon" target="_blank">图标库</a> *@
@* <FormItem Label="图标" LabelCol="LayoutModel._formItemLayout.LabelCol" WrapperCol="LayoutModel._formItemLayout.WrapperCol">
<Input Placeholder="请输入图标" @bind-Value="@context.Icon" />
<a href="https://antblazor.com/zh-CN/components/icon" target="_blank">图标库</a>
<IconPicker @bind-Value="@context.Icon"></IconPicker>
</FormItem>
</FormItem>*@
<FormItem Label="描述" LabelCol="LayoutModel._formItemLayout.LabelCol" WrapperCol="LayoutModel._formItemLayout.WrapperCol">
<Input Placeholder="请输入描述" @bind-Value="@context.Describe" />
</FormItem>

View File

@@ -7,7 +7,6 @@
@using BlazorComponents.Terminal
@page "/modelmanager/model/add"
@page "/modelmanager/model/add/{ModelId}"
@page "/modelmanager/model/addbypath/{ModelPath}"
@using AntSK.Services.Auth
@inherits AuthComponentBase
@using Microsoft.AspNetCore.Authorization
@@ -29,7 +28,6 @@
<Radio RadioButton Value="@(AIModelType.Chat)">会话模型</Radio>
<Radio RadioButton Value="@(AIModelType.Embedding)">向量模型</Radio>
<Radio RadioButton Value="@(AIModelType.Rerank)">Rerank重排模型</Radio>
<Radio RadioButton Value="@(AIModelType.Image)">图片模型</Radio>
</RadioGroup>
</FormItem>
@@ -56,10 +54,6 @@
{
<Radio RadioButton Value="@(AIType.BgeRerank)">BgeRerank</Radio>
}
else if (context.AIModelType == AIModelType.Image)
{
<Radio RadioButton Value="@(AIType.StableDiffusion)">StableDiffusion</Radio>
}
</RadioGroup>
</FormItem>
@@ -119,15 +113,6 @@
<Input Placeholder="请输入模型名称" @bind-Value="@context.ModelName" AutoComplete="false" />
</FormItem>
}
@if (context.AIType == AIType.StableDiffusion)
{
<FormItem Label="模型路径" LabelCol="LayoutModel._formItemLayout.LabelCol" WrapperCol="LayoutModel._formItemLayout.WrapperCol">
<InputGroup>
<AutoComplete Options="_modelFiles" Placeholder="请输入模型路径" @bind-Value="@context.ModelName" />
<Button OnClick="()=>_downloadModalVisible=true" Style="margin-top:5px">从Haggingface下载</Button>
</InputGroup>
</FormItem>
}
@if (context.AIType == AIType.LLamaFactory)
{
<FormItem Label="模型名称" LabelCol="LayoutModel._formItemLayout.LabelCol" WrapperCol="LayoutModel._formItemLayout.WrapperCol">

View File

@@ -21,8 +21,6 @@ namespace AntSK.Pages.Setting.AIModel
{
[Parameter]
public string ModelId { get; set; }
[Parameter]
public string ModelPath { get; set; }
[Inject] protected IAIModels_Repositories _aimodels_Repositories { get; set; }
[Inject] protected MessageService? Message { get; set; }
[Inject] public HttpClient HttpClient { get; set; }
@@ -94,32 +92,11 @@ namespace AntSK.Pages.Setting.AIModel
{
llamaFactoryIsStart = llamaFactoryDic.Value == "false" ? false : true;
}
//目前只支持gguf的 所以筛选一下
_modelFiles = Directory.GetFiles(Path.Combine(Directory.GetCurrentDirectory(), FileDirOption.DirectoryPath)).Where(p => p.Contains(".gguf") || p.Contains(".ckpt") || p.Contains(".safetensors")).ToArray();
if (!string.IsNullOrEmpty(ModelPath))
{
string extension = Path.GetExtension(ModelPath);
switch (extension)
{
case ".safetensors":
case ".ckpt":
_aiModel.AIType = AIType.StableDiffusion;
break;
}
//下载页跳入
_downloadModalVisible = true;
_downloadUrl = $"https://hf-mirror.com{ModelPath.Replace("---", "/")}";
}
}
catch (System.Exception ex)
{
Log.Error(ex.Message + ex.StackTrace);
_ = Message.Error("FileDirOption.FileDirectory目录配置不正确", 2);
_ = Message.Error($"{ex.Message + ex.StackTrace}", 2);
}
}
@@ -461,9 +438,6 @@ namespace AntSK.Pages.Setting.AIModel
_aiModel.EndPoint = "http://localhost:11434/";
_aiModel.AIModelType = AIModelType.Embedding;
break;
case AIType.StableDiffusion:
_aiModel.AIModelType = AIModelType.Image;
break;
case AIType.Mock:
_aiModel.AIModelType = AIModelType.Chat;
break;
@@ -494,9 +468,6 @@ namespace AntSK.Pages.Setting.AIModel
case AIModelType.Rerank:
_aiModel.AIType = AIType.BgeRerank;
break;
case AIModelType.Image:
_aiModel.AIType = AIType.StableDiffusion;
break;
}
}
}

View File

@@ -1,71 +0,0 @@
@namespace AntSK.Pages.Setting.AIModel
@page "/modelmanager/modeldown"
@using AntSK.Services.Auth
@inherits AuthComponentBase
@using Microsoft.AspNetCore.Authorization
@using AntSK.Domain.Domain.Model.hfmirror
@attribute [Authorize(Roles = "AntSKAdmin")]
<div>
<PageContainer Title="模型列表">
<Content>
<RadioGroup @bind-Value="@_modelType" OnChange="OnModelTypeChange" TValue="string" ButtonStyle="@RadioButtonStyle.Solid">
<Radio RadioButton Value="@("ckpt")">StableDiffusion2(ckpt)</Radio>
<Radio RadioButton Value="@("safetensors")">StableDiffusion(safetensors)</Radio>
</RadioGroup>
<div style="text-align: center;">
<Search Placeholder="输入回车"
EnterButton="@("搜索")"
Size="large"
Style="max-width: 522px; width: 100%;"
OnSearch="Search" />
</div>
</Content>
<ChildContent>
<div class="filterCardList">
<Spin Tip="加载中..." Spinning="@(loaddding)">
<AntList TItem="HfModels"
Grid="LayoutModel._listGridType"
DataSource="_modelList">
<ListItem NoFlex>
<Card Hoverable
BodyStyle="padding-bottom: 20px;"
Actions="new[] {
down(()=> Down(context.Id))
}">
<CardMeta>
<TitleTemplate>
@context.Id
</TitleTemplate>
<AvatarTemplate>
<Avatar Size="small" Src="@context.AuthorData.AvatarUrl" />
</AvatarTemplate>
</CardMeta>
<div class="cardItemContent">
<div class="cardInfo">
<div>
<p>Downloads</p>
<p>@context.Downloads.ToString("0,0")</p>
</div>
<div>
<p>Likes</p>
<p>@context.Likes.ToString("0,0")</p>
</div>
</div>
</div>
</Card>
</ListItem>
</AntList>
</Spin>
</div>
</ChildContent>
</PageContainer>
</div>
@code
{
RenderFragment down(Action clickAction) =>@<a key="down" @onclick="@clickAction">下载</a>;
}

View File

@@ -1,82 +0,0 @@
using AntSK.Domain.Domain.Model.hfmirror;
using AntSK.Domain.Utils;
using AntSK.Models;
using Microsoft.AspNetCore.Components;
using Newtonsoft.Json;
using RestSharp;
namespace AntSK.Pages.Setting.AIModel
{
public partial class ModelDown
{
private readonly ListFormModel _model = new ListFormModel();
private readonly IList<string> _selectCategories = new List<string>();
private List<HfModels> _modelList = new List<HfModels>();
private string _modelType="gguf";
private bool loaddding = false;
protected override async Task OnInitializedAsync()
{
await base.OnInitializedAsync();
InitData("");
}
private async Task InitData(string searchKey)
{
loaddding = true;
if (_modelType.Contains("safetensors"))
{
_modelList.Clear();
var param = searchKey.ConvertToString().Split(" ");
string[] lines = File.ReadAllLines(Path.Combine(AppContext.BaseDirectory, "StableDiffusionModelList.txt"));
foreach (string line in lines)
{
string urlBase = $"https://hf-mirror.com/models-json?sort=trending&search={line}";
if (param.Count() > 0)
{
urlBase += "+" + string.Join("+", param);
}
RestClient client = new RestClient();
RestRequest request = new RestRequest(urlBase, Method.Get);
var response = await client.ExecuteAsync(request);
var model = JsonConvert.DeserializeObject<HfModel>(response.Content);
_modelList.AddRange(model.models);
}
}
else
{
var param = searchKey.ConvertToString().Split(" ");
string urlBase = $"https://hf-mirror.com/models-json?sort=trending&search={_modelType}";
if (param.Count() > 0)
{
urlBase += "+" + string.Join("+", param);
}
RestClient client = new RestClient();
RestRequest request = new RestRequest(urlBase, Method.Get);
var response = await client.ExecuteAsync(request);
var model = JsonConvert.DeserializeObject<HfModel>(response.Content);
_modelList = model.models;
}
loaddding = false;
InvokeAsync(StateHasChanged);
}
private async Task Search(string searchKey)
{
InitData(searchKey);
}
private void Down(string modelPath)
{
NavigationManager.NavigateTo($"/modelmanager/modeldown/detail/{modelPath}");
}
private void OnModelTypeChange(string value)
{
InitData("");
}
}
}

View File

@@ -1,46 +0,0 @@
/* stylelint-disable at-rule-empty-line-before,at-rule-name-space-after,at-rule-no-unknown */
/* stylelint-disable no-duplicate-selectors */
/* stylelint-disable */
/* stylelint-disable declaration-bang-space-before,no-duplicate-selectors,string-no-newline */
.filterCardList .ant-card-meta-content {
margin-top: 0;
}
.filterCardList .ant-card-meta-avatar {
font-size: 0;
}
.filterCardList .ant-list .ant-list-item-content-single {
max-width: 100%;
}
.filterCardList .cardInfo {
margin-top: 16px;
margin-left: 40px;
zoom: 1;
}
.filterCardList .cardInfo::before,
.filterCardList .cardInfo::after {
display: table;
content: ' ';
}
.filterCardList .cardInfo::after {
clear: both;
height: 0;
font-size: 0;
visibility: hidden;
}
.filterCardList .cardInfo > div {
position: relative;
float: left;
width: 50%;
text-align: left;
}
.filterCardList .cardInfo > div p {
margin: 0;
font-size: 24px;
line-height: 32px;
}
.filterCardList .cardInfo > div p:first-child {
margin-bottom: 4px;
color: rgba(0, 0, 0, 0.45);
font-size: 12px;
line-height: 20px;
}

View File

@@ -1,55 +0,0 @@
@namespace AntSK.Pages.Setting.AIModel
@page "/modelmanager/modeldown/detail/{ModelName}/{ModelPath}"
@using AntSK.Services.Auth
@inherits AuthComponentBase
@using Microsoft.AspNetCore.Authorization
@using AntSK.Domain.Domain.Model.hfmirror;
using AntSK.Domain.Domain.Model.hfmirror
@attribute [Authorize(Roles = "AntSKAdmin")]
<div>
<PageContainer Title="模型下载">
<ChildContent>
<div class="standardList">
<Card Class="listCard"
Title="模型列表"
Style="margin-top: 24px;"
BodyStyle="padding: 0 32px 40px 32px">
<Extra>
</Extra>
<ChildContent>
<AntList TItem="HfModelDetail"
DataSource="modelList"
ItemLayout="ListItemLayout.Horizontal">
<ListItem Actions="new[] {
down(()=> Down(context.Path))
}" Style="width:100%">
<div class="listContent" style="width:100%">
<div class="listContentItem" style="width:20%">
<b>名称</b>
<p>@context.Name</p>
</div>
<div class="listContentItem" style="width:20%">
<b>文件大小</b>
<p>@context.Size</p>
</div>
<div class="listContentItem" style="width:20%">
<b>更新时间</b>
<p>@context.Time</p>
</div>
</div>
</ListItem>
</AntList>
</ChildContent>
</Card>
</div>
</ChildContent>
</PageContainer>
</div>
@code
{
RenderFragment down(Action clickAction) =>@<a key="down" @onclick="@clickAction">下载</a>;
}

View File

@@ -1,56 +0,0 @@
using AntSK.Domain.Domain.Model.hfmirror;
using DocumentFormat.OpenXml.EMMA;
using DocumentFormat.OpenXml.Spreadsheet;
using HtmlAgilityPack;
using Microsoft.AspNetCore.Components;
using RestSharp;
namespace AntSK.Pages.Setting.AIModel
{
public partial class ModelDownDetail
{
[Parameter]
public string ModelName { get; set; }
[Parameter]
public string ModelPath { get; set; }
List<HfModelDetail> modelList = new List<HfModelDetail>();
protected override async Task OnInitializedAsync()
{
await base.OnInitializedAsync();
InitData();
}
private void InitData()
{
string urlBase = $"https://hf-mirror.com/{ModelName}/{ModelPath}/tree/main";
RestClient client = new RestClient();
RestRequest request = new RestRequest(urlBase, Method.Get);
var response = client.Execute(request);
var htmlDocument = new HtmlDocument();
htmlDocument.LoadHtml(response.Content);
foreach (var listItem in htmlDocument.DocumentNode.SelectNodes("//li[contains(@class,'grid')]"))
{
var modelNameNode = listItem.SelectSingleNode(".//span[contains(@class,'truncate')]");
var fileSizeNode = listItem.SelectSingleNode(".//a[contains(@class,'text-[0.8rem]')]");
var downloadNode = listItem.SelectSingleNode(".//a[@title='Download file']");
var timeNode = listItem.SelectSingleNode(".//time");
var modelName = modelNameNode?.InnerText.Trim();
var fileSizeInfo = fileSizeNode?.InnerText.Trim().Split(' ');
var fileSize = fileSizeInfo?.Length > 1 ? fileSizeInfo[fileSizeInfo.Length - 2] : null;
var downloadUrl = downloadNode?.GetAttributeValue("href", null)?.Trim();
var time= timeNode?.InnerText.Trim();
modelList.Add(new HfModelDetail() { Name = modelName, Size = string.Join(" ",fileSizeInfo), Path = downloadUrl,Time=time });
}
}
private void Down(string path)
{
NavigationManager.NavigateTo($"/modelmanager/model/addbypath/{path.Replace("?download=true", "").Replace("/", "---")}");
}
}
}

View File

@@ -1,186 +0,0 @@
/* stylelint-disable at-rule-empty-line-before,at-rule-name-space-after,at-rule-no-unknown */
/* stylelint-disable no-duplicate-selectors */
/* stylelint-disable */
/* stylelint-disable declaration-bang-space-before,no-duplicate-selectors,string-no-newline */
.standardList .ant-card-head {
border-bottom: none;
}
.standardList .ant-card-head-title {
padding: 24px 0;
line-height: 32px;
}
.standardList .ant-card-extra {
padding: 24px 0;
}
.standardList .ant-list-pagination {
margin-top: 24px;
text-align: right;
}
.standardList .ant-avatar-lg {
width: 48px;
height: 48px;
line-height: 48px;
}
.standardList .headerInfo {
position: relative;
text-align: center;
}
.standardList .headerInfo > span {
display: inline-block;
margin-bottom: 4px;
color: rgba(0, 0, 0, 0.45);
font-size: 14px;
line-height: 22px;
}
.standardList .headerInfo > p {
margin: 0;
color: rgba(0, 0, 0, 0.85);
font-size: 24px;
line-height: 32px;
}
.standardList .headerInfo > em {
position: absolute;
top: 0;
right: 0;
width: 1px;
height: 56px;
background-color: #f0f0f0;
}
.standardList .listContent {
font-size: 0;
}
.standardList .listContent .listContentItem {
display: inline-block;
margin-left: 40px;
color: rgba(0, 0, 0, 0.45);
font-size: 14px;
vertical-align: middle;
}
.standardList .listContent .listContentItem > span {
line-height: 20px;
}
.standardList .listContent .listContentItem > p {
margin-top: 4px;
margin-bottom: 0;
line-height: 22px;
}
.standardList .extraContentSearch {
width: 272px;
margin-left: 16px;
}
@media screen and (max-width: 480px) {
.standardList .ant-list-item-content {
display: block;
flex: none;
width: 100%;
}
.standardList .ant-list-item-action {
margin-left: 0;
}
.standardList .listContent {
margin-left: 0;
}
.standardList .listContent > div {
margin-left: 0;
}
.standardList .listCard .ant-card-head-title {
overflow: visible;
}
}
@media screen and (max-width: 576px) {
.standardList .extraContentSearch {
width: 100%;
margin-left: 0;
}
.standardList .headerInfo {
margin-bottom: 16px;
}
.standardList .headerInfo > em {
display: none;
}
}
@media screen and (max-width: 768px) {
.standardList .listContent > div {
display: block;
}
.standardList .listContent > div:last-child {
top: 0;
width: 100%;
}
.listCard .ant-radio-group {
display: block;
margin-bottom: 8px;
}
}
@media screen and (max-width: 992px) and (min-width: 768px) {
.standardList .listContent > div {
display: block;
}
.standardList .listContent > div:last-child {
top: 0;
width: 100%;
}
}
@media screen and (max-width: 1200px) {
.standardList .listContent > div {
margin-left: 24px;
}
.standardList .listContent > div:last-child {
top: 0;
}
}
@media screen and (max-width: 1400px) {
.standardList .listContent {
text-align: right;
}
.standardList .listContent > div:last-child {
top: 0;
}
}
.standardListForm .ant-form-item {
margin-bottom: 12px;
}
.standardListForm .ant-form-item:last-child {
margin-bottom: 32px;
padding-top: 4px;
}
.formResult {
width: 100%;
}
.formResult [class^='title'] {
margin-bottom: 8px;
}

View File

@@ -74,10 +74,6 @@
{
<Tag Color="@PresetColor.GeekBlue.ToString()">BgeRerank</Tag>
}
else if (context.AIType == AIType.StableDiffusion)
{
<Tag Color="@PresetColor.Magenta.ToString()">StableDiffusion</Tag>
}
else if (context.AIType == AIType.Ollama || context.AIType == AIType.OllamaEmbedding)
{
<Tag Color="@PresetColor.Pink.ToString()">Ollama</Tag>
@@ -97,10 +93,6 @@
{
<Tag Color="@PresetColor.Green.ToString()">向量模型</Tag>
}
else if (context.AIModelType == AIModelType.Image)
{
<Tag Color="@PresetColor.Lime.ToString()">图片模型</Tag>
}
else if (context.AIModelType == AIModelType.Rerank)
{
<Tag Color="@PresetColor.GeekBlue.ToString()">Rerank重排模型</Tag>

View File

@@ -12,8 +12,8 @@
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>AntSK</title>
<base href="~/" />
<link href="_content/AntDesign/css/ant-design-blazor.css" rel="stylesheet" />
<link href="_content/AntDesign.ProLayout/css/ant-design-pro-layout-blazor.css" rel="stylesheet" />
<link href="./css/ant-design-blazor.css" rel="stylesheet" />
<link href="./css/ant-design-pro-layout-blazor.css" rel="stylesheet" />
<link href="./css/site.css" rel="stylesheet" />
<link href="AntSK.styles.css" rel="stylesheet" />

View File

@@ -10,7 +10,6 @@ using AntSK.Domain.Utils;
using AntSK.plugins.Functions;
using AntSK.Services.Auth;
using Blazored.LocalStorage;
using LLama.Native;
using Microsoft.AspNetCore.Components;
using Microsoft.AspNetCore.Components.Authorization;
using Microsoft.AspNetCore.Mvc;

File diff suppressed because it is too large Load Diff

File diff suppressed because one or more lines are too long

View File

@@ -0,0 +1,96 @@
.diagram-canvas {
width: 100%;
height: 100%;
position: inherit;
outline: 0;
overflow: hidden;
cursor: -webkit-grab;
cursor: grab;
touch-action: none;
}
.diagram-svg-layer, .diagram-html-layer {
top: 0;
left: 0;
right: 0;
bottom: 0;
position: absolute;
pointer-events: none;
-webkit-transform-origin: 0 0;
-ms-transform-origin: 0 0;
transform-origin: 0 0;
width: 100%;
height: 100%;
overflow: visible;
}
.html-layer, .svg-layer {
position: absolute;
pointer-events: none;
-webkit-transform-origin: 0 0;
-ms-transform-origin: 0 0;
transform-origin: 0 0;
width: 100%;
height: 100%;
overflow: visible;
}
.diagram-node {
position: absolute;
-webkit-user-select: none;
-moz-user-select: none;
-ms-user-select: none;
user-select: none;
cursor: move;
pointer-events: all;
}
.diagram-node.locked {
cursor: pointer;
}
.diagram-link {
pointer-events: visiblePainted;
cursor: pointer;
}
.diagram-navigator {
z-index: 10;
}
.diagram-navigator .current-view {
position: absolute;
border: 2px solid #000;
}
.diagram-group {
position: absolute;
-webkit-user-select: none;
-moz-user-select: none;
-ms-user-select: none;
user-select: none;
cursor: move;
pointer-events: all;
}
.diagram-group .children {
position: absolute;
overflow: visible;
pointer-events: none;
}
.diagram-link foreignObject.diagram-link-label {
overflow: visible;
pointer-events: none;
width: 1px;
height: 1px;
}
div.diagram-control {
position: absolute;
}
.executable.diagram-control {
pointer-events: all;
cursor: pointer;
}

View File

@@ -1 +1 @@
code[class*=language-],pre[class*=language-]{color:#000;background:0 0;font-family:Consolas,Monaco,'Andale Mono','Ubuntu Mono',monospace;font-size:1em;text-align:left;white-space:pre;word-spacing:normal;word-break:normal;word-wrap:normal;line-height:1.5;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-hyphens:none;-moz-hyphens:none;-ms-hyphens:none;hyphens:none}pre[class*=language-]{position:relative;margin:.5em 0;overflow:visible;padding:1px}pre[class*=language-]>code{position:relative;z-index:1;border-left:10px solid #358ccb;box-shadow:-1px 0 0 0 #358ccb,0 0 0 1px #dfdfdf;background-color:#fdfdfd;background-image:linear-gradient(transparent 50%,rgba(69,142,209,.04) 50%);background-size:3em 3em;background-origin:content-box;background-attachment:local}code[class*=language-]{max-height:inherit;height:inherit;padding:0 1em;display:block;overflow:auto}:not(pre)>code[class*=language-],pre[class*=language-]{background-color:#fdfdfd;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;margin-bottom:1em}:not(pre)>code[class*=language-]{position:relative;padding:.2em;border-radius:.3em;color:#c92c2c;border:1px solid rgba(0,0,0,.1);display:inline;white-space:normal}pre[class*=language-]:after,pre[class*=language-]:before{content:'';display:block;position:absolute;bottom:.75em;left:.18em;width:40%;height:20%;max-height:13em;box-shadow:0 13px 8px #979797;-webkit-transform:rotate(-2deg);-moz-transform:rotate(-2deg);-ms-transform:rotate(-2deg);-o-transform:rotate(-2deg);transform:rotate(-2deg)}pre[class*=language-]:after{right:.75em;left:auto;-webkit-transform:rotate(2deg);-moz-transform:rotate(2deg);-ms-transform:rotate(2deg);-o-transform:rotate(2deg);transform:rotate(2deg)}.token.block-comment,.token.cdata,.token.comment,.token.doctype,.token.prolog{color:#7d8b99}.token.punctuation{color:#5f6364}.token.boolean,.token.constant,.token.deleted,.token.function-name,.token.number,.token.property,.token.symbol,.token.tag{color:#c92c2c}.token.attr-name,.token.builtin,.token.char,.token.function,.token.inserted,.token.selector,.token.string{color:#2f9c0a}.token.entity,.token.operator,.token.url,.token.variable{color:#a67f59;background:rgba(255,255,255,.5)}.token.atrule,.token.attr-value,.token.class-name,.token.keyword{color:#1990b8}.token.important,.token.regex{color:#e90}.language-css .token.string,.style .token.string{color:#a67f59;background:rgba(255,255,255,.5)}.token.important{font-weight:400}.token.bold{font-weight:700}.token.italic{font-style:italic}.token.entity{cursor:help}.token.namespace{opacity:.7}@media screen and (max-width:767px){pre[class*=language-]:after,pre[class*=language-]:before{bottom:14px;box-shadow:none}}pre[class*=language-].line-numbers.line-numbers{padding-left:0}pre[class*=language-].line-numbers.line-numbers code{padding-left:3.8em}pre[class*=language-].line-numbers.line-numbers .line-numbers-rows{left:0}pre[class*=language-][data-line]{padding-top:0;padding-bottom:0;padding-left:0}pre[data-line] code{position:relative;padding-left:4em}pre .line-highlight{margin-top:0}
code[class*=language-],pre[class*=language-]{color:#000;background:0 0;font-family:Consolas,Monaco,'Andale Mono','Ubuntu Mono',monospace;font-size:1em;text-align:left;white-space:pre;word-spacing:normal;word-break:normal;word-wrap:normal;line-height:1.5;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-hyphens:none;-moz-hyphens:none;-ms-hyphens:none;hyphens:none}pre[class*=language-]{position:relative;margin:.5em 0;overflow:visible;padding:1px}pre[class*=language-]>code{position:relative;z-index:1;border-left:10px solid #1890ff;box-shadow:-1px 0 0 0 #1890ff,0 0 0 1px #dfdfdf;background-color:#fdfdfd;background-image:linear-gradient(transparent 50%,rgba(69,142,209,.04) 50%);background-size:3em 3em;background-origin:content-box;background-attachment:local}code[class*=language-]{max-height:inherit;height:inherit;padding:0 1em;display:block;overflow:auto}:not(pre)>code[class*=language-],pre[class*=language-]{background-color:#fdfdfd;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;margin-bottom:1em}:not(pre)>code[class*=language-]{position:relative;padding:.2em;border-radius:.3em;color:#c92c2c;border:1px solid rgba(0,0,0,.1);display:inline;white-space:normal}pre[class*=language-]:after,pre[class*=language-]:before{content:'';display:block;position:absolute;bottom:.75em;left:.18em;width:40%;height:20%;max-height:13em;box-shadow:0 13px 8px #979797;-webkit-transform:rotate(-2deg);-moz-transform:rotate(-2deg);-ms-transform:rotate(-2deg);-o-transform:rotate(-2deg);transform:rotate(-2deg)}pre[class*=language-]:after{right:.75em;left:auto;-webkit-transform:rotate(2deg);-moz-transform:rotate(2deg);-ms-transform:rotate(2deg);-o-transform:rotate(2deg);transform:rotate(2deg)}.token.block-comment,.token.cdata,.token.comment,.token.doctype,.token.prolog{color:#7d8b99}.token.punctuation{color:#5f6364}.token.boolean,.token.constant,.token.deleted,.token.function-name,.token.number,.token.property,.token.symbol,.token.tag{color:#c92c2c}.token.attr-name,.token.builtin,.token.char,.token.function,.token.inserted,.token.selector,.token.string{color:#2f9c0a}.token.entity,.token.operator,.token.url,.token.variable{color:#a67f59;background:rgba(255,255,255,.5)}.token.atrule,.token.attr-value,.token.class-name,.token.keyword{color:#1990b8}.token.important,.token.regex{color:#e90}.language-css .token.string,.style .token.string{color:#a67f59;background:rgba(255,255,255,.5)}.token.important{font-weight:400}.token.bold{font-weight:700}.token.italic{font-style:italic}.token.entity{cursor:help}.token.namespace{opacity:.7}@media screen and (max-width:767px){pre[class*=language-]:after,pre[class*=language-]:before{bottom:14px;box-shadow:none}}pre[class*=language-].line-numbers.line-numbers{padding-left:0}pre[class*=language-].line-numbers.line-numbers code{padding-left:3.8em}pre[class*=language-].line-numbers.line-numbers .line-numbers-rows{left:0}pre[class*=language-][data-line]{padding-top:0;padding-bottom:0;padding-left:0}pre[data-line] code{position:relative;padding-left:4em}pre .line-highlight{margin-top:0}

View File

@@ -53,3 +53,29 @@ ol {
min-height: 100vh;
}
}
::-webkit-scrollbar {
width: 1px; /* <20><><EFBFBD>ù<EFBFBD><C3B9><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ŀ<EFBFBD><C4BF><EFBFBD> */
height: 8px; /* <20><><EFBFBD><EFBFBD>ˮƽ<CBAE><C6BD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ĸ߶<C4B8> */
}
::-webkit-scrollbar-track {
background: #f5f5f5; /* <20><><EFBFBD>ù<EFBFBD><C3B9><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ı<EFBFBD><C4B1><EFBFBD>ɫ */
}
::-webkit-scrollbar-thumb {
background: #c1c1c1; /* <20><><EFBFBD>ù<EFBFBD><C3B9><EFBFBD><EFBFBD><EFBFBD>Ĵָ<C4B4>ı<EFBFBD><C4B1><EFBFBD>ɫ<EFBFBD><C9AB><EFBFBD><EFBFBD><EFBFBD>϶<EFBFBD><CFB6>IJ<EFBFBD><C4B2>֣<EFBFBD> */
border-radius: 8px; /* <20><><EFBFBD>ù<EFBFBD><C3B9><EFBFBD><EFBFBD><EFBFBD>Ĵָ<C4B4><D6B8>Բ<EFBFBD><D4B2> */
}
::-webkit-scrollbar-thumb:hover {
background: #555; /* <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ͣʱ<CDA3><CAB1><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ĵָ<C4B4>ı<EFBFBD><C4B1><EFBFBD>ɫ */
}
/* <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Firefox */
* {
scrollbar-width: thin; /* <20><><EFBFBD>ù<EFBFBD><C3B9><EFBFBD><EFBFBD><EFBFBD>Ϊϸ<CEAA><CFB8> */
scrollbar-color: #ccc #f1f1f1; /* <20><><EFBFBD>ù<EFBFBD><C3B9><EFBFBD><EFBFBD><EFBFBD>Ĵָ<C4B4>͹<EFBFBD><CDB9><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ɫ */
}

View File

@@ -0,0 +1,70 @@

/*@font-face {
font-family: 'IBM Plex Mono';
font-style: normal;
font-weight: 500;
font-display: swap;
src: url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F6qfjptAgt5VM-kVkqdyU8n3twJwl1FgtIU.woff2) format('woff2');
unicode-range: U+0460-052F, U+1C80-1C88, U+20B4, U+2DE0-2DFF, U+A640-A69F, U+FE2E-FE2F;
}*/
/*@font-face {
font-family: ibmplexmono;
src: url(fonts/ibmplexmono.woff2);
display: swap;
}*/
@font-face {
font-family: CascadiaCode;
src: url(fonts/CascadiaCode.ttf);
display: swap;
}
.bc-terminal-theme {
font-family: CascadiaCode, monospace;
font-style: normal;
font-weight: 500;
background-color: rgb(29, 42, 53);
color: rgb(203, 213, 225);
}
.bc-terminal-theme > .bc-paragraph {
}
.bc-terminal-theme .bc-terminal-input {
color: rgb(203, 213, 225);
caret-color: rgb(5, 206, 145);
font-family: inherit;
font-size: 100%;
/*line-height: 1.15;*/
padding: 0;
}
.bc-terminal-theme > .bc-paragraph-command > .bc-prompt > .bc-prompt-name {
color: rgb(255, 157, 0);
}
.bc-terminal-theme > .bc-paragraph-command > .bc-prompt > .bc-prompt-spr1 {
}
.bc-terminal-theme > .bc-paragraph-command > .bc-prompt > .bc-prompt-host {
color: rgb(5, 206, 145);
}
.bc-terminal-theme > .bc-paragraph-command > .bc-prompt > .bc-prompt-spr2 {
}
.bc-terminal-theme > .bc-paragraph-command > .bc-prompt > .bc-prompt-path {
}
.bc-terminal-theme > .bc-paragraph-command > .bc-prompt > .bc-prompt-pmt {
}
.bc-terminal-theme > .bc-paragraph-response > .bc-command-content {
}

View File

@@ -45,11 +45,6 @@
"path": "/modelmanager/modellist",
"name": "模型管理",
"key": "modelmanager.modellist"
},
{
"path": "/modelmanager/modeldown",
"name": "作图模型下载",
"key": "modelmanager.modeldown"
}
]
},
@@ -77,8 +72,8 @@
]
},
{
"path": "https://antsk.cn/",
"name": "使用文档",
"path": "https://antsk.cn",
"name": "官方文档",
"key": "antskdoc",
"icon": "question-circle"
},
@@ -94,4 +89,4 @@
"key": "antskvideo",
"icon": "video-camera"
}
]
]

View File

@@ -2,19 +2,19 @@
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="keywords" content="antd,umi,umijs,ant design,脚手架,布局, Ant Design,项目,Pro,admin,控制台,主页,开箱即用,中后台,解决方案,组件库" />
<meta name="description" content="An out-of-box UI solution for enterprise applications as a React boilerplate." />
<meta name="description" content="开箱即用的中台前端/设计解决方案。" />
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0" />
<title>Ant Design Pro Blazor</title>
<link rel="icon" href="favicon.ico" type="image/x-icon" />
<base href="/" />
<link href="_content/AntDesign/css/ant-design-blazor.css" rel="stylesheet" />
<link href="_content/AntDesign.ProLayout/css/ant-design-pro-layout-blazor.css" rel="stylesheet" />
<link href="./css/site.css" rel="stylesheet" />
<link href="AntSK.styles.css" rel="stylesheet" />
<meta charset="UTF-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="keywords" content="AI,SemanticKernel,Rag,KMS" />
<meta name="description" content="AntSKPro是一站式本地AI知识库支持模型管理、用户管理、知识库管理、GraphRAG等" />
<meta name="description" content="开箱即用的RAG、知识库平台" />
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0" />
<title>AntSK</title>
<link rel="icon" href="favicon.ico" type="image/x-icon" />
<base href="/" />
<link href="./css/ant-design-blazor.css" rel="stylesheet" />
<link href="./css/ant-design-pro-layout-blazor.css" rel="stylesheet" />
<link href="./css/site.css" rel="stylesheet" />
<link href="AntSK.styles.css" rel="stylesheet" />
</head>
<body>

View File

@@ -1,9 +1,9 @@
<Project>
<!-- See https://aka.ms/dotnet/msbuild/customize for more details on customizing your build -->
<PropertyGroup>
<KMVersion>0.70.240803.1</KMVersion>
<KMVersion>0.90.241021.1</KMVersion>
<NewtonsoftVersion>13.0.3</NewtonsoftVersion>
<RestSharpVersion>111.4.1</RestSharpVersion>
<SKVersion>1.17.1</SKVersion>
<RestSharpVersion>112.1.0</RestSharpVersion>
<SKVersion>1.24.1</SKVersion>
</PropertyGroup>
</Project>