mirror of
https://github.com/Mintplex-Labs/anything-llm.git
synced 2025-05-02 17:07:13 +00:00
patch agent invocation rule (#1175)
This commit is contained in:
parent
2543e8df40
commit
9c00db7d3b
1 changed files with 2 additions and 0 deletions
|
@ -3,7 +3,9 @@ const { v4: uuidv4 } = require("uuid");
|
|||
|
||||
const WorkspaceAgentInvocation = {
|
||||
// returns array of strings with their @ handle.
|
||||
// must start with @
|
||||
parseAgents: function (promptString) {
|
||||
if (!promptString.startsWith("@")) return [];
|
||||
return promptString.split(/\s+/).filter((v) => v.startsWith("@"));
|
||||
},
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue