feat(app): lint & beautify

This commit is contained in:
ItzCrazyKns
2025-09-25 18:57:21 +05:30
parent 5f18fc1d22
commit 984163bbbc
6 changed files with 36 additions and 22 deletions

View File

@@ -67,7 +67,9 @@ class MetaSearchAgent implements MetaSearchAgentType {
ChatPromptTemplate.fromMessages([
['system', this.config.queryGeneratorPrompt],
...this.config.queryGeneratorFewShots,
['user', `
[
'user',
`
<conversation>
{chat_history}
</conversation>
@@ -75,7 +77,8 @@ class MetaSearchAgent implements MetaSearchAgentType {
<query>
{query}
</query>
`]
`,
],
]),
llm,
this.strParser,
@@ -87,9 +90,9 @@ class MetaSearchAgent implements MetaSearchAgentType {
const questionOutputParser = new LineOutputParser({
key: 'question',
});
const links = await linksOutputParser.parse(input);
let question = await questionOutputParser.parse(input) ?? input;
let question = (await questionOutputParser.parse(input)) ?? input;
if (question === 'not_needed') {
return { query: '', docs: [] };