Skip to content

Commit

Permalink
better syntax for botfather
Browse files Browse the repository at this point in the history
  • Loading branch information
nothingmn committed Sep 14, 2024
1 parent 232c306 commit 9d80a7a
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,10 @@

namespace Ollabotica.InputProcessors;

[Trigger(Trigger = "/listchats", Description = "List all saved chats.")]
[Trigger(Trigger = "/deletechat", Description = "Delete a saved chat. /deletechat <name>")]
[Trigger(Trigger = "/savechat", Description = "Save the current chat. /savechat <name>")]
[Trigger(Trigger = "/loadchat", Description = "Load a chat based on its name. /loadchat <name>")]
[Trigger(Trigger = "listchats", Description = "List all saved chats.")]
[Trigger(Trigger = "deletechat", Description = "Delete a saved chat. /deletechat <name>")]
[Trigger(Trigger = "savechat", Description = "Save the current chat. /savechat <name>")]
[Trigger(Trigger = "loadchat", Description = "Load a chat based on its name. /loadchat <name>")]
public class ConversationManagerInputProcessor : IMessageInputProcessor
{
private readonly ILogger<ConversationManagerInputProcessor> _log;
Expand Down
2 changes: 1 addition & 1 deletion Ollabotica/InputProcessors/DiagnosticsInputProcessor.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@

namespace Ollabotica.InputProcessors;

[Trigger(Trigger = "/debug", Description = "Dump diagnostic information.", IsAdmin = true)]
[Trigger(Trigger = "debug", Description = "Dump diagnostic information.", IsAdmin = true)]
public class DiagnosticsInputProcessor : IMessageInputProcessor
{
public async Task<bool> Handle(Message message, StringBuilder prompt, OllamaSharp.Chat ollamaChat, TelegramBotClient telegramClient, bool isAdmin, BotConfiguration botConfiguration)
Expand Down
4 changes: 2 additions & 2 deletions Ollabotica/InputProcessors/ModelManagerInputProcessor.cs
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@

namespace Ollabotica.InputProcessors;

[Trigger(Trigger = "/listmodels", Description = "List all available models.")]
[Trigger(Trigger = "/usemodel", Description = "Change the current chat to use a different model. /usemodel <name>")]
[Trigger(Trigger = "listmodels", Description = "List all available models.")]
[Trigger(Trigger = "usemodel", Description = "Change the current chat to use a different model. /usemodel <name>")]
public class ModelManagerInputProcessor : IMessageInputProcessor
{
private readonly ILogger<ModelManagerInputProcessor> _log;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,8 @@

namespace Ollabotica.InputProcessors;

[Trigger(Trigger = "/start", Description = "Clears the message history and starts a new conversation with the model.", IsAdmin = false)]
[Trigger(Trigger = "start", Description = "Clears the message history and starts a new conversation with the model.", IsAdmin = false)]
[Trigger(Trigger = "new", Description = "Clears the message history and starts a new conversation with the model.", IsAdmin = false)]
public class StartNewConversationInputProcessor : IMessageInputProcessor
{
public async Task<bool> Handle(Message message, StringBuilder prompt, OllamaSharp.Chat ollamaChat, TelegramBotClient telegramClient, bool isAdmin, BotConfiguration botConfiguration)
Expand Down

0 comments on commit 9d80a7a

Please sign in to comment.