Update README.md.
This commit is contained in:
parent
071a64ea21
commit
c03be389ca
12
README.md
12
README.md
|
|
@ -28,19 +28,13 @@ BotSharp is in accordance with components principle strictly, decouples every pa
|
||||||
* Integrate with popular message channels like Facebook Messenger, Slack and Telegram.
|
* Integrate with popular message channels like Facebook Messenger, Slack and Telegram.
|
||||||
|
|
||||||
### Quick Started
|
### Quick Started
|
||||||
|
1. Run backend service
|
||||||
* Make sure that you have downloaded the related components.
|
|
||||||
* See the file "BotSharp\BotSharp.WebHost\Settings\app.json",change the path to your own project's path.
|
|
||||||
|
|
||||||
You can use docker compose to run BotSharp quickly, make sure you've got `Docker`_ installed.
|
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
PS D:\> git clone https://github.com/dotnetcore/BotSharp
|
PS D:\> git clone https://github.com/dotnetcore/BotSharp
|
||||||
PS D:\> cd BotSharp
|
PS D:\> cd BotSharp
|
||||||
PS D:\BotSharp\> docker-compose -f dockerfiles/docker-compose-core.yml up
|
PS D:\BotSharp\> dotnet run -p .\src\WebStarter
|
||||||
```
|
```
|
||||||
|
2. Run UI project, reference to [Chatbot UI](src\Plugins\BotSharp.Plugin.ChatbotUI\Chatbot-UI.md).
|
||||||
Point your web browser at http://localhost:5500 and enjoy BotSharp Core.
|
|
||||||
|
|
||||||
### Extension Libraries
|
### Extension Libraries
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,11 @@
|
||||||
|
namespace BotSharp.Abstraction.Agents;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Agent management service
|
||||||
|
/// </summary>
|
||||||
|
public interface IAgentService
|
||||||
|
{
|
||||||
|
void NewAgent();
|
||||||
|
void DeleteAgent();
|
||||||
|
void UpdateAgent();
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,16 @@
|
||||||
|
namespace BotSharp.Abstraction.Agents.Models;
|
||||||
|
|
||||||
|
public class Agent
|
||||||
|
{
|
||||||
|
[StringLength(36)]
|
||||||
|
public string Id { get; set; } = string.Empty;
|
||||||
|
public string Name { get; set; } = string.Empty;
|
||||||
|
public string? Description { get; set; }
|
||||||
|
public DateTime CreatedDateTime { get; set; }
|
||||||
|
public DateTime UpdatedDateTime { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Owner user id
|
||||||
|
/// </summary>
|
||||||
|
public string OwerId { get; set; } = string.Empty;
|
||||||
|
}
|
||||||
|
|
@ -19,6 +19,7 @@
|
||||||
<PackageReference Include="Microsoft.AspNetCore.Http.Abstractions" Version="2.2.0" />
|
<PackageReference Include="Microsoft.AspNetCore.Http.Abstractions" Version="2.2.0" />
|
||||||
<PackageReference Include="Microsoft.Extensions.Configuration.Binder" Version="6.0.0" />
|
<PackageReference Include="Microsoft.Extensions.Configuration.Binder" Version="6.0.0" />
|
||||||
<PackageReference Include="Microsoft.Extensions.DependencyInjection.Abstractions" Version="6.0.0" />
|
<PackageReference Include="Microsoft.Extensions.DependencyInjection.Abstractions" Version="6.0.0" />
|
||||||
|
<PackageReference Include="System.ComponentModel.Annotations" Version="5.0.0" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
</Project>
|
</Project>
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,5 @@
|
||||||
global using System;
|
global using System;
|
||||||
global using System.Collections.Generic;
|
global using System.Collections.Generic;
|
||||||
global using System.Text;
|
global using System.Text;
|
||||||
global using System.Threading.Tasks;
|
global using System.Threading.Tasks;
|
||||||
|
global using System.ComponentModel.DataAnnotations;
|
||||||
|
|
@ -10,13 +10,16 @@ public static class AzureOpenAiServiceCollectionExtensions
|
||||||
{
|
{
|
||||||
public static IServiceCollection AddAzureOpenAiPlatform(this IServiceCollection services, IConfiguration config)
|
public static IServiceCollection AddAzureOpenAiPlatform(this IServiceCollection services, IConfiguration config)
|
||||||
{
|
{
|
||||||
|
var settings = new AzureOpenAiSettings();
|
||||||
|
config.Bind("AzureAi", settings);
|
||||||
|
|
||||||
services.AddSingleton(x =>
|
services.AddSingleton(x =>
|
||||||
{
|
{
|
||||||
var settings = new AzureOpenAiSettings();
|
|
||||||
config.Bind("AzureAi", settings);
|
|
||||||
return settings;
|
return settings;
|
||||||
});
|
});
|
||||||
|
|
||||||
services.AddScoped<IChatCompletionProvider, ChatCompletionProvider>();
|
services.AddScoped<IChatCompletionProvider, ChatCompletionProvider>();
|
||||||
|
|
||||||
return services;
|
return services;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -13,4 +13,4 @@ npm run dev
|
||||||
# Change host to BotSharp service
|
# Change host to BotSharp service
|
||||||
OPENAI_API_HOST=http://localhost:5500
|
OPENAI_API_HOST=http://localhost:5500
|
||||||
```
|
```
|
||||||
|
Access `http://localhost:3000`
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue