122
123
private tryToParseAgent(message: string, fullMessage: string, offset: number, position: IPosition, parts: Array<IParsedChatRequestPart>, location: ChatAgentLocation, context: IChatParserContext | undefined): ChatRequestAgentPart | undefined {
125
>
if (!nextAgentMatch) {
126
return;
127
}
129
>
const [full, name] = nextAgentMatch;
130
>
const agentRange = new OffsetRange(offset, offset + full.length);
131
>
const agentEditorRange = new Range(position.lineNumber, position.column, position.lineNumber, position.column + full.length);
132
>
133
>
let agents = this.agentService.getAgentsByName(name);
134
>
if (!agents.length) {
135
const fqAgent = this.agentService.getAgentByFullyQualifiedId(name);
136
if (fqAgent) {