modcomms/frontend/types.ts
michael 404ba6868b Restructure agent system: remove Tone, split Channel, implement Legal
- Remove Tone Agent (tone is now part of Brand specs)
- Split Channel Agent into Channel Best Practices Agent and Channel Tech Specs Agent
- Convert Legal Agent from stub to full Gemini-powered implementation
- Add new prompt files for channel_best_practices.md, channel_tech_specs.md, legal.md
- Update ReferenceDocsService with new methods for loading specs
- Update schemas and analysis service to use new agent structure
- Update all frontend components to use new agent names and properties
- Update mock data in Projects.tsx and Campaigns.tsx

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-24 11:58:17 -06:00

71 lines
1.7 KiB
TypeScript
Executable file

// Fix: Broke a circular dependency by defining the AgentName type directly in this file instead of importing it.
export type AgentName = 'Legal Agent' | 'Brand Agent' | 'Channel Best Practices Agent' | 'Channel Tech Specs Agent';
export type AgentStatus = 'pending' | 'in-progress' | 'complete' | 'issues-found' | 'error';
export type ReviewStatus = {
[key in AgentName]?: AgentStatus;
};
export type RagStatus = 'Red' | 'Amber' | 'Green' | 'Error';
export interface SubReview {
ragStatus: RagStatus;
feedback: string;
issues: string[];
}
export type OverallStatus = 'Passed' | 'Failed' | 'Analysis Error' | 'Requires Manual Legal Review';
export interface AgentReview {
legalAgentReview: SubReview;
brandAgentReview: SubReview;
channelBestPracticesAgentReview: SubReview;
channelTechSpecsAgentReview: SubReview;
leadAgentSummary: string;
overallStatus: OverallStatus;
financialPromotionReason?: string;
}
export interface FlaggedItem {
id: string;
campaignName: string;
proofName: string;
version: number;
submitter: string;
submitAgency: string;
agentFlagged: string;
comments: string;
timestamp: string;
}
export interface ResolvedItem {
id: string;
campaignName: string;
proofName: string;
version: number;
submitter: string;
submitAgency: string;
agent: string;
issue: string;
resolution: string;
timestamp: string;
}
export interface ErrorItem {
id: string;
campaignName: string;
proofName: string;
version: number;
submitter: string;
submitAgency: string;
errorSummary: string;
timestamp: string;
}
export interface PDFPage {
page: number;
data_url: string;
width: number;
height: number;
}