last ...
This commit is contained in:
@@ -1,11 +1,16 @@
|
||||
using System.Threading;
|
||||
using xAiModels.Models;
|
||||
using xAiModels.Models.Dtos;
|
||||
using System.Threading.Tasks;
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace xAiApi.Interfaces
|
||||
{
|
||||
public interface IXAiServiceControllerBase
|
||||
{
|
||||
//
|
||||
#region Actions ...
|
||||
/// <summary>
|
||||
/// Ask Question and Get Response ...
|
||||
/// </summary>
|
||||
@@ -28,6 +33,44 @@ namespace xAiApi.Interfaces
|
||||
Task AskTextStream(
|
||||
[FromQuery] string question,
|
||||
CancellationToken cancellationToken = default
|
||||
);
|
||||
);
|
||||
#endregion
|
||||
|
||||
//
|
||||
#region Data Provided Actions ...
|
||||
/// <summary>
|
||||
/// Load AI Projects ...
|
||||
/// </summary>
|
||||
/// <param name="cancellationToken"></param>
|
||||
/// <returns></returns>
|
||||
[HttpGet("LoadProjects")]
|
||||
Task<ActionResult<IEnumerable<XAiProjectDto>>> LoadProjects(
|
||||
CancellationToken cancellationToken = default
|
||||
);
|
||||
|
||||
/// <summary>
|
||||
/// Ask Question and Get Response ...
|
||||
/// </summary>
|
||||
/// <param name="request"></param>
|
||||
/// <param name="cancellationToken"></param>
|
||||
/// <returns></returns>
|
||||
[HttpPost("Ask")]
|
||||
Task<ActionResult<string>> Ask(
|
||||
[FromBody] XAiResponseRequest request,
|
||||
CancellationToken cancellationToken = default
|
||||
);
|
||||
|
||||
/// <summary>
|
||||
/// Ask Question and Get Response Stream ...
|
||||
/// </summary>
|
||||
/// <param name="request"></param>
|
||||
/// <param name="cancellationToken"></param>
|
||||
/// <returns></returns>
|
||||
[HttpPost("AskStream")]
|
||||
Task AskStream(
|
||||
[FromBody] XAiResponseRequest request,
|
||||
CancellationToken cancellationToken = default
|
||||
);
|
||||
#endregion
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user