feat(agent): Refactor search agents and implement SpeedSearchAgent
- Updated FileSearchAgent to improve code readability and formatting. - Refactored SynthesizerAgent for better prompt handling and document processing. - Enhanced TaskManagerAgent with clearer file context handling. - Modified AgentSearch to maintain consistent parameter formatting. - Introduced SpeedSearchAgent for optimized search functionality. - Updated metaSearchAgent to support new SpeedSearchAgent. - Improved file processing utilities for better document handling. - Added test attachments for sporting events queries.
This commit is contained in:
parent
de3d26fb15
commit
d66300e78e
19 changed files with 832 additions and 996 deletions
|
|
@ -43,7 +43,7 @@ type EmbeddingModel = {
|
|||
|
||||
type Body = {
|
||||
message: Message;
|
||||
optimizationMode: 'speed' | 'balanced' | 'agent';
|
||||
optimizationMode: 'speed' | 'agent';
|
||||
focusMode: string;
|
||||
history: Array<[string, string]>;
|
||||
files: Array<string>;
|
||||
|
|
|
|||
|
|
@ -30,7 +30,7 @@ interface embeddingModel {
|
|||
}
|
||||
|
||||
interface ChatRequestBody {
|
||||
optimizationMode: 'speed' | 'balanced' | 'agent';
|
||||
optimizationMode: 'speed' | 'agent';
|
||||
focusMode: string;
|
||||
chatModel?: chatModel;
|
||||
embeddingModel?: embeddingModel;
|
||||
|
|
@ -52,7 +52,7 @@ export const POST = async (req: Request) => {
|
|||
}
|
||||
|
||||
body.history = body.history || [];
|
||||
body.optimizationMode = body.optimizationMode || 'balanced';
|
||||
body.optimizationMode = body.optimizationMode || 'speed';
|
||||
body.stream = body.stream || false;
|
||||
|
||||
const history: BaseMessage[] = body.history.map((msg) => {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue